mirror of
https://github.com/pound-emu/pound.git
synced 2025-12-11 07:36:57 +00:00
aarch64: move cpu files to a new folder
The aarch64 folder will hold all cpu code from now on. Signed-off-by: Ronald Caesar <github43132@proton.me>
This commit is contained in:
parent
b41e8b9d4f
commit
59e812bc63
2 changed files with 33 additions and 7 deletions
|
|
@ -1,5 +1,6 @@
|
|||
#include "cpu.h"
|
||||
#include "JIT/jit.h"
|
||||
#include "isa.h"
|
||||
#include "Base/Assert.h"
|
||||
|
||||
void cpuTest()
|
||||
{
|
||||
CPU cpu;
|
||||
|
|
@ -12,9 +13,5 @@ void cpuTest()
|
|||
cpu.write_byte(8, 0xFF); // RET placeholder
|
||||
|
||||
LOG_INFO(ARM, "{}", cpu.read_byte(0));
|
||||
|
||||
JIT jit;
|
||||
//jit.translate_and_run(cpu);
|
||||
|
||||
cpu.print_debug_information();
|
||||
}
|
||||
}
|
||||
|
|
@ -6,6 +6,35 @@
|
|||
|
||||
#include "Base/Logging/Log.h"
|
||||
|
||||
namespace aarch64
|
||||
{
|
||||
#define GPR_REGISTERS 32
|
||||
#define ZERO_REGISTER_INDEX 31
|
||||
|
||||
#define FPR_REGISTERS 32
|
||||
|
||||
typedef struct
|
||||
{
|
||||
uint64_t gpr[GPR_REGISTERS];
|
||||
unsigned __int128 fpr[FPR_REGISTERS];
|
||||
uint64_t pc;
|
||||
uint64_t sp;
|
||||
} isa_t;
|
||||
|
||||
uint64_t read_X(uint64_t* registers, size_t n);
|
||||
void adr(uint64_t* registers, size_t n, uint64_t pc, uint64_t offset);
|
||||
//=========================================================
|
||||
// Access Floating Point Registers
|
||||
//=========================================================
|
||||
|
||||
uint8_t B(unsigned __int128 registers, size_t n);
|
||||
uint16_t H(unsigned __int128 registers, size_t n);
|
||||
uint32_t S(unsigned __int128 registers, size_t n);
|
||||
uint64_t D(unsigned __int128 registers, size_t n);
|
||||
unsigned __int128 Q(unsigned __int128 registers, size_t n);
|
||||
|
||||
} // namespace aarch64
|
||||
|
||||
struct CPU
|
||||
{
|
||||
u64 regs[31] = {0}; // X0–X30
|
||||
Loading…
Add table
Add a link
Reference in a new issue