From 37ad98913f324b8873352832ae00eb9922f4842f Mon Sep 17 00:00:00 2001 From: jespergravgaard Date: Sat, 24 Apr 2021 08:05:16 +0200 Subject: [PATCH] working on type qualifiers --- .idea/vcs.xml | 1 + .../cache/fragment-cache-csg65ce02.asm | 2174 +- .../cache/fragment-cache-mega45gs02.asm | 528 +- .../cache/fragment-cache-mos6502x.asm | 21116 +++++++--------- .../cache/fragment-cache-rom6502x.asm | 1174 +- .../cache/fragment-cache-wdc65c02.asm | 4267 +--- .../kickc/model/VariableBuilder.java | 13 +- .../kickc/model/symbols/Variable.java | 28 +- .../kickc/model/types/SymbolType.java | 8 + .../model/types/SymbolTypeBlockScope.java | 10 +- .../kickc/model/types/SymbolTypeEnum.java | 23 +- .../model/types/SymbolTypeIntegerAuto.java | 5 + .../model/types/SymbolTypeIntegerFixed.java | 32 +- .../kickc/model/types/SymbolTypeNamed.java | 25 +- .../kickc/model/types/SymbolTypePointer.java | 19 +- .../model/types/SymbolTypeProcedure.java | 5 + .../kickc/model/types/SymbolTypeProgram.java | 4 + .../kickc/model/types/SymbolTypeStruct.java | 38 +- .../model/types/SymbolTypeTypeDefScope.java | 4 + .../Pass0GenerateStatementSequence.java | 20 +- .../kickc/passes/Pass1AddressOfHandling.java | 7 + .../kickc/passes/Pass1AsmUsesHandling.java | 5 + .../dk/camelot64/kickc/test/TestPrograms.java | 23 + src/test/kc/complex/includes/includes-3.c | 2 +- .../kc/examples/mega65/camelot-1536dots.c | 7 +- 25 files changed, 9235 insertions(+), 20303 deletions(-) diff --git a/.idea/vcs.xml b/.idea/vcs.xml index 94a25f7f4..b8ed274ea 100644 --- a/.idea/vcs.xml +++ b/.idea/vcs.xml @@ -2,5 +2,6 @@ + \ No newline at end of file diff --git a/src/main/fragment/cache/fragment-cache-csg65ce02.asm b/src/main/fragment/cache/fragment-cache-csg65ce02.asm index c07a503ee..3b350f972 100644 --- a/src/main/fragment/cache/fragment-cache-csg65ce02.asm +++ b/src/main/fragment/cache/fragment-cache-csg65ce02.asm @@ -1,2185 +1,15 @@ //KICKC FRAGMENT CACHE 108dd16dc1 108dd18d7f -//FRAGMENT vbuz1=vbuc1 -lda #{c1} -sta {z1} -//FRAGMENT pbuz1=pbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuc1 -lda {c1} -sta {z1} -//FRAGMENT vbuz1_lt_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcc {la1} -//FRAGMENT vbuz1=vbuz2 -lda {z2} -sta {z1} -//FRAGMENT vduz1=vduz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=_word_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_2 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_3 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=_inc_vbuz1 -inc {z1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuc1 -lda #{c1} -ldz {z2} -sta ({z1}),z -//FRAGMENT vbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -sta {z1} -//FRAGMENT pbuz1=_inc_pbuz1 -inw {z1} -//FRAGMENT 0_neq_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT _deref_pbuc1=vbuc2 -lda #{c2} -sta {c1} -//FRAGMENT vduz1=vduc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -lda #<{c1}>>$10 -sta {z1}+2 -lda #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT pbuc1_derefidx_vbuz1=_inc_pbuc1_derefidx_vbuz1 -ldx {z1} -inc {c1},x -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuc2_then_la1 -ldy {z1} -lda {c1},y -cmp #{c2} -beq {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT 0_eq_vbuz1_then_la1 -lda {z1} -beq {la1} -//FRAGMENT vbuz1_eq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -beq {la1} -//FRAGMENT vduz1=_inc_vduz1 -inc {z1} -bne !+ -inc {z1}+1 -bne !+ -inc {z1}+2 -bne !+ -inc {z1}+3 -!: -//FRAGMENT pbuc1_derefidx_vbuz1=vbuc2 -lda #{c2} -ldy {z1} -sta {c1},y -//FRAGMENT vbuz1=_dec_vbuz1 -dec {z1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuz3 -lda {z3} -ldz {z2} -sta ({z1}),z -//FRAGMENT vbuz1_neq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bne {la1} -//FRAGMENT vwuz1=vwuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=_byte_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=_inc_pbuz2 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -//FRAGMENT vbuz1=vbuz2_rol_1 -lda {z2} -asl -sta {z1} -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1_ge_vwuz2_then_la1 -lda {z2}+1 -cmp {z1}+1 -bne !+ -lda {z2} -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT vwuz1=vwuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbsz1=_sbyte_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT vbsz1=_inc_vbsz1 -inc {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsz3 -lda {z2} -sec -sbc {z3} -sta {z1} -//FRAGMENT vbsz1_ge_0_then_la1 -lda {z1} -cmp #0 -bpl {la1} -//FRAGMENT vbsz1=vbsc1 -lda #{c1} -sta {z1} -//FRAGMENT 0_neq_vbsz1_then_la1 -lda {z1} -cmp #0 -bne {la1} -//FRAGMENT vbuz1=vbuz2_minus_1 -ldx {z2} -dex -stx {z1} -//FRAGMENT vbuz1_le_vbuz2_then_la1 -lda {z2} -cmp {z1} -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuz2_then_la1 -ldy {z1} -lda {c1},y -cmp {z2} -beq {la1} -//FRAGMENT vbuz1_lt_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcc {la1} -//FRAGMENT vbuz1=vbuz2_minus_vbuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -//FRAGMENT vbuz1_neq_vbuz2_then_la1 -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT vbuz1=_byte_vduz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_rol_2 -lda {z2} -asl -asl -sta {z1} -//FRAGMENT vduz1=pduc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1_ge_vduz2_then_la1 -lda {z1}+3 -cmp {z2}+3 -bcc !+ -bne {la1} -lda {z1}+2 -cmp {z2}+2 -bcc !+ -bne {la1} -lda {z1}+1 -cmp {z2}+1 -bcc !+ -bne {la1} -lda {z1} -cmp {z2} -bcs {la1} -!: -//FRAGMENT vwuz1=vwuz1_minus_vwuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT 0_neq__deref_pbuz1_then_la1 -ldy #0 -lda ({z1}),y -cmp #0 -bne {la1} -//FRAGMENT vwuz1=_inc_vwuz1 -inw {z1} -//FRAGMENT _deref_pbuz1=vbuz2 -lda {z2} -ldy #0 -sta ({z1}),y -//FRAGMENT vduz1=vduz1_minus_vduz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -lda {z1}+2 -sbc {z2}+2 -sta {z1}+2 -lda {z1}+3 -sbc {z2}+3 -sta {z1}+3 -//FRAGMENT pvoz1=pvoc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_minus_vbuc1 -sec -lda {z1} -sbc #{c1} -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT vbuz1_le_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bcs {la1} -//FRAGMENT vbuz1=vbuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -//FRAGMENT vbuz1_ge_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcs {la1} -//FRAGMENT pbuz1=pbuz2_plus_vwuc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1_neq_pbuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT _deref_pbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=pbuz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1 -lda {c1} -//FRAGMENT vbuxx=_deref_pbuc1 -ldx {c1} -//FRAGMENT vbuaa_lt_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -//FRAGMENT vbuaa=vbuz1 -lda {z1} -//FRAGMENT vbuxx=vbuz1 -ldx {z1} -//FRAGMENT vbuz1=vbuxx -stx {z1} -//FRAGMENT vwuz1=_word_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuzz -tza -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuaa=vbuc1 -taz -lda #{c1} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuxx=vbuc1 -txa -taz -lda #{c1} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuyy=vbuc1 -lda #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuzz=vbuc1 -lda #{c1} -sta ({z1}),z -//FRAGMENT vbuaa=_deref_pbuz1 -ldy #0 -lda ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tay -//FRAGMENT vbuzz=_deref_pbuz1 -ldy #0 -lda ({z1}),y -taz -//FRAGMENT 0_neq_vbuaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuz1=vbuaa -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuxx=_inc_pbuc1_derefidx_vbuxx -inc {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuc2_then_la1 -lda {c1},x -cmp #{c2} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuc2_then_la1 -tza -tay -lda {c1},y -cmp #{c2} -beq {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1 -ldy {z1} -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1 -ldx {z1} -ldy {c1},x -//FRAGMENT vbuzz=pbuc1_derefidx_vbuz1 -ldx {z1} -ldz {c1},x -//FRAGMENT 0_eq_vbuaa_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vbuxx_eq_vbuc1_then_la1 -cpx #{c1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx=vbuc2 -lda #{c2} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuzz=vbuc2 -tza -tay -lda #{c2} -sta {c1},y -//FRAGMENT vbuaa_eq_vbuc1_then_la1 -cmp #{c1} -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuaa -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuxx -txa -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuyy -tya -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuzz -tza -ldz {z2} -sta ({z1}),z -//FRAGMENT vbuaa=_byte_vwuz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vwuz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vwuz1 -lda {z1} -tay -//FRAGMENT vbuzz=_byte_vwuz1 -lda {z1} -taz -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuzz -tza -tay -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa=vbuz1_rol_1 -lda {z1} -asl -//FRAGMENT vbuxx=vbuz1_rol_1 -lda {z1} -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_1 -lda {z1} -asl -tay -//FRAGMENT vbuzz=vbuz1_rol_1 -lda {z1} -asl -taz -//FRAGMENT vbuz1=vbuaa_rol_1 -asl -sta {z1} -//FRAGMENT vbuaa=vbuaa_rol_1 -asl -//FRAGMENT vbuxx=vbuaa_rol_1 -asl -tax -//FRAGMENT vbuyy=vbuaa_rol_1 -asl -tay -//FRAGMENT vbuzz=vbuaa_rol_1 -asl -taz -//FRAGMENT vbuz1=vbuxx_rol_1 -txa -asl -sta {z1} -//FRAGMENT vbuaa=vbuxx_rol_1 -txa -asl -//FRAGMENT vbuxx=vbuxx_rol_1 -txa -asl -tax -//FRAGMENT vbuyy=vbuxx_rol_1 -txa -asl -tay -//FRAGMENT vbuzz=vbuxx_rol_1 -txa -asl -taz -//FRAGMENT vbuz1=vbuyy_rol_1 -tya -asl -sta {z1} -//FRAGMENT vbuaa=vbuyy_rol_1 -tya -asl -//FRAGMENT vbuxx=vbuyy_rol_1 -tya -asl -tax -//FRAGMENT vbuyy=vbuyy_rol_1 -tya -asl -tay -//FRAGMENT vbuzz=vbuyy_rol_1 -tya -asl -taz -//FRAGMENT vbuz1=vbuzz_rol_1 -tza -asl -sta {z1} -//FRAGMENT vbuaa=vbuzz_rol_1 -tza -asl -//FRAGMENT vbuxx=vbuzz_rol_1 -tza -asl -tax -//FRAGMENT vbuyy=vbuzz_rol_1 -tza -asl -tay -//FRAGMENT vbuzz=vbuzz_rol_1 -tza -asl -taz -//FRAGMENT vwuz1=pwuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuzz -tza -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT 0_neq_vbuxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbsaa=_sbyte_vwuz1 -lda {z1} -//FRAGMENT vbsxx=_sbyte_vwuz1 -ldx {z1} -//FRAGMENT 0_eq_vbuxx_then_la1 -cpx #0 -beq {la1} -//FRAGMENT vbsz1=vbsz2_minus_vbsaa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsxx -txa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsyy -tya -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbszz -tza -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsxx=vbsz1_minus_vbsz2 -lda {z1} -sec -sbc {z2} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsaa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsxx -txa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsyy -tya -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbszz -tza -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsz1=vbsxx_minus_vbsz2 -txa -sec -sbc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsaa -sta $ff -txa -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsxx -lda #0 -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsyy -txa -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbszz -txa -stz $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsxx=vbsxx_minus_vbsz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsxx -lda #0 -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsxx_minus_vbszz -txa -stz $ff -sec -sbc $ff -tax -//FRAGMENT vbsz1=vbsyy_minus_vbsz2 -tya -sec -sbc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsaa -sta $ff -tya -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsxx -tya -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsyy -lda #0 -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbszz -tya -stz $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsxx=vbsyy_minus_vbsz1 -tya -sec -sbc {z1} -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsaa -sta $ff -tya -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsxx -tya -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsyy -lda #0 -tax -//FRAGMENT vbsxx=vbsyy_minus_vbszz -tya -stz $ff -sec -sbc $ff -tax -//FRAGMENT vbsz1=vbszz_minus_vbsz2 -tza -sec -sbc {z2} -sta {z1} -//FRAGMENT vbsz1=vbszz_minus_vbsaa -tay -tza -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbszz_minus_vbsxx -tza -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbszz_minus_vbsyy -tza -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbszz_minus_vbszz -tza -lda #0 -sta {z1} -//FRAGMENT vbsxx=vbszz_minus_vbsz1 -tza -sec -sbc {z1} -tax -//FRAGMENT vbsxx=vbszz_minus_vbsaa -tax -tza -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbszz_minus_vbsxx -tza -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbszz_minus_vbsyy -tza -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbszz_minus_vbszz -tza -lda #0 -tax -//FRAGMENT vbsxx_ge_0_then_la1 -cpx #0 -bpl {la1} -//FRAGMENT 0_neq_vbsxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuz1=vbuaa_minus_1 -sec -sbc #1 -sta {z1} -//FRAGMENT vbuaa_le_vbuz1_then_la1 -ldy {z1} -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuz1_then_la1 -tay -lda {c1},y -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuz1_then_la1 -lda {c1},x -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuz1_then_la1 -lda {c1},y -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuz1_then_la1 -tza -tay -lda {c1},y -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuaa_then_la1 -ldx {z1} -tay -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuaa_then_la1 -tax -lda {c1},x -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuaa_then_la1 -tay -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuaa_then_la1 -tax -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuaa_then_la1 -tax -tza -tay -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuxx_then_la1 -ldy {z1} -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuxx_then_la1 -tay -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuxx_then_la1 -lda {c1},x -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuxx_then_la1 -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuxx_then_la1 -tza -tay -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuyy_then_la1 -ldx {z1} -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuyy_then_la1 -tax -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuyy_then_la1 -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuyy_then_la1 -lda {c1},y -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuyy_then_la1 -tza -tax -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuzz_then_la1 -ldy {z1} -lda {c1},y -tay -sty $ff -cpz $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuzz_then_la1 -tay -lda {c1},y -tay -sty $ff -cpz $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuzz_then_la1 -lda {c1},x -tay -sty $ff -cpz $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuzz_then_la1 -lda {c1},y -tay -sty $ff -cpz $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuzz_eq_vbuzz_then_la1 -tza -tay -lda {c1},y -tay -sty $ff -cpz $ff -beq {la1} -//FRAGMENT vbuaa_lt_vbuz1_then_la1 -cmp {z1} -bcc {la1} -//FRAGMENT vbuz1=vbuaa_minus_vbuz2 -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuz2 -txa -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuz2 -tya -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuzz_minus_vbuz2 -tza -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -//FRAGMENT vbuaa=vbuaa_minus_vbuz1 -sec -sbc {z1} -//FRAGMENT vbuaa=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -//FRAGMENT vbuaa=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -//FRAGMENT vbuaa=vbuzz_minus_vbuz1 -tza -sec -sbc {z1} -//FRAGMENT vbuxx=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuz1 -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuzz_minus_vbuz1 -tza -sec -sbc {z1} -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuz1 -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuzz_minus_vbuz1 -tza -sec -sbc {z1} -tay -//FRAGMENT vbuzz=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -taz -//FRAGMENT vbuzz=vbuaa_minus_vbuz1 -sec -sbc {z1} -taz -//FRAGMENT vbuzz=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -taz -//FRAGMENT vbuzz=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -taz -//FRAGMENT vbuzz=vbuzz_minus_vbuz1 -tza -sec -sbc {z1} -taz -//FRAGMENT vbuz1=vbuz2_minus_vbuxx -txa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuxx -lda #0 -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuzz_minus_vbuxx -tza -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuxx_minus_vbuxx -lda #0 -//FRAGMENT vbuaa=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuzz_minus_vbuxx -tza -stx $ff -sec -sbc $ff -//FRAGMENT vbuxx=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuxx -lda #0 -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuzz_minus_vbuxx -tza -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuxx -lda #0 -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuzz_minus_vbuxx -tza -stx $ff -sec -sbc $ff -tay -//FRAGMENT vbuzz=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -taz -//FRAGMENT vbuzz=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuxx_minus_vbuxx -lda #0 -taz -//FRAGMENT vbuzz=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuzz_minus_vbuxx -tza -stx $ff -sec -sbc $ff -taz -//FRAGMENT vbuz1=vbuz2_minus_vbuyy -tya -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuyy -lda #0 -sta {z1} -//FRAGMENT vbuz1=vbuzz_minus_vbuyy -tza -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuyy_minus_vbuyy -lda #0 -//FRAGMENT vbuaa=vbuzz_minus_vbuyy -tza -sty $ff -sec -sbc $ff -//FRAGMENT vbuxx=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuyy -lda #0 -tax -//FRAGMENT vbuxx=vbuzz_minus_vbuyy -tza -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuyy -lda #0 -tay -//FRAGMENT vbuyy=vbuzz_minus_vbuyy -tza -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuzz=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -taz -//FRAGMENT vbuzz=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuyy_minus_vbuyy -lda #0 -taz -//FRAGMENT vbuzz=vbuzz_minus_vbuyy -tza -sty $ff -sec -sbc $ff -taz -//FRAGMENT vbuz1=vbuz2_minus_vbuzz -tza -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuzz -stz $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuzz -txa -stz $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuzz -tya -stz $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuzz_minus_vbuzz -tza -lda #0 -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuzz -tza -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuzz -stz $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuxx_minus_vbuzz -txa -stz $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuyy_minus_vbuzz -tya -stz $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuzz_minus_vbuzz -tza -lda #0 -//FRAGMENT vbuxx=vbuz1_minus_vbuzz -tza -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuzz -stz $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuzz -txa -stz $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuzz -tya -stz $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuzz_minus_vbuzz -tza -lda #0 -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuzz -tza -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuzz -stz $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuzz -txa -stz $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuzz -tya -stz $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuzz_minus_vbuzz -tza -lda #0 -tay -//FRAGMENT vbuzz=vbuz1_minus_vbuzz -tza -eor #$ff -sec -adc {z1} -taz -//FRAGMENT vbuzz=vbuaa_minus_vbuzz -stz $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuxx_minus_vbuzz -txa -stz $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuyy_minus_vbuzz -tya -stz $ff -sec -sbc $ff -taz -//FRAGMENT vbuzz=vbuzz_minus_vbuzz -tza -lda #0 -taz -//FRAGMENT vbuxx_lt_vbuz1_then_la1 -cpx {z1} -bcc {la1} -//FRAGMENT vbuz1_neq_vbuaa_then_la1 -cmp {z1} -bne {la1} -//FRAGMENT vbuz1=vbuz2_minus_vbuaa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuxx=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuzz=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -taz -//FRAGMENT vbuz1=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbuyy=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tay -//FRAGMENT vbuzz=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -taz -//FRAGMENT vbuz1=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -sta {z1} -//FRAGMENT vbuxx=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -tax -//FRAGMENT vbuyy=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -tay -//FRAGMENT vbuzz=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -taz -//FRAGMENT vbuz1=vbuzz_minus_vbuaa -tay -tza -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuxx=vbuzz_minus_vbuaa -tax -tza -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuyy=vbuzz_minus_vbuaa -tay -tza -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuzz=vbuzz_minus_vbuaa -tay -tza -sty $ff -sec -sbc $ff -taz -//FRAGMENT vbuxx_lt_vbuc1_then_la1 -cpx #{c1} -bcc {la1} -//FRAGMENT vbuaa=_byte_vduz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vduz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vduz1 -lda {z1} -tay -//FRAGMENT vbuzz=_byte_vduz1 -lda {z1} -taz -//FRAGMENT vbuz1=vbuaa_rol_2 -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuxx_rol_2 -txa -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuyy_rol_2 -tya -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuzz_rol_2 -tza -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuz1_rol_2 -lda {z1} -asl -asl -//FRAGMENT vbuaa=vbuaa_rol_2 -asl -asl -//FRAGMENT vbuaa=vbuxx_rol_2 -txa -asl -asl -//FRAGMENT vbuaa=vbuyy_rol_2 -tya -asl -asl -//FRAGMENT vbuaa=vbuzz_rol_2 -tza -asl -asl -//FRAGMENT vbuxx=vbuz1_rol_2 -lda {z1} -asl -asl -tax -//FRAGMENT vbuxx=vbuaa_rol_2 -asl -asl -tax -//FRAGMENT vbuxx=vbuxx_rol_2 -txa -asl -asl -tax -//FRAGMENT vbuxx=vbuyy_rol_2 -tya -asl -asl -tax -//FRAGMENT vbuxx=vbuzz_rol_2 -tza -asl -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_2 -lda {z1} -asl -asl -tay -//FRAGMENT vbuyy=vbuaa_rol_2 -asl -asl -tay -//FRAGMENT vbuyy=vbuxx_rol_2 -txa -asl -asl -tay -//FRAGMENT vbuyy=vbuyy_rol_2 -tya -asl -asl -tay -//FRAGMENT vbuyy=vbuzz_rol_2 -tza -asl -asl -tay -//FRAGMENT vbuzz=vbuz1_rol_2 -lda {z1} -asl -asl -taz -//FRAGMENT vbuzz=vbuaa_rol_2 -asl -asl -taz -//FRAGMENT vbuzz=vbuxx_rol_2 -txa -asl -asl -taz -//FRAGMENT vbuzz=vbuyy_rol_2 -tya -asl -asl -taz -//FRAGMENT vbuzz=vbuzz_rol_2 -tza -asl -asl -taz -//FRAGMENT vduz1=pduc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -lda {c1}+2,x -sta {z1}+2 -lda {c1}+3,x -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuzz -tza -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT _deref_pbuz1=vbuaa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuxx -txa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuyy -tya -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuzz -tza -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa_le_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuaa=vbuaa_plus_vbuc1 -clc -adc #{c1} -//FRAGMENT vbuxx=vbuxx_plus_vbuc1 -txa -clc -adc #{c1} -tax -//FRAGMENT vbuyy=vbuyy_plus_vbuc1 -tya -clc -adc #{c1} -tay -//FRAGMENT vbuzz=vbuzz_plus_vbuc1 -tza -clc -adc #{c1} -taz -//FRAGMENT vbuaa_ge_vbuz1_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuz1=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuzz -tza -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_1 -dex -stx {z1} -//FRAGMENT vbuz1=vbuyy_minus_1 -tya -sec -sbc #1 -sta {z1} -//FRAGMENT vbuxx_le_vbuz1_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuyy_le_vbuz1_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuzz_le_vbuz1_then_la1 -ldy {z1} -tza -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT vbuz1_le_vbuaa_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuxx_ge_vbuz1_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vbuxx=vbuc1 -ldx #{c1} //FRAGMENT vbuzz=vbuc1 ldz #{c1} -//FRAGMENT vbuzz=vbuz1 -ldz {z1} -//FRAGMENT vbuz1=vbuzz -tza -sta {z1} -//FRAGMENT vbuzz_ge_vbuz1_then_la1 -cpz {z1} -bcs {la1} -//FRAGMENT vbuxx=_inc_vbuxx -inx -//FRAGMENT vbuyy=vbuc1 -ldy #{c1} -//FRAGMENT vbuyy=_inc_vbuyy -iny -//FRAGMENT vbuzz=_inc_vbuzz -inz -//FRAGMENT vbuz1_ge_vbuxx_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuzz_ge_vbuxx_then_la1 -stx $ff -cpz $ff -bcs {la1} -//FRAGMENT vbuyy=vbuz1 -ldy {z1} -//FRAGMENT vbuz1_ge_vbuyy_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuyy_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuzz_ge_vbuyy_then_la1 -sty $ff -cpz $ff -bcs {la1} -//FRAGMENT vbuz1_ge_vbuzz_then_la1 -ldy {z1} -tza -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuzz_then_la1 -tza -tay -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuaa=vbuxx -txa -//FRAGMENT vbuaa=vbuzz -tza -//FRAGMENT vbuxx=vbuzz -tza -tax -//FRAGMENT vbuxx_le_vbuc1_then_la1 -cpx #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuz1=vbuyy -sty {z1} -//FRAGMENT vbuyy_lt_vbuc1_then_la1 -cpy #{c1} -bcc {la1} -//FRAGMENT vbuyy_le_vbuc1_then_la1 -cpy #{c1} -bcc {la1} -beq {la1} //FRAGMENT vbuzz_lt_vbuc1_then_la1 cpz #{c1} bcc {la1} -//FRAGMENT vbuzz_le_vbuc1_then_la1 -cpz #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuaa=vbuyy -tya -//FRAGMENT vbuxx=vbuaa -tax -//FRAGMENT vbuxx=vbuyy -tya -tax -//FRAGMENT vbuyy=vbuaa -tay -//FRAGMENT vbuyy=vbuxx -txa -tay -//FRAGMENT vbuyy=vbuzz -tza -tay -//FRAGMENT vbuzz=vbuaa -taz -//FRAGMENT vbuzz=vbuxx -txa -taz -//FRAGMENT vbuzz=vbuyy -tya -taz -//FRAGMENT vbuyy_eq_vbuc1_then_la1 -cpy #{c1} -beq {la1} -//FRAGMENT vbuzz_eq_vbuc1_then_la1 -cpz #{c1} -beq {la1} -//FRAGMENT vbuz1_lt_vbuxx_then_la1 -cpx {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuyy_ge_vbuz1_then_la1 -cpy {z1} -bcs {la1} -//FRAGMENT vbuaa=vbuc1 -lda #{c1} -//FRAGMENT 0_neq_vbuyy_then_la1 -cpy #0 -bne {la1} -//FRAGMENT 0_neq_vbuzz_then_la1 -cpz #0 -bne {la1} -//FRAGMENT vbuyy_ge_vbuxx_then_la1 -stx $ff -cpy $ff -bcs {la1} -//FRAGMENT vbsaa=_inc_vbsaa -inc -//FRAGMENT vbsxx=_inc_vbsxx -inx -//FRAGMENT vbsyy=_sbyte_vwuz1 -ldy {z1} -//FRAGMENT vbsyy=_inc_vbsyy -iny -//FRAGMENT vbszz=_sbyte_vwuz1 -ldz {z1} -//FRAGMENT vbszz=_inc_vbszz -inz -//FRAGMENT 0_eq_vbuzz_then_la1 -cpz #0 -beq {la1} -//FRAGMENT vbuz1_neq_vbuxx_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT vbuz1_neq_vbuyy_then_la1 -cpy {z1} -bne {la1} -//FRAGMENT vbuz1_neq_vbuzz_then_la1 -cpz {z1} -bne {la1} -//FRAGMENT vbuxx_neq_vbuz1_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT vbuxx_neq_vbuaa_then_la1 -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuxx_neq_vbuyy_then_la1 -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuxx_neq_vbuzz_then_la1 -tza -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuyy_neq_vbuz1_then_la1 -cpy {z1} -bne {la1} -//FRAGMENT vbuyy_neq_vbuaa_then_la1 -tax -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuyy_neq_vbuxx_then_la1 -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuyy_neq_vbuzz_then_la1 -tza -tax -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuzz_neq_vbuz1_then_la1 -cpz {z1} -bne {la1} -//FRAGMENT vbuzz_neq_vbuaa_then_la1 -tax -tza -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuzz_neq_vbuxx_then_la1 -tza -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuzz_neq_vbuyy_then_la1 -tza -tax -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -//FRAGMENT vbuyy_lt_vbuz1_then_la1 -cpy {z1} -bcc {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuzz -tza -tay -lda {c1},y -sta {z1} -//FRAGMENT vbuzz_lt_vbuz1_then_la1 -cpz {z1} -bcc {la1} -//FRAGMENT vbuaa=vbuz1_minus_1 -lda {z1} -sec -sbc #1 -//FRAGMENT 0_eq_vbuyy_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vbuyy=_deref_pbuc1 -ldy {c1} -//FRAGMENT vbuzz=_deref_pbuc1 -ldz {c1} -//FRAGMENT vbuyy_le_vbuaa_then_la1 -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx=vbuz1_minus_1 -ldx {z1} -dex -//FRAGMENT vbuyy_le_vbuxx_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuzz=vbuz1_minus_1 -lda {z1} -taz -dez -//FRAGMENT vbuyy_le_vbuzz_then_la1 -sty $ff -cpz $ff -bcs {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy -ldx {c1},y -//FRAGMENT vbuzz=pbuc1_derefidx_vbuyy -lda {c1},y -taz -//FRAGMENT vbuaa_lt_vbuzz_then_la1 -stz $ff -cmp $ff -bcc {la1} -//FRAGMENT vbuxx=vbuzz_minus_1 -tza -tax -dex -//FRAGMENT vbuyy_lt_vbuzz_then_la1 -stz $ff -cpy $ff -bcc {la1} -//FRAGMENT vwuz1=vwuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_3 -asw {z1} -asw {z1} -asw {z1} //FRAGMENT pbuc1_derefidx_vbuzz=vbuzz tza tax sta {c1},x +//FRAGMENT vbuzz=_inc_vbuzz +inz //FRAGMENT vbsz1=_deref_pbsc1 lda {c1} sta {z1} diff --git a/src/main/fragment/cache/fragment-cache-mega45gs02.asm b/src/main/fragment/cache/fragment-cache-mega45gs02.asm index 72dcc0f24..a571c7e7c 100644 --- a/src/main/fragment/cache/fragment-cache-mega45gs02.asm +++ b/src/main/fragment/cache/fragment-cache-mega45gs02.asm @@ -1,72 +1,24 @@ //KICKC FRAGMENT CACHE 108dd16dc1 108dd18d7f -//FRAGMENT _deref_pbuc1=vbuc2 -lda #{c2} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 -lda #{c2} -ora {c1} -sta {c1} +//FRAGMENT vbuz1=vbuc1 +lda #{c1} +sta {z1} //FRAGMENT pbuz1=pbuc1 lda #<{c1} sta {z1} lda #>{c1} sta {z1}+1 -//FRAGMENT pbuz1_lt_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: -//FRAGMENT _deref_pbuc1=_deref_pbuc2 -lda {c2} -sta {c1} -//FRAGMENT vbuz1=_lo_pbuz2 -lda {z2} -sta {z1} -//FRAGMENT _deref_pbuz1=vbuz2 -lda {z2} -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=_inc_pbuz1 -inw {z1} -//FRAGMENT _deref_pbuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa=_lo_pbuz1 -lda {z1} -//FRAGMENT vbuxx=_lo_pbuz1 -ldx {z1} -//FRAGMENT _deref_pbuz1=vbuaa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuxx -txa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuyy -tya -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuzz -tza -ldy #0 -sta ({z1}),y -//FRAGMENT vbuyy=_lo_pbuz1 -ldy {z1} -//FRAGMENT vbuzz=_lo_pbuz1 -ldz {z1} -//FRAGMENT vbuz1=vbuc1 -lda #{c1} -sta {z1} //FRAGMENT isr_hardware_all_entry pha @clob_a phx @clob_x phy @clob_y phz @clob_z +//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 +lda #{c2} +ora {c1} +sta {c1} +//FRAGMENT _deref_pbuc1=vbuc2 +lda #{c2} +sta {c1} //FRAGMENT vbuz1=_inc_vbuz1 inc {z1} //FRAGMENT vbuz1=vbuz2 @@ -93,6 +45,8 @@ dec {z1} ldy #0 lda ({z2}),y sta {z1} +//FRAGMENT pbuz1=_inc_pbuz1 +inw {z1} //FRAGMENT vbuz1_neq_0_then_la1 lda {z1} bne {la1} @@ -190,6 +144,10 @@ bne {la1} lda {z1} cmp #<{c1} bne {la1} +//FRAGMENT _deref_pbuz1=vbuc1 +lda #{c1} +ldy #0 +sta ({z1}),y //FRAGMENT vbuaa=vbuz1 lda {z1} //FRAGMENT vbuxx=vbuz1 @@ -1187,217 +1145,11 @@ inc stx {c1} //FRAGMENT _deref_pbuc1=vbuzz stz {c1} -//FRAGMENT vbuz1=_deref_pbuc1_plus_1 -lda {c1} -inc -sta {z1} -//FRAGMENT vwuz1=_word_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_2 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_4 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT 0_neq_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuz3 -lda {z3} -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuc1 -lda #{c1} -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1=pbuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: //FRAGMENT pvoz1=pvoc1 lda #<{c1} sta {z1} lda #>{c1} sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_minus_vbuc1 -sec -lda {z1} -sbc #{c1} -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vwuc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1_neq_pbuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT _deref_pbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=pbuz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuaa=_deref_pbuc1_plus_1 -lda {c1} -inc -//FRAGMENT vbuxx=_deref_pbuc1_plus_1 -ldx {c1} -inx -//FRAGMENT vbuz1=vbuxx -stx {z1} -//FRAGMENT vwuz1=_word_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuzz -tza -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT 0_neq_vbuaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuz1=vbuaa -sta {z1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuaa -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuxx -txa -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuyy -tya -ldz {z2} -sta ({z1}),z -//FRAGMENT pbuz1_derefidx_vbuz2=vbuzz -tza -ldz {z2} -sta ({z1}),z -//FRAGMENT 0_neq_vbuxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuaa=vbuxx -txa -//FRAGMENT 0_neq_vbuyy_then_la1 -cpy #0 -bne {la1} -//FRAGMENT vbuaa=vbuyy -tya -//FRAGMENT 0_neq_vbuzz_then_la1 -cpz #0 -bne {la1} -//FRAGMENT vbuaa=vbuzz -tza -//FRAGMENT vbuz1=vbuyy -sty {z1} -//FRAGMENT vbuz1=vbuzz -tza -sta {z1} -//FRAGMENT vbuxx=vbuaa -tax -//FRAGMENT vbuyy=_deref_pbuc1_plus_1 -ldy {c1} -iny -//FRAGMENT vbuxx=vbuyy -tya -tax -//FRAGMENT vbuzz=_deref_pbuc1_plus_1 -lda {c1} -inc -taz -//FRAGMENT vbuxx=vbuzz -tza -tax -//FRAGMENT vwuz1=vwuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_4 -asw {z1} -asw {z1} -asw {z1} -asw {z1} //FRAGMENT vwuz1=vwuc1 lda #<{c1} sta {z1} @@ -1408,6 +1160,9 @@ lda #<{c1} sta {z1} lda #>{c1} sta {z1}+1 +//FRAGMENT _deref_pbuc1=_deref_pbuc2 +lda {c2} +sta {c1} //FRAGMENT pbuz1=pbuz1_plus_vwuc1 clc lda {z1} @@ -1416,10 +1171,23 @@ sta {z1} lda {z1}+1 adc #>{c1} sta {z1}+1 +//FRAGMENT pbuz1=pbuz1_plus_vbuc1 +lda #{c1} +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: //FRAGMENT pbuz1_derefidx_vbuz2=pbuz3_derefidx_vbuz2 ldy {z2} lda ({z3}),y sta ({z1}),y +//FRAGMENT vwuz1=_word_vbuz2 +lda {z2} +sta {z1} +lda #0 +sta {z1}+1 //FRAGMENT pwuz1=pwuz1_plus_vbuc1 lda #{c1} clc @@ -1493,6 +1261,21 @@ sta ({z1}),y sta {z1} lda #0 sta {z1}+1 +//FRAGMENT vwuz1=_word_vbuxx +txa +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=_word_vbuyy +tya +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=_word_vbuzz +tza +sta {z1} +lda #0 +sta {z1}+1 //FRAGMENT vbuz1=vbuaa_rol_1 asl sta {z1} @@ -1661,6 +1444,8 @@ inc {c1},x lda {z1} //FRAGMENT vbuxx=_lo_vwuz1 ldx {z1} +//FRAGMENT vbuz1=vbuaa +sta {z1} //FRAGMENT vbuaa=_hi_vwuz1 lda {z1}+1 //FRAGMENT vbuxx=_hi_vwuz1 @@ -1700,10 +1485,17 @@ ora {z2} sta {z1} //FRAGMENT vbuz1=vbuxx_bor_vbuxx stx {z1} +//FRAGMENT vbuz1=vbuxx +stx {z1} //FRAGMENT vbuyy=_lo_vwuz1 ldy {z1} +//FRAGMENT vbuz1=vbuyy +sty {z1} //FRAGMENT vbuzz=_lo_vwuz1 ldz {z1} +//FRAGMENT vbuz1=vbuzz +tza +sta {z1} //FRAGMENT vbuyy=_hi_vwuz1 ldy {z1}+1 //FRAGMENT vbuzz=_hi_vwuz1 @@ -2541,6 +2333,8 @@ tza tax tya sta {c1},x +//FRAGMENT vbuxx=vbuaa +tax //FRAGMENT vbuyy=vbuaa tay //FRAGMENT vbuzz=vbuaa @@ -2609,3 +2403,209 @@ sta {z1}+3 NO_SYNTHESIS //FRAGMENT vduz1=vwsc1 NO_SYNTHESIS +//FRAGMENT pbuz1_lt_pbuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT vbuz1=_lo_pbuz2 +lda {z2} +sta {z1} +//FRAGMENT _deref_pbuz1=vbuz2 +lda {z2} +ldy #0 +sta ({z1}),y +//FRAGMENT vbuaa=_lo_pbuz1 +lda {z1} +//FRAGMENT vbuxx=_lo_pbuz1 +ldx {z1} +//FRAGMENT _deref_pbuz1=vbuaa +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=vbuxx +txa +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=vbuyy +tya +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=vbuzz +tza +ldy #0 +sta ({z1}),y +//FRAGMENT vbuyy=_lo_pbuz1 +ldy {z1} +//FRAGMENT vbuzz=_lo_pbuz1 +ldz {z1} +//FRAGMENT vbuz1=_deref_pbuc1_plus_1 +lda {c1} +inc +sta {z1} +//FRAGMENT vwuz1=vwuz2_rol_2 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=vwuz2_plus_vwuz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_rol_4 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vwuz2 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT pbuz1=pbuz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT 0_neq_vbuz1_then_la1 +lda {z1} +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuz2=vbuz3 +lda {z3} +ldz {z2} +sta ({z1}),z +//FRAGMENT pbuz1_derefidx_vbuz2=vbuc1 +lda #{c1} +ldz {z2} +sta ({z1}),z +//FRAGMENT pbuz1=pbuz1_minus_vbuc1 +sec +lda {z1} +sbc #{c1} +sta {z1} +lda {z1}+1 +sbc #0 +sta {z1}+1 +//FRAGMENT pbuz1=pbuz2_plus_vwuc1 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT pbuz1_neq_pbuz2_then_la1 +lda {z1}+1 +cmp {z2}+1 +bne {la1} +lda {z1} +cmp {z2} +bne {la1} +//FRAGMENT _deref_pbuz1=_deref_pbuz2 +ldy #0 +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1=pbuz2_plus_vbuc1 +lda #{c1} +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT vbuaa=_deref_pbuc1_plus_1 +lda {c1} +inc +//FRAGMENT vbuxx=_deref_pbuc1_plus_1 +ldx {c1} +inx +//FRAGMENT 0_neq_vbuaa_then_la1 +cmp #0 +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuz2=vbuaa +ldz {z2} +sta ({z1}),z +//FRAGMENT pbuz1_derefidx_vbuz2=vbuxx +txa +ldz {z2} +sta ({z1}),z +//FRAGMENT pbuz1_derefidx_vbuz2=vbuyy +tya +ldz {z2} +sta ({z1}),z +//FRAGMENT pbuz1_derefidx_vbuz2=vbuzz +tza +ldz {z2} +sta ({z1}),z +//FRAGMENT 0_neq_vbuxx_then_la1 +cpx #0 +bne {la1} +//FRAGMENT vbuaa=vbuxx +txa +//FRAGMENT 0_neq_vbuyy_then_la1 +cpy #0 +bne {la1} +//FRAGMENT vbuaa=vbuyy +tya +//FRAGMENT 0_neq_vbuzz_then_la1 +cpz #0 +bne {la1} +//FRAGMENT vbuaa=vbuzz +tza +//FRAGMENT vbuyy=_deref_pbuc1_plus_1 +ldy {c1} +iny +//FRAGMENT vbuxx=vbuyy +tya +tax +//FRAGMENT vbuzz=_deref_pbuc1_plus_1 +lda {c1} +inc +taz +//FRAGMENT vbuxx=vbuzz +tza +tax +//FRAGMENT vwuz1=vwuz2_plus_vwuz1 +lda {z1} +clc +adc {z2} +sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vwuz1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vwuz1=vwuz1_rol_4 +asw {z1} +asw {z1} +asw {z1} +asw {z1} diff --git a/src/main/fragment/cache/fragment-cache-mos6502x.asm b/src/main/fragment/cache/fragment-cache-mos6502x.asm index 457d46980..5d6321843 100644 --- a/src/main/fragment/cache/fragment-cache-mos6502x.asm +++ b/src/main/fragment/cache/fragment-cache-mos6502x.asm @@ -263,1612 +263,108 @@ ldy #{c1} lda {c1},x //FRAGMENT vbuaa=pbuc1_derefidx_vbuyy lda {c1},y -//FRAGMENT vbuz1_lt_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcc {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuc2 -lda #{c2} -ldy {z1} -sta {c1},y -//FRAGMENT _deref_pbuc1=vbuc2 -lda #{c2} -sta {c1} +//FRAGMENT 0_neq_pbuz1_derefidx_vbuz2_then_la1 +ldy {z2} +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT vbuxx=vbuz1 +ldx {z1} +//FRAGMENT vbuaa=pbuz1_derefidx_vbuz2 +ldy {z2} +lda ({z1}),y //FRAGMENT vbuz1=vbuz1_plus_2 lda {z1} clc adc #2 sta {z1} -//FRAGMENT vbuaa_lt_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -//FRAGMENT pbuc1_derefidx_vbuaa=vbuc2 +//FRAGMENT pbuz1_derefidx_vbuxx=vbuaa +stx $ff +ldy $ff +sta ({z1}),y +//FRAGMENT 0_neq_pbuz1_derefidx_vbuaa_then_la1 tay -lda #{c2} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbuc2 -lda #{c2} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuc2 -lda #{c2} -sta {c1},y +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT 0_neq_pbuz1_derefidx_vbuxx_then_la1 +txa +tay +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT 0_neq_pbuz1_derefidx_vbuyy_then_la1 +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT vbuaa=pbuz1_derefidx_vbuxx +txa +tay +lda ({z1}),y +//FRAGMENT vbuaa=pbuz1_derefidx_vbuyy +lda ({z1}),y //FRAGMENT vbuxx=vbuxx_plus_2 inx inx -//FRAGMENT vbuxx_lt_vbuc1_then_la1 -cpx #{c1} -bcc {la1} -//FRAGMENT vbuyy_lt_vbuc1_then_la1 -cpy #{c1} -bcc {la1} -//FRAGMENT vbuyy=vbuyy_plus_2 -iny -iny -//FRAGMENT vwuz1_lt_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: -//FRAGMENT vbsz1=vbsz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=_hi_vwsz2 -lda {z2}+1 -sta {z1} -//FRAGMENT vbuz1=vbuc1_plus_vbuz2 -lax {z2} -axs #-[{c1}] -stx {z1} -//FRAGMENT vbuz1=vbuz2 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=vwuz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=_inc_vwuz1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1_neq_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -//FRAGMENT 0_neq__deref_pbuz1_then_la1 -ldy #0 -lda ({z1}),y -cmp #0 -bne {la1} -//FRAGMENT vbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -sta {z1} -//FRAGMENT vwuz1=vwuz1_minus_vwuc1 -lda {z1} -sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuc1_minus_vwuz1 -sec -lda #<{c1} -sbc {z1} -sta {z1} -lda #>{c1} -sbc {z1}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_3 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vbuz1=vbuz2_minus_vbuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -//FRAGMENT vbuz1=vbuz2_plus_vbuz3 -lda {z2} -clc -adc {z3} -sta {z1} -//FRAGMENT vbuz1=_dec_vbuz1 -dec {z1} -//FRAGMENT vbuz1_eq_0_then_la1 -lda {z1} -beq {la1} -//FRAGMENT vbsz1=_neg_vbsz2 -lda {z2} -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vbsz1_ge_0_then_la1 -lda {z1} -cmp #0 -bpl {la1} -//FRAGMENT vbuz1=vbuz2_minus_vbuc1 -lax {z2} -axs #{c1} -stx {z1} -//FRAGMENT vwuz1=vwuz1_sethi_vbuz2 -lda {z2} -sta {z1}+1 -//FRAGMENT vbsz1_lt_0_then_la1 -lda {z1} -bmi {la1} -//FRAGMENT vbsz1=_neg_vbsz1 -lda {z1} -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vwuz1=vbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz1_bor_vbuc1 -lda #{c1} -ora {z1} -sta {z1} -//FRAGMENT vwuz1=vwuz2_rol_vbuz3 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -ldy {z3} -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=_word_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuz1_neq_0_then_la1 -lda {z1} -bne {la1} -//FRAGMENT vbuz1=vbuz1_ror_1 -lsr {z1} -//FRAGMENT vbsaa=vbsz1 -lda {z1} -//FRAGMENT vbsxx=vbsz1 -ldx {z1} -//FRAGMENT vbsz1=vbsaa -sta {z1} -//FRAGMENT vbuaa=_hi_vwsz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_vwsz1 -ldx {z1}+1 -//FRAGMENT vbuaa=vbuc1_plus_vbuz1 -lda #{c1} -clc -adc {z1} -//FRAGMENT vbuxx=vbuc1_plus_vbuz1 -lax {z1} -axs #-[{c1}] -//FRAGMENT vbuyy=vbuc1_plus_vbuz1 -lda #{c1} -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuc1_plus_vbuaa -clc -adc #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuc1_plus_vbuaa -clc -adc #{c1} -//FRAGMENT vbuxx=vbuc1_plus_vbuaa -tax -axs #-[{c1}] -//FRAGMENT vbuz1=vbuxx -stx {z1} -//FRAGMENT vbuaa=_deref_pbuz1 -ldy #0 -lda ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tay -//FRAGMENT vbuz1=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -tay -//FRAGMENT vbuz1=vbuyy_band_vbuc1 -tya -and #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_band_vbuc1 -tya -and #{c1} -//FRAGMENT vbuxx=vbuyy_band_vbuc1 -ldx #{c1} -tya -axs #0 -//FRAGMENT vbuyy=vbuyy_band_vbuc1 -tya -and #{c1} -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuz1 -lda {z1} -//FRAGMENT vbuxx=vbuz1 -ldx {z1} -//FRAGMENT vbuz1=vbuaa -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuz2 -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuz2 -txa -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuz2 -tya -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_minus_vbuaa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuaa -lda #0 -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuz2_minus_vbuxx -txa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuxx -lda #0 -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuz2_minus_vbuyy -tya -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuyy -lda #0 -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -//FRAGMENT vbuaa=vbuaa_minus_vbuz1 -sec -sbc {z1} -//FRAGMENT vbuaa=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -//FRAGMENT vbuaa=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuaa -lda #0 -//FRAGMENT vbuaa=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -//FRAGMENT vbuaa=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -//FRAGMENT vbuaa=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuxx_minus_vbuxx -lda #0 -//FRAGMENT vbuaa=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -//FRAGMENT vbuaa=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -//FRAGMENT vbuaa=vbuyy_minus_vbuyy -lda #0 -//FRAGMENT vbuxx=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuz1 -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -tax -//FRAGMENT vbuxx=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuaa -lda #0 -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuxx -lda #0 -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbuxx=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuxx=vbuyy_minus_vbuyy -lda #0 -tax -//FRAGMENT vbuyy=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuz1 -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuz1 -tya -sec -sbc {z1} -tay -//FRAGMENT vbuyy=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuaa -lda #0 -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuaa -sta $ff -tya -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuxx -stx $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuxx -lda #0 -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuxx -tya -stx $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbuyy=vbuaa_minus_vbuyy -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuyy -lda #0 -tay -//FRAGMENT vbuaa=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -//FRAGMENT vbuxx=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -tay -//FRAGMENT vbuz1=vbuz2_plus_vbuaa -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_vbuaa -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_vbuaa -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuaa -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_vbuxx -txa -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_vbuxx -txa -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuxx -txa -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuz2_plus_vbuyy -tya -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_vbuyy -tya -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_vbuyy -tya -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuyy -tya -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuxx_plus_vbuz2 -txa -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -//FRAGMENT vbuxx=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuxx_plus_vbuaa -stx $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_vbuaa -stx $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuxx_plus_vbuaa -stx $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuxx_plus_vbuaa -stx $ff -clc -adc $ff -tay -//FRAGMENT vbuz1=vbuxx_plus_vbuxx -txa -asl -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_vbuxx -txa -asl -//FRAGMENT vbuxx=vbuxx_plus_vbuxx -txa -asl -tax -//FRAGMENT vbuyy=vbuxx_plus_vbuxx -txa -asl -tay -//FRAGMENT vbuz1=vbuxx_plus_vbuyy -txa -sty $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_vbuyy -txa -sty $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuxx_plus_vbuyy -txa -sty $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuxx_plus_vbuyy -txa -sty $ff -clc -adc $ff -tay -//FRAGMENT vbuz1=vbuyy_plus_vbuz2 -tya -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -//FRAGMENT vbuxx=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuyy_plus_vbuaa -sty $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_vbuaa -sty $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuyy_plus_vbuaa -sty $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuyy_plus_vbuaa -sty $ff -clc -adc $ff -tay -//FRAGMENT vbuz1=vbuyy_plus_vbuxx -txa -sty $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_vbuxx -txa -sty $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuyy_plus_vbuxx -txa -sty $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuyy_plus_vbuxx -txa -sty $ff -clc -adc $ff -tay -//FRAGMENT vbuz1=vbuyy_plus_vbuyy -tya -asl -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_vbuyy -tya -asl -//FRAGMENT vbuxx=vbuyy_plus_vbuyy -tya -asl -tax -//FRAGMENT vbuyy=vbuyy_plus_vbuyy -tya -asl -tay -//FRAGMENT vbuxx_eq_0_then_la1 -cpx #0 -beq {la1} -//FRAGMENT vbsaa=_neg_vbsz1 -lda {z1} -eor #$ff -clc -adc #$01 -//FRAGMENT vbsxx=_neg_vbsz1 -lda {z1} -eor #$ff -clc -adc #$01 -tax -//FRAGMENT vbsyy=_neg_vbsz1 -lda {z1} -eor #$ff -clc -adc #$01 -tay -//FRAGMENT vbsz1=_neg_vbsaa -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vbsaa=_neg_vbsaa -eor #$ff -clc -adc #$01 -//FRAGMENT vbsxx=_neg_vbsaa -eor #$ff -clc -adc #$01 -tax -//FRAGMENT vbsyy=_neg_vbsaa -eor #$ff -clc -adc #$01 -tay -//FRAGMENT vbsz1=_neg_vbsxx -txa -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vbsaa=_neg_vbsxx -txa -eor #$ff -clc -adc #$01 -//FRAGMENT vbsxx=_neg_vbsxx -txa -eor #$ff -clc -adc #$01 -tax -//FRAGMENT vbsyy=_neg_vbsxx -txa -eor #$ff -clc -adc #$01 -tay -//FRAGMENT vbsz1=_neg_vbsyy -tya -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vbsaa=_neg_vbsyy -tya -eor #$ff -clc -adc #$01 -//FRAGMENT vbsxx=_neg_vbsyy -tya -eor #$ff -clc -adc #$01 -tax -//FRAGMENT vbsyy=_neg_vbsyy -tya -eor #$ff -clc -adc #$01 -tay -//FRAGMENT vbsxx_ge_0_then_la1 -cpx #0 -bpl {la1} -//FRAGMENT vbuz1=vbuaa_minus_vbuc1 -sec -sbc #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuxx_minus_vbuc1 -txa -axs #{c1} -stx {z1} -//FRAGMENT vbuz1=vbuyy_minus_vbuc1 -tya -sec -sbc #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus_vbuc1 -lda {z1} -sec -sbc #{c1} -//FRAGMENT vbuaa=vbuaa_minus_vbuc1 -sec -sbc #{c1} -//FRAGMENT vbuaa=vbuxx_minus_vbuc1 -txa -sec -sbc #{c1} -//FRAGMENT vbuaa=vbuyy_minus_vbuc1 -tya -sec -sbc #{c1} -//FRAGMENT vbuxx=vbuz1_minus_vbuc1 -lax {z1} -axs #{c1} -//FRAGMENT vbuxx=vbuaa_minus_vbuc1 -tax -axs #{c1} -//FRAGMENT vwuz1=vwuz1_sethi_vbuaa -sta {z1}+1 -//FRAGMENT vbsaa_lt_0_then_la1 -cmp #0 -bmi {la1} -//FRAGMENT vbuz1=vbuaa_band_vbuc1 -and #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuaa_band_vbuc1 -and #{c1} -//FRAGMENT vbuxx=vbuaa_band_vbuc1 -ldx #{c1} -axs #0 -//FRAGMENT vbuaa_eq_0_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vwuz1=vwuz2_rol_vbuxx -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -cpx #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dex -bne !- -!e: -//FRAGMENT vwuz1=vwuz2_rol_vbuyy -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=_word_vbuaa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuxx_neq_0_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbsz1=vbsxx -stx {z1} -//FRAGMENT vbuyy_eq_0_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vbuxx=vbuxx_ror_1 -txa -lsr -tax -//FRAGMENT vbuyy=vbuz1 +//FRAGMENT pbuc1_derefidx_vbuz1=vbuz1 ldy {z1} -//FRAGMENT vbuyy_neq_0_then_la1 -cpy #0 -bne {la1} -//FRAGMENT vbuyy=vbuyy_ror_1 tya -lsr -tay -//FRAGMENT vbuyy=_hi_vwuz1 -ldy {z1}+1 -//FRAGMENT vbuyy=vbuaa_band_vbuc1 -and #{c1} -tay -//FRAGMENT vbuxx=_inc_vbuxx -inx -//FRAGMENT vbuyy=_inc_vbuyy -iny -//FRAGMENT vbuyy_neq_vbuc1_then_la1 -cpy #{c1} -bne {la1} -//FRAGMENT vbuxx=vbuaa -tax -//FRAGMENT vbuxx=vbuyy -tya -tax -//FRAGMENT vbuaa=vbuyy -tya -//FRAGMENT vbuz1=vbuyy -sty {z1} -//FRAGMENT vbuaa=vbuxx -txa -//FRAGMENT vbuaa=_dec_vbuaa -sec -sbc #1 -//FRAGMENT vbuxx=_dec_vbuxx -dex -//FRAGMENT vbuyy=_dec_vbuyy -dey -//FRAGMENT vbsz1=vbsyy -sty {z1} -//FRAGMENT vbsaa=vbsxx -txa -//FRAGMENT vbsaa=vbsyy -tya -//FRAGMENT vbsxx=vbsaa -tax -//FRAGMENT vbsxx=vbsyy -tya -tax -//FRAGMENT vbsyy=vbsz1 -ldy {z1} -//FRAGMENT vbsyy=vbsaa -tay -//FRAGMENT vbsyy=vbsxx -txa -tay -//FRAGMENT vbuyy=vbuaa -tay -//FRAGMENT vwuz1=vwuz1_sethi_vbuxx -stx {z1}+1 -//FRAGMENT vbuxx=vbuxx_minus_vbuc1 -txa -axs #{c1} -//FRAGMENT vbuxx=vbuyy_minus_vbuc1 -tya -tax -axs #{c1} -//FRAGMENT vbuyy=vbuz1_minus_vbuc1 -lda {z1} -sec -sbc #{c1} -tay -//FRAGMENT vwuz1=vwuz1_sethi_vbuyy -sty {z1}+1 -//FRAGMENT vbuyy=vbuaa_minus_vbuc1 -sec -sbc #{c1} -tay -//FRAGMENT vbuyy=vbuxx_minus_vbuc1 -txa -sec -sbc #{c1} -tay -//FRAGMENT vbuyy=vbuyy_minus_vbuc1 -tya -sec -sbc #{c1} -tay -//FRAGMENT vbsyy_ge_0_then_la1 -cpy #0 -bpl {la1} -//FRAGMENT vbsxx_lt_0_then_la1 -cpx #0 -bmi {la1} -//FRAGMENT vbuz1=vbuc1_plus_vbuxx -txa -axs #-[{c1}] -stx {z1} -//FRAGMENT vbuyy=_hi_vwsz1 -ldy {z1}+1 -//FRAGMENT vbuz1=vbuc1_plus_vbuyy -tya -clc -adc #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_plus__hi_vwsz2 -lda #{c1} -clc -adc {z2}+1 -sta {z1} -//FRAGMENT vwuz1=vwuz1_rol_3 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_vbuz2 -ldy {z2} -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vbuz1_eq_vbuz2_then_la1 -lda {z1} -cmp {z2} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuz2 -lda {z2} -ldy {z1} sta {c1},y -//FRAGMENT vbuz1_eq_vbuaa_then_la1 -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuxx -ldy {z1} -txa -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=vbuyy -tya -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbuz1 -lda {z1} +//FRAGMENT vbuaa_neq_vbuc1_then_la1 +cmp #{c1} +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuaa=vbuaa +tax sta {c1},x +//FRAGMENT vbuaa=_inc_vbuaa +clc +adc #1 //FRAGMENT pbuc1_derefidx_vbuxx=vbuxx txa sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=vbuyy -tya -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuz1 -lda {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuyy=vbuxx -txa -sta {c1},y +//FRAGMENT vbuxx=_inc_vbuxx +inx +//FRAGMENT vbuyy_neq_vbuc1_then_la1 +cpy #{c1} +bne {la1} //FRAGMENT pbuc1_derefidx_vbuyy=vbuyy tya sta {c1},y -//FRAGMENT vbuz1_eq_vbuyy_then_la1 -tya -cmp {z1} -beq {la1} -//FRAGMENT vbuyy_eq_vbuz1_then_la1 -tya -cmp {z1} -beq {la1} -//FRAGMENT vbuyy_eq_vbuaa_then_la1 -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT vwuz1=vwuz2_plus_1 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_1 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -//FRAGMENT pwuz1=pwuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=_deref_pwuz2_plus__deref_pwuz3 -ldy #0 -clc -lda ({z2}),y -adc ({z3}),y -sta {z1} +//FRAGMENT vbuyy=_inc_vbuyy iny -lda ({z2}),y -adc ({z3}),y -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus__deref_pwuz3 -ldy #0 -clc -lda {z2} -adc ({z3}),y -sta {z1} -iny -lda {z2}+1 -adc ({z3}),y -sta {z1}+1 -//FRAGMENT vwuz1_neq_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} +//FRAGMENT vbuz1_lt_vbuc1_then_la1 lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT vwuz1=_deref_pwuz2 -ldy #0 -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vduz1=vduz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=_lo_vduz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pvoz1=_deref_qvoc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -//FRAGMENT 0_neq_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT vbuz1=_deref_pbuc1 -lda {c1} -sta {z1} -//FRAGMENT vduz1=_dword_vwuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda #0 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vduz1=vduc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -lda #<{c1}>>$10 -sta {z1}+2 -lda #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT vwuz1_neq_0_then_la1 -lda {z1} -ora {z1}+1 -bne {la1} -//FRAGMENT vbuz1=vwuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -//FRAGMENT vduz1=vduz1_plus_vduz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc {z2}+2 -sta {z1}+2 -lda {z1}+3 -adc {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz1_ror_1 -lsr {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz1_rol_1 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vwuz1_le_0_then_la1 -lda {z1} -bne !+ -lda {z1}+1 -beq {la1} -!: -//FRAGMENT pbuz1=pbuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT pbuz1_neq_pbuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT _deref_pwuc1=vbuc2 -lda #0 -sta {c1}+1 -lda #<{c2} -sta {c1} -//FRAGMENT vbuz1_eq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -beq {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_(_deref_pbuc2) -ldy {c2} -lda {c1},y -sta {z1} -//FRAGMENT _deref_pwuc1=_inc__deref_pwuc1 -inc {c1} -bne !+ -inc {c1}+1 -!: -//FRAGMENT _deref_pwuc1_eq_vbuc2_then_la1 -lda {c1}+1 -bne !+ -lda {c1} -cmp #{c2} -beq {la1} -!: -//FRAGMENT vbuz1=_byte_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=_inc_pbuz2 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 +cmp #{c1} +bcc {la1} //FRAGMENT vbuz1=vbuz2_rol_1 lda {z2} asl sta {z1} -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2 -ldy {z2} +//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_vbuc2 +ldy {z1} +clc lda {c1},y -sta {z1} +adc #{c2} +sta {c1},y lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1_ge_vwuz2_then_la1 -lda {z2}+1 -cmp {z1}+1 -bne !+ -lda {z2} -cmp {z1} -beq {la1} -!: +adc #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_pwuc2_derefidx_vbuz1 +ldy {z1} +clc +lda {c1},y +adc {c2},y +sta {c1},y +lda {c1}+1,y +adc {c2}+1,y +sta {c1}+1,y +//FRAGMENT vbuaa_lt_vbuc1_then_la1 +cmp #{c1} bcc {la1} -//FRAGMENT 0_eq_vbuz1_then_la1 -lda {z1} -beq {la1} -//FRAGMENT vbuz1=_byte_vduz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_rol_2 -lda {z2} -asl -asl -sta {z1} -//FRAGMENT vduz1=pduc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1_ge_vduz2_then_la1 -lda {z1}+3 -cmp {z2}+3 -bcc !+ -bne {la1} -lda {z1}+2 -cmp {z2}+2 -bcc !+ -bne {la1} -lda {z1}+1 -cmp {z2}+1 -bcc !+ -bne {la1} -lda {z1} -cmp {z2} -bcs {la1} -!: -//FRAGMENT _deref_(_deref_qbuc1)=_deref_pbuc2 -lda {c2} -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_pbuc1=vbuz1 -lda {z1} -sta {c1} -//FRAGMENT _deref_qbuc1=pbuz1 -lda {z1} -sta {c1} -lda {z1}+1 -sta {c1}+1 -//FRAGMENT vbuz1=vbuz2_bxor_vbuc1 -lda #{c1} -eor {z2} -sta {z1} -//FRAGMENT _deref_(_deref_qbuc1)=vbuz1 -lda {z1} -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_pbuc1=_inc__deref_pbuc1 -inc {c1} -//FRAGMENT _deref_pbuc1_neq_vbuc2_then_la1 -lda #{c2} -cmp {c1} -bne {la1} -//FRAGMENT _deref_(_deref_qbuc1)=_deref_(_deref_qbuc1)_bxor_vbuc2 -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -lda ($fe),y -eor #{c2} -sta ($fe),y -//FRAGMENT pbuz1=_deref_qbuc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pvoz1=pvoz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vwuc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_minus_vwuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT vduz1=vduz1_minus_vduz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -lda {z1}+2 -sbc {z2}+2 -sta {z1}+2 -lda {z1}+3 -sbc {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=_word__deref_pbuc1 -lda {c1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_2 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT pbuz1=_deref_qbuc1_plus_vwuz2 -clc -lda {z2} -adc {c1} -sta {z1} -lda {z2}+1 -adc {c1}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus__deref_pwuc1 -clc -lda {c1} -adc {z2} -sta {z1} -lda {c1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT 0_neq_vbuaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuaa=_deref_pbuc1 -lda {c1} -//FRAGMENT vbuxx=_deref_pbuc1 -ldx {c1} -//FRAGMENT vbuaa=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -//FRAGMENT vbuxx=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -tax -//FRAGMENT vbuyy=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -tay -//FRAGMENT vbuaa=pbuc1_derefidx_(_deref_pbuc2) -ldy {c2} -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_(_deref_pbuc2) -ldy {c2} -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_(_deref_pbuc2) -ldx {c2} -ldy {c1},x -//FRAGMENT vbuaa=_byte_vwuz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vwuz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vwuz1 -lda {z1} -tay -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -sta ({z1}),y //FRAGMENT vbuaa=vbuz1_rol_1 lda {z1} asl @@ -1921,894 +417,6 @@ tax tya asl tay -//FRAGMENT vwuz1=pwuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT 0_neq_vbuxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT 0_eq_vbuaa_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vbuaa=_byte_vduz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vduz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vduz1 -lda {z1} -tay -//FRAGMENT vbuz1=vbuaa_rol_2 -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuxx_rol_2 -txa -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuyy_rol_2 -tya -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuz1_rol_2 -lda {z1} -asl -asl -//FRAGMENT vbuaa=vbuaa_rol_2 -asl -asl -//FRAGMENT vbuaa=vbuxx_rol_2 -txa -asl -asl -//FRAGMENT vbuaa=vbuyy_rol_2 -tya -asl -asl -//FRAGMENT vbuxx=vbuz1_rol_2 -lda {z1} -asl -asl -tax -//FRAGMENT vbuxx=vbuaa_rol_2 -asl -asl -tax -//FRAGMENT vbuxx=vbuxx_rol_2 -txa -asl -asl -tax -//FRAGMENT vbuxx=vbuyy_rol_2 -tya -asl -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_2 -lda {z1} -asl -asl -tay -//FRAGMENT vbuyy=vbuaa_rol_2 -asl -asl -tay -//FRAGMENT vbuyy=vbuxx_rol_2 -txa -asl -asl -tay -//FRAGMENT vbuyy=vbuyy_rol_2 -tya -asl -asl -tay -//FRAGMENT vduz1=pduc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -lda {c1}+2,x -sta {z1}+2 -lda {c1}+3,x -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT _deref_pbuc1=vbuaa -sta {c1} -//FRAGMENT vbuaa=vbuz1_bxor_vbuc1 -lda #{c1} -eor {z1} -//FRAGMENT vbuxx=vbuz1_bxor_vbuc1 -lda #{c1} -eor {z1} -tax -//FRAGMENT vbuyy=vbuz1_bxor_vbuc1 -lda #{c1} -eor {z1} -tay -//FRAGMENT vbuz1=vbuxx_bxor_vbuc1 -txa -eor #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_bxor_vbuc1 -txa -eor #{c1} -//FRAGMENT vbuxx=vbuxx_bxor_vbuc1 -txa -eor #{c1} -tax -//FRAGMENT vbuyy=vbuxx_bxor_vbuc1 -txa -eor #{c1} -tay -//FRAGMENT vbuz1=vbuyy_bxor_vbuc1 -tya -eor #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_bxor_vbuc1 -tya -eor #{c1} -//FRAGMENT vbuxx=vbuyy_bxor_vbuc1 -tya -eor #{c1} -tax -//FRAGMENT vbuyy=vbuyy_bxor_vbuc1 -tya -eor #{c1} -tay -//FRAGMENT _deref_(_deref_qbuc1)=vbuaa -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=vbuxx -txa -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=vbuyy -tya -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_pbuc1=vbuxx -stx {c1} -//FRAGMENT _deref_pbuc1=vbuyy -sty {c1} -//FRAGMENT 0_neq_vbuyy_then_la1 -cpy #0 -bne {la1} -//FRAGMENT 0_eq_vbuxx_then_la1 -cpx #0 -beq {la1} -//FRAGMENT vbuyy=_deref_pbuc1 -ldy {c1} -//FRAGMENT 0_eq_vbuyy_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vwuz1=_deref_pwuz1 -ldy #0 -lda ({z1}),y -pha -iny -lda ({z1}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT pbuz1=pbuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=_deref_pwuz1_plus__deref_pwuz2 -ldy #0 -clc -lda ({z1}),y -adc ({z2}),y -pha -iny -lda ({z1}),y -adc ({z2}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT vwuz1=vwuz2_plus__deref_pwuz1 -ldy #0 -clc -lda ({z1}),y -adc {z2} -pha -iny -lda ({z1}),y -adc {z2}+1 -sta {z1}+1 -pla -sta {z1} -//FRAGMENT vwuz1=vwuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=_deref_qbuc1_plus_vwuz1 -clc -lda {z1} -adc {c1} -sta {z1} -lda {z1}+1 -adc {c1}+1 -sta {z1}+1 -//FRAGMENT pwuz1=pwuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_plus_vwuc1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_plus__deref_pwuc1 -clc -lda {c1} -adc {z1} -sta {z1} -lda {c1}+1 -adc {z1}+1 -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_minus_1 -ldx {z2} -dex -stx {z1} -//FRAGMENT pbuz1_derefidx_vbuz2_neq_vbuz3_then_la1 -ldy {z2} -lda ({z1}),y - -cmp {z3} -bne {la1} -//FRAGMENT vbuz1_lt_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcc {la1} -//FRAGMENT vbuz1_le_vbuz2_then_la1 -lda {z2} -cmp {z1} -bcs {la1} -//FRAGMENT _deref_pbuz1_neq_vbuz2_then_la1 -ldy #0 -lda ({z1}),y -cmp {z2} -bne {la1} -//FRAGMENT pbuz1=pbuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuz2=vbuc1 -lda #{c1} -ldy {z2} -sta ({z1}),y -//FRAGMENT vbuz1_le_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bcs {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuz3 -lda {z3} -ldy {z2} -sta ({z1}),y -//FRAGMENT pvoz1=pvoc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_minus_vbuc1 -sec -lda {z1} -sbc #{c1} -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT vbuaa=vbuz1_minus_1 -lda {z1} -sec -sbc #1 -//FRAGMENT pbuz1_derefidx_vbuaa_neq_vbuz2_then_la1 -tay -lda ({z1}),y - -cmp {z2} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_neq_vbuz2_then_la1 -txa -tay -lda ({z1}),y - -cmp {z2} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_neq_vbuz2_then_la1 -lda ({z1}),y - -cmp {z2} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuz2_neq_vbuxx_then_la1 -ldy {z2} -lda ({z1}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuaa_neq_vbuxx_then_la1 -tay -lda ({z1}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_neq_vbuxx_then_la1 -txa -tay -lda ({z1}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_neq_vbuxx_then_la1 -lda ({z1}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuz2_neq_vbuyy_then_la1 -tya -ldy {z2} -tax -lda ({z1}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuaa_neq_vbuyy_then_la1 -NO_SYNTHESIS -//FRAGMENT pbuz1_derefidx_vbuxx_neq_vbuyy_then_la1 -NO_SYNTHESIS -//FRAGMENT pbuz1_derefidx_vbuyy_neq_vbuyy_then_la1 -lda ({z1}),y - -tax -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuxx_lt_vbuz1_then_la1 -cpx {z1} -bcc {la1} -//FRAGMENT vbuxx_le_vbuz1_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuz1_le_vbuxx_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vbuxx_eq_vbuc1_then_la1 -cpx #{c1} -beq {la1} -//FRAGMENT _deref_pbuz1_neq_vbuxx_then_la1 -ldy #0 -lda ({z1}),y -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuaa=vbuc1 -tay -lda #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=vbuc1 -txa -tay -lda #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=vbuc1 -lda #{c1} -sta ({z1}),y -//FRAGMENT vbuaa_le_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuz1=vbuaa_plus_vbuz2 -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuaa_plus_vbuz1 -clc -adc {z1} -//FRAGMENT vbuxx=vbuaa_plus_vbuz1 -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuaa_plus_vbuz1 -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuaa_plus_vbuxx -stx $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuaa_plus_vbuxx -stx $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuaa_plus_vbuxx -stx $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuaa_plus_vbuxx -stx $ff -clc -adc $ff -tay -//FRAGMENT vbuz1=vbuaa_plus_vbuyy -sty $ff -clc -adc $ff -sta {z1} -//FRAGMENT vbuaa=vbuaa_plus_vbuyy -sty $ff -clc -adc $ff -//FRAGMENT vbuxx=vbuaa_plus_vbuyy -sty $ff -clc -adc $ff -tax -//FRAGMENT vbuyy=vbuaa_plus_vbuyy -sty $ff -clc -adc $ff -tay -//FRAGMENT vbuaa_eq_vbuc1_then_la1 -cmp #{c1} -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuaa -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=vbuxx -ldy {z2} -txa -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=vbuyy -tya -ldy {z2} -sta ({z1}),y -//FRAGMENT vbuxx_le_vbuc1_then_la1 -cpx #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuyy_eq_vbuc1_then_la1 -cpy #{c1} -beq {la1} -//FRAGMENT vbuyy_le_vbuc1_then_la1 -cpy #{c1} -bcc {la1} -beq {la1} -//FRAGMENT vbuxx=vbuz1_minus_1 -ldx {z1} -dex -//FRAGMENT vbuyy=vbuz1_minus_1 -lda {z1} -tay -dey -//FRAGMENT vbuz1=vbuz1_plus_vbuaa -clc -adc {z1} -sta {z1} -//FRAGMENT pbuz1=pbuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuz2_neq_vbuc1_then_la1 -ldy {z2} -lda ({z1}),y - -cmp #{c1} -bne {la1} -//FRAGMENT vbuz1=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuc1 -lax {z1} -axs #{c1} -stx {z1} -//FRAGMENT pbuz1=pbuz1_plus_vbuz2 -lda {z2} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=vwuz1_plus_vbuz2 -lda {z2} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1_derefidx_vbuxx_neq_vbuc1_then_la1 -txa -tay -lda ({z1}),y - -cmp #{c1} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_neq_vbuc1_then_la1 -lda ({z1}),y - -cmp #{c1} -bne {la1} -//FRAGMENT vbuz1=vbuz1_plus_vbuxx -txa -clc -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_plus_vbuyy -tya -clc -adc {z1} -sta {z1} -//FRAGMENT pbuz1=pbuz1_plus_vbuaa -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1=pbuz1_plus_vbuxx -txa -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1=pbuz1_plus_vbuyy -tya -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=vwuz1_plus_vbuxx -txa -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=vwuz1_plus_vbuyy -tya -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT _deref_pbuz1_neq_vbuc1_then_la1 -ldy #0 -lda ({z1}),y -cmp #{c1} -bne {la1} -//FRAGMENT 0_eq_pbuc1_derefidx_vbuz1_then_la1 -ldy {z1} -lda {c1},y -cmp #0 -beq {la1} -//FRAGMENT 0_eq__deref_pbuz1_then_la1 -ldy #0 -lda ({z1}),y -cmp #0 -beq {la1} -//FRAGMENT _deref_pbuz1_eq_vbuc1_then_la1 -lda #{c1} -ldy #0 -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuz2_neq_pbuz3_derefidx_vbuz2_then_la1 -ldy {z2} -lda ({z1}),y - -tax -lda ({z3}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT 0_eq_pbuc1_derefidx_vbuaa_then_la1 -tay -lda {c1},y -cmp #0 -beq {la1} -//FRAGMENT 0_eq_pbuc1_derefidx_vbuxx_then_la1 -lda {c1},x -cmp #0 -beq {la1} -//FRAGMENT 0_eq_pbuc1_derefidx_vbuyy_then_la1 -lda {c1},y -cmp #0 -beq {la1} -//FRAGMENT vbuaa_neq_vbuc1_then_la1 -cmp #{c1} -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuaa_neq_pbuz2_derefidx_vbuaa_then_la1 -tay -lda ({z1}),y - -tax -lda ({z2}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_neq_pbuz2_derefidx_vbuxx_then_la1 -txa -tay -lda ({z1}),y - -tax -lda ({z2}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_neq_pbuz2_derefidx_vbuyy_then_la1 -lda ({z1}),y - -tax -lda ({z2}),y - -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuz1_ge_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcs {la1} -//FRAGMENT vbuaa_ge_vbuc1_then_la1 -cmp #{c1} -bcs {la1} -//FRAGMENT vbuaa_neq_0_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuxx_ge_vbuc1_then_la1 -cpx #{c1} -bcs {la1} -//FRAGMENT vbuyy_ge_vbuc1_then_la1 -cpy #{c1} -bcs {la1} -//FRAGMENT 0_neq_pbuz1_derefidx_vbuz2_then_la1 -ldy {z2} -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=vbuaa -stx $ff -ldy $ff -sta ({z1}),y -//FRAGMENT 0_neq_pbuz1_derefidx_vbuaa_then_la1 -tay -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT 0_neq_pbuz1_derefidx_vbuxx_then_la1 -txa -tay -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT 0_neq_pbuz1_derefidx_vbuyy_then_la1 -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuyy -lda ({z1}),y -//FRAGMENT vbuz1_neq_vbuz2_then_la1 -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT vbuz1_gt_vbuz2_then_la1 -lda {z2} -cmp {z1} -bcc {la1} -//FRAGMENT vbuz1=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuz1_neq_vbuaa_then_la1 -cmp {z1} -bne {la1} -//FRAGMENT vbuz1_gt_vbuaa_then_la1 -cmp {z1} -bcc {la1} -//FRAGMENT vbuz1=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuz1_neq_vbuxx_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT vbuz1_gt_vbuxx_then_la1 -cpx {z1} -bcc {la1} -//FRAGMENT vbuz1_neq_vbuyy_then_la1 -cpy {z1} -bne {la1} -//FRAGMENT vbuz1_gt_vbuyy_then_la1 -cpy {z1} -bcc {la1} -//FRAGMENT vbuxx_neq_vbuz1_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT vbuxx_gt_vbuz1_then_la1 -cpx {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuxx_neq_vbuyy_then_la1 -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuxx_gt_vbuyy_then_la1 -stx $ff -cpy $ff -bcc {la1} -//FRAGMENT vbuyy_neq_vbuz1_then_la1 -cpy {z1} -bne {la1} -//FRAGMENT vbuyy_gt_vbuz1_then_la1 -cpy {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuyy_neq_vbuxx_then_la1 -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuyy_gt_vbuxx_then_la1 -sty $ff -cpx $ff -bcc {la1} -//FRAGMENT vbuyy=vbuxx -txa -tay -//FRAGMENT pbuc1_derefidx_vbuz1=vbuz1 -ldy {z1} -tya -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=vbuaa -tax -sta {c1},x -//FRAGMENT vbuaa=_inc_vbuaa -clc -adc #1 -//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_vbuc2 -ldy {z1} -clc -lda {c1},y -adc #{c2} -sta {c1},y -lda {c1}+1,y -adc #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_pwuc2_derefidx_vbuz1 -ldy {z1} -clc -lda {c1},y -adc {c2},y -sta {c1},y -lda {c1}+1,y -adc {c2}+1,y -sta {c1}+1,y //FRAGMENT pwuc1_derefidx_vbuaa=pwuc1_derefidx_vbuaa_plus_vbuc2 tay clc @@ -2856,32 +464,30 @@ sta {c1},y lda {c1}+1,y adc {c2}+1,y sta {c1}+1,y -//FRAGMENT isr_hardware_all_entry -sta rega+1 @clob_a -stx regx+1 @clob_x -sty regy+1 @clob_y -//FRAGMENT isr_hardware_all_exit -rega: @clob_a @nooptimize lda #0 @clob_a @nooptimize -regx: @clob_x @nooptimize ldx #0 @clob_x @nooptimize -regy: @clob_y @nooptimize ldy #0 @clob_y @nooptimize -rti -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 +//FRAGMENT vbuxx_lt_vbuc1_then_la1 +cpx #{c1} +bcc {la1} +//FRAGMENT vbuyy_lt_vbuc1_then_la1 +cpy #{c1} +bcc {la1} +//FRAGMENT _deref_pbuc1=vbuc2 lda #{c2} -ora {c1} sta {c1} -//FRAGMENT _deref_qprc1=pprc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -//FRAGMENT isr_rom_min_c64_entry - -//FRAGMENT isr_rom_min_c64_exit -jmp $ea81 +//FRAGMENT vbuz1=_deref_pbuc1 +lda {c1} +sta {z1} //FRAGMENT vbuz1=vbuz2_plus_vbuc1 lax {z2} axs #-[{c1}] stx {z1} +//FRAGMENT pbuc1_derefidx_vbuz1=vbuz2 +lda {z2} +ldy {z1} +sta {c1},y +//FRAGMENT vbuaa=_deref_pbuc1 +lda {c1} +//FRAGMENT vbuxx=_deref_pbuc1 +ldx {c1} //FRAGMENT vbuaa=vbuz1_plus_vbuc1 lda #{c1} clc @@ -2907,10 +513,24 @@ axs #-[{c1}] //FRAGMENT pbuc1_derefidx_vbuz1=vbuaa ldy {z1} sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=vbuxx +ldy {z1} +txa +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=vbuyy +tya +ldy {z1} +sta {c1},y //FRAGMENT pbuc1_derefidx_vbuaa=vbuz1 tay lda {z1} sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=vbuz1 +lda {z1} +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=vbuz1 +lda {z1} +sta {c1},y //FRAGMENT pbuc1_derefidx_vbuxx=vbuaa sta {c1},x //FRAGMENT pbuc1_derefidx_vbuyy=vbuaa @@ -2919,10 +539,16 @@ sta {c1},y tay txa sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuyy=vbuxx +txa +sta {c1},y //FRAGMENT pbuc1_derefidx_vbuaa=vbuyy tax tya sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=vbuyy +tya +sta {c1},x //FRAGMENT vbuyy=vbuaa_plus_vbuc1 clc adc #{c1} @@ -2940,6 +566,8 @@ txa clc adc #{c1} tay +//FRAGMENT vbuyy=_deref_pbuc1 +ldy {c1} //FRAGMENT vbuz1=vbuyy_plus_vbuc1 tya clc @@ -2957,46 +585,87 @@ axs #-[{c1}] ldy {z2} iny sty {z1} +//FRAGMENT pbuc1_derefidx_vbuz1=vbuc2 +lda #{c2} +ldy {z1} +sta {c1},y +//FRAGMENT vbuz1=vbuz2 +lda {z2} +sta {z1} //FRAGMENT vbuz1=_inc_vbuaa clc adc #1 sta {z1} +//FRAGMENT pbuc1_derefidx_vbuaa=vbuc2 +tay +lda #{c2} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=vbuc2 +lda #{c2} +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=vbuc2 +lda #{c2} +sta {c1},y +//FRAGMENT vbuaa=vbuz1 +lda {z1} //FRAGMENT vbuz1=_inc_vbuxx inx stx {z1} //FRAGMENT vbuz1=_inc_vbuyy iny sty {z1} +//FRAGMENT vbuyy=vbuz1 +ldy {z1} //FRAGMENT vbuaa=_inc_vbuz1 lda {z1} clc adc #1 +//FRAGMENT vbuz1=vbuaa +sta {z1} //FRAGMENT vbuaa=_inc_vbuxx inx txa +//FRAGMENT vbuxx=vbuaa +tax //FRAGMENT vbuaa=_inc_vbuyy iny tya +//FRAGMENT vbuyy=vbuaa +tay //FRAGMENT vbuxx=_inc_vbuz1 ldx {z1} inx +//FRAGMENT vbuz1=vbuxx +stx {z1} //FRAGMENT vbuxx=_inc_vbuaa tax inx +//FRAGMENT vbuaa=vbuxx +txa //FRAGMENT vbuxx=_inc_vbuyy tya tax inx +//FRAGMENT vbuyy=vbuxx +txa +tay //FRAGMENT vbuyy=_inc_vbuz1 ldy {z1} iny +//FRAGMENT vbuz1=vbuyy +sty {z1} //FRAGMENT vbuyy=_inc_vbuaa tay iny +//FRAGMENT vbuaa=vbuyy +tya //FRAGMENT vbuyy=_inc_vbuxx txa tay iny +//FRAGMENT vbuxx=vbuyy +tya +tax //FRAGMENT vwsz1=vwsz2_minus_vbsc1 lda {z2} sec @@ -3005,6 +674,17 @@ sta {z1} lda {z2}+1 sbc #>{c1} sta {z1}+1 +//FRAGMENT pbuz1_neq_pbuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT _deref_pbuz1=vbuc1 +lda #{c1} +ldy #0 +sta ({z1}),y //FRAGMENT vwsz1=vwsz1_minus_vbsc1 lda {z1} sec @@ -3122,15 +802,6 @@ inc {m1} lda #{c1} cmp {m1} bne {la1} -//FRAGMENT pbuz1_lt_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: //FRAGMENT vboz1=vbuz2_eq_vbuc1 lda {z2} eor #{c1} @@ -3157,6 +828,14 @@ sta {z1} lda {z2} ora {z3} sta {z1} +//FRAGMENT vbuz1=vbuaa_band_vbuc1 +and #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_band_vbuc1 +and #{c1} +//FRAGMENT vbuxx=vbuaa_band_vbuc1 +ldx #{c1} +axs #0 //FRAGMENT vboaa=vbuz1_eq_vbuc1 lda {z1} eor #{c1} @@ -3555,6 +1234,24 @@ tya sty $ff ora $ff tay +//FRAGMENT vbuz1=vbuyy_band_vbuc1 +tya +and #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuyy_band_vbuc1 +tya +and #{c1} +//FRAGMENT vbuxx=vbuyy_band_vbuc1 +ldx #{c1} +tya +axs #0 +//FRAGMENT vbuyy=vbuyy_band_vbuc1 +tya +and #{c1} +tay +//FRAGMENT vbuyy=vbuaa_band_vbuc1 +and #{c1} +tay //FRAGMENT vboxx_then_la1 cpx #0 bne {la1} @@ -3734,705 +1431,6 @@ dey bne !- !e: tay -//FRAGMENT pssz1=pssc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pssz1=pssz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pssz1=pssz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=vbuz1_plus_vbuc1 -lax {z1} -axs #-[{c1}] -stx {z1} -//FRAGMENT pssz1=pssz1_plus_vwuc1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pssz1=pssz1_minus_vwuc1 -lda {z1} -sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_ror_3 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vbuz1=vbuc1_minus_vbuz2 -lda #{c1} -sec -sbc {z2} -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz2 -ldy {z2} -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -sta {c1} -//FRAGMENT vbuz1=vbuz2_bor_vbuc1 -lda #{c1} -ora {z2} -sta {z1} -//FRAGMENT vwuz1_lt_vbuc1_then_la1 -lda {z1}+1 -bne !+ -lda {z1} -cmp #{c1} -bcc {la1} -!: -//FRAGMENT vwuz1=vwuz2_minus_vbuc1 -sec -lda {z2} -sbc #{c1} -sta {z1} -lda {z2}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT vwuz1_gt_vwuc1_then_la1 -lda #>{c1} -cmp {z1}+1 -bcc {la1} -bne !+ -lda #<{c1} -cmp {z1} -bcc {la1} -!: -//FRAGMENT vwuz1=vwuz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -sta {c1} -//FRAGMENT vbuz1=vbuz2_ror_1 -lda {z2} -lsr -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuz3 -ldx {z1} -ldy {z3} -lda ({z2}),y -sta {c1},x -//FRAGMENT vbuz1=pbuz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -sta {z1} -//FRAGMENT 0_neq_pbuc1_derefidx_vbuz1_then_la1 -ldy {z1} -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_pbuc2_derefidx_vbuz1 -lda {c1} -ldy {z1} -and {c2},y -sta {c1} -//FRAGMENT vbuz1=vbuz2_plus_1 -ldy {z2} -iny -sty {z1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_pbuc2_derefidx_vbuz1 -lda {c1} -ldy {z1} -ora {c2},y -sta {c1} -//FRAGMENT _deref_pbuz1_neq_0_then_la1 -ldy #0 -lda ({z1}),y -cmp #0 -bne {la1} -//FRAGMENT vwuz1_le_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne !+ -lda {z1} -cmp #<{c1} -!: -bcc {la1} -beq {la1} -//FRAGMENT pssz1=pssz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pssz1_eq_pssz2_then_la1 -lda {z1} -cmp {z2} -bne !+ -lda {z1}+1 -cmp {z2}+1 -beq {la1} -!: -//FRAGMENT pbuc1_derefidx_vbuz1_le_vbuz2_then_la1 -lda {z2} -ldy {z1} -cmp {c1},y -bcs {la1} -//FRAGMENT pbuz1_derefidx_vbuc1=vbuz2 -lda {z2} -ldy #{c1} -sta ({z1}),y -//FRAGMENT vbuz1=vbuz1_plus_1 -inc {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=_deref_pbuc2 -lda {c2} -ldy {z1} -sta {c1},y -//FRAGMENT vbuz1_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuz2)_then_la1 -lda {z1} -ldx {z2} -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -sta {c1},y -//FRAGMENT vbuz1_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuz2)_then_la1 -lda {z1} -ldx {z2} -ldy {c2},x -cmp {c1},y -bcc {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=pbuz3_derefidx_vbuz2 -ldy {z2} -lda ({z3}),y -sta ({z1}),y -//FRAGMENT vbuaa=vbuc1_minus_vbuz1 -lda #{c1} -sec -sbc {z1} -//FRAGMENT vbuxx=vbuc1_minus_vbuz1 -lda #{c1} -sec -sbc {z1} -tax -//FRAGMENT vbuyy=vbuc1_minus_vbuz1 -lda #{c1} -sec -sbc {z1} -tay -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuz1 -ldx {z1} -tay -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuz1 -ldx {z1} -lda {c2},x -sta {c1},y -//FRAGMENT vbuaa=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -tay -//FRAGMENT vbuz1=vbuxx_ror_1 -txa -lsr -sta {z1} -//FRAGMENT vbuz1=vbuyy_ror_1 -tya -lsr -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_1 -lda {z1} -lsr -//FRAGMENT vbuaa=vbuxx_ror_1 -txa -lsr -//FRAGMENT vbuaa=vbuyy_ror_1 -tya -lsr -//FRAGMENT vbuxx=vbuz1_ror_1 -lda {z1} -lsr -tax -//FRAGMENT vbuxx=vbuyy_ror_1 -tya -lsr -tax -//FRAGMENT vbuyy=vbuz1_ror_1 -lda {z1} -lsr -tay -//FRAGMENT vbuyy=vbuxx_ror_1 -txa -lsr -tay -//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuz2 -tya -ldy {z2} -tax -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuxx -txa -ldx {z1} -tay -lda ({z2}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuxx -sty $ff -txa -tay -lda ({z1}),y -ldy $ff -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuyy -lda ({z2}),y -ldx {z1} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuyy -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuyy -lda ({z1}),y -sta {c1},y -//FRAGMENT vbuz1=pbuz2_derefidx_vbuaa -tay -lda ({z2}),y -sta {z1} -//FRAGMENT vbuz1=pbuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta {z1} -//FRAGMENT vbuz1=pbuz2_derefidx_vbuyy -lda ({z2}),y -sta {z1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuyy -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuyy -lda ({z1}),y -tay -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuaa -tay -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuaa -tay -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuaa -tax -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuxx -lda {c2},x -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuxx -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuyy -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuyy -lda {c2},y -sta {c1},y -//FRAGMENT 0_neq_pbuc1_derefidx_vbuxx_then_la1 -lda {c1},x -cmp #0 -bne {la1} -//FRAGMENT 0_neq_pbuc1_derefidx_vbuyy_then_la1 -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_pbuc2_derefidx_vbuxx -lda {c1} -and {c2},x -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_pbuc2_derefidx_vbuyy -lda {c1} -and {c2},y -sta {c1} -//FRAGMENT vbuaa=vbuz1_plus_1 -lda {z1} -clc -adc #1 -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_pbuc2_derefidx_vbuxx -lda {c1} -ora {c2},x -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_pbuc2_derefidx_vbuyy -lda {c1} -ora {c2},y -sta {c1} -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuaa -tay -lda {c2},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuxx -tay -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuyy -tax -lda {c2},y -sta {c1},x -//FRAGMENT vbuaa=vbuc1_plus_vbuxx -txa -clc -adc #{c1} -//FRAGMENT vbuaa=vbuc1_plus_vbuyy -tya -clc -adc #{c1} -//FRAGMENT vbuxx=vbuxx_plus_vbuc1 -txa -axs #-[{c1}] -//FRAGMENT vbuyy=vbuyy_plus_vbuc1 -tya -clc -adc #{c1} -tay -//FRAGMENT pbuc1_derefidx_vbuaa_le_vbuz1_then_la1 -tay -lda {z1} -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_le_vbuz1_then_la1 -txa -tay -lda {z1} -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_le_vbuz1_then_la1 -lda {z1} -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_le_vbuxx_then_la1 -ldy {z1} -txa -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_le_vbuxx_then_la1 -tay -txa -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_le_vbuxx_then_la1 -txa -tay -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_le_vbuxx_then_la1 -txa -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_le_vbuyy_then_la1 -tya -ldy {z1} -cmp {c1},y -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_le_vbuyy_then_la1 -tax -lda {c1},x -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_le_vbuyy_then_la1 -lda {c1},x -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_le_vbuyy_then_la1 -tya -cmp {c1},y -bcs {la1} -//FRAGMENT pbuz1_derefidx_vbuc1=vbuxx -ldy #{c1} -txa -sta ({z1}),y -//FRAGMENT vbuz1=vbuxx_plus_1 -inx -stx {z1} -//FRAGMENT pbuc1_derefidx_vbuaa=_deref_pbuc2 -tay -lda {c2} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=_deref_pbuc2 -lda {c2} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=_deref_pbuc2 -lda {c2} -sta {c1},y -//FRAGMENT vbuaa_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuz1)_then_la1 -ldx {z1} -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuxx_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuz1)_then_la1 -ldy {z1} -txa -ldx {c2},y -cmp {c1},x -bcs {la1} -//FRAGMENT vbuyy_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuz1)_then_la1 -ldx {z1} -tya -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuz1_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuaa)_then_la1 -tax -lda {z1} -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuaa_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuaa)_then_la1 -tax -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuxx_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuaa)_then_la1 -tay -txa -ldx {c2},y -cmp {c1},x -bcs {la1} -//FRAGMENT vbuyy_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuaa)_then_la1 -tax -tya -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuz1_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -lda {z1} -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuaa_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuxx_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -txa -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuyy_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -tya -ldy {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuz1_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -lda {z1} -ldx {c2},y -cmp {c1},x -bcs {la1} -//FRAGMENT vbuz1_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -lda {z1} -ldy {c2},x -cmp {c1},y -bcc {la1} -//FRAGMENT vbuz1_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -lda {z1} -ldx {c2},y -cmp {c1},x -bcc {la1} -//FRAGMENT vbuxx_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuz1)_then_la1 -ldy {z1} -txa -ldx {c2},y -cmp {c1},x -bcc {la1} -//FRAGMENT vbuxx_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -txa -ldy {c2},x -cmp {c1},y -bcc {la1} -//FRAGMENT vbuxx_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -txa -ldx {c2},y -cmp {c1},x -bcc {la1} -//FRAGMENT vbuyy_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuz1)_then_la1 -ldx {z1} -tya -ldy {c2},x -cmp {c1},y -bcc {la1} -//FRAGMENT vbuyy_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuxx)_then_la1 -tya -ldy {c2},x -cmp {c1},y -bcc {la1} -//FRAGMENT vbuyy_lt_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -tya -ldx {c2},y -cmp {c1},x -bcc {la1} -//FRAGMENT vbuaa_lt_vbuz1_then_la1 -cmp {z1} -bcc {la1} -//FRAGMENT pbuz1_derefidx_vbuaa=pbuz2_derefidx_vbuaa -tay -lda ({z2}),y -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuz2_derefidx_vbuyy -lda ({z2}),y -sta ({z1}),y -//FRAGMENT vbuxx_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -txa -ldx {c2},y -cmp {c1},x -bcs {la1} -//FRAGMENT vbuyy_ge_pbuc1_derefidx_(pbuc2_derefidx_vbuyy)_then_la1 -tya -ldx {c2},y -cmp {c1},x -bcs {la1} -//FRAGMENT vbuxx=vbuxx_plus_1 -inx -//FRAGMENT vbuyy_lt_vbuz1_then_la1 -cpy {z1} -bcc {la1} -//FRAGMENT vbuxx=vbuc1_plus_vbuxx -txa -axs #-[{c1}] -//FRAGMENT vbuxx=vbuc1_plus_vbuyy -tya -tax -axs #-[{c1}] -//FRAGMENT vbuyy=vbuc1_plus_vbuaa -clc -adc #{c1} -tay -//FRAGMENT vbuyy=vbuc1_plus_vbuxx -txa -clc -adc #{c1} -tay -//FRAGMENT vbuyy=vbuc1_plus_vbuyy -tya -clc -adc #{c1} -tay -//FRAGMENT vbuxx=vbuz1_plus_1 -ldx {z1} -inx -//FRAGMENT vbuyy=vbuz1_plus_1 -ldy {z1} -iny -//FRAGMENT vbuyy=_lo_vwuz1 -ldy {z1} -//FRAGMENT vbuaa=vbuxx_plus_1 -inx -txa -//FRAGMENT vbuaa=vbuyy_plus_1 -iny -tya -//FRAGMENT vwuz1=vwuz1_ror_3 -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT pprz1=pprc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 //FRAGMENT _deref_pwsc1=vbsc2 NO_SYNTHESIS //FRAGMENT _deref_pwsc1=vwuc2 @@ -4517,6 +1515,15 @@ bvc !+ eor #$80 !: bmi {la1} +//FRAGMENT vduz1=vduz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +lda {z2}+2 +sta {z1}+2 +lda {z2}+3 +sta {z1}+3 //FRAGMENT vwsz1_ge_0_then_la1 lda {z1}+1 bpl {la1} @@ -4538,6 +1545,56 @@ lda {z2} sta {z1}+2 lda {z2}+1 sta {z1}+3 +//FRAGMENT vduz1=_dword_vwuz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +lda #0 +sta {z1}+2 +sta {z1}+3 +//FRAGMENT vduz1=vduc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +lda #<{c1}>>$10 +sta {z1}+2 +lda #>{c1}>>$10 +sta {z1}+3 +//FRAGMENT vwuz1_neq_0_then_la1 +lda {z1} +ora {z1}+1 +bne {la1} +//FRAGMENT vbuz1=vwuz2_band_vbuc1 +lda #{c1} +and {z2} +sta {z1} +//FRAGMENT vbuz1_eq_0_then_la1 +lda {z1} +beq {la1} +//FRAGMENT vduz1=vduz1_plus_vduz2 +lda {z1} +clc +adc {z2} +sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 +lda {z1}+2 +adc {z2}+2 +sta {z1}+2 +lda {z1}+3 +adc {z2}+3 +sta {z1}+3 +//FRAGMENT vwuz1=vwuz1_ror_1 +lsr {z1}+1 +ror {z1} +//FRAGMENT vduz1=vduz1_rol_1 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 //FRAGMENT vwsz1=_neg_vwsz2 sec lda #0 @@ -4550,6 +1607,56 @@ sta {z1}+1 lda #{c1} eor {z1} sta {z1} +//FRAGMENT vbuz1=_byte_vwuz2 +lda {z2} +sta {z1} +//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1=_inc_pbuz2 +clc +lda {z2} +adc #1 +sta {z1} +lda {z2}+1 +adc #0 +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +//FRAGMENT 0_neq_vbuz1_then_la1 +lda {z1} +bne {la1} +//FRAGMENT vwuz1_ge_vwuz2_then_la1 +lda {z2}+1 +cmp {z1}+1 +bne !+ +lda {z2} +cmp {z1} +beq {la1} +!: +bcc {la1} +//FRAGMENT 0_neq__deref_pbuz1_then_la1 +ldy #0 +lda ({z1}),y +cmp #0 +bne {la1} +//FRAGMENT vbuz1=_deref_pbuz2 +ldy #0 +lda ({z2}),y +sta {z1} +//FRAGMENT vwuz1=vwuz1_rol_1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=vwuz1_bor_vbuc1 +lda #{c1} +ora {z1} +sta {z1} //FRAGMENT vwuz1_lt_vwuz2_then_la1 lda {z1}+1 cmp {z2}+1 @@ -4559,6 +1666,103 @@ lda {z1} cmp {z2} bcc {la1} !: +//FRAGMENT vwuz1=_inc_vwuz1 +inc {z1} +bne !+ +inc {z1}+1 +!: +//FRAGMENT vwuz1=vwuz1_minus_vwuz2 +lda {z1} +sec +sbc {z2} +sta {z1} +lda {z1}+1 +sbc {z2}+1 +sta {z1}+1 +//FRAGMENT vbuaa=vwuz1_band_vbuc1 +lda #{c1} +and {z1} +//FRAGMENT vbuxx=vwuz1_band_vbuc1 +lda #{c1} +and {z1} +tax +//FRAGMENT vbuyy=vwuz1_band_vbuc1 +lda #{c1} +and {z1} +tay +//FRAGMENT vbuaa_eq_0_then_la1 +cmp #0 +beq {la1} +//FRAGMENT vbuxx_eq_0_then_la1 +cpx #0 +beq {la1} +//FRAGMENT vbuxx=vbuxx_bxor_vbuc1 +txa +eor #{c1} +tax +//FRAGMENT vbuyy=vbuyy_bxor_vbuc1 +tya +eor #{c1} +tay +//FRAGMENT vbuaa=_byte_vwuz1 +lda {z1} +//FRAGMENT vbuxx=_byte_vwuz1 +lda {z1} +tax +//FRAGMENT vbuyy=_byte_vwuz1 +lda {z1} +tay +//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuaa +tay +lda {c1},y +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuxx +lda {c1},x +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuyy +lda {c1},y +ldy #0 +sta ({z1}),y +//FRAGMENT vwuz1=pwuc1_derefidx_vbuaa +tay +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx +lda {c1},x +sta {z1} +lda {c1}+1,x +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +//FRAGMENT 0_neq_vbuxx_then_la1 +cpx #0 +bne {la1} +//FRAGMENT vbuaa=_deref_pbuz1 +ldy #0 +lda ({z1}),y +//FRAGMENT vbuxx=_deref_pbuz1 +ldy #0 +lda ({z1}),y +tax +//FRAGMENT vbuyy=_deref_pbuz1 +ldy #0 +lda ({z1}),y +tay +//FRAGMENT vbuyy=_hi_vwuz1 +ldy {z1}+1 +//FRAGMENT vbuyy_eq_0_then_la1 +cpy #0 +beq {la1} +//FRAGMENT 0_neq_vbuyy_then_la1 +cpy #0 +bne {la1} //FRAGMENT pwsz1=pwsc1_plus_vwsz1 clc lda {z1} @@ -4576,6 +1780,1416 @@ lda ({z1}),y sta {z1}+1 pla sta {z1} +//FRAGMENT pbuz1_lt_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT _deref_pbuz1=_inc__deref_pbuz1 +ldy #0 +lda ({z1}),y +clc +adc #1 +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1_lt_pbuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT vbuxx=vbuxx_plus_vbuc1 +txa +axs #-[{c1}] +//FRAGMENT vbuyy=vbuyy_plus_vbuc1 +tya +clc +adc #{c1} +tay +//FRAGMENT _deref_pbuz1=_deref_pbuz2 +ldy #0 +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT vbuz1_neq_vbuz2_then_la1 +lda {z1} +cmp {z2} +bne {la1} +//FRAGMENT vbuz1_gt_vbuz2_then_la1 +lda {z2} +cmp {z1} +bcc {la1} +//FRAGMENT vbuz1=vbuz1_minus_vbuz2 +lda {z1} +sec +sbc {z2} +sta {z1} +//FRAGMENT vbuz1=vbuyy_ror_4 +tya +lsr +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbuaa=vbuyy_ror_4 +tya +lsr +lsr +lsr +lsr +//FRAGMENT vbuxx=vbuyy_ror_4 +tya +lsr +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=vbuyy_ror_4 +tya +lsr +lsr +lsr +lsr +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy +lda {c1},y +sta {z1} +//FRAGMENT vbuz1_neq_vbuaa_then_la1 +cmp {z1} +bne {la1} +//FRAGMENT vbuz1_gt_vbuaa_then_la1 +cmp {z1} +bcc {la1} +//FRAGMENT vbuaa=vbuaa_minus_vbuz1 +sec +sbc {z1} +//FRAGMENT vbuxx=vbuxx_minus_vbuz1 +txa +sec +sbc {z1} +tax +//FRAGMENT vbuyy=vbuyy_minus_vbuz1 +tya +sec +sbc {z1} +tay +//FRAGMENT vbuz1=vbuz1_minus_vbuaa +eor #$ff +sec +adc {z1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_minus_vbuaa +lda #0 +//FRAGMENT vbuxx=vbuxx_minus_vbuaa +sta $ff +txa +sec +sbc $ff +tax +//FRAGMENT vbuyy=vbuyy_minus_vbuaa +sta $ff +tya +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuz1_minus_vbuxx +txa +eor #$ff +sec +adc {z1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_minus_vbuxx +stx $ff +sec +sbc $ff +//FRAGMENT vbuxx=vbuxx_minus_vbuxx +lda #0 +tax +//FRAGMENT vbuyy=vbuyy_minus_vbuxx +tya +stx $ff +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuz1_minus_vbuyy +tya +eor #$ff +sec +adc {z1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_minus_vbuyy +sty $ff +sec +sbc $ff +//FRAGMENT vbuxx=vbuxx_minus_vbuyy +txa +sty $ff +sec +sbc $ff +tax +//FRAGMENT vbuyy=vbuyy_minus_vbuyy +lda #0 +tay +//FRAGMENT vbuz1_neq_vbuxx_then_la1 +cpx {z1} +bne {la1} +//FRAGMENT vbuz1_gt_vbuxx_then_la1 +cpx {z1} +bcc {la1} +//FRAGMENT vbuz1_neq_vbuyy_then_la1 +cpy {z1} +bne {la1} +//FRAGMENT vbuz1_gt_vbuyy_then_la1 +cpy {z1} +bcc {la1} +//FRAGMENT vbuxx_neq_vbuz1_then_la1 +cpx {z1} +bne {la1} +//FRAGMENT vbuxx_gt_vbuz1_then_la1 +cpx {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT vbuxx_neq_vbuyy_then_la1 +stx $ff +cpy $ff +bne {la1} +//FRAGMENT vbuxx_gt_vbuyy_then_la1 +stx $ff +cpy $ff +bcc {la1} +//FRAGMENT vbuyy_neq_vbuz1_then_la1 +cpy {z1} +bne {la1} +//FRAGMENT vbuyy_gt_vbuz1_then_la1 +cpy {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT vbuyy_neq_vbuxx_then_la1 +stx $ff +cpy $ff +bne {la1} +//FRAGMENT vbuyy_gt_vbuxx_then_la1 +sty $ff +cpx $ff +bcc {la1} +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz2 +ldy {z2} +lda {c2},y +ldy {z1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuaa +tay +lda {c2},y +ldy {z1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuxx +lda {c2},x +ldy {z1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuyy +lda {c2},y +ldy {z1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuz1 +ldx {z1} +tay +lda {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuaa +tay +lda {c2},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuxx +tay +lda {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuyy +tax +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuaa +tay +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuxx +lda {c2},x +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuyy +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuz1 +ldx {z1} +lda {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuaa +tax +lda {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuxx +lda {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuyy +lda {c2},y +sta {c1},y +//FRAGMENT vwuz1=_deref_pwuc1_minus_vwuc2 +sec +lda {c1} +sbc #<{c2} +sta {z1} +lda {c1}+1 +sbc #>{c2} +sta {z1}+1 +//FRAGMENT _deref_pwuc1=vwuz1 +lda {z1} +sta {c1} +lda {z1}+1 +sta {c1}+1 +//FRAGMENT pbuz1=_deref_qbuc1_plus_vwuc2 +clc +lda {c1} +adc #<{c2} +sta {z1} +lda {c1}+1 +adc #>{c2} +sta {z1}+1 +//FRAGMENT _deref_qbuc1=pbuz1 +lda {z1} +sta {c1} +lda {z1}+1 +sta {c1}+1 +//FRAGMENT vbuz1_neq_0_then_la1 +lda {z1} +bne {la1} +//FRAGMENT vbuaa_neq_0_then_la1 +cmp #0 +bne {la1} +//FRAGMENT vbuxx_neq_0_then_la1 +cpx #0 +bne {la1} +//FRAGMENT vbuyy_neq_0_then_la1 +cpy #0 +bne {la1} +//FRAGMENT _deref_pbuc1=_inc__deref_pbuc1 +inc {c1} +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c2},y +sta {c1},y +//FRAGMENT 0_neq_pbuc1_derefidx_vbuz1_then_la1 +ldy {z1} +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuz3 +ldy {z3} +lda {c1},y +ldy {z2} +sta ({z1}),y +//FRAGMENT 0_neq_pbuc1_derefidx_vbuaa_then_la1 +tay +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT 0_neq_pbuc1_derefidx_vbuxx_then_la1 +lda {c1},x +cmp #0 +bne {la1} +//FRAGMENT 0_neq_pbuc1_derefidx_vbuyy_then_la1 +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuz2 +txa +ldx {z2} +tay +lda {c1},x +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuz2 +ldx {z2} +lda {c1},x +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuxx +lda {c1},x +ldy {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuxx +txa +tay +lda {c1},y +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuxx +lda {c1},x +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuyy +lda {c1},y +ldy {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuyy +lda {c1},y +stx $ff +ldy $ff +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuyy +lda {c1},y +sta ({z1}),y +//FRAGMENT vbuyy=vbuyy_plus_2 +iny +iny +//FRAGMENT vwsz1=_sword_vbuz2 +lda {z2} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwsz1=vwsz1_rol_1 +asl {z1} +rol {z1}+1 +//FRAGMENT _stackpushbyte_=vbuc1 +lda #{c1} +pha +//FRAGMENT _stackpullbyte_1 +pla +//FRAGMENT vbuz1=_stackpullbyte_ +pla +sta {z1} +//FRAGMENT _deref_pbuc1=vbuz1 +lda {z1} +sta {c1} +//FRAGMENT vbuz1=_stackidxbyte_vbuc1 +tsx +lda STACK_BASE+{c1},x +sta {z1} +//FRAGMENT vbuz1=vbuz2_plus_vbuz3 +lda {z2} +clc +adc {z3} +sta {z1} +//FRAGMENT _stackidxbyte_vbuc1=vbuz1 +lda {z1} +tsx +sta STACK_BASE+{c1},x +//FRAGMENT vbuaa=_stackpullbyte_ +pla +//FRAGMENT vbuxx=_stackpullbyte_ +pla +tax +//FRAGMENT vbuyy=_stackpullbyte_ +pla +tay +//FRAGMENT _deref_pbuc1=vbuaa +sta {c1} +//FRAGMENT vbuaa=_stackidxbyte_vbuc1 +tsx +lda STACK_BASE+{c1},x +//FRAGMENT vbuxx=_stackidxbyte_vbuc1 +tsx +lda STACK_BASE+{c1},x +tax +//FRAGMENT vbuyy=_stackidxbyte_vbuc1 +tsx +lda STACK_BASE+{c1},x +tay +//FRAGMENT vbuaa=vbuz1_plus_vbuz2 +lda {z1} +clc +adc {z2} +//FRAGMENT vbuxx=vbuz1_plus_vbuz2 +lda {z1} +clc +adc {z2} +tax +//FRAGMENT vbuyy=vbuz1_plus_vbuz2 +lda {z1} +clc +adc {z2} +tay +//FRAGMENT vbuz1=vbuyy_plus_vbuz2 +tya +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_vbuz1 +tya +clc +adc {z1} +//FRAGMENT vbuxx=vbuyy_plus_vbuz1 +tya +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuyy_plus_vbuz1 +tya +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuz2_plus_vbuaa +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_vbuaa +clc +adc {z1} +//FRAGMENT vbuxx=vbuz1_plus_vbuaa +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_plus_vbuaa +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuyy_plus_vbuaa +sty $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_vbuaa +sty $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuyy_plus_vbuaa +sty $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuyy_plus_vbuaa +sty $ff +clc +adc $ff +tay +//FRAGMENT vbuz1=vbuz2_plus_vbuxx +txa +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_vbuxx +txa +clc +adc {z1} +//FRAGMENT vbuxx=vbuz1_plus_vbuxx +txa +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_plus_vbuxx +txa +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuyy_plus_vbuxx +txa +sty $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_vbuxx +txa +sty $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuyy_plus_vbuxx +txa +sty $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuyy_plus_vbuxx +txa +sty $ff +clc +adc $ff +tay +//FRAGMENT vbuz1=vbuz2_plus_vbuyy +tya +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_vbuyy +tya +clc +adc {z1} +//FRAGMENT vbuxx=vbuz1_plus_vbuyy +tya +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_plus_vbuyy +tya +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuyy_plus_vbuyy +tya +asl +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_vbuyy +tya +asl +//FRAGMENT vbuxx=vbuyy_plus_vbuyy +tya +asl +tax +//FRAGMENT vbuyy=vbuyy_plus_vbuyy +tya +asl +tay +//FRAGMENT _stackidxbyte_vbuc1=vbuaa +tsx +sta STACK_BASE+{c1},x +//FRAGMENT _stackidxbyte_vbuc1=vbuxx +txa +tsx +sta STACK_BASE+{c1},x +//FRAGMENT _stackidxbyte_vbuc1=vbuyy +tya +tsx +sta STACK_BASE+{c1},x +//FRAGMENT vbuz1=vbuaa_plus_vbuz2 +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuaa_plus_vbuz1 +clc +adc {z1} +//FRAGMENT vbuxx=vbuaa_plus_vbuz1 +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuaa_plus_vbuz1 +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuxx_plus_vbuz2 +txa +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_vbuz1 +txa +clc +adc {z1} +//FRAGMENT vbuxx=vbuxx_plus_vbuz1 +txa +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuxx_plus_vbuz1 +txa +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuaa_plus_vbuaa +asl +sta {z1} +//FRAGMENT vbuaa=vbuaa_plus_vbuaa +asl +//FRAGMENT vbuxx=vbuaa_plus_vbuaa +asl +tax +//FRAGMENT vbuyy=vbuaa_plus_vbuaa +asl +tay +//FRAGMENT vbuz1=vbuxx_plus_vbuaa +stx $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_vbuaa +stx $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuxx_plus_vbuaa +stx $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuxx_plus_vbuaa +stx $ff +clc +adc $ff +tay +//FRAGMENT vbuz1=vbuaa_plus_vbuxx +stx $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuaa_plus_vbuxx +stx $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuaa_plus_vbuxx +stx $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuaa_plus_vbuxx +stx $ff +clc +adc $ff +tay +//FRAGMENT vbuz1=vbuxx_plus_vbuxx +txa +asl +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_vbuxx +txa +asl +//FRAGMENT vbuxx=vbuxx_plus_vbuxx +txa +asl +tax +//FRAGMENT vbuyy=vbuxx_plus_vbuxx +txa +asl +tay +//FRAGMENT vbuz1=vbuaa_plus_vbuyy +sty $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuaa_plus_vbuyy +sty $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuaa_plus_vbuyy +sty $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuaa_plus_vbuyy +sty $ff +clc +adc $ff +tay +//FRAGMENT vbuz1=vbuxx_plus_vbuyy +txa +sty $ff +clc +adc $ff +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_vbuyy +txa +sty $ff +clc +adc $ff +//FRAGMENT vbuxx=vbuxx_plus_vbuyy +txa +sty $ff +clc +adc $ff +tax +//FRAGMENT vbuyy=vbuxx_plus_vbuyy +txa +sty $ff +clc +adc $ff +tay +//FRAGMENT _deref_pbuc1=vbuxx +stx {c1} +//FRAGMENT _deref_pbuc1=vbuyy +sty {c1} +//FRAGMENT vbuz1=vbuz1_plus_1 +inc {z1} +//FRAGMENT vbuaa=vbuaa_plus_1 +clc +adc #1 +//FRAGMENT vbuxx=vbuxx_plus_1 +inx +//FRAGMENT vbuyy=vbuyy_plus_1 +iny +//FRAGMENT vbuz1=_dec_vbuz1 +dec {z1} +//FRAGMENT vbuz1_gt_0_then_la1 +lda {z1} +bne {la1} +//FRAGMENT vbuaa_gt_0_then_la1 +cmp #0 +bne {la1} +//FRAGMENT vbuaa=_dec_vbuaa +sec +sbc #1 +//FRAGMENT vbuxx=_dec_vbuxx +dex +//FRAGMENT vbuxx_gt_0_then_la1 +cpx #0 +bne {la1} +//FRAGMENT vbuyy=_dec_vbuyy +dey +//FRAGMENT vbuyy_gt_0_then_la1 +cpy #0 +bne {la1} +//FRAGMENT vwuz1=_word_vbuz2 +lda {z2} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_rol_2 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=vwuz2_plus_vwuz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_rol_3 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vwuz2 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuz2=vbuz3 +lda {z3} +ldy {z2} +sta ({z1}),y +//FRAGMENT vwuz1=_word_vbuaa +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=_word_vbuxx +txa +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=_word_vbuyy +tya +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuz2=vbuaa +ldy {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2=vbuxx +ldy {z2} +txa +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2=vbuyy +tya +ldy {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=vbuz2 +txa +tay +lda {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=vbuxx +txa +tay +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=vbuyy +stx $ff +tya +ldy $ff +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=vbuz2 +lda {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=vbuaa +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=vbuxx +txa +sta ({z1}),y +//FRAGMENT vwuz1=vwuz2_plus_vwuz1 +lda {z1} +clc +adc {z2} +sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vwuz1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vwuz1=vwuz1_rol_3 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT 0_eq_vbuz1_then_la1 +lda {z1} +beq {la1} +//FRAGMENT vbuz1=vbuz2_plus_1 +ldy {z2} +iny +sty {z1} +//FRAGMENT pbuz1_derefidx_vbuz2=vbuc1 +lda #{c1} +ldy {z2} +sta ({z1}),y +//FRAGMENT 0_eq_vbuaa_then_la1 +cmp #0 +beq {la1} +//FRAGMENT vbuz1=vbuaa_plus_1 +clc +adc #1 +sta {z1} +//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuaa +tay +lda {c1},y +ldy {z2} +sta ({z1}),y +//FRAGMENT vbuz1=vbuxx_plus_1 +inx +stx {z1} +//FRAGMENT 0_eq_vbuxx_then_la1 +cpx #0 +beq {la1} +//FRAGMENT 0_eq_vbuyy_then_la1 +cpy #0 +beq {la1} +//FRAGMENT vbuz1=_lo_vwsz2 +lda {z2} +sta {z1} +//FRAGMENT vbuaa=_lo_vwsz1 +lda {z1} +//FRAGMENT vbuxx=_lo_vwsz1 +ldx {z1} +//FRAGMENT vbuyy=_lo_vwsz1 +ldy {z1} +//FRAGMENT vbuz1_ge_vbuc1_then_la1 +lda {z1} +cmp #{c1} +bcs {la1} +//FRAGMENT vbuaa_ge_vbuc1_then_la1 +cmp #{c1} +bcs {la1} +//FRAGMENT vbuxx_ge_vbuc1_then_la1 +cpx #{c1} +bcs {la1} +//FRAGMENT vbuyy_ge_vbuc1_then_la1 +cpy #{c1} +bcs {la1} +//FRAGMENT pbuz1=pbuz2_plus_vbuc1 +lda #{c1} +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuaa=vbuz2 +tay +lda {z2} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa=vbuaa +tay +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa=vbuxx +tay +txa +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa=vbuyy +sta $ff +tya +ldy $ff +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=vbuyy +tya +sta ({z1}),y +//FRAGMENT _deref_pbuz1_eq_vbuz2_then_la1 +lda {z2} +ldy #0 +cmp ({z1}),y +beq {la1} +//FRAGMENT _deref_pbuz1_neq_0_then_la1 +ldy #0 +lda ({z1}),y +cmp #0 +bne {la1} +//FRAGMENT _deref_pbuz1_eq_vbuxx_then_la1 +txa +ldy #0 +cmp ({z1}),y +beq {la1} +//FRAGMENT _deref_pbuz1_eq_vbuyy_then_la1 +tya +ldy #0 +cmp ({z1}),y +beq {la1} +//FRAGMENT pbuz1=pbuc1_plus_vbuz2 +lda {z2} +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1=pbuz2_plus_vwuz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vbuaa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vbuxx +txa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1=pbuc1_plus_vbuyy +tya +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1=pbuz1_plus_vwuz2 +lda {z1} +clc +adc {z2} +sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT vbuz1=vbuz1_plus_vbuc1 +lax {z1} +axs #-[{c1}] +stx {z1} +//FRAGMENT vwuz1=vbuz2 +lda {z2} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT pwuc1_derefidx_vbuz1=vwuz2 +ldy {z1} +lda {z2} +sta {c1},y +lda {z2}+1 +sta {c1}+1,y +//FRAGMENT vbuz1=pwuc1_derefidx_vbuz2_band_vbuc2 +lda #{c2} +ldy {z2} +and {c1},y +sta {z1} +//FRAGMENT vbuz1=vbuz2_ror_1 +lda {z2} +lsr +sta {z1} +//FRAGMENT vwuz1=vbuaa +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vbuxx +txa +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vbuyy +tya +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT pwuc1_derefidx_vbuaa=vwuz1 +tay +lda {z1} +sta {c1},y +lda {z1}+1 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=vwuz1 +lda {z1} +sta {c1},x +lda {z1}+1 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=vwuz1 +lda {z1} +sta {c1},y +lda {z1}+1 +sta {c1}+1,y +//FRAGMENT vbuaa=pwuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldy {z1} +and {c1},y +//FRAGMENT vbuxx=pwuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldx {z1} +and {c1},x +tax +//FRAGMENT vbuyy=pwuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldy {z1} +and {c1},y +tay +//FRAGMENT vbuz1=pwuc1_derefidx_vbuaa_band_vbuc2 +tay +lda #{c2} +and {c1},y +sta {z1} +//FRAGMENT vbuaa=pwuc1_derefidx_vbuaa_band_vbuc2 +tay +lda #{c2} +and {c1},y +//FRAGMENT vbuxx=pwuc1_derefidx_vbuaa_band_vbuc2 +tax +lda #{c2} +and {c1},x +tax +//FRAGMENT vbuyy=pwuc1_derefidx_vbuaa_band_vbuc2 +tay +lda #{c2} +and {c1},y +tay +//FRAGMENT vbuz1=pwuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +sta {z1} +//FRAGMENT vbuaa=pwuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +//FRAGMENT vbuxx=pwuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +tax +//FRAGMENT vbuyy=pwuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +tay +//FRAGMENT vbuz1=pwuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +sta {z1} +//FRAGMENT vbuaa=pwuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +//FRAGMENT vbuxx=pwuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +tax +//FRAGMENT vbuyy=pwuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +tay +//FRAGMENT vbuaa=vbuz1_ror_1 +lda {z1} +lsr +//FRAGMENT vbuxx=vbuz1_ror_1 +lda {z1} +lsr +tax +//FRAGMENT vbuyy=vbuz1_ror_1 +lda {z1} +lsr +tay +//FRAGMENT vbuz1=vbuaa_ror_1 +lsr +sta {z1} +//FRAGMENT vbuaa=vbuaa_ror_1 +lsr +//FRAGMENT vbuxx=vbuaa_ror_1 +lsr +tax +//FRAGMENT vbuyy=vbuaa_ror_1 +lsr +tay +//FRAGMENT vbuz1=vbuxx_ror_1 +txa +lsr +sta {z1} +//FRAGMENT vbuaa=vbuxx_ror_1 +txa +lsr +//FRAGMENT vbuxx=vbuxx_ror_1 +txa +lsr +tax +//FRAGMENT vbuyy=vbuxx_ror_1 +txa +lsr +tay +//FRAGMENT vbuz1=vbuyy_ror_1 +tya +lsr +sta {z1} +//FRAGMENT vbuaa=vbuyy_ror_1 +tya +lsr +//FRAGMENT vbuxx=vbuyy_ror_1 +tya +lsr +tax +//FRAGMENT vbuyy=vbuyy_ror_1 +tya +lsr +tay +//FRAGMENT _deref_pbuc1_neq_vbuc2_then_la1 +lda #{c2} +cmp {c1} +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuz2 +ldx {z2} +tay +lda {c1},x +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuxx +tay +lda {c1},x +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuyy +ldx {c1},y +tay +txa +sta ({z1}),y +//FRAGMENT vwuz1=vbuz2_word_vbuz3 +lda {z2} +sta {z1}+1 +lda {z3} +sta {z1} +//FRAGMENT vwuz1=vbuaa_word_vbuz2 +sta {z1}+1 +lda {z2} +sta {z1} +//FRAGMENT vwuz1=vbuxx_word_vbuz2 +lda {z2} +stx {z1}+1 +sta {z1} +//FRAGMENT vwuz1=vbuyy_word_vbuz2 +lda {z2} +sty {z1}+1 +sta {z1} +//FRAGMENT vwuz1=vbuz2_word_vbuaa +ldy {z2} +sty {z1}+1 +sta {z1} +//FRAGMENT vwuz1=vbuxx_word_vbuaa +stx {z1}+1 +sta {z1} +//FRAGMENT vwuz1=vbuyy_word_vbuaa +sty {z1}+1 +sta {z1} +//FRAGMENT vwuz1=vbuz2_word_vbuxx +lda {z2} +sta {z1}+1 +stx {z1} +//FRAGMENT vwuz1=vbuaa_word_vbuxx +sta {z1}+1 +stx {z1} +//FRAGMENT vwuz1=vbuyy_word_vbuxx +sty {z1}+1 +stx {z1} +//FRAGMENT vwuz1=vbuz2_word_vbuyy +lda {z2} +sta {z1}+1 +sty {z1} +//FRAGMENT vwuz1=vbuaa_word_vbuyy +sta {z1}+1 +sty {z1} +//FRAGMENT vwuz1=vbuxx_word_vbuyy +stx {z1}+1 +sty {z1} +//FRAGMENT _deref_pbuc1=_dec__deref_pbuc1 +dec {c1} +//FRAGMENT vbuz1_lt_vbuz2_then_la1 +lda {z1} +cmp {z2} +bcc {la1} +//FRAGMENT vbuz1_lt_vbuaa_then_la1 +cmp {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT vbuaa_lt_vbuz1_then_la1 +cmp {z1} +bcc {la1} +//FRAGMENT vbuxx_lt_vbuz1_then_la1 +cpx {z1} +bcc {la1} +//FRAGMENT vbuxx_lt_vbuaa_then_la1 +sta $ff +cpx $ff +bcc {la1} +//FRAGMENT vbuz1_lt_vbuxx_then_la1 +cpx {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT vbuaa_lt_vbuxx_then_la1 +stx $ff +cmp $ff +bcc {la1} +//FRAGMENT vbuz1=vbuz1_plus_vbuz2 +lda {z1} +clc +adc {z2} +sta {z1} +//FRAGMENT vbuz1=vbuz1_plus_vbuaa +clc +adc {z1} +sta {z1} +//FRAGMENT vbuz1=vbuz1_plus_vbuxx +txa +clc +adc {z1} +sta {z1} +//FRAGMENT vbuz1=vbuz1_plus_vbuyy +tya +clc +adc {z1} +sta {z1} +//FRAGMENT pbuz1_derefidx_vbuaa=vbuc1 +tay +lda #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=vbuc1 +txa +tay +lda #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=vbuc1 +lda #{c1} +sta ({z1}),y +//FRAGMENT _deref_pboc1=vboc2 +lda #{c2} +sta {c1} +//FRAGMENT _deref_pboc1_then_la1 +lda {c1} +cmp #0 +bne {la1} +//FRAGMENT vboz1=vboc1 +lda #{c1} +sta {z1} +//FRAGMENT vboaa=vboc1 +lda #{c1} +//FRAGMENT vboxx=vboc1 +lda #{c1} +tax +//FRAGMENT vboyy=vboc1 +lda #{c1} +tay +//FRAGMENT _deref_pbuc1_lt_vbuc2_then_la1 +lda {c1} +cmp #{c2} +bcc {la1} +//FRAGMENT pbuz1_ge_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc !+ +bne {la1} +lda {z1} +cmp #<{c1} +bcs {la1} +!: +//FRAGMENT _deref_pbuz1_neq_vbuc1_then_la1 +ldy #0 +lda ({z1}),y +cmp #{c1} +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuz2_eq_vbuc1_then_la1 +lda #{c1} +ldy {z2} +cmp ({z1}),y +beq {la1} +//FRAGMENT pbuz1_derefidx_vbuaa_eq_vbuc1_then_la1 +tay +lda #{c1} +cmp ({z1}),y +beq {la1} +//FRAGMENT pbuz1_derefidx_vbuxx_eq_vbuc1_then_la1 +txa +tay +lda #{c1} +cmp ({z1}),y +beq {la1} +//FRAGMENT pbuz1_derefidx_vbuyy_eq_vbuc1_then_la1 +lda #{c1} +cmp ({z1}),y +beq {la1} +//FRAGMENT vbuz1_eq_vbuz2_then_la1 +lda {z1} +cmp {z2} +beq {la1} +//FRAGMENT vbuz1_eq_vbuaa_then_la1 +cmp {z1} +beq {la1} +//FRAGMENT vbuz1_eq_vbuyy_then_la1 +tya +cmp {z1} +beq {la1} +//FRAGMENT vbuyy_eq_vbuz1_then_la1 +tya +cmp {z1} +beq {la1} +//FRAGMENT vbuyy_eq_vbuaa_then_la1 +tax +sty $ff +cpx $ff +beq {la1} +//FRAGMENT isr_hardware_all_entry +sta rega+1 @clob_a +stx regx+1 @clob_x +sty regy+1 @clob_y +//FRAGMENT isr_hardware_all_exit +rega: @clob_a @nooptimize lda #0 @clob_a @nooptimize +regx: @clob_x @nooptimize ldx #0 @clob_x @nooptimize +regy: @clob_y @nooptimize ldy #0 @clob_y @nooptimize +rti +//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 +lda #{c2} +ora {c1} +sta {c1} +//FRAGMENT _deref_qprc1=pprc2 +lda #<{c2} +sta {c1} +lda #>{c2} +sta {c1}+1 +//FRAGMENT isr_rom_min_c64_entry + +//FRAGMENT isr_rom_min_c64_exit +jmp $ea81 +//FRAGMENT pprz1=pprc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 //FRAGMENT pprz1=pprz2 lda {z2} sta {z1} @@ -4603,32 +3217,6 @@ lda {c1},y sta {z1} lda {c1}+1,y sta {z1}+1 -//FRAGMENT pbuz1_lt_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: -//FRAGMENT _deref_pbuz1=_inc__deref_pbuz1 -ldy #0 -lda ({z1}),y -clc -adc #1 -ldy #0 -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuaa -ldx {z1} -tay -lda ({z2}),y -sta {c1},x -//FRAGMENT vwuz1=_deref_pbuc1_word__deref_pbuc2 -lda {c2} -sta {z1} -lda {c1} -sta {z1}+1 //FRAGMENT vbsz1=vbsc1 lda #{c1} sta {z1} @@ -4673,6 +3261,12 @@ ldx {z2} lda {c2},x ldy {c1},x sta ({z1}),y +//FRAGMENT vbsz1=_neg_vbsz1 +lda {z1} +eor #$ff +clc +adc #$01 +sta {z1} //FRAGMENT pbuz1_derefidx_(pbsc1_derefidx_vbuaa)=vbuc2 tax lda #{c2} @@ -4793,182 +3387,22 @@ sta {c1},y //FRAGMENT pbsc1_derefidx_vbuyy=vbsyy tya sta {c1},y +//FRAGMENT vbsxx=_neg_vbsxx +txa +eor #$ff +clc +adc #$01 +tax +//FRAGMENT vbsyy=_neg_vbsyy +tya +eor #$ff +clc +adc #$01 +tay //FRAGMENT pbsc1_derefidx_vbuxx=vbsaa sta {c1},x //FRAGMENT vbsyy=vbsc1 ldy #{c1} -//FRAGMENT vbuz1=vbuz2_plus_vbuz2 -lda {z2} -asl -sta {z1} -//FRAGMENT vwuz1=vwuz2_plus_vbuz3 -lda {z3} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2_eq_vbuc1_then_la1 -lda #{c1} -ldy {z2} -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuz2_neq_0_then_la1 -ldy {z2} -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT vwuz1=vbuz2_rol_3 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vbuz1=vbuaa_plus_vbuaa -asl -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_vbuz1 -lda {z1} -asl -//FRAGMENT vbuaa=vbuaa_plus_vbuaa -asl -//FRAGMENT vbuxx=vbuz1_plus_vbuz1 -lda {z1} -asl -tax -//FRAGMENT vbuxx=vbuaa_plus_vbuaa -asl -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuz1 -lda {z1} -asl -tay -//FRAGMENT vbuyy=vbuaa_plus_vbuaa -asl -tay -//FRAGMENT vbuz1=vbuaa_plus_1 -clc -adc #1 -sta {z1} -//FRAGMENT vbuxx_eq_vbuz1_then_la1 -cpx {z1} -beq {la1} -//FRAGMENT vwuz1=vwuz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus_vbuyy -tya -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuyy -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa_eq_vbuc1_then_la1 -tay -lda #{c1} -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_eq_vbuc1_then_la1 -txa -tay -lda #{c1} -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_eq_vbuc1_then_la1 -lda #{c1} -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_neq_0_then_la1 -txa -tay -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_neq_0_then_la1 -lda ({z1}),y - -cmp #0 -bne {la1} -//FRAGMENT vwuz1=vbuaa_rol_3 -sta {z1} -lda #0 -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vbuxx_rol_3 -txa -sta {z1} -lda #0 -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vbuyy_rol_3 -tya -sta {z1} -lda #0 -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vbuz1_lt_vbuxx_then_la1 -cpx {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vwuz1=vwuz2_plus_vbuaa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=vbuyy_plus_1 -iny -sty {z1} -//FRAGMENT vbuxx_lt_vbuaa_then_la1 -sta $ff -cpx $ff -bcc {la1} //FRAGMENT vbuz1=_lo__deref_pwuc1 lda {c1} sta {z1} @@ -4995,6 +3429,13 @@ sta {z1} lda {z2}+1 adc {z3}+1 sta {z1}+1 +//FRAGMENT pbuz1_neq_pbuz2_then_la1 +lda {z1}+1 +cmp {z2}+1 +bne {la1} +lda {z1} +cmp {z2} +bne {la1} //FRAGMENT vwsz1=vbsc1_minus_vwsz2 NO_SYNTHESIS //FRAGMENT vwsz1=vwuc1_minus_vwsz2 @@ -5095,9 +3536,6 @@ sta {z1} lda {z2}+1 adc #>{c1} sta {z1}+1 -//FRAGMENT vbuz1=_lo_vwsz2 -lda {z2} -sta {z1} //FRAGMENT pbuz1=pbuz2_plus_vbuz3 lda {z3} clc @@ -5149,10 +3587,6 @@ lda ({z2}),y ldy {z3} ora {c1},y sta {z1} -//FRAGMENT vbuaa=_lo_vwsz1 -lda {z1} -//FRAGMENT vbuxx=_lo_vwsz1 -ldx {z1} //FRAGMENT pbuz1=pbuz2_plus_vbuaa clc adc {z2} @@ -5265,8 +3699,6 @@ lda {c1},y ldy #0 ora ({z1}),y tay -//FRAGMENT vbuyy=_lo_vwsz1 -ldy {z1} //FRAGMENT vwsz1=vwsz1_plus_vwsz2 lda {z1} clc @@ -5327,6 +3759,13 @@ sta {z1} lda {z1}+1 adc {z2}+1 sta {z1}+1 +//FRAGMENT pbuz1=pbuz1_plus_vbuaa +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: //FRAGMENT vwsz1=vwsz1_rol_6 lda {z1}+1 sta $ff @@ -5345,26 +3784,54 @@ lda #<{c2} sta {c1} lda #>{c2} sta {c1}+1 -//FRAGMENT 0_eq_vwuz1_then_la1 -lda {z1} -ora {z1}+1 -beq {la1} -//FRAGMENT vwuz1=_dec_vwuz1 -lda {z1} -bne !+ -dec {z1}+1 -!: -dec {z1} -//FRAGMENT 0_neq_pbuc1_derefidx_vbuaa_then_la1 -tay -lda {c1},y -cmp #0 -bne {la1} //FRAGMENT _deref_pwuc1=_deref_pwuc2 lda {c2} sta {c1} lda {c2}+1 sta {c1}+1 +//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuz3 +ldx {z1} +ldy {z3} +lda ({z2}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuxx +txa +ldx {z1} +tay +lda ({z2}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuyy +lda ({z2}),y +ldx {z1} +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuz2 +ldy {z2} +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuxx +txa +tay +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuyy +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuz2 +tya +ldy {z2} +tax +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuxx +sty $ff +txa +tay +lda ({z1}),y +ldy $ff +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuyy +lda ({z1}),y +sta {c1},y //FRAGMENT _deref_pbuc1=_deref_qbuc2_memcpy_vbuc3 ldy #{c3} !: @@ -5386,6 +3853,78 @@ lda {c2}-1,y sta {c1}-1,y dey bne !- +//FRAGMENT vbuz1=vbuz2_rol_2 +lda {z2} +asl +asl +sta {z1} +//FRAGMENT vbuaa=vbuz1_rol_2 +lda {z1} +asl +asl +//FRAGMENT vbuxx=vbuz1_rol_2 +lda {z1} +asl +asl +tax +//FRAGMENT vbuyy=vbuz1_rol_2 +lda {z1} +asl +asl +tay +//FRAGMENT vbuz1=vbuaa_rol_2 +asl +asl +sta {z1} +//FRAGMENT vbuaa=vbuaa_rol_2 +asl +asl +//FRAGMENT vbuxx=vbuaa_rol_2 +asl +asl +tax +//FRAGMENT vbuyy=vbuaa_rol_2 +asl +asl +tay +//FRAGMENT vbuz1=vbuxx_rol_2 +txa +asl +asl +sta {z1} +//FRAGMENT vbuaa=vbuxx_rol_2 +txa +asl +asl +//FRAGMENT vbuxx=vbuxx_rol_2 +txa +asl +asl +tax +//FRAGMENT vbuyy=vbuxx_rol_2 +txa +asl +asl +tay +//FRAGMENT vbuz1=vbuyy_rol_2 +tya +asl +asl +sta {z1} +//FRAGMENT vbuaa=vbuyy_rol_2 +tya +asl +asl +//FRAGMENT vbuxx=vbuyy_rol_2 +tya +asl +asl +tax +//FRAGMENT vbuyy=vbuyy_rol_2 +tya +asl +asl +tay //FRAGMENT vbuz1=vbuz2_rol_3 lda {z2} asl @@ -5597,27 +4136,21 @@ bne !- //FRAGMENT _deref_pbuc1=_byte_pprz1 lda {z1} sta {c1} -//FRAGMENT vwuz1=_deref_pwuc1_minus_vwuc2 -sec -lda {c1} -sbc #<{c2} +//FRAGMENT vbuz1=vbuz2_plus_vbuz2 +lda {z2} +asl sta {z1} -lda {c1}+1 -sbc #>{c2} -sta {z1}+1 -//FRAGMENT _deref_pwuc1=vwuz1 +//FRAGMENT vbuaa=vbuz1_plus_vbuz1 lda {z1} -sta {c1} -lda {z1}+1 -sta {c1}+1 -//FRAGMENT pbuz1=_deref_qbuc1_plus_vwuc2 -clc -lda {c1} -adc #<{c2} -sta {z1} -lda {c1}+1 -adc #>{c2} -sta {z1}+1 +asl +//FRAGMENT vbuxx=vbuz1_plus_vbuz1 +lda {z1} +asl +tax +//FRAGMENT vbuyy=vbuz1_plus_vbuz1 +lda {z1} +asl +tay //FRAGMENT 0_neq__deref_pbuc1_then_la1 lda {c1} cmp #0 @@ -5627,12 +4160,14 @@ lda #{c1} ldy {z2} sty {z1}+1 sta {z1} -//FRAGMENT vbuz1=vbuz2_minus__deref_pbuz3 -lda {z2} -sec -ldy #0 -sbc ({z3}),y +//FRAGMENT vwuz1=vwuz2_plus_vbuc1 +lda #{c1} +clc +adc {z2} sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 //FRAGMENT vbsz1=_inc_vbsz1 inc {z1} //FRAGMENT vbsz1_neq_vbsc1_then_la1 @@ -5663,6 +4198,14 @@ sta {z1}+1 lda {z2} ror sta {z1} +//FRAGMENT vwuz1=vwuc1_minus_vwuz1 +sec +lda #<{c1} +sbc {z1} +sta {z1} +lda #>{c1} +sbc {z1}+1 +sta {z1}+1 //FRAGMENT vwuz1=_neg_vwuz1 sec lda #0 @@ -5693,6 +4236,10 @@ sta {z1} lda {z1}+1 sbc {c1}+1,y sta {z1}+1 +//FRAGMENT vbuz1_eq_vbuc1_then_la1 +lda #{c1} +cmp {z1} +beq {la1} //FRAGMENT vwuz1=vwuz1_plus_pwuc1_derefidx_vbuz2 ldy {z2} clc @@ -5722,53 +4269,6 @@ sty {z1} lda #{c1} stx {z1}+1 sta {z1} -//FRAGMENT vwuz1=vwuz1_plus_vbuaa -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=vbuxx_minus__deref_pbuz2 -txa -sec -ldy #0 -sbc ({z2}),y -sta {z1} -//FRAGMENT vbuaa=vbuz1_minus__deref_pbuz2 -lda {z1} -sec -ldy #0 -sbc ({z2}),y -//FRAGMENT vbuaa=vbuxx_minus__deref_pbuz1 -txa -sec -ldy #0 -sbc ({z1}),y -//FRAGMENT vbuxx=vbuz1_minus__deref_pbuz2 -lda {z1} -sec -ldy #0 -sbc ({z2}),y -tax -//FRAGMENT vbuxx=vbuxx_minus__deref_pbuz1 -txa -sec -ldy #0 -sbc ({z1}),y -tax -//FRAGMENT vbuyy=vbuz1_minus__deref_pbuz2 -lda {z1} -sec -ldy #0 -sbc ({z2}),y -tay -//FRAGMENT vbuyy=vbuxx_minus__deref_pbuz1 -txa -sec -ldy #0 -sbc ({z1}),y -tay //FRAGMENT vbsxx_neq_vbsc1_then_la1 cpx #{c1} bne {la1} @@ -5965,14 +4465,6 @@ ora {z2} sta {z1} //FRAGMENT vbuz1=vbuxx_bor_vbuxx stx {z1} -//FRAGMENT pbuz1_derefidx_vbuxx=vbuz2 -txa -tay -lda {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=vbuz2 -lda {z2} -sta ({z1}),y //FRAGMENT vwuz1=vwuz1_minus_pwuc1_derefidx_vbuaa tay sec @@ -5998,6 +4490,9 @@ sta {z1} lda {z1}+1 sbc {c1}+1,y sta {z1}+1 +//FRAGMENT vbuxx_eq_vbuc1_then_la1 +cpx #{c1} +beq {la1} //FRAGMENT vwuz1=vwuz1_plus_pwuc1_derefidx_vbuaa tay clc @@ -6023,17 +4518,15 @@ sta {z1} lda {z1}+1 adc {c1}+1,y sta {z1}+1 -//FRAGMENT vbuz1_lt_vbuaa_then_la1 -cmp {z1} -beq !+ -bcs {la1} -!: //FRAGMENT vbuxx=vbuxx_minus_2 dex dex //FRAGMENT vbuyy=vbuyy_minus_2 dey dey +//FRAGMENT vbuyy_eq_vbuc1_then_la1 +cpy #{c1} +beq {la1} //FRAGMENT vbuz1=vbuz2_bor_vbuyy tya ora {z2} @@ -6079,22 +4572,6 @@ tay tya ora {z1} tay -//FRAGMENT pbuz1_derefidx_vbuxx=vbuyy -stx $ff -tya -ldy $ff -sta ({z1}),y -//FRAGMENT vbuz1_lt_vbuyy_then_la1 -cpy {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuxx_lt_vbuyy_then_la1 -sty $ff -cpx $ff -bcc {la1} -//FRAGMENT pbuz1_derefidx_vbuyy=vbuaa -sta ({z1}),y //FRAGMENT vbuaa=vbuyy_bor_vbuaa sty $ff ora $ff @@ -6106,9 +4583,15 @@ sta {z1} bcc !+ inc {z1}+1 !: +//FRAGMENT vbuaa_eq_vbuc1_then_la1 +cmp #{c1} +beq {la1} //FRAGMENT vbuz1_eq_vbuxx_then_la1 cpx {z1} beq {la1} +//FRAGMENT vbuxx_eq_vbuz1_then_la1 +cpx {z1} +beq {la1} //FRAGMENT vbuxx_eq_vbuaa_then_la1 tay sty $ff @@ -6122,53 +4605,10 @@ beq {la1} sty $ff cpx $ff beq {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuz3 -ldy {z3} -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuz2 -txa -ldx {z2} -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuz2 -ldx {z2} -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuxx -lda {c1},x -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuxx -txa -tay -lda {c1},y -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuxx -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuyy -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_vbuyy -lda {c1},y -stx $ff -ldy $ff -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_vbuyy -lda {c1},y -sta ({z1}),y -//FRAGMENT vwsz1=_sword_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_rol_1 -asl {z1} -rol {z1}+1 +//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +sta {c1} //FRAGMENT vboz1=vbuz2_lt_vbuc1 lda {z2} cmp #{c1} @@ -6265,6 +4705,70 @@ lda #0 rol eor #1 tay +//FRAGMENT vbuz1=vbuc1_plus_vbuz2 +lax {z2} +axs #-[{c1}] +stx {z1} +//FRAGMENT vbuz1=vbuc1_plus_vbuaa +clc +adc #{c1} +sta {z1} +//FRAGMENT vbuz1=vbuc1_plus_vbuxx +txa +axs #-[{c1}] +stx {z1} +//FRAGMENT vbuz1=vbuc1_plus_vbuyy +tya +clc +adc #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuc1_plus_vbuz1 +lda #{c1} +clc +adc {z1} +//FRAGMENT vbuaa=vbuc1_plus_vbuaa +clc +adc #{c1} +//FRAGMENT vbuaa=vbuc1_plus_vbuxx +txa +clc +adc #{c1} +//FRAGMENT vbuaa=vbuc1_plus_vbuyy +tya +clc +adc #{c1} +//FRAGMENT vbuxx=vbuc1_plus_vbuz1 +lax {z1} +axs #-[{c1}] +//FRAGMENT vbuxx=vbuc1_plus_vbuaa +tax +axs #-[{c1}] +//FRAGMENT vbuxx=vbuc1_plus_vbuxx +txa +axs #-[{c1}] +//FRAGMENT vbuxx=vbuc1_plus_vbuyy +tya +tax +axs #-[{c1}] +//FRAGMENT vbuyy=vbuc1_plus_vbuz1 +lda #{c1} +clc +adc {z1} +tay +//FRAGMENT vbuyy=vbuc1_plus_vbuaa +clc +adc #{c1} +tay +//FRAGMENT vbuyy=vbuc1_plus_vbuxx +txa +clc +adc #{c1} +tay +//FRAGMENT vbuyy=vbuc1_plus_vbuyy +tya +clc +adc #{c1} +tay //FRAGMENT vbuz1=vbuz2_rol_4 lda {z2} asl @@ -6434,9 +4938,6 @@ ora {z1} txa sty $ff ora $ff -//FRAGMENT pbuz1_derefidx_vbuyy=vbuxx -txa -sta ({z1}),y //FRAGMENT vbuxx=vbuxx_bor_vbuz1 txa ora {z1} @@ -6599,75 +5100,16 @@ inc {c1},x bne !+ inc {c1}+1,x !: -//FRAGMENT vbuz1=vbuc1_bor_vbuz2 -lda #{c1} -ora {z2} -sta {z1} -//FRAGMENT pbuz1_neq_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT vbuz1=vbuc1_bor_vbuaa -ora #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bor_vbuxx -txa -ora #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bor_vbuyy -tya -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -//FRAGMENT vbuaa=vbuc1_bor_vbuaa -ora #{c1} -//FRAGMENT vbuaa=vbuc1_bor_vbuxx -txa -ora #{c1} -//FRAGMENT vbuaa=vbuc1_bor_vbuyy -tya -ora #{c1} -//FRAGMENT vbuxx=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -tax -//FRAGMENT vbuxx=vbuc1_bor_vbuaa -ora #{c1} -tax -//FRAGMENT vbuxx=vbuc1_bor_vbuxx -txa -ora #{c1} -tax -//FRAGMENT vbuxx=vbuc1_bor_vbuyy -tya -ora #{c1} -tax -//FRAGMENT vbuyy=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -tay -//FRAGMENT vbuyy=vbuc1_bor_vbuaa -ora #{c1} -tay -//FRAGMENT vbuyy=vbuc1_bor_vbuxx -txa -ora #{c1} -tay -//FRAGMENT vbuyy=vbuc1_bor_vbuyy -tya -ora #{c1} -tay //FRAGMENT vwuz1_gt_vbuc1_then_la1 lda {z1}+1 bne {la1} lda #{c1} cmp {z1} bcc {la1} +//FRAGMENT vbuz1=vbuz2_bxor_vbuc1 +lda #{c1} +eor {z2} +sta {z1} //FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuz1 lda {c1} and {z1} @@ -6676,6 +5118,17 @@ sta {c1} lda {c1} ora {z1} sta {c1} +//FRAGMENT vbuaa=vbuz1_bxor_vbuc1 +lda #{c1} +eor {z1} +//FRAGMENT vbuxx=vbuz1_bxor_vbuc1 +lda #{c1} +eor {z1} +tax +//FRAGMENT vbuyy=vbuz1_bxor_vbuc1 +lda #{c1} +eor {z1} +tay //FRAGMENT vbuz1=vbuaa_bxor_vbuc1 eor #{c1} sta {z1} @@ -6687,6 +5140,28 @@ tax //FRAGMENT vbuyy=vbuaa_bxor_vbuc1 eor #{c1} tay +//FRAGMENT vbuz1=vbuxx_bxor_vbuc1 +txa +eor #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuxx_bxor_vbuc1 +txa +eor #{c1} +//FRAGMENT vbuyy=vbuxx_bxor_vbuc1 +txa +eor #{c1} +tay +//FRAGMENT vbuz1=vbuyy_bxor_vbuc1 +tya +eor #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuyy_bxor_vbuc1 +tya +eor #{c1} +//FRAGMENT vbuxx=vbuyy_bxor_vbuc1 +tya +eor #{c1} +tax //FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuaa and {c1} sta {c1} @@ -6709,52 +5184,20 @@ sta {c1} tya ora {c1} sta {c1} -//FRAGMENT _stackpushbyte_=vbuc1 +//FRAGMENT vbuyy=_lo_vwuz1 +ldy {z1} +//FRAGMENT vbuz1_le_vbuc1_then_la1 lda #{c1} -pha -//FRAGMENT _stackpullbyte_1 -pla -//FRAGMENT vbuz1=_stackpullbyte_ -pla -sta {z1} -//FRAGMENT vbuz1=_stackidxbyte_vbuc1 -tsx -lda STACK_BASE+{c1},x -sta {z1} -//FRAGMENT _stackidxbyte_vbuc1=vbuz1 +cmp {z1} +bcs {la1} +//FRAGMENT vbuaa_le_vbuc1_then_la1 +cmp #{c1} +bcc {la1} +beq {la1} +//FRAGMENT vbsz1_ge_0_then_la1 lda {z1} -tsx -sta STACK_BASE+{c1},x -//FRAGMENT vbuaa=_stackpullbyte_ -pla -//FRAGMENT vbuxx=_stackpullbyte_ -pla -tax -//FRAGMENT vbuyy=_stackpullbyte_ -pla -tay -//FRAGMENT vbuaa=_stackidxbyte_vbuc1 -tsx -lda STACK_BASE+{c1},x -//FRAGMENT vbuxx=_stackidxbyte_vbuc1 -tsx -lda STACK_BASE+{c1},x -tax -//FRAGMENT vbuyy=_stackidxbyte_vbuc1 -tsx -lda STACK_BASE+{c1},x -tay -//FRAGMENT _stackidxbyte_vbuc1=vbuaa -tsx -sta STACK_BASE+{c1},x -//FRAGMENT _stackidxbyte_vbuc1=vbuxx -txa -tsx -sta STACK_BASE+{c1},x -//FRAGMENT _stackidxbyte_vbuc1=vbuyy -tya -tsx -sta STACK_BASE+{c1},x +cmp #0 +bpl {la1} //FRAGMENT vbsz1=_dec_vbsz1 dec {z1} //FRAGMENT pbuz1=pbuc1_plus_vbsz2 @@ -6848,6 +5291,9 @@ tay sty $ff ora $ff tay +//FRAGMENT vbsxx_ge_0_then_la1 +cpx #0 +bpl {la1} //FRAGMENT vbuyy=vbuxx_bor_vbuyy txa sty $ff @@ -6862,47 +5308,291 @@ tax ldx #{c1} //FRAGMENT vbsxx=_dec_vbsxx dex -//FRAGMENT vduz1=vduz2_minus_vduc1 -lda {z2} +//FRAGMENT pbuz1=_dec_pbuz1 +lda {z1} +bne !+ +dec {z1}+1 +!: +dec {z1} +//FRAGMENT _stackpushbyte_=vbuz1 +lda {z1} +pha +//FRAGMENT _stackpushbyte_1 +pha +//FRAGMENT _stackpullbyte_2 +pla +pla +//FRAGMENT _stackpushbyte_=vbuxx +txa +pha +//FRAGMENT _stackpushbyte_=vbuyy +tya +pha +//FRAGMENT _stackpushbyte_3 +pha +pha +pha +//FRAGMENT _stackpullbyte_4 +tsx +txa +axs #-4 +txs +//FRAGMENT vbuaa=vbuz1_plus_1 +lda {z1} +clc +adc #1 +//FRAGMENT vbuyy=vbuz1_plus_1 +ldy {z1} +iny +//FRAGMENT vbuz1=vbuyy_plus_1 +iny +sty {z1} +//FRAGMENT vbuyy=vbuxx_plus_1 +txa +tay +iny +//FRAGMENT pbuz1=_stackidxptr_vbuc1 +tsx +lda STACK_BASE+{c1},x +sta {z1} +lda STACK_BASE+{c1}+1,x +sta {z1}+1 +//FRAGMENT pbuc1_derefidx_vbuz1=_deref_pbuz2 +ldy #0 +lda ({z2}),y +ldy {z1} +sta {c1},y +//FRAGMENT _stackpushptr_=pbuc1 +lda #>{c1} +pha +lda #<{c1} +pha +//FRAGMENT _stackpullbyte_3 +tsx +txa +axs #-3 +txs +//FRAGMENT vbuz1=vbuz2_minus_1 +ldx {z2} +dex +stx {z1} +//FRAGMENT vbuaa=vbuz1_minus_1 +lda {z1} sec -sbc #<{c1} +sbc #1 +//FRAGMENT _stackpushbyte_=vbuaa +pha +//FRAGMENT vbuxx=vbuz1_minus_1 +ldx {z1} +dex +//FRAGMENT vbuyy=vbuz1_minus_1 +lda {z1} +tay +dey +//FRAGMENT vbuz1=vbuaa_minus_1 +sec +sbc #1 +sta {z1} +//FRAGMENT vbuaa=vbuaa_minus_1 +sec +sbc #1 +//FRAGMENT vbuxx=vbuaa_minus_1 +tax +dex +//FRAGMENT pbuc1_derefidx_vbuz1_neq_0_then_la1 +ldy {z1} +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuc1=vbuc2 +lda #{c2} +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuc1_derefidx_vbuaa_neq_0_then_la1 +tay +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuxx_neq_0_then_la1 +lda {c1},x +cmp #0 +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuyy_neq_0_then_la1 +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pvoz1=pvoz2 +lda {z2} sta {z1} lda {z2}+1 -sbc #>{c1} sta {z1}+1 -lda {z2}+2 -sbc #<{c1}>>$10 -sta {z1}+2 -lda {z2}+3 -sbc #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT _deref_pduc1=vduc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -lda #<{c2}>>$10 -sta {c1}+2 -lda #>{c2}>>$10 -sta {c1}+3 -//FRAGMENT vduz1=vduc1_minus__deref_pduc2 +//FRAGMENT vwuz1=vbuc1 lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +//FRAGMENT pbuz1=pbuz2_minus_vwuz3 +lda {z2} sec -sbc {c2} +sbc {z3} sta {z1} -lda #>{c1} -sbc {c2}+1 +lda {z2}+1 +sbc {z3}+1 sta {z1}+1 -lda #<{c1}>>$10 -sbc {c2}+2 -sta {z1}+2 -lda #>{c1}>>$10 -sbc {c2}+3 -sta {z1}+3 -//FRAGMENT pwuz1=pwuc1 -lda #<{c1} +//FRAGMENT pwuz1=qwuz2_derefidx_vbuz3 +ldy {z3} +lda ({z2}),y sta {z1} -lda #>{c1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT vbuz1=pbuz2_derefidx_vbuz3 +ldy {z3} +lda ({z2}),y +sta {z1} +//FRAGMENT vbuz1_le_0_then_la1 +lda {z1} +cmp #0 +beq {la1} +//FRAGMENT vwuz1_eq_vwuc1_then_la1 +lda {z1} +cmp #<{c1} +bne !+ +lda {z1}+1 +cmp #>{c1} +beq {la1} +!: +//FRAGMENT vwuz1=pwuz2_derefidx_vbuz3 +ldy {z3} +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT _deref_pbuz1_eq_vbuc1_then_la1 +lda #{c1} +ldy #0 +cmp ({z1}),y +beq {la1} +//FRAGMENT _deref_pbuz1_gt_vbuz2_then_la1 +ldy #0 +lda ({z1}),y +cmp {z2} +beq !+ +bcs {la1} +!: +//FRAGMENT pbuz1=pbuz2_plus_vwuc1 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vbuz1=vbuc1_minus_vbuz2 +lda #{c1} +sec +sbc {z2} +sta {z1} +//FRAGMENT pbuz1=pbuz1_minus_vbuc1 +sec +lda {z1} +sbc #{c1} +sta {z1} +lda {z1}+1 +sbc #0 +sta {z1}+1 +//FRAGMENT vbuz1=vbuz2_minus_vbuc1 +lax {z2} +axs #{c1} +stx {z1} +//FRAGMENT vbuz1=_neg_vbuz2 +lda {z2} +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT pbuz1_derefidx_(_deref_pbuz2)=_inc_pbuz1_derefidx_(_deref_pbuz2) +ldy #0 +lda ({z2}),y +tay +lda ({z1}),y +clc +adc #1 +sta ({z1}),y +//FRAGMENT vwuz1_neq_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT vwuz1=_deref_pbuz2_rol_1 +ldy #0 +lda ({z2}),y +asl +sta {z1} +lda #0 +rol +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_rol_1 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +//FRAGMENT qwuz1=qwuz2_plus_vwuz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +//FRAGMENT _deref_qwuz1=pwuz2 +ldy #0 +lda {z2} +sta ({z1}),y +iny +lda {z2}+1 +sta ({z1}),y +//FRAGMENT vwuz1_neq_vbuc1_then_la1 +NO_SYNTHESIS +//FRAGMENT vwuz1_neq_vbsc1_then_la1 +NO_SYNTHESIS +//FRAGMENT pwuz1=_deref_qwuz2 +ldy #0 +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT vwuz1=pbuz2_minus_pbuz3 +lda {z2} +sec +sbc {z3} +sta {z1} +lda {z2}+1 +sbc {z3}+1 +sta {z1}+1 +//FRAGMENT pwuz1_derefidx_vbuz2=vwuz3 +ldy {z2} +lda {z3} +sta ({z1}),y +iny +lda {z3}+1 +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2=_inc_pbuz1_derefidx_vbuz2 +ldy {z2} +lda ({z1}),y +clc +adc #1 +sta ({z1}),y +//FRAGMENT pwuz1=pwuz2 +lda {z2} +sta {z1} +lda {z2}+1 sta {z1}+1 //FRAGMENT _deref_pwuz1=vwuz2 ldy #0 @@ -6919,22 +5609,22 @@ sta {z1} bcc !+ inc {z1}+1 !: -//FRAGMENT pwuz1=pwuz2 +//FRAGMENT vwuz1=vwuz1_plus_vbuz2 lda {z2} +clc +adc {z1} sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=pwuz2_minus_pwuc1 +bcc !+ +inc {z1}+1 +!: +//FRAGMENT vwuz1=pwuz2_minus_pwuz3 lda {z2} sec -sbc #<{c1} +sbc {z3} sta {z1} lda {z2}+1 -sbc #>{c1} +sbc {z3}+1 sta {z1}+1 -//FRAGMENT vbuz1_gt_0_then_la1 -lda {z1} -bne {la1} //FRAGMENT _deref_pwuz1_le_vwuz2_then_la1 ldy #1 lda ({z1}),y @@ -6987,14 +5677,96 @@ sta {z1} lda #0 adc {z2}+1 sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_1 -clc -lda {z2} -adc #1 +//FRAGMENT vbuz1=vbuz1_ror_1 +lsr {z1} +//FRAGMENT pwuz1=qwuz2_derefidx_vbuaa +tay +lda ({z2}),y sta {z1} -lda {z2}+1 -adc #0 +iny +lda ({z2}),y sta {z1}+1 +//FRAGMENT pwuz1=qwuz2_derefidx_vbuxx +txa +tay +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT pwuz1=qwuz2_derefidx_vbuyy +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT vbuxx=pbuz1_derefidx_vbuz2 +ldy {z2} +lda ({z1}),y +tax +//FRAGMENT vbuyy=pbuz1_derefidx_vbuz2 +ldy {z2} +lda ({z1}),y +tay +//FRAGMENT vbuz1=pbuz2_derefidx_vbuxx +txa +tay +lda ({z2}),y +sta {z1} +//FRAGMENT vbuxx=pbuz1_derefidx_vbuxx +txa +tay +lda ({z1}),y +tax +//FRAGMENT vbuyy=pbuz1_derefidx_vbuxx +txa +tay +lda ({z1}),y +tay +//FRAGMENT vbuaa_le_0_then_la1 +cmp #0 +beq {la1} +//FRAGMENT vwuz1=pwuz2_derefidx_vbuaa +tay +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT vwuz1=pwuz2_derefidx_vbuxx +txa +tay +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT vwuz1=pwuz2_derefidx_vbuyy +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT _deref_pbuz1_gt_vbuxx_then_la1 +ldy #0 +lda ({z1}),y +sta $ff +cpx $ff +bcc {la1} +//FRAGMENT vbuaa=vbuc1_minus_vbuz1 +lda #{c1} +sec +sbc {z1} +//FRAGMENT vbuxx=vbuc1_minus_vbuz1 +lda #{c1} +sec +sbc {z1} +tax +//FRAGMENT vbuyy=vbuc1_minus_vbuz1 +lda #{c1} +sec +sbc {z1} +tay //FRAGMENT vbuz1=vbuc1_minus_vbuaa eor #$ff sec @@ -7057,471 +5829,45 @@ eor #$ff sec adc #{c1} tay -//FRAGMENT pbuz1_derefidx_vbuxx=vbuxx +//FRAGMENT vbuz1=vbuaa_minus_vbuc1 +sec +sbc #{c1} +sta {z1} +//FRAGMENT vbuz1=vbuxx_minus_vbuc1 txa -tay -sta ({z1}),y -//FRAGMENT vbuaa_gt_0_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuz1=vbuaa_ror_1 -lsr -sta {z1} -//FRAGMENT vbuaa=vbuaa_ror_1 -lsr -//FRAGMENT vbuxx=vbuaa_ror_1 -lsr -tax -//FRAGMENT vbuyy=vbuaa_ror_1 -lsr -tay -//FRAGMENT pwuz1=pwuz2_plus_vbuaa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pwuz1=pwuz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pwuz1=pwuz2_plus_vbuyy +axs #{c1} +stx {z1} +//FRAGMENT vbuz1=vbuyy_minus_vbuc1 tya -clc -adc {z2} +sec +sbc #{c1} sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuxx_gt_0_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuaa=vbuaa_plus_1 -clc -adc #1 -//FRAGMENT vbuxx=vbuaa_plus_1 -tax -inx -//FRAGMENT vbuxx=vbuyy_plus_1 +//FRAGMENT vbuaa=vbuz1_minus_vbuc1 +lda {z1} +sec +sbc #{c1} +//FRAGMENT vbuaa=vbuaa_minus_vbuc1 +sec +sbc #{c1} +//FRAGMENT vbuaa=vbuxx_minus_vbuc1 +txa +sec +sbc #{c1} +//FRAGMENT vbuaa=vbuyy_minus_vbuc1 tya +sec +sbc #{c1} +//FRAGMENT vbuxx=vbuz1_minus_vbuc1 +lax {z1} +axs #{c1} +//FRAGMENT vbuxx=vbuaa_minus_vbuc1 tax -inx -//FRAGMENT vbuyy=vbuaa_plus_1 -tay -iny -//FRAGMENT vbuyy=vbuxx_plus_1 -txa -tay -iny -//FRAGMENT vbuyy=vbuyy_plus_1 -iny -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx -lda {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy -ldx {c1},y -//FRAGMENT vwuz1=pwuz1_minus_pwuc1 +axs #{c1} +//FRAGMENT vbuyy=vbuz1_minus_vbuc1 lda {z1} sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT vduz1=vduz1_minus_vduc1 -lda {z1} -sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -lda {z1}+2 -sbc #<{c1}>>$10 -sta {z1}+2 -lda {z1}+3 -sbc #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT pbuz1=_dec_pbuz1 -lda {z1} -bne !+ -dec {z1}+1 -!: -dec {z1} -//FRAGMENT _stackpushbyte_=vbuz1 -lda {z1} -pha -//FRAGMENT _stackpushbyte_1 -pha -//FRAGMENT _stackpullbyte_2 -pla -pla -//FRAGMENT _stackpushbyte_=vbuxx -txa -pha -//FRAGMENT _stackpushbyte_=vbuyy -tya -pha -//FRAGMENT _stackpushbyte_3 -pha -pha -pha -//FRAGMENT _stackpullbyte_4 -tsx -txa -axs #-4 -txs -//FRAGMENT pbuz1=_stackidxptr_vbuc1 -tsx -lda STACK_BASE+{c1},x -sta {z1} -lda STACK_BASE+{c1}+1,x -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -ldy {z1} -sta {c1},y -//FRAGMENT _stackpushptr_=pbuc1 -lda #>{c1} -pha -lda #<{c1} -pha -//FRAGMENT _stackpullbyte_3 -tsx -txa -axs #-3 -txs -//FRAGMENT _stackpushbyte_=vbuaa -pha -//FRAGMENT vbuz1=vbuaa_minus_1 -sec -sbc #1 -sta {z1} -//FRAGMENT vbuaa=vbuaa_minus_1 -sec -sbc #1 -//FRAGMENT vbuxx=vbuaa_minus_1 -tax -dex -//FRAGMENT vwuz1=vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuz1=_lo_pbuz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=_hi_pbuz2 -lda {z2}+1 -sta {z1} -//FRAGMENT vwuz1_eq_0_then_la1 -lda {z1} -ora {z1}+1 -beq {la1} -//FRAGMENT vwuz1_gt_vwuz2_then_la1 -lda {z2}+1 -cmp {z1}+1 -bcc {la1} -bne !+ -lda {z2} -cmp {z1} -bcc {la1} -!: -//FRAGMENT vwuz1_neq_vwuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_pbuc2_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1}+1 -lda {c2},y -sta {z1} -//FRAGMENT vwuz1=vwuz2_band_vwuc1 -lda {z2} -and #<{c1} -sta {z1} -lda {z2}+1 -and #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuz2 -ldy #0 -lda ({z1}),y -ldy {z2} -ora {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT vwuz1=vbuaa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuaa=_lo_pbuz1 -lda {z1} -//FRAGMENT vbuxx=_lo_pbuz1 -ldx {z1} -//FRAGMENT vbuz1=vbuaa_bor_vbuaa -sta {z1} -//FRAGMENT vbuaa=_hi_pbuz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_pbuz1 -ldx {z1}+1 -//FRAGMENT vwuz1=pbuc1_derefidx_vbuaa_word_pbuc2_derefidx_vbuaa +sbc #{c1} tay -lda {c1},y -sta {z1}+1 -lda {c2},y -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_pbuc2_derefidx_vbuxx -lda {c1},x -sta {z1}+1 -lda {c2},x -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuyy_word_pbuc2_derefidx_vbuyy -lda {c1},y -sta {z1}+1 -lda {c2},y -sta {z1} -//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy #0 -ora ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -ora ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -ora ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT vbuyy=_hi_pbuz1 -ldy {z1}+1 -//FRAGMENT pbuz1=pbuz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1_neq_0_then_la1 -ldy {z1} -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuc1=vbuc2 -lda #{c2} -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuaa_neq_0_then_la1 -tay -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_neq_0_then_la1 -lda {c1},x -cmp #0 -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_neq_0_then_la1 -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT pbuz1=pbuz2_minus_vwuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -lda {z2}+1 -sbc {z3}+1 -sta {z1}+1 -//FRAGMENT pwuz1=qwuz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vbuz1_le_0_then_la1 -lda {z1} -cmp #0 -beq {la1} -//FRAGMENT vwuz1_eq_vwuc1_then_la1 -lda {z1} -cmp #<{c1} -bne !+ -lda {z1}+1 -cmp #>{c1} -beq {la1} -!: -//FRAGMENT _deref_pbuc1=_dec__deref_pbuc1 -dec {c1} -//FRAGMENT vwuz1=pwuz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT _deref_pbuz1_gt_vbuz2_then_la1 -ldy #0 -lda ({z1}),y -cmp {z2} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuz1=_neg_vbuz2 -lda {z2} -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT pbuz1_derefidx_(_deref_pbuz2)=_inc_pbuz1_derefidx_(_deref_pbuz2) -ldy #0 -lda ({z2}),y -tay -lda ({z1}),y -clc -adc #1 -sta ({z1}),y -//FRAGMENT vwuz1=_deref_pbuz2_rol_1 -ldy #0 -lda ({z2}),y -asl -sta {z1} -lda #0 -rol -sta {z1}+1 -//FRAGMENT qwuz1=qwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT _deref_qwuz1=pwuz2 -ldy #0 -lda {z2} -sta ({z1}),y -iny -lda {z2}+1 -sta ({z1}),y -//FRAGMENT vwuz1_neq_vbuc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vwuz1_neq_vbsc1_then_la1 -NO_SYNTHESIS -//FRAGMENT pwuz1=_deref_qwuz2 -ldy #0 -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vwuz1=pbuz2_minus_pbuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -lda {z2}+1 -sbc {z3}+1 -sta {z1}+1 -//FRAGMENT pwuz1_derefidx_vbuz2=vwuz3 -ldy {z2} -lda {z3} -sta ({z1}),y -iny -lda {z3}+1 -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=_inc_pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -clc -adc #1 -sta ({z1}),y -//FRAGMENT vwuz1=pwuz2_minus_pwuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -lda {z2}+1 -sbc {z3}+1 -sta {z1}+1 -//FRAGMENT pwuz1=qwuz2_derefidx_vbuaa -tay -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT pwuz1=qwuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT pwuz1=qwuz2_derefidx_vbuyy -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vbuaa_le_0_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vwuz1=pwuz2_derefidx_vbuaa -tay -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vwuz1=pwuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vwuz1=pwuz2_derefidx_vbuyy -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT _deref_pbuz1_gt_vbuxx_then_la1 -ldy #0 -lda ({z1}),y -sta $ff -cpx $ff -bcc {la1} //FRAGMENT vbuz1=_neg_vbuaa eor #$ff clc @@ -7620,16 +5966,99 @@ lda ({z1}),y clc adc #1 sta ({z1}),y +//FRAGMENT vwuz1=vwuz1_plus_vbuaa +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: +//FRAGMENT vwuz1=vwuz1_plus_vbuxx +txa +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: +//FRAGMENT vwuz1=vwuz1_plus_vbuyy +tya +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: +//FRAGMENT pwuz1=pwuz2_plus_vbuaa +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pwuz1=pwuz2_plus_vbuxx +txa +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pwuz1=pwuz2_plus_vbuyy +tya +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 //FRAGMENT vbuxx_le_0_then_la1 cpx #0 beq {la1} -//FRAGMENT pbuz1_derefidx_vbuyy=vbuyy -tya -sta ({z1}),y //FRAGMENT vwuz1=vbuyy_word_vbuc1 lda #{c1} sty {z1}+1 sta {z1} +//FRAGMENT vbuyy=vbuaa_minus_vbuc1 +sec +sbc #{c1} +tay +//FRAGMENT vbuxx=vbuxx_minus_vbuc1 +txa +axs #{c1} +//FRAGMENT vbuyy=vbuxx_minus_vbuc1 +txa +sec +sbc #{c1} +tay +//FRAGMENT vbuxx=vbuyy_minus_vbuc1 +tya +tax +axs #{c1} +//FRAGMENT vbuyy=vbuyy_minus_vbuc1 +tya +sec +sbc #{c1} +tay +//FRAGMENT vbuaa=vbuxx_plus_1 +inx +txa +//FRAGMENT vbuaa=vbuyy_plus_1 +iny +tya +//FRAGMENT vbuxx=vbuz1_plus_1 +ldx {z1} +inx +//FRAGMENT vbuxx=vbuaa_plus_1 +tax +inx +//FRAGMENT vbuxx=vbuyy_plus_1 +tya +tax +inx +//FRAGMENT vbuyy=vbuaa_plus_1 +tay +iny //FRAGMENT pbuz1=pbuz2_minus_vwuz1 lda {z2} sec @@ -7646,6 +6075,14 @@ sta {z1} lda #0 rol sta {z1}+1 +//FRAGMENT pbuz1=pbuz1_plus_vwuc1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 //FRAGMENT qwuz1=qwuz2_plus_vwuz1 lda {z1} clc @@ -7671,372 +6108,14 @@ sta {z1} lda {z1}+1 sbc {z2}+1 sta {z1}+1 -//FRAGMENT vbuyy_gt_0_then_la1 -cpy #0 -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx -ldy {c1},x -//FRAGMENT vduz1=_inc_vduz1 -inc {z1} -bne !+ -inc {z1}+1 -bne !+ -inc {z1}+2 -bne !+ -inc {z1}+3 -!: -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuz2_then_la1 -ldy {z1} -lda {c1},y -cmp {z2} -beq {la1} -//FRAGMENT vbsz1=_sbyte_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsz3 -lda {z2} -sec -sbc {z3} -sta {z1} -//FRAGMENT 0_neq_vbsz1_then_la1 +//FRAGMENT vwuz1=vwuz1_plus_vwuz2 lda {z1} -cmp #0 -bne {la1} -//FRAGMENT vbuz1_ge_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcs {la1} -//FRAGMENT vbuaa_le_vbuz1_then_la1 -ldy {z1} -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuz1_then_la1 -tay -lda {c1},y -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuz1_then_la1 -lda {c1},x -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuz1_then_la1 -lda {c1},y -cmp {z1} -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuaa_then_la1 -ldx {z1} -tay -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuaa_then_la1 -tax -lda {c1},x -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuaa_then_la1 -tay -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuaa_then_la1 -tax -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuxx_then_la1 -ldy {z1} -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuxx_then_la1 -tay -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuxx_then_la1 -lda {c1},x -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuxx_then_la1 -lda {c1},y -tay -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuyy_then_la1 -ldx {z1} -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuaa_eq_vbuyy_then_la1 -tax -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuyy_then_la1 -lda {c1},x -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuyy_then_la1 -lda {c1},y -tax -sty $ff -cpx $ff -beq {la1} -//FRAGMENT vbuaa_neq_vbuz1_then_la1 -cmp {z1} -bne {la1} -//FRAGMENT vbsaa=_sbyte_vwuz1 -lda {z1} -//FRAGMENT vbsxx=_sbyte_vwuz1 -ldx {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsaa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsxx -txa -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsyy -tya -eor #$ff -sec -adc {z2} -sta {z1} -//FRAGMENT vbsxx=vbsz1_minus_vbsz2 -lda {z1} -sec -sbc {z2} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsaa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsxx -txa -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsxx=vbsz1_minus_vbsyy -tya -eor #$ff -sec -adc {z1} -tax -//FRAGMENT vbsz1=vbsxx_minus_vbsz2 -txa -sec -sbc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsaa -sta $ff -txa -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsxx -lda #0 -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsyy -txa -sty $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsxx=vbsxx_minus_vbsz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsxx -lda #0 -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbsz1=vbsyy_minus_vbsz2 -tya -sec -sbc {z2} -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsaa -sta $ff -tya -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsxx -tya -stx $ff -sec -sbc $ff -sta {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsyy -lda #0 -sta {z1} -//FRAGMENT vbsxx=vbsyy_minus_vbsz1 -tya -sec -sbc {z1} -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsaa -sta $ff -tya -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsxx -tya -stx $ff -sec -sbc $ff -tax -//FRAGMENT vbsxx=vbsyy_minus_vbsyy -lda #0 -tax -//FRAGMENT 0_neq_vbsxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuaa_ge_vbuz1_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuz1=vbuxx_minus_1 -dex -stx {z1} -//FRAGMENT vbuz1=vbuyy_minus_1 -tya -sec -sbc #1 -sta {z1} -//FRAGMENT vbuyy_le_vbuz1_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuz1_le_vbuaa_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuxx_ge_vbuz1_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vbuz1_ge_vbuxx_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuz1_ge_vbuyy_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuyy_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuyy_ge_vbuz1_then_la1 -cpy {z1} -bcs {la1} -//FRAGMENT vbuyy_ge_vbuxx_then_la1 -stx $ff -cpy $ff -bcs {la1} -//FRAGMENT vbsaa=_inc_vbsaa clc -adc #1 -//FRAGMENT vbsxx=_inc_vbsxx -inx -//FRAGMENT vbsyy=_sbyte_vwuz1 -ldy {z1} -//FRAGMENT vbsyy=_inc_vbsyy -iny -//FRAGMENT vbuaa_lt_vbuxx_then_la1 -stx $ff -cmp $ff -bcc {la1} -//FRAGMENT vbuaa_lt_vbuyy_then_la1 -tax -sty $ff -cpx $ff -bcc {la1} -//FRAGMENT vbuyy_lt_vbuaa_then_la1 -sta $ff -cpy $ff -bcc {la1} -//FRAGMENT vbuyy_lt_vbuxx_then_la1 -stx $ff -cpy $ff -bcc {la1} -//FRAGMENT vbuxx_le_vbuaa_then_la1 -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuyy_le_vbuaa_then_la1 -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuyy_le_vbuxx_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuz1_le_vbuyy_then_la1 -cpy {z1} -bcs {la1} -//FRAGMENT vbuxx_le_vbuyy_then_la1 -stx $ff -cpy $ff -bcs {la1} -//FRAGMENT vbuz1=vbuz2_minus_vbuz1 -lda {z2} -sec -sbc {z1} -sta {z1} -//FRAGMENT vbsz1=vbsz1_minus_vbsz2 -lda {z1} -sec -sbc {z2} +adc {z2} sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 //FRAGMENT pbuz1_le_pbuc1_then_la1 lda {z1}+1 cmp #>{c1} @@ -8055,8 +6134,6 @@ lda #<{c1} cmp {z1} bcc {la1} !: -//FRAGMENT vbuz1=vbuz1_rol_1 -asl {z1} //FRAGMENT vdsz1=vdsc1 lda #<{c1} sta {z1} @@ -8275,6 +6352,16 @@ lda {z2} sta {z1} lda {z2}+1 sta {z1}+1 +//FRAGMENT vwuz1=_word1_vduz2 +lda {z2}+2 +sta {z1} +lda {z2}+3 +sta {z1}+1 +//FRAGMENT vwuz1=_word1_vdsz2 +lda {z2}+2 +sta {z1} +lda {z2}+3 +sta {z1}+1 //FRAGMENT vduz1=vduc1_plus_vbuz2 lda {z2} clc @@ -8289,6 +6376,9 @@ sta {z1}+2 lda #>{c1}>>$10 adc #0 sta {z1}+3 +//FRAGMENT vbuz1=_byte_vduz2 +lda {z2} +sta {z1} //FRAGMENT vduz1=vduc1_plus_vbuaa clc adc #<{c1} @@ -8330,22 +6420,745 @@ sta {z1}+2 lda #>{c1}>>$10 adc #0 sta {z1}+3 -//FRAGMENT pbuz1_derefidx_vbuaa=vbuz2 +//FRAGMENT vbuaa=_byte_vduz1 +lda {z1} +//FRAGMENT vbuxx=_byte_vduz1 +lda {z1} +tax +//FRAGMENT vbuyy=_byte_vduz1 +lda {z1} tay +//FRAGMENT pvoz1=pvoc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +//FRAGMENT vwuz1_lt_vbuc1_then_la1 +lda {z1}+1 +bne !+ +lda {z1} +cmp #{c1} +bcc {la1} +!: +//FRAGMENT vduz1=vduz2_minus_vduc1 +lda {z2} +sec +sbc #<{c1} +sta {z1} +lda {z2}+1 +sbc #>{c1} +sta {z1}+1 +lda {z2}+2 +sbc #<{c1}>>$10 +sta {z1}+2 +lda {z2}+3 +sbc #>{c1}>>$10 +sta {z1}+3 +//FRAGMENT vwuz1=_word_vduz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT vwuz1_lt_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT vwuz1_le_0_then_la1 +lda {z1} +bne !+ +lda {z1}+1 +beq {la1} +!: +//FRAGMENT _deref_pduc1=vduc2 +lda #<{c2} +sta {c1} +lda #>{c2} +sta {c1}+1 +lda #<{c2}>>$10 +sta {c1}+2 +lda #>{c2}>>$10 +sta {c1}+3 +//FRAGMENT vduz1=vduc1_minus__deref_pduc2 +lda #<{c1} +sec +sbc {c2} +sta {z1} +lda #>{c1} +sbc {c2}+1 +sta {z1}+1 +lda #<{c1}>>$10 +sbc {c2}+2 +sta {z1}+2 +lda #>{c1}>>$10 +sbc {c2}+3 +sta {z1}+3 +//FRAGMENT vwuz1=_lo_vduz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT vduz1=vwuz2_dword_vwuz3 +lda {z2} +sta {z1}+2 +lda {z2}+1 +sta {z1}+3 +lda {z3} +sta {z1} +lda {z3}+1 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz1_minus_vwuc1 +lda {z1} +sec +sbc #<{c1} +sta {z1} +lda {z1}+1 +sbc #>{c1} +sta {z1}+1 +//FRAGMENT vduz1=pduc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +lda {c1}+2,y +sta {z1}+2 +lda {c1}+3,y +sta {z1}+3 +//FRAGMENT vduz1_ge_vduz2_then_la1 +lda {z1}+3 +cmp {z2}+3 +bcc !+ +bne {la1} +lda {z1}+2 +cmp {z2}+2 +bcc !+ +bne {la1} +lda {z1}+1 +cmp {z2}+1 +bcc !+ +bne {la1} +lda {z1} +cmp {z2} +bcs {la1} +!: +//FRAGMENT vduz1=vduz1_minus_vduz2 +lda {z1} +sec +sbc {z2} +sta {z1} +lda {z1}+1 +sbc {z2}+1 +sta {z1}+1 +lda {z1}+2 +sbc {z2}+2 +sta {z1}+2 +lda {z1}+3 +sbc {z2}+3 +sta {z1}+3 +//FRAGMENT vduz1=pduc1_derefidx_vbuaa +tay +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +lda {c1}+2,y +sta {z1}+2 +lda {c1}+3,y +sta {z1}+3 +//FRAGMENT vduz1=pduc1_derefidx_vbuxx +lda {c1},x +sta {z1} +lda {c1}+1,x +sta {z1}+1 +lda {c1}+2,x +sta {z1}+2 +lda {c1}+3,x +sta {z1}+3 +//FRAGMENT vduz1=pduc1_derefidx_vbuyy +lda {c1},y +sta {z1} +lda {c1}+1,y +sta {z1}+1 +lda {c1}+2,y +sta {z1}+2 +lda {c1}+3,y +sta {z1}+3 +//FRAGMENT pbuz1=pbuz2_plus_vwuz1 +lda {z1} +clc +adc {z2} +sta {z1} +lda {z1}+1 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT vduz1=vduz1_minus_vduc1 +lda {z1} +sec +sbc #<{c1} +sta {z1} +lda {z1}+1 +sbc #>{c1} +sta {z1}+1 +lda {z1}+2 +sbc #<{c1}>>$10 +sta {z1}+2 +lda {z1}+3 +sbc #>{c1}>>$10 +sta {z1}+3 +//FRAGMENT _deref_qbuc1=pbuc2 +lda #<{c2} +sta {c1} +lda #>{c2} +sta {c1}+1 +//FRAGMENT _deref_pbsc1=vbsc2 +lda #{c2} +sta {c1} +//FRAGMENT 0_neq_vbuaa_then_la1 +cmp #0 +bne {la1} +//FRAGMENT vwuz1=vwuz2_bor_vbuz3 +lda {z3} +ora {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT vbuz1=vbuz1_rol_1 +asl {z1} +//FRAGMENT pbuz1_derefidx_vbuz2=pbuz3_derefidx_vbuz2 +ldy {z2} +lda ({z3}),y +sta ({z1}),y +//FRAGMENT vwuz1=vwuz2_rol_4 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuz2 +ldy {z2} +lda {c2},y +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2_eq_pbuz3_derefidx_vbuz2_then_la1 +ldy {z2} +lda ({z1}),y + +cmp ({z3}),y +beq {la1} +//FRAGMENT vbuz1=pbuz2_derefidx_vbuaa +tay +lda ({z2}),y +sta {z1} +//FRAGMENT vbuaa=pbuz1_derefidx_vbuaa +tay +lda ({z1}),y +//FRAGMENT vbuxx=pbuz1_derefidx_vbuaa +tay +lda ({z1}),y +tax +//FRAGMENT vbuyy=pbuz1_derefidx_vbuaa +tay +lda ({z1}),y +tay +//FRAGMENT vbuz1=pbuz2_derefidx_vbuyy +lda ({z2}),y +sta {z1} +//FRAGMENT vbuxx=pbuz1_derefidx_vbuyy +lda ({z1}),y +tax +//FRAGMENT vbuyy=pbuz1_derefidx_vbuyy +lda ({z1}),y +tay +//FRAGMENT vwuz1=vwuz2_bor_vbuxx +txa +ora {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_bor_vbuyy +tya +ora {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuaa=pbuz2_derefidx_vbuaa +tay +lda ({z2}),y +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx=pbuz2_derefidx_vbuxx +txa +tay +lda ({z2}),y +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuyy=pbuz2_derefidx_vbuyy +lda ({z2}),y +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuaa +tay +lda {c2},y +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuxx +lda {c2},x +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuyy +lda {c2},y +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuaa_eq_pbuz2_derefidx_vbuaa_then_la1 +tay +lda ({z1}),y + +cmp ({z2}),y +beq {la1} +//FRAGMENT pbuz1_derefidx_vbuxx_eq_pbuz2_derefidx_vbuxx_then_la1 +txa +tay +lda ({z1}),y + +cmp ({z2}),y +beq {la1} +//FRAGMENT pbuz1_derefidx_vbuyy_eq_pbuz2_derefidx_vbuyy_then_la1 +lda ({z1}),y + +cmp ({z2}),y +beq {la1} +//FRAGMENT vbuyy_lt_vbuz1_then_la1 +cpy {z1} +bcc {la1} +//FRAGMENT vbuyy_lt_vbuxx_then_la1 +stx $ff +cpy $ff +bcc {la1} +//FRAGMENT vbuz1_lt_vbuyy_then_la1 +cpy {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT vbuxx_lt_vbuyy_then_la1 +sty $ff +cpx $ff +bcc {la1} +//FRAGMENT vwuz1=vwuz1_bor_vbuxx +txa +ora {z1} +sta {z1} +//FRAGMENT vwuz1=vwuz1_rol_4 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT pwuz1=pwuc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +//FRAGMENT pwuz1_derefidx_vbuc1=vwuz2 +ldy #{c1} lda {z2} sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=vbuaa -tay +iny +lda {z2}+1 sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=vbuxx +//FRAGMENT vbuz1=vbuz2_plus_2 +lda {z2} +clc +adc #2 +sta {z1} +//FRAGMENT vbuz1=vbuaa_plus_2 +clc +adc #2 +sta {z1} +//FRAGMENT vbuz1=vbuxx_plus_2 +inx +inx +stx {z1} +//FRAGMENT vbuxx_le_vbuc1_then_la1 +cpx #{c1} +bcc {la1} +beq {la1} +//FRAGMENT vbuyy_le_vbuc1_then_la1 +cpy #{c1} +bcc {la1} +beq {la1} +//FRAGMENT vbuxx=vbuz1_plus_2 +ldx {z1} +inx +inx +//FRAGMENT vbuyy=vbuz1_plus_2 +ldy {z1} +iny +iny +//FRAGMENT vbuxx=vbuaa_plus_2 +tax +inx +inx +//FRAGMENT vbuxx=vbuyy_plus_2 +tya +clc +adc #2 +tax +//FRAGMENT vbsz1_lt_vbsc1_then_la1 +lda {z1} +sec +sbc #{c1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsaa_lt_vbsc1_then_la1 +sec +sbc #{c1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsxx_lt_vbsc1_then_la1 +txa +sec +sbc #{c1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsyy_lt_vbsc1_then_la1 +tya +sec +sbc #{c1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsxx=_inc_vbsxx +inx +//FRAGMENT vbsyy=_inc_vbsyy +iny +//FRAGMENT vwsz1=vwsz1_plus_vwsc1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vwsz1=vwsz2_ror_7 +lda {z2}+1 +sta {z1} +and #$80 +beq !+ +lda #$ff +!: +sta {z1}+1 +lda {z2} +rol +rol {z1} +rol {z1}+1 +//FRAGMENT vwsz1=vwsz2_plus_vwsc1 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vwsz1=vwsz2_ror_5 +lda {z2} +sta $ff +lda {z2}+1 +sta {z1} +lda #0 +bit {z2}+1 +bpl !+ +lda #$ff +!: +sta {z1}+1 +rol $ff +rol {z1} +rol {z1}+1 +rol $ff +rol {z1} +rol {z1}+1 +rol $ff +rol {z1} +rol {z1}+1 +//FRAGMENT _deref_pbuc1=_byte_vwsz1 +lda {z1} +sta {c1} +//FRAGMENT vbuz1=_hi_vwsz2 +lda {z2}+1 +sta {z1} +//FRAGMENT vbuaa=_hi_vwsz1 +lda {z1}+1 +//FRAGMENT vbuxx=_hi_vwsz1 +ldx {z1}+1 +//FRAGMENT vbuyy=_hi_vwsz1 +ldy {z1}+1 +//FRAGMENT vwsz1=vwsc1_minus_vwsz1 +lda #<{c1} +sec +sbc {z1} +sta {z1} +lda #>{c1} +sbc {z1}+1 +sta {z1}+1 +//FRAGMENT _deref_pbsc1=vbsz1 +lda {z1} +sta {c1} +//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuz2 +lda {z2} +ldy {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuz1 +tay +lda {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuz1 +lda {z1} +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuz1 +lda {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuxx +ldy {z1} +txa +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuxx tay txa -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=vbuyy -sta $ff +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuxx +txa +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuxx +txa +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuyy tya -ldy $ff -sta ({z1}),y +ldy {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuyy +tax +tya +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuyy +tya +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuyy +tya +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT _deref_pbuc1=_deref_pbuz1 +ldy #0 +lda ({z1}),y +sta {c1} +//FRAGMENT vwuz1=pbuc1_minus_pbuz2 +sec +lda #<{c1} +sbc {z2} +sta {z1} +lda #>{c1} +sbc {z2}+1 +sta {z1}+1 +//FRAGMENT vwuz1=pbuc1_minus_pbuz1 +sec +lda #<{c1} +sbc {z1} +sta {z1} +lda #>{c1} +sbc {z1}+1 +sta {z1}+1 +//FRAGMENT pbuc1_derefidx_vbuaa=_deref_pbuz1 +tax +ldy #0 +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=_deref_pbuz1 +ldy #0 +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=_deref_pbuz1 +tya +tax +ldy #0 +lda ({z1}),y +sta {c1},x +//FRAGMENT vwsz1_neq_vbsc1_then_la1 +NO_SYNTHESIS +//FRAGMENT vwsz1_neq_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT vwuz1=_word__deref_pbuc1 +lda {c1} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_rol_8 +lda {z2} +sta {z1}+1 +lda #0 +sta {z1} +//FRAGMENT vbuz1_le_vbuz2_then_la1 +lda {z2} +cmp {z1} +bcs {la1} +//FRAGMENT pbuc1_derefidx_vbuz1=_byte_vwuz2 +ldy {z1} +lda {z2} +sta {c1},y +//FRAGMENT vwuz1=vwuz2_plus_1 +clc +lda {z2} +adc #1 +sta {z1} +lda {z2}+1 +adc #0 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_ror_4 +lda {z2}+1 +lsr +sta {z1}+1 +lda {z2} +ror +sta {z1} +lsr {z1}+1 +ror {z1} +lsr {z1}+1 +ror {z1} +lsr {z1}+1 +ror {z1} +//FRAGMENT vwuz1=vwuz2_ror_8 +lda {z2}+1 +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1_ge_vwuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc !+ +bne {la1} +lda {z1} +cmp #<{c1} +bcs {la1} +!: +//FRAGMENT vwuz1_ge_vbuc1_then_la1 +lda {z1}+1 +bne {la1} +lda {z1} +cmp #{c1} +bcs {la1} +!: +//FRAGMENT vbuxx_le_vbuz1_then_la1 +lda {z1} +stx $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuz1_le_vbuxx_then_la1 +cpx {z1} +bcs {la1} +//FRAGMENT pbuc1_derefidx_vbuxx=_byte_vwuz1 +lda {z1} +sta {c1},x +//FRAGMENT vbuz1_le_vbuyy_then_la1 +cpy {z1} +bcs {la1} +//FRAGMENT vwuz1=vwuz1_plus_1 +inc {z1} +bne !+ +inc {z1}+1 +!: +//FRAGMENT vwuz1=vwuz1_rol_8 +lda {z1} +sta {z1}+1 +lda #0 +sta {z1} +//FRAGMENT vwuz1=vwuz1_ror_4 +lsr {z1}+1 +ror {z1} +lsr {z1}+1 +ror {z1} +lsr {z1}+1 +ror {z1} +lsr {z1}+1 +ror {z1} +//FRAGMENT pwsc1_derefidx_vbuz1=vwsc2 +ldy {z1} +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT _deref_pwsc1=_deref_pwsc2 +lda {c2} +sta {c1} +lda {c2}+1 +sta {c1}+1 +//FRAGMENT pwsc1_derefidx_vbuaa=vwsc2 +tay +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT pwsc1_derefidx_vbuxx=vwsc2 +lda #<{c2} +sta {c1},x +lda #>{c2} +sta {c1}+1,x +//FRAGMENT pwsc1_derefidx_vbuyy=vwsc2 +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT vwuz1=vwuz2_plus_vbuz3 +lda {z3} +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 //FRAGMENT vwuz1=vwuz2_rol_7 lda {z2}+1 lsr @@ -8368,11 +7181,22 @@ lsr sta {z1} lda #0 sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_8 -lda {z2} -sta {z1}+1 -lda #0 +//FRAGMENT vwuz1=vwuz2_plus_vbuxx +txa +clc +adc {z2} sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_plus_vbuyy +tya +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 //FRAGMENT vwuz1=vwuz1_bxor_vwuz2 lda {z1} eor {z2} @@ -8380,180 +7204,3672 @@ sta {z1} lda {z1}+1 eor {z2}+1 sta {z1}+1 -//FRAGMENT vwuz1=_word_vduz2 +//FRAGMENT _deref_pbuc1=_byte_vwuz1 +lda {z1} +sta {c1} +//FRAGMENT pbuz1=pbuz1_plus_1 +inc {z1} +bne !+ +inc {z1}+1 +!: +//FRAGMENT vbuc1_gt_vbuz1_then_la1 +lda {z1} +cmp #{c1} +bcc {la1} +//FRAGMENT vbuz1=vbuz1_minus_vbuc1 +lax {z1} +axs #{c1} +stx {z1} +//FRAGMENT vbuc1_gt_vbuxx_then_la1 +cpx #{c1} +bcc {la1} +//FRAGMENT vwuz1=vbuz2_rol_1 lda {z2} +asl sta {z1} -lda {z2}+1 +lda #0 +rol sta {z1}+1 -//FRAGMENT vduz1=vwuz2_dword_vwuz3 -lda {z2} -sta {z1}+2 -lda {z2}+1 -sta {z1}+3 -lda {z3} -sta {z1} -lda {z3}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1_eq_vbuz2_then_la1 -lda {z2} -ldy #0 -cmp ({z1}),y -beq {la1} -//FRAGMENT _deref_pbuz1_eq_vbuxx_then_la1 +//FRAGMENT vwuz1=vbuxx_rol_1 txa -ldy #0 -cmp ({z1}),y -beq {la1} -//FRAGMENT _deref_pbuz1_eq_vbuyy_then_la1 +asl +sta {z1} +lda #0 +rol +sta {z1}+1 +//FRAGMENT vwuz1=vbuyy_rol_1 tya -ldy #0 -cmp ({z1}),y -beq {la1} -//FRAGMENT pbuz1=pbuc1_plus_vbuz2 -lda {z2} -clc -adc #<{c1} +asl sta {z1} -lda #>{c1} -adc #0 +lda #0 +rol sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuaa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuxx -txa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuyy -tya -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pwuc1_derefidx_vbuz1=vwuz2 -ldy {z1} -lda {z2} -sta {c1},y -lda {z2}+1 -sta {c1}+1,y -//FRAGMENT vbuz1=pwuc1_derefidx_vbuz2_band_vbuc2 -lda #{c2} -ldy {z2} -and {c1},y -sta {z1} -//FRAGMENT pwuc1_derefidx_vbuaa=vwuz1 -tay -lda {z1} -sta {c1},y -lda {z1}+1 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vwuz1 -lda {z1} -sta {c1},x -lda {z1}+1 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vwuz1 -lda {z1} -sta {c1},y -lda {z1}+1 -sta {c1}+1,y -//FRAGMENT vbuaa=pwuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldy {z1} -and {c1},y -//FRAGMENT vbuxx=pwuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldx {z1} -and {c1},x -tax -//FRAGMENT vbuyy=pwuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldy {z1} -and {c1},y -tay -//FRAGMENT vbuz1=pwuc1_derefidx_vbuaa_band_vbuc2 -tay -lda #{c2} -and {c1},y -sta {z1} -//FRAGMENT vbuaa=pwuc1_derefidx_vbuaa_band_vbuc2 -tay -lda #{c2} -and {c1},y -//FRAGMENT vbuxx=pwuc1_derefidx_vbuaa_band_vbuc2 -tax -lda #{c2} -and {c1},x -tax -//FRAGMENT vbuyy=pwuc1_derefidx_vbuaa_band_vbuc2 -tay -lda #{c2} -and {c1},y -tay -//FRAGMENT vbuz1=pwuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -sta {z1} -//FRAGMENT vbuaa=pwuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -//FRAGMENT vbuxx=pwuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -tax -//FRAGMENT vbuyy=pwuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -tay -//FRAGMENT vbuz1=pwuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -sta {z1} -//FRAGMENT vbuaa=pwuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -//FRAGMENT vbuxx=pwuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -tax -//FRAGMENT vbuyy=pwuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -tay -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuz2 -ldx {z2} -tay +//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuxx -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_vbuyy +tax +//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy ldx {c1},y +//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx +ldy {c1},x +//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy +lda {c1},y tay +//FRAGMENT isr_rom_sys_c64_entry + +//FRAGMENT isr_rom_sys_c64_exit +jmp $ea31 +//FRAGMENT vwsz1_neq_vwsc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT vbuz1=_bnot__deref_pbuc1 +lda {c1} +eor #$ff +sta {z1} +//FRAGMENT vbuaa=_bnot__deref_pbuc1 +lda {c1} +eor #$ff +//FRAGMENT vbuxx=_bnot__deref_pbuc1 +lda {c1} +eor #$ff +tax +//FRAGMENT vbuyy=_bnot__deref_pbuc1 +lda {c1} +eor #$ff +tay +//FRAGMENT _deref_pwsc1=vwsz1 +lda {z1} +sta {c1} +lda {z1}+1 +sta {c1}+1 +//FRAGMENT pssz1=pssc1_plus_vbuz2 +lda {z2} +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuc1=vbuz2 +lda {z2} +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuc2 +ldx {z1} +ldy #{c2} +lda ({z2}),y +sta {c1},x +//FRAGMENT pssz1=pssc1_plus_vbuaa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pssz1=pssc1_plus_vbuxx +txa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pssz1=pssc1_plus_vbuyy +tya +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pbuz1_derefidx_vbuc1=vbuaa +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuc1=vbuxx +ldy #{c1} txa sta ({z1}),y -//FRAGMENT vwsz1=vwsz2_plus_pbuz3_derefidx_vbuz4 -ldy {z4} +//FRAGMENT pbuz1_derefidx_vbuc1=vbuyy +tya +ldy #{c1} +sta ({z1}),y +//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuc2 +ldy #{c2} +lda ({z1}),y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuc2 +tya +ldy #{c2} +tax +lda ({z1}),y +sta {c1},x +//FRAGMENT pssz1=pssc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +//FRAGMENT pssz1=pssz1_plus_vbuc1 +lda #{c1} clc -lda {z2} -adc ({z3}),y +adc {z1} sta {z1} bcc !+ -inc {z2}+1 +inc {z1}+1 !: -//FRAGMENT vwsz1=vwsz2_minus_vbuc1 +//FRAGMENT pbuc1_derefidx_vbuaa=pbuz1_derefidx_vbuc2 +ldy #{c2} +tax +lda ({z1}),y +sta {c1},x +//FRAGMENT _deref_qssc1=pssc2 +lda #<{c2} +sta {c1} +lda #>{c2} +sta {c1}+1 +//FRAGMENT pssc1_neq_pssz1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT vbuz1=vbuc1_plus__deref_pbuz2 +lda #{c1} +clc +ldy #0 +adc ({z2}),y +sta {z1} +//FRAGMENT vbuz1=_lo_qssz2_derefidx_vbuc1 +ldy #{c1} +lda ({z2}),y +sta {z1} +//FRAGMENT vbuz1=_hi_qssz2_derefidx_vbuc1 +ldy #{c1}+1 +lda ({z2}),y +sta {z1} +//FRAGMENT pssz1=qssz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +pha +iny +lda ({z1}),y +sta {z1}+1 +pla +sta {z1} +//FRAGMENT vbuaa=vbuc1_plus__deref_pbuz1 +lda #{c1} +clc +ldy #0 +adc ({z1}),y +//FRAGMENT vbuxx=vbuc1_plus__deref_pbuz1 +ldy #0 +lda ({z1}),y +tax +axs #-[{c1}] +//FRAGMENT vbuyy=vbuc1_plus__deref_pbuz1 +lda #{c1} +clc +ldy #0 +adc ({z1}),y +tay +//FRAGMENT vbuaa=_lo_qssz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +//FRAGMENT vbuxx=_lo_qssz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +tax +//FRAGMENT vbuyy=_lo_qssz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +tay +//FRAGMENT vbuaa=_hi_qssz1_derefidx_vbuc1 +ldy #{c1}+1 +lda ({z1}),y +//FRAGMENT vbuxx=_hi_qssz1_derefidx_vbuc1 +ldy #{c1}+1 +lda ({z1}),y +tax +//FRAGMENT vbuyy=_hi_qssz1_derefidx_vbuc1 +ldy #{c1}+1 +lda ({z1}),y +tay +//FRAGMENT pssc1_derefidx_vbuz1=pssc2_derefidx_vbuz1_memcpy_vbuc3 +ldx #{c3} +ldy {z1} +!: +lda {c2},y +sta {c1},y +iny +dex +bne !- +//FRAGMENT pssc1_derefidx_vbuaa=pssc2_derefidx_vbuaa_memcpy_vbuc3 +ldx #{c3} +tay +!: +lda {c2},y +sta {c1},y +iny +dex +bne !- +//FRAGMENT pssc1_derefidx_vbuxx=pssc2_derefidx_vbuxx_memcpy_vbuc3 +ldy #{c3} +!: +lda {c2},x +sta {c1},x +inx +dey +bne !- +//FRAGMENT pssc1_derefidx_vbuyy=pssc2_derefidx_vbuyy_memcpy_vbuc3 +ldx #{c3} +!: +lda {c2},y +sta {c1},y +iny +dex +bne !- +//FRAGMENT vbum1_lt_vbuc1_then_la1 +lda {m1} +cmp #{c1} +bcc {la1} +//FRAGMENT pbuc1_derefidx_vbum1=vbum1 +ldy {m1} +tya +sta {c1},y +//FRAGMENT pwuc1_derefidx_vbuz1=vwuc2 +ldy {z1} +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=vwuc2 +tay +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=vwuc2 +lda #<{c2} +sta {c1},x +lda #>{c2} +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=vwuc2 +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT _deref_pbuc1_ge_vbuc2_then_la1 +lda {c1} +cmp #{c2} +bcs {la1} +//FRAGMENT vboz1=vboxx +txa +sta {z1} +//FRAGMENT vboaa=vboxx +txa +//FRAGMENT vboxx=vboaa +tax +//FRAGMENT vboxx=vboyy +tya +tax +//FRAGMENT vboyy=vboxx +txa +tay +//FRAGMENT vbuc1_ge_vbuz1_then_la1 +lda #{c1} +cmp {z1} +bcs {la1} +//FRAGMENT vbuc1_ge_vbuxx_then_la1 +cpx #{c1} +bcc {la1} +beq {la1} +//FRAGMENT vwuz1=_deref_pwuc1 +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 +//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuz2_then_la1 +ldy {z1} +lda {c1},y +cmp {z2} +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuz1_then_la1 +lda {c1},x +cmp {z1} +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuz1_then_la1 +lda {c1},y +cmp {z1} +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuxx_then_la1 +ldy {z1} +lda {c1},y +tay +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuxx_then_la1 +lda {c1},x +tay +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuxx_then_la1 +lda {c1},y +tay +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuz1_eq_vbuyy_then_la1 +ldx {z1} +lda {c1},x +tax +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuxx_eq_vbuyy_then_la1 +lda {c1},x +tax +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pbuc1_derefidx_vbuyy_eq_vbuyy_then_la1 +lda {c1},y +tax +sty $ff +cpx $ff +beq {la1} +//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_minus_1 +ldx {z1} +lda {c1},x +bne !+ +dec {c1}+1,x +!: +dec {c1},x +//FRAGMENT pwuc1_derefidx_vbuaa=pwuc1_derefidx_vbuaa_minus_1 +tax +lda {c1},x +bne !+ +dec {c1}+1,x +!: +dec {c1},x +//FRAGMENT pwuc1_derefidx_vbuxx=pwuc1_derefidx_vbuxx_minus_1 +lda {c1},x +bne !+ +dec {c1}+1,x +!: +dec {c1},x +//FRAGMENT pwuc1_derefidx_vbuyy=pwuc1_derefidx_vbuyy_minus_1 +sec +lda {c1},y +sbc #$01 +sta {c1},y +lda {c1}+1,y +sbc #$00 +sta {c1}+1,y +//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_1 +ldx {z2} +ldy {c1},x +iny +sty {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_1 +ldy {z1} +lda {c1},y +clc +adc #1 +//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_1 +ldy {z1} +ldx {c1},y +inx +//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_1 +ldx {z1} +ldy {c1},x +iny +//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_1 +tax +ldy {c1},x +iny +sty {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_1 +tay +lda {c1},y +clc +adc #1 +//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_1 +tay +ldx {c1},y +inx +//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_1 +tax +ldy {c1},x +iny +//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_1 +ldy {c1},x +iny +sty {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_1 +lda {c1},x +clc +adc #1 +//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_1 +ldy {c1},x +iny +//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_1 +ldx {c1},y +inx +stx {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_1 +lda {c1},y +clc +adc #1 +//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_1 +ldx {c1},y +inx +//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuz3 +lda {z2} +ldy {z3} +clc +adc {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +clc +adc {c1},y +//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuz2 +lda {z1} +ldx {z2} +clc +adc {c1},x +tax +//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +clc +adc {c1},y +tay +//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuz2 +ldy {z2} +txa +clc +adc {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuz1 +ldy {z1} +txa +clc +adc {c1},y +//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuz1 +txa +ldx {z1} +clc +adc {c1},x +tax +//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuz1 +ldy {z1} +txa +clc +adc {c1},y +tay +//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuz2 +tya +ldy {z2} +clc +adc {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuz1 +tya +ldy {z1} +clc +adc {c1},y +//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuz1 +ldx {z1} +tya +clc +adc {c1},x +tax +//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuz1 +tya +ldy {z1} +clc +adc {c1},y +tay +//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuxx +lda {c1},x +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuxx +lda {c1},x +clc +adc {z1} +//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuxx +lda {c1},x +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuxx +lda {c1},x +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuxx +txa +clc +adc {c1},x +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuxx +txa +clc +adc {c1},x +//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuxx +txa +clc +adc {c1},x +tax +//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuxx +txa +clc +adc {c1},x +tay +//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuxx +tya +clc +adc {c1},x +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuxx +tya +clc +adc {c1},x +//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuxx +tya +clc +adc {c1},x +tax +//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuxx +tya +clc +adc {c1},x +tay +//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuyy +lda {c1},y +clc +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuyy +lda {c1},y +clc +adc {z1} +//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuyy +lda {c1},y +clc +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuyy +lda {c1},y +clc +adc {z1} +tay +//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuyy +txa +clc +adc {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuyy +txa +clc +adc {c1},y +//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuyy +txa +clc +adc {c1},y +tax +//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuyy +txa +clc +adc {c1},y +tay +//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuyy +tya +clc +adc {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuyy +tya +clc +adc {c1},y +//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuyy +tya +clc +adc {c1},y +tax +//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuyy +tya +clc +adc {c1},y +tay +//FRAGMENT vbuz1=vbuz2_band__deref_pbuc1 +lda {c1} +and {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_band__deref_pbuc1 +lda {c1} +and {z1} +//FRAGMENT vbuxx=vbuz1_band__deref_pbuc1 +lda {c1} +and {z1} +tax +//FRAGMENT vbuyy=vbuz1_band__deref_pbuc1 +lda {c1} +and {z1} +tay +//FRAGMENT vbuz1=vbuaa_band__deref_pbuc1 +and {c1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_band__deref_pbuc1 +and {c1} +//FRAGMENT vbuxx=vbuaa_band__deref_pbuc1 +ldx {c1} +axs #0 +//FRAGMENT vbuz1=vbuxx_band__deref_pbuc1 +lda {c1} +sax {z1} +//FRAGMENT vbuz1=vbuyy_band__deref_pbuc1 +tya +and {c1} +sta {z1} +//FRAGMENT vbuaa=vbuxx_band__deref_pbuc1 +txa +and {c1} +//FRAGMENT vbuaa=vbuyy_band__deref_pbuc1 +tya +and {c1} +//FRAGMENT vbuxx=vbuxx_band__deref_pbuc1 +lda {c1} +axs #0 +//FRAGMENT vbuxx=vbuyy_band__deref_pbuc1 +ldx {c1} +tya +axs #0 +//FRAGMENT vbuyy=vbuaa_band__deref_pbuc1 +and {c1} +tay +//FRAGMENT vbuyy=vbuxx_band__deref_pbuc1 +txa +and {c1} +tay +//FRAGMENT vbuyy=vbuyy_band__deref_pbuc1 +tya +and {c1} +tay +//FRAGMENT vduz1_lt_vwuc1_then_la1 +NO_SYNTHESIS +//FRAGMENT vduz1_lt_vwsc1_then_la1 +NO_SYNTHESIS +//FRAGMENT vduz1_lt_vduc1_then_la1 +lda {z1}+3 +cmp #>{c1}>>$10 +bcc {la1} +bne !+ +lda {z1}+2 +cmp #<{c1}>>$10 +bcc {la1} +bne !+ +lda {z1}+1 +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT vduz1=vduz2_rol_4 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +lda {z2}+2 +rol +sta {z1}+2 +lda {z2}+3 +rol +sta {z1}+3 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +//FRAGMENT vduz1=vduz2_plus_vduz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +lda {z2}+2 +adc {z3}+2 +sta {z1}+2 +lda {z2}+3 +adc {z3}+3 +sta {z1}+3 +//FRAGMENT vduz1=vduz2_rol_2 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +lda {z2}+2 +rol +sta {z1}+2 +lda {z2}+3 +rol +sta {z1}+3 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +//FRAGMENT vduz1=vduz2_rol_1 +lda {z2} +asl +sta {z1} +lda {z2}+1 +rol +sta {z1}+1 +lda {z2}+2 +rol +sta {z1}+2 +lda {z2}+3 +rol +sta {z1}+3 +//FRAGMENT vduz1=vduz1_plus_vwuc1 +lda {z1} +clc +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +lda {z1}+2 +adc #0 +sta {z1}+2 +lda {z1}+3 +adc #0 +sta {z1}+3 +//FRAGMENT vduz1=vduz1_rol_2 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +asl {z1} +rol {z1}+1 +rol {z1}+2 +rol {z1}+3 +//FRAGMENT pbuz1=_deref_qbuc1 +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 +//FRAGMENT vbsz1=vbsz2 +lda {z2} +sta {z1} +//FRAGMENT vbsz1_gt_0_then_la1 +lda {z1} +cmp #0 +beq !+ +bpl {la1} +!: +//FRAGMENT vbsz1=_neg_vbsz2 +lda {z2} +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT vbsz1_neq_0_then_la1 +lda {z1} +cmp #0 +bne {la1} +//FRAGMENT vbuz1=vbuc1_minus_vbuz1 +lda #{c1} +sec +sbc {z1} +sta {z1} +//FRAGMENT vbuz1=_neg_vbuz1 +lda {z1} +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT vbsz1=vbsz2_ror_vbuz3 +lda {z2} +ldy {z3} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsz1=vbsz1_minus_vbsz2 +lda {z1} +sec +sbc {z2} +sta {z1} +//FRAGMENT vbsz1=vbsz1_plus_vbsz2 +lda {z1} +clc +adc {z2} +sta {z1} +//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +sec +sbc {c1},y +sta {z1} +//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +clc +adc {c1},y +sta {z1} +//FRAGMENT vbsz1=vbsaa +sta {z1} +//FRAGMENT vbsaa_neq_vbsc1_then_la1 +cmp #{c1} +bne {la1} +//FRAGMENT vbsaa_gt_0_then_la1 +cmp #0 +beq !+ +bpl {la1} +!: +//FRAGMENT vbsz1=_neg_vbsaa +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT vbsz1=_neg_vbsxx +txa +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT vbsz1=_neg_vbsyy +tya +eor #$ff +clc +adc #$01 +sta {z1} +//FRAGMENT vbsaa=_neg_vbsz1 +lda {z1} +eor #$ff +clc +adc #$01 +//FRAGMENT vbsaa=_neg_vbsaa +eor #$ff +clc +adc #$01 +//FRAGMENT vbsaa=_neg_vbsxx +txa +eor #$ff +clc +adc #$01 +//FRAGMENT vbsaa=_neg_vbsyy +tya +eor #$ff +clc +adc #$01 +//FRAGMENT vbsxx=_neg_vbsz1 +lda {z1} +eor #$ff +clc +adc #$01 +tax +//FRAGMENT vbsxx=_neg_vbsaa +eor #$ff +clc +adc #$01 +tax +//FRAGMENT vbsxx=_neg_vbsyy +tya +eor #$ff +clc +adc #$01 +tax +//FRAGMENT vbsyy=_neg_vbsz1 +lda {z1} +eor #$ff +clc +adc #$01 +tay +//FRAGMENT vbsyy=_neg_vbsaa +eor #$ff +clc +adc #$01 +tay +//FRAGMENT vbsyy=_neg_vbsxx +txa +eor #$ff +clc +adc #$01 +tay +//FRAGMENT vbsxx_gt_0_then_la1 +txa +cmp #0 +beq !+ +bpl {la1} +!: +//FRAGMENT vbsyy_gt_0_then_la1 +tya +cmp #0 +beq !+ +bpl {la1} +!: +//FRAGMENT vbsxx_neq_0_then_la1 +cpx #0 +bne {la1} +//FRAGMENT vbsaa=vbsz1_ror_vbuz2 +lda {z1} +ldy {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsz1_ror_vbuz2 +lda {z1} +ldx {z2} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsz1_ror_vbuz2 +lda {z1} +ldy {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsaa_ror_vbuz2 +ldy {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsaa_ror_vbuz1 +ldy {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsaa_ror_vbuz1 +ldx {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsaa_ror_vbuz1 +ldy {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsxx_ror_vbuz2 +ldy {z2} +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsxx_ror_vbuz1 +ldy {z1} +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsxx_ror_vbuz1 +txa +ldx {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsxx_ror_vbuz1 +ldy {z1} +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsyy_ror_vbuz2 +tya +ldy {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsyy_ror_vbuz1 +tya +ldy {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsyy_ror_vbuz1 +ldx {z1} +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsyy_ror_vbuz1 +tya +ldy {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsz2_ror_vbuaa +tay +lda {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsz1_ror_vbuaa +tay +lda {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsz1_ror_vbuaa +tax +lda {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsz1_ror_vbuaa +tay +lda {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsaa_ror_vbuaa +tay +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsaa_ror_vbuaa +tay +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsaa_ror_vbuaa +tax +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsaa_ror_vbuaa +tay +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsxx_ror_vbuaa +tay +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsxx_ror_vbuaa +tay +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsxx_ror_vbuaa +tay +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsxx_ror_vbuaa +tay +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsyy_ror_vbuaa +tax +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsyy_ror_vbuaa +tax +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +//FRAGMENT vbsxx=vbsyy_ror_vbuaa +tax +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsyy_ror_vbuaa +tax +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsz2_ror_vbuxx +lda {z2} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsz1_ror_vbuxx +lda {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +//FRAGMENT vbsxx=vbsz1_ror_vbuxx +lda {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsz1_ror_vbuxx +lda {z1} +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsaa_ror_vbuxx +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsaa_ror_vbuxx +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +//FRAGMENT vbsxx=vbsaa_ror_vbuxx +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsaa_ror_vbuxx +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsxx_ror_vbuxx +txa +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsxx_ror_vbuxx +txa +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +//FRAGMENT vbsxx=vbsxx_ror_vbuxx +txa +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsxx_ror_vbuxx +txa +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsyy_ror_vbuxx +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsyy_ror_vbuxx +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +//FRAGMENT vbsxx=vbsyy_ror_vbuxx +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsyy_ror_vbuxx +tya +cpx #0 +beq !e+ +!l: +cmp #$80 +ror +dex +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsz2_ror_vbuyy +lda {z2} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsz1_ror_vbuyy +lda {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsz1_ror_vbuyy +lda {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsz1_ror_vbuyy +lda {z1} +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsaa_ror_vbuyy +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsaa_ror_vbuyy +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsaa_ror_vbuyy +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsaa_ror_vbuyy +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsxx_ror_vbuyy +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsxx_ror_vbuyy +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsxx_ror_vbuyy +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsxx_ror_vbuyy +txa +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsyy_ror_vbuyy +tya +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +sta {z1} +//FRAGMENT vbsaa=vbsyy_ror_vbuyy +tya +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +//FRAGMENT vbsxx=vbsyy_ror_vbuyy +tya +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tax +//FRAGMENT vbsyy=vbsyy_ror_vbuyy +tya +cpy #0 +beq !e+ +!l: +cmp #$80 +ror +dey +bne !l- +!e: +tay +//FRAGMENT vbsz1=vbsz1_minus_vbsxx +txa +eor #$ff +sec +adc {z1} +sta {z1} +//FRAGMENT vbsz1=vbsz1_minus_vbsyy +tya +eor #$ff +sec +adc {z1} +sta {z1} +//FRAGMENT vbsxx=vbsxx_minus_vbsz1 +txa +sec +sbc {z1} +tax +//FRAGMENT vbsxx=vbsxx_minus_vbsxx +lda #0 +tax +//FRAGMENT vbsxx=vbsxx_minus_vbsyy +txa +sty $ff +sec +sbc $ff +tax +//FRAGMENT vbsyy=vbsyy_minus_vbsz1 +tya +sec +sbc {z1} +tay +//FRAGMENT vbsyy=vbsyy_minus_vbsxx +tya +stx $ff +sec +sbc $ff +tay +//FRAGMENT vbsyy=vbsyy_minus_vbsyy +lda #0 +tay +//FRAGMENT vbsz1=vbsz1_plus_vbsxx +txa +clc +adc {z1} +sta {z1} +//FRAGMENT vbsz1=vbsz1_plus_vbsyy +tya +clc +adc {z1} +sta {z1} +//FRAGMENT vbsxx=vbsxx_plus_vbsz1 +txa +clc +adc {z1} +tax +//FRAGMENT vbsxx=vbsxx_plus_vbsxx +txa +asl +tax +//FRAGMENT vbsxx=vbsxx_plus_vbsyy +txa +sty $ff +clc +adc $ff +tax +//FRAGMENT vbsyy=vbsyy_plus_vbsz1 +tya +clc +adc {z1} +tay +//FRAGMENT vbsyy=vbsyy_plus_vbsxx +txa +sty $ff +clc +adc $ff +tay +//FRAGMENT vbsyy=vbsyy_plus_vbsyy +tya +asl +tay +//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuz1 +txa +ldx {z1} +sec +sbc {c1},x +tax +//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuz1 +tya +ldy {z1} +sec +sbc {c1},y +tay +//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuxx +lda {z1} +sec +sbc {c1},x +sta {z1} +//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuxx +txa +tax +sec +sbc {c1},x +tax +//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuxx +tya +sec +sbc {c1},x +tay +//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuyy +lda {z1} +sec +sbc {c1},y +sta {z1} +//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuyy +txa +sec +sbc {c1},y +tax +//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuyy +tya +tay +sec +sbc {c1},y +tay +//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuxx +lda {c1},x +clc +adc {z1} +sta {z1} +//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuyy +lda {c1},y +clc +adc {z1} +sta {z1} +//FRAGMENT vbsxx=vbsz1 +ldx {z1} +//FRAGMENT vbsz1=vbsxx +stx {z1} +//FRAGMENT vbsyy_neq_0_then_la1 +cpy #0 +bne {la1} +//FRAGMENT vbsyy=vbsz1 +ldy {z1} +//FRAGMENT _deref_pduc1=vduz1 +lda {z1} +sta {c1} +lda {z1}+1 +sta {c1}+1 +lda {z1}+2 +sta {c1}+2 +lda {z1}+3 +sta {c1}+3 +//FRAGMENT vduz1=_dec_vduz2 +lda {z2} +sec +sbc #1 +sta {z1} +lda {z2}+1 +sbc #0 +sta {z1}+1 +lda {z2}+2 +sbc #0 +sta {z1}+2 +lda {z2}+3 +sbc #0 +sta {z1}+3 +//FRAGMENT vduz1=_inc_vduz1 +inc {z1} +bne !+ +inc {z1}+1 +bne !+ +inc {z1}+2 +bne !+ +inc {z1}+3 +!: +//FRAGMENT vduz1=vduz1_plus_vbuc1 +lda {z1} +clc +adc #{c1} +sta {z1} +bcc !+ +inc {z1}+1 +bne !+ +inc {z1}+2 +bne !+ +inc {z1}+3 +!: +//FRAGMENT vduz1=_dec_vduz1 +lda {z1} +sec +sbc #1 +sta {z1} +lda {z1}+1 +sbc #0 +sta {z1}+1 +lda {z1}+2 +sbc #0 +sta {z1}+2 +lda {z1}+3 +sbc #0 +sta {z1}+3 +//FRAGMENT vwuz1=_stackidxword_vbuc1 +tsx +lda STACK_BASE+{c1},x +sta {z1} +lda STACK_BASE+{c1}+1,x +sta {z1}+1 +//FRAGMENT _stackidxword_vbuc1=vwuz1 +tsx +lda {z1} +sta STACK_BASE+{c1},x +lda {z1}+1 +sta STACK_BASE+{c1}+1,x +//FRAGMENT _stackpushword_=vwuc1 +lda #>{c1} +pha +lda #<{c1} +pha +//FRAGMENT vwuz1=_stackpullword_ +pla +sta {z1} +pla +sta {z1}+1 +//FRAGMENT _stackpushword_=vbuc1 +lda #0 +pha +lda #<{c1} +pha +//FRAGMENT _stackidxsword_vbuc1=vwsz1 +tsx +lda {z1} +sta STACK_BASE+{c1},x +lda {z1}+1 +sta STACK_BASE+{c1}+1,x +//FRAGMENT _stackpushbyte_2 +pha +pha +//FRAGMENT vwsz1=_stackpullsword_ +pla +sta {z1} +pla +sta {z1}+1 +//FRAGMENT pbuc1_derefidx_vbuaa=_inc_pbuc1_derefidx_vbuaa +tax +inc {c1},x +//FRAGMENT vbuz1=vbuz1_bor_vbuc1 +lda #{c1} +ora {z1} +sta {z1} +//FRAGMENT vbuaa=vbuaa_bor_vbuc1 +ora #{c1} +//FRAGMENT vbuxx=vbuxx_bor_vbuc1 +txa +ora #{c1} +tax +//FRAGMENT vbuyy=vbuyy_bor_vbuc1 +tya +ora #{c1} +tay +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_(pbuc3_derefidx_vbuz1) +ldx {z1} +ldy {c3},x +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_(pbuc3_derefidx_vbuxx) +ldy {c3},x +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_(pbuc3_derefidx_vbuyy) +ldx {c3},y +lda {c2},x +sta {c1},y +//FRAGMENT vbuz1=vbuc1_bxor_vbuz2 +lda #{c1} +eor {z2} +sta {z1} +//FRAGMENT vbuz1=_deref_pbuc1_bxor_vbuc2 +lda #{c2} +eor {c1} +sta {z1} +//FRAGMENT vbuz1=vbuc1_bxor_vbuaa +eor #{c1} +sta {z1} +//FRAGMENT vbuz1=vbuc1_bxor_vbuxx +txa +eor #{c1} +sta {z1} +//FRAGMENT vbuz1=vbuc1_bxor_vbuyy +tya +eor #{c1} +sta {z1} +//FRAGMENT vbuaa=vbuc1_bxor_vbuz1 +lda #{c1} +eor {z1} +//FRAGMENT vbuaa=vbuc1_bxor_vbuaa +eor #{c1} +//FRAGMENT vbuaa=vbuc1_bxor_vbuxx +txa +eor #{c1} +//FRAGMENT vbuaa=vbuc1_bxor_vbuyy +tya +eor #{c1} +//FRAGMENT vbuxx=vbuc1_bxor_vbuz1 +lda #{c1} +eor {z1} +tax +//FRAGMENT vbuxx=vbuc1_bxor_vbuaa +eor #{c1} +tax +//FRAGMENT vbuxx=vbuc1_bxor_vbuxx +txa +eor #{c1} +tax +//FRAGMENT vbuxx=vbuc1_bxor_vbuyy +tya +eor #{c1} +tax +//FRAGMENT vbuyy=vbuc1_bxor_vbuz1 +lda #{c1} +eor {z1} +tay +//FRAGMENT vbuyy=vbuc1_bxor_vbuaa +eor #{c1} +tay +//FRAGMENT vbuyy=vbuc1_bxor_vbuxx +txa +eor #{c1} +tay +//FRAGMENT vbuyy=vbuc1_bxor_vbuyy +tya +eor #{c1} +tay +//FRAGMENT vbuaa=_deref_pbuc1_bxor_vbuc2 +lda #{c2} +eor {c1} +//FRAGMENT vbuxx=_deref_pbuc1_bxor_vbuc2 +lda #{c2} +eor {c1} +tax +//FRAGMENT vbuyy=_deref_pbuc1_bxor_vbuc2 +lda #{c2} +eor {c1} +tay +//FRAGMENT vbuaa=vbuaa_plus_2 +clc +adc #2 +//FRAGMENT vbuz1_ge__deref_pbuc1_then_la1 +lda {c1} +ldy {z1} +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuxx_ge__deref_pbuc1_then_la1 +ldy {c1} +sty $ff +cpx $ff +bcs {la1} +//FRAGMENT vbuyy_ge__deref_pbuc1_then_la1 +lda {c1} +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuz3 +ldy {z2} +lda {c1},y +sta {z1}+1 +lda {z3} +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuaa_word_vbuz2 +tay +lda {c1},y +sta {z1}+1 +lda {z2} +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_vbuz2 +lda {c1},x +sta {z1}+1 +lda {z2} +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuyy_word_vbuz2 +lda {c1},y +sta {z1}+1 +lda {z2} +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuaa +ldx {z2} +ldy {c1},x +sty {z1}+1 +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuxx +ldy {z2} +lda {c1},y +sta {z1}+1 +stx {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_vbuxx +lda {c1},x +sta {z1}+1 +stx {z1} +//FRAGMENT _deref_(_deref_qwuc1)=_deref_(_deref_qwuc2) +ldy {c2} +sty $fe +ldy {c2}+1 +sty $ff +ldy #0 +lda ($fe),y +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_pbuc1_eq__deref_pbuc2_then_la1 +lda {c1} +cmp {c2} +beq {la1} +//FRAGMENT _deref_pbsc1=_deref_pbsc2 +lda {c2} +sta {c1} +//FRAGMENT vbuz1=_deref_pbuc1_plus_1 +ldy {c1} +iny +sty {z1} +//FRAGMENT vbuz1=_deref_pbuc1_minus_1 +ldx {c1} +dex +stx {z1} +//FRAGMENT vbuz1=_deref_pbuc1_plus_vbuc2 +lda #{c2} +clc +adc {c1} +sta {z1} +//FRAGMENT vbuz1=_deref_pbuc1_minus_vbuc2 +lda {c1} +sec +sbc #{c2} +sta {z1} +//FRAGMENT vbuz1=vbuz2_minus_vbuz3 +lda {z2} +sec +sbc {z3} +sta {z1} +//FRAGMENT vbuz1_ge_vbuz2_then_la1 +lda {z1} +cmp {z2} +bcs {la1} +//FRAGMENT vbuaa=_deref_pbuc1_plus_1 +lda {c1} +clc +adc #1 +//FRAGMENT vbuaa=_deref_pbuc1_minus_1 +lda {c1} +sec +sbc #1 +//FRAGMENT vbuaa=_deref_pbuc1_plus_vbuc2 +lda #{c2} +clc +adc {c1} +//FRAGMENT vbuxx=_deref_pbuc1_plus_vbuc2 +lda {c1} +tax +axs #-[{c2}] +//FRAGMENT vbuyy=_deref_pbuc1_plus_vbuc2 +lda #{c2} +clc +adc {c1} +tay +//FRAGMENT vbuaa=_deref_pbuc1_minus_vbuc2 +lda {c1} +sec +sbc #{c2} +//FRAGMENT vbuxx=_deref_pbuc1_minus_vbuc2 +lda {c1} +tax +axs #{c2} +//FRAGMENT vbuyy=_deref_pbuc1_minus_vbuc2 +lda {c1} +sec +sbc #{c2} +tay +//FRAGMENT vbuaa_neq_vbuz1_then_la1 +cmp {z1} +bne {la1} +//FRAGMENT vbuaa=vbuz1_minus_vbuz2 +lda {z1} +sec +sbc {z2} +//FRAGMENT vbuxx=vbuz1_minus_vbuz2 +lda {z1} +sec +sbc {z2} +tax +//FRAGMENT vbuyy=vbuz1_minus_vbuz2 +lda {z1} +sec +sbc {z2} +tay +//FRAGMENT vbuz1=vbuaa_minus_vbuz2 +sec +sbc {z2} +sta {z1} +//FRAGMENT vbuxx=vbuaa_minus_vbuz1 +sec +sbc {z1} +tax +//FRAGMENT vbuyy=vbuaa_minus_vbuz1 +sec +sbc {z1} +tay +//FRAGMENT vbuz1=vbuxx_minus_vbuz2 +txa +sec +sbc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuxx_minus_vbuz1 +txa +sec +sbc {z1} +//FRAGMENT vbuyy=vbuxx_minus_vbuz1 +txa +sec +sbc {z1} +tay +//FRAGMENT vbuz1=vbuyy_minus_vbuz2 +tya +sec +sbc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuyy_minus_vbuz1 +tya +sec +sbc {z1} +//FRAGMENT vbuxx=vbuyy_minus_vbuz1 +tya +sec +sbc {z1} +tax +//FRAGMENT vbuz1=vbuz2_minus_vbuaa +eor #$ff +sec +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_minus_vbuaa +eor #$ff +sec +adc {z1} +//FRAGMENT vbuxx=vbuz1_minus_vbuaa +eor #$ff +sec +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_minus_vbuaa +eor #$ff +sec +adc {z1} +tay +//FRAGMENT vbuz1=vbuaa_minus_vbuaa +lda #0 +sta {z1} +//FRAGMENT vbuxx=vbuaa_minus_vbuaa +lda #0 +tax +//FRAGMENT vbuyy=vbuaa_minus_vbuaa +lda #0 +tay +//FRAGMENT vbuz1=vbuxx_minus_vbuaa +sta $ff +txa +sec +sbc $ff +sta {z1} +//FRAGMENT vbuaa=vbuxx_minus_vbuaa +sta $ff +txa +sec +sbc $ff +//FRAGMENT vbuyy=vbuxx_minus_vbuaa +sta $ff +txa +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuyy_minus_vbuaa +sta $ff +tya +sec +sbc $ff +sta {z1} +//FRAGMENT vbuaa=vbuyy_minus_vbuaa +sta $ff +tya +sec +sbc $ff +//FRAGMENT vbuxx=vbuyy_minus_vbuaa +sta $ff +tya +sec +sbc $ff +tax +//FRAGMENT vbuz1=vbuz2_minus_vbuxx +txa +eor #$ff +sec +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_minus_vbuxx +txa +eor #$ff +sec +adc {z1} +//FRAGMENT vbuxx=vbuz1_minus_vbuxx +txa +eor #$ff +sec +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_minus_vbuxx +txa +eor #$ff +sec +adc {z1} +tay +//FRAGMENT vbuz1=vbuaa_minus_vbuxx +stx $ff +sec +sbc $ff +sta {z1} +//FRAGMENT vbuxx=vbuaa_minus_vbuxx +stx $ff +sec +sbc $ff +tax +//FRAGMENT vbuyy=vbuaa_minus_vbuxx +stx $ff +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuxx_minus_vbuxx +lda #0 +sta {z1} +//FRAGMENT vbuaa=vbuxx_minus_vbuxx +lda #0 +//FRAGMENT vbuyy=vbuxx_minus_vbuxx +lda #0 +tay +//FRAGMENT vbuz1=vbuyy_minus_vbuxx +tya +stx $ff +sec +sbc $ff +sta {z1} +//FRAGMENT vbuaa=vbuyy_minus_vbuxx +tya +stx $ff +sec +sbc $ff +//FRAGMENT vbuxx=vbuyy_minus_vbuxx +tya +stx $ff +sec +sbc $ff +tax +//FRAGMENT vbuz1=vbuz2_minus_vbuyy +tya +eor #$ff +sec +adc {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_minus_vbuyy +tya +eor #$ff +sec +adc {z1} +//FRAGMENT vbuxx=vbuz1_minus_vbuyy +tya +eor #$ff +sec +adc {z1} +tax +//FRAGMENT vbuyy=vbuz1_minus_vbuyy +tya +eor #$ff +sec +adc {z1} +tay +//FRAGMENT vbuz1=vbuaa_minus_vbuyy +sty $ff +sec +sbc $ff +sta {z1} +//FRAGMENT vbuxx=vbuaa_minus_vbuyy +sty $ff +sec +sbc $ff +tax +//FRAGMENT vbuyy=vbuaa_minus_vbuyy +sty $ff +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuxx_minus_vbuyy +txa +sty $ff +sec +sbc $ff +sta {z1} +//FRAGMENT vbuaa=vbuxx_minus_vbuyy +txa +sty $ff +sec +sbc $ff +//FRAGMENT vbuyy=vbuxx_minus_vbuyy +txa +sty $ff +sec +sbc $ff +tay +//FRAGMENT vbuz1=vbuyy_minus_vbuyy +lda #0 +sta {z1} +//FRAGMENT vbuaa=vbuyy_minus_vbuyy +lda #0 +//FRAGMENT vbuxx=vbuyy_minus_vbuyy +lda #0 +tax +//FRAGMENT vbuaa_ge_vbuz1_then_la1 +cmp {z1} +bcs {la1} +//FRAGMENT vbuxx_ge_vbuz1_then_la1 +cpx {z1} +bcs {la1} +//FRAGMENT vbuyy_ge_vbuz1_then_la1 +cpy {z1} +bcs {la1} +//FRAGMENT vbuz1_ge_vbuxx_then_la1 +lda {z1} +stx $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuaa_ge_vbuxx_then_la1 +stx $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuyy_ge_vbuxx_then_la1 +stx $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuz1_ge_vbuyy_then_la1 +lda {z1} +sty $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuaa_ge_vbuyy_then_la1 +sty $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuxx_ge_vbuyy_then_la1 +sty $ff +cpx $ff +bcs {la1} +//FRAGMENT vbuxx=_deref_pbuc1_plus_1 +ldx {c1} +inx +//FRAGMENT vbuyy=_deref_pbuc1_plus_1 +ldy {c1} +iny +//FRAGMENT vbuxx=_deref_pbuc1_minus_1 +ldx {c1} +dex +//FRAGMENT vbuyy=_deref_pbuc1_minus_1 +lda {c1} +tay +dey +//FRAGMENT vbsz1_neq_vbsz2_then_la1 +lda {z1} +cmp {z2} +bne {la1} +//FRAGMENT vbsz1_neq_vbsxx_then_la1 +cpx {z1} +bne {la1} +//FRAGMENT vbsxx_neq_vbsz1_then_la1 +cpx {z1} +bne {la1} +//FRAGMENT pwuz1=pwuc1_plus_vwuz2 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT pwuz1=pwuc1_plus_vwuz1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT vwuz1=vwuz2_plus_vbuaa +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT _deref_pbuz1=vbum2 +lda {m2} +ldy #0 +sta ({z1}),y +//FRAGMENT pbuc1_derefidx_vbum1=vbuc2 +lda #{c2} +ldy {m1} +sta {c1},y +//FRAGMENT vbuz1=vbum2 +lda {m2} +sta {z1} +//FRAGMENT vbuaa=vbum1 +lda {m1} +//FRAGMENT vbuxx=vbum1 +ldx {m1} +//FRAGMENT vbuyy=vbum1 +ldy {m1} +//FRAGMENT qbuc1_derefidx_vbuz1=pbuc2 +ldy {z1} +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT qbuc1_derefidx_vbuaa=pbuc2 +tay +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT qbuc1_derefidx_vbuxx=pbuc2 +lda #<{c2} +sta {c1},x +lda #>{c2} +sta {c1}+1,x +//FRAGMENT qbuc1_derefidx_vbuyy=pbuc2 +lda #<{c2} +sta {c1},y +lda #>{c2} +sta {c1}+1,y +//FRAGMENT pbuz1_ge_pbuc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bcc !+ +bne {la1} +lda {z1} +cmp #<{c1} +bcs {la1} +!: +//FRAGMENT vbuz1=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +sta {z1} +//FRAGMENT vbuz1=_deref_pbuc1_ror_1 +lda {c1} +lsr +sta {z1} +//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuz2_then_la1 +ldy {z2} +lda {c1}+1,y +cmp {z1}+1 +bne !+ +lda {c1},y +cmp {z1} +beq {la1} +!: +bcc {la1} +//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c2},y +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_qbuc1=_inc__deref_qbuc1 +inc {c1} +bne !+ +inc {c1}+1 +!: +//FRAGMENT vbuaa=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +//FRAGMENT vbuxx=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +tax +//FRAGMENT vbuyy=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +tay +//FRAGMENT vbuaa=_deref_pbuc1_ror_1 +lda {c1} +lsr +//FRAGMENT vbuxx=_deref_pbuc1_ror_1 +lda {c1} +lsr +tax +//FRAGMENT vbuyy=_deref_pbuc1_ror_1 +lda {c1} +lsr +tay +//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuaa_then_la1 +tay +lda {c1}+1,y +cmp {z1}+1 +bne !+ +lda {c1},y +cmp {z1} +beq {la1} +!: +bcc {la1} +//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuxx_then_la1 +lda {c1}+1,x +cmp {z1}+1 +bne !+ +lda {c1},x +cmp {z1} +beq {la1} +!: +bcc {la1} +//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuyy_then_la1 +lda {c1}+1,y +cmp {z1}+1 +bne !+ +lda {c1},y +cmp {z1} +beq {la1} +!: +bcc {la1} +//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuaa +tay +lda {c2},y +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuxx +lda {c2},x +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuyy +lda {c2},y +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_pwuz1=vbuz2 +lda {z2} +ldy #0 +sta ({z1}),y +tya +iny +sta ({z1}),y +//FRAGMENT _deref_pwuz1=vbuaa +ldy #0 +sta ({z1}),y +tya +iny +sta ({z1}),y +//FRAGMENT _deref_pwuz1=vbuxx +txa +ldy #0 +sta ({z1}),y +tya +iny +sta ({z1}),y +//FRAGMENT _deref_pwuz1=vbuyy +tya +ldy #0 +sta ({z1}),y +tya +iny +sta ({z1}),y +//FRAGMENT vbsz1=vbsz2_rol_1 +lda {z2} +asl +sta {z1} +//FRAGMENT vbsaa=vbsz1_rol_1 +lda {z1} +asl +//FRAGMENT vbsxx=vbsz1_rol_1 +lda {z1} +asl +tax +//FRAGMENT vbsyy=vbsz1_rol_1 +lda {z1} +asl +tay +//FRAGMENT vbsz1=vbsaa_rol_1 +asl +sta {z1} +//FRAGMENT vbsaa=vbsaa_rol_1 +asl +//FRAGMENT vbsxx=vbsaa_rol_1 +asl +tax +//FRAGMENT vbsyy=vbsaa_rol_1 +asl +tay +//FRAGMENT vbsz1=vbsxx_rol_1 +txa +asl +sta {z1} +//FRAGMENT vbsaa=vbsxx_rol_1 +txa +asl +//FRAGMENT vbsxx=vbsxx_rol_1 +txa +asl +tax +//FRAGMENT vbsyy=vbsxx_rol_1 +txa +asl +tay +//FRAGMENT vbsz1=vbsyy_rol_1 +tya +asl +sta {z1} +//FRAGMENT vbsaa=vbsyy_rol_1 +tya +asl +//FRAGMENT vbsxx=vbsyy_rol_1 +tya +asl +tax +//FRAGMENT vbsyy=vbsyy_rol_1 +tya +asl +tay +//FRAGMENT vwuz1=_deref_pwuz2 +ldy #0 +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT pwsz1=pwsc1 +lda #<{c1} +sta {z1} +lda #>{c1} +sta {z1}+1 +//FRAGMENT pwsz1=pwsc1_plus_vbuz2 +lda {z2} +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pwsc1_derefidx_vbuz1=_deref_pwsz2 +ldx {z1} +ldy #0 +lda ({z2}),y +sta {c1},x +iny +lda ({z2}),y +sta {c1}+1,x +//FRAGMENT pwsz1=pwsc1_plus_vbuaa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pwsz1=pwsc1_plus_vbuxx +txa +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pwsz1=pwsc1_plus_vbuyy +tya +clc +adc #<{c1} +sta {z1} +lda #>{c1} +adc #0 +sta {z1}+1 +//FRAGMENT pwsc1_derefidx_vbuaa=_deref_pwsz1 +tax +ldy #0 +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT pwsc1_derefidx_vbuxx=_deref_pwsz1 +ldy #0 +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT pwsc1_derefidx_vbuyy=_deref_pwsz1 +tya +tax +ldy #0 +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1} +//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuz2 +ldy {z2} +lda {c1}+1,y +sta {z1} +//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuz1 +ldy {z1} +lda {c1},y +//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuz1 +ldx {z1} +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuz1 +ldy {z1} +lda {c1},y +tay +//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuaa +tay +lda {c1},y +sta {z1} +//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuaa +tay +lda {c1},y +//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuaa +tax +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuaa +tay +lda {c1},y +tay +//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuxx +lda {c1},x +sta {z1} +//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuxx +lda {c1},x +//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuxx +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuxx +lda {c1},x +tay +//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuyy +lda {c1},y +sta {z1} +//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuyy +lda {c1},y +//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuyy +lda {c1},y +tax +//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuyy +lda {c1},y +tay +//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuz1 +ldy {z1} +lda {c1}+1,y +//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuz1 +ldx {z1} +lda {c1}+1,x +tax +//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuz1 +ldy {z1} +lda {c1}+1,y +tay +//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuxx +lda {c1}+1,x +sta {z1} +//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuxx +lda {c1}+1,x +//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuxx +lda {c1}+1,x +tax +//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuxx +lda {c1}+1,x +tay +//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuyy +lda {c1}+1,y +sta {z1} +//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuyy +lda {c1}+1,y +//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuyy +lda {c1}+1,y +tax +//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuyy +lda {c1}+1,y +tay +//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1} +//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuz2 +ldy {z2} +lda {c1}+1,y +sta {z1} +//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuz1 +ldy {z1} +lda {c1},y +//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuz1 +ldx {z1} +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuz1 +ldy {z1} +lda {c1},y +tay +//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuxx +lda {c1},x +sta {z1} +//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuxx +lda {c1},x +//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuxx +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuxx +lda {c1},x +tay +//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuyy +lda {c1},y +sta {z1} +//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuyy +lda {c1},y +//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuyy +lda {c1},y +tax +//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuyy +lda {c1},y +tay +//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuz1 +ldy {z1} +lda {c1}+1,y +//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuz1 +ldx {z1} +lda {c1}+1,x +tax +//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuz1 +ldy {z1} +lda {c1}+1,y +tay +//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuxx +lda {c1}+1,x +sta {z1} +//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuxx +lda {c1}+1,x +//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuxx +lda {c1}+1,x +tax +//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuxx +lda {c1}+1,x +tay +//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuyy +lda {c1}+1,y +sta {z1} +//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuyy +lda {c1}+1,y +//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuyy +lda {c1}+1,y +tax +//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuyy +lda {c1}+1,y +tay +//FRAGMENT pbuz1=pbuz2_plus_1 +clc +lda {z2} +adc #1 +sta {z1} +lda {z2}+1 +adc #0 +sta {z1}+1 +//FRAGMENT vbuz1=vbuz2_ror_2 +lda {z2} +lsr +lsr +sta {z1} +//FRAGMENT vbuz1=vbuaa_ror_2 +lsr +lsr +sta {z1} +//FRAGMENT vbuz1=vbuxx_ror_2 +txa +lsr +lsr +sta {z1} +//FRAGMENT vbuz1=vbuyy_ror_2 +tya +lsr +lsr +sta {z1} +//FRAGMENT vbuaa=vbuz1_ror_2 +lda {z1} +lsr +lsr +//FRAGMENT vbuaa=vbuaa_ror_2 +lsr +lsr +//FRAGMENT vbuaa=vbuxx_ror_2 +txa +lsr +lsr +//FRAGMENT vbuaa=vbuyy_ror_2 +tya +lsr +lsr +//FRAGMENT vbuxx=vbuz1_ror_2 +lda {z1} +lsr +lsr +tax +//FRAGMENT vbuxx=vbuaa_ror_2 +lsr +lsr +tax +//FRAGMENT vbuxx=vbuxx_ror_2 +txa +lsr +lsr +tax +//FRAGMENT vbuxx=vbuyy_ror_2 +tya +lsr +lsr +tax +//FRAGMENT vbuyy=vbuz1_ror_2 +lda {z1} +lsr +lsr +tay +//FRAGMENT vbuyy=vbuaa_ror_2 +lsr +lsr +tay +//FRAGMENT vbuyy=vbuxx_ror_2 +txa +lsr +lsr +tay +//FRAGMENT vbuyy=vbuyy_ror_2 +tya +lsr +lsr +tay +//FRAGMENT vwuz1=vbuz2_band_vbuc1 +lda {z2} +and #{c1} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vbuaa_band_vbuc1 +and #{c1} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vbuxx_band_vbuc1 +txa +and #{c1} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuz1=vbuyy_band_vbuc1 +tya +and #{c1} +sta {z1} +lda #0 +sta {z1}+1 +//FRAGMENT vwuc1_le_vwuc2_then_la1 +lda #>{c1} +cmp #>{c2} +bne !+ +lda #<{c1} +cmp #<{c2} +beq {la1} +!: +bcc {la1} +//FRAGMENT pbuz1_derefidx_vbuc1=_byte_vwuz2 +ldy #{c1} +lda {z2} +sta ({z1}),y +//FRAGMENT pssz1=pssc1_plus_vwuz2 +clc +lda {z2} +adc #<{c1} +sta {z1} +lda {z2}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT _deref_pssz1=_deref_pssz2_memcpy_vbuc1 +ldy #00 +!: +lda ({z2}),y +sta ({z1}),y +iny +cpy #{c1} +bne !- +//FRAGMENT pssz1=pssc1_plus_vwuz1 +clc +lda {z1} +adc #<{c1} +sta {z1} +lda {z1}+1 +adc #>{c1} +sta {z1}+1 +//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuc2 +lda #{c2} +clc +adc {c1} +sta {c1} +//FRAGMENT vbuz1=pbuz2_derefidx_vbuc1 +ldy #{c1} +lda ({z2}),y +sta {z1} +//FRAGMENT pssz1=pssz2_plus_vbuc1 +lda #{c1} +clc +adc {z2} +sta {z1} +lda #0 +adc {z2}+1 +sta {z1}+1 +//FRAGMENT vbuaa=pbuz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +//FRAGMENT vbuxx=pbuz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +tax +//FRAGMENT vbuyy=pbuz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +tay +//FRAGMENT vbuz1_lt__deref_pbuc1_then_la1 +lda {z1} +cmp {c1} +bcc {la1} +//FRAGMENT pwuc1_derefidx_vbuz1=(_deref_qwuc2)_derefidx_vbuz1 +ldy {z1} +lda {c2} +sta $fe +lda {c2}+1 +sta $ff +lda ($fe),y +sta {c1},y +iny +lda ($fe),y +sta {c1},y +//FRAGMENT vbuaa_lt__deref_pbuc1_then_la1 +cmp {c1} +bcc {la1} +//FRAGMENT pwuc1_derefidx_vbuaa=(_deref_qwuc2)_derefidx_vbuaa +tay +lda {c2} +sta $fe +lda {c2}+1 +sta $ff +lda ($fe),y +sta {c1},y +iny +lda ($fe),y +sta {c1},y +//FRAGMENT pwuc1_derefidx_vbuxx=(_deref_qwuc2)_derefidx_vbuxx +txa +tay +lda {c2} +sta $fe +lda {c2}+1 +sta $ff +lda ($fe),y +sta {c1},y +iny +lda ($fe),y +sta {c1},y +//FRAGMENT pwuc1_derefidx_vbuyy=(_deref_qwuc2)_derefidx_vbuyy +lda {c2} +sta $fe +lda {c2}+1 +sta $ff +lda ($fe),y +sta {c1},y +iny +lda ($fe),y +sta {c1},y +//FRAGMENT vbuxx_lt__deref_pbuc1_then_la1 +cpx {c1} +bcc {la1} +//FRAGMENT pssz1_neq_pssc1_then_la1 +lda {z1}+1 +cmp #>{c1} +bne {la1} +lda {z1} +cmp #<{c1} +bne {la1} +//FRAGMENT pssz1=pssz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_(_deref_pbuz2) +ldy #0 +lda ({z2}),y +tay +lda {c2},y +ldy {z1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_(_deref_pbuz1) +tax +ldy #0 +lda ({z1}),y +tay +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_(_deref_pbuz1) +ldy #0 +lda ({z1}),y +tay +lda {c2},y +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_(_deref_pbuz1) +tya +tax +ldy #0 +lda ({z1}),y +tay +lda {c2},y +sta {c1},x +//FRAGMENT _deref_pwuc1=vbuc2 +lda #0 +sta {c1}+1 +lda #<{c2} +sta {c1} +//FRAGMENT qssz1=qssc1_plus_vwsz2 +lda #<{c1} +clc +adc {z2} +sta {z1} +lda #>{c1} +adc {z2}+1 +sta {z1}+1 +//FRAGMENT pssz1=_deref_qssz2 +ldy #0 +lda ({z2}),y +sta {z1} +iny +lda ({z2}),y +sta {z1}+1 +//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuc1 +ldy #{c1} +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT qssz1=qssc1_plus_vwsz1 +lda #<{c1} +clc +adc {z1} +sta {z1} +lda #>{c1} +adc {z1}+1 +sta {z1}+1 +//FRAGMENT pssz1=_deref_qssz1 +ldy #0 +lda ({z1}),y +pha +iny +lda ({z1}),y +sta {z1}+1 +pla +sta {z1} +//FRAGMENT vwuz1=_deref_pbuz2_word__deref_pbuz3 +ldy #0 +lda ({z3}),y +sta {z1} +lda ({z2}),y +sta {z1}+1 +//FRAGMENT 0_neq_vwuz1_then_la1 +lda {z1} +ora {z1}+1 +bne {la1} +//FRAGMENT _deref_pbuz1=_byte_vwsz2 +lda {z2} +ldy #0 +sta ({z1}),y +//FRAGMENT vbuz1=vbuxx_band_pbuz2_derefidx_vbuc1 +ldy #{c1} +txa +and ({z2}),y +sta {z1} +//FRAGMENT vbuaa=vbuxx_band_pbuz1_derefidx_vbuc1 +ldy #{c1} +txa +and ({z1}),y +//FRAGMENT vbuxx=vbuxx_band_pbuz1_derefidx_vbuc1 +ldy #{c1} +lda ({z1}),y +axs #0 +//FRAGMENT vbuyy=vbuxx_band_pbuz1_derefidx_vbuc1 +ldy #{c1} +txa +and ({z1}),y +tay +//FRAGMENT _deref_pbuc1_eq_vbuc2_then_la1 +lda #{c2} +cmp {c1} +beq {la1} +//FRAGMENT vbuz1=vbuz2_ror_3 +lda {z2} +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbsz1=vbsz2_ror_1 +lda {z2} +cmp #$80 +ror +sta {z1} +//FRAGMENT vbuaa=vbuz1_ror_3 +lda {z1} +lsr +lsr +lsr +//FRAGMENT vbuxx=vbuz1_ror_3 +lda {z1} +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=vbuz1_ror_3 +lda {z1} +lsr +lsr +lsr +tay +//FRAGMENT vbuz1=vbuxx_ror_3 +txa +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbuaa=vbuxx_ror_3 +txa +lsr +lsr +lsr +//FRAGMENT vbuxx=vbuxx_ror_3 +txa +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=vbuxx_ror_3 +txa +lsr +lsr +lsr +tay +//FRAGMENT vbuz1=vbuyy_ror_3 +tya +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbuaa=vbuyy_ror_3 +tya +lsr +lsr +lsr +//FRAGMENT vbuxx=vbuyy_ror_3 +tya +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=vbuyy_ror_3 +tya +lsr +lsr +lsr +tay +//FRAGMENT vbsaa=vbsz1_ror_1 +lda {z1} +cmp #$80 +ror +//FRAGMENT vbsxx=vbsz1_ror_1 +lda {z1} +cmp #$80 +ror +tax +//FRAGMENT vbsyy=vbsz1_ror_1 +lda {z1} +cmp #$80 +ror +tay +//FRAGMENT vbsz1=vbsaa_ror_1 +cmp #$80 +ror +sta {z1} +//FRAGMENT vbsaa=vbsaa_ror_1 +cmp #$80 +ror +//FRAGMENT vbsxx=vbsaa_ror_1 +cmp #$80 +ror +tax +//FRAGMENT vbsyy=vbsaa_ror_1 +cmp #$80 +ror +tay +//FRAGMENT vbsz1=vbsxx_ror_1 +txa +cmp #$80 +ror +sta {z1} +//FRAGMENT vbsaa=vbsxx_ror_1 +txa +cmp #$80 +ror +//FRAGMENT vbsxx=vbsxx_ror_1 +txa +cmp #$80 +ror +tax +//FRAGMENT vbsyy=vbsxx_ror_1 +txa +cmp #$80 +ror +tay +//FRAGMENT vbsz1=vbsyy_ror_1 +tya +cmp #$80 +ror +sta {z1} +//FRAGMENT vbsaa=vbsyy_ror_1 +tya +cmp #$80 +ror +//FRAGMENT vbsxx=vbsyy_ror_1 +tya +cmp #$80 +ror +tax +//FRAGMENT vbsyy=vbsyy_ror_1 +tya +cmp #$80 +ror +tay +//FRAGMENT vbuz1=vbuz2_band_vbuz3 +lda {z2} +and {z3} +sta {z1} +//FRAGMENT vbuz1=vbuaa_band_vbuz2 +and {z2} +sta {z1} +//FRAGMENT vbuz1=vbuxx_band_vbuz2 +lda {z2} +sax {z1} +//FRAGMENT vbuz1=vbuyy_band_vbuz2 +tya +and {z2} +sta {z1} +//FRAGMENT vbuz1=vbuz2_band_vbuxx +lda {z2} +sax {z1} +//FRAGMENT vbuz1=vbuaa_band_vbuxx +sax {z1} +//FRAGMENT vbuaa=vbuz1_band_vbuz2 +lda {z1} +and {z2} +//FRAGMENT vbuaa=vbuaa_band_vbuz1 +and {z1} +//FRAGMENT vbuaa=vbuxx_band_vbuz1 +txa +and {z1} +//FRAGMENT vbuaa=vbuyy_band_vbuz1 +tya +and {z1} +//FRAGMENT vbuxx=vbuz1_band_vbuz2 +lda {z1} +and {z2} +tax +//FRAGMENT vbuxx=vbuaa_band_vbuz1 +ldx {z1} +axs #0 +//FRAGMENT vbuxx=vbuxx_band_vbuz1 +lda {z1} +axs #0 +//FRAGMENT vbuxx=vbuyy_band_vbuz1 +ldx {z1} +tya +axs #0 +//FRAGMENT vbuyy=vbuz1_band_vbuz2 +lda {z1} +and {z2} +tay +//FRAGMENT vbuyy=vbuaa_band_vbuz1 +and {z1} +tay +//FRAGMENT vbuyy=vbuxx_band_vbuz1 +txa +and {z1} +tay +//FRAGMENT vbuyy=vbuyy_band_vbuz1 +tya +and {z1} +tay +//FRAGMENT pbuc1_derefidx_vbuz1=vbum2 +lda {m2} +ldy {z1} +sta {c1},y +//FRAGMENT vbum1=vbum1_plus_vbuz2 +lda {m1} +clc +adc {z2} +sta {m1} +//FRAGMENT pbuc1_derefidx_vbuaa=vbum1 +tay +lda {m1} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=vbum1 +lda {m1} +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=vbum1 +lda {m1} +sta {c1},y +//FRAGMENT vbum1=vbum1_plus_vbuxx +txa +clc +adc {m1} +sta {m1} +//FRAGMENT vbum1=vbum1_plus_vbuyy +tya +clc +adc {m1} +sta {m1} +//FRAGMENT pbuc1_derefidx_vbuz1=_deref_pbuc2 +lda {c2} +ldy {z1} +sta {c1},y +//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuz1 +lda {c1} +clc +adc {z1} +sta {c1} +//FRAGMENT pbuc1_derefidx_vbuaa=_deref_pbuc2 +tay +lda {c2} +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=_deref_pbuc2 +lda {c2} +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=_deref_pbuc2 +lda {c2} +sta {c1},y +//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuxx +txa +clc +adc {c1} +sta {c1} +//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuyy +tya +clc +adc {c1} +sta {c1} +//FRAGMENT pbum1=pbum1_plus_vbuc1 +lda #{c1} +clc +adc {m1} +sta {m1} +bcc !+ +inc {m1}+1 +!: +//FRAGMENT vwsz1=vwsz1_plus_vbsz2 +lda {z2} +pha +clc +adc {z1} +sta {z1} +pla +ora #$7f +bmi !+ +lda #0 +!: +adc {z1}+1 +sta {z1}+1 +//FRAGMENT vwsz1=vwsz1_plus_vbsaa +pha +clc +adc {z1} +sta {z1} +pla +ora #$7f +bmi !+ +lda #0 +!: +adc {z1}+1 +sta {z1}+1 +//FRAGMENT vwsz1=vwsz1_plus_vbsxx +txa +pha +clc +adc {z1} +sta {z1} +pla +ora #$7f +bmi !+ +lda #0 +!: +adc {z1}+1 +sta {z1}+1 +//FRAGMENT vwsz1=vwsz1_plus_vbsyy +tya +pha +clc +adc {z1} +sta {z1} +pla +ora #$7f +bmi !+ +lda #0 +!: +adc {z1}+1 +sta {z1}+1 +//FRAGMENT pwsc1_derefidx_vbuz1_ge_vwsz2_then_la1 +ldy {z1} +lda {c1},y +cmp {z2} +lda {c1}+1,y +sbc {z2}+1 +bvc !+ +eor #$80 +!: +bpl {la1} +//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuaa +tay +lda {c1},y +sta {z1} +//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuaa +tay +lda {c1},y +//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuaa +tax +lda {c1},x +tax +//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuaa +tay +lda {c1},y +tay +//FRAGMENT pwsc1_derefidx_vbuaa_ge_vwsz1_then_la1 +tay +lda {c1},y +cmp {z1} +lda {c1}+1,y +sbc {z1}+1 +bvc !+ +eor #$80 +!: +bpl {la1} +//FRAGMENT pwsc1_derefidx_vbuxx_ge_vwsz1_then_la1 +lda {c1},x +cmp {z1} +lda {c1}+1,x +sbc {z1}+1 +bvc !+ +eor #$80 +!: +bpl {la1} +//FRAGMENT pwsc1_derefidx_vbuyy_ge_vwsz1_then_la1 +lda {c1},y +cmp {z1} +lda {c1}+1,y +sbc {z1}+1 +bvc !+ +eor #$80 +!: +bpl {la1} +//FRAGMENT pbuz1_derefidx_vbuz2=vbuz2 +lda {z2} +tay +sta ({z1}),y +//FRAGMENT pbuz1=pbuz2_minus_vbuc1 sec lda {z2} sbc #{c1} @@ -8561,25 +10877,646 @@ sta {z1} lda {z2}+1 sbc #0 sta {z1}+1 -//FRAGMENT vwsz1=vwsz2_plus_pbuz3_derefidx_vbuxx +//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuz2 +ldy {z2} +lda {c1},y +clc +adc {c2},y +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c1},y +clc +adc {c2},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 +ldx {z1} +lda {c1},x +clc +adc {c2},x +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c1},y +clc +adc {c2},y +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa +tay +lda {c1},y +clc +adc {c2},y +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa +tay +lda {c1},y +clc +adc {c2},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa +tax +lda {c1},x +clc +adc {c2},x +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa +tay +lda {c1},y +clc +adc {c2},y +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx +lda {c1},x +clc +adc {c2},x +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx +lda {c1},x +clc +adc {c2},x +//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx +lda {c1},x +clc +adc {c2},x +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx +lda {c1},x +clc +adc {c2},x +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy +lda {c1},y +clc +adc {c2},y +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy +lda {c1},y +clc +adc {c2},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy +lda {c1},y +clc +adc {c2},y +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy +lda {c1},y +clc +adc {c2},y +tay +//FRAGMENT _deref_pbuc1=_deref_(_deref_qbuc2) +ldy {c2} +sty $fe +ldy {c2}+1 +sty $ff +ldy #0 +lda ($fe),y +sta {c1} +//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c2},y +sta {c1} +//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuaa +tay +lda {c2},y +sta {c1} +//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuxx +lda {c2},x +sta {c1} +//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuyy +lda {c2},y +sta {c1} +//FRAGMENT _deref_pwsz1=vwsc1 +ldy #0 +lda #<{c1} +sta ({z1}),y +iny +lda #>{c1} +sta ({z1}),y +//FRAGMENT vwsz1=_deref_pwsz2_band_vwsc1 +ldy #0 +lda ({z2}),y +and #<{c1} +sta {z1} +iny +lda ({z2}),y +and #>{c1} +sta {z1}+1 +//FRAGMENT vbuz1=_hi__deref_pwsz2 +ldy #1 +lda ({z2}),y +sta {z1} +//FRAGMENT pwsz1=pwsz1_plus_vbuc1 +lda #{c1} +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: +//FRAGMENT vbuaa=_hi__deref_pwsz1 +ldy #1 +lda ({z1}),y +//FRAGMENT vbuxx=_hi__deref_pwsz1 +ldy #1 +lda ({z1}),y +tax +//FRAGMENT vbuyy=_hi__deref_pwsz1 +ldy #1 +lda ({z1}),y +tay +//FRAGMENT pwuc1_derefidx_vbuaa=vbuc2 +tay +lda #{c2} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT _deref_pwuz1=vbuc1 +lda #{c1} +ldy #0 +sta ({z1}),y +tya +iny +sta ({z1}),y +//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuz3 +ldx {z2} +ldy {z3} +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vbuaa=vbuz1_plus_2 +lda {z1} +clc +adc #2 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuz2 +ldy {z2} +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuz2 +ldx {z2} +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuaa +ldx {z2} +tay +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuaa +tay +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuaa +tax +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuxx +ldy {z2} +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuxx txa tay clc -lda {z2} -adc ({z3}),y +lda {c1},x +adc {c1},y sta {z1} -bcc !+ -inc {z2}+1 -!: -//FRAGMENT vwsz1=vwsz2_plus_pbuz3_derefidx_vbuyy +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuxx clc -lda {z2} +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuyy +ldx {z2} +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuyy +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuyy +tya +tax +clc +lda {c1},x +adc {c1},y +sta {z1} +lda {c1}+1,x +adc {c1}+1,y +sta {z1}+1 +//FRAGMENT vbuz1=vbuyy_plus_2 +iny +iny +sty {z1} +//FRAGMENT vbuz1=_deref_pbuz2_plus__deref_pbuz3 +ldy #0 +lda ({z2}),y +clc +ldy #0 adc ({z3}),y sta {z1} -bcc !+ -inc {z2}+1 -!: -//FRAGMENT vwsz1=vwsz2_plus_vwsz1 +//FRAGMENT vbuaa=_deref_pbuz1_plus__deref_pbuz2 +ldy #0 +lda ({z1}),y +clc +ldy #0 +adc ({z2}),y +//FRAGMENT vbuxx=_deref_pbuz1_plus__deref_pbuz2 +ldy #0 +lda ({z1}),y +clc +ldy #0 +adc ({z2}),y +tax +//FRAGMENT vbuyy=_deref_pbuz1_plus__deref_pbuz2 +ldy #0 +lda ({z1}),y +clc +ldy #0 +adc ({z2}),y +tay +//FRAGMENT vwuz1=_deref_pwuz2_plus__deref_pwuz3 +ldy #0 +clc +lda ({z2}),y +adc ({z3}),y +sta {z1} +iny +lda ({z2}),y +adc ({z3}),y +sta {z1}+1 +//FRAGMENT vwuz1=_deref_pwuz2_plus__deref_pwuz1 +ldy #0 +clc +lda ({z1}),y +adc ({z2}),y +pha +iny +lda ({z1}),y +adc ({z2}),y +sta {z1}+1 +pla +sta {z1} +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 +ldy {z1} +lda {c1},y +clc +adc {c2},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_plus_vbuc2 +lda #{c2} +ldy {z1} +clc +adc {c1},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa +tax +tay +lda {c1},x +clc +adc {c2},x +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx +lda {c1},x +clc +adc {c2},x +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy +lda {c1},y +clc +adc {c2},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_plus_vbuc2 +lda #{c2} +clc +adc {c1},x +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_plus_vbuc2 +lda #{c2} +clc +adc {c1},y +sta {c1},y +//FRAGMENT _deref_pbuz1=_deref_pbuz1_plus_pbuz1_derefidx_vbuc1 +ldy #0 +lda ({z1}),y +ldy #{c1} +clc +adc ({z1}),y +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuc1=pbuz1_derefidx_vbuc1_plus_vbuc2 +lda #{c2} +ldy #{c1} +clc +adc ({z1}),y +sta ({z1}),y +//FRAGMENT vbuz1=_deref_pbuz2_ror_4 +ldy #0 +lda ({z2}),y +lsr +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbuz1=_hi_pbuz2 +lda {z2}+1 +sta {z1} +//FRAGMENT vbuaa=_deref_pbuz1_ror_4 +ldy #0 +lda ({z1}),y +lsr +lsr +lsr +lsr +//FRAGMENT vbuxx=_deref_pbuz1_ror_4 +ldy #0 +lda ({z1}),y +lsr +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=_deref_pbuz1_ror_4 +ldy #0 +lda ({z1}),y +lsr +lsr +lsr +lsr +tay +//FRAGMENT vbuaa=_hi_pbuz1 +lda {z1}+1 +//FRAGMENT vbuxx=_hi_pbuz1 +ldx {z1}+1 +//FRAGMENT vbuyy=_hi_pbuz1 +ldy {z1}+1 +//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_vwuc2 +ldy {z1} +clc +lda {c1},y +adc #<{c2} +sta {c1},y +lda {c1}+1,y +adc #>{c2} +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=pwuc1_derefidx_vbuaa_plus_vwuc2 +tay +clc +lda {c1},y +adc #<{c2} +sta {c1},y +lda {c1}+1,y +adc #>{c2} +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=pwuc1_derefidx_vbuxx_plus_vwuc2 +clc +lda {c1},x +adc #<{c2} +sta {c1},x +lda {c1}+1,x +adc #>{c2} +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=pwuc1_derefidx_vbuyy_plus_vwuc2 +clc +lda {c1},y +adc #<{c2} +sta {c1},y +lda {c1}+1,y +adc #>{c2} +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=vbuz2 +lda {z2} +ldy {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=vbuz1 +tay +lda {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=vbuz1 +lda {z1} +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=vbuz1 +lda {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=vbuxx +ldy {z1} +txa +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=vbuxx +tay +txa +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuxx=vbuxx +txa +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=vbuxx +txa +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuz1=vbuyy +tya +ldy {z1} +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT pwuc1_derefidx_vbuaa=vbuyy +tax +tya +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuxx=vbuyy +tya +sta {c1},x +lda #0 +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=vbuyy +tya +sta {c1},y +lda #0 +sta {c1}+1,y +//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuz3 +lda {z2} +ldy {z3} +and {c1},y +sta {z1} +//FRAGMENT vbuz1=vbuaa_ror_3 +lsr +lsr +lsr +sta {z1} +//FRAGMENT vbuaa=vbuaa_ror_3 +lsr +lsr +lsr +//FRAGMENT vbuxx=vbuaa_ror_3 +lsr +lsr +lsr +tax +//FRAGMENT vbuyy=vbuaa_ror_3 +lsr +lsr +lsr +tay +//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuxx +lda {c1},x +and {z2} +sta {z1} +//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuyy +lda {c1},y +and {z2} +sta {z1} +//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +and {c1},y +//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuxx +lda {c1},x +and {z1} +//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuyy +lda {c1},y +and {z1} +//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuz2 +lda {z1} +ldx {z2} +and {c1},x +tax +//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuxx +lda {c1},x +and {z1} +tax +//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuyy +lda {c1},y +and {z1} +tax +//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuz2 +lda {z1} +ldy {z2} +and {c1},y +tay +//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuxx +lda {c1},x +and {z1} +tay +//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuyy +lda {c1},y +and {z1} +tay +//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuz2 +ldy {z2} +and {c1},y +sta {z1} +//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuxx +and {c1},x +sta {z1} +//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuyy +and {c1},y +sta {z1} +//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuz1 +ldy {z1} +and {c1},y +//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuxx +and {c1},x +//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuyy +and {c1},y +//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuz1 +ldx {z1} +and {c1},x +tax +//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuxx +and {c1},x +tax +//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuyy +ldx {c1},y +axs #0 +//FRAGMENT vbuz1=vbuxx_band_pbuc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sax {z1} +//FRAGMENT vbuz1=vbuyy_band_pbuc1_derefidx_vbuz2 +tya +ldy {z2} +and {c1},y +sta {z1} +//FRAGMENT vbuyy=vbuaa_band_pbuc1_derefidx_vbuyy +and {c1},y +tay +//FRAGMENT vduz1=vduz2_plus_vwuz3 +lda {z2} +clc +adc {z3} +sta {z1} +lda {z2}+1 +adc {z3}+1 +sta {z1}+1 +lda {z2}+2 +adc #0 +sta {z1}+2 +lda {z2}+3 +adc #0 +sta {z1}+3 +//FRAGMENT vduz1=vduz1_plus_vwuz2 lda {z1} clc adc {z2} @@ -8587,28 +11524,754 @@ sta {z1} lda {z1}+1 adc {z2}+1 sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_minus_vbuc1 +lda {z1}+2 +adc #0 +sta {z1}+2 +lda {z1}+3 +adc #0 +sta {z1}+3 +//FRAGMENT _deref_(_deref_qbuc1)=vbuc2 +lda #{c2} +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=vbuz1 +lda {z1} +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=vbuaa +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=vbuxx +txa +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT _deref_(_deref_qbuc1)=vbuyy +tya +ldy {c1} +sty $fe +ldy {c1}+1 +sty $ff +ldy #0 +sta ($fe),y +//FRAGMENT vbsz1_le_vbsc1_then_la1 +lda #{c1} sec -lda {z1} -sbc #{c1} -sta {z1} -bcs !+ -dec {z1}+1 +sbc {z1} +bvc !+ +eor #$80 !: -//FRAGMENT vwsz1=vwsz1_plus_pbuz2_derefidx_vbuyy -clc +bpl {la1} +//FRAGMENT vbsaa=vbsz1 lda {z1} +//FRAGMENT vbsaa_le_vbsc1_then_la1 +sec +sbc #{c1} +beq {la1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsxx_le_vbsc1_then_la1 +txa +sec +sbc #{c1} +beq {la1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsyy_le_vbsc1_then_la1 +tya +sec +sbc #{c1} +beq {la1} +bvc !+ +eor #$80 +!: +bmi {la1} +//FRAGMENT vbsxx=vbsyy +tya +tax +//FRAGMENT vbsyy_neq_vbsc1_then_la1 +cpy #{c1} +bne {la1} +//FRAGMENT vbuaa_gt_vbuz1_then_la1 +cmp {z1} +beq !+ +bcs {la1} +!: +//FRAGMENT pbuz1=_dec_pbuz2 +lda {z2} +sec +sbc #1 +sta {z1} +lda {z2}+1 +sbc #0 +sta {z1}+1 +//FRAGMENT vwsz1_lt_vbsc1_then_la1 +NO_SYNTHESIS +//FRAGMENT vwsz1_lt_vwuc1_then_la1 +lda {z1}+1 +bmi {la1} +cmp #>{c1} +bcc {la1} +bne !+ +lda {z1} +cmp #<{c1} +bcc {la1} +!: +//FRAGMENT _deref_pwuc1=_deref_pwuc1_plus_vwuc2 +lda #<{c2} +clc +adc {c1} +sta {c1} +lda #>{c2} +adc {c1}+1 +sta {c1}+1 +//FRAGMENT vbuz1=vbuz1_minus_1 +dec {z1} +//FRAGMENT vbuxx=vbuxx_minus_1 +dex +//FRAGMENT vbuyy=vbuyy_minus_1 +tya +tay +dey +//FRAGMENT vwsz1=pwsc1_derefidx_vbuz2_plus__deref_pwsz3 +ldx {z2} +clc +ldy #0 +lda {c1},x +adc ({z3}),y +sta {z1} +iny +lda {c1}+1,x +adc ({z3}),y +sta {z1}+1 +//FRAGMENT vwsz1=pwsc1_derefidx_vbuaa_plus__deref_pwsz2 +tax +clc +ldy #0 +lda {c1},x adc ({z2}),y sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} +iny +lda {c1}+1,x +adc ({z2}),y +sta {z1}+1 +//FRAGMENT vwsz1=pwsc1_derefidx_vbuxx_plus__deref_pwsz2 clc -adc {c1},y +ldy #0 +lda {c1},x +adc ({z2}),y sta {z1} +iny +lda {c1}+1,x +adc ({z2}),y +sta {z1}+1 +//FRAGMENT vwsz1=pwsc1_derefidx_vbuyy_plus__deref_pwsz2 +tya +tax +clc +ldy #0 +lda {c1},x +adc ({z2}),y +sta {z1} +iny +lda {c1}+1,x +adc ({z2}),y +sta {z1}+1 +//FRAGMENT vwsz1=pwsc1_derefidx_vbuaa_plus__deref_pwsz1 +tax +ldy #0 +clc +lda {c1},x +adc ({z1}),y +pha +iny +lda {c1}+1,x +adc ({z1}),y +sta {z1}+1 +pla +sta {z1} +//FRAGMENT vwuz1_le_vwuz2_then_la1 +lda {z1}+1 +cmp {z2}+1 +bne !+ +lda {z1} +cmp {z2} +beq {la1} +!: +bcc {la1} +//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuaa +ldx {z1} +tay +lda ({z2}),y +sta {c1},x +//FRAGMENT pprz1=_deref_qprc1 +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 +//FRAGMENT vbuz1_ge_vbuaa_then_la1 +ldy {z1} +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuz1_le_vbuaa_then_la1 +cmp {z1} +bcs {la1} +//FRAGMENT vbuaa_le_vbuz1_then_la1 +ldy {z1} +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuaa_le_vbuxx_then_la1 +tay +sty $ff +cpx $ff +bcs {la1} +//FRAGMENT vbuaa_le_vbuyy_then_la1 +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuxx_ge_vbuaa_then_la1 +tay +sty $ff +cpx $ff +bcs {la1} +//FRAGMENT vbuxx_le_vbuaa_then_la1 +stx $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuxx_le_vbuyy_then_la1 +stx $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuyy_le_vbuz1_then_la1 +lda {z1} +sty $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuyy_ge_vbuaa_then_la1 +sta $ff +cpy $ff +bcs {la1} +//FRAGMENT vbuyy_le_vbuaa_then_la1 +sty $ff +cmp $ff +bcs {la1} +//FRAGMENT vbuyy_le_vbuxx_then_la1 +sty $ff +cpx $ff +bcs {la1} +//FRAGMENT pwuc1_derefidx_vbuz1=pwuz2_derefidx_vbuc2 +ldx {z1} +ldy #{c2} +lda ({z2}),y +sta {c1},x +iny +lda ({z2}),y +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuaa=pwuz1_derefidx_vbuc2 +ldy #{c2} +tax +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuxx=pwuz1_derefidx_vbuc2 +ldy #{c2} +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT pwuc1_derefidx_vbuyy=pwuz1_derefidx_vbuc2 +tya +ldy #{c2} +tax +lda ({z1}),y +sta {c1},x +iny +lda ({z1}),y +sta {c1}+1,x +//FRAGMENT 0_eq_vwuz1_then_la1 +lda {z1} +ora {z1}+1 +beq {la1} +//FRAGMENT vbuz1=_dec_vbuz2 +ldy {z2} +dey +sty {z1} +//FRAGMENT vbuz1=_dec_vbuaa +sec +sbc #1 +sta {z1} +//FRAGMENT vbuz1=_dec_vbuxx +dex +stx {z1} +//FRAGMENT vbuz1=_dec_vbuyy +dey +sty {z1} +//FRAGMENT vbuaa=_dec_vbuz1 +lda {z1} +sec +sbc #1 +//FRAGMENT vbuaa=_dec_vbuxx +txa +sec +sbc #1 +//FRAGMENT vbuyy=_dec_vbuz1 +ldy {z1} +dey +//FRAGMENT 0_neq_vbsz1_then_la1 +lda {z1} +cmp #0 +bne {la1} +//FRAGMENT 0_neq_vbsaa_then_la1 +cmp #0 +bne {la1} +//FRAGMENT vbsaa=vbsc1 +lda #{c1} +//FRAGMENT vbsaa=_inc_vbsaa +clc +adc #1 +//FRAGMENT 0_neq_vbsxx_then_la1 +cpx #0 +bne {la1} +//FRAGMENT 0_neq_vbsyy_then_la1 +cpy #0 +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_bor_vbuc2 +lda #{c2} +ldy {z1} +ora {c1},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_bor_vbuc2 +lda #{c2} +ora {c1},x +sta {c1},x +//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_bor_vbuc2 +lda #{c2} +ora {c1},y +sta {c1},y +//FRAGMENT pbuc1_derefidx_vbuz1_neq_vbuc2_then_la1 +lda #{c2} +ldy {z1} +cmp {c1},y +bne {la1} +//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_band_vbuc2 +lda #{c2} +ldy {z2} +and {c1},y +sta {z1} +//FRAGMENT pbuc1_derefidx_vbuaa_neq_vbuc2_then_la1 +tay +lda #{c2} +cmp {c1},y +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuxx_neq_vbuc2_then_la1 +lda {c1},x +cmp #{c2} +bne {la1} +//FRAGMENT pbuc1_derefidx_vbuyy_neq_vbuc2_then_la1 +lda #{c2} +cmp {c1},y +bne {la1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldy {z1} +and {c1},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldx {z1} +and {c1},x +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_band_vbuc2 +lda #{c2} +ldy {z1} +and {c1},y +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_band_vbuc2 +lda #{c2} +and {c1},x +tay +//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +sta {z1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +tax +//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_band_vbuc2 +lda #{c2} +and {c1},y +tay +//FRAGMENT vwuz1=vwuz1_sethi_vbuz2 +lda {z2} +sta {z1}+1 +//FRAGMENT vbsz1_lt_0_then_la1 +lda {z1} +bmi {la1} +//FRAGMENT vwuz1=vwuz2_rol_vbuz3 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +ldy {z3} +beq !e+ +!: +asl {z1} +rol {z1}+1 +dey +bne !- +!e: +//FRAGMENT vwuz1=vwuz1_sethi_vbuaa +sta {z1}+1 +//FRAGMENT vbsaa_lt_0_then_la1 +cmp #0 +bmi {la1} +//FRAGMENT vwuz1=vwuz2_rol_vbuxx +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +cpx #0 +beq !e+ +!: +asl {z1} +rol {z1}+1 +dex +bne !- +!e: +//FRAGMENT vwuz1=vwuz2_rol_vbuyy +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +cpy #0 +beq !e+ +!: +asl {z1} +rol {z1}+1 +dey +bne !- +!e: +//FRAGMENT vbsz1=vbsyy +sty {z1} +//FRAGMENT vbsaa=vbsxx +txa +//FRAGMENT vbsaa=vbsyy +tya +//FRAGMENT vbsxx=vbsaa +tax +//FRAGMENT vbsyy=vbsaa +tay +//FRAGMENT vbsyy=vbsxx +txa +tay +//FRAGMENT vwuz1=vwuz1_sethi_vbuxx +stx {z1}+1 +//FRAGMENT vwuz1=vwuz1_sethi_vbuyy +sty {z1}+1 +//FRAGMENT vbsyy_ge_0_then_la1 +cpy #0 +bpl {la1} +//FRAGMENT vbsxx_lt_0_then_la1 +cpx #0 +bmi {la1} +//FRAGMENT vbuz1=vbuc1_plus__hi_vwsz2 +lda #{c1} +clc +adc {z2}+1 +sta {z1} +//FRAGMENT vwuz1=vwuz1_rol_vbuz2 +ldy {z2} +beq !e+ +!: +asl {z1} +rol {z1}+1 +dey +bne !- +!e: +//FRAGMENT vwuz1=_deref_pbuc1_word__deref_pbuc2 +lda {c2} +sta {z1} +lda {c1} +sta {z1}+1 +//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuz3 +ldy {z3} +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuz2_neq_vbuc1_then_la1 +ldy {z2} +lda ({z1}),y + +cmp #{c1} +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuz2_neq_0_then_la1 +ldy {z2} +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT vwuz1=vbuz2_rol_3 +lda {z2} +sta {z1} +lda #0 +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuxx +txa +tay +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuyy +lda ({z2}),y +ldy #0 +sta ({z1}),y +//FRAGMENT pbuz1_derefidx_vbuxx_neq_vbuc1_then_la1 +txa +tay +lda ({z1}),y + +cmp #{c1} +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuxx_neq_0_then_la1 +txa +tay +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT pbuz1_derefidx_vbuyy_neq_0_then_la1 +lda ({z1}),y + +cmp #0 +bne {la1} +//FRAGMENT vwuz1=vbuaa_rol_3 +sta {z1} +lda #0 +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=vbuxx_rol_3 +txa +sta {z1} +lda #0 +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=vbuyy_rol_3 +tya +sta {z1} +lda #0 +sta {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +asl {z1} +rol {z1}+1 +//FRAGMENT vwuz1=_dec_vwuz1 +lda {z1} +bne !+ +dec {z1}+1 +!: +dec {z1} +//FRAGMENT vbuz1=vbuz2_minus__deref_pbuz3 +lda {z2} +sec +ldy #0 +sbc ({z3}),y +sta {z1} +//FRAGMENT vbuz1=vbuxx_minus__deref_pbuz2 +txa +sec +ldy #0 +sbc ({z2}),y +sta {z1} +//FRAGMENT vbuaa=vbuz1_minus__deref_pbuz2 +lda {z1} +sec +ldy #0 +sbc ({z2}),y +//FRAGMENT vbuaa=vbuxx_minus__deref_pbuz1 +txa +sec +ldy #0 +sbc ({z1}),y +//FRAGMENT vbuxx=vbuz1_minus__deref_pbuz2 +lda {z1} +sec +ldy #0 +sbc ({z2}),y +tax +//FRAGMENT vbuxx=vbuxx_minus__deref_pbuz1 +txa +sec +ldy #0 +sbc ({z1}),y +tax +//FRAGMENT vbuyy=vbuz1_minus__deref_pbuz2 +lda {z1} +sec +ldy #0 +sbc ({z2}),y +tay +//FRAGMENT vbuyy=vbuxx_minus__deref_pbuz1 +txa +sec +ldy #0 +sbc ({z1}),y +tay +//FRAGMENT vwuz1=pwuz2_minus_pwuc1 +lda {z2} +sec +sbc #<{c1} +sta {z1} +lda {z2}+1 +sbc #>{c1} +sta {z1}+1 +//FRAGMENT vwuz1=pwuz1_minus_pwuc1 +lda {z1} +sec +sbc #<{c1} +sta {z1} +lda {z1}+1 +sbc #>{c1} +sta {z1}+1 +//FRAGMENT vbuz1=_lo_pbuz2 +lda {z2} +sta {z1} +//FRAGMENT vwuz1_eq_0_then_la1 +lda {z1} +ora {z1}+1 +beq {la1} +//FRAGMENT vwuz1_gt_vwuz2_then_la1 +lda {z2}+1 +cmp {z1}+1 +bcc {la1} +bne !+ +lda {z2} +cmp {z1} +bcc {la1} +!: +//FRAGMENT vwuz1_neq_vwuz2_then_la1 +lda {z1}+1 +cmp {z2}+1 +bne {la1} +lda {z1} +cmp {z2} +bne {la1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_pbuc2_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1}+1 +lda {c2},y +sta {z1} +//FRAGMENT vwuz1=vwuz2_band_vwuc1 +lda {z2} +and #<{c1} +sta {z1} +lda {z2}+1 +and #>{c1} +sta {z1}+1 +//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuz2 +ldy #0 +lda ({z1}),y +ldy {z2} +ora {c1},y +ldy #0 +sta ({z1}),y +//FRAGMENT vbuaa=_lo_pbuz1 +lda {z1} +//FRAGMENT vbuxx=_lo_pbuz1 +ldx {z1} +//FRAGMENT vbuz1=vbuaa_bor_vbuaa +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuaa_word_pbuc2_derefidx_vbuaa +tay +lda {c1},y +sta {z1}+1 +lda {c2},y +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_pbuc2_derefidx_vbuxx +lda {c1},x +sta {z1}+1 +lda {c2},x +sta {z1} +//FRAGMENT vwuz1=pbuc1_derefidx_vbuyy_word_pbuc2_derefidx_vbuyy +lda {c1},y +sta {z1}+1 +lda {c2},y +sta {z1} +//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuaa +tay +lda {c1},y +ldy #0 +ora ({z1}),y +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuxx +lda {c1},x +ldy #0 +ora ({z1}),y +ldy #0 +sta ({z1}),y +//FRAGMENT _deref_pbuz1=_deref_pbuz1_bor_pbuc1_derefidx_vbuyy +lda {c1},y +ldy #0 +ora ({z1}),y +ldy #0 +sta ({z1}),y //FRAGMENT vbuz1=pbuz2_derefidx_vbuc1_plus_pbuz2_derefidx_vbuc1 ldy #{c1} lda ({z2}),y @@ -8621,17 +12284,6 @@ ldy #{c1} clc adc ({z3}),y sta {z1} -//FRAGMENT vbuz1=vbuz2_ror_2 -lda {z2} -lsr -lsr -sta {z1} -//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -clc -adc {c1},y -tay //FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuaa tay lda {c1},y @@ -8644,26 +12296,6 @@ tya clc adc {c1},x tay -//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z1} -sta {z1} -//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuxx -tya -clc -adc {c1},x -tay -//FRAGMENT vbuz1=vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z1} -sta {z1} -//FRAGMENT vbuyy=vbuyy_plus_pbuc1_derefidx_vbuyy -tya -clc -adc {c1},y -tay //FRAGMENT vbuaa=pbuz1_derefidx_vbuc1_plus_pbuz1_derefidx_vbuc1 ldy #{c1} lda ({z1}),y @@ -8763,150 +12395,6 @@ ldy #{c1} clc adc ({z1}),y tay -//FRAGMENT vbuz1=vbuaa_ror_2 -lsr -lsr -sta {z1} -//FRAGMENT vbuz1=vbuxx_ror_2 -txa -lsr -lsr -sta {z1} -//FRAGMENT vbuz1=vbuyy_ror_2 -tya -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_2 -lda {z1} -lsr -lsr -//FRAGMENT vbuaa=vbuaa_ror_2 -lsr -lsr -//FRAGMENT vbuaa=vbuxx_ror_2 -txa -lsr -lsr -//FRAGMENT vbuaa=vbuyy_ror_2 -tya -lsr -lsr -//FRAGMENT vbuxx=vbuz1_ror_2 -lda {z1} -lsr -lsr -tax -//FRAGMENT vbuxx=vbuaa_ror_2 -lsr -lsr -tax -//FRAGMENT vbuxx=vbuxx_ror_2 -txa -lsr -lsr -tax -//FRAGMENT vbuxx=vbuyy_ror_2 -tya -lsr -lsr -tax -//FRAGMENT vbuyy=vbuz1_ror_2 -lda {z1} -lsr -lsr -tay -//FRAGMENT vbuyy=vbuaa_ror_2 -lsr -lsr -tay -//FRAGMENT vbuyy=vbuxx_ror_2 -txa -lsr -lsr -tay -//FRAGMENT vbuyy=vbuyy_ror_2 -tya -lsr -lsr -tay -//FRAGMENT vwuz1=vbuz2_word_vbuz3 -lda {z2} -sta {z1}+1 -lda {z3} -sta {z1} -//FRAGMENT vwuz1=vbuaa_word_vbuz2 -sta {z1}+1 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=vbuxx_word_vbuz2 -lda {z2} -stx {z1}+1 -sta {z1} -//FRAGMENT vwuz1=vbuyy_word_vbuz2 -lda {z2} -sty {z1}+1 -sta {z1} -//FRAGMENT vwuz1=vbuz2_word_vbuaa -ldy {z2} -sty {z1}+1 -sta {z1} -//FRAGMENT vwuz1=vbuxx_word_vbuaa -stx {z1}+1 -sta {z1} -//FRAGMENT vwuz1=vbuyy_word_vbuaa -sty {z1}+1 -sta {z1} -//FRAGMENT vwuz1=vbuz2_word_vbuxx -lda {z2} -sta {z1}+1 -stx {z1} -//FRAGMENT vwuz1=vbuaa_word_vbuxx -sta {z1}+1 -stx {z1} -//FRAGMENT vwuz1=vbuyy_word_vbuxx -sty {z1}+1 -stx {z1} -//FRAGMENT vwuz1=vbuz2_word_vbuyy -lda {z2} -sta {z1}+1 -sty {z1} -//FRAGMENT vwuz1=vbuaa_word_vbuyy -sta {z1}+1 -sty {z1} -//FRAGMENT vwuz1=vbuxx_word_vbuyy -stx {z1}+1 -sty {z1} -//FRAGMENT _deref_qbuc1=pbuc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -//FRAGMENT _deref_pbsc1=vbsc2 -lda #{c2} -sta {c1} -//FRAGMENT vbuz1=_dec_vbuz2 -ldy {z2} -dey -sty {z1} -//FRAGMENT vbuz1=_dec_vbuaa -sec -sbc #1 -sta {z1} -//FRAGMENT vbuz1=_dec_vbuxx -dex -stx {z1} -//FRAGMENT vbuz1=_dec_vbuyy -dey -sty {z1} -//FRAGMENT vbuaa=_dec_vbuz1 -lda {z1} -sec -sbc #1 -//FRAGMENT vbuaa=_dec_vbuxx -txa -sec -sbc #1 //FRAGMENT vbuaa=_dec_vbuyy tya sec @@ -8921,9 +12409,6 @@ dex tya tax dex -//FRAGMENT vbuyy=_dec_vbuz1 -ldy {z1} -dey //FRAGMENT vbuyy=_dec_vbuaa tay dey @@ -8931,92 +12416,6 @@ dey txa tay dey -//FRAGMENT vwuz1=vwuz2_bor_vbuz3 -lda {z3} -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_4 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuz2 -ldy {z2} -lda {c2},y -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2_eq_pbuz3_derefidx_vbuz2_then_la1 -ldy {z2} -lda ({z1}),y - -cmp ({z3}),y -beq {la1} -//FRAGMENT vwuz1=vwuz2_bor_vbuxx -txa -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_bor_vbuyy -tya -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuaa -tay -lda {c2},y -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuxx -lda {c2},x -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuc1=pbuc2_derefidx_vbuyy -lda {c2},y -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa_eq_pbuz2_derefidx_vbuaa_then_la1 -tay -lda ({z1}),y - -cmp ({z2}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuxx_eq_pbuz2_derefidx_vbuxx_then_la1 -txa -tay -lda ({z1}),y - -cmp ({z2}),y -beq {la1} -//FRAGMENT pbuz1_derefidx_vbuyy_eq_pbuz2_derefidx_vbuyy_then_la1 -lda ({z1}),y - -cmp ({z2}),y -beq {la1} -//FRAGMENT vwuz1=vwuz1_bor_vbuxx -txa -ora {z1} -sta {z1} -//FRAGMENT vwuz1=vwuz1_rol_4 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 //FRAGMENT vbuz1_ge_pbuc1_derefidx_vbuz2_then_la1 lda {z1} ldy {z2} @@ -9062,11 +12461,6 @@ bne {la1} lda {z1} cmp {z1} bne {la1} -//FRAGMENT vbuz1_ge_vbuaa_then_la1 -ldy {z1} -sta $ff -cpy $ff -bcs {la1} //FRAGMENT vbuz1_ge_pbuc1_derefidx_vbuxx_then_la1 txa tay @@ -9317,269 +12711,6 @@ tax stx $ff cpy $ff bne {la1} -//FRAGMENT pwuz1_derefidx_vbuc1=vwuz2 -ldy #{c1} -lda {z2} -sta ({z1}),y -iny -lda {z2}+1 -sta ({z1}),y -//FRAGMENT vbuz1=vbuz2_plus_2 -lda {z2} -clc -adc #2 -sta {z1} -//FRAGMENT vbuz1=vbuaa_plus_2 -clc -adc #2 -sta {z1} -//FRAGMENT vbuz1=vbuxx_plus_2 -inx -inx -stx {z1} -//FRAGMENT vbuxx=vbuz1_plus_2 -ldx {z1} -inx -inx -//FRAGMENT vbuyy=vbuz1_plus_2 -ldy {z1} -iny -iny -//FRAGMENT vbuxx=vbuaa_plus_2 -tax -inx -inx -//FRAGMENT vbuxx=vbuyy_plus_2 -tya -clc -adc #2 -tax -//FRAGMENT vbsz1_lt_vbsc1_then_la1 -lda {z1} -sec -sbc #{c1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vbsaa_lt_vbsc1_then_la1 -sec -sbc #{c1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vbsxx_lt_vbsc1_then_la1 -txa -sec -sbc #{c1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vbsyy_lt_vbsc1_then_la1 -tya -sec -sbc #{c1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vwsz1=vwsz1_plus_vwsc1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwsz1=vwsz2_ror_7 -lda {z2}+1 -sta {z1} -and #$80 -beq !+ -lda #$ff -!: -sta {z1}+1 -lda {z2} -rol -rol {z1} -rol {z1}+1 -//FRAGMENT vwsz1=vwsz2_plus_vwsc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwsz1=vwsz2_ror_5 -lda {z2} -sta $ff -lda {z2}+1 -sta {z1} -lda #0 -bit {z2}+1 -bpl !+ -lda #$ff -!: -sta {z1}+1 -rol $ff -rol {z1} -rol {z1}+1 -rol $ff -rol {z1} -rol {z1}+1 -rol $ff -rol {z1} -rol {z1}+1 -//FRAGMENT _deref_pbuc1=_byte_vwsz1 -lda {z1} -sta {c1} -//FRAGMENT vwsz1=vwsc1_minus_vwsz1 -lda #<{c1} -sec -sbc {z1} -sta {z1} -lda #>{c1} -sbc {z1}+1 -sta {z1}+1 -//FRAGMENT _deref_pbsc1=vbsz1 -lda {z1} -sta {c1} -//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuz2 -lda {z2} -ldy {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuz1 -tay -lda {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuz1 -lda {z1} -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuz1 -lda {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuxx -ldy {z1} -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuxx -tay -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuxx -txa -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuxx -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=_word_vbuyy -tya -ldy {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=_word_vbuyy -tax -tya -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuxx=_word_vbuyy -tya -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=_word_vbuyy -tya -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pbuc1_derefidx_vbuz1_neq_vbuc2_then_la1 -lda #{c2} -ldy {z1} -cmp {c1},y -bne {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_band_vbuc2 -lda #{c2} -ldy {z2} -and {c1},y -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuaa_neq_vbuc2_then_la1 -tay -lda #{c2} -cmp {c1},y -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_neq_vbuc2_then_la1 -lda {c1},x -cmp #{c2} -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_neq_vbuc2_then_la1 -lda #{c2} -cmp {c1},y -bne {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldy {z1} -and {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldx {z1} -and {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_band_vbuc2 -lda #{c2} -ldy {z1} -and {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_band_vbuc2 -lda #{c2} -and {c1},x -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_band_vbuc2 -lda #{c2} -and {c1},y -tay //FRAGMENT vwuz1=pbuc1_derefidx_vbuz2 ldy {z2} lda {c1},y @@ -9602,41 +12733,6 @@ lda {c1},y sta {z1} lda #0 sta {z1}+1 -//FRAGMENT _deref_pbuc1=_deref_pbuz1 -ldy #0 -lda ({z1}),y -sta {c1} -//FRAGMENT vwuz1=pbuc1_minus_pbuz2 -sec -lda #<{c1} -sbc {z2} -sta {z1} -lda #>{c1} -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=pbuc1_minus_pbuz1 -sec -lda #<{c1} -sbc {z1} -sta {z1} -lda #>{c1} -sbc {z1}+1 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuaa=_deref_pbuz1 -tax -ldy #0 -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=_deref_pbuz1 -ldy #0 -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=_deref_pbuz1 -tya -tax -ldy #0 -lda ({z1}),y -sta {c1},x //FRAGMENT vbsz1=pbsc1_derefidx_vbuz2 ldy {z2} lda {c1},y @@ -9653,6 +12749,11 @@ lda {z2} clc adc {z3} sta {z1} +//FRAGMENT vbsz1=vbsz2_minus_vbsz3 +lda {z2} +sec +sbc {z3} +sta {z1} //FRAGMENT vbsz1=pbsc1_derefidx_vbsz2_plus_pbsc1_derefidx_vbsz3 ldy {z2} lda {c1},y @@ -9888,26 +12989,11 @@ txa sty $ff clc adc $ff -//FRAGMENT vbsxx=vbsxx_plus_vbsz1 -txa -clc -adc {z1} -tax //FRAGMENT vbsxx=vbsxx_plus_vbsaa stx $ff clc adc $ff tax -//FRAGMENT vbsxx=vbsxx_plus_vbsxx -txa -asl -tax -//FRAGMENT vbsxx=vbsxx_plus_vbsyy -txa -sty $ff -clc -adc $ff -tax //FRAGMENT vbsyy=vbsxx_plus_vbsz1 txa clc @@ -9984,26 +13070,23 @@ tax tya asl tax -//FRAGMENT vbsyy=vbsyy_plus_vbsz1 -tya -clc -adc {z1} -tay //FRAGMENT vbsyy=vbsyy_plus_vbsaa sty $ff clc adc $ff tay -//FRAGMENT vbsyy=vbsyy_plus_vbsxx +//FRAGMENT vbsz1=vbsz2_minus_vbsxx txa -sty $ff -clc -adc $ff -tay -//FRAGMENT vbsyy=vbsyy_plus_vbsyy +eor #$ff +sec +adc {z2} +sta {z1} +//FRAGMENT vbsz1=vbsz2_minus_vbsyy tya -asl -tay +eor #$ff +sec +adc {z2} +sta {z1} //FRAGMENT vbsaa=vbsz1_minus_vbsz2 lda {z1} sec @@ -10018,6 +13101,23 @@ tya eor #$ff sec adc {z1} +//FRAGMENT vbsxx=vbsz1_minus_vbsz2 +lda {z1} +sec +sbc {z2} +tax +//FRAGMENT vbsxx=vbsz1_minus_vbsxx +txa +eor #$ff +sec +adc {z1} +tax +//FRAGMENT vbsxx=vbsz1_minus_vbsyy +tya +eor #$ff +sec +adc {z1} +tax //FRAGMENT vbsyy=vbsz1_minus_vbsz2 lda {z1} sec @@ -10035,6 +13135,20 @@ eor #$ff sec adc {z1} tay +//FRAGMENT vbsz1=vbsxx_minus_vbsz2 +txa +sec +sbc {z2} +sta {z1} +//FRAGMENT vbsz1=vbsxx_minus_vbsxx +lda #0 +sta {z1} +//FRAGMENT vbsz1=vbsxx_minus_vbsyy +txa +sty $ff +sec +sbc $ff +sta {z1} //FRAGMENT vbsaa=vbsxx_minus_vbsz1 txa sec @@ -10060,6 +13174,20 @@ sty $ff sec sbc $ff tay +//FRAGMENT vbsz1=vbsyy_minus_vbsz2 +tya +sec +sbc {z2} +sta {z1} +//FRAGMENT vbsz1=vbsyy_minus_vbsxx +tya +stx $ff +sec +sbc $ff +sta {z1} +//FRAGMENT vbsz1=vbsyy_minus_vbsyy +lda #0 +sta {z1} //FRAGMENT vbsaa=vbsyy_minus_vbsz1 tya sec @@ -10071,20 +13199,20 @@ sec sbc $ff //FRAGMENT vbsaa=vbsyy_minus_vbsyy lda #0 -//FRAGMENT vbsyy=vbsyy_minus_vbsz1 +//FRAGMENT vbsxx=vbsyy_minus_vbsz1 tya sec sbc {z1} -tay -//FRAGMENT vbsyy=vbsyy_minus_vbsxx +tax +//FRAGMENT vbsxx=vbsyy_minus_vbsxx tya stx $ff sec sbc $ff -tay -//FRAGMENT vbsyy=vbsyy_minus_vbsyy +tax +//FRAGMENT vbsxx=vbsyy_minus_vbsyy lda #0 -tay +tax //FRAGMENT vbsaa=pbsc1_derefidx_vbsz1_plus_pbsc1_derefidx_vbsz2 ldy {z1} lda {c1},y @@ -10953,33 +14081,6 @@ ldy {c1} stx {c1} //FRAGMENT _deref_pbsc1=vbsyy sty {c1} -//FRAGMENT pbuz1=pbuz1_plus_1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=pbuz2_derefidx_vbuc1 -ldy #{c1} -lda ({z2}),y -sta {z1} -//FRAGMENT pbuz1_derefidx_vbuc1=vbuaa -ldy #{c1} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuc1=vbuyy -tya -ldy #{c1} -sta ({z1}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tay //FRAGMENT vwuz1=vwuc1_plus_vbuz2 lda {z2} clc @@ -11016,14 +14117,6 @@ sta {z1} iny lda ({z2}),y sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_band__deref_pbuc1 -lda {c1} -and {z2} -sta {z1} -//FRAGMENT vbuz1=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -sta {z1} //FRAGMENT vwuz1=vwuc1_plus_vbuaa clc adc #<{c1} @@ -11047,1276 +14140,18 @@ sta {z1} lda #>{c1} adc #0 sta {z1}+1 -//FRAGMENT vbuaa=vbuz1_band__deref_pbuc1 -lda {c1} -and {z1} -//FRAGMENT vbuxx=vbuz1_band__deref_pbuc1 -lda {c1} -and {z1} -tax -//FRAGMENT vbuyy=vbuz1_band__deref_pbuc1 -lda {c1} -and {z1} -tay -//FRAGMENT vbuz1=vbuaa_band__deref_pbuc1 -and {c1} -sta {z1} -//FRAGMENT vbuaa=vbuaa_band__deref_pbuc1 -and {c1} -//FRAGMENT vbuxx=vbuaa_band__deref_pbuc1 -ldx {c1} -axs #0 -//FRAGMENT vbuaa=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -//FRAGMENT vbuxx=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -tax -//FRAGMENT vbuyy=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -tay -//FRAGMENT vbuz1=vbuxx_band__deref_pbuc1 -lda {c1} -sax {z1} -//FRAGMENT vbuz1=vbuyy_band__deref_pbuc1 -tya -and {c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_band__deref_pbuc1 -txa -and {c1} -//FRAGMENT vbuaa=vbuyy_band__deref_pbuc1 -tya -and {c1} -//FRAGMENT vbuxx=vbuxx_band__deref_pbuc1 -lda {c1} -axs #0 -//FRAGMENT vbuxx=vbuyy_band__deref_pbuc1 -ldx {c1} -tya -axs #0 -//FRAGMENT vbuyy=vbuaa_band__deref_pbuc1 -and {c1} -tay -//FRAGMENT vbuyy=vbuxx_band__deref_pbuc1 -txa -and {c1} -tay -//FRAGMENT vbuyy=vbuyy_band__deref_pbuc1 -tya -and {c1} -tay -//FRAGMENT vwsz1_neq_vbsc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vwsz1_neq_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuc1_lt_vbuc2_then_la1 -lda {c1} -cmp #{c2} -bcc {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=_byte_vwuz2 -ldy {z1} +//FRAGMENT vbsz1=_sbyte_vwuz2 lda {z2} -sta {c1},y -//FRAGMENT vwuz1=vwuz2_ror_4 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror sta {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vwuz1=vwuz2_ror_8 -lda {z2}+1 -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1_ge_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc !+ -bne {la1} -lda {z1} -cmp #<{c1} -bcs {la1} -!: -//FRAGMENT vwuz1_ge_vbuc1_then_la1 -lda {z1}+1 -bne {la1} -lda {z1} -cmp #{c1} -bcs {la1} -!: -//FRAGMENT pbuc1_derefidx_vbuxx=_byte_vwuz1 -lda {z1} -sta {c1},x -//FRAGMENT vwuz1=vwuz1_plus_1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=vwuz1_rol_8 -lda {z1} -sta {z1}+1 -lda #0 -sta {z1} -//FRAGMENT vwuz1=vwuz1_ror_4 -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT pwsc1_derefidx_vbuz1=vwsc2 -ldy {z1} -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT _deref_pwsc1=_deref_pwsc2 -lda {c2} -sta {c1} -lda {c2}+1 -sta {c1}+1 -//FRAGMENT pwsc1_derefidx_vbuaa=vwsc2 -tay -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT pwsc1_derefidx_vbuxx=vwsc2 -lda #<{c2} -sta {c1},x -lda #>{c2} -sta {c1}+1,x -//FRAGMENT pwsc1_derefidx_vbuyy=vwsc2 -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT _deref_pbuc1=_byte_vwuz1 -lda {z1} -sta {c1} -//FRAGMENT vbuz1_eq__deref_pbuc1_then_la1 -lda {c1} -cmp {z1} -beq {la1} -//FRAGMENT _deref_pbuc1_eq_0_then_la1 -lda {c1} -cmp #0 -beq {la1} -//FRAGMENT vbuz1=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_rol_4 -lda {c1} -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor__deref_pbuc1 -lda {c1} -ora {z2} -sta {z1} -//FRAGMENT vduz1=vduz2_plus_vbuz3 -lda {z3} -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz2_ror_6 -lda {z2} -asl -sta $ff -lda {z2}+1 -rol -sta {z1} -lda #0 -rol -sta {z1}+1 -asl $ff -rol {z1} -rol {z1}+1 -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_(pbuc2_derefidx_vbuz3) -ldx {z3} -ldy {c2},x -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuz1=_dec_pbuc1_derefidx_vbuz1 -ldx {z1} -dec {c1},x -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_(pbuc2_derefidx_vbuz2) -ldx {z2} -ldy {c2},x -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuz1_le_pbuc2_derefidx_vbuz1_then_la1 -ldy {z1} -lda {c2},y -cmp {c1},y -bcs {la1} -//FRAGMENT vbuz1=_deref_pbuz2_bor_vbuc1 -lda #{c1} -ldy #0 -ora ({z2}),y -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuz1 -ldy {z1} -lda ({z2}),y -sta {c1},y -//FRAGMENT vbuz1=vbuz2_bxor_pbuc1_derefidx_vbuz3 -lda {z2} -ldy {z3} -eor {c1},y -sta {z1} -//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuz3 -lda {z2} -ldy {z3} -and {c1},y -sta {z1} -//FRAGMENT vduz1=vduz2_rol_2 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -lda {z2}+2 -rol -sta {z1}+2 -lda {z2}+3 -rol -sta {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vwuz1=vwuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_ror_3 -lda {z2} -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuxx_eq__deref_pbuc1_then_la1 -cpx {c1} -beq {la1} -//FRAGMENT vbuxx=vbuxx_bor_vbuc1 -txa -ora #{c1} -tax -//FRAGMENT vbuyy=vbuyy_bor_vbuc1 -tya -ora #{c1} -tay -//FRAGMENT vbuaa=_deref_pbuc1_rol_4 -lda {c1} -asl -asl -asl -asl -//FRAGMENT vbuxx=_deref_pbuc1_rol_4 -lda {c1} -asl -asl -asl -asl -tax -//FRAGMENT vbuyy=_deref_pbuc1_rol_4 -lda {c1} -asl -asl -asl -asl -tay -//FRAGMENT vbuaa=vbuz1_bor__deref_pbuc1 -lda {c1} -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor__deref_pbuc1 -lda {c1} -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor__deref_pbuc1 -lda {c1} -ora {z1} -tay -//FRAGMENT vbuz1=vbuaa_bor__deref_pbuc1 -ora {c1} -sta {z1} -//FRAGMENT vbuaa=vbuaa_bor__deref_pbuc1 -ora {c1} -//FRAGMENT vbuxx=vbuaa_bor__deref_pbuc1 -ora {c1} -tax -//FRAGMENT vbuyy=vbuaa_bor__deref_pbuc1 -ora {c1} -tay -//FRAGMENT vbuz1=vbuxx_bor__deref_pbuc1 -txa -ora {c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor__deref_pbuc1 -txa -ora {c1} -//FRAGMENT vbuxx=vbuxx_bor__deref_pbuc1 -txa -ora {c1} -tax -//FRAGMENT vbuyy=vbuxx_bor__deref_pbuc1 -txa -ora {c1} -tay -//FRAGMENT vbuz1=vbuyy_bor__deref_pbuc1 -tya -ora {c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_bor__deref_pbuc1 -tya -ora {c1} -//FRAGMENT vbuxx=vbuyy_bor__deref_pbuc1 -tya -ora {c1} -tax -//FRAGMENT vbuyy=vbuyy_bor__deref_pbuc1 -tya -ora {c1} -tay -//FRAGMENT vduz1=vduz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vbuyy -tya -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_(pbuc2_derefidx_vbuaa) -tax -ldy {c2},x -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_(pbuc2_derefidx_vbuxx) -ldy {c2},x -lda {c1},y -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuz2=pbuc1_derefidx_(pbuc2_derefidx_vbuyy) -ldx {c2},y -lda {c1},x -ldy {z2} -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_(pbuc2_derefidx_vbuz2) -ldy {z2} -ldx {c2},y -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_(pbuc2_derefidx_vbuaa) -tay -ldx {c2},y -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_(pbuc2_derefidx_vbuxx) -ldy {c2},x -ldx {c1},y -tay -txa -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuaa=pbuc1_derefidx_(pbuc2_derefidx_vbuyy) -ldx {c2},y -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_(pbuc2_derefidx_vbuz2) -ldy {z2} -txa -ldx {c2},y -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_(pbuc2_derefidx_vbuaa) -tay -txa -ldx {c2},y -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_(pbuc2_derefidx_vbuxx) -txa -tay -ldx {c2},y -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuxx=pbuc1_derefidx_(pbuc2_derefidx_vbuyy) -txa -ldx {c2},y -tay -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_(pbuc2_derefidx_vbuz2) -ldx {z2} -lda {c2},x -tax -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_(pbuc2_derefidx_vbuaa) -tax -lda {c2},x -tax -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_(pbuc2_derefidx_vbuxx) -lda {c2},x -tax -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuyy=pbuc1_derefidx_(pbuc2_derefidx_vbuyy) -ldx {c2},y -lda {c1},x -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuxx=_dec_pbuc1_derefidx_vbuxx -dec {c1},x -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_(pbuc2_derefidx_vbuxx) -ldy {c2},x -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbuxx_le_pbuc2_derefidx_vbuxx_then_la1 -txa -tay -lda {c2},x -cmp {c1},y -bcs {la1} -//FRAGMENT vbuaa=_deref_pbuz1_bor_vbuc1 -lda #{c1} -ldy #0 -ora ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1_bor_vbuc1 -lda #{c1} -ldy #0 -ora ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1_bor_vbuc1 -lda #{c1} -ldy #0 -ora ({z1}),y -tay -//FRAGMENT pbuc1_derefidx_vbuaa=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -sta {c1},y -//FRAGMENT vbuz1_neq_pbuc1_derefidx_vbuaa_then_la1 -tay -lda {c1},y -cmp {z1} -bne {la1} -//FRAGMENT vbuaa_neq_pbuc1_derefidx_vbuz1_then_la1 -ldy {z1} -cmp {c1},y -bne {la1} -//FRAGMENT vbuaa=vbuz1_bxor_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -eor {c1},y -//FRAGMENT vbuxx=vbuz1_bxor_pbuc1_derefidx_vbuz2 -lda {z1} -ldx {z2} -eor {c1},x -tax -//FRAGMENT vbuyy=vbuz1_bxor_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -eor {c1},y -tay -//FRAGMENT vbuz1=vbuz2_bxor_pbuc1_derefidx_vbuxx -lda {c1},x -eor {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bxor_pbuc1_derefidx_vbuxx -lda {c1},x -eor {z1} -//FRAGMENT vbuxx=vbuz1_bxor_pbuc1_derefidx_vbuxx -lda {c1},x -eor {z1} -tax -//FRAGMENT vbuyy=vbuz1_bxor_pbuc1_derefidx_vbuxx -lda {c1},x -eor {z1} -tay -//FRAGMENT vbuz1=vbuz2_bxor_pbuc1_derefidx_vbuyy -lda {c1},y -eor {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bxor_pbuc1_derefidx_vbuyy -lda {c1},y -eor {z1} -//FRAGMENT vbuxx=vbuz1_bxor_pbuc1_derefidx_vbuyy -lda {c1},y -eor {z1} -tax -//FRAGMENT vbuyy=vbuz1_bxor_pbuc1_derefidx_vbuyy -lda {c1},y -eor {z1} -tay -//FRAGMENT vbuz1=vbuaa_bxor_pbuc1_derefidx_vbuz2 -ldy {z2} -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_bxor_pbuc1_derefidx_vbuz1 -ldy {z1} -eor {c1},y -//FRAGMENT vbuxx=vbuaa_bxor_pbuc1_derefidx_vbuz1 -ldx {z1} -eor {c1},x -tax -//FRAGMENT vbuyy=vbuaa_bxor_pbuc1_derefidx_vbuz1 -ldy {z1} -eor {c1},y -tay -//FRAGMENT vbuz1=vbuaa_bxor_pbuc1_derefidx_vbuxx -eor {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuaa_bxor_pbuc1_derefidx_vbuxx -eor {c1},x -//FRAGMENT vbuxx=vbuaa_bxor_pbuc1_derefidx_vbuxx -eor {c1},x -tax -//FRAGMENT vbuyy=vbuaa_bxor_pbuc1_derefidx_vbuxx -eor {c1},x -tay -//FRAGMENT vbuz1=vbuaa_bxor_pbuc1_derefidx_vbuyy -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_bxor_pbuc1_derefidx_vbuyy -eor {c1},y -//FRAGMENT vbuxx=vbuaa_bxor_pbuc1_derefidx_vbuyy -eor {c1},y -tax -//FRAGMENT vbuyy=vbuaa_bxor_pbuc1_derefidx_vbuyy -eor {c1},y -tay -//FRAGMENT vbuz1=vbuxx_bxor_pbuc1_derefidx_vbuz2 -ldy {z2} -txa -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_bxor_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -eor {c1},y -//FRAGMENT vbuxx=vbuxx_bxor_pbuc1_derefidx_vbuz1 -txa -ldx {z1} -eor {c1},x -tax -//FRAGMENT vbuyy=vbuxx_bxor_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -eor {c1},y -tay -//FRAGMENT vbuz1=vbuxx_bxor_pbuc1_derefidx_vbuxx -txa -eor {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuxx_bxor_pbuc1_derefidx_vbuxx -txa -eor {c1},x -//FRAGMENT vbuxx=vbuxx_bxor_pbuc1_derefidx_vbuxx -txa -eor {c1},x -tax -//FRAGMENT vbuyy=vbuxx_bxor_pbuc1_derefidx_vbuxx -txa -eor {c1},x -tay -//FRAGMENT vbuz1=vbuxx_bxor_pbuc1_derefidx_vbuyy -txa -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_bxor_pbuc1_derefidx_vbuyy -txa -eor {c1},y -//FRAGMENT vbuxx=vbuxx_bxor_pbuc1_derefidx_vbuyy -txa -eor {c1},y -tax -//FRAGMENT vbuyy=vbuxx_bxor_pbuc1_derefidx_vbuyy -txa -eor {c1},y -tay -//FRAGMENT vbuz1=vbuyy_bxor_pbuc1_derefidx_vbuz2 -tya -ldy {z2} -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_bxor_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -eor {c1},y -//FRAGMENT vbuxx=vbuyy_bxor_pbuc1_derefidx_vbuz1 -ldx {z1} -tya -eor {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bxor_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -eor {c1},y -tay -//FRAGMENT vbuz1=vbuyy_bxor_pbuc1_derefidx_vbuxx -tya -eor {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuyy_bxor_pbuc1_derefidx_vbuxx -tya -eor {c1},x -//FRAGMENT vbuxx=vbuyy_bxor_pbuc1_derefidx_vbuxx -tya -eor {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bxor_pbuc1_derefidx_vbuxx -tya -eor {c1},x -tay -//FRAGMENT vbuz1=vbuyy_bxor_pbuc1_derefidx_vbuyy -tya -eor {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_bxor_pbuc1_derefidx_vbuyy -tya -eor {c1},y -//FRAGMENT vbuxx=vbuyy_bxor_pbuc1_derefidx_vbuyy -tya -eor {c1},y -tax -//FRAGMENT vbuyy=vbuyy_bxor_pbuc1_derefidx_vbuyy -tya -eor {c1},y -tay -//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -and {c1},y -//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuz2 -lda {z1} -ldx {z2} -and {c1},x -tax -//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -and {c1},y -tay -//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuz2 -ldy {z2} -and {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuz1 -ldy {z1} -and {c1},y -//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuz1 -ldx {z1} -and {c1},x -tax -//FRAGMENT vbuyy=vbuaa_band_pbuc1_derefidx_vbuz1 -ldy {z1} -and {c1},y -tay -//FRAGMENT vbuz1=vbuxx_band_pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sax {z1} -//FRAGMENT vbuaa=vbuxx_band_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -and {c1},y -//FRAGMENT vbuxx=vbuxx_band_pbuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -axs #0 -//FRAGMENT vbuyy=vbuxx_band_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -and {c1},y -tay -//FRAGMENT vbuz1=vbuyy_band_pbuc1_derefidx_vbuz2 -tya -ldy {z2} -and {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_band_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -and {c1},y -//FRAGMENT vbuxx=vbuyy_band_pbuc1_derefidx_vbuz1 -ldx {z1} -tya -and {c1},x -tax -//FRAGMENT vbuyy=vbuyy_band_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -and {c1},y -tay -//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuxx -lda {c1},x -and {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuxx -lda {c1},x -and {z1} -//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuxx -lda {c1},x -and {z1} -tax -//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuxx -lda {c1},x -and {z1} -tay -//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuxx -and {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuxx -and {c1},x -//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuxx -and {c1},x -tax -//FRAGMENT vbuyy=vbuaa_band_pbuc1_derefidx_vbuxx -and {c1},x -tay -//FRAGMENT vbuz1=vbuxx_band_pbuc1_derefidx_vbuxx -lda {c1},x -sax {z1} -//FRAGMENT vbuaa=vbuxx_band_pbuc1_derefidx_vbuxx -txa -and {c1},x -//FRAGMENT vbuxx=vbuxx_band_pbuc1_derefidx_vbuxx -lda {c1},x -axs #0 -//FRAGMENT vbuyy=vbuxx_band_pbuc1_derefidx_vbuxx -txa -and {c1},x -tay -//FRAGMENT vbuz1=vbuyy_band_pbuc1_derefidx_vbuxx -tya -and {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuyy_band_pbuc1_derefidx_vbuxx -tya -and {c1},x -//FRAGMENT vbuxx=vbuyy_band_pbuc1_derefidx_vbuxx -tya -and {c1},x -tax -//FRAGMENT vbuyy=vbuyy_band_pbuc1_derefidx_vbuxx -tya -and {c1},x -tay -//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuyy -lda {c1},y -and {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuyy -lda {c1},y -and {z1} -//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuyy -lda {c1},y -and {z1} -tax -//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuyy -lda {c1},y -and {z1} -tay -//FRAGMENT vbuz1=vbuaa_band_pbuc1_derefidx_vbuyy -and {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_band_pbuc1_derefidx_vbuyy -and {c1},y -//FRAGMENT vbuxx=vbuaa_band_pbuc1_derefidx_vbuyy -ldx {c1},y -axs #0 -//FRAGMENT vbuz1=vbuxx_band_pbuc1_derefidx_vbuyy -lda {c1},y -sax {z1} -//FRAGMENT vbuz1=vbuyy_band_pbuc1_derefidx_vbuyy -tya -and {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_band_pbuc1_derefidx_vbuyy -txa -and {c1},y -//FRAGMENT vbuaa=vbuyy_band_pbuc1_derefidx_vbuyy -tya -and {c1},y -//FRAGMENT vbuxx=vbuxx_band_pbuc1_derefidx_vbuyy -lda {c1},y -axs #0 -//FRAGMENT vbuxx=vbuyy_band_pbuc1_derefidx_vbuyy -ldx {c1},y -tya -axs #0 -//FRAGMENT vbuyy=vbuxx_band_pbuc1_derefidx_vbuyy -txa -and {c1},y -tay -//FRAGMENT vbuyy=vbuyy_band_pbuc1_derefidx_vbuyy -tya -and {c1},y -tay -//FRAGMENT vbuz1=vbuxx_bor_vbuc1 -txa -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_vbuc1 -txa -ora #{c1} -//FRAGMENT vbuyy=vbuxx_bor_vbuc1 -txa -ora #{c1} -tay -//FRAGMENT vbuz1=vbuyy_bor_vbuc1 -tya -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_bor_vbuc1 -tya -ora #{c1} -//FRAGMENT vbuxx=vbuyy_bor_vbuc1 -tya -ora #{c1} -tax -//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuaa -tay -lda {c2},y -sta {c1} -//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuxx -lda {c2},x -sta {c1} -//FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuyy -lda {c2},y -sta {c1} -//FRAGMENT vbuz1=vbuaa_ror_3 -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuz1=vbuxx_ror_3 -txa -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuz1=vbuyy_ror_3 -tya -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_3 -lda {z1} -lsr -lsr -lsr -//FRAGMENT vbuaa=vbuaa_ror_3 -lsr -lsr -lsr -//FRAGMENT vbuaa=vbuxx_ror_3 -txa -lsr -lsr -lsr -//FRAGMENT vbuaa=vbuyy_ror_3 -tya -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuz1_ror_3 -lda {z1} -lsr -lsr -lsr -tax -//FRAGMENT vbuxx=vbuaa_ror_3 -lsr -lsr -lsr -tax -//FRAGMENT vbuxx=vbuxx_ror_3 -txa -lsr -lsr -lsr -tax -//FRAGMENT vbuxx=vbuyy_ror_3 -tya -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuz1_ror_3 -lda {z1} -lsr -lsr -lsr -tay -//FRAGMENT vbuyy=vbuaa_ror_3 -lsr -lsr -lsr -tay -//FRAGMENT vbuyy=vbuxx_ror_3 -txa -lsr -lsr -lsr -tay -//FRAGMENT vbuyy=vbuyy_ror_3 -tya -lsr -lsr -lsr -tay -//FRAGMENT vbuz1=vbuz2_band_pbuc1_derefidx_vbuaa -tay -lda {c1},y -and {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_band_pbuc1_derefidx_vbuaa -tay -lda {c1},y -sax {z1} -//FRAGMENT vbuz1=vbuyy_band_pbuc1_derefidx_vbuaa -tax -tya -and {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuz1_band_pbuc1_derefidx_vbuaa -tay -lda {c1},y -and {z1} -//FRAGMENT vbuaa=vbuxx_band_pbuc1_derefidx_vbuaa -tay -txa -and {c1},y -//FRAGMENT vbuaa=vbuyy_band_pbuc1_derefidx_vbuaa -tax -tya -and {c1},x -//FRAGMENT vbuxx=vbuz1_band_pbuc1_derefidx_vbuaa -tax -lda {c1},x -and {z1} -tax -//FRAGMENT vbuxx=vbuxx_band_pbuc1_derefidx_vbuaa -tay -lda {c1},y -axs #0 -//FRAGMENT vbuxx=vbuyy_band_pbuc1_derefidx_vbuaa -tax -tya -and {c1},x -tax -//FRAGMENT vbuyy=vbuz1_band_pbuc1_derefidx_vbuaa -tay -lda {c1},y -and {z1} -tay -//FRAGMENT vbuyy=vbuxx_band_pbuc1_derefidx_vbuaa -tay -txa -and {c1},y -tay -//FRAGMENT vbuyy=vbuyy_band_pbuc1_derefidx_vbuaa -tax -tya -and {c1},x -tay -//FRAGMENT vbuyy=_lo_pbuz1 -ldy {z1} -//FRAGMENT vbuz1=vbuz2_bor__lo_pbuz3 -lda {z2} -ora {z3} -sta {z1} -//FRAGMENT vduz1=vduz1_plus_vbuxx -txa -clc -adc {z1} -sta {z1} -lda {z1}+1 -adc #0 -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz1_band_vwuc1 -lda {z1} -and #<{c1} -sta {z1} -lda {z1}+1 -and #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_ror_6 -lda {z1} -asl -sta $ff -lda {z1}+1 -rol -sta {z1} -lda #0 -rol -sta {z1}+1 -asl $ff -rol {z1} -rol {z1}+1 -//FRAGMENT vbsz1=vbsz2_plus_vbsc1 -lax {z2} -axs #-[{c1}] -stx {z1} -//FRAGMENT vbsz1=vbsc1_plus_vbsz2 -lax {z2} -axs #-[{c1}] -stx {z1} -//FRAGMENT vbsz1=vbsz2_plus_vbsz2 -lda {z2} -asl -sta {z1} -//FRAGMENT vbsaa=vbsz1_plus_vbsc1 -lda #{c1} -clc -adc {z1} -//FRAGMENT vbsxx=vbsz1_plus_vbsc1 -lax {z1} -axs #-[{c1}] -//FRAGMENT vbsyy=vbsz1_plus_vbsc1 -lda #{c1} -clc -adc {z1} -tay -//FRAGMENT vbsaa=vbsc1_plus_vbsz1 -lda #{c1} -clc -adc {z1} -//FRAGMENT vbsxx=vbsc1_plus_vbsz1 -lax {z1} -axs #-[{c1}] -//FRAGMENT vbsyy=vbsc1_plus_vbsz1 -lda #{c1} -clc -adc {z1} -tay -//FRAGMENT vbsaa=vbsz1_plus_vbsz1 -lda {z1} -asl -//FRAGMENT vbsxx=vbsz1_plus_vbsz1 -lda {z1} -asl -tax -//FRAGMENT vbsyy=vbsz1_plus_vbsz1 -lda {z1} -asl -tay -//FRAGMENT vbsz1=vbsz2_rol_1 -lda {z2} -asl -sta {z1} -//FRAGMENT vbsz1=vbsz2_minus_vbsc1 -lax {z2} -axs #{c1} -stx {z1} -//FRAGMENT vbsaa=vbsz1_rol_1 -lda {z1} -asl -//FRAGMENT vbsxx=vbsz1_rol_1 -lda {z1} -asl -tax -//FRAGMENT vbsyy=vbsz1_rol_1 -lda {z1} -asl -tay -//FRAGMENT vbsz1=vbsxx_rol_1 -txa -asl -sta {z1} -//FRAGMENT vbsaa=vbsxx_rol_1 -txa -asl -//FRAGMENT vbsxx=vbsxx_rol_1 -txa -asl -tax -//FRAGMENT vbsyy=vbsxx_rol_1 -txa -asl -tay -//FRAGMENT vbsz1=vbsyy_rol_1 -tya -asl -sta {z1} -//FRAGMENT vbsaa=vbsyy_rol_1 -tya -asl -//FRAGMENT vbsxx=vbsyy_rol_1 -tya -asl -tax -//FRAGMENT vbsyy=vbsyy_rol_1 -tya -asl -tay -//FRAGMENT vbsz1=vbsaa_minus_vbsc1 -sec -sbc #{c1} -sta {z1} -//FRAGMENT vbsz1=vbsxx_minus_vbsc1 -txa -axs #{c1} -stx {z1} -//FRAGMENT vbsz1=vbsyy_minus_vbsc1 -tya -sec -sbc #{c1} -sta {z1} -//FRAGMENT vbsaa=vbsz1_minus_vbsc1 -lda {z1} -sec -sbc #{c1} -//FRAGMENT vbsaa=vbsaa_minus_vbsc1 -sec -sbc #{c1} -//FRAGMENT vbsaa=vbsxx_minus_vbsc1 -txa -sec -sbc #{c1} -//FRAGMENT vbsaa=vbsyy_minus_vbsc1 -tya -sec -sbc #{c1} -//FRAGMENT vbsxx=vbsz1_minus_vbsc1 -lax {z1} -axs #{c1} -//FRAGMENT vbsxx=vbsaa_minus_vbsc1 -tax -axs #{c1} -//FRAGMENT vbsxx=vbsyy_minus_vbsc1 -tya -tax -axs #{c1} -//FRAGMENT vbsyy=vbsz1_minus_vbsc1 -lda {z1} -sec -sbc #{c1} -tay -//FRAGMENT vbsyy=vbsaa_minus_vbsc1 -sec -sbc #{c1} -tay -//FRAGMENT vbsyy=vbsxx_minus_vbsc1 -txa -sec -sbc #{c1} -tay -//FRAGMENT vbuc1_gt_vbuz1_then_la1 -lda {z1} -cmp #{c1} -bcc {la1} -//FRAGMENT vbuc1_gt_vbuxx_then_la1 -cpx #{c1} -bcc {la1} -//FRAGMENT vwuz1=vbuz2_rol_1 -lda {z2} -asl -sta {z1} -lda #0 -rol -sta {z1}+1 -//FRAGMENT vwuz1=vbuxx_rol_1 -txa -asl -sta {z1} -lda #0 -rol -sta {z1}+1 -//FRAGMENT vwuz1=vbuyy_rol_1 -tya -asl -sta {z1} -lda #0 -rol -sta {z1}+1 -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy -lda {c1},y -tay //FRAGMENT vbsz1=vbsc1_minus_vbsz2 lda #{c1} sec sbc {z2} sta {z1} +//FRAGMENT vbsaa=_sbyte_vwuz1 +lda {z1} +//FRAGMENT vbsxx=_sbyte_vwuz1 +ldx {z1} //FRAGMENT vbsz1=vbsc1_minus_vbsaa eor #$ff sec @@ -12393,88 +14228,17 @@ eor #$ff sec adc #{c1} tay -//FRAGMENT 0_neq_vbsaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbsyy=vbsz1_minus_vbsaa -eor #$ff -sec -adc {z1} -tay -//FRAGMENT vbsyy=vbsxx_minus_vbsaa -sta $ff -txa -sec -sbc $ff -tay -//FRAGMENT vbsyy=vbsyy_minus_vbsaa -sta $ff -tya -sec -sbc $ff -tay -//FRAGMENT vbsyy_lt_0_then_la1 -cpy #0 -bmi {la1} -//FRAGMENT vbsz1_neq_0_then_la1 -lda {z1} -cmp #0 -bne {la1} -//FRAGMENT vwsz1=vbsz2 -lda {z2} -sta {z1} -and #$80 -beq !+ -lda #$ff -!: -sta {z1}+1 -//FRAGMENT vbsaa_neq_0_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vwsz1=vbsaa -sta {z1} -and #$80 -beq !+ -lda #$ff -!: -sta {z1}+1 -//FRAGMENT vwsz1=vbsxx -txa -sta {z1} -and #$80 -beq !+ -lda #$ff -!: -sta {z1}+1 -//FRAGMENT vwsz1=vbsyy -tya -sta {z1} -and #$80 -beq !+ -lda #$ff -!: -sta {z1}+1 -//FRAGMENT vbsxx_neq_0_then_la1 -cpx #0 -bne {la1} -//FRAGMENT pwsz1=pwsc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 +//FRAGMENT vbsyy=_sbyte_vwuz1 +ldy {z1} +//FRAGMENT _deref_pbuz1=_deref_pbuc1 +lda {c1} +ldy #0 +sta ({z1}),y //FRAGMENT vwuz1=_hi_vdsz2 lda {z2}+2 sta {z1} lda {z2}+3 sta {z1}+1 -//FRAGMENT pwsz1=pwsz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: //FRAGMENT pwsz1=pwsc1_plus_vwuz2 clc lda {z2} @@ -12483,23 +14247,6 @@ sta {z1} lda {z2}+1 adc #>{c1} sta {z1}+1 -//FRAGMENT vduz1_lt_vduc1_then_la1 -lda {z1}+3 -cmp #>{c1}>>$10 -bcc {la1} -bne !+ -lda {z1}+2 -cmp #<{c1}>>$10 -bcc {la1} -bne !+ -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: //FRAGMENT vduz1=vduc1_minus_vduz1 lda #<{c1} sec @@ -12546,9 +14293,14 @@ sta {z1}+1 //FRAGMENT vbuz1=_byte_vwsz2 lda {z2} sta {z1} -//FRAGMENT vbsz1=_sbyte_vwsz2 -lda {z2} +//FRAGMENT vwsz1=vwsz1_minus_vwsc1 +lda {z1} +sec +sbc #<{c1} sta {z1} +lda {z1}+1 +sbc #>{c1} +sta {z1}+1 //FRAGMENT vduz1=vduz2_rol_vbuz3 ldy {z3} lda {z2} @@ -12577,14 +14329,6 @@ tax //FRAGMENT vbuyy=_byte_vwsz1 lda {z1} tay -//FRAGMENT vbsaa=_sbyte_vwsz1 -lda {z1} -//FRAGMENT vbsxx=_sbyte_vwsz1 -lda {z1} -tax -//FRAGMENT vbsyy=_sbyte_vwsz1 -lda {z1} -tay //FRAGMENT vduz1=vduz2_rol_vbuxx lda {z2} sta {z1} @@ -12651,253 +14395,6 @@ rol {z1}+3 dex bne !- !e: -//FRAGMENT isr_rom_sys_c64_entry - -//FRAGMENT isr_rom_sys_c64_exit -jmp $ea31 -//FRAGMENT vwsz1_neq_vwsc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pwsc1=vwsz1 -lda {z1} -sta {c1} -lda {z1}+1 -sta {c1}+1 -//FRAGMENT pssz1=pssc1_plus_vbuz2 -lda {z2} -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=pbuz2_derefidx_vbuc2 -ldx {z1} -ldy #{c2} -lda ({z2}),y -sta {c1},x -//FRAGMENT pssz1=pssc1_plus_vbuaa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pssz1=pssc1_plus_vbuxx -txa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pssz1=pssc1_plus_vbuyy -tya -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuxx=pbuz1_derefidx_vbuc2 -ldy #{c2} -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuz1_derefidx_vbuc2 -tya -ldy #{c2} -tax -lda ({z1}),y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuaa=pbuz1_derefidx_vbuc2 -ldy #{c2} -tax -lda ({z1}),y -sta {c1},x -//FRAGMENT _deref_qssc1=pssc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -//FRAGMENT pssc1_neq_pssz1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT vbuz1=vbuc1_plus__deref_pbuz2 -lda #{c1} -clc -ldy #0 -adc ({z2}),y -sta {z1} -//FRAGMENT vbuz1=_lo_qssz2_derefidx_vbuc1 -ldy #{c1} -lda ({z2}),y -sta {z1} -//FRAGMENT vbuz1=_hi_qssz2_derefidx_vbuc1 -ldy #{c1}+1 -lda ({z2}),y -sta {z1} -//FRAGMENT pssz1=qssz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -pha -iny -lda ({z1}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT vbuaa=vbuc1_plus__deref_pbuz1 -lda #{c1} -clc -ldy #0 -adc ({z1}),y -//FRAGMENT vbuxx=vbuc1_plus__deref_pbuz1 -ldy #0 -lda ({z1}),y -tax -axs #-[{c1}] -//FRAGMENT vbuyy=vbuc1_plus__deref_pbuz1 -lda #{c1} -clc -ldy #0 -adc ({z1}),y -tay -//FRAGMENT vbuaa=_lo_qssz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -//FRAGMENT vbuxx=_lo_qssz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tax -//FRAGMENT vbuyy=_lo_qssz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tay -//FRAGMENT vbuaa=_hi_qssz1_derefidx_vbuc1 -ldy #{c1}+1 -lda ({z1}),y -//FRAGMENT vbuxx=_hi_qssz1_derefidx_vbuc1 -ldy #{c1}+1 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_hi_qssz1_derefidx_vbuc1 -ldy #{c1}+1 -lda ({z1}),y -tay -//FRAGMENT pssc1_derefidx_vbuz1=pssc2_derefidx_vbuz1_memcpy_vbuc3 -ldx #{c3} -ldy {z1} -!: -lda {c2},y -sta {c1},y -iny -dex -bne !- -//FRAGMENT pssc1_derefidx_vbuaa=pssc2_derefidx_vbuaa_memcpy_vbuc3 -ldx #{c3} -tay -!: -lda {c2},y -sta {c1},y -iny -dex -bne !- -//FRAGMENT pssc1_derefidx_vbuxx=pssc2_derefidx_vbuxx_memcpy_vbuc3 -ldy #{c3} -!: -lda {c2},x -sta {c1},x -inx -dey -bne !- -//FRAGMENT pssc1_derefidx_vbuyy=pssc2_derefidx_vbuyy_memcpy_vbuc3 -ldx #{c3} -!: -lda {c2},y -sta {c1},y -iny -dex -bne !- -//FRAGMENT vbum1_lt_vbuc1_then_la1 -lda {m1} -cmp #{c1} -bcc {la1} -//FRAGMENT pbuc1_derefidx_vbum1=vbum1 -ldy {m1} -tya -sta {c1},y -//FRAGMENT pwuc1_derefidx_vbuz1=vwuc2 -ldy {z1} -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=vwuc2 -tay -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vwuc2 -lda #<{c2} -sta {c1},x -lda #>{c2} -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vwuc2 -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT _deref_pbuc1_ge_vbuc2_then_la1 -lda {c1} -cmp #{c2} -bcs {la1} -//FRAGMENT vboz1=vboxx -txa -sta {z1} -//FRAGMENT vboaa=vboxx -txa -//FRAGMENT vboxx=vboaa -tax -//FRAGMENT vboxx=vboyy -tya -tax -//FRAGMENT vboyy=vboxx -txa -tay -//FRAGMENT _deref_pbuz1=_deref_pbuc1 -lda {c1} -ldy #0 -sta ({z1}),y -//FRAGMENT vbsz1=vbsz1_minus_vbsxx -txa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vwsz1=vwsz1_minus_vwsc1 -lda {z1} -sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT vbuc1_ge_vbuz1_then_la1 -lda #{c1} -cmp {z1} -bcs {la1} -//FRAGMENT vbuc1_ge_vbuxx_then_la1 -cpx #{c1} -bcc {la1} -beq {la1} //FRAGMENT vbsz1=pbsc1_derefidx_vbuz2_minus_pbsc2_derefidx_vbuz2 ldy {z2} lda {c1},y @@ -13007,97 +14504,6 @@ sta ({z1}),y tya ldy #0 sta ({z1}),y -//FRAGMENT vwuz1=_deref_pwuc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_minus_1 -ldx {z1} -lda {c1},x -bne !+ -dec {c1}+1,x -!: -dec {c1},x -//FRAGMENT pwuc1_derefidx_vbuaa=pwuc1_derefidx_vbuaa_minus_1 -tax -lda {c1},x -bne !+ -dec {c1}+1,x -!: -dec {c1},x -//FRAGMENT pwuc1_derefidx_vbuxx=pwuc1_derefidx_vbuxx_minus_1 -lda {c1},x -bne !+ -dec {c1}+1,x -!: -dec {c1},x -//FRAGMENT pwuc1_derefidx_vbuyy=pwuc1_derefidx_vbuyy_minus_1 -sec -lda {c1},y -sbc #$01 -sta {c1},y -lda {c1}+1,y -sbc #$00 -sta {c1}+1,y -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_1 -ldx {z2} -ldy {c1},x -iny -sty {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_1 -ldy {z1} -lda {c1},y -clc -adc #1 -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_1 -ldy {z1} -ldx {c1},y -inx -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_1 -ldx {z1} -ldy {c1},x -iny -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_1 -tax -ldy {c1},x -iny -sty {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_1 -tay -lda {c1},y -clc -adc #1 -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_1 -tay -ldx {c1},y -inx -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_1 -tax -ldy {c1},x -iny -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_1 -ldy {c1},x -iny -sty {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_1 -lda {c1},x -clc -adc #1 -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_1 -ldy {c1},x -iny -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_1 -ldx {c1},y -inx -stx {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_1 -lda {c1},y -clc -adc #1 -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_1 -ldx {c1},y -inx //FRAGMENT vwuz1_eq_vwuz2_then_la1 lda {z1} cmp {z2} @@ -13106,15 +14512,6 @@ lda {z1}+1 cmp {z2}+1 beq {la1} !: -//FRAGMENT vwuz1_le_vwuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne !+ -lda {z1} -cmp {z2} -beq {la1} -!: -bcc {la1} //FRAGMENT vduz1=vwuz2_dword_vwuc1 lda #<{c1} sta {z1} @@ -13132,1162 +14529,6 @@ sta {z1} lda {z1}+1 sbc #0 sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuz3 -lda {z2} -ldy {z3} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -clc -adc {c1},y -//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuz2 -lda {z1} -ldx {z2} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuz2 -ldy {z2} -txa -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -clc -adc {c1},y -//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuz1 -txa -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -clc -adc {c1},y -tay -//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuz2 -tya -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuz1 -ldx {z1} -tya -clc -adc {c1},x -tax -//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuxx -txa -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuxx -txa -clc -adc {c1},x -//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuxx -txa -clc -adc {c1},x -tax -//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuxx -txa -clc -adc {c1},x -tay -//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuxx -tya -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuxx -tya -clc -adc {c1},x -//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuxx -tya -clc -adc {c1},x -tax -//FRAGMENT vbuz1=vbuz2_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuxx_plus_pbuc1_derefidx_vbuyy -txa -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus_pbuc1_derefidx_vbuyy -txa -clc -adc {c1},y -//FRAGMENT vbuxx=vbuxx_plus_pbuc1_derefidx_vbuyy -txa -clc -adc {c1},y -tax -//FRAGMENT vbuyy=vbuxx_plus_pbuc1_derefidx_vbuyy -txa -clc -adc {c1},y -tay -//FRAGMENT vbuz1=vbuyy_plus_pbuc1_derefidx_vbuyy -tya -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus_pbuc1_derefidx_vbuyy -tya -clc -adc {c1},y -//FRAGMENT vbuxx=vbuyy_plus_pbuc1_derefidx_vbuyy -tya -clc -adc {c1},y -tax -//FRAGMENT vduz1_lt_vwuc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vduz1_lt_vwsc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz2_rol_4 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -lda {z2}+2 -rol -sta {z1}+2 -lda {z2}+3 -rol -sta {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vduz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -lda {z2}+2 -adc {z3}+2 -sta {z1}+2 -lda {z2}+3 -adc {z3}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_1 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -lda {z2}+2 -rol -sta {z1}+2 -lda {z2}+3 -rol -sta {z1}+3 -//FRAGMENT vduz1=vduz1_plus_vwuc1 -lda {z1} -clc -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_rol_2 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vbsz1_gt_0_then_la1 -lda {z1} -cmp #0 -beq !+ -bpl {la1} -!: -//FRAGMENT vbuz1=vbuc1_minus_vbuz1 -lda #{c1} -sec -sbc {z1} -sta {z1} -//FRAGMENT vbuz1=_neg_vbuz1 -lda {z1} -eor #$ff -clc -adc #$01 -sta {z1} -//FRAGMENT vbsz1=vbsz2_ror_vbuz3 -lda {z2} -ldy {z3} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsz1=vbsz1_plus_vbsz2 -lda {z1} -clc -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -sec -sbc {c1},y -sta {z1} -//FRAGMENT vbsaa_neq_vbsc1_then_la1 -cmp #{c1} -bne {la1} -//FRAGMENT vbsaa_gt_0_then_la1 -cmp #0 -beq !+ -bpl {la1} -!: -//FRAGMENT vbsxx_gt_0_then_la1 -txa -cmp #0 -beq !+ -bpl {la1} -!: -//FRAGMENT vbsyy_gt_0_then_la1 -tya -cmp #0 -beq !+ -bpl {la1} -!: -//FRAGMENT vbsaa=vbsz1_ror_vbuz2 -lda {z1} -ldy {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsz1_ror_vbuz2 -lda {z1} -ldx {z2} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsz1_ror_vbuz2 -lda {z1} -ldy {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsaa_ror_vbuz2 -ldy {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsaa_ror_vbuz1 -ldy {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsaa_ror_vbuz1 -ldx {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsaa_ror_vbuz1 -ldy {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsxx_ror_vbuz2 -ldy {z2} -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsxx_ror_vbuz1 -ldy {z1} -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsxx_ror_vbuz1 -txa -ldx {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsxx_ror_vbuz1 -ldy {z1} -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsyy_ror_vbuz2 -tya -ldy {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsyy_ror_vbuz1 -tya -ldy {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsyy_ror_vbuz1 -ldx {z1} -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsyy_ror_vbuz1 -tya -ldy {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsz2_ror_vbuaa -tay -lda {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsz1_ror_vbuaa -tay -lda {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsz1_ror_vbuaa -tax -lda {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsz1_ror_vbuaa -tay -lda {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsaa_ror_vbuaa -tay -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsaa_ror_vbuaa -tay -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsaa_ror_vbuaa -tax -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsaa_ror_vbuaa -tay -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsyy_ror_vbuaa -tax -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsyy_ror_vbuaa -tax -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -//FRAGMENT vbsxx=vbsyy_ror_vbuaa -tax -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsyy_ror_vbuaa -tax -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsz2_ror_vbuxx -lda {z2} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -//FRAGMENT vbsxx=vbsz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsaa_ror_vbuxx -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsaa_ror_vbuxx -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -//FRAGMENT vbsxx=vbsaa_ror_vbuxx -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsaa_ror_vbuxx -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsxx_ror_vbuxx -txa -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsxx_ror_vbuxx -txa -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -//FRAGMENT vbsxx=vbsxx_ror_vbuxx -txa -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsxx_ror_vbuxx -txa -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsyy_ror_vbuxx -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsyy_ror_vbuxx -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -//FRAGMENT vbsxx=vbsyy_ror_vbuxx -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsyy_ror_vbuxx -tya -cpx #0 -beq !e+ -!l: -cmp #$80 -ror -dex -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsz2_ror_vbuyy -lda {z2} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsaa_ror_vbuyy -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsaa_ror_vbuyy -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsaa_ror_vbuyy -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsaa_ror_vbuyy -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsyy_ror_vbuyy -tya -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -sta {z1} -//FRAGMENT vbsaa=vbsyy_ror_vbuyy -tya -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -//FRAGMENT vbsxx=vbsyy_ror_vbuyy -tya -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tax -//FRAGMENT vbsyy=vbsyy_ror_vbuyy -tya -cpy #0 -beq !e+ -!l: -cmp #$80 -ror -dey -bne !l- -!e: -tay -//FRAGMENT vbsz1=vbsz1_minus_vbsyy -tya -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbsz1=vbsz1_plus_vbsxx -txa -clc -adc {z1} -sta {z1} -//FRAGMENT vbsz1=vbsz1_plus_vbsyy -tya -clc -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuz1 -txa -ldx {z1} -sec -sbc {c1},x -tax -//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -sec -sbc {c1},y -tay -//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuxx -lda {z1} -sec -sbc {c1},x -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuxx -txa -tax -sec -sbc {c1},x -tax -//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuxx -tya -sec -sbc {c1},x -tay -//FRAGMENT vbuz1=vbuz1_minus_pbuc1_derefidx_vbuyy -lda {z1} -sec -sbc {c1},y -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_pbuc1_derefidx_vbuyy -txa -sec -sbc {c1},y -tax -//FRAGMENT vbuyy=vbuyy_minus_pbuc1_derefidx_vbuyy -tya -tay -sec -sbc {c1},y -tay -//FRAGMENT vbsyy_neq_0_then_la1 -cpy #0 -bne {la1} -//FRAGMENT _deref_pduc1=vduz1 -lda {z1} -sta {c1} -lda {z1}+1 -sta {c1}+1 -lda {z1}+2 -sta {c1}+2 -lda {z1}+3 -sta {c1}+3 -//FRAGMENT vduz1=_dec_vduz2 -lda {z2} -sec -sbc #1 -sta {z1} -lda {z2}+1 -sbc #0 -sta {z1}+1 -lda {z2}+2 -sbc #0 -sta {z1}+2 -lda {z2}+3 -sbc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_plus_vbuc1 -lda {z1} -clc -adc #{c1} -sta {z1} -bcc !+ -inc {z1}+1 -bne !+ -inc {z1}+2 -bne !+ -inc {z1}+3 -!: -//FRAGMENT vduz1=_dec_vduz1 -lda {z1} -sec -sbc #1 -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -lda {z1}+2 -sbc #0 -sta {z1}+2 -lda {z1}+3 -sbc #0 -sta {z1}+3 -//FRAGMENT vwuz1=_stackidxword_vbuc1 -tsx -lda STACK_BASE+{c1},x -sta {z1} -lda STACK_BASE+{c1}+1,x -sta {z1}+1 -//FRAGMENT _stackidxword_vbuc1=vwuz1 -tsx -lda {z1} -sta STACK_BASE+{c1},x -lda {z1}+1 -sta STACK_BASE+{c1}+1,x -//FRAGMENT _stackpushword_=vwuc1 -lda #>{c1} -pha -lda #<{c1} -pha -//FRAGMENT vwuz1=_stackpullword_ -pla -sta {z1} -pla -sta {z1}+1 -//FRAGMENT _stackpushword_=vbuc1 -lda #0 -pha -lda #<{c1} -pha -//FRAGMENT _stackidxsword_vbuc1=vwsz1 -tsx -lda {z1} -sta STACK_BASE+{c1},x -lda {z1}+1 -sta STACK_BASE+{c1}+1,x -//FRAGMENT _stackpushbyte_2 -pha -pha -//FRAGMENT vwsz1=_stackpullsword_ -pla -sta {z1} -pla -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuaa=_inc_pbuc1_derefidx_vbuaa -tax -inc {c1},x -//FRAGMENT vbuaa=vbuaa_bor_vbuc1 -ora #{c1} //FRAGMENT vbuz1=_deref_pbuz2_rol_1 ldy #0 lda ({z2}),y @@ -14331,163 +14572,6 @@ inc {c1},x bne !+ inc {c1}+1,x !: -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_(pbuc3_derefidx_vbuz1) -ldx {z1} -ldy {c3},x -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_(pbuc3_derefidx_vbuxx) -ldy {c3},x -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_(pbuc3_derefidx_vbuyy) -ldx {c3},y -lda {c2},x -sta {c1},y -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -sta {z1} -//FRAGMENT _deref_pbuc1_lt_vbuz1_then_la1 -lda {c1} -cmp {z1} -bcc {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_(pbuc2_derefidx_vbuz2) -ldx {z2} -ldy {c2},x -ldx {c1},y -stx {z1} -//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuz2 -ldy {z2} -lda {c1}+1,y -sta {z1} -//FRAGMENT vbuz1=vbuc1_bxor_vbuz2 -lda #{c1} -eor {z2} -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -tax -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -tay -//FRAGMENT _deref_pbuc1_lt_vbuaa_then_la1 -ldy {c1} -sta $ff -cpy $ff -bcc {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_(pbuc2_derefidx_vbuz1) -ldx {z1} -ldy {c2},x -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_(pbuc2_derefidx_vbuz1) -ldx {z1} -ldy {c2},x -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_(pbuc2_derefidx_vbuz1) -ldy {z1} -ldx {c2},y -ldy {c1},x -//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuz1 -ldx {z1} -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -tay -//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuaa -tay -lda {c1},y -//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuaa -tax -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuaa -tay -lda {c1},y -tay -//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuxx -lda {c1},x -//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuxx -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuxx -lda {c1},x -tay -//FRAGMENT vbuz1=_lo_pwuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=_lo_pwuc1_derefidx_vbuyy -lda {c1},y -//FRAGMENT vbuxx=_lo_pwuc1_derefidx_vbuyy -lda {c1},y -tax -//FRAGMENT vbuyy=_lo_pwuc1_derefidx_vbuyy -lda {c1},y -tay -//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuxx -lda {c1}+1,x -sta {z1} -//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuz1 -ldy {z1} -lda {c1}+1,y -//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuxx -lda {c1}+1,x -//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuz1 -ldx {z1} -lda {c1}+1,x -tax -//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuxx -lda {c1}+1,x -tax -//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuz1 -ldy {z1} -lda {c1}+1,y -tay -//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuxx -lda {c1}+1,x -tay -//FRAGMENT vbuaa=vbuc1_bxor_vbuz1 -lda #{c1} -eor {z1} -//FRAGMENT vbuxx=vbuc1_bxor_vbuz1 -lda #{c1} -eor {z1} -tax -//FRAGMENT vbuyy=vbuc1_bxor_vbuz1 -lda #{c1} -eor {z1} -tay -//FRAGMENT _deref_pbuc1_lt_vbuxx_then_la1 -lda {c1} -stx $ff -cmp $ff -bcc {la1} -//FRAGMENT _deref_pbuc1_lt_vbuyy_then_la1 -ldx {c1} -sty $ff -cpx $ff -bcc {la1} //FRAGMENT pwsz1_lt_pwsc1_then_la1 lda {z1}+1 cmp #>{c1} @@ -14497,6 +14581,17 @@ lda {z1} cmp #<{c1} bcc {la1} !: +//FRAGMENT vbsz1=vbsz2_minus_vbsaa +eor #$ff +sec +adc {z2} +sta {z1} +//FRAGMENT vbsz1=vbsxx_minus_vbsaa +sta $ff +txa +sec +sbc $ff +sta {z1} //FRAGMENT vbsaa=vbsz1_minus_vbsaa eor #$ff sec @@ -14506,848 +14601,27 @@ sta $ff txa sec sbc $ff -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_vbuz3 -lda {z3} -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT pbuz1=pbuc1_plus_pwuc2_derefidx_vbuz2 -ldy {z2} -clc -lda #<{c1} -adc {c2},y -sta {z1} -lda #>{c1} -adc {c2}+1,y -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1_ge_vbuc2_then_la1 -ldy {z1} -lda {c1},y -cmp #{c2} -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_lt_vbuc2_then_la1 -ldy {z1} -lda {c1},y -cmp #{c2} -bcc {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -sta {z1} -//FRAGMENT vbuz1=vbuz2_band_vbuz3 -lda {z2} -and {z3} -sta {z1} -//FRAGMENT vbuz1=vbuz1_band_vbuz2 -lda {z1} -and {z2} -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuz3 -ldy {z2} -lda {c1},y -ldy {z3} -clc -adc {c2},y -sta {z1} -//FRAGMENT pbuz1=qbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT pwuz1=pwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus__deref_pwuz3 -ldy #0 -clc -lda {z2} -adc ({z3}),y -sta {z1} -iny -lda {z2}+1 -adc ({z3}),y -sta {z1}+1 -//FRAGMENT vwuz1=pbuz2_derefidx_vbuc1_word__deref_pbuz2 -ldy #{c1} -lda ({z2}),y -sta {z1}+1 -ldy #0 -lda ({z2}),y -sta {z1} -//FRAGMENT pbuz1=pbuz1_plus_pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=pbuz2_derefidx_vbuz3_bor_pbuz4_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -ora ({z4}),y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_vbuz2 -lda {c1},x -clc -adc {z2} -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_vbuz2 -lda {c1},y -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_vbuz2 -lda {z2} -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_vbuz1 -lda {c1},x -clc -adc {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_vbuz1 -lda {c1},y -clc -adc {z1} -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_vbuz2 -lda {z2} -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_vbuz1 -lda {c1},x -clc +//FRAGMENT vbsxx=vbsz1_minus_vbsaa +eor #$ff +sec adc {z1} tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_vbuz1 -lda {c1},y -clc -adc {z1} -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_vbuz2 -lda {z2} -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_vbuz1 -lda {c1},x -clc -adc {z1} -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_vbuz1 -lda {c1},y -clc -adc {z1} -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_vbuaa -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_vbuaa -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_vbuaa -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_vbuaa -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_vbuaa -clc -adc {c1},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_vbuaa -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_vbuaa -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_vbuaa -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_vbuaa -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_vbuaa -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_vbuaa -clc -adc {c1},x -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_vbuaa -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_vbuxx -ldy {z2} -txa -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_vbuxx -txa -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_vbuxx -txa -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_vbuxx -ldy {z1} -txa -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_vbuxx -txa -clc -adc {c1},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_vbuxx -txa -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_vbuxx -txa -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_vbuxx -txa -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_vbuxx -txa -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_vbuxx -ldy {z1} -txa -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_vbuxx -txa -clc -adc {c1},x -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_vbuxx -txa -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_vbuyy -tya -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_vbuyy -tya -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_vbuyy -tya -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_vbuyy -tya -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_vbuyy -tya -clc -adc {c1},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_vbuyy -tya -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_vbuyy -ldx {z1} -tya -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_vbuyy -tya -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_vbuyy -tya -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_vbuyy -tya -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_vbuyy -tya -clc -adc {c1},x -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_vbuyy -tya -clc -adc {c1},y -tay -//FRAGMENT pbuz1=pbuc1_plus_pwuc2_derefidx_vbuaa -tay -clc -lda #<{c1} -adc {c2},y -sta {z1} -lda #>{c1} -adc {c2}+1,y -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_pwuc2_derefidx_vbuxx -txa -tay -clc -lda #<{c1} -adc {c2},y -sta {z1} -lda #>{c1} -adc {c2}+1,y -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_pwuc2_derefidx_vbuyy -clc -lda #<{c1} -adc {c2},y -sta {z1} -lda #>{c1} -adc {c2}+1,y -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuxx_ge_vbuc2_then_la1 -lda {c1},x -cmp #{c2} -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_ge_vbuc2_then_la1 -lda {c1},y -cmp #{c2} -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuxx_lt_vbuc2_then_la1 -lda {c1},x -cmp #{c2} -bcc {la1} -//FRAGMENT pbuc1_derefidx_vbuyy_lt_vbuc2_then_la1 -lda {c1},y -cmp #{c2} -bcc {la1} -//FRAGMENT vbuz1=vbuaa_band_vbuz2 -and {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_band_vbuz2 -lda {z2} -sax {z1} -//FRAGMENT vbuz1=vbuyy_band_vbuz2 -tya -and {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_band_vbuxx -lda {z2} -sax {z1} -//FRAGMENT vbuz1=vbuaa_band_vbuxx -sax {z1} -//FRAGMENT vbuz1=vbuz1_band_vbuxx -lda {z1} -sax {z1} -//FRAGMENT vbuz1=vbuz1_band_vbuyy -tya -and {z1} -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuyy=_byte_vwuz1 -lda {z1} -sta {c1},y -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz2 -lda {c1},x -ldy {z2} -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz2 -lda {c1},y -ldy {z2} -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c2},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c2},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c2},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldx {z1} -lda {c1},x -ldx {z2} -clc -adc {c2},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldx {z1} -clc -adc {c2},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldx {z1} -clc -adc {c2},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c2},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c2},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c2},y -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -tay -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -tay -//FRAGMENT vbuaa_eq_vbuz1_then_la1 -cmp {z1} -beq {la1} -//FRAGMENT pbuz1=qbuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT pbuz1=qbuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -//FRAGMENT pbuz1=qbuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuz1=vbuaa_plus_pbuc1_derefidx_vbuz2 -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuz1=vbuaa_plus_pbuc1_derefidx_vbuxx -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuz1=vbuaa_plus_pbuc1_derefidx_vbuyy -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_plus_pbuc1_derefidx_vbuz1 -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuaa=vbuaa_plus_pbuc1_derefidx_vbuxx -clc -adc {c1},x -//FRAGMENT vbuaa=vbuaa_plus_pbuc1_derefidx_vbuyy -clc -adc {c1},y -//FRAGMENT vbuxx=vbuaa_plus_pbuc1_derefidx_vbuz1 -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuxx=vbuaa_plus_pbuc1_derefidx_vbuxx -clc -adc {c1},x -tax -//FRAGMENT vbuxx=vbuaa_plus_pbuc1_derefidx_vbuyy -clc -adc {c1},y -tax -//FRAGMENT vbuyy=vbuaa_plus_pbuc1_derefidx_vbuz1 -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuyy=vbuaa_plus_pbuc1_derefidx_vbuxx -clc -adc {c1},x -tay -//FRAGMENT vbuyy=vbuaa_plus_pbuc1_derefidx_vbuyy -clc -adc {c1},y -tay -//FRAGMENT pbuz1=pbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1=pbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=pbuz2_derefidx_vbuaa_bor_pbuz3_derefidx_vbuaa -tay -lda ({z2}),y -ora ({z3}),y -sta {z1} -//FRAGMENT vbuz1=pbuz2_derefidx_vbuxx_bor_pbuz3_derefidx_vbuxx -txa -tay -lda ({z2}),y -ora ({z3}),y -sta {z1} -//FRAGMENT vbuz1=pbuz2_derefidx_vbuyy_bor_pbuz3_derefidx_vbuyy -lda ({z2}),y -ora ({z3}),y -sta {z1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuz2_bor_pbuz3_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -ora ({z3}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuaa_bor_pbuz2_derefidx_vbuaa -tay -lda ({z1}),y -ora ({z2}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuxx_bor_pbuz2_derefidx_vbuxx -txa -tay -lda ({z1}),y -ora ({z2}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuyy_bor_pbuz2_derefidx_vbuyy -lda ({z1}),y -ora ({z2}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuz2_bor_pbuz3_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -ora ({z3}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuaa_bor_pbuz2_derefidx_vbuaa -tay -lda ({z1}),y -ora ({z2}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuxx_bor_pbuz2_derefidx_vbuxx -txa -tay -lda ({z1}),y -ora ({z2}),y -tax -//FRAGMENT vbuxx=pbuz1_derefidx_vbuyy_bor_pbuz2_derefidx_vbuyy -lda ({z1}),y -ora ({z2}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuz2_bor_pbuz3_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -ora ({z3}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuaa_bor_pbuz2_derefidx_vbuaa -tay -lda ({z1}),y -ora ({z2}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuxx_bor_pbuz2_derefidx_vbuxx -txa -tay -lda ({z1}),y -ora ({z2}),y -tay -//FRAGMENT vbuyy=pbuz1_derefidx_vbuyy_bor_pbuz2_derefidx_vbuyy -lda ({z1}),y -ora ({z2}),y -tay -//FRAGMENT vbuxx=vbuyy_minus_1 -tya -tax -dex -//FRAGMENT vbuaa=vbuxx_minus_1 +//FRAGMENT vbsxx=vbsxx_minus_vbsaa +sta $ff txa sec -sbc #1 -//FRAGMENT vbuyy=vbuxx_minus_1 -txa -tay -dey -//FRAGMENT vbuaa=vbuyy_minus_1 -tya +sbc $ff +tax +//FRAGMENT vbsyy=vbsz1_minus_vbsaa +eor #$ff sec -sbc #1 -//FRAGMENT vbuaa=vbuz1_band_vbuz2 -lda {z1} -and {z2} -//FRAGMENT vbuxx=vbuz1_band_vbuz2 -lda {z1} -and {z2} -tax -//FRAGMENT vbuyy=vbuz1_band_vbuz2 -lda {z1} -and {z2} +adc {z1} tay -//FRAGMENT vbuaa=vbuaa_band_vbuz1 -and {z1} -//FRAGMENT vbuaa=vbuxx_band_vbuz1 +//FRAGMENT vbsyy=vbsxx_minus_vbsaa +sta $ff txa -and {z1} -//FRAGMENT vbuaa=vbuyy_band_vbuz1 -tya -and {z1} -//FRAGMENT vbuaa=vbuaa_band_vbuxx -stx $ff -and $ff -//FRAGMENT vbuaa=vbuaa_band_vbuyy -sty $ff -and $ff -//FRAGMENT pbuz1=pbuz2_plus__deref_pwuz1 -ldy #0 -clc -lda ({z1}),y -adc {z2} -pha -iny -lda ({z1}),y -adc {z2}+1 -sta {z1}+1 -pla -sta {z1} -//FRAGMENT pwuz1=pwuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuc1_bxor_vbuc2 -lda #{c2} -eor {c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bxor_vbuaa -eor #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bxor_vbuxx -txa -eor #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bxor_vbuyy -tya -eor #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuc1_bxor_vbuaa -eor #{c1} -//FRAGMENT vbuaa=vbuc1_bxor_vbuxx -txa -eor #{c1} -//FRAGMENT vbuaa=vbuc1_bxor_vbuyy -tya -eor #{c1} -//FRAGMENT vbuxx=vbuc1_bxor_vbuaa -eor #{c1} -tax -//FRAGMENT vbuxx=vbuc1_bxor_vbuxx -txa -eor #{c1} -tax -//FRAGMENT vbuxx=vbuc1_bxor_vbuyy -tya -eor #{c1} -tax -//FRAGMENT vbuyy=vbuc1_bxor_vbuaa -eor #{c1} -tay -//FRAGMENT vbuyy=vbuc1_bxor_vbuxx -txa -eor #{c1} -tay -//FRAGMENT vbuyy=vbuc1_bxor_vbuyy -tya -eor #{c1} -tay -//FRAGMENT vbuaa=_deref_pbuc1_bxor_vbuc2 -lda #{c2} -eor {c1} -//FRAGMENT vbuxx=_deref_pbuc1_bxor_vbuc2 -lda #{c2} -eor {c1} -tax -//FRAGMENT vbuyy=_deref_pbuc1_bxor_vbuc2 -lda #{c2} -eor {c1} +sec +sbc $ff tay //FRAGMENT vduz1_neq_vduc1_then_la1 lda {z1}+3 @@ -15393,25 +14667,6 @@ lda {z2} sta {z1} lda {z2}+1 sta {z1}+1 -//FRAGMENT vbuaa=vbuaa_plus_2 -clc -adc #2 -//FRAGMENT vbuz1_ge__deref_pbuc1_then_la1 -lda {c1} -ldy {z1} -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT vbuxx_ge__deref_pbuc1_then_la1 -ldy {c1} -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuyy_ge__deref_pbuc1_then_la1 -lda {c1} -sta $ff -cpy $ff -bcs {la1} //FRAGMENT vduz1=_deref_pduc1 lda {c1} sta {z1} @@ -15421,65 +14676,6 @@ lda {c1}+2 sta {z1}+2 lda {c1}+3 sta {z1}+3 -//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuz3 -ldy {z2} -lda {c1},y -sta {z1}+1 -lda {z3} -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuaa_word_vbuz2 -tay -lda {c1},y -sta {z1}+1 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_vbuz2 -lda {c1},x -sta {z1}+1 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuyy_word_vbuz2 -lda {c1},y -sta {z1}+1 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuaa -ldx {z2} -ldy {c1},x -sty {z1}+1 -sta {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuz2_word_vbuxx -ldy {z2} -lda {c1},y -sta {z1}+1 -stx {z1} -//FRAGMENT vwuz1=pbuc1_derefidx_vbuxx_word_vbuxx -lda {c1},x -sta {z1}+1 -stx {z1} -//FRAGMENT _deref_(_deref_qwuc1)=_deref_(_deref_qwuc2) -ldy {c2} -sty $fe -ldy {c2}+1 -sty $ff -ldy #0 -lda ($fe),y -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT vbuyy=vbuaa_band_pbuc1_derefidx_vbuyy -and {c1},y -tay -//FRAGMENT _deref_pbuc1_eq__deref_pbuc2_then_la1 -lda {c1} -cmp {c2} -beq {la1} -//FRAGMENT _deref_pbsc1=_deref_pbsc2 -lda {c2} -sta {c1} //FRAGMENT vwsz1_eq_vwsz2_then_la1 lda {z1} cmp {z2} @@ -15522,128 +14718,6 @@ bvc !+ eor #$80 !: bpl {la1} -//FRAGMENT vbuz1=_deref_pbuc1_plus_1 -ldy {c1} -iny -sty {z1} -//FRAGMENT vbuz1=_deref_pbuc1_minus_1 -ldx {c1} -dex -stx {z1} -//FRAGMENT vbuz1=_deref_pbuc1_plus_vbuc2 -lda #{c2} -clc -adc {c1} -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_minus_vbuc2 -lda {c1} -sec -sbc #{c2} -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1_plus_1 -lda {c1} -clc -adc #1 -//FRAGMENT vbuaa=_deref_pbuc1_minus_1 -lda {c1} -sec -sbc #1 -//FRAGMENT vbuaa=_deref_pbuc1_plus_vbuc2 -lda #{c2} -clc -adc {c1} -//FRAGMENT vbuxx=_deref_pbuc1_plus_vbuc2 -lda {c1} -tax -axs #-[{c2}] -//FRAGMENT vbuyy=_deref_pbuc1_plus_vbuc2 -lda #{c2} -clc -adc {c1} -tay -//FRAGMENT vbuaa=_deref_pbuc1_minus_vbuc2 -lda {c1} -sec -sbc #{c2} -//FRAGMENT vbuxx=_deref_pbuc1_minus_vbuc2 -lda {c1} -tax -axs #{c2} -//FRAGMENT vbuyy=_deref_pbuc1_minus_vbuc2 -lda {c1} -sec -sbc #{c2} -tay -//FRAGMENT vbuaa_ge_vbuxx_then_la1 -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuaa_ge_vbuyy_then_la1 -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx=_deref_pbuc1_plus_1 -ldx {c1} -inx -//FRAGMENT vbuyy=_deref_pbuc1_plus_1 -ldy {c1} -iny -//FRAGMENT vbuxx=_deref_pbuc1_minus_1 -ldx {c1} -dex -//FRAGMENT vbuyy=_deref_pbuc1_minus_1 -lda {c1} -tay -dey -//FRAGMENT vbsz1_neq_vbsz2_then_la1 -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT vbsz1_neq_vbsxx_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT vbsxx_neq_vbsz1_then_la1 -cpx {z1} -bne {la1} -//FRAGMENT _deref_pbuz1=vbum2 -lda {m2} -ldy #0 -sta ({z1}),y -//FRAGMENT pbuc1_derefidx_vbum1=vbuc2 -lda #{c2} -ldy {m1} -sta {c1},y -//FRAGMENT vbuz1=vbum2 -lda {m2} -sta {z1} -//FRAGMENT vbuaa=vbum1 -lda {m1} -//FRAGMENT vbuxx=vbum1 -ldx {m1} -//FRAGMENT vbuyy=vbum1 -ldy {m1} -//FRAGMENT qbuc1_derefidx_vbuz1=pbuc2 -ldy {z1} -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT qbuc1_derefidx_vbuaa=pbuc2 -tay -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT qbuc1_derefidx_vbuxx=pbuc2 -lda #<{c2} -sta {c1},x -lda #>{c2} -sta {c1}+1,x -//FRAGMENT qbuc1_derefidx_vbuyy=pbuc2 -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y //FRAGMENT vwuz1=vwuc1_plus_pbuc2_derefidx_vbuz2 ldy {z2} lda {c2},y @@ -15697,365 +14771,6 @@ sta {z1} //FRAGMENT vbuz1=vbuz1_bor_vbuaa ora {z1} sta {z1} -//FRAGMENT pbuz1_ge_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc !+ -bne {la1} -lda {z1} -cmp #<{c1} -bcs {la1} -!: -//FRAGMENT vbuz1=_deref_pbuc1_ror_1 -lda {c1} -lsr -sta {z1} -//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuz2_then_la1 -ldy {z2} -lda {c1}+1,y -cmp {z1}+1 -bne !+ -lda {c1},y -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_qbuc1=_inc__deref_qbuc1 -inc {c1} -bne !+ -inc {c1}+1 -!: -//FRAGMENT vbuaa=_deref_pbuc1_ror_1 -lda {c1} -lsr -//FRAGMENT vbuxx=_deref_pbuc1_ror_1 -lda {c1} -lsr -tax -//FRAGMENT vbuyy=_deref_pbuc1_ror_1 -lda {c1} -lsr -tay -//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuaa_then_la1 -tay -lda {c1}+1,y -cmp {z1}+1 -bne !+ -lda {c1},y -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuxx_then_la1 -lda {c1}+1,x -cmp {z1}+1 -bne !+ -lda {c1},x -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT vwuz1_ge_pwuc1_derefidx_vbuyy_then_la1 -lda {c1}+1,y -cmp {z1}+1 -bne !+ -lda {c1},y -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuaa -tay -lda {c2},y -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuxx -lda {c2},x -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=pbuc2_derefidx_vbuyy -lda {c2},y -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_pwuz1=vbuz2 -lda {z2} -ldy #0 -sta ({z1}),y -tya -iny -sta ({z1}),y -//FRAGMENT _deref_pwuz1=vbuaa -ldy #0 -sta ({z1}),y -tya -iny -sta ({z1}),y -//FRAGMENT _deref_pwuz1=vbuxx -txa -ldy #0 -sta ({z1}),y -tya -iny -sta ({z1}),y -//FRAGMENT _deref_pwuz1=vbuyy -tya -ldy #0 -sta ({z1}),y -tya -iny -sta ({z1}),y -//FRAGMENT vbsz1=vbsaa_rol_1 -asl -sta {z1} -//FRAGMENT vbsaa=vbsaa_rol_1 -asl -//FRAGMENT vbsxx=vbsaa_rol_1 -asl -tax -//FRAGMENT vbsyy=vbsaa_rol_1 -asl -tay -//FRAGMENT pwsz1=pwsc1_plus_vbuz2 -lda {z2} -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pwsc1_derefidx_vbuz1=_deref_pwsz2 -ldx {z1} -ldy #0 -lda ({z2}),y -sta {c1},x -iny -lda ({z2}),y -sta {c1}+1,x -//FRAGMENT pwsz1=pwsc1_plus_vbuaa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pwsz1=pwsc1_plus_vbuxx -txa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pwsz1=pwsc1_plus_vbuyy -tya -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pwsc1_derefidx_vbuaa=_deref_pwsz1 -tax -ldy #0 -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT pwsc1_derefidx_vbuxx=_deref_pwsz1 -ldy #0 -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT pwsc1_derefidx_vbuyy=_deref_pwsz1 -tya -tax -ldy #0 -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT vbuz1=_hi_pwuc1_derefidx_vbuyy -lda {c1}+1,y -sta {z1} -//FRAGMENT vbuaa=_hi_pwuc1_derefidx_vbuyy -lda {c1}+1,y -//FRAGMENT vbuxx=_hi_pwuc1_derefidx_vbuyy -lda {c1}+1,y -tax -//FRAGMENT vbuyy=_hi_pwuc1_derefidx_vbuyy -lda {c1}+1,y -tay -//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuz2 -ldy {z2} -lda {c1}+1,y -sta {z1} -//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuz1 -ldx {z1} -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -tay -//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuxx -lda {c1},x -sta {z1} -//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuxx -lda {c1},x -//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuxx -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuxx -lda {c1},x -tay -//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuyy -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuyy -lda {c1},y -//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuyy -lda {c1},y -tax -//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuyy -lda {c1},y -tay -//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuz1 -ldy {z1} -lda {c1}+1,y -//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuz1 -ldx {z1} -lda {c1}+1,x -tax -//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuz1 -ldy {z1} -lda {c1}+1,y -tay -//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuxx -lda {c1}+1,x -sta {z1} -//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuxx -lda {c1}+1,x -//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuxx -lda {c1}+1,x -tax -//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuxx -lda {c1}+1,x -tay -//FRAGMENT vbuz1=_hi_pwsc1_derefidx_vbuyy -lda {c1}+1,y -sta {z1} -//FRAGMENT vbuaa=_hi_pwsc1_derefidx_vbuyy -lda {c1}+1,y -//FRAGMENT vbuxx=_hi_pwsc1_derefidx_vbuyy -lda {c1}+1,y -tax -//FRAGMENT vbuyy=_hi_pwsc1_derefidx_vbuyy -lda {c1}+1,y -tay -//FRAGMENT vwuz1=vbuz2_band_vbuc1 -lda {z2} -and #{c1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vbuaa_band_vbuc1 -and #{c1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vbuxx_band_vbuc1 -txa -and #{c1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vbuyy_band_vbuc1 -tya -and #{c1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuc1_le_vwuc2_then_la1 -lda #>{c1} -cmp #>{c2} -bne !+ -lda #<{c1} -cmp #<{c2} -beq {la1} -!: -bcc {la1} -//FRAGMENT _deref_pboc1=vboc2 -lda #{c2} -sta {c1} -//FRAGMENT _deref_pboc1_then_la1 -lda {c1} -cmp #0 -bne {la1} -//FRAGMENT pbuz1_derefidx_vbuc1=_byte_vwuz2 -ldy #{c1} -lda {z2} -sta ({z1}),y -//FRAGMENT pssz1=pssc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pssz1=_deref_pssz2_memcpy_vbuc1 -ldy #00 -!: -lda ({z2}),y -sta ({z1}),y -iny -cpy #{c1} -bne !- -//FRAGMENT pssz1=pssc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuc2 -lda #{c2} -clc -adc {c1} -sta {c1} //FRAGMENT pssz1_lt_pssc1_then_la1 lda {z1}+1 cmp #>{c1} @@ -16065,60 +14780,6 @@ lda {z1} cmp #<{c1} bcc {la1} !: -//FRAGMENT vbuz1_lt__deref_pbuc1_then_la1 -lda {z1} -cmp {c1} -bcc {la1} -//FRAGMENT pwuc1_derefidx_vbuz1=(_deref_qwuc2)_derefidx_vbuz1 -ldy {z1} -lda {c2} -sta $fe -lda {c2}+1 -sta $ff -lda ($fe),y -sta {c1},y -iny -lda ($fe),y -sta {c1},y -//FRAGMENT vbuaa_lt__deref_pbuc1_then_la1 -cmp {c1} -bcc {la1} -//FRAGMENT pwuc1_derefidx_vbuaa=(_deref_qwuc2)_derefidx_vbuaa -tay -lda {c2} -sta $fe -lda {c2}+1 -sta $ff -lda ($fe),y -sta {c1},y -iny -lda ($fe),y -sta {c1},y -//FRAGMENT pwuc1_derefidx_vbuxx=(_deref_qwuc2)_derefidx_vbuxx -txa -tay -lda {c2} -sta $fe -lda {c2}+1 -sta $ff -lda ($fe),y -sta {c1},y -iny -lda ($fe),y -sta {c1},y -//FRAGMENT pwuc1_derefidx_vbuyy=(_deref_qwuc2)_derefidx_vbuyy -lda {c2} -sta $fe -lda {c2}+1 -sta $ff -lda ($fe),y -sta {c1},y -iny -lda ($fe),y -sta {c1},y -//FRAGMENT vbuxx_lt__deref_pbuc1_then_la1 -cpx {c1} -bcc {la1} //FRAGMENT (_deref_qbuc1)_derefidx_vbuc2=vbuc3 lda #{c3} ldy #{c2} @@ -16127,13 +14788,6 @@ stx $fe ldx {c1}+1 stx $ff sta ($fe),y -//FRAGMENT pssz1_neq_pssc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} //FRAGMENT vwuz1=(_deref_qwuc1)_derefidx_vbuc2 ldy #{c2} lda {c1} @@ -16145,585 +14799,30 @@ sta {z1} iny lda ($fe),y sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_(_deref_pbuz2) -ldy #0 -lda ({z2}),y -tay -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_(_deref_pbuz1) -ldy #0 -lda ({z1}),y -tay -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_(_deref_pbuz1) -tax -ldy #0 -lda ({z1}),y -tay -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_(_deref_pbuz1) -tya -tax -ldy #0 -lda ({z1}),y -tay -lda {c2},y -sta {c1},x -//FRAGMENT qssz1=qssc1_plus_vwsz2 -lda #<{c1} -clc -adc {z2} -sta {z1} -lda #>{c1} -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pssz1=_deref_qssz2 -ldy #0 -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT _deref_pbuz1=pbuz2_derefidx_vbuc1 -ldy #{c1} -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT qssz1=qssc1_plus_vwsz1 -lda #<{c1} -clc -adc {z1} -sta {z1} -lda #>{c1} -adc {z1}+1 -sta {z1}+1 -//FRAGMENT pssz1=_deref_qssz1 -ldy #0 -lda ({z1}),y -pha -iny -lda ({z1}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT vboz1=vboc1 -lda #{c1} -sta {z1} -//FRAGMENT vboaa=vboc1 -lda #{c1} -//FRAGMENT vboxx=vboc1 -lda #{c1} -tax -//FRAGMENT vboyy=vboc1 -lda #{c1} -tay -//FRAGMENT vbuxx_neq_vbuaa_then_la1 -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vbuyy_neq_vbuaa_then_la1 -tax -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vwuz1=_deref_pbuz2_word__deref_pbuz3 -ldy #0 -lda ({z3}),y -sta {z1} -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_minus_2 -lda {z2} -sec -sbc #2 -sta {z1} -//FRAGMENT vbuxx=vbuz1_minus_2 -ldx {z1} -dex -dex -//FRAGMENT vbuz1=_deref_pbuc1_plus_2 -lda {c1} -clc -adc #2 -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1_plus_2 -lda {c1} -clc -adc #2 -//FRAGMENT vbuxx=_deref_pbuc1_plus_2 -ldx {c1} -inx -inx -//FRAGMENT vbuyy=_deref_pbuc1_plus_2 -ldy {c1} -iny -iny -//FRAGMENT 0_neq_vwuz1_then_la1 -lda {z1} -ora {z1}+1 -bne {la1} -//FRAGMENT _deref_pbuz1=_byte_vwsz2 -lda {z2} -ldy #0 -sta ({z1}),y -//FRAGMENT vwuz1=vwuz2_rol_6 -lda {z2}+1 -lsr -sta $ff -lda {z2} -ror -sta {z1}+1 -lda #0 -ror -sta {z1} -lsr $ff -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vwuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda #0 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vwsz1_lt_vwuz2_then_la1 +//FRAGMENT pbuz1_neq_vwuc1_then_la1 lda {z1}+1 -bmi {la1} -cmp {z2}+1 -bcc {la1} -bne !+ +cmp #>{c1} +bne {la1} lda {z1} -cmp {z2} -bcc {la1} -!: -//FRAGMENT vduz1=pduz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -iny -lda ({z2}),y -sta {z1}+2 -iny -lda ({z2}),y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_pduc1_derefidx_vbuz3 -ldy {z3} -lda {z2} -clc -adc {c1},y -sta {z1} -lda {z2}+1 -adc {c1}+1,y -sta {z1}+1 -lda {z2}+2 -adc {c1}+2,y -sta {z1}+2 -lda {z2}+3 -adc {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_pduz3_derefidx_vbuz4 -ldy {z4} -lda {z2} -clc -adc ({z3}),y -sta {z1} -iny -lda {z2}+1 -adc ({z3}),y -sta {z1}+1 -iny -lda {z2}+2 -adc ({z3}),y -sta {z1}+2 -iny -lda {z2}+3 -adc ({z3}),y -sta {z1}+3 -//FRAGMENT vduz1=_bnot_vduz2 -lda {z2} -eor #$ff -sta {z1} -lda {z2}+1 -eor #$ff -sta {z1}+1 -lda {z2}+2 -eor #$ff -sta {z1}+2 -lda {z2}+3 -eor #$ff -sta {z1}+3 -//FRAGMENT vduz1=vduz2_bor_vduz3 +cmp #<{c1} +bne {la1} +//FRAGMENT vbuyy=vbuaa_band_pbuc1_derefidx_vbuz1 +ldy {z1} +and {c1},y +tay +//FRAGMENT vbuyy=_lo_pbuz1 +ldy {z1} +//FRAGMENT vbuz1=vbuz2_bor__lo_pbuz3 lda {z2} ora {z3} sta {z1} -lda {z2}+1 -ora {z3}+1 -sta {z1}+1 -lda {z2}+2 -ora {z3}+2 -sta {z1}+2 -lda {z2}+3 -ora {z3}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_bxor_vduz3 -lda {z2} -eor {z3} -sta {z1} -lda {z2}+1 -eor {z3}+1 -sta {z1}+1 -lda {z2}+2 -eor {z3}+2 -sta {z1}+2 -lda {z2}+3 -eor {z3}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_band_vduz3 -lda {z2} -and {z3} -sta {z1} -lda {z2}+1 -and {z3}+1 -sta {z1}+1 -lda {z2}+2 -and {z3}+2 -sta {z1}+2 -lda {z2}+3 -and {z3}+3 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_minus_vwuz2 -sec -lda #<{c1} -sbc {z2} -sta {z1} -lda #>{c1} -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT vduz1=pduz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -iny -lda ({z2}),y -sta {z1}+2 -iny -lda ({z2}),y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_pduc1_derefidx_vbuxx -lda {z2} -clc -adc {c1},x -sta {z1} -lda {z2}+1 -adc {c1}+1,x -sta {z1}+1 -lda {z2}+2 -adc {c1}+2,x -sta {z1}+2 -lda {z2}+3 -adc {c1}+3,x -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_pduz3_derefidx_vbuxx -txa -tay -lda {z2} -clc -adc ({z3}),y -sta {z1} -iny -lda {z2}+1 -adc ({z3}),y -sta {z1}+1 -iny -lda {z2}+2 -adc ({z3}),y -sta {z1}+2 -iny -lda {z2}+3 -adc ({z3}),y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_bxor_vduz1 -lda {z1} -eor {z2} -sta {z1} -lda {z1}+1 -eor {z2}+1 -sta {z1}+1 -lda {z1}+2 -eor {z2}+2 -sta {z1}+2 -lda {z1}+3 -eor {z2}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_bxor_vduz2 -lda {z1} -eor {z2} -sta {z1} -lda {z1}+1 -eor {z2}+1 -sta {z1}+1 -lda {z1}+2 -eor {z2}+2 -sta {z1}+2 -lda {z1}+3 -eor {z2}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_bor_vduz2 -lda {z2} -ora {z1} -sta {z1} -lda {z2}+1 -ora {z1}+1 -sta {z1}+1 -lda {z2}+2 -ora {z1}+2 -sta {z1}+2 -lda {z2}+3 -ora {z1}+3 -sta {z1}+3 -//FRAGMENT vbuz1=vbuz1_rol_2 -lda {z1} -asl -asl -sta {z1} -//FRAGMENT vwuz1=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_6 -lda {z1}+1 -lsr -sta $ff -lda {z1} -ror -sta {z1}+1 -lda #0 -ror -sta {z1} -lsr $ff -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz1_plus_pduz2_derefidx_vbuz3 -ldy {z3} -lda {z1} -clc -adc ({z2}),y -sta {z1} -iny -lda {z1}+1 -adc ({z2}),y -sta {z1}+1 -iny -lda {z1}+2 -adc ({z2}),y -sta {z1}+2 -iny -lda {z1}+3 -adc ({z2}),y -sta {z1}+3 -//FRAGMENT vduz1=vduz1_band_vduz2 -lda {z1} -and {z2} -sta {z1} -lda {z1}+1 -and {z2}+1 -sta {z1}+1 -lda {z1}+2 -and {z2}+2 -sta {z1}+2 -lda {z1}+3 -and {z2}+3 -sta {z1}+3 -//FRAGMENT pbuz1=pbuc1_minus_vwuz1 -sec -lda #<{c1} -sbc {z1} -sta {z1} -lda #>{c1} -sbc {z1}+1 -sta {z1}+1 -//FRAGMENT vduz1=vduz1_plus_pduc1_derefidx_vbuz2 -ldy {z2} -lda {z1} -clc -adc {c1},y -sta {z1} -lda {z1}+1 -adc {c1}+1,y -sta {z1}+1 -lda {z1}+2 -adc {c1}+2,y -sta {z1}+2 -lda {z1}+3 -adc {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_bor_vduz1 -lda {z2} -ora {z1} -sta {z1} -lda {z2}+1 -ora {z1}+1 -sta {z1}+1 -lda {z2}+2 -ora {z1}+2 -sta {z1}+2 -lda {z2}+3 -ora {z1}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vduz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc {z2}+2 -sta {z1}+2 -lda {z1}+3 -adc {z2}+3 -sta {z1}+3 -//FRAGMENT vbuz1=vbuxx_band_pbuz2_derefidx_vbuc1 -ldy #{c1} -txa -and ({z2}),y -sta {z1} -//FRAGMENT vbuaa=vbuxx_band_pbuz1_derefidx_vbuc1 -ldy #{c1} -txa -and ({z1}),y -//FRAGMENT vbuxx=vbuxx_band_pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -axs #0 -//FRAGMENT vbuyy=vbuxx_band_pbuz1_derefidx_vbuc1 -ldy #{c1} -txa -and ({z1}),y -tay -//FRAGMENT _deref_pbuc1_eq_vbuc2_then_la1 -lda #{c2} -cmp {c1} -beq {la1} -//FRAGMENT vbsz1=vbsz2_ror_1 -lda {z2} -cmp #$80 -ror -sta {z1} -//FRAGMENT vbsaa=vbsz1_ror_1 -lda {z1} -cmp #$80 -ror -//FRAGMENT vbsxx=vbsz1_ror_1 -lda {z1} -cmp #$80 -ror -tax -//FRAGMENT vbsyy=vbsz1_ror_1 -lda {z1} -cmp #$80 -ror -tay -//FRAGMENT vbsz1=vbsaa_ror_1 -cmp #$80 -ror -sta {z1} -//FRAGMENT vbsaa=vbsaa_ror_1 -cmp #$80 -ror -//FRAGMENT vbsxx=vbsaa_ror_1 -cmp #$80 -ror -tax -//FRAGMENT vbsyy=vbsaa_ror_1 -cmp #$80 -ror -tay -//FRAGMENT vbsz1=vbsxx_ror_1 -txa -cmp #$80 -ror -sta {z1} -//FRAGMENT vbsaa=vbsxx_ror_1 -txa -cmp #$80 -ror -//FRAGMENT vbsxx=vbsxx_ror_1 -txa -cmp #$80 -ror -tax -//FRAGMENT vbsyy=vbsxx_ror_1 -txa -cmp #$80 -ror -tay -//FRAGMENT vbsz1=vbsyy_ror_1 -tya -cmp #$80 -ror -sta {z1} -//FRAGMENT vbsaa=vbsyy_ror_1 -tya -cmp #$80 -ror -//FRAGMENT vbsxx=vbsyy_ror_1 -tya -cmp #$80 -ror -tax -//FRAGMENT vbsyy=vbsyy_ror_1 -tya -cmp #$80 -ror -tay //FRAGMENT vbsaa=pbsc1_derefidx_vbuxx lda {c1},x //FRAGMENT vbsaa=pbsc1_derefidx_vbuyy lda {c1},y -//FRAGMENT vbuxx=vbuaa_band_vbuz1 -ldx {z1} -axs #0 -//FRAGMENT vbuxx=vbuxx_band_vbuz1 -lda {z1} -axs #0 -//FRAGMENT vbuxx=vbuyy_band_vbuz1 -ldx {z1} -tya -axs #0 -//FRAGMENT vbuyy=vbuaa_band_vbuz1 -and {z1} -tay -//FRAGMENT vbuyy=vbuxx_band_vbuz1 -txa -and {z1} -tay -//FRAGMENT vbuyy=vbuyy_band_vbuz1 -tya -and {z1} -tay +//FRAGMENT vbsyy_lt_0_then_la1 +cpy #0 +bmi {la1} //FRAGMENT vdsz1=vdsz2_rol_4 lda {z2} sta {z1} @@ -16860,251 +14959,14 @@ lda {c1},y sta {z1} lda #0 sta {z1}+1 -//FRAGMENT pbuz1_ge_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc !+ -bne {la1} -lda {z1} -cmp #<{c1} -bcs {la1} -!: -//FRAGMENT pbuc1_derefidx_vbuz1=vbum2 -lda {m2} +//FRAGMENT vbuaa=vbuxx_band_pbuc1_derefidx_vbuz1 ldy {z1} -sta {c1},y -//FRAGMENT vbum1=vbum1_plus_vbuz2 -lda {m1} -clc -adc {z2} -sta {m1} -//FRAGMENT pbuc1_derefidx_vbuaa=vbum1 -tay -lda {m1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbum1 -lda {m1} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbum1 -lda {m1} -sta {c1},y -//FRAGMENT vbum1=vbum1_plus_vbuxx txa -clc -adc {m1} -sta {m1} -//FRAGMENT vbum1=vbum1_plus_vbuyy +and {c1},y +//FRAGMENT vbuaa=vbuyy_band_pbuc1_derefidx_vbuz1 tya -clc -adc {m1} -sta {m1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuz1 -lda {c1} -clc -adc {z1} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuxx -txa -clc -adc {c1} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_plus_vbuyy -tya -clc -adc {c1} -sta {c1} -//FRAGMENT pbum1=pbum1_plus_vbuc1 -lda #{c1} -clc -adc {m1} -sta {m1} -bcc !+ -inc {m1}+1 -!: -//FRAGMENT vwsz1=vwsz1_plus_vbsz2 -lda {z2} -pha -clc -adc {z1} -sta {z1} -pla -ora #$7f -bmi !+ -lda #0 -!: -adc {z1}+1 -sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_plus_vbsaa -pha -clc -adc {z1} -sta {z1} -pla -ora #$7f -bmi !+ -lda #0 -!: -adc {z1}+1 -sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_plus_vbsxx -txa -pha -clc -adc {z1} -sta {z1} -pla -ora #$7f -bmi !+ -lda #0 -!: -adc {z1}+1 -sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_plus_vbsyy -tya -pha -clc -adc {z1} -sta {z1} -pla -ora #$7f -bmi !+ -lda #0 -!: -adc {z1}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_sethi_vbuz2 -lda {z2} -sta {z1}+1 -lda #<{c1} -sta {z1} -//FRAGMENT pbuz1=pbuz2_setlo_vbuz3 -lda {z3} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuc1_sethi_vbuz2 -lda {z2} -sta {z1}+1 -lda #<{c1} -sta {z1} -//FRAGMENT vwuz1=vwuz2_setlo_vbuz3 -lda {z3} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuz2_bor_pbuc1_derefidx_vbuz3 -ldy #0 -lda ({z2}),y -ldy {z3} -ora {c1},y -sta {z1} -//FRAGMENT pbuz1=pbuc1_sethi_vbuaa -sta {z1}+1 -lda #<{c1} -sta {z1} -//FRAGMENT pbuz1=pbuc1_sethi_vbuxx -stx {z1}+1 -ldx #<{c1} -stx {z1} -//FRAGMENT pbuz1=pbuz2_setlo_vbuaa -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_setlo_vbuxx -stx {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_setlo_vbuyy -sty {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuc1_sethi_vbuaa -sta {z1}+1 -lda #<{c1} -sta {z1} -//FRAGMENT vwuz1=vwuc1_sethi_vbuxx -stx {z1}+1 -ldx #<{c1} -stx {z1} -//FRAGMENT vwuz1=vwuz2_setlo_vbuaa -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_setlo_vbuxx -stx {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_setlo_vbuyy -sty {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuz2_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -ora ({z2}),y -sta {z1} -//FRAGMENT vbuz1=_deref_pbuz2_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -ora ({z2}),y -sta {z1} -//FRAGMENT vbuaa=_deref_pbuz1_bor_pbuc1_derefidx_vbuz2 -ldy #0 -lda ({z1}),y -ldy {z2} -ora {c1},y -//FRAGMENT vbuaa=_deref_pbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -ora ({z1}),y -//FRAGMENT vbuaa=_deref_pbuz1_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -ora ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1_bor_pbuc1_derefidx_vbuz2 -ldx {z2} -lda {c1},x -ldy #0 -ora ({z1}),y -tax -//FRAGMENT vbuxx=_deref_pbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -ora ({z1}),y -tax -//FRAGMENT vbuxx=_deref_pbuz1_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -ora ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1_bor_pbuc1_derefidx_vbuz2 -ldy #0 -lda ({z1}),y -ldy {z2} -ora {c1},y -tay -//FRAGMENT vbuyy=_deref_pbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -ora ({z1}),y -tay -//FRAGMENT vbuyy=_deref_pbuz1_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -ora ({z1}),y -tay -//FRAGMENT pbuz1=pbuc1_sethi_vbuyy -sty {z1}+1 -ldy #<{c1} -sty {z1} -//FRAGMENT vwuz1=vwuc1_sethi_vbuyy -sty {z1}+1 -ldy #<{c1} -sty {z1} -//FRAGMENT pbuz1=pbuz1_setlo_vbuaa -sta {z1} -//FRAGMENT vwuz1=vwuz1_setlo_vbuaa -sta {z1} +ldy {z1} +and {c1},y //FRAGMENT vdsz1_lt_0_then_la1 lda {z1}+3 bmi {la1} @@ -17126,71 +14988,6 @@ lda {z1}+3 eor #$ff adc #$0 sta {z1}+3 -//FRAGMENT pwsc1_derefidx_vbuz1_ge_vwsz2_then_la1 -ldy {z1} -lda {c1},y -cmp {z2} -lda {c1}+1,y -sbc {z2}+1 -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT vbuz1=_lo_pwsc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=_lo_pwsc1_derefidx_vbuaa -tay -lda {c1},y -//FRAGMENT vbuxx=_lo_pwsc1_derefidx_vbuaa -tax -lda {c1},x -tax -//FRAGMENT vbuyy=_lo_pwsc1_derefidx_vbuaa -tay -lda {c1},y -tay -//FRAGMENT pwsc1_derefidx_vbuaa_ge_vwsz1_then_la1 -tay -lda {c1},y -cmp {z1} -lda {c1}+1,y -sbc {z1}+1 -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT pwsc1_derefidx_vbuxx_ge_vwsz1_then_la1 -lda {c1},x -cmp {z1} -lda {c1}+1,x -sbc {z1}+1 -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT pwsc1_derefidx_vbuyy_ge_vwsz1_then_la1 -lda {c1},y -cmp {z1} -lda {c1}+1,y -sbc {z1}+1 -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT pbuz1_derefidx_vbuz2=vbuz2 -lda {z2} -tay -sta ({z1}),y -//FRAGMENT pbuz1=pbuz2_minus_vbuc1 -sec -lda {z2} -sbc #{c1} -sta {z1} -lda {z2}+1 -sbc #0 -sta {z1}+1 //FRAGMENT _deref_qssz1=pssz2 ldy #0 lda {z2} @@ -17345,9 +15142,6 @@ tya sec sbc {c1} tay -//FRAGMENT vbsyy_neq_vbsc1_then_la1 -cpy #{c1} -bne {la1} //FRAGMENT vbsxx_le_0_then_la1 cpx #1 bmi {la1} @@ -17375,528 +15169,6 @@ lda {z1} ldy {z2} ora {c1},y sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc1_derefidx_vbuz3 -ldy {z2} -lda {c1},y -ldy {z3} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuz1 -txa -ldx {z1} -ora {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -ora {c1},y -tay -//FRAGMENT vbuz1=vbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ora {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuxx -txa -ora {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuxx -tya -ora {c1},x -tay -//FRAGMENT vbuz1=vbuz1_bor_pbuc1_derefidx_vbuyy -lda {c1},y -ora {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuyy -txa -ora {c1},y -tax -//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuyy -tya -ora {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuz2 -tay -lda {c1},y -ldy {z2} -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuz1 -tay -lda {c1},y -ldy {z1} -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuz1 -tax -lda {c1},x -ldx {z1} -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuz1 -tay -lda {c1},y -ldy {z1} -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuxx -tay -lda {c1},y -clc -adc {c2},x -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuxx -tay -lda {c1},y -clc -adc {c2},x -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuxx -tay -lda {c1},y -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuxx -tay -lda {c1},y -clc -adc {c2},x -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c2},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c2},y -tay -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuz2 -ldx {z1} -lda {c1},x -ldx {z2} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuz2 -tay -lda {c1},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuz1 -tay -lda {c1},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuz1 -tax -lda {c1},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuz1 -tay -lda {c1},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuz2 -lda {c1},x -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuz1 -lda {c1},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuz2 -lda {c1},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuz1 -lda {c1},y -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuaa -tay -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc1_derefidx_vbuxx -lda {c1},x -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuxx -lda {c1},x -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuxx -tay -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuxx -tay -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuxx -tay -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuxx -tay -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},x -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},x -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},x -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuxx -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc1_derefidx_vbuyy -lda {c1},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc1_derefidx_vbuyy -lda {c1},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc1_derefidx_vbuyy -tax -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuyy -lda {c1},x -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuyy -lda {c1},x -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuyy -lda {c1},x -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc1_derefidx_vbuyy -lda {c1},x -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {c1},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc1_derefidx_vbuyy -lda {c1},y -clc -adc {c1},y -tay -//FRAGMENT vbuaa_le_vbuxx_then_la1 -tay -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuz2 -ldy {z2} -lda {c1},y -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c1},y -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 -ldx {z1} -lda {c1},x -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c1},y -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa -tax -lda {c1},x -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa -tay -lda {c1},y -clc -adc {c2},y -tay //FRAGMENT vbuz1=pbuz2_derefidx_(pbuz3_derefidx_vbuz4)_plus_pbuz5_derefidx_(pbuz6_derefidx_vbuz4) ldy {z4} lda ({z6}),y @@ -17913,16 +15185,50 @@ tay lda {c1},y ora {z1} sta {z1} +//FRAGMENT vbuz1=vbuz1_bor_pbuc1_derefidx_vbuxx +lda {c1},x +ora {z1} +sta {z1} +//FRAGMENT vbuz1=vbuz1_bor_pbuc1_derefidx_vbuyy +lda {c1},y +ora {z1} +sta {z1} +//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuz1 +txa +ldx {z1} +ora {c1},x +tax //FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuaa tay txa ora {c1},y tax +//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuxx +txa +ora {c1},x +tax +//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuyy +txa +ora {c1},y +tax +//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuz1 +tya +ldy {z1} +ora {c1},y +tay //FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuaa tax tya ora {c1},x tay +//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuxx +tya +ora {c1},x +tay +//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuyy +tya +ora {c1},y +tay //FRAGMENT vbuaa=pbuz1_derefidx_(pbuz2_derefidx_vbuz3)_plus_pbuz4_derefidx_(pbuz5_derefidx_vbuz3) ldy {z3} lda ({z5}),y @@ -18084,45 +15390,6 @@ ldy $ff clc adc ({z3}),y tay -//FRAGMENT _deref_pbuc1=_deref_(_deref_qbuc2) -ldy {c2} -sty $fe -ldy {c2}+1 -sty $ff -ldy #0 -lda ($fe),y -sta {c1} -//FRAGMENT _deref_pwsz1=vwsc1 -ldy #0 -lda #<{c1} -sta ({z1}),y -iny -lda #>{c1} -sta ({z1}),y -//FRAGMENT vwsz1=_deref_pwsz2_band_vwsc1 -ldy #0 -lda ({z2}),y -and #<{c1} -sta {z1} -iny -lda ({z2}),y -and #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=_hi__deref_pwsz2 -ldy #1 -lda ({z2}),y -sta {z1} -//FRAGMENT vbuaa=_hi__deref_pwsz1 -ldy #1 -lda ({z1}),y -//FRAGMENT vbuxx=_hi__deref_pwsz1 -ldy #1 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_hi__deref_pwsz1 -ldy #1 -lda ({z1}),y -tay //FRAGMENT pwsc1_derefidx_vbuz1=pwsc1_derefidx_vbuz1_minus_vbuz2 ldx {z1} sec @@ -18241,360 +15508,6 @@ lda {c1}+1,y sbc #$01 sta {c1}+1,y !: -//FRAGMENT pwuc1_derefidx_vbuaa=vbuc2 -tay -lda #{c2} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT _deref_pwuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -tya -iny -sta ({z1}),y -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuz3 -ldx {z2} -ldy {z3} -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuaa=vbuz1_plus_2 -lda {z1} -clc -adc #2 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuz2 -ldy {z2} -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuz2 -ldx {z2} -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuaa -ldx {z2} -tay -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuaa -tay -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuaa -tax -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuxx -ldy {z2} -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuxx -txa -tay -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuxx -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2_plus_pwuc1_derefidx_vbuyy -ldx {z2} -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx_plus_pwuc1_derefidx_vbuyy -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy_plus_pwuc1_derefidx_vbuyy -tya -tax -clc -lda {c1},x -adc {c1},y -sta {z1} -lda {c1}+1,x -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuz1=vbuyy_plus_2 -iny -iny -sty {z1} -//FRAGMENT vbuz1=_deref_pbuz2_plus__deref_pbuz3 -ldy #0 -lda ({z2}),y -clc -ldy #0 -adc ({z3}),y -sta {z1} -//FRAGMENT vbuaa=_deref_pbuz1_plus__deref_pbuz2 -ldy #0 -lda ({z1}),y -clc -ldy #0 -adc ({z2}),y -//FRAGMENT vbuxx=_deref_pbuz1_plus__deref_pbuz2 -ldy #0 -lda ({z1}),y -clc -ldy #0 -adc ({z2}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1_plus__deref_pbuz2 -ldy #0 -lda ({z1}),y -clc -ldy #0 -adc ({z2}),y -tay -//FRAGMENT vwuz1=_deref_pwuz2_plus__deref_pwuz1 -ldy #0 -clc -lda ({z1}),y -adc ({z2}),y -pha -iny -lda ({z1}),y -adc ({z2}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c1},y -clc -adc {c2},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_plus_vbuc2 -lda #{c2} -ldy {z1} -clc -adc {c1},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc1_derefidx_vbuaa_plus_pbuc2_derefidx_vbuaa -tax -tay -lda {c1},x -clc -adc {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_plus_vbuc2 -lda #{c2} -clc -adc {c1},x -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_plus_vbuc2 -lda #{c2} -clc -adc {c1},y -sta {c1},y -//FRAGMENT _deref_pbuz1=_deref_pbuz1_plus_pbuz1_derefidx_vbuc1 -ldy #0 -lda ({z1}),y -ldy #{c1} -clc -adc ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1_derefidx_vbuc1=pbuz1_derefidx_vbuc1_plus_vbuc2 -lda #{c2} -ldy #{c1} -clc -adc ({z1}),y -sta ({z1}),y -//FRAGMENT vbuz1=_deref_pbuz2_ror_4 -ldy #0 -lda ({z2}),y -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=_deref_pbuz1_ror_4 -ldy #0 -lda ({z1}),y -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=_deref_pbuz1_ror_4 -ldy #0 -lda ({z1}),y -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=_deref_pbuz1_ror_4 -ldy #0 -lda ({z1}),y -lsr -lsr -lsr -lsr -tay -//FRAGMENT pwuc1_derefidx_vbuz1=pwuc1_derefidx_vbuz1_plus_vwuc2 -ldy {z1} -clc -lda {c1},y -adc #<{c2} -sta {c1},y -lda {c1}+1,y -adc #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=pwuc1_derefidx_vbuaa_plus_vwuc2 -tay -clc -lda {c1},y -adc #<{c2} -sta {c1},y -lda {c1}+1,y -adc #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=pwuc1_derefidx_vbuxx_plus_vwuc2 -clc -lda {c1},x -adc #<{c2} -sta {c1},x -lda {c1}+1,x -adc #>{c2} -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=pwuc1_derefidx_vbuyy_plus_vwuc2 -clc -lda {c1},y -adc #<{c2} -sta {c1},y -lda {c1}+1,y -adc #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=vbuz2 -lda {z2} -ldy {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=vbuz1 -tay -lda {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vbuz1 -lda {z1} -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vbuz1 -lda {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=vbuxx -ldy {z1} -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=vbuxx -tay -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vbuxx -txa -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vbuxx -txa -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuz1=vbuyy -tya -ldy {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuaa=vbuyy -tax -tya -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuxx=vbuyy -tya -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vbuyy -tya -sta {c1},y -lda #0 -sta {c1}+1,y //FRAGMENT vwsz1=_deref_pwsz2_minus__deref_pwsz3 ldy #0 sec @@ -18605,76 +15518,6 @@ iny lda ({z2}),y sbc ({z3}),y sta {z1}+1 -//FRAGMENT vduz1=vduz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT _deref_(_deref_qbuc1)=vbuc2 -lda #{c2} -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT vbsz1_le_vbsc1_then_la1 -lda #{c1} -sec -sbc {z1} -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT vbsaa_le_vbsc1_then_la1 -sec -sbc #{c1} -beq {la1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vbsxx_le_vbsc1_then_la1 -txa -sec -sbc #{c1} -beq {la1} -bvc !+ -eor #$80 -!: -bmi {la1} -//FRAGMENT vbsyy_le_vbsc1_then_la1 -tya -sec -sbc #{c1} -beq {la1} -bvc !+ -eor #$80 -!: -bmi {la1} //FRAGMENT vwsz1=vbsz2_plus_vwsc1 lda {z2} tax @@ -18726,19 +15569,6 @@ lda #0 !: adc #>{c1} sta {z1}+1 -//FRAGMENT vbuaa_gt_vbuz1_then_la1 -cmp {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT pbuz1=_dec_pbuz2 -lda {z2} -sec -sbc #1 -sta {z1} -lda {z2}+1 -sbc #0 -sta {z1}+1 //FRAGMENT vduz1_eq_vduz2_then_la1 lda {z1} cmp {z2} @@ -18813,36 +15643,21 @@ bne !+ dec {z1}+1 !: dec {z1} -//FRAGMENT _deref_pwuc1=vbuz1 -lda {z1} -sta {c1} -lda #0 -sta {c1}+1 -//FRAGMENT _deref_pwuc1=vbuaa -sta {c1} -lda #0 -sta {c1}+1 -//FRAGMENT _deref_pwuc1=vbuxx +//FRAGMENT pbuz1=pbuz1_plus_vbuz2 +lda {z2} +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 +!: +//FRAGMENT pbuz1=pbuz1_plus_vbuxx txa -sta {c1} -lda #0 -sta {c1}+1 -//FRAGMENT _deref_pwuc1=vbuyy -tya -sta {c1} -lda #0 -sta {c1}+1 -//FRAGMENT vwsz1_lt_vbsc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vwsz1_lt_vwuc1_then_la1 -lda {z1}+1 -bmi {la1} -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} +clc +adc {z1} +sta {z1} +bcc !+ +inc {z1}+1 !: //FRAGMENT vwsz1=pwsc1_derefidx_vbuz2_minus_pwsc2_derefidx_vbuz2 ldy {z2} @@ -18944,206 +15759,6 @@ sta {c1},x //FRAGMENT pbsc1_derefidx_vbuyy=vbsc2 lda #{c2} sta {c1},y -//FRAGMENT _deref_pwuc1=_deref_pwuc1_plus_vwuc2 -lda #<{c2} -clc -adc {c1} -sta {c1} -lda #>{c2} -adc {c1}+1 -sta {c1}+1 -//FRAGMENT vbuz1=vbuz2_plus__deref_pbuc1 -lda {c1} -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus__deref_pbuc1 -lda {c1} -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus__deref_pbuc1 -lda {c1} -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus__deref_pbuc1 -lda {c1} -clc -adc {z1} -tay -//FRAGMENT vbuz1=vbuaa_plus__deref_pbuc1 -clc -adc {c1} -sta {z1} -//FRAGMENT vbuaa=vbuaa_plus__deref_pbuc1 -clc -adc {c1} -//FRAGMENT vbuxx=vbuaa_plus__deref_pbuc1 -clc -adc {c1} -tax -//FRAGMENT vbuyy=vbuaa_plus__deref_pbuc1 -clc -adc {c1} -tay -//FRAGMENT vbuz1=vbuxx_plus__deref_pbuc1 -txa -clc -adc {c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_plus__deref_pbuc1 -txa -clc -adc {c1} -//FRAGMENT vbuxx=vbuxx_plus__deref_pbuc1 -txa -clc -adc {c1} -tax -//FRAGMENT vbuyy=vbuxx_plus__deref_pbuc1 -txa -clc -adc {c1} -tay -//FRAGMENT vbuz1=vbuyy_plus__deref_pbuc1 -tya -clc -adc {c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_plus__deref_pbuc1 -tya -clc -adc {c1} -//FRAGMENT vbuxx=vbuyy_plus__deref_pbuc1 -tya -clc -adc {c1} -tax -//FRAGMENT vbuyy=vbuyy_plus__deref_pbuc1 -tya -clc -adc {c1} -tay -//FRAGMENT vbuz1=vbuz1_minus_1 -dec {z1} -//FRAGMENT vbuxx=vbuxx_minus_1 -dex -//FRAGMENT vbuyy=vbuyy_minus_1 -tya -tay -dey -//FRAGMENT vwsz1=pwsc1_derefidx_vbuz2_plus__deref_pwsz3 -ldx {z2} -clc -ldy #0 -lda {c1},x -adc ({z3}),y -sta {z1} -iny -lda {c1}+1,x -adc ({z3}),y -sta {z1}+1 -//FRAGMENT vwsz1=pwsc1_derefidx_vbuaa_plus__deref_pwsz2 -tax -clc -ldy #0 -lda {c1},x -adc ({z2}),y -sta {z1} -iny -lda {c1}+1,x -adc ({z2}),y -sta {z1}+1 -//FRAGMENT vwsz1=pwsc1_derefidx_vbuxx_plus__deref_pwsz2 -clc -ldy #0 -lda {c1},x -adc ({z2}),y -sta {z1} -iny -lda {c1}+1,x -adc ({z2}),y -sta {z1}+1 -//FRAGMENT vwsz1=pwsc1_derefidx_vbuyy_plus__deref_pwsz2 -tya -tax -clc -ldy #0 -lda {c1},x -adc ({z2}),y -sta {z1} -iny -lda {c1}+1,x -adc ({z2}),y -sta {z1}+1 -//FRAGMENT vwsz1=pwsc1_derefidx_vbuaa_plus__deref_pwsz1 -tax -ldy #0 -clc -lda {c1},x -adc ({z1}),y -pha -iny -lda {c1}+1,x -adc ({z1}),y -sta {z1}+1 -pla -sta {z1} -//FRAGMENT pprz1=_deref_qprc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -//FRAGMENT vbuaa_le_vbuyy_then_la1 -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuaa_then_la1 -tay -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuyy_ge_vbuaa_then_la1 -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pwuc1_derefidx_vbuz1=pwuz2_derefidx_vbuc2 -ldx {z1} -ldy #{c2} -lda ({z2}),y -sta {c1},x -iny -lda ({z2}),y -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuaa=pwuz1_derefidx_vbuc2 -ldy #{c2} -tax -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuxx=pwuz1_derefidx_vbuc2 -ldy #{c2} -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=pwuz1_derefidx_vbuc2 -tya -ldy #{c2} -tax -lda ({z1}),y -sta {c1},x -iny -lda ({z1}),y -sta {c1}+1,x -//FRAGMENT vbsaa=vbsc1 -lda #{c1} -//FRAGMENT 0_neq_vbsyy_then_la1 -cpy #0 -bne {la1} //FRAGMENT vbum1=vbum2 lda {m2} sta {m1} @@ -19156,571 +15771,6 @@ ldy {m2} lda {c2},y ldy {m1} sta {c1},y -//FRAGMENT vwuz1=pbuz2_minus_pbuc1 -lda {z2} -sec -sbc #<{c1} -sta {z1} -lda {z2}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT vwuc1_neq_vwuz1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT pvoc1_neq_pvoz1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuz1_neq_vbuyy_then_la1 -tya -tax -ldy #0 -lda ({z1}),y -tay -stx $ff -cpy $ff -bne {la1} -//FRAGMENT vwuz1=pbuz1_minus_pbuc1 -lda {z1} -sec -sbc #<{c1} -sta {z1} -lda {z1}+1 -sbc #>{c1} -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_bor_vbuc2 -lda #{c2} -ldy {z1} -ora {c1},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_bor_vbuc2 -lda #{c2} -ora {c1},x -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_bor_vbuc2 -lda #{c2} -ora {c1},y -sta {c1},y -//FRAGMENT vduz1=vduz2_rol_0 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_5 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -lda {z2}+2 -rol -sta {z1}+2 -lda {z2}+3 -rol -sta {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vduz1=vduz2_rol_6 -lda {z2}+3 -lsr -sta $ff -lda {z2}+2 -ror -sta {z1}+3 -lda {z2}+1 -ror -sta {z1}+2 -lda {z2} -ror -sta {z1}+1 -lda #0 -ror -sta {z1} -lsr $ff -ror {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz2_rol_7 -lda {z2}+3 -lsr -lda {z2}+2 -ror -sta {z1}+3 -lda {z2}+1 -ror -sta {z1}+2 -lda {z2} -ror -sta {z1}+1 -lda #0 -ror -sta {z1} -//FRAGMENT vduz1=vduz2_rol_8 -lda #0 -sta {z1} -lda {z2} -sta {z1}+1 -lda {z2}+1 -sta {z1}+2 -lda {z2}+2 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_9 -lda #0 -sta {z1} -lda {z2} -asl -sta {z1}+1 -lda {z2}+1 -rol -sta {z1}+2 -lda {z2}+2 -rol -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_vbuc1 -ldy #{c1} -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_rol_16 -lda #0 -sta {z1} -sta {z1}+1 -lda {z2} -sta {z1}+2 -lda {z2}+1 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_24 -lda #0 -sta {z1} -sta {z1}+1 -sta {z1}+2 -lda {z2} -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_32 -lda #0 -sta {z1} -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_ror_0 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_ror_1 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -//FRAGMENT vduz1=vduz2_ror_2 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz2_ror_3 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz2_ror_4 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz2_ror_5 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz2_ror_6 -lda {z2} -asl -sta $ff -lda {z2}+1 -rol -sta {z1} -lda {z2}+2 -rol -sta {z1}+1 -lda {z2}+3 -rol -sta {z1}+2 -lda #0 -rol -sta {z1}+3 -asl $ff -rol {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vduz1=vduz2_ror_7 -lda {z2} -asl -lda {z2}+1 -rol -sta {z1} -lda {z2}+2 -rol -sta {z1}+1 -lda {z2}+3 -rol -sta {z1}+2 -lda #0 -rol -sta {z1}+3 -//FRAGMENT vduz1=vduz2_ror_8 -lda #0 -sta {z1}+3 -lda {z2}+3 -sta {z1}+2 -lda {z2}+2 -sta {z1}+1 -lda {z2}+1 -sta {z1} -//FRAGMENT vduz1=vduz2_ror_9 -lda #0 -sta {z1}+3 -lda {z2}+3 -lsr -sta {z1}+2 -lda {z2}+2 -ror -sta {z1}+1 -lda {z2}+1 -ror -sta {z1} -//FRAGMENT vduz1=vduz2_ror_vbuc1 -ldx #{c1} -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -dex -bne !- -!e: -//FRAGMENT vduz1=vduz2_ror_16 -lda #0 -sta {z1}+3 -sta {z1}+2 -lda {z2}+3 -sta {z1}+1 -lda {z2}+2 -sta {z1} -//FRAGMENT vduz1=vduz2_ror_24 -lda #0 -sta {z1}+3 -sta {z1}+2 -sta {z1}+1 -lda {z2}+3 -sta {z1} -//FRAGMENT vduz1=vduz2_ror_32 -lda #0 -sta {z1}+3 -sta {z1}+2 -sta {z1}+1 -sta {z1} -//FRAGMENT vduz1=vduz2_rol_pbuc1_derefidx_vbuz3 -ldx {z3} -ldy {c1},x -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_ror_pbuc1_derefidx_vbuz3 -ldy {z3} -ldx {c1},y -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -dex -bne !- -!e: -//FRAGMENT vduz1=vduz2_rol_pbuc1_derefidx_vbuaa -tax -ldy {c1},x -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_rol_pbuc1_derefidx_vbuxx -ldy {c1},x -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_rol_pbuc1_derefidx_vbuyy -ldx {c1},y -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -dex -bne !- -!e: -//FRAGMENT vduz1=vduz2_ror_pbuc1_derefidx_vbuaa -tay -ldx {c1},y -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -dex -bne !- -!e: -//FRAGMENT vduz1=vduz2_ror_pbuc1_derefidx_vbuxx -lda {c1},x -tax -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -dex -bne !- -!e: -//FRAGMENT vduz1=vduz2_ror_pbuc1_derefidx_vbuyy -ldx {c1},y -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -cpx #0 -beq !e+ -!: -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -dex -bne !- -!e: //FRAGMENT vwsz1=_sword_vbsz2 lda {z2} sta {z1} diff --git a/src/main/fragment/cache/fragment-cache-rom6502x.asm b/src/main/fragment/cache/fragment-cache-rom6502x.asm index ee223899a..d170b8ea2 100644 --- a/src/main/fragment/cache/fragment-cache-rom6502x.asm +++ b/src/main/fragment/cache/fragment-cache-rom6502x.asm @@ -1,12 +1,13 @@ //KICKC FRAGMENT CACHE 108dd16dc1 108dd18d7f -//FRAGMENT _deref_pbuc1=_inc__deref_pbuc1 -inc {c1} //FRAGMENT isr_hardware_all_entry pha @clob_none txa @clob_x pha @clob_x tya @clob_y pha @clob_y +//FRAGMENT _deref_pbuc1=vbuc2 +lda #{c2} +sta {c1} //FRAGMENT isr_hardware_all_exit pla @clob_y tay @clob_y @@ -14,46 +15,6 @@ pla @clob_x tax @clob_x pla @clob_none rti -//FRAGMENT vbuz1=vbuc1 -lda #{c1} -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -sta {c1},y -//FRAGMENT vbuz1=_inc_vbuz1 -inc {z1} -//FRAGMENT vbuz1_neq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuaa -tay -lda {c2},y -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuxx -lda {c2},x -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuyy -lda {c2},y -sta {c1},y -//FRAGMENT vbuxx_neq_vbuc1_then_la1 -cpx #{c1} -bne {la1} -//FRAGMENT vbuxx=vbuc1 -ldx #{c1} -//FRAGMENT vbuxx=_inc_vbuxx -inx -//FRAGMENT vbuyy=vbuc1 -ldy #{c1} -//FRAGMENT vbuyy=_inc_vbuyy -iny -//FRAGMENT vbuyy_neq_vbuc1_then_la1 -cpy #{c1} -bne {la1} -//FRAGMENT _deref_pbuc1=vbuc2 -lda #{c2} -sta {c1} //FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 lda #{c2} ora {c1} @@ -63,1130 +24,5 @@ lda #<{c2} sta {c1} lda #>{c2} sta {c1}+1 -//FRAGMENT vbuz1=vbuz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -//FRAGMENT 0_eq_vbuz1_then_la1 -lda {z1} -beq {la1} -//FRAGMENT _deref_pbuc1=_dec__deref_pbuc1 -dec {c1} -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuc2 -lda #{c2} -ldy {z1} -sta {c1},y -//FRAGMENT 0_neq_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT vwuz1=vwuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pvoz1=pvoc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1_lt_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcc {la1} -//FRAGMENT pbuz1=pbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuz2 -lda {z2} -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pvoz1=pvoz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=vbuz1_plus_2 -lda {z1} -clc -adc #2 -sta {z1} -//FRAGMENT vbuz1=vbuz2_rol_1 -lda {z2} -asl -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_vbuz3 -lda {z2} -ora {z3} -sta {z1} -//FRAGMENT vwuz1_lt_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: -//FRAGMENT vbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -sta {z1} -//FRAGMENT _deref_pbuc1=vbuz1 -lda {z1} -sta {c1} -//FRAGMENT pbuz1=_inc_pbuz1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=_inc_vwuz1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=_hi_pvoz2 -lda {z2}+1 -sta {z1} -//FRAGMENT vbuz1=_lo_pvoz2 -lda {z2} -sta {z1} -//FRAGMENT vwuz1_lt_vwuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bcc {la1} -bne !+ -lda {z1} -cmp {z2} -bcc {la1} -!: -//FRAGMENT vbuz1=pbuz2_derefidx_vbuc1 -ldy #{c1} -lda ({z2}),y -sta {z1} -//FRAGMENT pbuz1=pbuz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1_neq_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -ldy #0 -sta ({z1}),y -//FRAGMENT vbuz1=vbuaa -sta {z1} -//FRAGMENT vbuaa=vbuz1 -lda {z1} -//FRAGMENT vbuxx=vbuz1 -ldx {z1} -//FRAGMENT vbuz1=vbuaa_band_vbuc1 -and #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuxx_band_vbuc1 -lda #{c1} -sax {z1} -//FRAGMENT vbuz1=vbuyy_band_vbuc1 -tya -and #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -//FRAGMENT vbuaa=vbuaa_band_vbuc1 -and #{c1} -//FRAGMENT vbuaa=vbuxx_band_vbuc1 -txa -and #{c1} -//FRAGMENT vbuaa=vbuyy_band_vbuc1 -tya -and #{c1} -//FRAGMENT vbuxx=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -tax -//FRAGMENT vbuxx=vbuaa_band_vbuc1 -ldx #{c1} -axs #0 -//FRAGMENT 0_eq_vbuaa_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vbuyy=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -tay -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -tax -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -tay -//FRAGMENT pbuc1_derefidx_vbuaa=vbuc2 -tay -lda #{c2} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbuc2 -lda #{c2} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuc2 -lda #{c2} -sta {c1},y -//FRAGMENT 0_neq_vbuxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuaa_lt_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -//FRAGMENT pbuz1=pbuc1_plus_vbuaa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuxx -txa -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vbuyy -tya -clc -adc #<{c1} -sta {z1} -lda #>{c1} -adc #0 -sta {z1}+1 -//FRAGMENT vbuxx=vbuxx_plus_2 -inx -inx -//FRAGMENT vbuz1=vbuaa_rol_1 -asl -sta {z1} -//FRAGMENT vbuz1=vbuxx_rol_1 -txa -asl -sta {z1} -//FRAGMENT vbuz1=vbuyy_rol_1 -tya -asl -sta {z1} -//FRAGMENT vbuaa=vbuz1_rol_1 -lda {z1} -asl -//FRAGMENT vbuaa=vbuaa_rol_1 -asl -//FRAGMENT vbuaa=vbuxx_rol_1 -txa -asl -//FRAGMENT vbuaa=vbuyy_rol_1 -tya -asl -//FRAGMENT vbuxx=vbuz1_rol_1 -lda {z1} -asl -tax -//FRAGMENT vbuxx=vbuaa_rol_1 -asl -tax -//FRAGMENT vbuxx=vbuxx_rol_1 -txa -asl -tax -//FRAGMENT vbuxx=vbuyy_rol_1 -tya -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_1 -lda {z1} -asl -tay -//FRAGMENT vbuyy=vbuaa_rol_1 -asl -tay -//FRAGMENT vbuyy=vbuxx_rol_1 -txa -asl -tay -//FRAGMENT vbuyy=vbuyy_rol_1 -tya -asl -tay -//FRAGMENT vbuz1=vbuxx_bor_vbuz2 -txa -ora {z2} -sta {z1} -//FRAGMENT vbuz1=vbuyy_bor_vbuz2 -tya -ora {z2} -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_vbuaa -ora {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_bor_vbuaa -stx $ff -ora $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_bor_vbuaa -sty $ff -ora $ff -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_vbuxx -txa -ora {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_bor_vbuxx -stx {z1} -//FRAGMENT vbuaa=_deref_pbuz1 -ldy #0 -lda ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tay -//FRAGMENT _deref_pbuc1=vbuaa -sta {c1} -//FRAGMENT vbuaa=_hi_pvoz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_pvoz1 -ldx {z1}+1 -//FRAGMENT vbuaa=_lo_pvoz1 -lda {z1} -//FRAGMENT vbuxx=_lo_pvoz1 -ldx {z1} -//FRAGMENT _deref_pbuc1=vbuxx -stx {c1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuc1 -ldy #{c1} -lda ({z1}),y -tay -//FRAGMENT vbuxx_lt_vbuc1_then_la1 -cpx #{c1} -bcc {la1} -//FRAGMENT vbuyy=_hi_pvoz1 -ldy {z1}+1 -//FRAGMENT _deref_pbuc1=vbuyy -sty {c1} -//FRAGMENT vbuyy=_lo_pvoz1 -ldy {z1} -//FRAGMENT vbuyy_lt_vbuc1_then_la1 -cpy #{c1} -bcc {la1} -//FRAGMENT vbuz1=vbuz2_bor_vbuyy -tya -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuc1 -lda #{c1} -//FRAGMENT vbuaa=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -//FRAGMENT vbuaa=vbuz1_bor_vbuaa -ora {z1} -//FRAGMENT vbuaa=vbuz1_bor_vbuxx -txa -ora {z1} -//FRAGMENT vbuaa=vbuz1_bor_vbuyy -tya -ora {z1} -//FRAGMENT vbuz1=vbuxx -stx {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -tax -//FRAGMENT vbuxx=vbuz1_bor_vbuaa -ora {z1} -tax -//FRAGMENT vbuxx=vbuz1_bor_vbuxx -txa -ora {z1} -tax -//FRAGMENT vbuxx=vbuz1_bor_vbuyy -tya -ora {z1} -tax -//FRAGMENT vbuz1=vbuyy -sty {z1} -//FRAGMENT vbuyy=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -tay -//FRAGMENT vbuyy=vbuz1_bor_vbuaa -ora {z1} -tay -//FRAGMENT vbuyy=vbuz1_bor_vbuxx -txa -ora {z1} -tay -//FRAGMENT vbuyy=vbuz1_bor_vbuyy -tya -ora {z1} -tay -//FRAGMENT vbuz1=vbuxx_bor_vbuyy -txa -sty $ff -ora $ff -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_vbuz1 -txa -ora {z1} -//FRAGMENT vbuaa=vbuxx_bor_vbuaa -stx $ff -ora $ff -//FRAGMENT vbuaa=vbuxx_bor_vbuyy -txa -sty $ff -ora $ff -//FRAGMENT vbuxx=vbuxx_bor_vbuz1 -txa -ora {z1} -tax -//FRAGMENT vbuxx=vbuxx_bor_vbuaa -stx $ff -ora $ff -tax -//FRAGMENT vbuxx=vbuxx_bor_vbuyy -txa -sty $ff -ora $ff -tax -//FRAGMENT vbuyy=vbuxx_bor_vbuz1 -txa -ora {z1} -tay -//FRAGMENT vbuyy=vbuxx_bor_vbuaa -stx $ff -ora $ff -tay -//FRAGMENT vbuyy=vbuxx_bor_vbuyy -txa -sty $ff -ora $ff -tay -//FRAGMENT 0_neq_vbuyy_then_la1 -cpy #0 -bne {la1} -//FRAGMENT 0_eq_vbuxx_then_la1 -cpx #0 -beq {la1} -//FRAGMENT 0_eq_vbuyy_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vbuaa=vbuyy_bor_vbuaa -sty $ff -ora $ff -//FRAGMENT vbuxx=vbuaa -tax -//FRAGMENT vbuyy=vbuaa -tay -//FRAGMENT pbuz1=pbuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vbuz1=_dec_vbuz1 -dec {z1} -//FRAGMENT pbuz1=pbuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=_inc_pbuz2 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT vbuz1_ge_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcs {la1} -//FRAGMENT vbuz1=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -//FRAGMENT vwuz1=_word_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_5 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1_eq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -beq {la1} -//FRAGMENT pbuz1=pbuz2_plus_vbuz3 -lda {z3} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_minus_vbuc1 -sec -lda {z1} -sbc #{c1} -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuc1 -lda {c1} -sta {z1} -//FRAGMENT _deref_pbuz1=vbuz2 -lda {z2} -ldy #0 -sta ({z1}),y -//FRAGMENT vbuxx=vbuxx_band_vbuc1 -lda #{c1} -axs #0 -//FRAGMENT vbuyy=vbuxx_band_vbuc1 -txa -and #{c1} -tay -//FRAGMENT vbuxx=vbuyy_band_vbuc1 -ldx #{c1} -tya -axs #0 -//FRAGMENT vbuyy=vbuyy_band_vbuc1 -tya -and #{c1} -tay -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1 -ldy {z1} -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1 -ldx {z1} -ldy {c1},x -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa -tay -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa -tay -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa -tax -ldy {c1},x -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -//FRAGMENT 0_neq_vbuaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuaa_ge_vbuz1_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuxx=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuxx -lda #0 -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vwuz1=_word_vbuaa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuaa_eq_vbuc1_then_la1 -cmp #{c1} -beq {la1} -//FRAGMENT vbuaa=_deref_pbuc1 -lda {c1} -//FRAGMENT vbuxx=_deref_pbuc1 -ldx {c1} -//FRAGMENT _deref_pbuz1=vbuaa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuxx -txa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuyy -tya -ldy #0 -sta ({z1}),y -//FRAGMENT vbuxx_ge_vbuz1_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vbuxx_eq_vbuc1_then_la1 -cpx #{c1} -beq {la1} -//FRAGMENT vbuyy=_deref_pbuc1 -ldy {c1} -//FRAGMENT vbuz1_ge_vbuxx_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuyy=vbuz1 -ldy {z1} -//FRAGMENT vbuz1_ge_vbuyy_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuyy_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuaa=vbuxx -txa -//FRAGMENT vbuyy=vbuxx -txa -tay -//FRAGMENT vbuyy_eq_vbuc1_then_la1 -cpy #{c1} -beq {la1} -//FRAGMENT vbuaa=vbuyy -tya -//FRAGMENT vbuxx=vbuyy -tya -tax -//FRAGMENT vbuyy_ge_vbuz1_then_la1 -cpy {z1} -bcs {la1} -//FRAGMENT vwuz1=vwuz1_rol_5 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pbuz1=pbuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_plus_1 -ldy {z2} -iny -sty {z1} -//FRAGMENT vbuz1=vbuz2_rol_2 -lda {z2} -asl -asl -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuz2 -ldy {z2} -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT vbuz1=vbuz1_minus_vbuc1 -lax {z1} -axs #{c1} -stx {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuz3 -ldy {z2} -lda {c1},y -ldy {z3} -clc -adc {c2},y -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuz2 -lda {z2} -ldy {z1} -sta {c1},y -//FRAGMENT vbuz1_ge_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcs {la1} -//FRAGMENT vbuz1=vbuz1_plus_vbuc1 -lax {z1} -axs #-[{c1}] -stx {z1} -//FRAGMENT vbuaa=vbuz1_plus_1 -lda {z1} -clc -adc #1 -//FRAGMENT vbuaa=vbuz1_rol_2 -lda {z1} -asl -asl -//FRAGMENT vbuxx=vbuz1_rol_2 -lda {z1} -asl -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_2 -lda {z1} -asl -asl -tay -//FRAGMENT vbuz1=vbuaa_rol_2 -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuaa_rol_2 -asl -asl -//FRAGMENT vbuxx=vbuaa_rol_2 -asl -asl -tax -//FRAGMENT vbuyy=vbuaa_rol_2 -asl -asl -tay -//FRAGMENT vbuz1=vbuxx_rol_2 -txa -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuxx_rol_2 -txa -asl -asl -//FRAGMENT vbuxx=vbuxx_rol_2 -txa -asl -asl -tax -//FRAGMENT vbuyy=vbuxx_rol_2 -txa -asl -asl -tay -//FRAGMENT vbuz1=vbuyy_rol_2 -tya -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuyy_rol_2 -tya -asl -asl -//FRAGMENT vbuxx=vbuyy_rol_2 -tya -asl -asl -tax -//FRAGMENT vbuyy=vbuyy_rol_2 -tya -asl -asl -tay -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuz1 -ldx {z1} -tay -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuz1 -ldy {z1} -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuz1 -ldx {z1} -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuxx -tay -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc2_derefidx_vbuxx -lda {c2},x -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc2_derefidx_vbuyy -tax -lda {c2},y -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc2_derefidx_vbuyy -lda {c2},y -sta {c1},x -//FRAGMENT vbuxx=vbuxx_minus_vbuc1 -txa -axs #{c1} -//FRAGMENT vbuyy=vbuyy_minus_vbuc1 -tya -sec -sbc #{c1} -tay -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldx {z1} -lda {c1},x -ldx {z2} -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuz2 -ldy {z1} -lda {c1},y -ldy {z2} -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuxx -lda {c2},x -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z2} -clc -adc {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -clc -adc {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldx {z1} -clc -adc {c1},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_plus_pbuc2_derefidx_vbuyy -lda {c2},y -ldy {z1} -clc -adc {c1},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz2 -lda {c1},x -ldy {z2} -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldx {z1} -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuz1 -lda {c1},x -ldy {z1} -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuxx -lda {c1},x -clc -adc {c2},x -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_plus_pbuc2_derefidx_vbuyy -lda {c1},x -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz2 -lda {c1},y -ldy {z2} -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldx {z1} -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuz1 -lda {c1},y -ldy {z1} -clc -adc {c2},y -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuxx -lda {c1},y -clc -adc {c2},x -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy_plus_pbuc2_derefidx_vbuyy -lda {c1},y -clc -adc {c2},y -tay -//FRAGMENT pbuc1_derefidx_vbuz1=vbuaa -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=vbuxx -ldy {z1} -txa -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=vbuyy -tya -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbuz1 -lda {z1} -sta {c1},x -//FRAGMENT vbuxx_ge_vbuc1_then_la1 -cpx #{c1} -bcs {la1} -//FRAGMENT vbuxx=vbuxx_plus_vbuc1 -txa -axs #-[{c1}] -//FRAGMENT vbuyy=vbuyy_plus_vbuc1 -tya -clc -adc #{c1} -tay -//FRAGMENT vbuyy_ge_vbuc1_then_la1 -cpy #{c1} -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuxx=vbuaa -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuaa -sta {c1},y -//FRAGMENT vbuxx=vbuz1_plus_1 -ldx {z1} -inx -//FRAGMENT vbuyy=vbuz1_plus_1 -ldy {z1} -iny +//FRAGMENT _deref_pbuc1=_inc__deref_pbuc1 +inc {c1} diff --git a/src/main/fragment/cache/fragment-cache-wdc65c02.asm b/src/main/fragment/cache/fragment-cache-wdc65c02.asm index b329762dd..87d73fb8c 100644 --- a/src/main/fragment/cache/fragment-cache-wdc65c02.asm +++ b/src/main/fragment/cache/fragment-cache-wdc65c02.asm @@ -1,3407 +1,28 @@ //KICKC FRAGMENT CACHE 108dd16dc1 108dd18d7f -//FRAGMENT vbuz1=vbuc1 -lda #{c1} -sta {z1} -//FRAGMENT vwuz1=vwuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vduz1=vduc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -lda #<{c1}>>$10 -sta {z1}+2 -lda #>{c1}>>$10 -sta {z1}+3 //FRAGMENT vbuz1=_deref_pbuc1 lda {c1} sta {z1} -//FRAGMENT vbuz1_lt_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcc {la1} -//FRAGMENT vbuz1=vbuz2_minus_1 -ldx {z2} -dex -stx {z1} -//FRAGMENT vbuz1=vbuz2 -lda {z2} -sta {z1} -//FRAGMENT pvoz1=pvoc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor__deref_pbuc2 -lda {c1} -ora {c2} -sta {c1} -//FRAGMENT 0_eq_vbuz1_then_la1 -lda {z1} -beq {la1} -//FRAGMENT vwuz1=vwuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=_inc_vbuz1 -inc {z1} -//FRAGMENT vwuz1=_inc_vwuz1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1_le_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne !+ -lda {z1} -cmp #<{c1} -!: -bcc {la1} -beq {la1} -//FRAGMENT vbuz1=vwuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_ror_7 -lda {c1} -rol -rol -and #$01 -sta {z1} -//FRAGMENT vbuz1=vbuc1_rol_vbuz2 -lda #{c1} -ldy {z2} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT _deref_pbuc1=vbuz1 -lda {z1} -sta {c1} -//FRAGMENT vbuz1=vbuz2_rol_1 -lda {z2} -asl -sta {z1} -//FRAGMENT pbuz1=qbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuz2_band_vbuc1 -lda #{c1} -ldy #0 -and ({z2}),y -sta {z1} -//FRAGMENT vbuz1=vbuz2_ror_4 -lda {z2} -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vwuz1=pwuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_ror_6 -lda {z2} -rol -rol -rol -and #$03 -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuz2 -lda {z2} -ldy {z1} -sta {c1},y -//FRAGMENT _deref_pbuz1=vbuz2 -lda {z2} -ldy #0 -sta ({z1}),y -//FRAGMENT vbuz1_le_vbuz2_then_la1 -lda {z2} -cmp {z1} -bcs {la1} -//FRAGMENT 0_lt_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuc2 -lda #{c2} -ldy {z1} -sta {c1},y -//FRAGMENT vwuz1=_word_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_vbuz3 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -ldy {z3} -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT pwuc1_derefidx_vbuz1=vwuz2 -ldy {z1} -lda {z2} -sta {c1},y -lda {z2}+1 -sta {c1}+1,y -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuc2 -lda #{c2} -and {c1} -sta {c1} -//FRAGMENT vbuz1=_lo_pvoz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=_hi_pvoz2 -lda {z2}+1 -sta {z1} -//FRAGMENT _deref_pbuc1=vbuc2 -lda #{c2} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 -lda #{c2} -ora {c1} -sta {c1} -//FRAGMENT vbuz1=vbuc1_bor_vbuz2 -lda #{c1} -ora {z2} -sta {z1} -//FRAGMENT vwuz1_lt_vwuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bcc {la1} -bne !+ -lda {z1} -cmp {z2} -bcc {la1} -!: -//FRAGMENT _deref_pbuc1=_deref_pbuc2 -lda {c2} -sta {c1} -//FRAGMENT vwuz1_eq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bne !+ -lda {z1}+1 -bne !+ -jmp {la1} -!: -//FRAGMENT vwuz1_neq_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT pwuc1_derefidx_vbuz1=vwuc2 -ldy {z1} -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT vbuz1=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -sta {z1} -//FRAGMENT vwuz1=_lo_vduz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=_hi_vduz2 -lda {z2}+2 -sta {z1} -lda {z2}+3 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=_byte_vwuz2 -ldy {z1} -lda {z2} -sta {c1},y -//FRAGMENT vbuz1=vbuz2_rol_2 -lda {z2} -asl -asl -sta {z1} -//FRAGMENT pduc1_derefidx_vbuz1=vduz2 -ldy {z1} -lda {z2} -sta {c1},y -lda {z2}+1 -sta {c1}+1,y -lda {z2}+2 -sta {c1}+2,y -lda {z2}+3 -sta {c1}+3,y -//FRAGMENT vduz1=vduz2_ror_1 -lda {z2}+3 -lsr -sta {z1}+3 -lda {z2}+2 -ror -sta {z1}+2 -lda {z2}+1 -ror -sta {z1}+1 -lda {z2} -ror -sta {z1} -//FRAGMENT vbuz1=_hi_vwuz2 -lda {z2}+1 -sta {z1} -//FRAGMENT vbuz1=vbuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -//FRAGMENT vbuz1_eq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -beq {la1} -//FRAGMENT vbuz1_neq_vbuc1_then_la1 -lda #{c1} -cmp {z1} -bne {la1} -//FRAGMENT pwuc1_derefidx_vbuz1=vbuc2 -lda #{c2} -ldy {z1} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT _deref_pwuc1=vwuc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -//FRAGMENT _deref_pduc1=vduc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -lda #<{c2}>>$10 -sta {c1}+2 -lda #>{c2}>>$10 -sta {c1}+3 -//FRAGMENT pbuz1=pbuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=vbuz2_rol_4 -lda {z2} -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_vbuz3 -lda {z2} -ora {z3} -sta {z1} -//FRAGMENT vbuz1_lt_vwuz2_then_la1 -lda {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bcc {la1} -//FRAGMENT vbuz1=_lo_pbuz2 -lda {z2} -sta {z1} -//FRAGMENT vbuz1=_hi_pbuz2 -lda {z2}+1 -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_vbuc1 -lda #{c1} -ora {z2} -sta {z1} -//FRAGMENT pbuz1=pbuz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vbuz1=_deref_pbuz2 -ldy #0 -lda ({z2}),y -sta {z1} -//FRAGMENT pbuz1=_inc_pbuz1 -inc {z1} -bne !+ -inc {z1}+1 -!: -//FRAGMENT 0_neq_vbuz1_then_la1 -lda {z1} -bne {la1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT vbsz1=pbsc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -//FRAGMENT vbuz1_neq_0_then_la1 -lda {z1} -bne {la1} -//FRAGMENT vwuz1=vwuz2_ror_3 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vwuz1=vwuz2_rol_1 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -//FRAGMENT pwuz1=pwuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pwuz1=vwuz2 -ldy #0 -lda {z2} -sta ({z1}),y -iny -lda {z2}+1 -sta ({z1}),y -//FRAGMENT pbuz1=pbuc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vbsz1=vbsz1_minus_1 -dec {z1} -//FRAGMENT vbuz1=vbuz1_ror_1 -lsr {z1} -//FRAGMENT vwuz1=vwuz2_ror_2 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vbsz1=vbsz1_minus_2 -dec {z1} -dec {z1} -//FRAGMENT vbuz1=vbuz1_ror_2 -lda {z1} -lsr -lsr -sta {z1} -//FRAGMENT vwuz1=vwuz2_ror_1 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror -sta {z1} -//FRAGMENT vbsz1=vbsz1_minus_vbsc1 -lda {z1} -sec -sbc #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuz1_ror_4 -lda {z1} -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbsz1_ge_0_then_la1 -lda {z1} -cmp #0 -bpl {la1} -//FRAGMENT vbuz1=vbuz2_plus_vbuz3 -lda {z2} -clc -adc {z3} -sta {z1} -//FRAGMENT vduz1=vduz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda {z2}+2 -sta {z1}+2 -lda {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz2_rol_2 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT pduz1=pduc1_plus_vwuz2 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT _deref_pduz1=vduz2 -ldy #0 -lda {z2} -sta ({z1}),y -iny -lda {z2}+1 -sta ({z1}),y -iny -lda {z2}+2 -sta ({z1}),y -iny -lda {z2}+3 -sta ({z1}),y -//FRAGMENT vduz1=vduz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vbuz1=_lo_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT pvoz1=pvoz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_minus_vwuz3 -lda {z2} -sec -sbc {z3} -sta {z1} -lda {z2}+1 -sbc {z3}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_7 -lda {z2}+1 -lsr -lda {z2} -ror -sta {z1}+1 -lda #0 -ror -sta {z1} -//FRAGMENT vwuz1=vwuz2_bxor_vwuz3 -lda {z2} -eor {z3} -sta {z1} -lda {z2}+1 -eor {z3}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_ror_9 -lda {z2}+1 -lsr -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_8 -lda {z2} -sta {z1}+1 -lda #0 -sta {z1} -//FRAGMENT pbuz1=_deref_qbuc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuz1=_deref_pbuz1_band_vbuc1 -lda #{c1} -ldy #0 -and ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=_deref_pbuz1 -ldy #0 -lda ({z1}),y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=pbuz2_plus_pwuc1_derefidx_vbuz3 -ldy {z3} -clc -lda {z2} -adc {c1},y -sta {z1} -lda {z2}+1 -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_rol_1 -ldy {z2} -lda {c1},y -asl -sta {z1} -//FRAGMENT pbuz1=pbuz2_plus_vbuz3 -lda {z3} -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuc1_derefidx_vbuz1=_inc_pbuc1_derefidx_vbuz1 -ldx {z1} -inc {c1},x -//FRAGMENT vwuz1=_word_pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1_neq_vwuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_neq_vbuz2_then_la1 -lda {z2} -ldy {z1} -cmp {c1},y -bne {la1} -//FRAGMENT _deref_pbuc1_neq_pbuc2_derefidx_vbuz1_then_la1 -lda {c1} -ldy {z1} -cmp {c2},y -bne {la1} -//FRAGMENT vduz1=_dword_vwuz2 -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -lda #0 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vwuz1_neq_0_then_la1 -lda {z1} -ora {z1}+1 -bne {la1} -//FRAGMENT vbuz1_eq_0_then_la1 -lda {z1} -beq {la1} -//FRAGMENT vduz1=vduz1_plus_vduz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc {z2}+2 -sta {z1}+2 -lda {z1}+3 -adc {z2}+3 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz1_ror_1 -lsr {z1}+1 -ror {z1} -//FRAGMENT vduz1=vduz1_rol_1 -asl {z1} -rol {z1}+1 -rol {z1}+2 -rol {z1}+3 -//FRAGMENT vduz1_lt_vduz2_then_la1 -lda {z1}+3 -cmp {z2}+3 -bcc {la1} -bne !+ -lda {z1}+2 -cmp {z2}+2 -bcc {la1} -bne !+ -lda {z1}+1 -cmp {z2}+1 -bcc {la1} -bne !+ -lda {z1} -cmp {z2} -bcc {la1} -!: -//FRAGMENT vduz1=_inc_vduz1 -inc {z1} -bne !+ -inc {z1}+1 -bne !+ -inc {z1}+2 -bne !+ -inc {z1}+3 -!: -//FRAGMENT vwuz1=vwuz1_plus_vwuz2 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1_ge_vwuz2_then_la1 -lda {z2}+1 -cmp {z1}+1 -bne !+ -lda {z2} -cmp {z1} -beq {la1} -!: -bcc {la1} -//FRAGMENT vwuz1=vwuz1_minus_vwuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_plus_1 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT vwuz1=_dec_vwuz1 -lda {z1} -bne !+ -dec {z1}+1 -!: -dec {z1} -//FRAGMENT vwuz1=vwuz1_rol_1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz1_bor_vbuc1 -lda #{c1} -ora {z1} -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2_rol_4 -ldy {z2} -lda {c1},y -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuz2_bor_pbuc1_derefidx_vbuz3 -lda {z2} -ldy {z3} -ora {c1},y -sta {z1} -//FRAGMENT vwuz1=vwuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT vduz1=_dword__deref_pwuz2 -ldy #0 -sty {z1}+2 -sty {z1}+3 -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -//FRAGMENT vduz1=_deref_pduz2 -ldy #0 -lda ({z2}),y -sta {z1} -iny -lda ({z2}),y -sta {z1}+1 -iny -lda ({z2}),y -sta {z1}+2 -iny -lda ({z2}),y -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vduz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -lda {z2}+2 -adc {z3}+2 -sta {z1}+2 -lda {z2}+3 -adc {z3}+3 -sta {z1}+3 -//FRAGMENT vbuz1=vbuz1_rol_vbuz2 -lda {z1} -ldy {z2} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuz1=_bnot__deref_pbuz2 -ldy #0 -lda ({z2}),y -eor #$ff -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuz2 -lda {c1} -and {z2} -sta {z1} -//FRAGMENT pbuc1_derefidx_vbuz1_lt_vbuz2_then_la1 -ldy {z1} -lda {c1},y -cmp {z2} -bcc {la1} -//FRAGMENT 0_neq_pbuc1_derefidx_vbuz1_then_la1 -ldy {z1} -lda {c1},y -cmp #0 -bne {la1} -//FRAGMENT pbuc1_derefidx_vbuz1_lt_vwuz2_then_la1 -ldy {z1} -lda {c1},y -ldy {z2}+1 -bne {la1} -cmp {z2} -bcc {la1} -//FRAGMENT vwuz1=vbuz2_rol_vbuz3 -lda {z2} -ldy {z3} -sta {z1} -lda #0 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT pbuz1=pbuz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1_lt_vbuz2_then_la1 -lda {z1}+1 -bne !+ -lda {z1} -cmp {z2} -bcc {la1} -!: -//FRAGMENT vbuaa=_deref_pbuc1 -lda {c1} -//FRAGMENT vbuxx=_deref_pbuc1 -ldx {c1} -//FRAGMENT vbuaa_lt_vbuz1_then_la1 -cmp {z1} -bcc {la1} -//FRAGMENT vbuaa=vbuz1_minus_1 -lda {z1} -sec -sbc #1 -//FRAGMENT vbuz1=vbuaa -sta {z1} -//FRAGMENT vbuaa=vbuz1 -lda {z1} -//FRAGMENT vbuxx=vbuz1 -ldx {z1} -//FRAGMENT 0_eq_vbuaa_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vbuaa=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -//FRAGMENT vbuxx=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -tax -//FRAGMENT vbuyy=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -tay -//FRAGMENT vbuaa=_deref_pbuc1_ror_7 -lda {c1} -rol -rol -and #$01 -//FRAGMENT vbuxx=_deref_pbuc1_ror_7 -lda {c1} -rol -rol -and #$01 -tax -//FRAGMENT vbuyy=_deref_pbuc1_ror_7 -lda {c1} -rol -rol -and #$01 -tay -//FRAGMENT vbuz1=vbuc1_rol_vbuaa -tay -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuz1=vbuc1_rol_vbuxx -lda #{c1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -sta {z1} -//FRAGMENT vbuz1=vbuc1_rol_vbuyy -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuc1_rol_vbuz1 -lda #{c1} -ldy {z1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -//FRAGMENT vbuaa=vbuc1_rol_vbuaa -tay -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -//FRAGMENT vbuaa=vbuc1_rol_vbuxx -lda #{c1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -//FRAGMENT vbuaa=vbuc1_rol_vbuyy -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuc1_rol_vbuz1 -lda #{c1} -ldx {z1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tax -//FRAGMENT vbuxx=vbuc1_rol_vbuaa -tax -lda #{c1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tax -//FRAGMENT vbuxx=vbuc1_rol_vbuxx -lda #{c1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tax -//FRAGMENT vbuxx=vbuc1_rol_vbuyy -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuc1_rol_vbuz1 -lda #{c1} -ldy {z1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tay -//FRAGMENT vbuyy=vbuc1_rol_vbuaa -tay -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tay -//FRAGMENT vbuyy=vbuc1_rol_vbuxx -lda #{c1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tay -//FRAGMENT vbuyy=vbuc1_rol_vbuyy -lda #{c1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tay -//FRAGMENT _deref_pbuc1=vbuaa -sta {c1} -//FRAGMENT vbuaa=vbuz1_rol_1 -lda {z1} -asl -//FRAGMENT vbuxx=vbuz1_rol_1 -lda {z1} -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_1 -lda {z1} -asl -tay -//FRAGMENT vbuz1=vbuaa_rol_1 -asl -sta {z1} -//FRAGMENT vbuaa=vbuaa_rol_1 -asl -//FRAGMENT vbuxx=vbuaa_rol_1 -asl -tax -//FRAGMENT vbuyy=vbuaa_rol_1 -asl -tay -//FRAGMENT vbuz1=vbuxx_rol_1 -txa -asl -sta {z1} -//FRAGMENT vbuaa=vbuxx_rol_1 -txa -asl -//FRAGMENT vbuxx=vbuxx_rol_1 -txa -asl -tax -//FRAGMENT vbuyy=vbuxx_rol_1 -txa -asl -tay -//FRAGMENT vbuz1=vbuyy_rol_1 -tya -asl -sta {z1} -//FRAGMENT vbuaa=vbuyy_rol_1 -tya -asl -//FRAGMENT vbuxx=vbuyy_rol_1 -tya -asl -tax -//FRAGMENT vbuyy=vbuyy_rol_1 -tya -asl -tay -//FRAGMENT pbuz1=qbuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT pbuz1=qbuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -//FRAGMENT pbuz1=qbuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuaa=_deref_pbuz1_band_vbuc1 -lda #{c1} -ldy #0 -and ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1_band_vbuc1 -lda #{c1} -ldy #0 -and ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1_band_vbuc1 -lda #{c1} -ldy #0 -and ({z1}),y -tay -//FRAGMENT vbuaa=vbuz1_ror_4 -lda {z1} -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuz1_ror_4 -lda {z1} -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuz1_ror_4 -lda {z1} -lsr -lsr -lsr -lsr -tay -//FRAGMENT vbuz1=vbuaa_ror_4 -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuaa_ror_4 -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuaa_ror_4 -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuaa_ror_4 -lsr -lsr -lsr -lsr -tay -//FRAGMENT vbuz1=vbuxx_ror_4 -txa -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_4 -txa -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuxx_ror_4 -txa -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuxx_ror_4 -txa -lsr -lsr -lsr -lsr -tay -//FRAGMENT vbuz1=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -sta {z1} -//FRAGMENT vbuaa=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -//FRAGMENT vbuxx=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -tax -//FRAGMENT vbuyy=vbuyy_ror_4 -tya -lsr -lsr -lsr -lsr -tay -//FRAGMENT vwuz1=pwuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -lda {c1}+1,x -sta {z1}+1 -//FRAGMENT vwuz1=pwuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuaa=vbuz1_ror_6 -lda {z1} -rol -rol -rol -and #$03 -//FRAGMENT vbuxx=vbuz1_ror_6 -lda {z1} -rol -rol -rol -and #$03 -tax -//FRAGMENT vbuyy=vbuz1_ror_6 -lda {z1} -rol -rol -rol -and #$03 -tay -//FRAGMENT vbuz1=vbuaa_ror_6 -rol -rol -rol -and #$03 -sta {z1} -//FRAGMENT vbuaa=vbuaa_ror_6 -rol -rol -rol -and #$03 -//FRAGMENT vbuxx=vbuaa_ror_6 -rol -rol -rol -and #$03 -tax -//FRAGMENT vbuyy=vbuaa_ror_6 -rol -rol -rol -and #$03 -tay -//FRAGMENT vbuz1=vbuxx_ror_6 -txa -rol -rol -rol -and #$03 -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_6 -txa -rol -rol -rol -and #$03 -//FRAGMENT vbuxx=vbuxx_ror_6 -txa -rol -rol -rol -and #$03 -tax -//FRAGMENT vbuyy=vbuxx_ror_6 -txa -rol -rol -rol -and #$03 -tay -//FRAGMENT vbuz1=vbuyy_ror_6 -tya -rol -rol -rol -and #$03 -sta {z1} -//FRAGMENT vbuaa=vbuyy_ror_6 -tya -rol -rol -rol -and #$03 -//FRAGMENT vbuxx=vbuyy_ror_6 -tya -rol -rol -rol -and #$03 -tax -//FRAGMENT vbuyy=vbuyy_ror_6 -tya -rol -rol -rol -and #$03 -tay -//FRAGMENT pbuc1_derefidx_vbuaa=vbuz1 -tay -lda {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=vbuz1 -lda {z1} -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuz1 -lda {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=vbuaa -ldy {z1} -sta {c1},y -//FRAGMENT _deref_pbuz1=vbuxx -txa -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=vbuyy -tya -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa_le_vbuz1_then_la1 -ldy {z1} -sta $ff -cpy $ff -bcs {la1} -//FRAGMENT pbuc1_derefidx_vbuz1=vbuxx -ldy {z1} -txa -sta {c1},y -//FRAGMENT vwuz1=_word_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT pwuc1_derefidx_vbuaa=vwuz1 -tay -lda {z1} -sta {c1},y -lda {z1}+1 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vwuz1 -lda {z1} -sta {c1},x -lda {z1}+1 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vwuz1 -lda {z1} -sta {c1},y -lda {z1}+1 -sta {c1}+1,y -//FRAGMENT vbuaa=_lo_pvoz1 -lda {z1} -//FRAGMENT vbuxx=_lo_pvoz1 -ldx {z1} -//FRAGMENT vbuaa=_hi_pvoz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_pvoz1 -ldx {z1}+1 -//FRAGMENT vbuz1=vbuc1_bor_vbuxx -txa -ora #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuc1_bor_vbuyy -tya -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -//FRAGMENT vbuaa=vbuc1_bor_vbuxx -txa -ora #{c1} -//FRAGMENT vbuaa=vbuc1_bor_vbuyy -tya -ora #{c1} -//FRAGMENT vbuxx=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -tax -//FRAGMENT vbuxx=vbuc1_bor_vbuxx -txa -ora #{c1} -tax -//FRAGMENT vbuxx=vbuc1_bor_vbuyy -tya -ora #{c1} -tax -//FRAGMENT vbuyy=vbuc1_bor_vbuz1 -lda #{c1} -ora {z1} -tay -//FRAGMENT vbuyy=vbuc1_bor_vbuxx -txa -ora #{c1} -tay -//FRAGMENT vbuyy=vbuc1_bor_vbuyy -tya -ora #{c1} -tay -//FRAGMENT pbuc1_derefidx_vbuxx=vbuc2 -lda #{c2} -sta {c1},x -//FRAGMENT pwuc1_derefidx_vbuaa=vwuc2 -tay -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vwuc2 -lda #<{c2} -sta {c1},x -lda #>{c2} -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vwuc2 -lda #<{c2} -sta {c1},y -lda #>{c2} -sta {c1}+1,y -//FRAGMENT vbuxx=vbuxx_bor_vbuc1 -txa -ora #{c1} -tax -//FRAGMENT vbuyy=vbuyy_bor_vbuc1 -tya -ora #{c1} -tay -//FRAGMENT vbuz1=vbuxx -stx {z1} -//FRAGMENT pbuc1_derefidx_vbuxx=_byte_vwuz1 -lda {z1} -sta {c1},x -//FRAGMENT vbuz1=vbuxx_rol_2 -txa -asl -asl -sta {z1} -//FRAGMENT vbuxx=vbuz1_rol_2 -lda {z1} -asl -asl -tax -//FRAGMENT vbuxx=vbuxx_rol_2 -txa -asl -asl -tax -//FRAGMENT pduc1_derefidx_vbuxx=vduz1 -lda {z1} -sta {c1},x -lda {z1}+1 -sta {c1}+1,x -lda {z1}+2 -sta {c1}+2,x -lda {z1}+3 -sta {c1}+3,x -//FRAGMENT vbuaa=_hi_vwuz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_vwuz1 -ldx {z1}+1 -//FRAGMENT vbuz1=vbuaa_band_vbuc1 -and #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuxx_band_vbuc1 -txa -and #{c1} -sta {z1} -//FRAGMENT vbuz1=vbuyy_band_vbuc1 -tya -and #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -//FRAGMENT vbuaa=vbuaa_band_vbuc1 -and #{c1} -//FRAGMENT vbuaa=vbuxx_band_vbuc1 -txa -and #{c1} -//FRAGMENT vbuaa=vbuyy_band_vbuc1 -tya -and #{c1} -//FRAGMENT vbuxx=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -tax -//FRAGMENT vbuxx=vbuaa_band_vbuc1 -and #{c1} -tax -//FRAGMENT vbuxx=vbuxx_band_vbuc1 -txa -and #{c1} -tax -//FRAGMENT vbuxx=vbuyy_band_vbuc1 -tya -and #{c1} -tax -//FRAGMENT vbuyy=vbuz1_band_vbuc1 -lda #{c1} -and {z1} -tay -//FRAGMENT vbuyy=vbuaa_band_vbuc1 -and #{c1} -tay -//FRAGMENT vbuyy=vbuxx_band_vbuc1 -txa -and #{c1} -tay -//FRAGMENT vbuyy=vbuyy_band_vbuc1 -tya -and #{c1} -tay -//FRAGMENT vbuxx_eq_vbuc1_then_la1 -cpx #{c1} -beq {la1} -//FRAGMENT vbuxx_neq_vbuc1_then_la1 -cpx #{c1} -bne {la1} -//FRAGMENT vbuaa=vbuaa_bor_vbuc1 -ora #{c1} -//FRAGMENT pwuc1_derefidx_vbuaa=vbuc2 -tay -lda #{c2} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT pwuc1_derefidx_vbuxx=vbuc2 -lda #{c2} -sta {c1},x -lda #0 -sta {c1}+1,x -//FRAGMENT pwuc1_derefidx_vbuyy=vbuc2 -lda #{c2} -sta {c1},y -lda #0 -sta {c1}+1,y -//FRAGMENT vbuz1=vbuaa_rol_4 -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuxx_rol_4 -txa -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuyy_rol_4 -tya -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuz1_rol_4 -lda {z1} -asl -asl -asl -asl -//FRAGMENT vbuaa=vbuaa_rol_4 -asl -asl -asl -asl -//FRAGMENT vbuaa=vbuxx_rol_4 -txa -asl -asl -asl -asl -//FRAGMENT vbuaa=vbuyy_rol_4 -tya -asl -asl -asl -asl -//FRAGMENT vbuxx=vbuz1_rol_4 -lda {z1} -asl -asl -asl -asl -tax -//FRAGMENT vbuxx=vbuaa_rol_4 -asl -asl -asl -asl -tax -//FRAGMENT vbuxx=vbuxx_rol_4 -txa -asl -asl -asl -asl -tax -//FRAGMENT vbuxx=vbuyy_rol_4 -tya -asl -asl -asl -asl -tax -//FRAGMENT vbuyy=vbuz1_rol_4 -lda {z1} -asl -asl -asl -asl -tay -//FRAGMENT vbuyy=vbuaa_rol_4 -asl -asl -asl -asl -tay -//FRAGMENT vbuyy=vbuxx_rol_4 -txa -asl -asl -asl -asl -tay -//FRAGMENT vbuyy=vbuyy_rol_4 -tya -asl -asl -asl -asl -tay -//FRAGMENT vbuaa=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -//FRAGMENT vbuxx=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuz2 -lda {z1} -ora {z2} -tay -//FRAGMENT vbuz1=vbuz2_bor_vbuaa -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bor_vbuaa -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuaa -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuaa -ora {z1} -tay -//FRAGMENT vbuz1=vbuz2_bor_vbuxx -txa -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bor_vbuxx -txa -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuxx -txa -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuxx -txa -ora {z1} -tay -//FRAGMENT vbuz1=vbuz2_bor_vbuyy -tya -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bor_vbuyy -tya -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuyy -tya -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuyy -tya -ora {z1} -tay -//FRAGMENT vbuz1=vbuaa_bor_vbuz2 -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuaa_bor_vbuz1 -ora {z1} -//FRAGMENT vbuxx=vbuaa_bor_vbuz1 -ora {z1} -tax -//FRAGMENT vbuyy=vbuaa_bor_vbuz1 -ora {z1} -tay -//FRAGMENT vbuz1=vbuaa_bor_vbuaa -sta {z1} -//FRAGMENT vbuaa_lt_vwuz1_then_la1 -ldy {z1}+1 -bne {la1} -cmp {z1} -bcc {la1} -//FRAGMENT vbuaa=_lo_pbuz1 -lda {z1} -//FRAGMENT vbuxx=_lo_pbuz1 -ldx {z1} -//FRAGMENT vbuaa=_hi_pbuz1 -lda {z1}+1 -//FRAGMENT vbuxx=_hi_pbuz1 -ldx {z1}+1 -//FRAGMENT vbuaa=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_vbuc1 -lda #{c1} -ora {z1} -tay -//FRAGMENT vbuz1=vbuxx_bor_vbuc1 -txa -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_vbuc1 -txa -ora #{c1} -//FRAGMENT vbuyy=vbuxx_bor_vbuc1 -txa -ora #{c1} -tay -//FRAGMENT _deref_pbuc1=vbuxx -stx {c1} -//FRAGMENT vbuaa=_deref_pbuz1 -ldy #0 -lda ({z1}),y -//FRAGMENT vbuxx=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tax -//FRAGMENT vbuyy=_deref_pbuz1 -ldy #0 -lda ({z1}),y -tay -//FRAGMENT 0_neq_vbuaa_then_la1 -cmp #0 -bne {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1 -ldy {z1} -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1 -ldx {z1} -ldy {c1},x -//FRAGMENT vbsaa=pbsc1_derefidx_vbuz1 -ldy {z1} -lda {c1},y -//FRAGMENT vbsxx=pbsc1_derefidx_vbuz1 -ldy {z1} -ldx {c1},y -//FRAGMENT vbsyy=pbsc1_derefidx_vbuz1 -ldx {z1} -ldy {c1},x -//FRAGMENT vbuxx=vbuxx_ror_2 -txa -lsr -lsr -tax -//FRAGMENT vbsxx=vbsxx_minus_vbsc1 -txa -sec -sbc #{c1} -tax -//FRAGMENT vbsxx_ge_0_then_la1 -cpx #0 -bpl {la1} -//FRAGMENT vbuxx_neq_0_then_la1 -cpx #0 -bne {la1} -//FRAGMENT vbuaa=vbuz1_rol_2 -lda {z1} -asl -asl -//FRAGMENT vbuyy=vbuz1_rol_2 -lda {z1} -asl -asl -tay -//FRAGMENT vbuz1=vbuaa_plus_vbuz2 -clc -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_plus_vbuz2 -txa -clc -adc {z2} -sta {z1} -//FRAGMENT vbuz1=vbuyy_plus_vbuz2 -tya -clc -adc {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -//FRAGMENT vbuaa=vbuaa_plus_vbuz1 -clc -adc {z1} -//FRAGMENT vbuaa=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -//FRAGMENT vbuaa=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -//FRAGMENT vbuxx=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -tax -//FRAGMENT vbuxx=vbuaa_plus_vbuz1 -clc -adc {z1} -tax -//FRAGMENT vbuxx=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -tax -//FRAGMENT vbuxx=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -tax -//FRAGMENT vbuyy=vbuz1_plus_vbuz2 -lda {z1} -clc -adc {z2} -tay -//FRAGMENT vbuyy=vbuaa_plus_vbuz1 -clc -adc {z1} -tay -//FRAGMENT vbuyy=vbuxx_plus_vbuz1 -txa -clc -adc {z1} -tay -//FRAGMENT vbuyy=vbuyy_plus_vbuz1 -tya -clc -adc {z1} -tay -//FRAGMENT vbuaa=_lo_vwuz1 -lda {z1} -//FRAGMENT vbuxx=_lo_vwuz1 -ldx {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -sta {z1} -//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuaa -tay -lda {c1},y -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx -lda {c1},x -//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy -lda {c1},y -//FRAGMENT vbuxx=pbuc1_derefidx_vbuaa -tay -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuaa -tax -ldy {c1},x -//FRAGMENT pbuz1=pbuz2_plus_pwuc1_derefidx_vbuaa -tay -clc -lda {z2} -adc {c1},y -sta {z1} -lda {z2}+1 -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_pwuc1_derefidx_vbuxx -clc -lda {z2} -adc {c1},x -sta {z1} -lda {z2}+1 -adc {c1}+1,x -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_pwuc1_derefidx_vbuyy -clc -lda {z2} -adc {c1},y -sta {z1} -lda {z2}+1 -adc {c1}+1,y -sta {z1}+1 -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_rol_1 -ldy {z1} -lda {c1},y -asl -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_rol_1 -ldx {z1} -lda {c1},x -asl -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_rol_1 -ldy {z1} -lda {c1},y -asl -tay -//FRAGMENT pbuz1=pbuz2_plus_vbuaa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vbuyy -tya -clc -adc {z2} -sta {z1} -lda #0 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT _deref_pbuc1_neq_pbuc2_derefidx_vbuaa_then_la1 -tay -lda {c1} -cmp {c2},y -bne {la1} -//FRAGMENT _deref_pbuc1_neq_pbuc2_derefidx_vbuxx_then_la1 -lda {c2},x -cmp {c1} -bne {la1} -//FRAGMENT _deref_pbuc1_neq_pbuc2_derefidx_vbuyy_then_la1 -lda {c1} -cmp {c2},y -bne {la1} -//FRAGMENT vbuaa_eq_0_then_la1 -cmp #0 -beq {la1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1_rol_4 -ldy {z1} -lda {c1},y -asl -asl -asl -asl -//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1_rol_4 -ldx {z1} -lda {c1},x -asl -asl -asl -asl -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1_rol_4 -ldy {z1} -lda {c1},y -asl -asl -asl -asl -tay -//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx_rol_4 -lda {c1},x -asl -asl -asl -asl -sta {z1} -//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx_rol_4 -lda {c1},x -asl -asl -asl -asl -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx_rol_4 -lda {c1},x -asl -asl -asl -asl -tax -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx_rol_4 -lda {c1},x -asl -asl -asl -asl -tay -//FRAGMENT vbuaa=vbuz1_bor_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -ora {c1},y -//FRAGMENT vbuxx=vbuz1_bor_pbuc1_derefidx_vbuz2 -lda {z1} -ldx {z2} -ora {c1},x -tax -//FRAGMENT vbuyy=vbuz1_bor_pbuc1_derefidx_vbuz2 -lda {z1} -ldy {z2} -ora {c1},y -tay -//FRAGMENT vbuz1=vbuaa_bor_pbuc1_derefidx_vbuz2 -ldy {z2} -ora {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuaa_bor_pbuc1_derefidx_vbuz1 -ldy {z1} -ora {c1},y -//FRAGMENT vbuxx=vbuaa_bor_pbuc1_derefidx_vbuz1 -ldx {z1} -ora {c1},x -tax -//FRAGMENT vbuyy=vbuaa_bor_pbuc1_derefidx_vbuz1 -ldy {z1} -ora {c1},y -tay -//FRAGMENT vbuz1=vbuxx_bor_pbuc1_derefidx_vbuz2 -ldy {z2} -txa -ora {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -ora {c1},y -//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuz1 -txa -ldx {z1} -ora {c1},x -tax -//FRAGMENT vbuyy=vbuxx_bor_pbuc1_derefidx_vbuz1 -ldy {z1} -txa -ora {c1},y -tay -//FRAGMENT vbuz1=vbuyy_bor_pbuc1_derefidx_vbuz2 -tya -ldy {z2} -ora {c1},y -sta {z1} -//FRAGMENT vbuaa=vbuyy_bor_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -ora {c1},y -//FRAGMENT vbuxx=vbuyy_bor_pbuc1_derefidx_vbuz1 -ldx {z1} -tya -ora {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuz1 -tya -ldy {z1} -ora {c1},y -tay -//FRAGMENT vbuz1=vbuz2_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ora {z1} -//FRAGMENT vbuxx=vbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ora {z1} -tax -//FRAGMENT vbuyy=vbuz1_bor_pbuc1_derefidx_vbuxx -lda {c1},x -ora {z1} -tay -//FRAGMENT vbuz1=vbuaa_bor_pbuc1_derefidx_vbuxx -ora {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuaa_bor_pbuc1_derefidx_vbuxx -ora {c1},x -//FRAGMENT vbuxx=vbuaa_bor_pbuc1_derefidx_vbuxx -ora {c1},x -tax -//FRAGMENT vbuyy=vbuaa_bor_pbuc1_derefidx_vbuxx -ora {c1},x -tay -//FRAGMENT vbuz1=vbuxx_bor_pbuc1_derefidx_vbuxx -txa -ora {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_pbuc1_derefidx_vbuxx -txa -ora {c1},x -//FRAGMENT vbuxx=vbuxx_bor_pbuc1_derefidx_vbuxx -txa -ora {c1},x -tax -//FRAGMENT vbuyy=vbuxx_bor_pbuc1_derefidx_vbuxx -txa -ora {c1},x -tay -//FRAGMENT vbuz1=vbuyy_bor_pbuc1_derefidx_vbuxx -tya -ora {c1},x -sta {z1} -//FRAGMENT vbuaa=vbuyy_bor_pbuc1_derefidx_vbuxx -tya -ora {c1},x -//FRAGMENT vbuxx=vbuyy_bor_pbuc1_derefidx_vbuxx -tya -ora {c1},x -tax -//FRAGMENT vbuyy=vbuyy_bor_pbuc1_derefidx_vbuxx -tya -ora {c1},x -tay -//FRAGMENT vbuxx=vbuxx_rol_vbuz1 -txa -ldx {z1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tax -//FRAGMENT vbuz1=vbuz1_rol_vbuaa -tay -lda {z1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuxx=vbuxx_rol_vbuaa -tay -txa -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tax -//FRAGMENT vbuz1=vbuz1_rol_vbuxx -lda {z1} -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -sta {z1} -//FRAGMENT vbuxx=vbuxx_rol_vbuxx -txa -tax -cpx #0 -beq !e+ -!: -asl -dex -bne !- -!e: -tax -//FRAGMENT vbuz1=vbuz1_rol_vbuyy -lda {z1} -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuxx=vbuxx_rol_vbuyy -txa -cpy #0 -beq !e+ -!: -asl -dey -bne !- -!e: -tax -//FRAGMENT vbuaa=_bnot__deref_pbuz1 -ldy #0 -lda ({z1}),y -eor #$ff -//FRAGMENT vbuxx=_bnot__deref_pbuz1 -ldy #0 -lda ({z1}),y -eor #$ff -tax -//FRAGMENT vbuyy=_bnot__deref_pbuz1 -ldy #0 -lda ({z1}),y -eor #$ff -tay -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuaa -and {c1} -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuxx -txa -and {c1} -sta {z1} -//FRAGMENT vbuz1=_deref_pbuc1_band_vbuyy -tya -and {c1} -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuz1 -lda {c1} -and {z1} -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuaa -and {c1} -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuxx -txa -and {c1} -//FRAGMENT vbuaa=_deref_pbuc1_band_vbuyy -tya -and {c1} -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuz1 -lda {c1} -and {z1} -tax -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuaa -and {c1} -tax -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuxx -txa -and {c1} -tax -//FRAGMENT vbuxx=_deref_pbuc1_band_vbuyy -tya -and {c1} -tax -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuz1 -lda {c1} -and {z1} -tay -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuaa -and {c1} -tay -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuxx -txa -and {c1} -tay -//FRAGMENT vbuyy=_deref_pbuc1_band_vbuyy -tya -and {c1} -tay -//FRAGMENT vbuz1=vbuaa_bor_vbuxx -stx $ff -ora $ff -sta {z1} -//FRAGMENT vbuaa=vbuaa_bor_vbuxx -stx $ff -ora $ff -//FRAGMENT vbuxx=vbuaa_bor_vbuxx -stx $ff -ora $ff -tax -//FRAGMENT vbuyy=vbuaa_bor_vbuxx -stx $ff -ora $ff -tay -//FRAGMENT vbuz1=vbuxx_bor_vbuz2 -txa -ora {z2} -sta {z1} -//FRAGMENT vbuz1=vbuxx_bor_vbuxx -stx {z1} -//FRAGMENT vbuxx=vbuz1_minus_1 -ldx {z1} -dex -//FRAGMENT vbuz1_le_vbuxx_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vwuz1=vbuaa_rol_vbuz2 -ldy {z2} -sta {z1} -lda #0 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=vbuxx_rol_vbuz2 -ldy {z2} -txa -sta {z1} -lda #0 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=vbuyy_rol_vbuz2 -tya -ldy {z2} -sta {z1} -lda #0 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuxx_lt_vbuz1_then_la1 -cpx {z1} -bcc {la1} -//FRAGMENT vbuxx_le_vbuz1_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx_lt_vwuz1_then_la1 -lda {z1}+1 -bne {la1} -cpx {z1} -bcc {la1} -//FRAGMENT vbuyy_lt_vwuz1_then_la1 -lda {z1}+1 -bne {la1} -cpy {z1} -bcc {la1} -//FRAGMENT vbuyy=_lo_pvoz1 -ldy {z1} -//FRAGMENT _deref_pbuc1=vbuyy -sty {c1} -//FRAGMENT vbuyy=_hi_pvoz1 -ldy {z1}+1 -//FRAGMENT vbuyy=_lo_vwuz1 -ldy {z1} -//FRAGMENT vbuyy=_hi_vwuz1 -ldy {z1}+1 -//FRAGMENT vbuyy=vbuz1 -ldy {z1} -//FRAGMENT vbuyy=_lo_pbuz1 -ldy {z1} -//FRAGMENT vbuz1=vbuyy -sty {z1} -//FRAGMENT 0_neq_vbuxx_then_la1 -cpx #0 -bne {la1} -//FRAGMENT 0_neq_vbuyy_then_la1 -cpy #0 -bne {la1} -//FRAGMENT vbuxx=vbuc1 -ldx #{c1} -//FRAGMENT vbuz1=vbuxx_minus_1 -dex -stx {z1} -//FRAGMENT vbuxx=_inc_vbuxx -inx -//FRAGMENT vbuaa=vbuxx_minus_1 -txa -sec -sbc #1 -//FRAGMENT vbuyy=vbuz1_minus_1 -lda {z1} -tay -dey -//FRAGMENT vbuyy=vbuxx_minus_1 -txa -tay -dey -//FRAGMENT vbuxx_eq_0_then_la1 -cpx #0 -beq {la1} -//FRAGMENT vbuyy_eq_0_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vbuyy=vbuc1 -ldy #{c1} -//FRAGMENT vbuyy=_inc_vbuyy -iny -//FRAGMENT vbuyy_neq_vbuc1_then_la1 -cpy #{c1} -bne {la1} -//FRAGMENT vbuxx=vbuxx_ror_1 -txa -lsr -tax -//FRAGMENT vbsxx=vbsxx_minus_1 -dex -//FRAGMENT vbsxx=vbsxx_minus_2 -dex -dex -//FRAGMENT vbuaa=vbuc1 -lda #{c1} -//FRAGMENT vbuxx=vbuyy -tya -tax -//FRAGMENT vbuaa=vbuxx -txa -//FRAGMENT vbuaa=vbuyy -tya -//FRAGMENT vbuyy=vbuxx -txa -tay -//FRAGMENT vbuxx=vbuaa -tax -//FRAGMENT vbuyy=vbuaa -tay -//FRAGMENT 0_eq_vbuxx_then_la1 -cpx #0 -beq {la1} -//FRAGMENT 0_eq_vbuyy_then_la1 -cpy #0 -beq {la1} -//FRAGMENT vbuxx=pbuc1_derefidx_vbuxx -lda {c1},x -tax -//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy -ldx {c1},y -//FRAGMENT vbuyy=pbuc1_derefidx_vbuxx -ldy {c1},x -//FRAGMENT vbuyy=pbuc1_derefidx_vbuyy -lda {c1},y -tay -//FRAGMENT pbuc1_derefidx_vbuxx=vbuaa -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=vbuaa -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=vbuxx -tay -txa -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuyy=vbuxx -txa -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuz1=vbuyy -tya -ldy {z1} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuaa=vbuyy -tax -tya -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuxx=vbuyy -tya -sta {c1},x -//FRAGMENT vbuz1=vbuyy_bor_vbuxx -txa -sty $ff -ora $ff -sta {z1} -//FRAGMENT vbuz1=vbuyy_bor_vbuaa -sty $ff -ora $ff -sta {z1} -//FRAGMENT vduz1=vduz1_ror_1 -lsr {z1}+3 -ror {z1}+2 -ror {z1}+1 -ror {z1} -//FRAGMENT vwuz1=vwuz1_bxor_vwuz2 -lda {z1} -eor {z2} -sta {z1} -lda {z1}+1 -eor {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_vbuz2 -ldy {z2} -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vbuz1=vbuz1_bor_vbuaa -ora {z1} -sta {z1} -//FRAGMENT pwuz1=pwuc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pduz1=pduc1_plus_vwuz1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz1_plus_vbuaa -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT pbuz1=pbuz2_plus_vwuz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vduz1=vbuc1 -lda #{c1} -sta {z1} -lda #0 -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT pbuc1_derefidx_vbuz1=pbuc1_derefidx_vbuz1_plus_1 -ldy {z1} -lda {c1},y -inc -sta {c1},y -//FRAGMENT vwuz1=vwuz1_plus_vwuc1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vbuz1=vbuz1_plus_2 -lda {z1} -clc -adc #2 -sta {z1} -//FRAGMENT vwuz1=_inc_vwuz2 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_band_vbuc1 -lda #{c1} -and {z2} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuz1=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -sta {z1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuz1 -lda {c1} -and {z1} -sta {c1} -//FRAGMENT vduz1=vwuc1 -NO_SYNTHESIS -//FRAGMENT pbuz1_neq_pbuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuc1=_deref_pbuz1 -ldy #0 -lda ({z1}),y -sta {c1} -//FRAGMENT vduz1=_deref_pduc1 -lda {c1} -sta {z1} -lda {c1}+1 -sta {z1}+1 -lda {c1}+2 -sta {z1}+2 -lda {c1}+3 -sta {z1}+3 -//FRAGMENT vwuz1=vwuc1_rol_vbuz2 -ldy {z2} -lda #<{c1} -sta {z1} -lda #>{c1}+1 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_plus_vwuz3 -lda {z2} -clc -adc {z3} -sta {z1} -lda {z2}+1 -adc {z3}+1 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vbuz3 -lda {z3} -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT pbuc1_derefidx_vbuaa=pbuc1_derefidx_vbuaa_plus_1 -tay -lda {c1},y -inc -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuxx=pbuc1_derefidx_vbuxx_plus_1 -lda {c1},x -inc -sta {c1},x -//FRAGMENT pbuc1_derefidx_vbuyy=pbuc1_derefidx_vbuyy_plus_1 -lda {c1},y -inc -sta {c1},y -//FRAGMENT vbuxx=vbuxx_plus_2 -inx -inx -//FRAGMENT vbuaa=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -//FRAGMENT vbuxx=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -tax -//FRAGMENT vbuyy=_bnot__deref_pbuc1 -lda {c1} -eor #$ff -tay -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuaa -and {c1} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuxx -txa -and {c1} -sta {c1} -//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuyy -tya -and {c1} -sta {c1} -//FRAGMENT pbuc1_derefidx_vbuaa=vbuc2 -tay -lda #{c2} -sta {c1},y -//FRAGMENT pbuc1_derefidx_vbuyy=vbuc2 -lda #{c2} -sta {c1},y -//FRAGMENT vbuaa_eq_vbuc1_then_la1 -cmp #{c1} -beq {la1} -//FRAGMENT vbuaa_neq_vbuc1_then_la1 -cmp #{c1} -bne {la1} -//FRAGMENT vwuz1=vwuc1_rol_vbuaa -tay -lda #<{c1} -sta {z1} -lda #>{c1}+1 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vwuz1=vwuc1_rol_vbuxx -lda #<{c1} -sta {z1} -lda #>{c1}+1 -sta {z1}+1 -cpx #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dex -bne !- -!e: -//FRAGMENT vwuz1=vwuc1_rol_vbuyy -lda #<{c1} -sta {z1} -lda #>{c1}+1 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vbuz1=vbuyy_bor_vbuz2 -tya -ora {z2} -sta {z1} -//FRAGMENT vbuaa=vbuxx_bor_vbuz1 -txa -ora {z1} -//FRAGMENT vbuaa=vbuyy_bor_vbuz1 -tya -ora {z1} -//FRAGMENT vbuxx=vbuxx_bor_vbuz1 -txa -ora {z1} -tax -//FRAGMENT vbuxx=vbuyy_bor_vbuz1 -tya -ora {z1} -tax -//FRAGMENT vbuyy=vbuxx_bor_vbuz1 -txa -ora {z1} -tay -//FRAGMENT vbuyy=vbuyy_bor_vbuz1 -tya -ora {z1} -tay -//FRAGMENT vwuz1=_word_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_rol_vbuxx -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -cpx #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dex -bne !- -!e: -//FRAGMENT vwuz1=vwuz2_rol_vbuyy -lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -cpy #0 -beq !e+ -!: -asl {z1} -rol {z1}+1 -dey -bne !- -!e: -//FRAGMENT vduz1=vduz2_plus_vbuaa -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vbuxx -txa -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_plus_vbuyy -tya -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vbuz1=vbuaa_bor_vbuc1 -ora #{c1} -sta {z1} -//FRAGMENT vbuxx=vbuaa_bor_vbuc1 -ora #{c1} -tax -//FRAGMENT vbuyy=vbuaa_bor_vbuc1 -ora #{c1} -tay -//FRAGMENT vbuz1=vbuyy_bor_vbuc1 -tya -ora #{c1} -sta {z1} -//FRAGMENT vbuaa=vbuyy_bor_vbuc1 -tya -ora #{c1} -//FRAGMENT vbuxx=vbuyy_bor_vbuc1 -tya -ora #{c1} -tax -//FRAGMENT vbuyy_neq_0_then_la1 -cpy #0 -bne {la1} -//FRAGMENT vbuyy=vbuyy_plus_2 -iny -iny -//FRAGMENT vbuaa=_inc_vbuaa -inc -//FRAGMENT vbuyy_lt_vbuz1_then_la1 -cpy {z1} -bcc {la1} -//FRAGMENT vbuyy=_deref_pbuc1 -ldy {c1} -//FRAGMENT vbuaa=vbuaa_bor_vbuyy -sty $ff -ora $ff -//FRAGMENT vbuz1=vbuaa_bor_vbuyy -sty $ff -ora $ff -sta {z1} -//FRAGMENT vbuyy_eq_vbuc1_then_la1 -cpy #{c1} -beq {la1} -//FRAGMENT vwuz1=vwuz1_band_vbuc1 -lda #{c1} -and {z1} -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vduz1=vduz1_plus_vbuaa -clc -adc {z1} -sta {z1} -lda {z1}+1 -adc #0 -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vbuz1=vbuaa_bor_vbuz1 -ora {z1} -sta {z1} -//FRAGMENT _deref_pssc1=_deref_pssc2_memcpy_vbuc3 -ldy #{c3} -!: -lda {c2}-1,y -sta {c1}-1,y -dey -bne !- -//FRAGMENT vduz1=vwsc1 -NO_SYNTHESIS -//FRAGMENT _deref_pwuc1=vbuc2 -lda #0 -sta {c1}+1 -lda #<{c2} -sta {c1} -//FRAGMENT vwuz1=vwuz2_bor_vbuz3 -lda {z3} -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_ror_5 -lda {z2}+1 -lsr -sta {z1}+1 -lda {z2} -ror -sta {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vwuz1=vwuz2_rol_3 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vbuz1=_byte_vwuz2 -lda {z2} -sta {z1} -//FRAGMENT vwuz1=vwuz2_band_vwuc1 -lda {z2} -and #<{c1} -sta {z1} -lda {z2}+1 -and #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1=pbuz2_plus_vwuc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT pbuz1_neq_vwuc1_then_la1 -lda {z1}+1 -cmp #>{c1} -bne {la1} -lda {z1} -cmp #<{c1} -bne {la1} -//FRAGMENT _deref_pbuz1=vbuc1 -lda #{c1} -ldy #0 -sta ({z1}),y -//FRAGMENT 0_neq__deref_pbuz1_then_la1 -ldy #0 -lda ({z1}),y -cmp #0 -bne {la1} -//FRAGMENT vwuz1=vwuz2_bor_vbuxx -txa -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=vwuz2_bor_vbuyy -tya -ora {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwuz1=_word_vbuaa -sta {z1} -lda #0 -sta {z1}+1 -//FRAGMENT vbuaa=_byte_vwuz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vwuz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vwuz1 -lda {z1} -tay -//FRAGMENT vduz1=vduz2_plus_vduz1 -lda {z1} -clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -lda {z1}+2 -adc {z2}+2 -sta {z1}+2 -lda {z1}+3 -adc {z2}+3 -sta {z1}+3 -//FRAGMENT pbuz1=pbuz1_plus_vwuc1 -clc -lda {z1} -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_rol_8 -lda {z1} -sta {z1}+1 -lda #0 -sta {z1} -//FRAGMENT vwuz1=vwuz1_bor_vbuxx -txa -ora {z1} -sta {z1} -//FRAGMENT vwuz1=vwuz1_rol_3 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -asl {z1} -rol {z1}+1 -//FRAGMENT vwuz1=vwuz1_band_vwuc1 -lda {z1} -and #<{c1} -sta {z1} -lda {z1}+1 -and #>{c1} -sta {z1}+1 -//FRAGMENT vwuz1=vwuz1_ror_5 -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -lsr {z1}+1 -ror {z1} -//FRAGMENT vbuz1=_deref_pbuc1_band__deref_pbuc2 -lda {c1} -and {c2} -sta {z1} -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT pbuz1=_inc_pbuz2 -clc -lda {z2} -adc #1 -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -//FRAGMENT vbuz1=pbuz2_derefidx_vbuz3 -ldy {z3} -lda ({z2}),y -sta {z1} -//FRAGMENT vbuz1_ge_vbuz2_then_la1 -lda {z1} -cmp {z2} -bcs {la1} -//FRAGMENT vbuz1=vbuz1_minus_vbuz2 -lda {z1} -sec -sbc {z2} -sta {z1} -//FRAGMENT vbuaa=_deref_pbuc1_band__deref_pbuc2 -lda {c1} -and {c2} -//FRAGMENT vbuxx=_deref_pbuc1_band__deref_pbuc2 -lda {c1} -and {c2} -tax -//FRAGMENT vbuyy=_deref_pbuc1_band__deref_pbuc2 -lda {c1} -and {c2} -tay -//FRAGMENT pbuc1_derefidx_vbuaa=vbuaa -tax -sta {c1},x -//FRAGMENT vbuz1_lt_vbuaa_then_la1 -cmp {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuaa -tay -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuxx -lda {c1},x -ldy #0 -sta ({z1}),y -//FRAGMENT _deref_pbuz1=pbuc1_derefidx_vbuyy -lda {c1},y -ldy #0 -sta ({z1}),y -//FRAGMENT vbuaa=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuz2 -ldy {z2} -lda ({z1}),y -tay -//FRAGMENT vbuz1=pbuz2_derefidx_vbuaa -tay -lda ({z2}),y -sta {z1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuaa -tay -lda ({z1}),y -tay -//FRAGMENT vbuz1=pbuz2_derefidx_vbuxx -txa -tay -lda ({z2}),y -sta {z1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuxx -txa -tay -lda ({z1}),y -tay -//FRAGMENT vbuz1=pbuz2_derefidx_vbuyy -lda ({z2}),y -sta {z1} -//FRAGMENT vbuaa=pbuz1_derefidx_vbuyy -lda ({z1}),y -//FRAGMENT vbuxx=pbuz1_derefidx_vbuyy -lda ({z1}),y -tax -//FRAGMENT vbuyy=pbuz1_derefidx_vbuyy -lda ({z1}),y -tay -//FRAGMENT vbuxx_ge_vbuz1_then_la1 -cpx {z1} -bcs {la1} -//FRAGMENT vbuaa_ge_vbuz1_then_la1 -cmp {z1} -bcs {la1} -//FRAGMENT vbuxx=vbuxx_minus_vbuz1 -txa -sec -sbc {z1} -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuaa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuaa -sta $ff -txa -sec -sbc $ff -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuxx -txa -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuxx -lda #0 -tax -//FRAGMENT vbuz1=vbuz1_minus_vbuyy -tya -eor #$ff -sec -adc {z1} -sta {z1} -//FRAGMENT vbuxx=vbuxx_minus_vbuyy -txa -sty $ff -sec -sbc $ff -tax -//FRAGMENT vbuz1_ge_vbuxx_then_la1 -lda {z1} -stx $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuz1_ge_vbuyy_then_la1 -lda {z1} -sty $ff -cmp $ff -bcs {la1} -//FRAGMENT vbuxx_ge_vbuyy_then_la1 -sty $ff -cpx $ff -bcs {la1} -//FRAGMENT vbuz1_lt_vbuxx_then_la1 -cpx {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT vbuz1_lt_vbuyy_then_la1 -cpy {z1} -beq !+ -bcs {la1} -!: -//FRAGMENT isr_rom_sys_cx16_entry - -//FRAGMENT vwuz1_neq_vbuc1_then_la1 -NO_SYNTHESIS -//FRAGMENT vbuz1_lt_vbuc1_then_la1 -lda {z1} -cmp #{c1} -bcc {la1} -//FRAGMENT isr_rom_sys_cx16_exit -jmp $e034 -//FRAGMENT _deref_pwuc1=_deref_pwuz1 -ldy #0 -lda ({z1}),y -sta {c1} -iny -lda ({z1}),y -sta {c1}+1 -//FRAGMENT pbuz1=pbuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1=vwuz1_plus_vbuc1 -lda #{c1} -clc -adc {z1} -sta {z1} -bcc !+ -inc {z1}+1 -!: -//FRAGMENT vwuz1_lt_vbuc1_then_la1 -lda {z1}+1 -bne !+ -lda {z1} -cmp #{c1} -bcc {la1} -!: -//FRAGMENT vwuz1=vwuz1_minus_vbuc1 -sec -lda {z1} -sbc #{c1} -sta {z1} -lda {z1}+1 -sbc #0 -sta {z1}+1 -//FRAGMENT _deref_qprc1=pprc2 -lda #<{c2} -sta {c1} -lda #>{c2} -sta {c1}+1 -//FRAGMENT _deref_pwuc1=_deref_pwuc1_plus_vbuc2 -NO_SYNTHESIS -//FRAGMENT _deref_pwuc1=_deref_pwuc1_plus_vbsc2 -NO_SYNTHESIS -//FRAGMENT _deref_pwuc1=_deref_pwuc1_plus_vwuc2 -lda #<{c2} -clc -adc {c1} -sta {c1} -lda #>{c2} -adc {c1}+1 -sta {c1}+1 -//FRAGMENT pbuz1_neq_pbuz2_then_la1 -lda {z1}+1 -cmp {z2}+1 -bne {la1} -lda {z1} -cmp {z2} -bne {la1} -//FRAGMENT vbuaa_lt_vbuc1_then_la1 -cmp #{c1} -bcc {la1} -//FRAGMENT vbuxx_lt_vbuc1_then_la1 -cpx #{c1} -bcc {la1} //FRAGMENT vbuz1=vbuz2_plus_1 lda {z2} inc sta {z1} +//FRAGMENT _deref_pbuc1=vbuz1 +lda {z1} +sta {c1} +//FRAGMENT vbuaa=_deref_pbuc1 +lda {c1} +//FRAGMENT vbuxx=_deref_pbuc1 +ldx {c1} //FRAGMENT vbuz1=vbuaa_plus_1 inc sta {z1} //FRAGMENT vbuz1=vbuxx_plus_1 inx stx {z1} +//FRAGMENT _deref_pbuc1=vbuaa +sta {c1} +//FRAGMENT vbuyy=_deref_pbuc1 +ldy {c1} //FRAGMENT vbuz1=vbuyy_plus_1 iny sty {z1} @@ -3419,6 +40,8 @@ inc //FRAGMENT vbuxx=vbuz1_plus_1 ldx {z1} inx +//FRAGMENT _deref_pbuc1=vbuxx +stx {c1} //FRAGMENT vbuxx=vbuaa_plus_1 tax inx @@ -3431,6 +54,8 @@ tax //FRAGMENT vbuyy=vbuz1_plus_1 ldy {z1} iny +//FRAGMENT _deref_pbuc1=vbuyy +sty {c1} //FRAGMENT vbuyy=vbuaa_plus_1 tay iny @@ -3440,566 +65,66 @@ inc tay //FRAGMENT vbuyy=vbuyy_plus_1 iny -//FRAGMENT vwsz1=vwsc1 +//FRAGMENT pbuz1=pbuc1 lda #<{c1} sta {z1} lda #>{c1} sta {z1}+1 -//FRAGMENT vwsz1=vwsz1_plus_vwsz2 -lda {z1} +//FRAGMENT vbuz1=vbuc1 +lda #{c1} +sta {z1} +//FRAGMENT 0_neq_pbuc1_derefidx_vbuz1_then_la1 +ldy {z1} +lda {c1},y +cmp #0 +bne {la1} +//FRAGMENT pbuz1=pbuz2 +lda {z2} +sta {z1} +lda {z2}+1 +sta {z1}+1 +//FRAGMENT vbuz1=pbuc1_derefidx_vbuz2 +ldy {z2} +lda {c1},y +sta {z1} +//FRAGMENT pbuz1=_inc_pbuz2 clc -adc {z2} -sta {z1} -lda {z1}+1 -adc {z2}+1 -sta {z1}+1 -//FRAGMENT vwsz1_le_vwsc1_then_la1 -lda #<{c1} -cmp {z1} -lda #>{c1} -sbc {z1}+1 -bvc !+ -eor #$80 -!: -bpl {la1} -//FRAGMENT vwsz1=vbsc1 -lda #<{c1} -sta {z1} -lda #>{c1} -sta {z1}+1 -//FRAGMENT vwsz1=vwsz2 lda {z2} -sta {z1} -lda {z2}+1 -sta {z1}+1 -//FRAGMENT vwsz1=_neg_vwsz2 -sec -lda #0 -sbc {z2} -sta {z1} -lda #0 -sbc {z2}+1 -sta {z1}+1 -//FRAGMENT vwsz1_ge_0_then_la1 -lda {z1}+1 -bpl {la1} -//FRAGMENT _deref_(_deref_qbuc1)=vbuz1 -lda {z1} -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT vbuz1=_deref_(_deref_qbuc1) -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -lda ($fe),y -sta {z1} -//FRAGMENT vduz1=_dword_vbuz2 -lda {z2} -sta {z1} -lda #0 -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_band_vbuc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz2_band_vwuc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz2_band_vwsc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz2_band_vduc1 -lda {z2} -and #<{c1} -sta {z1} -lda {z2}+1 -and #>{c1} -sta {z1}+1 -lda {z2}+2 -and #<{c1}>>$10 -sta {z1}+2 -lda {z2}+3 -and #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_8 -lda #0 -sta {z1} -lda {z2} -sta {z1}+1 -lda {z2}+1 -sta {z1}+2 -lda {z2}+2 -sta {z1}+3 -//FRAGMENT vduz1=vduz2_rol_1 -lda {z2} -asl -sta {z1} -lda {z2}+1 -rol -sta {z1}+1 -lda {z2}+2 -rol -sta {z1}+2 -lda {z2}+3 -rol -sta {z1}+3 -//FRAGMENT vbuz1=vbuz2_ror_vbuz3 -lda {z2} -ldy {z3} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuz1=_dec_vbuz1 -dec {z1} -//FRAGMENT vduz1=vduz1_plus_vbuc1 -lda {z1} -clc -adc #{c1} -sta {z1} -bcc !+ -inc {z1}+1 -bne !+ -inc {z1}+2 -bne !+ -inc {z1}+3 -!: -//FRAGMENT vduz1=vduz1_plus_1 -lda {z1} -clc adc #1 sta {z1} -lda {z1}+1 +lda {z2}+1 adc #0 sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT _deref_(_deref_qbuc1)=vbuaa -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=vbuxx -txa -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT _deref_(_deref_qbuc1)=vbuyy -tya -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -sta ($fe),y -//FRAGMENT vbuaa=_deref_(_deref_qbuc1) -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -lda ($fe),y -//FRAGMENT vbuxx=_deref_(_deref_qbuc1) -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -lda ($fe),y -tax -//FRAGMENT vbuyy=_deref_(_deref_qbuc1) -ldy {c1} -sty $fe -ldy {c1}+1 -sty $ff -ldy #0 -lda ($fe),y -tay -//FRAGMENT vduz1=_dword_vbuaa -sta {z1} -lda #0 -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vduz1=_dword_vbuxx -txa -sta {z1} -lda #0 -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vduz1=_dword_vbuyy -tya -sta {z1} -lda #0 -sta {z1}+1 -sta {z1}+2 -sta {z1}+3 -//FRAGMENT vbuaa=vbuz1_ror_vbuz2 -lda {z1} -ldy {z2} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuz1_ror_vbuz2 -lda {z1} -ldx {z2} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuz1_ror_vbuz2 -lda {z1} -ldy {z2} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuz2_ror_vbuaa -tay -lda {z2} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_vbuaa -tay -lda {z1} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuz1_ror_vbuaa -tax -lda {z1} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuz1_ror_vbuaa -tay -lda {z1} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuz2_ror_vbuxx -lda {z2} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -//FRAGMENT vbuxx=vbuz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuz1_ror_vbuxx -lda {z1} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuz2_ror_vbuyy -lda {z2} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuz1_ror_vbuyy -lda {z1} -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuxx_ror_vbuz2 -ldy {z2} -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_vbuz1 -ldy {z1} -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuxx_ror_vbuz1 -txa -ldx {z1} -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuxx_ror_vbuz1 -ldy {z1} -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuxx_ror_vbuaa -tay -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuxx_ror_vbuxx -txa -tay -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_vbuxx -txa -tay -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuxx_ror_vbuxx -txa -tax -cpx #0 -beq !e+ -!: -lsr -dex -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuxx_ror_vbuxx -txa -tay -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vbuz1=vbuxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -sta {z1} -//FRAGMENT vbuaa=vbuxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -//FRAGMENT vbuxx=vbuxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tax -//FRAGMENT vbuyy=vbuxx_ror_vbuyy -txa -cpy #0 -beq !e+ -!: -lsr -dey -bne !- -!e: -tay -//FRAGMENT vduz1=vduz1_band_vbuc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz1_band_vwuc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz1_band_vwsc1 -NO_SYNTHESIS -//FRAGMENT vduz1=vduz1_band_vduc1 -lda {z1} -and #<{c1} -sta {z1} +//FRAGMENT vbuz1=_inc_vbuz1 +inc {z1} +//FRAGMENT _deref_pbuc1=_deref_pbuc1_band_vbuc2 +lda #{c2} +and {c1} +sta {c1} +//FRAGMENT _deref_pbuc1=vbuc2 +lda #{c2} +sta {c1} +//FRAGMENT pbuz1_neq_pbuc1_then_la1 lda {z1}+1 -and #>{c1} -sta {z1}+1 -lda {z1}+2 -and #<{c1}>>$10 -sta {z1}+2 -lda {z1}+3 -and #>{c1}>>$10 -sta {z1}+3 -//FRAGMENT vduz1=vduz1_rol_8 -lda {z1}+2 -sta {z1}+3 -lda {z1}+1 -sta {z1}+2 +cmp #>{c1} +bne {la1} lda {z1} -sta {z1}+1 -lda #0 +cmp #<{c1} +bne {la1} +//FRAGMENT _deref_pbuc1=_deref_pbuz1 +ldy #0 +lda ({z1}),y +sta {c1} +//FRAGMENT pbuz1=_inc_pbuz1 +inc {z1} +bne !+ +inc {z1}+1 +!: +//FRAGMENT vbuz1=_lo_pbuz2 +lda {z2} +sta {z1} +//FRAGMENT vbuz1=_hi_pbuz2 +lda {z2}+1 sta {z1} //FRAGMENT 0_neq_pbuc1_derefidx_vbuaa_then_la1 tay @@ -4014,193 +139,71 @@ bne {la1} lda {c1},y cmp #0 bne {la1} -//FRAGMENT vbuyy=_hi_pbuz1 -ldy {z1}+1 -//FRAGMENT vduz1_lt_vduc1_then_la1 -lda {z1}+3 -cmp #>{c1}>>$10 -bcc {la1} -bne !+ -lda {z1}+2 -cmp #<{c1}>>$10 -bcc {la1} -bne !+ -lda {z1}+1 -cmp #>{c1} -bcc {la1} -bne !+ -lda {z1} -cmp #<{c1} -bcc {la1} -!: -//FRAGMENT vduz1=vduz2_plus_vbuc1 -lda #{c1} -clc -adc {z2} -sta {z1} -lda {z2}+1 -adc #0 -sta {z1}+1 -lda {z2}+2 -adc #0 -sta {z1}+2 -lda {z2}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vwuz1=vwuz2_plus_vwuc1 -clc -lda {z2} -adc #<{c1} -sta {z1} -lda {z2}+1 -adc #>{c1} -sta {z1}+1 -//FRAGMENT vduz1=vduz1_plus_vwuc1 -lda {z1} -clc -adc #<{c1} -sta {z1} -lda {z1}+1 -adc #>{c1} -sta {z1}+1 -lda {z1}+2 -adc #0 -sta {z1}+2 -lda {z1}+3 -adc #0 -sta {z1}+3 -//FRAGMENT vbuz1=_byte_vduz2 -lda {z2} -sta {z1} -//FRAGMENT vduz1=pduc1_derefidx_vbuz2 -ldy {z2} -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1_ge_vduz2_then_la1 -lda {z1}+3 -cmp {z2}+3 -bcc !+ -bne {la1} -lda {z1}+2 -cmp {z2}+2 -bcc !+ -bne {la1} -lda {z1}+1 -cmp {z2}+1 -bcc !+ -bne {la1} -lda {z1} -cmp {z2} -bcs {la1} -!: -//FRAGMENT vduz1=vduz1_minus_vduz2 -lda {z1} -sec -sbc {z2} -sta {z1} -lda {z1}+1 -sbc {z2}+1 -sta {z1}+1 -lda {z1}+2 -sbc {z2}+2 -sta {z1}+2 -lda {z1}+3 -sbc {z2}+3 -sta {z1}+3 -//FRAGMENT vbuaa=_byte_vduz1 -lda {z1} -//FRAGMENT vbuxx=_byte_vduz1 -lda {z1} -tax -//FRAGMENT vbuyy=_byte_vduz1 -lda {z1} -tay -//FRAGMENT vbuz1=vbuaa_rol_2 -asl -asl -sta {z1} -//FRAGMENT vbuz1=vbuyy_rol_2 -tya -asl -asl -sta {z1} -//FRAGMENT vbuaa=vbuaa_rol_2 -asl -asl -//FRAGMENT vbuaa=vbuxx_rol_2 -txa -asl -asl -//FRAGMENT vbuaa=vbuyy_rol_2 -tya -asl -asl -//FRAGMENT vbuxx=vbuaa_rol_2 -asl -asl -tax -//FRAGMENT vbuxx=vbuyy_rol_2 -tya -asl -asl -tax -//FRAGMENT vbuyy=vbuaa_rol_2 -asl -asl -tay -//FRAGMENT vbuyy=vbuxx_rol_2 -txa -asl -asl -tay -//FRAGMENT vbuyy=vbuyy_rol_2 -tya -asl -asl -tay -//FRAGMENT vduz1=pduc1_derefidx_vbuaa -tay -lda {c1},y -sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuxx +//FRAGMENT vbuz1=pbuc1_derefidx_vbuxx lda {c1},x sta {z1} -lda {c1}+1,x -sta {z1}+1 -lda {c1}+2,x -sta {z1}+2 -lda {c1}+3,x -sta {z1}+3 -//FRAGMENT vduz1=pduc1_derefidx_vbuyy +//FRAGMENT vbuz1=pbuc1_derefidx_vbuyy lda {c1},y sta {z1} -lda {c1}+1,y -sta {z1}+1 -lda {c1}+2,y -sta {z1}+2 -lda {c1}+3,y -sta {z1}+3 -//FRAGMENT vbuyy_ge_vbuz1_then_la1 -cpy {z1} -bcs {la1} +//FRAGMENT vbuaa=pbuc1_derefidx_vbuz1 +ldy {z1} +lda {c1},y +//FRAGMENT vbuaa=pbuc1_derefidx_vbuxx +lda {c1},x +//FRAGMENT vbuaa=pbuc1_derefidx_vbuyy +lda {c1},y +//FRAGMENT vbuxx=pbuc1_derefidx_vbuz1 +ldy {z1} +ldx {c1},y +//FRAGMENT vbuaa=_lo_pbuz1 +lda {z1} +//FRAGMENT vbuxx=_lo_pbuz1 +ldx {z1} +//FRAGMENT vbuaa=_hi_pbuz1 +lda {z1}+1 +//FRAGMENT vbuxx=_hi_pbuz1 +ldx {z1}+1 +//FRAGMENT vbuyy=_lo_pbuz1 +ldy {z1} +//FRAGMENT vbuyy=_hi_pbuz1 +ldy {z1}+1 +//FRAGMENT vbuxx=vbuc1 +ldx #{c1} +//FRAGMENT vbuyy=pbuc1_derefidx_vbuz1 +ldx {z1} +ldy {c1},x +//FRAGMENT vbuyy=vbuc1 +ldy #{c1} +//FRAGMENT vbuxx=pbuc1_derefidx_vbuyy +ldx {c1},y +//FRAGMENT vbuyy=_inc_vbuyy +iny //FRAGMENT isr_rom_min_cx16_entry +//FRAGMENT _deref_pbuc1=_deref_pbuc1_bor_vbuc2 +lda #{c2} +ora {c1} +sta {c1} +//FRAGMENT vbuz1_neq_vbuc1_then_la1 +lda #{c1} +cmp {z1} +bne {la1} +//FRAGMENT vbuz1=_dec_vbuz1 +dec {z1} +//FRAGMENT vbuz1_neq_0_then_la1 +lda {z1} +bne {la1} //FRAGMENT vbuz1_ge_vbuc1_then_la1 lda {z1} cmp #{c1} bcs {la1} +//FRAGMENT vbuz1=vbuz2 +lda {z2} +sta {z1} +//FRAGMENT vbuz1_lt_vbuc1_then_la1 +lda {z1} +cmp #{c1} +bcc {la1} //FRAGMENT isr_rom_min_cx16_exit jmp $e049 //FRAGMENT pbuz1=pbuc1_plus_pbuc2_derefidx_vbuz2 @@ -4225,6 +228,25 @@ sta ({z1}),y ldy {z1} lda {c2},y sta {c1} +//FRAGMENT _deref_qprc1=pprc2 +lda #<{c2} +sta {c1} +lda #>{c2} +sta {c1}+1 +//FRAGMENT _deref_pbuz1=vbuc1 +lda #{c1} +ldy #0 +sta ({z1}),y +//FRAGMENT vbuaa_neq_vbuc1_then_la1 +cmp #{c1} +bne {la1} +//FRAGMENT vbuaa=vbuz1 +lda {z1} +//FRAGMENT vbuxx=vbuz1 +ldx {z1} +//FRAGMENT vbuaa_lt_vbuc1_then_la1 +cmp #{c1} +bcc {la1} //FRAGMENT pbuz1=pbuc1_plus_pbuc2_derefidx_vbuaa tay lda {c2},y @@ -4282,6 +304,21 @@ sta {c1} //FRAGMENT _deref_pbuc1=pbuc2_derefidx_vbuyy lda {c2},y sta {c1} +//FRAGMENT vbuxx_neq_vbuc1_then_la1 +cpx #{c1} +bne {la1} +//FRAGMENT vbuxx_lt_vbuc1_then_la1 +cpx #{c1} +bcc {la1} +//FRAGMENT vbuxx=_inc_vbuxx +inx //FRAGMENT vbuyy_lt_vbuc1_then_la1 cpy #{c1} bcc {la1} +//FRAGMENT vbuaa=vbuc1 +lda #{c1} +//FRAGMENT vbuaa=_inc_vbuaa +inc +//FRAGMENT vbuyy_neq_vbuc1_then_la1 +cpy #{c1} +bne {la1} diff --git a/src/main/java/dk/camelot64/kickc/model/VariableBuilder.java b/src/main/java/dk/camelot64/kickc/model/VariableBuilder.java index e1004e78d..67b9c7c2c 100644 --- a/src/main/java/dk/camelot64/kickc/model/VariableBuilder.java +++ b/src/main/java/dk/camelot64/kickc/model/VariableBuilder.java @@ -54,13 +54,20 @@ public class VariableBuilder { * @return The variable */ public Variable build() { - Variable variable = new Variable(varName, getKind(), type, scope, getMemoryArea(), dataSegment, null); + + // Todo: move to type parsing! + SymbolType typeQualified = type.getQualified(this.isVolatile(), this.isNoModify()); + + Variable variable = new Variable(varName, getKind(), typeQualified, scope, getMemoryArea(), dataSegment, null); + + // Todo: remove! variable.setNoModify(this.isNoModify()); variable.setVolatile(this.isVolatile()); - variable.setExport(this.isExport()); - variable.setPermanent(this.isPermanent()); variable.setToNoModify(this.isToNoModify()); variable.setToVolatile(this.isToVolatile()); + + variable.setExport(this.isExport()); + variable.setPermanent(this.isPermanent()); variable.setOptimize(this.isOptimize()); variable.setRegister(this.getRegister()); if(variable.getRegister() instanceof Registers.RegisterMainMem) { diff --git a/src/main/java/dk/camelot64/kickc/model/symbols/Variable.java b/src/main/java/dk/camelot64/kickc/model/symbols/Variable.java index 51ebb2405..b33327433 100644 --- a/src/main/java/dk/camelot64/kickc/model/symbols/Variable.java +++ b/src/main/java/dk/camelot64/kickc/model/symbols/Variable.java @@ -193,11 +193,14 @@ public class Variable implements Symbol { version.setMemoryAlignment(phiMaster.getMemoryAlignment()); version.setMemoryAddress(phiMaster.getMemoryAddress()); version.setOptimize(phiMaster.isOptimize()); - version.setNoModify(phiMaster.isNoModify()); - version.setRegister(phiMaster.getRegister()); + + // TODO: remove version.setVolatile(phiMaster.isVolatile()); + version.setNoModify(phiMaster.isNoModify()); version.setToNoModify(phiMaster.isToNoModify()); version.setToVolatile(phiMaster.isToVolatile()); + + version.setRegister(phiMaster.getRegister()); version.setPermanent(phiMaster.isPermanent()); version.setExport(phiMaster.isExport()); version.setComments(phiMaster.getComments()); @@ -239,11 +242,13 @@ public class Variable implements Symbol { constVar.setMemoryAlignment(variable.getMemoryAlignment()); constVar.setMemoryAddress(variable.getMemoryAddress()); constVar.setOptimize(variable.isOptimize()); - constVar.setNoModify(variable.isNoModify()); constVar.setRegister(variable.getRegister()); + // Todo: remove constVar.setVolatile(variable.isVolatile()); + constVar.setNoModify(variable.isNoModify()); constVar.setToNoModify(variable.isToNoModify()); constVar.setToVolatile(variable.isToVolatile()); + constVar.setPermanent(variable.isPermanent()); constVar.setExport(variable.isExport()); constVar.setComments(variable.getComments()); @@ -262,11 +267,14 @@ public class Variable implements Symbol { copy.setMemoryAlignment(original.getMemoryAlignment()); copy.setMemoryAddress(original.getMemoryAddress()); copy.setOptimize(original.isOptimize()); - copy.setNoModify(original.isNoModify()); copy.setPermanent(original.isPermanent()); + + // Todo: remove copy.setVolatile(original.isVolatile()); + copy.setNoModify(original.isNoModify()); copy.setToNoModify(original.isToNoModify()); copy.setToVolatile(original.isToVolatile()); + copy.setExport(original.isExport()); copy.setRegister(original.getRegister()); copy.setComments(original.getComments()); @@ -288,18 +296,24 @@ public class Variable implements Symbol { if(isParameter && memberDefinition.isArray()) { // Array struct members are converted to pointers when unwound (use same kind as the struct variable) SymbolTypePointer arrayType = (SymbolTypePointer) memberDefinition.getType(); - memberVariable = new Variable(name, structVar.getKind(), new SymbolTypePointer(arrayType.getElementType()), structVar.getScope(), memoryArea, structVar.getDataSegment(), null); + SymbolType typeQualified = new SymbolTypePointer(arrayType.getElementType()).getQualified(structVar.isVolatile, structVar.isNoModify()); + memberVariable = new Variable(name, structVar.getKind(), typeQualified, structVar.getScope(), memoryArea, structVar.getDataSegment(), null); } else if(memberDefinition.isKindConstant()) { // Constant members are unwound as constants - memberVariable = new Variable(name, Kind.CONSTANT, memberDefinition.getType(), structVar.getScope(), memoryArea, structVar.getDataSegment(), memberDefinition.getInitValue()); + SymbolType typeQualified = memberDefinition.getType().getQualified(structVar.isVolatile, structVar.isNoModify()); + memberVariable = new Variable(name, Kind.CONSTANT, typeQualified, structVar.getScope(), memoryArea, structVar.getDataSegment(), memberDefinition.getInitValue()); } else { // For others the kind is preserved from the member definition - memberVariable = new Variable(name, structVar.getKind(), memberDefinition.getType(), structVar.getScope(), memoryArea, structVar.getDataSegment(), memberDefinition.getInitValue()); + SymbolType typeQualified = memberDefinition.getType().getQualified(structVar.isVolatile, structVar.isNoModify()); + memberVariable = new Variable(name, structVar.getKind(),typeQualified, structVar.getScope(), memoryArea, structVar.getDataSegment(), memberDefinition.getInitValue()); } + + // Todo: fix struct member qualifiers - and remove! memberVariable.setVolatile(structVar.isVolatile()); memberVariable.setNoModify(structVar.isNoModify()); memberVariable.setToNoModify(structVar.isToNoModify()); memberVariable.setToVolatile(structVar.isToVolatile()); + memberVariable.setExport(structVar.isExport()); memberVariable.setPermanent(structVar.isPermanent()); return memberVariable; diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolType.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolType.java index cabdd4966..9cdce4c17 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolType.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolType.java @@ -11,6 +11,14 @@ public interface SymbolType extends Serializable { /** Specifies that the variable is not allowed to be modified (const keyword). The compiler should try to detect modifications and generate compile-time errors if they occur.*/ boolean isNomodify(); + /** Get the type with different type qualifiers. + * + * @param isVolatile Should the type be marked as volatile + * @param isNomodify Should the type be marked as nomodify (keyword const) + * @return The type with different qualifiers + */ + SymbolType getQualified(boolean isVolatile, boolean isNomodify); + /** Unsigned byte (8 bits)). */ SymbolTypeIntegerFixed BYTE = new SymbolTypeIntegerFixed("byte", 0, 255, false, 8, false, false); /** Signed byte (8 bits). */ diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeBlockScope.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeBlockScope.java index 476b28041..e60c2107a 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeBlockScope.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeBlockScope.java @@ -4,12 +4,11 @@ package dk.camelot64.kickc.model.types; public class SymbolTypeBlockScope implements SymbolType { public SymbolTypeBlockScope() { - } @Override - public String getTypeName() { - return "BLOCK"; + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return this; } @Override @@ -22,6 +21,11 @@ public class SymbolTypeBlockScope implements SymbolType { return false; } + @Override + public String getTypeName() { + return "BLOCK"; + } + @Override public int getSizeBytes() { return -1; diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeEnum.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeEnum.java index f321bc604..baafd7d4b 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeEnum.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeEnum.java @@ -8,7 +8,7 @@ import java.util.Objects; public class SymbolTypeEnum implements SymbolType { /** Name of the enum type. */ - private String name; + private String enumName; /** The enum definition. */ private EnumDefinition definition; @@ -18,11 +18,16 @@ public class SymbolTypeEnum implements SymbolType { public SymbolTypeEnum(EnumDefinition definition, boolean isVolatile, boolean isNomodify) { this.definition = definition; - this.name = definition.getLocalName(); + this.enumName = definition.getLocalName(); this.isVolatile = isVolatile; this.isNomodify = isNomodify; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return new SymbolTypeEnum(this.definition, isVolatile, isNomodify); + } + @Override public boolean isVolatile() { return isVolatile; @@ -35,7 +40,15 @@ public class SymbolTypeEnum implements SymbolType { @Override public String getTypeName() { - return "enum " + name; + String name = ""; + /* + if(isVolatile) + name += "volatile "; + if(isNomodify) + name += "const "; + */ + name += "enum " + this.enumName; + return name; } @Override @@ -57,12 +70,12 @@ public class SymbolTypeEnum implements SymbolType { if(this == o) return true; if(o == null || getClass() != o.getClass()) return false; SymbolTypeEnum that = (SymbolTypeEnum) o; - return Objects.equals(name, that.name); + return Objects.equals(enumName, that.enumName); } @Override public int hashCode() { - return Objects.hash(name); + return Objects.hash(enumName); } } diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerAuto.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerAuto.java index 99cc35d95..f0ffa83df 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerAuto.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerAuto.java @@ -11,6 +11,11 @@ public class SymbolTypeIntegerAuto implements SymbolTypeInteger { this.typeName = typeName; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return this; + } + @Override public boolean isVolatile() { return false; diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerFixed.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerFixed.java index 0088f6010..c349a310d 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerFixed.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeIntegerFixed.java @@ -7,16 +7,19 @@ import java.util.Objects; /** Integer type with a fixed size (byte, signed byte, word, ...). */ public class SymbolTypeIntegerFixed implements SymbolTypeInteger { - private final String typeName; + /** The basename of the the type (without any qualifiers). */ + private final String typeBaseName; + private final long minValue; private final long maxValue; private final boolean signed; private final int bits; + private final boolean isVolatile; private final boolean isNomodify; - SymbolTypeIntegerFixed(String typeName, long minValue, long maxValue, boolean signed, int bits, boolean isVolatile, boolean isNomodify) { - this.typeName = typeName; + SymbolTypeIntegerFixed(String typeBaseName, long minValue, long maxValue, boolean signed, int bits, boolean isVolatile, boolean isNomodify) { + this.typeBaseName = typeBaseName; this.minValue = minValue; this.maxValue = maxValue; this.signed = signed; @@ -25,10 +28,15 @@ public class SymbolTypeIntegerFixed implements SymbolTypeInteger { this.isNomodify = isNomodify; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return new SymbolTypeIntegerFixed(this.typeBaseName, this.minValue, this.maxValue, this.signed, this.bits, isVolatile, isNomodify); + } + /** - * Get all fixed size integer types. + * Get all (unqualified) fixed size integer types. * - * @return All fixed size integer types + * @return All (unqualified) fixed size integer types */ public static Collection getIntegerFixedTypes() { ArrayList types = new ArrayList<>(); @@ -88,7 +96,15 @@ public class SymbolTypeIntegerFixed implements SymbolTypeInteger { @Override public String getTypeName() { - return typeName; + String name = ""; + /* + if(isVolatile) + name += "volatile "; + if(isNomodify) + name += "const "; + */ + name += typeBaseName; + return name; } public long getMinValue() { @@ -122,11 +138,11 @@ public class SymbolTypeIntegerFixed implements SymbolTypeInteger { if(this == o) return true; if(o == null || getClass() != o.getClass()) return false; SymbolTypeIntegerFixed that = (SymbolTypeIntegerFixed) o; - return Objects.equals(typeName, that.typeName); + return Objects.equals(typeBaseName, that.typeBaseName); } @Override public int hashCode() { - return Objects.hash(typeName); + return Objects.hash(typeBaseName); } } diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeNamed.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeNamed.java index e04caff74..e05fa4e83 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeNamed.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeNamed.java @@ -3,18 +3,23 @@ package dk.camelot64.kickc.model.types; /** Basic named (string, char, ...) Symbol Types */ public class SymbolTypeNamed implements SymbolType { - private String typeName; + private String typeBaseName; private int sizeBytes; private final boolean isVolatile; private final boolean isNomodify; - SymbolTypeNamed(String typeName, int sizeBytes, boolean isVolatile, boolean isNomodify) { - this.typeName = typeName; + SymbolTypeNamed(String typeBaseName, int sizeBytes, boolean isVolatile, boolean isNomodify) { + this.typeBaseName = typeBaseName; this.sizeBytes = sizeBytes; this.isVolatile = isVolatile; this.isNomodify = isNomodify; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return new SymbolTypeNamed(this.typeBaseName, this.sizeBytes, isVolatile, isNomodify); + } + @Override public boolean isVolatile() { return isVolatile; @@ -26,7 +31,15 @@ public class SymbolTypeNamed implements SymbolType { } public String getTypeName() { - return typeName; + String name = ""; + /* + if(isVolatile) + name += "volatile "; + if(isNomodify) + name += "const "; + */ + name += typeBaseName; + return name; } @Override @@ -45,12 +58,12 @@ public class SymbolTypeNamed implements SymbolType { SymbolTypeNamed that = (SymbolTypeNamed) o; - return typeName != null ? typeName.equals(that.typeName) : that.typeName == null; + return typeBaseName != null ? typeBaseName.equals(that.typeBaseName) : that.typeBaseName == null; } @Override public int hashCode() { - return typeName != null ? typeName.hashCode() : 0; + return typeBaseName != null ? typeBaseName.hashCode() : 0; } @Override diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypePointer.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypePointer.java index bdb916c87..5e0e1210d 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypePointer.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypePointer.java @@ -18,7 +18,6 @@ public class SymbolTypePointer implements SymbolType { private final boolean isVolatile; private final boolean isNomodify; - public SymbolTypePointer(SymbolType elementType, ArraySpec arraySpec, boolean isVolatile, boolean isNomodify) { this.elementType = elementType; this.arraySpec = arraySpec; @@ -30,14 +29,19 @@ public class SymbolTypePointer implements SymbolType { this(elementType, null, false, false); } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return new SymbolTypePointer(this.elementType, this.arraySpec, isVolatile, isNomodify); + } + @Override public boolean isVolatile() { - return false; + return isVolatile; } @Override public boolean isNomodify() { - return false; + return isNomodify; } public SymbolType getElementType() { @@ -54,7 +58,14 @@ public class SymbolTypePointer implements SymbolType { @Override public String getTypeName() { - return elementType.getTypeName() + "*"; + String name = elementType.getTypeName() + "*"; + /* + if(isVolatile) + name += " volatile"; + if(isNomodify) + name += " const"; + */ + return name; } @Override diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProcedure.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProcedure.java index 552bedda8..a735380b2 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProcedure.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProcedure.java @@ -11,6 +11,11 @@ public class SymbolTypeProcedure implements SymbolType { this.returnType = returnType; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return this; + } + @Override public boolean isVolatile() { return false; diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProgram.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProgram.java index 2b362b20c..6ad418c18 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProgram.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeProgram.java @@ -4,7 +4,11 @@ package dk.camelot64.kickc.model.types; public class SymbolTypeProgram implements SymbolType { public SymbolTypeProgram() { + } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return this; } @Override diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeStruct.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeStruct.java index 0cf8548b8..837d2e154 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeStruct.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeStruct.java @@ -13,7 +13,7 @@ import java.util.Objects; public class SymbolTypeStruct implements SymbolType { /** Name of the struct type. */ - private String name; + private String structName; /** Size of the struct in bytes. */ private int sizeBytes; @@ -21,13 +21,25 @@ public class SymbolTypeStruct implements SymbolType { private final boolean isVolatile; private final boolean isNomodify; + public SymbolTypeStruct(String structName, int sizeBytes, boolean isVolatile, boolean isNomodify) { + this.structName = structName; + this.sizeBytes = sizeBytes; + this.isVolatile = isVolatile; + this.isNomodify = isNomodify; + } + public SymbolTypeStruct(StructDefinition structDefinition, boolean isVolatile, boolean isNomodify) { - this.name = structDefinition.getLocalName(); + this.structName = structDefinition.getLocalName(); this.sizeBytes = calculateSizeBytes(structDefinition, null); this.isVolatile = isVolatile; this.isNomodify = isNomodify; } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return new SymbolTypeStruct(this.structName, this.sizeBytes, isVolatile, isNomodify); + } + @Override public boolean isVolatile() { return isVolatile; @@ -40,15 +52,23 @@ public class SymbolTypeStruct implements SymbolType { @Override public String getTypeName() { - return "struct " + name; - } - - public String getStructTypeName() { + String name = ""; + /* + if(isVolatile) + name += "volatile "; + if(isNomodify) + name += "const "; + */ + name += "struct " + this.structName; return name; } + public String getStructTypeName() { + return structName; + } + public StructDefinition getStructDefinition(ProgramScope programScope) { - return programScope.getLocalStructDefinition(name); + return programScope.getLocalStructDefinition(structName); } @Override @@ -98,12 +118,12 @@ public class SymbolTypeStruct implements SymbolType { if(this == o) return true; if(o == null || getClass() != o.getClass()) return false; SymbolTypeStruct that = (SymbolTypeStruct) o; - return Objects.equals(name, that.name); + return Objects.equals(structName, that.structName); } @Override public int hashCode() { - return Objects.hash(name, sizeBytes); + return Objects.hash(structName, sizeBytes); } @Override diff --git a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeTypeDefScope.java b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeTypeDefScope.java index 25356a172..35030c38d 100644 --- a/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeTypeDefScope.java +++ b/src/main/java/dk/camelot64/kickc/model/types/SymbolTypeTypeDefScope.java @@ -4,7 +4,11 @@ package dk.camelot64.kickc.model.types; public class SymbolTypeTypeDefScope implements SymbolType { public SymbolTypeTypeDefScope() { + } + @Override + public SymbolType getQualified(boolean isVolatile, boolean isNomodify) { + return this; } @Override diff --git a/src/main/java/dk/camelot64/kickc/passes/Pass0GenerateStatementSequence.java b/src/main/java/dk/camelot64/kickc/passes/Pass0GenerateStatementSequence.java index e1d23a067..0d23c93b5 100644 --- a/src/main/java/dk/camelot64/kickc/passes/Pass0GenerateStatementSequence.java +++ b/src/main/java/dk/camelot64/kickc/passes/Pass0GenerateStatementSequence.java @@ -794,9 +794,11 @@ public class Pass0GenerateStatementSequence extends KickCParserBaseVisitorchar volatile * const * [42] */ + // TODO: Remove when const/volatile are put into type static class VariableDeclType { /** The type. */ SymbolType type; + // TODO: Remove when const/volatile are put into type /** Const / Volatile Directives if applied to the type */ List typeDirectives; /** If the type is SymbolTypePointer this holds the declaration type of the elements. */ @@ -851,8 +853,20 @@ public class Pass0GenerateStatementSequence extends KickCParserBaseVisitor directives) { this.declDirectives = new ArrayList<>(); for(Directive directive : directives) { - if(directive instanceof Directive.Const || directive instanceof Directive.Volatile) { + if(directive instanceof Directive.Volatile) { // Type directive + SymbolType type = this.declType.getType(); + SymbolType typeQualified = type.getQualified(true, type.isNomodify()); + this.declType.setType(typeQualified); + // TODO: Remove when const/volatile are put into type + if(!this.declType.getTypeDirectives().contains(directive)) + this.declType.getTypeDirectives().add(directive); + } else if(directive instanceof Directive.Const) { + // Type directive + SymbolType type = this.declType.getType(); + SymbolType typeQualified = type.getQualified(type.isVolatile(), true); + this.declType.setType(typeQualified); + // TODO: Remove when const/volatile are put into type if(!this.declType.getTypeDirectives().contains(directive)) this.declType.getTypeDirectives().add(directive); } else { @@ -868,9 +882,11 @@ public class Pass0GenerateStatementSequence extends KickCParserBaseVisitorCHARPTR_HILO = 0; graphics_render = GRAPHICS1; } + VICIV->BORDER_COLOR = BLUE; // Clear the graphics memset_dma(graphics_render, 0x00, 40*25*8); + VICIV->BORDER_COLOR = PURPLE; // Render some dots render_dots(); + VICIV->BORDER_COLOR = BLACK; //Play SID (*musicPlay)(); @@ -212,7 +213,7 @@ unsigned int SINX2[SINX2_SIZE+256] = kickasm {{ void graphics_mode(void) { // 16-bit text mode - VICIV->CONTROLC = VICIV_CHR16; + VICIV->CONTROLC = VICIV_CHR16|VICIV_VFAST; // H320, fast CPU VICIV->CONTROLB = VICIV_FAST; // 320x200 per char, 16 pixels wide per char