diff --git a/src/snes/cpu_65816/cpu.rs b/src/snes/cpu_65816/cpu.rs index 2c34a51..fb7ec71 100644 --- a/src/snes/cpu_65816/cpu.rs +++ b/src/snes/cpu_65816/cpu.rs @@ -266,6 +266,12 @@ where .wrapping_add(Address::from(self.regs.read(Register::X))) & ADDRESS_MASK } + AddressingMode::AbsoluteY => { + (Address::from(self.regs.read(Register::DBR)) << 16 + | Address::from(instr.imm::()?)) + .wrapping_add(Address::from(self.regs.read(Register::Y))) + & ADDRESS_MASK + } AddressingMode::StackS => Address::from( self.regs .read(Register::S) diff --git a/src/test/processortests_65816.rs b/src/test/processortests_65816.rs index c4f4429..a8435a8 100644 --- a/src/test/processortests_65816.rs +++ b/src/test/processortests_65816.rs @@ -290,7 +290,7 @@ cpu_test!(instr_95, 0x95); cpu_test!(instr_96, 0x96); cpu_test!(instr_97, 0x97); cpu_test!(instr_98, 0x98); -//cpu_test!(instr_99, 0x99); +cpu_test!(instr_99, 0x99); cpu_test!(instr_9a, 0x9a); cpu_test!(instr_9b, 0x9b); cpu_test!(instr_9c, 0x9c);