z80: inline all uses of pushRS/popRS

I'm trying to move stuff around and it simplifies things. Will make
a lot more sense to inline when BC replaces IY.
This commit is contained in:
Virgil Dupras 2020-07-05 21:54:01 -04:00
parent ebf47a2ab5
commit 3ea221d0eb
6 changed files with 15 additions and 23 deletions

View File

@ -1,2 +1 @@
VARIABLE lblofl VARIABLE lblpushRS VARIABLE lblpopRS VARIABLE lblofl VARIABLE lblexec VARIABLE lblfind
VARIABLE lblexec VARIABLE lblfind

11
blk/297
View File

@ -1,11 +0,0 @@
lblpushRS BSET
IX INCd, IX INCd,
0 IX+ L LDIXYr,
1 IX+ H LDIXYr,
RET,
lblpopRS BSET
L 0 IX+ LDrIXY,
H 1 IX+ LDrIXY,
IX DECd, IX DECd,
RET,

View File

@ -3,7 +3,9 @@
2. Set new IP to the second atom of the list 2. Set new IP to the second atom of the list
3. Execute the first atom of the list. ) 3. Execute the first atom of the list. )
IY PUSH, HL POP, ( <-- IP ) IY PUSH, HL POP, ( <-- IP )
lblpushRS @ ( pushRS ) CALL, IX INCd, IX INCd,
0 IX+ L LDIXYr,
1 IX+ H LDIXYr,
EXDEHL, ( HL points to PFA ) EXDEHL, ( HL points to PFA )
( While we inc, dereference into DE for execute call later. ) ( While we inc, dereference into DE for execute call later. )
LDDE(HL), LDDE(HL),

View File

@ -6,6 +6,8 @@ CODE EXECUTE
CODE EXIT CODE EXIT
PC ORG @ 0x0d + ! ( stable ABI JP ) PC ORG @ 0x0d + ! ( stable ABI JP )
lblpopRS @ CALL, L 0 IX+ LDrIXY,
H 1 IX+ LDrIXY,
IX DECd, IX DECd,
HL PUSH, IY POP, ( --> IP ) HL PUSH, IY POP, ( --> IP )
JPNEXT, JPNEXT,

View File

@ -8,4 +8,3 @@ PC ORG @ 0x25 + ! ( stable ABI JP )
IY INCd, IY INCd, IY INCd, IY INCd,
DE PUSH, DE PUSH,
;CODE ;CODE
( END OF STABLE ABI )

15
blk/326
View File

@ -1,15 +1,16 @@
CODE >R CODE >R
HL POP, lblpushRS @ CALL, HL POP, IX INCd, IX INCd, 0 IX+ L LDIXYr, 1 IX+ H LDIXYr,
;CODE ;CODE
CODE R> CODE R>
lblpopRS @ CALL, HL PUSH, L 0 IX+ LDrIXY, H 1 IX+ LDrIXY, IX DECd, IX DECd, HL PUSH,
;CODE ;CODE
CODE 2>R CODE 2>R PC ORG @ 0x35 + ! ( stable ABI JP )
PC ORG @ 0x35 + ! ( stable ABI JP )
DE POP, HL POP, DE POP, HL POP,
lblpushRS @ CALL, EXDEHL, lblpushRS @ CALL, IX INCd, IX INCd, 0 IX+ L LDIXYr, 1 IX+ H LDIXYr,
IX INCd, IX INCd, 0 IX+ E LDIXYr, 1 IX+ D LDIXYr,
;CODE ;CODE
CODE 2R> CODE 2R>
lblpopRS @ CALL, EXDEHL, lblpopRS @ CALL, L 0 IX+ LDrIXY, H 1 IX+ LDrIXY, IX DECd, IX DECd,
HL PUSH, DE PUSH, E 0 IX+ LDrIXY, D 1 IX+ LDrIXY, IX DECd, IX DECd,
DE PUSH, HL PUSH,
;CODE ;CODE