1
0
mirror of https://github.com/dschmenk/PLASMA.git synced 2024-07-23 02:29:02 +00:00

Update ops $50-$5E

This commit is contained in:
David Schmenk 2018-03-25 13:53:53 -07:00
parent 23779176d2
commit 08e41bf472

View File

@ -894,7 +894,7 @@ def compiler(defptr)#0
addrxlate=>[dest] = codeptr + 5 - *jitcodeptr
//addrxlate=>[dest] = codeptr - *jitcodeptr
fin
codeptr = codeptr + 7
codeptr = codeptr + 7
//codeptr = codeptr + 2
A_IS_TOSL = FALSE
break
@ -924,7 +924,7 @@ def compiler(defptr)#0
addrxlate=>[dest] = codeptr + 5 - *jitcodeptr
//addrxlate=>[dest] = codeptr - *jitcodeptr
fin
codeptr = codeptr + 7
codeptr = codeptr + 7
//codeptr = codeptr + 2
A_IS_TOSL = FALSE
break
@ -939,12 +939,17 @@ def compiler(defptr)#0
*codeptr = $D095+(VX<<8) // STA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $4C; codeptr++ // JMP abs
*codeptr = addrxlate=>[dest]
if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[dest] = codeptr - *jitcodeptr
codeptr->0 = $4C // JMP abs
//^codeptr = $4C; codeptr++ // JMP abs
codeptr=>1 = addrxlate=>[dest]
//*codeptr = addrxlate=>[dest]
if not (codeptr->2 & $80) // Unresolved address list
//if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[dest] = codeptr + 1 - *jitcodeptr
//addrxlate=>[dest] = codeptr - *jitcodeptr
fin
codeptr = codeptr + 2
codeptr = codeptr + 3
//codeptr = codeptr + 2
A_IS_TOSL = FALSE
break
is $52
@ -958,47 +963,64 @@ def compiler(defptr)#0
^(bytecode+case) = $FE // Flag as NOP
case++
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $B4; codeptr++ // LDY zp,X
^codeptr = $C0+VX; codeptr++ // ESTKH
//VX++ //^codeptr = $E8; codeptr++ // INX
codeptr, VX = resolveX(codeptr, VX + 1)
codeptr=>0 = $C0B4+(VX<<8) // LDY ESTKH,X
//^codeptr = $B4; codeptr++ // LDY zp,X
//^codeptr = $C0+VX; codeptr++ // ESTKH
codeptr = codeptr + 2
codeptr, VX = resolveX(codeptr, VX + 1) // INX
repeat
//puts(" $"); puth(*(bytecode+case))
^codeptr = $C9; codeptr++ // CMP #imm
^codeptr = ^(bytecode+case); codeptr++
^codeptr = $D0; codeptr++ // BNE rel
^codeptr = $09; codeptr++ // +9
^codeptr = $C0; codeptr++ // CPY #imm
^codeptr = ^(bytecode+case+1); codeptr++
^codeptr = $D0; codeptr++ // BNE rel
^codeptr = $05; codeptr++ // +5
codeptr=>0 = $C9+(^(bytecode+case)<<8) // CMP #imm
//^codeptr = $C9; codeptr++ // CMP #imm
//^codeptr = ^(bytecode+case); codeptr++
codeptr=>2 = $09D0 // BNE +9
//^codeptr = $D0; codeptr++ // BNE rel
//^codeptr = $09; codeptr++ // +9
codeptr=>4 = $C0+(^(bytecode+case+1)<<8) // CPY #imm
//^codeptr = $C0; codeptr++ // CPY #imm
//^codeptr = ^(bytecode+case+1); codeptr++
codeptr=>6 = $05D0 // BNE +5
//^codeptr = $D0; codeptr++ // BNE rel
//^codeptr = $05; codeptr++ // +5
*(bytecode+case) = $FEFE
case = case + 2
dest = case + *(bytecode+case)
//puts("-->"); puti(dest); putln
^codeptr = $A0; codeptr++ // LDY #imm
^codeptr = $00; codeptr++ // $00
^codeptr = $4C; codeptr++ // JMP abs
*codeptr = addrxlate=>[dest]
if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[dest] = codeptr - *jitcodeptr
codeptr=>8 = $00A0 // LDY #$00
//^codeptr = $A0; codeptr++ // LDY #imm
//^codeptr = $00; codeptr++ // $00
codeptr->10 = $4C // JMP abs
//^codeptr = $4C; codeptr++ // JMP abs
codeptr=>11 = addrxlate=>[dest]
//*codeptr = addrxlate=>[dest]
if not (codeptr->12 & $80) // Unresolved address list
//if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[dest] = codeptr + 11 - *jitcodeptr
//addrxlate=>[dest] = codeptr - *jitcodeptr
fin
codeptr = codeptr + 2
codeptr = codeptr + 13
//codeptr = codeptr + 2
*(bytecode+case) = $FEFE
case = case + 2
j--
until not j
^codeptr = $A0; codeptr++ // LDY #imm
^codeptr = $00; codeptr++ // $00
^codeptr = $4C; codeptr++ // JMP abs
*codeptr = addrxlate=>[case]
if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[case] = codeptr - *jitcodeptr
codeptr=>0 = $00A0 // LDY #$00
//^codeptr = $A0; codeptr++ // LDY #imm
//^codeptr = $00; codeptr++ // $00
codeptr->1 = $4C // JMP abs
//^codeptr = $4C; codeptr++ // JMP abs
codeptr=>2 = addrxlate=>[case]
//*codeptr = addrxlate=>[case]
if not (codeptr->3 & $80) // Unresolved address list
//if not (*codeptr & $8000) // Unresolved address list
addrxlate=>[case] = codeptr + 2- *jitcodeptr
//addrxlate=>[case] = codeptr - *jitcodeptr
fin
codeptr = codeptr + 2
codeptr = codeptr + 4
//codeptr = codeptr + 2
else
codeptr = dest
fin
@ -1015,10 +1037,14 @@ def compiler(defptr)#0
codeptr = codeptr + 2
fin
codeptr, VX = resolveX(codeptr, VX)
^codeptr = $20; codeptr++ // JSR abs
*codeptr = *(bytecode+i); codeptr = codeptr + 2
^codeptr = $A0; codeptr++ // LDY #imm
^codeptr = $00; codeptr++ // $00
codeptr->0 = $20 // JSR abs
//^codeptr = $20; codeptr++ // JSR abs
codeptr=>1 = *(bytecode+i)
//*codeptr = *(bytecode+i); codeptr = codeptr + 2
codeptr=>3 = $00A0 // LDY #$00
//^codeptr = $A0; codeptr++ // LDY #imm
//^codeptr = $00; codeptr++ // $00
codeptr = codeptr + 5
A_IS_TOSL = FALSE
i++
break
@ -1028,25 +1054,33 @@ def compiler(defptr)#0
// Pull address off stack
//
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $85; codeptr++ // STA zp
^codeptr = $E7; codeptr++ // $E7:TMPL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $C0+VX; codeptr++ // ESTKH
^codeptr = $85; codeptr++ // STA zp
^codeptr = $E8; codeptr++ // $E8:TMPH
//VX++ //^codeptr = $E8; codeptr++ // INX
codeptr, VX = resolveX(codeptr, VX + 1)
codeptr=>0 = $E785 // STA $E7:TMPL
//^codeptr = $85; codeptr++ // STA zp
//^codeptr = $E7; codeptr++ // $E7:TMPL
codeptr=>2 = $C0B5+(VX<<8) // LDA ESTKH,X
//^codeptr = $B5; codeptr++ // LDA zp,X
//^codeptr = $C0+VX; codeptr++ // ESTKH
codeptr=>4 = $E885 // STA $E8:TMPH
//^codeptr = $85; codeptr++ // STA zp
//^codeptr = $E8; codeptr++ // $E8:TMPH
//^codeptr = $E8; codeptr++ // INX
codeptr = codeptr + 6
//
// Call through TMP
//
^codeptr = $20; codeptr++ // JSR abs
^codeptr = $E6; codeptr++ // <JMPTMP
^codeptr = $00; codeptr++ // >JMPTMP
^codeptr = $A0; codeptr++ // LDY #imm
^codeptr = $00; codeptr++ // $00
codeptr, VX = resolveX(codeptr, VX + 1) // INX
codeptr->0 = $20 // JSR abs
//^codeptr = $20; codeptr++ // JSR abs
codeptr=>1 = $00E6 // JMPTMP
//^codeptr = $E6; codeptr++ // <JMPTMP
//^codeptr = $00; codeptr++ // >JMPTMP
codeptr=>3 = $00A0 // LDY #$00
//^codeptr = $A0; codeptr++ // LDY #imm
//^codeptr = $00; codeptr++ // $00
codeptr = codeptr + 5
A_IS_TOSL = FALSE
break
is $5A
@ -1060,10 +1094,14 @@ def compiler(defptr)#0
codeptr = codeptr + 2
fin
codeptr, VX = resolveX(codeptr, VX)
^codeptr = $20; codeptr++ // JSR INTERP
*codeptr = $3D0; codeptr = codeptr + 2
^codeptr = $5A; codeptr++ // LEAVE CODE
^codeptr = ^(bytecode+i); codeptr++ // LEAVE OPERAND
codeptr->0 = $20 // JSR abs
//^codeptr = $20; codeptr++ // JSR INTERP
codeptr=>1 = $03D0 // INTERP
//*codeptr = $3D0; codeptr = codeptr + 2
codeptr=>3 = $5A + (^(bytecode+i)<<8) // LEAVE CODE AND OPERAND
//^codeptr = $5A; codeptr++ // LEAVE CODE
//^codeptr = ^(bytecode+i); codeptr++ // LEAVE OPERAND
codeptr = codeptr + 5
A_IS_TOSL = FALSE
break
is $5C
@ -1073,7 +1111,8 @@ def compiler(defptr)#0
codeptr = codeptr + 2
fin
codeptr, VX = resolveX(codeptr, VX)
^codeptr = $60; codeptr++ // RTS
^codeptr = $60 //RTS
codeptr++
A_IS_TOSL = FALSE
break
is $5E
@ -1083,23 +1122,27 @@ def compiler(defptr)#0
*codeptr = $D095+(VX<<8) // STA ESTKL,X
codeptr = codeptr + 2
fin
VX-- //^codeptr = $CA; codeptr++ // DEX
^codeptr = $A9; codeptr++ // LDA #imm
^codeptr = $FF; codeptr++ // $FF
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $C0+VX; codeptr++ // ESTKH
^codeptr = $A9; codeptr++ // LDA #imm
^codeptr = ^(bytecode+i); codeptr++
VX-- // DEX
codeptr=>0 = $FFA9 // LDA #$FF
//^codeptr = $A9; codeptr++ // LDA #imm
//^codeptr = $FF; codeptr++ // $FF
codeptr=>2 = $C095+(VX<<8) // STA ESTKH,X
//^codeptr = $95; codeptr++ // STA zp,X
//^codeptr = $C0+VX; codeptr++ // ESTKH
codeptr=>4 = $A9 + (^(bytecode+i)<<8) // LDA #imm
//^codeptr = $A9; codeptr++ // LDA #imm
//^codeptr = ^(bytecode+i); codeptr++
//^codeptr = $95; codeptr++ // STA zp,X
//^codeptr = $D0+VX; codeptr++ // ESTKL
codeptr = codeptr + 6
A_IS_TOSL = TOSL_DIRTY
break
// LB,LW,LLB,LLW,LAB,LAW,DLB,DLW ; 60 62 64 66 68 6A 6C 6E
is $60
//puts("LB")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $C0-1+VX; codeptr++ // ESTKH-1
@ -1114,8 +1157,8 @@ def compiler(defptr)#0
is $62
//puts("LW")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $C0-1+VX; codeptr++ // ESTKH-1
@ -1228,8 +1271,8 @@ def compiler(defptr)#0
i++
//puts("DLB "); puti(^(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
A_IS_TOSL = TOSL_CLEAN
fin
if ^(bytecode+i) <> 0
@ -1275,8 +1318,8 @@ def compiler(defptr)#0
is $70
//puts("SB")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $C0-1+VX; codeptr++ // ESTKH-1
@ -1292,8 +1335,8 @@ def compiler(defptr)#0
is $72
//puts("SW")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $C0-1+VX; codeptr++ // ESTKH-1
@ -1320,8 +1363,8 @@ def compiler(defptr)#0
i++
//puts("SLB "); puti(^(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
if ^(bytecode+i) <> 0
^codeptr = $A0; codeptr++ // LDY #imm
@ -1340,8 +1383,8 @@ def compiler(defptr)#0
i++
//puts("SLW "); puti(^(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
if ^(bytecode+i) <> 0
^codeptr = $A0; codeptr++ // LDY #imm
@ -1367,8 +1410,8 @@ def compiler(defptr)#0
i++
//puts("SAB $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $8D; codeptr++ // STA abs
*codeptr = *(bytecode+i); codeptr = codeptr + 2
@ -1380,8 +1423,8 @@ def compiler(defptr)#0
i++
//puts("SAW $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $8D; codeptr++ // STA abs
*codeptr = *(bytecode+i); codeptr = codeptr + 2
@ -1397,8 +1440,8 @@ def compiler(defptr)#0
i++
//puts("DAB $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
A_IS_TOSL = TOSL_CLEAN
fin
^codeptr = $8D; codeptr++ // STA abs
@ -1409,8 +1452,8 @@ def compiler(defptr)#0
i++
//puts("DAW $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
A_IS_TOSL = TOSL_CLEAN
fin
^codeptr = $8D; codeptr++ // STA abs
@ -1427,8 +1470,8 @@ def compiler(defptr)#0
is $80
//puts("NOT")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $15; codeptr++ // ORA zp,X
^codeptr = $C0+VX; codeptr++ // ESTKH
@ -1447,8 +1490,8 @@ def compiler(defptr)#0
is $82
//puts("ADD")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $75; codeptr++ // ADC zp,X
@ -1523,8 +1566,8 @@ def compiler(defptr)#0
is $8C
//puts("INCR")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $69; codeptr++ // ADC #imm
@ -1540,8 +1583,8 @@ def compiler(defptr)#0
is $8E
//puts("DECR")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $38; codeptr++ // SEC
^codeptr = $E9; codeptr++ // SBC #imm
@ -1577,8 +1620,8 @@ def compiler(defptr)#0
is $92
//puts("COMP")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $49; codeptr++ // EOR #imm
^codeptr = $FF; codeptr++ // $FF
@ -1595,8 +1638,8 @@ def compiler(defptr)#0
is $94
//puts("AND")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $35; codeptr++ // AND zp,X
^codeptr = $D0+1+VX; codeptr++ // ESTKL+1
@ -1614,8 +1657,8 @@ def compiler(defptr)#0
is $96
//puts("OR")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $15; codeptr++ // ORA zp,X
^codeptr = $D0+1+VX; codeptr++ // ESTKL+1
@ -1633,8 +1676,8 @@ def compiler(defptr)#0
is $98
//puts("XOR")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $55; codeptr++ // EOR zp,X
^codeptr = $D0+1+VX; codeptr++ // ESTKL+1
@ -1652,8 +1695,8 @@ def compiler(defptr)#0
is $9E
//puts("IDXW")
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $0A; codeptr++ // ASL
^codeptr = $36; codeptr++ // ROL zp,X
@ -1714,8 +1757,8 @@ def compiler(defptr)#0
i++
codeptr, VX = resolveX(codeptr, VX)
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
else
^codeptr = $95; codeptr++ // STA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
@ -1751,8 +1794,8 @@ def compiler(defptr)#0
// INCR
//
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $69; codeptr++ // ADC #imm
@ -1800,8 +1843,8 @@ def compiler(defptr)#0
// ADD
//
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $75; codeptr++ // ADC zp,X
@ -1852,8 +1895,8 @@ def compiler(defptr)#0
// DECR
//
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $38; codeptr++ // SEC
^codeptr = $E9; codeptr++ // SBC #imm
@ -2003,8 +2046,8 @@ def compiler(defptr)#0
i++
//puts("ADDLB "); puti(^(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
if ^(bytecode+i) <> 0
^codeptr = $A0; codeptr++ // LDY #imm
@ -2029,8 +2072,8 @@ def compiler(defptr)#0
i++
//puts("ADDLW "); puti(^(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
if ^(bytecode+i) <> 0
^codeptr = $A0; codeptr++ // LDY #imm
@ -2060,8 +2103,8 @@ def compiler(defptr)#0
i++
//puts("ADDAB $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $6D; codeptr++ // ADC abs
@ -2079,8 +2122,8 @@ def compiler(defptr)#0
i++
//puts("ADDAW $"); puth(*(bytecode+i))
if not A_IS_TOSL
^codeptr = $B5; codeptr++ // LDA zp,X
^codeptr = $D0+VX; codeptr++ // ESTKL
*codeptr = $D0B5+(VX<<8) // LDA ESTKL,X
codeptr = codeptr + 2
fin
^codeptr = $18; codeptr++ // CLC
^codeptr = $6D; codeptr++ // ADC abs