geos-atari icon indicating copy to clipboard operation
geos-atari copied to clipboard

Make CallBackBank reentrant

Open ytmytm opened this issue 1 year ago • 0 comments

CallBackBank procedure stores current RAM config from PIA_PORTB in a fixed location. Because of this:

  • bank0 procedures can't be used for functions called from interrupts (an interrupt might happen while bank0 procedure (e.g. Rectangle) is running)
  • bank0 procedure can call another bank0 procedure only directly in bank0, not via jump table that might route it through CallBankBank

This limits the kind of code that can be moved to bank0 - there is still about 1-2K available there, assuming 4K reserved for SIO driver.

ytmytm avatar Nov 08 '22 11:11 ytmytm