diff options
author | StapleButter <thetotalworm@gmail.com> | 2018-12-07 14:20:38 +0100 |
---|---|---|
committer | StapleButter <thetotalworm@gmail.com> | 2018-12-08 20:27:00 +0100 |
commit | 86dae1a25c63fa2970c8c870bb2cd32c4a488653 (patch) | |
tree | 52488dbf577c96c632fea6d9a551f1a5b8354c69 /src/ARMInterpreter.cpp | |
parent | 0b1c2f9691ac3f42533f14ce9108e3e56b26936c (diff) |
make this other branch where we're going to actually make it usable
but it'll be a gross hack
Diffstat (limited to 'src/ARMInterpreter.cpp')
-rw-r--r-- | src/ARMInterpreter.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ARMInterpreter.cpp b/src/ARMInterpreter.cpp index b29f558..1312771 100644 --- a/src/ARMInterpreter.cpp +++ b/src/ARMInterpreter.cpp @@ -34,8 +34,8 @@ void A_UNK(ARM* cpu) //for (int i = 0; i < 16; i++) printf("R%d: %08X\n", i, cpu->R[i]); //NDS::Halt(); u32 oldcpsr = cpu->CPSR; - cpu->CPSR &= ~0xFF; - cpu->CPSR |= 0xDB; + cpu->CPSR &= ~0xBF; + cpu->CPSR |= 0x9B; cpu->UpdateMode(oldcpsr, cpu->CPSR); cpu->R_UND[2] = oldcpsr; @@ -48,8 +48,8 @@ void T_UNK(ARM* cpu) printf("undefined THUMB%d instruction %04X @ %08X\n", cpu->Num?7:9, cpu->CurInstr, cpu->R[15]-4); //NDS::Halt(); u32 oldcpsr = cpu->CPSR; - cpu->CPSR &= ~0xFF; - cpu->CPSR |= 0xDB; + cpu->CPSR &= ~0xBF; + cpu->CPSR |= 0x9B; cpu->UpdateMode(oldcpsr, cpu->CPSR); cpu->R_UND[2] = oldcpsr; @@ -221,8 +221,8 @@ void A_MRC(ARM* cpu) void A_SVC(ARM* cpu) { u32 oldcpsr = cpu->CPSR; - cpu->CPSR &= ~0xFF; - cpu->CPSR |= 0xD3; + cpu->CPSR &= ~0xBF; + cpu->CPSR |= 0x93; cpu->UpdateMode(oldcpsr, cpu->CPSR); cpu->R_SVC[2] = oldcpsr; @@ -233,8 +233,8 @@ void A_SVC(ARM* cpu) void T_SVC(ARM* cpu) { u32 oldcpsr = cpu->CPSR; - cpu->CPSR &= ~0xFF; - cpu->CPSR |= 0xD3; + cpu->CPSR &= ~0xBF; + cpu->CPSR |= 0x93; cpu->UpdateMode(oldcpsr, cpu->CPSR); cpu->R_SVC[2] = oldcpsr; |