diff --git a/OSBindings/Mac/Clock SignalTests/6502TimingTests.swift b/OSBindings/Mac/Clock SignalTests/6502TimingTests.swift index 550879e75..5f236b8ca 100644 --- a/OSBindings/Mac/Clock SignalTests/6502TimingTests.swift +++ b/OSBindings/Mac/Clock SignalTests/6502TimingTests.swift @@ -217,7 +217,7 @@ class MOS6502TimingTests: XCTestCase, CSTestMachineJamHandler { machine.runForNumber(ofCycles: 10) } - XCTAssert(self.endTime == expectedRunLength, "Took \(self.endTime) cycles to perform") + XCTAssert(self.endTime == expectedRunLength, "Took \(self.endTime) cycles to perform rather than \(expectedRunLength)") } func testMachine(_ machine: CSTestMachine!, didJamAtAddress address: UInt16) { diff --git a/Processors/6502/CPU6502.hpp b/Processors/6502/CPU6502.hpp index 44a75f7d2..96b81dad7 100644 --- a/Processors/6502/CPU6502.hpp +++ b/Processors/6502/CPU6502.hpp @@ -964,8 +964,9 @@ template class Processor { _address.bytes.low = nextAddress.bytes.low; if(_address.bytes.high != nextAddress.bytes.high) { throwaway_read(_address.full); + break; } - break; + continue; case CycleAddXToAddressLowRead: nextAddress.full = _address.full + _x; _address.bytes.low = nextAddress.bytes.low; @@ -976,8 +977,9 @@ template class Processor { _address.bytes.low = nextAddress.bytes.low; if(_address.bytes.high != nextAddress.bytes.high) { throwaway_read(_address.full); + break; } - break; + continue; case CycleAddYToAddressLowRead: nextAddress.full = _address.full + _y; _address.bytes.low = nextAddress.bytes.low; @@ -1061,8 +1063,9 @@ template class Processor { uint16_t halfUpdatedPc = _pc.full; _pc.full = nextAddress.full; throwaway_read(halfUpdatedPc); + break; } - break; + continue; #undef BRA