|
/* JSR
* PC is next instruction (minus 1) <-- is that right?
- Push high byte of PC - Push low byte of PC - jump to new address
So... RTS: - Pull low byte of PC - Pull high byte of PC - Add 1 to PC */
right
/* if BRK, PC is next instruction + 1 (padding byte) * if IRQ, PC is next instruction
- Push high byte of PC - Push low byte of PC - Push Processor status (B flag set on break, cleared on IRQ, R always set) - Set I flag ??? <-- is this right? - Jump to address at $FFFE-$FFFF
So to compliment this... RTI would: - Pull Processor Status - Pull low byte of PC - Pull high byte of PC */ sounds good except on brk you push PC+2
|