fix(cpu): write results of ORR to destination register

This commit is contained in:
Rekai Nyangadzayi Musuka 2022-01-10 10:56:41 -04:00
parent ed3bdd90fb
commit 072a66cfdb
1 changed files with 1 additions and 0 deletions

View File

@ -76,6 +76,7 @@ pub fn dataProcessing(comptime I: bool, comptime S: bool, comptime instrKind: u4
0xC => {
// ORR
const result = cpu.r[op1] | op2;
cpu.r[rd] = result;
if (S and rd != 0xF) {
cpu.cpsr.n.write(result >> 31 & 1 == 1);