Inner interp loop optimization too good to pass up

This commit is contained in:
David Schmenk 2014-06-21 20:49:46 -07:00
parent 72af9602db
commit 73fee14a43
2 changed files with 14 additions and 9 deletions

View File

@ -247,7 +247,7 @@ CMDEXEC = *
;
; INSTALL PAGE 0 FETCHOP ROUTINE
;
LDY #$0E
LDY #$0F
- LDA PAGE0,Y
STA DROP,Y
DEY
@ -319,9 +319,9 @@ PAGE0 = *
INX ; DROP @ $EF
INY ; NEXTOP @ $F0
BEQ NEXTOPH
FETCHOP LDA (IP),Y
LDA $FFFF,Y ; FETCHOP @ $F3, IP MAPS OVER $FFFF @ $F4
STA OPIDX
JMP (OPTBL)
JMP (OPTBL) ; OPIDX AND OPPAGE MAP OVER OPTBL
NEXTOPH INC IPH
BNE FETCHOP
}

View File

@ -17,11 +17,12 @@ VMZP = ESTK+ESTKSZ
IFP = VMZP
IFPL = IFP
IFPH = IFP+1
IP = IFP+2
IPL = IP
IPH = IP+1
IPY = IP+2
TMP = IP+3
;IP = IFP+2 ; MOVED TO OVERLAY NEXTOP
;IPL = IP
;IPH = IP+1
;IPY = IP+2
IPY = IFP+2
TMP = IPY+1
TMPL = TMP
TMPH = TMP+1
NPARMS = TMPL
@ -30,5 +31,9 @@ DVSIGN = TMP+2
ESP = TMP+2
DROP = $EF
NEXTOP = $F0
OPIDX = NEXTOP+8
FETCHOP = NEXTOP+3
IP = FETCHOP+1
IPL = IP
IPH = IPL+1
OPIDX = FETCHOP+6
OPPAGE = OPIDX+1