mirror of
https://github.com/cc65/cc65.git
synced 2025-01-08 20:31:31 +00:00
19 lines
473 B
ArmAsm
19 lines
473 B
ArmAsm
|
;
|
||
|
; Miloslaw Smyk, 2024
|
||
|
;
|
||
|
; CC65 runtime: Scale the primary register by 128, signed
|
||
|
;
|
||
|
|
||
|
.export asrax7
|
||
|
|
||
|
asrax7: ; HXXXXXXL hAAAAAAl
|
||
|
asl ; AAAAAAA0, h->C
|
||
|
txa
|
||
|
rol ; XXXXXXLh, H->C
|
||
|
ldx #$00 ; 00000000 XXXXXXLh
|
||
|
bcc :+
|
||
|
dex ; 11111111 XXXXXXLh if C
|
||
|
: rts
|
||
|
|
||
|
; 12 cycles max, 9 bytes
|