mirror of
https://github.com/melonDS-emu/melonDS.git
synced 2025-07-25 15:19:53 -06:00
fix stmd(a/b) writeback
This commit is contained in:
@ -558,8 +558,12 @@ void A_STM(ARM* cpu)
|
|||||||
if (cpu->CurInstr & (1<<22))
|
if (cpu->CurInstr & (1<<22))
|
||||||
cpu->UpdateMode((cpu->CPSR&~0x1F)|0x10, cpu->CPSR, true);
|
cpu->UpdateMode((cpu->CPSR&~0x1F)|0x10, cpu->CPSR, true);
|
||||||
|
|
||||||
if ((cpu->CurInstr & (1<<23)) && (cpu->CurInstr & (1<<21)) && !dataabort)
|
if (!dataabort)
|
||||||
cpu->R[baseid] = base;
|
{
|
||||||
|
if ((cpu->CurInstr & (1<<23)) && (cpu->CurInstr & (1<<21)))
|
||||||
|
cpu->R[baseid] = base;
|
||||||
|
}
|
||||||
|
else cpu->R[baseid] = oldbase;
|
||||||
|
|
||||||
cpu->AddCycles_CD();
|
cpu->AddCycles_CD();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user