ALU instructions can write to PC

This commit is contained in:
Jeffrey Pfau 2013-04-07 02:01:14 -07:00
parent 6e3a9a9508
commit bda71cafc2
1 changed files with 4 additions and 1 deletions

View File

@ -207,7 +207,10 @@ void ARMStep(struct ARMCore* cpu) {
SHIFTER(cpu, opcode); \
BODY; \
S_BODY; \
POST_BODY;)
POST_BODY; \
if (rd == ARM_PC) { \
ARM_WRITE_PC; \
})
#define DEFINE_ALU_INSTRUCTION_ARM(NAME, S_BODY, BODY, POST_BODY) \
DEFINE_ALU_INSTRUCTION_EX_ARM(NAME, , _barrelShift, BODY, POST_BODY) \