Clean up and comments. No functional change

This commit is contained in:
Flyinghead 2019-01-24 09:40:14 +01:00
parent 1501e2273d
commit 0cce6cc5a5
5 changed files with 9 additions and 28 deletions

View File

@ -261,8 +261,8 @@ public:
// ACCUM
//s64 v = ((s64)X * (s64)Y) >> 10; // magic value from dynarec. 1 sign bit + 24-1 bits + 13-1 bits -> 26 bits?
const vixl::aarch64::Register X64 = Register::GetXRegFromCode(X_alias->GetCode());
const vixl::aarch64::Register Y64 = Register::GetXRegFromCode(Y.GetCode());
const Register& X64 = Register::GetXRegFromCode(X_alias->GetCode());
const Register& Y64 = Register::GetXRegFromCode(Y.GetCode());
Sxtw(X64, *X_alias);
Sxtw(Y64, Y);
Mul(x0, X64, Y64);
@ -340,7 +340,7 @@ public:
if (op.EWT)
{
// 4 ????
//DSPData->EFREG[op.EWA] += SHIFTED >> 4; // dynarec uses = instead of +=
//DSPData->EFREG[op.EWA] += SHIFTED >> 4; // x86 dynarec uses = instead of +=
MemOperand mem_operand = dspdata_operand(DSPData->EFREG, op.EWA);
Ldr(w1, mem_operand);
Asr(w2, SHIFTED, 4);

View File

@ -500,10 +500,10 @@ __asm__ (
"arm_dispatch: \n\t"
"ldp w0, w1, [x28, #184] \n\t" // load Next PC, interrupt
"ubfx w2, w0, #2, #21 \n\t"
"cbnz w1, arm_dofiq \n\t"
"ubfx w2, w0, #2, #21 \n\t" // w2 = pc >> 2. Note: assuming address space <= 8 MB (23 bits)
"cbnz w1, arm_dofiq \n\t" // if interrupt pending, handle it
"add x2, x26, x2, lsl #3 \n\t"
"add x2, x26, x2, lsl #3 \n\t" // x2 = EntryPoints + pc << 1
"ldr x3, [x2] \n\t"
"br x3 \n"

View File

@ -62,9 +62,6 @@ void term_mem();
#define AICA_RAM_SIZE (ARAM_SIZE)
#define AICA_RAM_MASK (ARAM_MASK)
#define AICA_MEMMAP_RAM_SIZE (8*1024*1024) //this is the max for the map, the actual ram size is AICA_RAM_SIZE
#define AICA_MEMMAP_RAM_MASK (AICA_MEMMAP_RAM_SIZE-1)
extern bool e68k_out;
void update_armintc();
void update_armintc();

View File

@ -27,8 +27,8 @@ public:
virtual void AdvancePtr(u32 size) override;
virtual std::string GetGameId() override;
void SetKey(u32 key);
void SetKeyData(u8 *key) { SetKey(key[0] | (key[1] << 8) | (key[2] << 16) | (key[3] << 24)); }
void SetKey(u32 key) override;
void SetKeyData(u8 *key) override { SetKey(key[0] | (key[1] << 8) | (key[2] << 16) | (key[3] << 24)); }
private:
virtual void device_reset();

View File

@ -165,22 +165,6 @@ void bm_AddBlock(RuntimeBlockInfo* blk)
}
u32 PAGE_STATE[RAM_SIZE/32];
bool PageIsConst(u32 addr)
{
if (IsOnRam(addr))
{
addr&=RAM_MASK;
if (addr>0x0010100)
{
return PAGE_STATE[addr/32]&(1<<addr);
}
}
return false;
}
bool UDgreaterX ( RuntimeBlockInfo* elem1, RuntimeBlockInfo* elem2 )
{
return elem1->runs > elem2->runs;