fix: get beeg.gba working again

This commit is contained in:
2022-07-02 03:15:26 -03:00
parent 66ac4050fd
commit 379e667704
2 changed files with 4 additions and 0 deletions

View File

@@ -13,6 +13,7 @@ pub fn dataProcessing(comptime I: bool, comptime S: bool, comptime instrKind: u4
const old_carry = @boolToInt(cpu.cpsr.c.read());
// If certain conditions are met, PC is 12 ahead instead of 8
// TODO: What are these conditions? I can't remember
if (!I and opcode >> 4 & 1 == 1) cpu.r[15] += 4;
const op1 = if (rn == 0xF) cpu.fakePC() else cpu.r[rn];
@@ -127,6 +128,8 @@ pub fn dataProcessing(comptime I: bool, comptime S: bool, comptime instrKind: u4
setArmLogicOpFlags(S, cpu, rd, result);
},
}
if (rd == 0xF) cpu.pipe.flush();
}
}.inner;
}