ProcessorTests
ProcessorTests copied to clipboard
The 6502 tests assume the P register has bits 4 & 5.
It doesn't. They just don't exist. Bit 5 is hardwired to 1 where it matters, bit 4 to !irq_taken (only visible in the pushed P value in brk).
So any test that requires a result in P that has bits 4 or 5 unset in incorrect (and there's a lot of them). A or with 0x30 would clean them up (and doing that to the inputs too would be a decent idea).