We've just updated MediaWiki and its underlying software. If anything doesn't look or work quite right, please mention it to us. --RanAS
XBA: Difference between revisions
From SnesLab
(snes9x implementation) |
(added undisbeliever's opcode page link) |
||
Line 41: | Line 41: | ||
* [[Labiak]] page on XBA: https://archive.org/details/Programming_the_65816/page/n214 | * [[Labiak]] page on XBA: https://archive.org/details/Programming_the_65816/page/n214 | ||
* snes9x implementation of XBA: https://github.com/snes9xgit/snes9x/blob/master/cpuops.cpp#L3261 | * snes9x implementation of XBA: https://github.com/snes9xgit/snes9x/blob/master/cpuops.cpp#L3261 | ||
* undisbeliever on XBA: https://undisbeliever.net/snesdev/65816-opcodes.html#xba-exchange-the-b-and-a-accumulators | |||
[[Category:ASM]] | [[Category:ASM]] | ||
[[Category:65c816 additions]] | [[Category:65c816 additions]] |
Revision as of 04:15, 18 May 2023
XBA is an instruction that exchanges the high byte (B) and low byte (typically called A) of the C accumulator. It works even in 6502 emulation mode. In 65816 native mode, its mnemonic is still "XBA" even when the accumulator is 16-bits wide.
Basic Info | |||||||
---|---|---|---|---|---|---|---|
Addressing Mode | Opcode | Length | Speed | ||||
implied | EB | 1 byte | 3 cycles |
Flags Clobbered | |||||||
---|---|---|---|---|---|---|---|
N | V | M | X | D | I | Z | C |
. | . | . | . | . | . |
External Links
- Eyes & Lichty page on XBA: https://archive.org/details/0893037893ProgrammingThe65816/page/n550
- Labiak page on XBA: https://archive.org/details/Programming_the_65816/page/n214
- snes9x implementation of XBA: https://github.com/snes9xgit/snes9x/blob/master/cpuops.cpp#L3261
- undisbeliever on XBA: https://undisbeliever.net/snesdev/65816-opcodes.html#xba-exchange-the-b-and-a-accumulators