add more 'modified' comments to self-modifying code lines

This commit is contained in:
Irmen de Jong 2025-03-21 02:38:37 +01:00
parent e281994898
commit 90f80558d7
7 changed files with 23 additions and 18 deletions

View File

@ -414,7 +414,7 @@ byte_read_loop: ; fallback if MACPTR isn't supported on the device
while num_bytes!=0 {
%asm {{
jsr cbm.CHRIN
m_in_buffer sta $ffff
m_in_buffer sta $ffff ; modified
inc m_in_buffer+1
bne +
inc m_in_buffer+2

View File

@ -366,7 +366,7 @@ close_end:
while num_bytes!=0 {
%asm {{
jsr cbm.CHRIN
m_in_buffer sta $ffff
m_in_buffer sta $ffff ; modified
inc m_in_buffer+1
bne +
inc m_in_buffer+2

View File

@ -45,6 +45,12 @@ Various things:
`Prog8 code for ZSMkit <https://github.com/mooinglemur/zsmkit/tree/main/p8demo>`_
ZSMkit is an advanced music and sound effects engine for the Commander X16.
`vtsbank: a library for affine transformation and rotation of sprites and tiles <https://github.com/tallLeRoy/vtsbank>`_
"VERA Tile Set and Sprite feature" is a module that provides all sorts
of routines to perform tile and sprite transformations and rotation, using
the VeraFX hardware feature. Includes examples.
.. image:: _static/curious.png
:align: center
:alt: Curious

View File

@ -88,10 +88,10 @@ interrupts {
sta _lp2+2
ldx #4
ldy #0
_loop lda $ffff,y
_loop lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
_lp2 lda $ffff,y
_lp2 lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
bne _loop

View File

@ -89,10 +89,10 @@ music {
sta _lp2+2
ldx #4
ldy #0
_loop lda $ffff,y
_loop lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
_lp2 lda $ffff,y
_lp2 lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
bne _loop

View File

@ -237,11 +237,11 @@ music {
sta _lp2+2
ldx #4
ldy #0
_loop lda $ffff,y
_loop lda $ffff,y ;modified
eor #$80 ; convert to signed
sta cx16.VERA_AUDIO_DATA
iny
_lp2 lda $ffff,y
_lp2 lda $ffff,y ; modified
eor #$80 ; convert to signed
sta cx16.VERA_AUDIO_DATA
iny
@ -274,10 +274,10 @@ _lp2 lda $ffff,y
sta _lp2+2
ldx #4
ldy #0
_loop lda $ffff,y
_loop lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
_lp2 lda $ffff,y
_lp2 lda $ffff,y ; modified
sta cx16.VERA_AUDIO_DATA
iny
bne _loop

View File

@ -1,17 +1,16 @@
%import textio
%zeropage basicsafe
%option no_sysinit
%option no_sysinit, romable
main {
sub start() {
cx16.r0L = 25
uword @shared @nozp ptr
when cx16.r0L {
0 -> txt.print("zero")
1 -> txt.print("one")
21 to 29 step 2 -> txt.print("between 20 and 30 and odd")
else -> txt.print("something else")
}
cx16.r0L = @(ptr)
@(ptr)++
@(ptr)+=10
}
}