Re: Question IRQ interruption during BRK execution .
Posted: Tue Jan 09, 2024 4:32 pm
For comparison, Acorn's MOS does the same thing in both the early 6502 and later 65C02 versions:
This is nice and fast, but (perhaps notably) not re-entrant. Whether the ISR should be re-entrant is of course a system design decision.
Code: Select all
irqEntryPoint = $dc1c
STA .interruptAccumulator save A
PLA read flags
PHA store flags again
AND #%00010000 check BRK flag
BNE .brkRoutine if (BRK flag set) then branch (to
BRK handler)
... and on into the IRQ handler