tweak word shift unroll

This commit is contained in:
Irmen de Jong 2020-12-06 08:36:19 +01:00
parent a92ec14989
commit 6b5211ad12
2 changed files with 1 additions and 11 deletions

View File

@ -881,7 +881,7 @@ internal class AugmentableAssignmentAsmGen(private val program: Program,
else else
asmgen.out(" lda #0 | sta $name") asmgen.out(" lda #0 | sta $name")
} }
value>2 -> asmgen.out(""" value>3 -> asmgen.out("""
ldy #$value ldy #$value
- asl $name - asl $name
rol $name+1 rol $name+1

View File

@ -5,16 +5,6 @@
main { main {
sub start() { sub start() {
uword uw
ubyte ub1
ubyte ub2
uw = ub1 as uword + ub2 ; fairly ok asm.. but the next though...:
ub1++
uw = ub1 + ub2 ; TODO horrible asm using the eval stack... fix
uw *= 8 ; TODO is using a loop... unroll somewhat
txt.print("hello\n") txt.print("hello\n")
} }
} }