sta sp+1
rts
- .data
+.segment "ZPSAVE"
zpsave: .res zpspace
.byte $00 ; $2AF
.byte $80 ; $2AE Machine code flag
.byte $C7 ; $2AD Autoload flag
- .dbyt __BSS_LOAD__ ; $2AB
+ .dbyt __BSS_LOAD__ ; $2AB
.dbyt __RAM_START__ ; $2A9
.byte $00 ; $2A8
.byte $00 ; Zero terminated name
; ------------------------------------------------------------------------
; Data
-.data
+.segment "ZPSAVE"
zpsave: .res zpspace
; ------------------------------------------------------------------------
; Data
-.data
+.segment "ZPSAVE"
+
zpsave: .res zpspace
.bss
jmp RESTOR
-.data
+.segment "ZPSAVE"
+
zpsave: .res zpspace
.bss
+
spsave: .res 1
.data
-zpsave: .res zpspace
IRQInd: jmp $0000
+.segment "ZPSAVE"
+
+zpsave: .res zpspace
+
.bss
spsave: .res 1
.data
-zpsave: .res zpspace
IRQInd: jmp $0000
+.segment "ZPSAVE"
+
+zpsave: .res zpspace
+
.bss
spsave: .res 1
bne dobreak
; It's an IRQ and RAM is enabled. If we have handlers, call them. We will use
-; a flag here instead of loading __INTERRUPTOR_COUNT__ directly, since the
-; condes function is not reentrant. The irqcount flag will be set/reset from
+; a flag here instead of loading __INTERRUPTOR_COUNT__ directly, since the
+; condes function is not reentrant. The irqcount flag will be set/reset from
; the main code, to avoid races.
ldy irqcount
; Data
.data
-zpsave: .res zpspace
; BRK handling
brk_jmp: jmp $0000
spsave: .res 1
+.segment "ZPSAVE"
+
+zpsave: .res zpspace
+
.bss
irqcount: .byte 0
.data
-zpsave: .res zpspace
IRQInd: jmp $0000
+.segment "ZPSAVE"
+
+zpsave: .res zpspace
+
.bss
spsave: .res 1
CODE: load = RAM, type = ro, define = yes;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;
CODE: load = RAM, type = ro;
RODATA: load = RAM, type = ro;
DATA: load = RAM, type = rw;
+ ZPSAVE: load = RAM, type = bss;
BSS: load = RAM, type = bss, define = yes;
HEAP: load = RAM, type = bss, optional = yes; # must sit just below stack
ZEROPAGE: load = ZP, type = zp;