-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dual: arm: Add a stubbed DynarecCPU class
- Loading branch information
Showing
5 changed files
with
151 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,5 +5,4 @@ if(DUAL_ENABLE_JIT) | |
add_subdirectory(lunatic) | ||
endif() | ||
|
||
|
||
add_subdirectory(oaknut) | ||
add_subdirectory(oaknut) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
|
||
#include <atom/panic.hpp> | ||
|
||
#include "dynarec_cpu.hpp" | ||
|
||
namespace dual::arm { | ||
|
||
DynarecCPU::DynarecCPU( | ||
Memory& memory, | ||
Scheduler& scheduler, | ||
CycleCounter& cycle_counter, | ||
Model model, | ||
std::span<const AttachCPn> coprocessors | ||
) { | ||
} | ||
|
||
void DynarecCPU::Reset() { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
u32 DynarecCPU::GetExceptionBase() const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetExceptionBase(u32 address) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::InvalidateICache() { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::InvalidateICacheRange(u32 address_lo, u32 address_hi) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetUnalignedDataAccessEnable(bool enable) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
bool DynarecCPU::GetWaitingForIRQ() const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetWaitingForIRQ(bool value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
bool DynarecCPU::GetIRQFlag() const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetIRQFlag(bool value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
u32 DynarecCPU::GetGPR(GPR reg) const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
u32 DynarecCPU::GetGPR(GPR reg, Mode mode) const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
CPU::PSR DynarecCPU::GetCPSR() const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
CPU::PSR DynarecCPU::GetSPSR(Mode mode) const { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetGPR(GPR reg, u32 value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetGPR(GPR reg, Mode mode, u32 value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetCPSR(PSR value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::SetSPSR(Mode mode, PSR value) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
void DynarecCPU::Run(int cycles) { | ||
ATOM_PANIC("unimplemented"); | ||
} | ||
|
||
} // namespace dual::arm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
|
||
#pragma once | ||
|
||
#include <dual/arm/cpu.hpp> | ||
#include <dual/arm/memory.hpp> | ||
#include <dual/common/scheduler.hpp> | ||
#include <dual/common/cycle_counter.hpp> | ||
#include <span> | ||
|
||
namespace dual::arm { | ||
|
||
class DynarecCPU final : public CPU { | ||
public: | ||
DynarecCPU( | ||
Memory& memory, | ||
Scheduler& scheduler, | ||
CycleCounter& cycle_counter, | ||
Model model, | ||
std::span<const AttachCPn> coprocessors = {} | ||
); | ||
|
||
void Reset() override; | ||
|
||
u32 GetExceptionBase() const override; | ||
void SetExceptionBase(u32 address) override; | ||
|
||
void InvalidateICache() override; | ||
void InvalidateICacheRange(u32 address_lo, u32 address_hi) override; | ||
|
||
void SetUnalignedDataAccessEnable(bool enable) override; | ||
|
||
bool GetWaitingForIRQ() const override; | ||
void SetWaitingForIRQ(bool value) override; | ||
|
||
bool GetIRQFlag() const override; | ||
void SetIRQFlag(bool value) override; | ||
|
||
u32 GetGPR(GPR reg) const override; | ||
u32 GetGPR(GPR reg, Mode mode) const override; | ||
PSR GetCPSR() const override; | ||
PSR GetSPSR(Mode mode) const override; | ||
|
||
void SetGPR(GPR reg, u32 value) override; | ||
void SetGPR(GPR reg, Mode mode, u32 value) override; | ||
void SetCPSR(PSR value) override; | ||
void SetSPSR(Mode mode, PSR value) override; | ||
|
||
void Run(int cycles) override; | ||
}; | ||
|
||
} // namespace dual::arm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters