mirror of
https://github.com/cc65/cc65.git
synced 2024-10-31 20:06:11 +00:00
287 lines
2.8 KiB
ArmAsm
287 lines
2.8 KiB
ArmAsm
.setcpu "65816"
|
|
|
|
ADC ($10,X)
|
|
ADC $32,S
|
|
ADC $10
|
|
ADC [$10]
|
|
ADC #$54
|
|
ADC $9876
|
|
ADC $FEDBCA
|
|
ADC ($10),Y
|
|
ADC ($10)
|
|
ADC ($32,S),Y
|
|
ADC $10,X
|
|
ADC [$10],Y
|
|
ADC $9876,Y
|
|
ADC $9876,X
|
|
ADC $FEDCBA,X
|
|
SBC ($10,X)
|
|
SBC $32,S
|
|
SBC $10
|
|
SBC [$10]
|
|
SBC #$54
|
|
SBC $9876
|
|
SBC $FEDBCA
|
|
SBC ($10),Y
|
|
SBC ($10)
|
|
SBC ($32,S),Y
|
|
SBC $10,X
|
|
SBC [$10],Y
|
|
SBC $9876,Y
|
|
SBC $9876,X
|
|
SBC $FEDCBA,X
|
|
CMP ($10,X)
|
|
CMP $32,S
|
|
CMP $10
|
|
CMP [$10]
|
|
CMP #$54
|
|
CMP $9876
|
|
CMP $FEDBCA
|
|
CMP ($10),Y
|
|
CMP ($10)
|
|
CMP ($32,S),Y
|
|
CMP $10,X
|
|
CMP [$10],Y
|
|
CMP $9876,Y
|
|
CMP $9876,X
|
|
CMP $FEDCBA,X
|
|
CPX #$54
|
|
CPX $10
|
|
CPX $9876
|
|
CPY #$54
|
|
CPY $10
|
|
CPY $9876
|
|
DEC
|
|
DEC $10
|
|
DEC $9876
|
|
DEC $10,X
|
|
DEC $9876,X
|
|
DEX
|
|
DEY
|
|
INC
|
|
INC $10
|
|
INC $9876
|
|
INC $10,X
|
|
INC $9876,X
|
|
INX
|
|
INY
|
|
AND ($10,X)
|
|
AND $32,S
|
|
AND $10
|
|
AND [$10]
|
|
AND #$54
|
|
AND $9876
|
|
AND $FEDBCA
|
|
AND ($10),Y
|
|
AND ($10)
|
|
AND ($32,S),Y
|
|
AND $10,X
|
|
AND [$10],Y
|
|
AND $9876,Y
|
|
AND $9876,X
|
|
AND $FEDCBA,X
|
|
EOR ($10,X)
|
|
EOR $32,S
|
|
EOR $10
|
|
EOR [$10]
|
|
EOR #$54
|
|
EOR $9876
|
|
EOR $FEDBCA
|
|
EOR ($10),Y
|
|
EOR ($10)
|
|
EOR ($32,S),Y
|
|
EOR $10,X
|
|
EOR [$10],Y
|
|
EOR $9876,Y
|
|
EOR $9876,X
|
|
EOR $FEDCBA,X
|
|
ORA ($10,X)
|
|
ORA $32,S
|
|
ORA $10
|
|
ORA [$10]
|
|
ORA #$54
|
|
ORA $9876
|
|
ORA $FEDBCA
|
|
ORA ($10),Y
|
|
ORA ($10)
|
|
ORA ($32,S),Y
|
|
ORA $10,X
|
|
ORA [$10],Y
|
|
ORA $9876,Y
|
|
ORA $9876,X
|
|
ORA $FEDCBA,X
|
|
BIT $10
|
|
BIT $9876
|
|
BIT $10,X
|
|
BIT $9876,X
|
|
BIT #$54
|
|
TRB $10
|
|
TRB $9876
|
|
TSB $10
|
|
TSB $9876
|
|
ASL $10
|
|
ASL
|
|
ASL $9876
|
|
ASL $10,X
|
|
ASL $9876,X
|
|
LSR $10
|
|
LSR
|
|
LSR $9876
|
|
LSR $10,X
|
|
LSR $9876,X
|
|
ROL $10
|
|
ROL
|
|
ROL $9876
|
|
ROL $10,X
|
|
ROL $9876,X
|
|
ROR $10
|
|
ROR
|
|
ROR $9876
|
|
ROR $10,X
|
|
ROR $9876,X
|
|
LABEL:
|
|
BCC LABEL
|
|
BCS LABEL
|
|
BEQ LABEL
|
|
BMI LABEL
|
|
BNE LABEL
|
|
BPL LABEL
|
|
BRA LABEL
|
|
BVC LABEL
|
|
BVS LABEL
|
|
BRL LABEL
|
|
JMP $1234
|
|
JML $FEDCBA
|
|
JMP ($1234)
|
|
JMP ($1234,X)
|
|
JMP [$1234]
|
|
JML [$1234] ; alternative to JMP []
|
|
JSL $123456
|
|
JSR $1234
|
|
JSR ($1234,X)
|
|
RTL
|
|
RTS
|
|
BRK
|
|
RTI
|
|
CLC
|
|
CLD
|
|
CLI
|
|
CLV
|
|
SEC
|
|
SED
|
|
SEI
|
|
REP #$12
|
|
SEP #$12
|
|
LDA ($10,X)
|
|
LDA $32,S
|
|
LDA $10
|
|
LDA [$10]
|
|
LDA #$54
|
|
LDA $9876
|
|
LDA $FEDBCA
|
|
LDA ($10),Y
|
|
LDA ($10)
|
|
LDA ($32,S),Y
|
|
LDA $10,X
|
|
LDA [$10],Y
|
|
LDA $9876,Y
|
|
LDA $9876,X
|
|
LDA $FEDCBA,X
|
|
LDX #$54
|
|
LDX $10
|
|
LDX $9876
|
|
LDX $10,Y
|
|
LDX $9876,Y
|
|
LDY #$54
|
|
LDY $10
|
|
LDY $9876
|
|
LDY $10,X
|
|
LDY $9876,X
|
|
STA ($10,X)
|
|
STA $32,S
|
|
STA $10
|
|
STA [$10]
|
|
STA $9876
|
|
STA $FEDBCA
|
|
STA ($10),Y
|
|
STA ($10)
|
|
STA ($32,S),Y
|
|
STA $10,X
|
|
STA [$10],Y
|
|
STA $9876,Y
|
|
STA $9876,X
|
|
STA $FEDCBA,X
|
|
STX $10
|
|
STX $9876
|
|
STX $10,Y
|
|
STY $10
|
|
STY $9876
|
|
STY $10,X
|
|
STZ $10
|
|
STZ $10,X
|
|
STZ $9876
|
|
STZ $9876,X
|
|
MVN #$12,#$34
|
|
MVP #$12,#$34
|
|
NOP
|
|
PEA $1234
|
|
PEI ($12)
|
|
PER LABEL
|
|
PHA
|
|
PHX
|
|
PHY
|
|
PLA
|
|
PLX
|
|
PLY
|
|
PHB
|
|
PHD
|
|
PHK
|
|
PHP
|
|
PLB
|
|
PLD
|
|
PLP
|
|
STP
|
|
WAI
|
|
TAX
|
|
TAY
|
|
TSX
|
|
TXA
|
|
TXS
|
|
TXY
|
|
TYA
|
|
TYX
|
|
TCD
|
|
TCS
|
|
TDC
|
|
TSC
|
|
XBA
|
|
XCE
|
|
|
|
.a16
|
|
.i16
|
|
longs:
|
|
ADC #$5432
|
|
SBC #$5432
|
|
CMP #$5432
|
|
CPX #$5432
|
|
CPY #$5432
|
|
AND #$5432
|
|
EOR #$5432
|
|
ORA #$5432
|
|
BIT #$5432
|
|
LDA #$5432
|
|
LDX #$5432
|
|
LDY #$5432
|
|
|
|
; test of smart and long_jsr_jmp_rts
|
|
.smart
|
|
.proc short_rts : far
|
|
RTS ; not promoted to RTL
|
|
.endproc
|
|
.feature long_jsr_jmp_rts
|
|
JSR $FEDCBA ; promoted to JSL
|
|
JMP $FEDCBA ; promoted to JML
|
|
.proc long_rts : far
|
|
RTS ; promoted to RTL
|
|
.endproc
|