Split 2018x-extension-scripts

Created the 20180-extension-scripts test by cutting out the handful
of 65816-specific items from 20182.  Removed some issue-specific stuff
from 20182 that didn't need to be duplicated.  Renamed some stale
references to test 2022.
This commit is contained in:
Andy McFadden committed 2025-11-30 14:20:38 -08:00
1 parent da7548a24a
commit 5a3d288707
18 files changed
+859 -264

No files matched your search

@@ -3,7 +3,7 @@
;
; Assembler: Merlin 32
; EDIT: the project must include the platform symbol file and extension script
; EDIT: the project must include the platform symbol file and extension scripts
PrintInlineL1String equ $011000
PrintInlineL2String equ $012000
@@ -43,36 +43,13 @@ PrintInlineDciString equ $013000 ;EDIT: add to project symbols
brk $02
dw data02
; Handle an edge case where the inline formatting gets thrown out.
; Two paths: BIT $A9 / BRK $85 / inline $FF/EA goes first, then
; LDA $00 / STA $FF / NOP goes. When we get to the STA we notice
; that it's marked as inline data, so we remove it from $85 $ff
; but not from $ea.
;
; If we try to walk through the file, advancing offset by the anattrib
; length, we will traverse the first path, which (with 2-byte BRKs)
; runs into the $FF, which is marked as an instruction but not an
; instruction start.
;
; Switching to 1-byte BRKs makes the $85 an inline data item rather
; than an instruction. When we come back through, we LDA $00 and
; then skip over the next 3 bytes. No conflict.
nop
jsr edge1 ;alt path, evaluated later
dfb $24 ;1: BIT dp
edge1 dfb $a9 ;2: LDA imm
brk ;1: BRK <op>
dfb $85 ;2: STA imm
dfb $ff ;1: address $eaff
nop ;2:
jmp Next1
jmp Next
PrintInline8String rts ;EDIT: set label
PrintInlineRev8String rts ;EDIT: set label
PrintInlineNullString rts ;EDIT: set label
data01 ;EDIT: set label
data01 ;EDIT: set label (unique local)
dw $1122 ;should be little-endian
dw $4433 ;should be big-endian
hex 55667788 ;32-bit
@@ -85,43 +62,14 @@ data01 ;EDIT: set label
dfb $80
data02 ;EDIT: set label, must be "data02"
data02 ;EDIT: set label, must be "data02" (unique local)
dw data03
dfb $80
data03 ;EDIT: set label
data03 ;EDIT: set label (unique local)
asc "AllEight"
;
; The analyzer is trying to avoid calling the inline JSR check on code it
; has previously visited. There was a bug that caused us to lose the
; no-continue value if code was revisited.
;
; To ensure we revisit the function, we need to call it, then call
; something else that calls it, changing up the flags.
;
NoCont pla
pla
rts
TestNC1 jsr NoCont
dfb $00,$80
TestNC2 jsr NoCont
dfb $00,$80
Next1 jsr TestNC1
jsr PushThing
clc
jsr TestNC2
rts
PushThing
sec
jsr TestNC2
Next
; Make sure flags get marked as indeterminate across inline BRK.
; Also exercises formatting the same block twice.