ZX0
ZX0 copied to clipboard
minor dzx0_turbo optimization
I have found a small optimization to dzx0_turbo. Changing ld a, $80 to inc c \ scf allows us to skip a few instructions. I believe this optimization can also be done to dzx0_fast.
dzx0_turbo:
ld bc, $ffff ; preserve default offset 1
ld (dzx0t_last_offset+1), bc
inc bc
- ld a, $80
- jr dzx0t_literals
+ inc c
+ scf
jr dzx0t_start
; ...
dzx0t_literals:
inc c ; obtain length
add a, a
jp nz, dzx0t_literals_skip
+ dzx0t_start:
ld a, (hl) ; load another group of 8 bits
inc hl
rla
dzx0t_literals_skip: