From cfff09e038fe74fc9d60ed157f27e8382185b519 Mon Sep 17 00:00:00 2001 From: jespergravgaard Date: Mon, 30 Sep 2019 08:15:07 +0200 Subject: [PATCH] Added fragments from Paul Gardner-Stephen. --- .../mos6502-common/pbuz1=pptz1_derefidx_vbuyy.asm | 7 +++++++ .../fragment/mos6502-common/pduz1=_deref_pptc1.asm | 4 ++++ .../mos6502-common/pduz1_derefidx_vbuyy=vduz2.asm | 11 +++++++++++ .../mos6502-common/pptz1_derefidx_vbuyy=pbuc2.asm | 5 +++++ .../fragment/mos6502-common/pwuz1=_deref_pptc1.asm | 4 ++++ .../mos6502-common/pwuz1=pptz1_derefidx_vbuyy.asm | 7 +++++++ .../fragment/mos6502-common/vbuz1=vbuz2_rol_8.asm | 2 ++ .../fragment/mos6502-common/vduz1=_deref_pptc1.asm | 7 +++++++ .../mos6502-common/vduz1=_dword__deref_pptc1.asm | 7 +++++++ .../vduz1=_word_pbuz2_derefidx_vbuyy.asm | 6 ++++++ .../mos6502-common/vduz1=pduz2_derefidx_vbuyy.asm | 11 +++++++++++ .../fragment/mos6502-common/vduz1=vduz1_rol_16.asm | 7 +++++++ .../fragment/mos6502-common/vduz1=vduz1_rol_8.asm | 8 ++++++++ .../mos6502-common/vduz1=vduz2_bor_vduz1.asm | 12 ++++++++++++ .../mos6502-common/vduz1=vduz2_bor_vduz3.asm | 12 ++++++++++++ .../fragment/mos6502-common/vduz1=vduz2_rol_16.asm | 7 +++++++ .../fragment/mos6502-common/vwsz1=vwsz2_rol_8.asm | 4 ++++ .../mos6502-common/vwuz1=_word__deref_pbuz2.asm | 6 ++++++ .../vwuz1=_word_pbuz2_derefidx_vbuyy.asm | 5 +++++ 19 files changed, 132 insertions(+) create mode 100644 src/main/fragment/mos6502-common/pbuz1=pptz1_derefidx_vbuyy.asm create mode 100644 src/main/fragment/mos6502-common/pduz1=_deref_pptc1.asm create mode 100644 src/main/fragment/mos6502-common/pduz1_derefidx_vbuyy=vduz2.asm create mode 100644 src/main/fragment/mos6502-common/pptz1_derefidx_vbuyy=pbuc2.asm create mode 100644 src/main/fragment/mos6502-common/pwuz1=_deref_pptc1.asm create mode 100644 src/main/fragment/mos6502-common/pwuz1=pptz1_derefidx_vbuyy.asm create mode 100644 src/main/fragment/mos6502-common/vbuz1=vbuz2_rol_8.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=_deref_pptc1.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=_dword__deref_pptc1.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=_word_pbuz2_derefidx_vbuyy.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=pduz2_derefidx_vbuyy.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=vduz1_rol_16.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=vduz1_rol_8.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz1.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz3.asm create mode 100644 src/main/fragment/mos6502-common/vduz1=vduz2_rol_16.asm create mode 100644 src/main/fragment/mos6502-common/vwsz1=vwsz2_rol_8.asm create mode 100644 src/main/fragment/mos6502-common/vwuz1=_word__deref_pbuz2.asm create mode 100644 src/main/fragment/mos6502-common/vwuz1=_word_pbuz2_derefidx_vbuyy.asm diff --git a/src/main/fragment/mos6502-common/pbuz1=pptz1_derefidx_vbuyy.asm b/src/main/fragment/mos6502-common/pbuz1=pptz1_derefidx_vbuyy.asm new file mode 100644 index 000000000..117f5eede --- /dev/null +++ b/src/main/fragment/mos6502-common/pbuz1=pptz1_derefidx_vbuyy.asm @@ -0,0 +1,7 @@ +lda ({z1}),y +pha +iny +lda ({z1}),y +sta {z1}+1 +pla +sta {z1} diff --git a/src/main/fragment/mos6502-common/pduz1=_deref_pptc1.asm b/src/main/fragment/mos6502-common/pduz1=_deref_pptc1.asm new file mode 100644 index 000000000..1f588b460 --- /dev/null +++ b/src/main/fragment/mos6502-common/pduz1=_deref_pptc1.asm @@ -0,0 +1,4 @@ +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 \ No newline at end of file diff --git a/src/main/fragment/mos6502-common/pduz1_derefidx_vbuyy=vduz2.asm b/src/main/fragment/mos6502-common/pduz1_derefidx_vbuyy=vduz2.asm new file mode 100644 index 000000000..ed1f3bcd9 --- /dev/null +++ b/src/main/fragment/mos6502-common/pduz1_derefidx_vbuyy=vduz2.asm @@ -0,0 +1,11 @@ +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 diff --git a/src/main/fragment/mos6502-common/pptz1_derefidx_vbuyy=pbuc2.asm b/src/main/fragment/mos6502-common/pptz1_derefidx_vbuyy=pbuc2.asm new file mode 100644 index 000000000..475862f26 --- /dev/null +++ b/src/main/fragment/mos6502-common/pptz1_derefidx_vbuyy=pbuc2.asm @@ -0,0 +1,5 @@ +lda #<{c2} +sta ({z1}),y +iny +lda #>{c2} +sta ({z1}),y diff --git a/src/main/fragment/mos6502-common/pwuz1=_deref_pptc1.asm b/src/main/fragment/mos6502-common/pwuz1=_deref_pptc1.asm new file mode 100644 index 000000000..1f588b460 --- /dev/null +++ b/src/main/fragment/mos6502-common/pwuz1=_deref_pptc1.asm @@ -0,0 +1,4 @@ +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 \ No newline at end of file diff --git a/src/main/fragment/mos6502-common/pwuz1=pptz1_derefidx_vbuyy.asm b/src/main/fragment/mos6502-common/pwuz1=pptz1_derefidx_vbuyy.asm new file mode 100644 index 000000000..117f5eede --- /dev/null +++ b/src/main/fragment/mos6502-common/pwuz1=pptz1_derefidx_vbuyy.asm @@ -0,0 +1,7 @@ +lda ({z1}),y +pha +iny +lda ({z1}),y +sta {z1}+1 +pla +sta {z1} diff --git a/src/main/fragment/mos6502-common/vbuz1=vbuz2_rol_8.asm b/src/main/fragment/mos6502-common/vbuz1=vbuz2_rol_8.asm new file mode 100644 index 000000000..1a784bbc0 --- /dev/null +++ b/src/main/fragment/mos6502-common/vbuz1=vbuz2_rol_8.asm @@ -0,0 +1,2 @@ +lda #0 +sta {z1} \ No newline at end of file diff --git a/src/main/fragment/mos6502-common/vduz1=_deref_pptc1.asm b/src/main/fragment/mos6502-common/vduz1=_deref_pptc1.asm new file mode 100644 index 000000000..34e4e8214 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=_deref_pptc1.asm @@ -0,0 +1,7 @@ +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 +lda #0 +sta {z1}+2 +sta {z1}+3 diff --git a/src/main/fragment/mos6502-common/vduz1=_dword__deref_pptc1.asm b/src/main/fragment/mos6502-common/vduz1=_dword__deref_pptc1.asm new file mode 100644 index 000000000..34e4e8214 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=_dword__deref_pptc1.asm @@ -0,0 +1,7 @@ +lda {c1} +sta {z1} +lda {c1}+1 +sta {z1}+1 +lda #0 +sta {z1}+2 +sta {z1}+3 diff --git a/src/main/fragment/mos6502-common/vduz1=_word_pbuz2_derefidx_vbuyy.asm b/src/main/fragment/mos6502-common/vduz1=_word_pbuz2_derefidx_vbuyy.asm new file mode 100644 index 000000000..9469c75c7 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=_word_pbuz2_derefidx_vbuyy.asm @@ -0,0 +1,6 @@ +lda ({z2}),y +sta {z1} +lda #0 +sta {z1}+1 +sta {z1}+2 +sta {z1}+3 diff --git a/src/main/fragment/mos6502-common/vduz1=pduz2_derefidx_vbuyy.asm b/src/main/fragment/mos6502-common/vduz1=pduz2_derefidx_vbuyy.asm new file mode 100644 index 000000000..cfe1683b5 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=pduz2_derefidx_vbuyy.asm @@ -0,0 +1,11 @@ +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 diff --git a/src/main/fragment/mos6502-common/vduz1=vduz1_rol_16.asm b/src/main/fragment/mos6502-common/vduz1=vduz1_rol_16.asm new file mode 100644 index 000000000..95ae636f6 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=vduz1_rol_16.asm @@ -0,0 +1,7 @@ +lda {z1}+1 +sta {z1}+3 +lda {z1} +sta {z1}+2 +lda #0 +sta {z1} +sta {z1}+1 diff --git a/src/main/fragment/mos6502-common/vduz1=vduz1_rol_8.asm b/src/main/fragment/mos6502-common/vduz1=vduz1_rol_8.asm new file mode 100644 index 000000000..60127d6e6 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=vduz1_rol_8.asm @@ -0,0 +1,8 @@ +lda {z1}+2 +sta {z1}+3 +lda {z1}+1 +sta {z1}+2 +lda {z1} +sta {z1}+1 +lda #0 +sta {z1} diff --git a/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz1.asm b/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz1.asm new file mode 100644 index 000000000..15d3cdaec --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz1.asm @@ -0,0 +1,12 @@ +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 diff --git a/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz3.asm b/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz3.asm new file mode 100644 index 000000000..fd27a7467 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=vduz2_bor_vduz3.asm @@ -0,0 +1,12 @@ +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 diff --git a/src/main/fragment/mos6502-common/vduz1=vduz2_rol_16.asm b/src/main/fragment/mos6502-common/vduz1=vduz2_rol_16.asm new file mode 100644 index 000000000..a5272f458 --- /dev/null +++ b/src/main/fragment/mos6502-common/vduz1=vduz2_rol_16.asm @@ -0,0 +1,7 @@ +lda #0 +sta {z1} +sta {z1}+1 +lda {z2} +sta {z1}+2 +lda {z2}+1 +sta {z1}+3 diff --git a/src/main/fragment/mos6502-common/vwsz1=vwsz2_rol_8.asm b/src/main/fragment/mos6502-common/vwsz1=vwsz2_rol_8.asm new file mode 100644 index 000000000..584864357 --- /dev/null +++ b/src/main/fragment/mos6502-common/vwsz1=vwsz2_rol_8.asm @@ -0,0 +1,4 @@ +lda #0 +sta {z1} +lda {z2} +sta {z1}+1 diff --git a/src/main/fragment/mos6502-common/vwuz1=_word__deref_pbuz2.asm b/src/main/fragment/mos6502-common/vwuz1=_word__deref_pbuz2.asm new file mode 100644 index 000000000..90207678e --- /dev/null +++ b/src/main/fragment/mos6502-common/vwuz1=_word__deref_pbuz2.asm @@ -0,0 +1,6 @@ +ldy #0 +lda ({z2}),y +sta {z1} +iny +lda #0 +sta {z1}+1 diff --git a/src/main/fragment/mos6502-common/vwuz1=_word_pbuz2_derefidx_vbuyy.asm b/src/main/fragment/mos6502-common/vwuz1=_word_pbuz2_derefidx_vbuyy.asm new file mode 100644 index 000000000..adbb90984 --- /dev/null +++ b/src/main/fragment/mos6502-common/vwuz1=_word_pbuz2_derefidx_vbuyy.asm @@ -0,0 +1,5 @@ +lda ({z2}),y +sta {z1} +iny +lda #0 +sta {z1}+1