diff --git a/core/src/cpu/operations.rs b/core/src/cpu/operations.rs index c4e351e..b248c97 100644 --- a/core/src/cpu/operations.rs +++ b/core/src/cpu/operations.rs @@ -1,6 +1,8 @@ use crate::cpu::op::Operand; use crate::cpu::{Cpu, CpuInternals, CpuStatus}; +// Unofficial ops documentation: https://www.masswerk.at/6502/6502_instruction_set.html#SAX + fn is_sign_overflow(val1: u8, val2: u8, result: u8) -> bool { (val1 & 0x80 == val2 & 0x80) && (val1 & 0x80 != result & 0x80) }