mirror of
https://github.com/cc65/cc65.git
synced 2025-01-11 11:30:13 +00:00
Moved the data that keeps a copy of the used zero page locations in its own
segment to reduce the executable size. git-svn-id: svn://svn.cc65.org/cc65/trunk@3849 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
ab39981db1
commit
f257b2ee81
@ -174,7 +174,7 @@ initsp:
|
||||
sta sp+1
|
||||
rts
|
||||
|
||||
.data
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
.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
|
||||
@ -100,7 +100,7 @@ L2: lda zpsave,x
|
||||
; ------------------------------------------------------------------------
|
||||
; Data
|
||||
|
||||
.data
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
|
@ -182,7 +182,8 @@ IRQStub:
|
||||
; ------------------------------------------------------------------------
|
||||
; Data
|
||||
|
||||
.data
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
|
@ -102,10 +102,12 @@ L2: lda zpsave,x
|
||||
jmp RESTOR
|
||||
|
||||
|
||||
.data
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
|
||||
spsave: .res 1
|
||||
|
||||
|
||||
|
@ -150,9 +150,12 @@ IRQStub:
|
||||
|
||||
.data
|
||||
|
||||
zpsave: .res zpspace
|
||||
IRQInd: jmp $0000
|
||||
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
|
||||
spsave: .res 1
|
||||
|
@ -136,9 +136,12 @@ IRQStub:
|
||||
|
||||
.data
|
||||
|
||||
zpsave: .res zpspace
|
||||
IRQInd: jmp $0000
|
||||
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
|
||||
spsave: .res 1
|
||||
|
@ -147,8 +147,8 @@ IRQ: cld ; Just to be sure
|
||||
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
|
||||
@ -194,13 +194,16 @@ nohandler:
|
||||
; Data
|
||||
|
||||
.data
|
||||
zpsave: .res zpspace
|
||||
|
||||
; BRK handling
|
||||
brk_jmp: jmp $0000
|
||||
|
||||
spsave: .res 1
|
||||
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
irqcount: .byte 0
|
||||
|
||||
|
@ -142,9 +142,12 @@ IRQStub:
|
||||
|
||||
.data
|
||||
|
||||
zpsave: .res zpspace
|
||||
IRQInd: jmp $0000
|
||||
|
||||
.segment "ZPSAVE"
|
||||
|
||||
zpsave: .res zpspace
|
||||
|
||||
.bss
|
||||
|
||||
spsave: .res 1
|
||||
|
@ -18,6 +18,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -11,6 +11,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
@ -9,6 +9,7 @@ SEGMENTS {
|
||||
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;
|
||||
|
Loading…
x
Reference in New Issue
Block a user