Fixed cycle delay: Difference between revisions
From NESdev Wiki
Jump to navigationJump to search
(Gotta have more data) |
(update) |
||
Line 12: | Line 12: | ||
* Alternatively, @rts15 means you know a memory address that contains a harmless 3-cycle instruction that fits your constraints (such as <code>LDA $00</code>), followed by <code>RTS</code>. | * Alternatively, @rts15 means you know a memory address that contains a harmless 3-cycle instruction that fits your constraints (such as <code>LDA $00</code>), followed by <code>RTS</code>. | ||
* @A, @X, @Y are local labels. | * @A, @X, @Y are local labels. | ||
=== 2 cycles === | === 2 cycles === | ||
Line 670: | Line 672: | ||
!colspan="2"|6 bytes | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #4 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #4 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
Line 723: | Line 732: | ||
PLA | PLA | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #4 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #4 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
Line 731: | Line 752: | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #3 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #3 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 969: | Line 996: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #3 | |||
@X: | |||
PHA | PHA | ||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | LDY #3 | ||
@Y: | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
PLP | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
BIT $00 | BIT $00 | ||
PLP | PLP | ||
Line 995: | Line 1,036: | ||
TXS | TXS | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #2 | |||
@Y: | |||
PHP | |||
PLP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 1,061: | Line 1,110: | ||
!colspan="2"|6 bytes | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #5 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #5 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
Line 1,287: | Line 1,336: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts15 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDX #5 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDY #5 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |- | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
JSR @rts14 | NOP | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | LDY #5 | ||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDX #5 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
!colspan="2"|8 bytes | !colspan="2"|8 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #4 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #4 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #5 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
Line 1,309: | Line 1,407: | ||
PLA | PLA | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
Line 1,337: | Line 1,426: | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|5 bytes | !colspan="2"|5 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | ||
Line 1,342: | Line 1,436: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
Line 1,406: | Line 1,495: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
JSR @rts14 | PHP | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14, and support for unofficial opcodes | LDY #4 | ||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #4 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14, and support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDX #3 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #3 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
Line 1,478: | Line 1,591: | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #4 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #4 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
Line 1,485: | Line 1,612: | ||
!colspan="2"|8 bytes | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY # | NOP | ||
NOP | |||
LDY #5 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
LDX #5 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
Line 1,562: | Line 1,697: | ||
!colspan="2"|6 bytes | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #6 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #6 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #5 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 1,582: | Line 1,724: | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
Line 1,697: | Line 1,832: | ||
=== 34 cycles === | === 34 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY #6 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
LDX #6 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
|- | LDY #6 | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | @Y: | ||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDX #6 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N; and requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
LDY #6 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | JSR @rts15 | ||
JSR @rts14 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
Line 1,768: | Line 1,947: | ||
PLA | PLA | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDX #4 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDY #4 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
Line 1,786: | Line 1,983: | ||
JSR @rts12 | JSR @rts12 | ||
JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
TYA | |||
PHA | |||
LDY #4 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #2 | |||
@Y: | |||
PHP | |||
PLP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 1,850: | Line 2,067: | ||
=== 35 cycles === | === 35 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDY #5 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDX #5 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 1,874: | Line 2,132: | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | ||
|- | |- | ||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | SEC | ||
LDA #5 | LDA #5 | ||
Line 1,906: | Line 2,141: | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
Line 2,001: | Line 2,222: | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
Line 2,018: | Line 2,246: | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
Line 2,034: | Line 2,269: | ||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | ||
|- | |- | ||
!colspan="2"|10 bytes | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
NOP | NOP | ||
SBC #1 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | |||
LDA #130 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 | |||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S; and requires support for unofficial opcodes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
NOP | PHA | ||
NOP | SEC | ||
LDA #130 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 | |||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"|11 bytes | !colspan="2"|11 bytes | ||
Line 2,099: | Line 2,337: | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
NOP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} | ||
Line 2,141: | Line 2,394: | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
Line 2,154: | Line 2,414: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHP | PHP | ||
LDX #5 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #5 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | PHP | ||
PLP | PLP | ||
JSR @ | JSR @rts14 | ||
JSR @ | JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | ||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
PLP | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts12 | |||
|- | |- | ||
!colspan="2"|11 bytes | !colspan="2"|11 bytes | ||
Line 2,209: | Line 2,483: | ||
=== 38 cycles === | === 38 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY # | LDY #7 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #6 | LDX #6 | ||
@X: | @X: | ||
Line 2,325: | Line 2,613: | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Requires @zptemp, and support for unofficial opcodes | PLP</nowiki></pre> || style="padding:2px" | Requires @zptemp, and support for unofficial opcodes | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
BIT $00 | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} | ||
Line 2,331: | Line 2,633: | ||
=== 39 cycles === | === 39 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY #7 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDY #7 | |||
@ | @Y: | ||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
BNE @ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #7 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
LDY #7 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PLP | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #3 | |||
@A: | |||
PHP | |||
PLP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDY #4 | LDY #4 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDX #4 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PLA | |||
JSR @ | PLA | ||
JSR @ | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N; and requires @rts14 | |||
|- | |- | ||
!colspan="2"|10 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | |||
PHA | |||
LDY #5 | |||
@Y: | @Y: | ||
DEY | |||
BNE @Y | |||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | |||
PHP | |||
LDX #5 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | NOP | ||
PHP | |||
LDY #5 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
PHP | |||
PLP | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts12 | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | PHA | ||
LDY #4 | |||
@Y: | |||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 2,511: | Line 2,818: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
@ | JSR @rts12 | ||
JSR @rts12 | |||
NOP | JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @zptemp, and @rts12 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12, and support for unofficial opcodes | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | NOP | ||
PHP | PHP | ||
PLP | PLP | ||
PHP | |||
PLP | PLP | ||
PHP | PHP | ||
PLP | PLP | ||
PHP | PHP | ||
PLP | PLP | ||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |||
=== 40 cycles === | |||
|} | |||
=== | |||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDY #7 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | PHP | ||
LDY #6 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | PHP | ||
LDX #6 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA #2 | SEC | ||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #6 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | | JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts12, and @rts14 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
PLP | PLP | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>ROL $00,X | |||
ROR $00,X | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers Z&N; and requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | | JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | ||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
JSR @rts12 | JSR @rts12 | ||
JSR @rts12 | JSR @rts12 | ||
JSR @rts12</nowiki></pre> || style="padding:2px" | | JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | PHP | ||
BIT $00 | |||
PLP | PLP | ||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
@ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 2,747: | Line 2,972: | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides !NOP #imm | ; ^ Hides !NOP #imm | ||
NOP $ | NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 | ||
SBC #1 | SBC #1 | ||
BMI @A | BMI @A | ||
Line 2,754: | Line 2,978: | ||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | ||
|- | |- | ||
|} | !colspan="2"|12 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
ROL $00,X | |||
ROR $00,X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== | === 41 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #8 | ||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #8 | ||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | LDX #6 | ||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY # | PHP | ||
LDY #6 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | SEC | ||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
LDY #6 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | BIT $00 | ||
LDX #6 | |||
@X: | @X: | ||
DEX | DEX | ||
Line 2,848: | Line 3,051: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
SEC | |||
LDA #7 | |||
LDA # | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @ | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @ | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts12, @rts14, and @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PLA | PLA | ||
PLA | PLA | ||
JSR @rts15 | |||
JSR @ | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N; and requires @rts15 | ||
JSR @ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
PHP | PHP | ||
Line 2,904: | Line 3,077: | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | |||
PHA | |||
LDY #5 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHA | PHA | ||
PHP | PHP | ||
Line 2,924: | Line 3,094: | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | ||
|- | |- | ||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
TYA | |||
@A | PHA | ||
; | LDY #5 | ||
NOP | @Y: | ||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts12 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #4 | ||
@A: | @A: | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #4 | ||
@A: | @A: | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |- | ||
! | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | |||
LDA #130 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA ;hides 'NOP' | |||
PHP | |||
PLP | |||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #130 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
PHP | NOP $EA ;hides 'NOP' | ||
PLP | PHP | ||
PLP | |||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
!colspan="2"|12 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
PHP | PHP | ||
BIT $00 | |||
PLP | PLP | ||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY # | PHA | ||
TYA | |||
PHA | |||
LDY #4 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #5 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | PHP | ||
PLP | |||
PHP | |||
PLP | PLP | ||
PHP | PHP | ||
PLP | PLP | ||
PHP | PHP | ||
PLP | PLP | ||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
Line 3,073: | Line 3,217: | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides !NOP #imm | ; ^ Hides !NOP #imm | ||
NOP $ | NOP $EAEA ;hides two 'NOP's | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
Line 3,080: | Line 3,224: | ||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | ||
|- | |- | ||
!colspan="2"|13 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 42 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | PHA | ||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | PHA | ||
LDY #7 | |||
@Y: | |||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"|8 bytes | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | NOP | ||
LDY #7 | |||
BNE @ | @Y: | ||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
!colspan="2"|9 bytes | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts12, and @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @ | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | ||
PHA | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDX #6 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>ROL $00,X | |||
ROR $00,X | |||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers Z&N; and requires @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 3,140: | Line 3,339: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 3,148: | Line 3,348: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | PHP | ||
PLP | |||
JSR @ | JSR @rts15 | ||
JSR @ | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | ||
|- | |- | ||
!colspan="2"|11 bytes | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 3,194: | Line 3,370: | ||
=== | === 43 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #7 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA #8 | |||
@ | @A: | ||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
BNE @ | |||
|- | |- | ||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | ||
JSR @rts14 | JSR @rts14 | ||
JSR @ | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | ||
|- | |- | ||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
PHP | PHP | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
JSR @rts12 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts12, and @rts14 | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | PLP | ||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDA $00 | |||
@ | SEC | ||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
BNE @ | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 3,316: | Line 3,481: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
PHA | |||
PHP | |||
PLP | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
NOP | |||
PHP | |||
PLP | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | PHA | ||
SEC | |||
LDA #130 | |||
@A = * - 1 | |||
@ | ; ^ Hides !NOP #imm | ||
NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 | |||
SBC #1 | |||
BMI @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | PLP</nowiki></pre> || style="padding:2px" | Clobbers S; and requires support for unofficial opcodes | ||
|- | |- | ||
!colspan="2"|13 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | |||
PHA | PHA | ||
LDY # | LDY #2 | ||
@Y: | @Y: | ||
PHP | |||
PLP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | PHA | ||
PHA | PHA | ||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #130 | |||
@A = * - 1 | |||
@ | ; ^ Hides !NOP #imm | ||
NOP $EA44 ;hides 'NOP zp' | |||
SBC #1 | |||
BMI @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"|14 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
NOP | NOP | ||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | |} | ||
=== 44 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #8 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX #8 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY #8 | |||
@Y: | |||
DEY | |||
@ | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
BNE @ | |||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDX #8 | |||
@X: | |||
= | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDY #8 | LDY #8 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDX #8 | LDX #8 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDY #8 | |||
@ | @Y: | ||
DEY | |||
BNE @ | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDX #8 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #8 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDX #8 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDY #8 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #8 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #3 | |||
@Y: | |||
PHP | |||
PLP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #3 | LDX #3 | ||
@X: | @X: | ||
Line 3,481: | Line 3,673: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PLA | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
PHP | |||
PLP | |||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | |||
PHA | PHA | ||
LDY #6 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14 | JSR @rts14 | ||
JSR @rts14</nowiki></pre> || style="padding:2px" | | JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | ||
|- | |- | ||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #5 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHP | |||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | !colspan="2"|12 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 45 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDY #8 | |||
@Y: | |||
@A = | DEY | ||
; | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDX #8 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #6 | |||
@Y: | |||
NOP | NOP | ||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #6 | |||
@X: | |||
@ | |||
NOP | NOP | ||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #6 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 3,573: | Line 3,823: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | PLP | ||
SBC #1 | JSR @rts12 | ||
JSR @rts12 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts12, and @rts14 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and V; and requires @rts14 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @zptemp, and @rts14 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14, and support for unofficial opcodes | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #4 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
|} | |} | ||
=== | === 46 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #9 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #9 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | !colspan="2"|8 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #7 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
!colspan="2"| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #8 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
@ | LDY #7 | ||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDA # | SEC | ||
@A | LDA #8 | ||
@A: | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
JSR @rts14 | |||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | TYA | ||
PHA | PHA | ||
Line 3,673: | Line 3,954: | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY | TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | ||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PLP | |||
PHP | |||
PLP | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | |||
LDA #3 | |||
@A: | |||
PHP | |||
PLP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #3 | |||
@A: | |||
PHP | |||
PLP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #5 | ||
@Y: | @Y: | ||
DEY | DEY | ||
Line 3,685: | Line 4,004: | ||
PLA | PLA | ||
TAY | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PLP | PLP | ||
JSR @ | JSR @rts12 | ||
JSR @ | JSR @rts12 | ||
JSR @ | JSR @rts12</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts12 | ||
|- | |- | ||
!colspan="2"|13 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #5 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 47 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
LDX #8 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
LDY #8 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"|8 bytes | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
LDX #6 | LDX #6 | ||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDY #6 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
SEC | SEC | ||
LDA #8 | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | ||
|- | |||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | ||
PHA | |||
LDY #7 | |||
@ | @Y: | ||
DEY | |||
BNE @ | BNE @Y | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | | JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
|- | !colspan="2"|11 bytes | ||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 3,796: | Line 4,142: | ||
=== | === 48 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #9 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #9 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #8 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #8 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | LDA $00 | ||
SEC | |||
LDA #7 | |||
@A: | |||
@ | SBC #1 | ||
BNE @A | |||
BNE @ | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PLA | LDA $00 | ||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
JSR @rts15 | |||
JSR @rts15 | |||
= | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and V; and requires @rts15 | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | NOP | ||
JSR @ | JSR @rts14 | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
@ | JSR @rts15 | ||
JSR @ | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @zptemp, and @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
@ | JSR @rts14 | ||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
@ | JSR @rts15 | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15, and support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12</nowiki></pre> || style="padding:2px" | Requires @rts12 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHA | |||
TYA | |||
PHA | PHA | ||
LDY # | LDY #5 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | |||
SEC | SEC | ||
LDA # | LDA #4 | ||
@A: | @A: | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
@ | SEC | ||
NOP | LDA #130 | ||
NOP | @A = * - 1 | ||
; ^ Hides !NOP #imm | |||
NOP $EA ;hides 'NOP' | |||
PHP | |||
PLP</nowiki></pre> || style="padding:2px" | | PLP | ||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|14 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #5 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 4,008: | Line 4,330: | ||
=== | === 49 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | |||
@Y: | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | ||
LDX # | |||
@X: | @X: | ||
PHA | |||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #4 | ||
LDY # | |||
@Y: | @Y: | ||
PHP | |||
PLP | |||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #4 | ||
@X: | |||
@ | PHP | ||
PLP | |||
BNE @ | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHP | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PLA | |||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
TYA | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
PHA | PHA | ||
LDY #7 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 4,095: | Line 4,402: | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | NOP | ||
PHP | |||
LDY #7 | LDY #7 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
LDX #7 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #6 | ||
@Y: | @Y: | ||
DEY | DEY | ||
Line 4,117: | Line 4,439: | ||
PLA | PLA | ||
TAY | TAY | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PLP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
!colspan="2"|12 bytes | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
PHA | PHA | ||
LDY # | SEC | ||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 50 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #7 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #7 | |||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | LDX #6 | ||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #6 | ||
@Y: | @Y: | ||
NOP | NOP | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #9 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
NOP | |||
LDA # | |||
@A | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
Line 4,202: | Line 4,518: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 4,210: | Line 4,526: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 4,216: | Line 4,532: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15 | JSR @rts15 | ||
JSR @rts15 | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
BIT $00 | |||
JSR @rts15 | |||
JSR @rts15 | |||
@ | JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and V; and requires @rts15 | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts12 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts12, and @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
STA @zptemp | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @zptemp, and @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | | PLP</nowiki></pre> || style="padding:2px" | Clobbers S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP $00 | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15, and support for unofficial opcodes | |||
NOP $ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|13 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 4,285: | Line 4,598: | ||
=== | === 51 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|5 bytes | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #10 | ||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #10 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | !colspan="2"|8 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #8 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #8 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #6 | |||
@A: | |||
PHA | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | BIT $00 | ||
LDY #8 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDX #8 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA #4 | |||
@ | @A: | ||
PHP | PHP | ||
PLP | PLP | ||
SBC #1 | |||
BNE @ | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"|10 bytes | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | |||
@ | PHA | ||
LDY #7 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |- | ||
!colspan="2"|11 bytes | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
TYA | |||
PHA | PHA | ||
LDY #7 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 4,377: | Line 4,689: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHP | |||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A = | @A: | ||
; | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHA | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | PHA | ||
TYA | TYA | ||
Line 4,410: | Line 4,739: | ||
PLA | PLA | ||
TAY | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PLP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #6 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
Line 4,416: | Line 4,776: | ||
=== | === 52 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #7 | |||
@Y: | @Y: | ||
NOP | NOP | ||
Line 4,426: | Line 4,787: | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #7 | |||
@X: | @X: | ||
NOP | NOP | ||
Line 4,432: | Line 4,794: | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #7 | ||
@A | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #8 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY # | PHP | ||
LDY #6 | |||
@Y: | @Y: | ||
NOP | NOP | ||
Line 4,451: | Line 4,823: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | PHP | ||
LDX #6 | |||
@X: | @X: | ||
NOP | NOP | ||
Line 4,459: | Line 4,832: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
|} | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #6 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== | === 53 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #10 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | LDX #9 | ||
@X: | @X: | ||
DEX | DEX | ||
Line 4,497: | Line 4,893: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #9 | ||
@Y: | @Y: | ||
DEY | DEY | ||
Line 4,504: | Line 4,900: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #10 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | LDA $00 | ||
SEC | |||
LDA #8 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A = | @A: | ||
SBC #1 | |||
BNE @A | |||
NOP | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | PHP | ||
PLP | PLP | ||
JSR @rts14 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
PHA | |||
JSR @rts15 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Clobbers S; and requires @rts15 | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|13 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | |||
@ | LDA #3 | ||
@A: | |||
PHP | |||
PLP | |||
SBC #1 | |||
BNE @A | |||
BNE @ | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} | ||
=== | === 54 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY # | LDY #10 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY #10 | |||
LDA | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDX # | LDX #10 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDY #10 | |||
@Y: | |||
@ | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
|- | |||
BNE @ | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #10 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
LDY #10 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
LDY # | LDY #10 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
LDX # | LDX #10 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A: | @A: | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
PHP | |||
LDY #8 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHP | |||
LDX #8 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | ||
PHA | PHA | ||
LDY #6 | |||
BNE @ | @Y: | ||
NOP | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | PHP | ||
LDX #6 | |||
NOP | |||
LDX # | |||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
NOP | NOP | ||
PHP | |||
LDY #6 | LDY #6 | ||
@Y: | @Y: | ||
Line 4,776: | Line 5,116: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
TYA | TYA | ||
PHA | PHA | ||
Line 4,792: | Line 5,129: | ||
PLA | PLA | ||
TAY | TAY | ||
PLA | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #6 | |||
@A: | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
@ | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 4,866: | Line 5,157: | ||
=== | === 55 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | ||
LDY # | @Y: | ||
PLA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | |||
@X: | |||
PLA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | |||
@Y: | |||
NOP | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | |||
@X: | |||
NOP | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #9 | |||
@Y: | @Y: | ||
DEY | DEY | ||
Line 4,877: | Line 5,199: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | PHP | ||
LDX #9 | |||
@X: | @X: | ||
DEX | DEX | ||
Line 4,884: | Line 5,207: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA # | SEC | ||
LDA #10 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts12 | ||
JSR @rts14 | |||
@ | |||
JSR @rts14 | JSR @rts14 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts12, @rts14, and @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | |||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|13 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
LDA $00 | |||
SEC | |||
LDA #7 | |||
@A: | |||
SEC | |||
LDA # | |||
@A | |||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
|} | |} | ||
=== | === 56 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #9 | !colspan="2"|8 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #9 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX # | PHP | ||
@X: | LDX #9 | ||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #10 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #4 | |||
@X: | |||
PHP | |||
PLP | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
Line 5,034: | Line 5,317: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #4 | ||
@Y: | @Y: | ||
PHP | |||
PLP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
SEC | SEC | ||
LDA # | LDA #10 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | |||
PHA | |||
@ | LDY #8 | ||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |- | ||
!colspan="2"|11 bytes | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #6 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY | TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | ||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHP | |||
= | SEC | ||
LDA #8 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
PHA | PHA | ||
SEC | |||
BNE @ | LDA #8 | ||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
TYA | |||
PHA | |||
LDY #7 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | NOP | ||
PHP | |||
SEC | |||
BNE @ | LDA #6 | ||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | ||
@ | JSR @rts14 | ||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
!colspan="2"|13 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | NOP | ||
PHP | |||
PHA | |||
SEC | |||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
| | |} | ||
=== 57 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #8 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #8 | ||
@X: | @X: | ||
NOP | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
Line 5,153: | Line 5,436: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #8 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #8 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #136 | |||
@A = * - 1 | |||
; ^ Hides DEY | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #7 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #7 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | ||
PHA | |||
LDY #9 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 5,167: | Line 5,489: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 5,175: | Line 5,498: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 5,192: | Line 5,513: | ||
=== | === 58 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #11 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #11 | |||
@Y: | @Y: | ||
DEY | DEY | ||
Line 5,208: | Line 5,531: | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY #10 | |||
@ | @Y: | ||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #10 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
Line 5,227: | Line 5,553: | ||
!colspan="2"|10 bytes | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #4 | ||
@A: | @A: | ||
PHP | |||
PLP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #4 | |||
=== | @A: | ||
PHP | |||
!colspan="2"| | PLP | ||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts15 | |||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts14, and @rts15 | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHA | PHA | ||
TYA | |||
PHA | PHA | ||
LDY #7 | |||
@Y: | |||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14 | |||
JSR @rts14</nowiki></pre> || style="padding:2px" | Requires @rts14 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
PHP | |||
PHA | PHA | ||
SEC | |||
BNE @ | LDA #7 | ||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|14 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
PHP | |||
PHA | |||
BNE @ | SEC | ||
LDA #7 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | |} | ||
=== 59 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #11 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #8 | |||
@Y: | @Y: | ||
NOP | NOP | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #8 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA #8 | LDA #8 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDX # | LDY #7 | ||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #7 | |||
@X: | @X: | ||
NOP | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #7 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #7 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
LDA # | |||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | |||
PHA | PHA | ||
LDY #8 | LDY #8 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
LDA # | SEC | ||
@A | LDA #6 | ||
@A: | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |} | ||
@A | === 60 cycles === | ||
; | {| class="wikitable" | ||
!colspan="2"|6 bytes | |||
|- | |||
BNE @ | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDX #11 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDX #11 | |||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDY #10 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #10 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
SEC | |||
@ | LDA #11 | ||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
BNE @ | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
@ | SEC | ||
LDA #10 | |||
@A: | |||
SBC #1 | |||
BNE @ | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #10 | |||
LDA # | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JSR @rts15 | ||
JSR @rts15 | |||
@ | JSR @rts15 | ||
JSR @rts15</nowiki></pre> || style="padding:2px" | Requires @rts15 | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | PHA | ||
SEC | |||
@ | LDA #8 | ||
@A: | |||
BNE @ | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
LDA $00 | |||
@ | SEC | ||
LDA #8 | |||
BNE @ | @A: | ||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
|} | |} | ||
=== | === 61 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #12 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #12 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDY #10 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDX #10 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #11 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDY #10 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
LDX #10 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | SEC | ||
LDA #8 | |||
@A: | |||
NOP | |||
BNE @ | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TXA | ||
PHA | PHA | ||
LDX #7 | |||
@X: | @X: | ||
NOP | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X | ||
PLA | |||
TAX</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
NOP | SEC | ||
LDA #7 | |||
@A: | |||
@ | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | |||
PLP | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | PHA | ||
SEC | |||
LDA #7 | |||
@A: | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
BNE @ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #6 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | PLA | ||
TAY | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | !colspan="2"|13 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
!colspan="2"| | |} | ||
=== 62 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
LDY # | LDY #11 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
LDX #11 | |||
@X: | |||
@ | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | NOP | ||
LDX #11 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | NOP | ||
NOP | NOP | ||
LDY #11 | |||
@Y: | |||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
PLA | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #11 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TXA | ||
@ | PHA | ||
LDX #10 | |||
BNE @ | @X: | ||
DEX | |||
BNE @X | |||
PLA | |||
TAX</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #6 | |||
@X: | @X: | ||
NOP | |||
NOP | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #6 | ||
@Y: | @Y: | ||
NOP | |||
NOP | NOP | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
!colspan="2"|10 bytes | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA # | PHP | ||
SEC | |||
LDA #10 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
!colspan="2"|11 bytes | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
SEC | |||
LDA #10 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
Line 5,817: | Line 6,107: | ||
=== | === 63 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #12 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #12 | LDY #12 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | LDX #11 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA #12 | |||
SEC | |||
LDA # | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"|10 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
@ | PHP | ||
SEC | |||
LDA #10 | |||
BNE @ | @A: | ||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
SEC | |||
LDA #10 | |||
LDA # | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #10 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #10 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|13 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
TYA | |||
@ | PHA | ||
LDY #6 | |||
@Y: | |||
NOP | NOP | ||
DEY | |||
BNE @ | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
PHP | |||
PHA | |||
SEC | SEC | ||
LDA # | LDA #8 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|14 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #6 | ||
@A: | @A: | ||
NOP | NOP | ||
Line 5,957: | Line 6,230: | ||
=== | === 64 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #9 | ||
LDY # | |||
@Y: | @Y: | ||
NOP | NOP | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #9 | ||
LDX # | |||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY #8 | |||
@Y: | |||
NOP | |||
@ | DEY | ||
BNE @Y | |||
BNE @ | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #8 | |||
LDX # | |||
@X: | @X: | ||
NOP | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
Line 6,023: | Line 6,268: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #136 | ||
@A | @A = * - 1 | ||
; ^ Hides DEY | |||
SBC #1 | SBC #1 | ||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #136 | ||
@A | @A = * - 1 | ||
; ^ Hides DEY | |||
SBC #1 | SBC #1 | ||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #9 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 6,051: | Line 6,297: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
PHA | PHA | ||
SEC | |||
LDA # | LDA #9 | ||
@A | @A: | ||
SBC #1 | |||
BNE @A | BNE @A | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
Line 6,084: | Line 6,313: | ||
=== | === 65 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #8 | |||
@X: | |||
PHA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #8 | |||
@Y: | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDY #12 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDX #12 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDY #11 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | PHP | ||
LDX #11 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
!colspan="2"| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
SEC | |||
LDA #12 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 6,171: | Line 6,382: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #9 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
!colspan="2"|13 bytes | !colspan="2"|13 bytes | ||
Line 6,184: | Line 6,405: | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | |||
LDA #4 | |||
@A: | |||
@ | PHP | ||
PLP | |||
BNE @ | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
Line 6,198: | Line 6,418: | ||
=== | === 66 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #13 | ||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #13 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | |||
|- | |- | ||
!colspan="2"|9 | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
|- | LDA #137 | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | @A = * - 1 | ||
PHA | ; ^ Hides !NOP #imm | ||
LDX # | NOP | ||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #11 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | PHP | ||
PLP | LDY #8 | ||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | PHP | ||
LDX #8 | |||
@X: | |||
NOP | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
!colspan="2"|10 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA #12 | LDA #8 | ||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #8 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #7 | |||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 6,266: | Line 6,523: | ||
=== | === 67 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|6 | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | |||
@Y: | |||
PHA | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | ||
@X: | @X: | ||
PHA | |||
PHA | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #6 | ||
@Y: | @Y: | ||
NOP | |||
NOP | |||
NOP | NOP | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #6 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
LDX # | |||
@X: | @X: | ||
NOP | |||
NOP | |||
NOP | |||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDY # | LDA #8 | ||
@A: | |||
PHA | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDX #11 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #11 | |||
@Y: | @Y: | ||
DEY | DEY | ||
Line 6,298: | Line 6,595: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #10 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} | ||
=== | === 68 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #13 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #12 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY #12 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
!colspan="2"| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TXA | ||
PHA | |||
LDX #8 | |||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X | ||
PLA | |||
TAX</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
@ | PHP | ||
SEC | |||
LDA #11 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
BNE @ | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
SEC | |||
LDA #11 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | @A: | ||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA # | PHP | ||
SEC | |||
LDA #8 | |||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA # | PHA | ||
@A | SEC | ||
LDA #8 | |||
@A: | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TXA | |||
PHA | PHA | ||
LDX #7 | |||
@ | @X: | ||
NOP | |||
BNE @ | DEX | ||
BNE @X | |||
PLA | PLA | ||
TAX | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | !colspan="2"|13 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | PHA | ||
SEC | |||
@ | LDA #7 | ||
@A: | |||
BNE @ | NOP | ||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
|} | |} | ||
=== | === 69 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY #13 | |||
@ | @Y: | ||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
BNE @ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDX #13 | |||
@X: | |||
@ | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
BNE @ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY #13 | |||
LDA | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA # | SEC | ||
LDA #137 | |||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides | ; ^ Hides !NOP #imm | ||
NOP | |||
SBC #1 | SBC #1 | ||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes | ||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
@ | PHP | ||
; | LDX #11 | ||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDY #11 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #6 | ||
@A | @A: | ||
PHA | |||
PHA | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDA # | SEC | ||
LDA #137 | |||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides | ; ^ Hides !NOP #imm | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | ||
Line 6,581: | Line 6,879: | ||
!colspan="2"|10 bytes | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | |||
PHA | PHA | ||
LDY #11 | |||
@Y: | |||
DEY | |||
@ | BNE @Y | ||
BNE @ | |||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
LDY #11 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
NOP | NOP | ||
PHP | |||
LDX #11 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TXA | |||
PHA | PHA | ||
LDX #10 | |||
@ | @X: | ||
DEX | |||
BNE @ | BNE @X | ||
PLA | PLA | ||
TAX | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | PHP | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #10 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 6,665: | Line 6,948: | ||
=== | === 70 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDX # | LDX #13 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDY # | LDY #13 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDX #13 | |||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDY #12 | |||
LDX # | @Y: | ||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #12 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #12 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #12 | |||
@A: | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA # | |||
@A | |||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA # | PHP | ||
PHA | |||
SEC | |||
LDA #10 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers | BNE @A | ||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|13 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
LDY # | LDA $00 | ||
SEC | |||
LDA #10 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 71 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|5 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #14 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | LDX #9 | ||
@X: | @X: | ||
NOP | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #9 | ||
@Y: | @Y: | ||
NOP | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #13 | |||
@A: | |||
@ | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
BNE @ | |- | ||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | |||
PHA | PHA | ||
LDY #11 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
@ | SEC | ||
LDA #136 | |||
@A = * - 1 | |||
; ^ Hides DEY | |||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
|} | |} | ||
=== | === 72 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
LDY #13 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | |||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
NOP | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #12 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX # | LDX #8 | ||
@X: | @X: | ||
BIT $00 | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
Line 6,859: | Line 7,191: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #8 | ||
@Y: | @Y: | ||
BIT $00 | |||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #12 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 6,876: | Line 7,209: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | |||
SEC | SEC | ||
LDA # | LDA #12 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 6,884: | Line 7,218: | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|11 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
Line 6,928: | Line 7,233: | ||
=== | === 73 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX #14 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY # | LDY #13 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | |||
@ | LDA #137 | ||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP | NOP | ||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
@ | LDA #137 | ||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP | NOP | ||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | SEC | ||
LDA # | LDA #9 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
!colspan="2"|12 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | |||
LDA # | SEC | ||
@A | LDA #8 | ||
@A: | |||
NOP | NOP | ||
SBC #1 | |||
BNE @A | BNE @A | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
Line 7,040: | Line 7,329: | ||
=== | === 74 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX #14 | |||
@ | @X: | ||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
BNE @ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY #14 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDY #14 | |||
@Y: | |||
@ | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
BNE @ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | ||
LDX #14 | |||
@X: | |||
@ | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
BNE @ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #14 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDX # | LDX #14 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
LDX #14 | |||
@ | @X: | ||
DEX | |||
BNE @ | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDY #9 | |||
@ | @Y: | ||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDX #9 | |||
@ | @X: | ||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PLA | |||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | |||
PHA | PHA | ||
LDY #12 | |||
@ | @Y: | ||
DEY | |||
BNE @Y | |||
BNE @ | |||
PLA | PLA | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #6 | |||
LDX # | |||
@X: | @X: | ||
NOP | NOP | ||
NOP | NOP | ||
NOP | |||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
|- | LDY #6 | ||
!colspan="2"| | @Y: | ||
NOP | |||
NOP | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #11 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 7,222: | Line 7,481: | ||
TAY | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #12 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #11 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} | ||
=== | === 75 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|6 bytes | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDX #14 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | ||
|- | |- | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
LDX #14 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDY #13 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
@ | SEC | ||
LDA #14 | |||
@A: | |||
BNE @ | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | LDA #13 | ||
@ | @A: | ||
SBC #1 | |||
BNE @A | |||
BNE @ | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #13 | |||
@A: | |||
LDA # | |||
@A | |||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TXA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
TXA | |||
PHA | PHA | ||
LDX # | LDX #8 | ||
@X: | @X: | ||
NOP | NOP | ||
Line 7,345: | Line 7,594: | ||
BNE @X | BNE @X | ||
PLA | PLA | ||
TAX</nowiki></pre> || style="padding:2px" | Clobbers | TAX | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
PHA | PHA | ||
SEC | |||
@ | LDA #11 | ||
@A: | |||
BNE @ | SBC #1 | ||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
PHA | PHA | ||
SEC | |||
@ | LDA #8 | ||
@A: | |||
BNE @ | NOP | ||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
|} | |} | ||
=== | === 76 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #15 | ||
@X: | |||
DEX | |||
@ | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
BNE @ | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #15 | ||
@Y: | |||
DEY | |||
@ | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
BNE @ | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDX #13 | |||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #13 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | LDA #14 | ||
LDA # | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | ||
Line 7,461: | Line 7,666: | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | BIT $00 | ||
LDY #13 | |||
BNE @ | @Y: | ||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDA # | SEC | ||
LDA #14 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | |||
PHA | |||
LDY #12 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | SEC | ||
LDA #137 | LDA #137 | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides !NOP #imm | ; ^ Hides !NOP #imm | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BMI @A | BMI @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S; and requires support for unofficial opcodes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | |||
SEC | SEC | ||
LDA #137 | LDA #137 | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides !NOP #imm | ; ^ Hides !NOP #imm | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BMI @A | BMI @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C; and requires support for unofficial opcodes | ||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #8 | |||
@Y: | |||
LDA $00 | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA # | PHP | ||
SEC | |||
LDA #9 | |||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
SEC | SEC | ||
LDA #9 | LDA #9 | ||
@A: | @A: | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #137 | ||
@A | @A = * - 1 | ||
; ^ Hides !NOP #imm | |||
NOP | NOP | ||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHA | PHA | ||
TYA | |||
PHA | PHA | ||
LDY #11 | |||
@ | @Y: | ||
DEY | |||
BNE @ | BNE @Y | ||
PLA | PLA | ||
TAY | |||
PLA | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | |||
LDA #6 | |||
= | @A: | ||
NOP | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
!colspan="2"|13 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | NOP | ||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 7,614: | Line 7,819: | ||
=== | === 77 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|7 bytes | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY # | PHA | ||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | NOP | ||
NOP | |||
LDX #14 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDA # | SEC | ||
LDA #14 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | ||
PHA | PHA | ||
LDY # | LDY #13 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 7,651: | Line 7,873: | ||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
NOP | |||
PHP | |||
LDX #13 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | ||
|- | |||
!colspan="2"|11 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | |||
LDA # | LDA #12 | ||
@A | @A: | ||
SBC #1 | |||
BNE @A | BNE @A | ||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
|} | |} | ||
=== | === 78 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | ||
@Y: | |||
@ | |||
NOP | NOP | ||
DEY | |||
BNE @ | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDY #14 | |||
@Y: | |||
@ | DEY | ||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
BNE @ | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDX #14 | |||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
BNE @ | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA | PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | ||
|- | |- | ||
!colspan="2"|11 bytes | |||
!colspan="2"| | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 7,763: | Line 7,996: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA $00 | |||
SEC | SEC | ||
LDA # | LDA #13 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
Line 7,773: | Line 8,007: | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PLP | |||
PHP | |||
PHA | PHA | ||
SEC | SEC | ||
Line 7,778: | Line 8,014: | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides DEY | ; ^ Hides DEY | ||
SBC #1 | SBC #1 | ||
BMI @A | BMI @A | ||
Line 7,787: | Line 8,022: | ||
=== | === 79 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDY #15 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDX #15 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|7 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDY # | LDY #15 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
LDX # | LDX #15 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDY #15 | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDX #15 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDY #15 | |||
@Y: | |||
@ | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | ||
LDX #15 | |||
@X: | |||
@ | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | ||
LDX #15 | |||
LDX # | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | ||
LDY #15 | |||
LDY # | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #15 | |||
@X: | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | |||
@X: | |||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
Line 7,921: | Line 8,104: | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHA | PHA | ||
LDX # | PHP | ||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PLA | |||
SEC | SEC | ||
LDA # | LDA #14 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | ||
|- | |||
!colspan="2"|10 bytes | |||
|- | |- | ||
| | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
TYA | |||
PHA | |||
== | LDY #13 | ||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | NOP | ||
NOP | |||
PHP | |||
LDX #13 | |||
@X: | @X: | ||
DEX | DEX | ||
Line 7,956: | Line 8,162: | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | PLP</nowiki></pre> || style="padding:2px" | Clobbers X | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | !colspan="2"|11 bytes | ||
LDY # | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #12 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDA # | NOP | ||
PHP | |||
SEC | |||
LDA #13 | |||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
PHP | |||
PHA | |||
SEC | SEC | ||
LDA # | LDA #12 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A | ||
PLA | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | ||
|- | |- | ||
Line 8,038: | Line 8,201: | ||
=== | === 80 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"|6 bytes | !colspan="2"|6 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDY #15 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
LDX #15 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | ||
|- | |||
!colspan="2"|7 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #11 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDX # | LDX #11 | ||
@X: | @X: | ||
NOP | NOP | ||
DEX | DEX | ||
BNE @X | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |||
!colspan="2"|8 bytes | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | ||
LDY # | PHP | ||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | ||
LDA # | LDA #11 | ||
@A: | @A: | ||
NOP | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
SEC | SEC | ||
LDA # | LDA #14 | ||
@A | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | PLP</nowiki></pre> || style="padding:2px" | Clobbers A | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | SEC | ||
LDA #137 | LDA #137 | ||
@A = * - 1 | @A = * - 1 | ||
; ^ Hides !NOP #imm | ; ^ Hides !NOP #imm | ||
NOP | NOP | ||
SBC #1 | SBC #1 | ||
BMI @A | BMI @A | ||
PLA</nowiki></pre> || style="padding:2px" | | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |- | ||
!colspan="2"| | !colspan="2"|12 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
PHA | PHA | ||
SEC | |||
@ | LDA #9 | ||
@A: | |||
BNE @ | NOP | ||
SBC #1 | |||
BNE @A | |||
PLA | PLA | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | |||
|- | |- | ||
|} | |} | ||
=== | === 81 cycles === | ||
{| class="wikitable" | {| class="wikitable" | ||
!colspan="2"| | !colspan="2"|5 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #16 | ||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers | BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #16 | ||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers | BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|8 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDY #14 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX # | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
PHP | |||
LDX #14 | |||
@X: | @X: | ||
DEX | DEX | ||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and | BNE @X | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | ||
LDA # | SEC | ||
@A | LDA #15 | ||
@A: | |||
SBC #1 | SBC #1 | ||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |- | ||
!colspan="2"|9 bytes | !colspan="2"|9 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | ||
BIT $00 | |||
LDY #14 | |||
@ | @Y: | ||
DEY | |||
BNE @ | BNE @Y | ||
PLP</nowiki></pre> || style="padding:2px" | Clobbers | PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | ||
SEC | SEC | ||
LDA # | LDA #15 | ||
@A: | @A: | ||
SBC #1 | SBC #1 | ||
BNE @A | BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | ||
|- | |- | ||
!colspan="2"| | !colspan="2"|10 bytes | ||
|- | |- | ||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki> | | style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | ||
TYA | TYA | ||
PHA | PHA | ||
LDY # | LDY #13 | ||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
TYA | |||
PHA | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
TYA | |||
PHA | |||
LDY #12 | |||
@Y: | @Y: | ||
DEY | DEY | ||
BNE @Y | BNE @Y | ||
Line 8,208: | Line 8,428: | ||
TAY | TAY | ||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | ||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #12 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 82 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #9 | |||
@Y: | |||
PLA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #9 | |||
@X: | |||
PLA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #9 | |||
@Y: | |||
NOP | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #9 | |||
@X: | |||
NOP | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 83 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #15 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDA $00 | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDA $00 | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP | |||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #8 | |||
@Y: | |||
LDA $00 | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
PHP | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP | |||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|14 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #6 | |||
@A: | |||
NOP | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 84 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>BIT $00 | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>STA @zptemp | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP $00 | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>JMP *+3 | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
LDX #14 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 85 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #12 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #12 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #11 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #11 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
LDA $00 | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 86 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|5 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #17 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #15 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDX #15 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
TYA | |||
PHA | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 87 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #12 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #12 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #11 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #11 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #11 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #11 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 88 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDA $00 | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDA $00 | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHA | |||
TYA | |||
PHA | |||
LDY #13 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|14 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #13 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 89 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
PHA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
LDA $00 | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
LDA $00 | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
BIT $00 | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
BIT $00 | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, Z&N, and V | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
STA @zptemp | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
STA @zptemp | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires @zptemp | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
NOP $00 | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
NOP $00 | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
JMP *+3 | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
JMP *+3 | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #9 | |||
@Y: | |||
NOP | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #9 | |||
@X: | |||
NOP | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TXA | |||
PHA | |||
LDX #11 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLA | |||
TAX</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #11 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 90 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
LDA $00 | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 91 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|5 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #18 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $48 ;hides 'PHA' | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #11 | |||
@A: | |||
PHA | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDX #16 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
BIT $00 | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDA $00 | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
TYA | |||
PHA | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, S, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 92 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #13 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #13 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA44 ;hides 'NOP zp' | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #12 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #12 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 93 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDA $00 | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDA $00 | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHA | |||
TYA | |||
PHA | |||
LDY #14 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|14 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #14 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 94 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #13 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #13 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #13 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #12 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #12 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #15 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #11 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 95 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
LDA $00 | |||
SEC | |||
LDA #15 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 96 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|5 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #19 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #19 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #11 | |||
@Y: | |||
BIT $00 | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #11 | |||
@X: | |||
BIT $00 | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #13 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #12 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
SEC | |||
LDA #12 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TXA | |||
PHA | |||
LDX #11 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLA | |||
TAX | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #11 | |||
@A: | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 97 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #12 | |||
@X: | |||
PHA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #12 | |||
@Y: | |||
PHA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #8 | |||
@X: | |||
PHP | |||
PLP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #8 | |||
@Y: | |||
PHP | |||
PLP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PLA | |||
SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>TYA | |||
PHA | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
LDX #17 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHA | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 98 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDY #19 | |||
@Y: | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
LDX #19 | |||
@X: | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #19 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A, and S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHA | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers S, Z&N, and C | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #11 | |||
@A: | |||
BIT $00 | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
LDA $00 | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
SEC | |||
LDA #9 | |||
@A: | |||
NOP | |||
NOP | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 99 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #14 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #14 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDX #13 | |||
@X: | |||
NOP | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
LDY #13 | |||
@Y: | |||
NOP | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #12 | |||
@A: | |||
PHA | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, S, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #8 | |||
@A: | |||
PHP | |||
PLP | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA44 ;hides 'NOP zp' | |||
SBC #1 | |||
BMI @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A; and requires support for unofficial opcodes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA44 ;hides 'NOP zp' | |||
SBC #1 | |||
BMI @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|10 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
TYA | |||
PHA | |||
LDY #17 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY</nowiki></pre> || style="padding:2px" | Clobbers A, and Z&N | |||
|- | |||
!colspan="2"|11 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
TYA | |||
PHA | |||
LDY #16 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLA | |||
TAY | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
NOP | |||
PHP | |||
SEC | |||
LDA #17 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |||
|} | |||
=== 100 cycles === | |||
{| class="wikitable" | |||
!colspan="2"|6 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
PLA | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers A, Y, S, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
PLA | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers A, X, S, and Z&N | |||
|- | |||
!colspan="2"|7 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDX #11 | |||
@X: | |||
NOP | |||
NOP | |||
DEX | |||
BNE @X</nowiki></pre> || style="padding:2px" | Clobbers X, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>LDY #11 | |||
@Y: | |||
NOP | |||
NOP | |||
DEY | |||
BNE @Y</nowiki></pre> || style="padding:2px" | Clobbers Y, and Z&N | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EAEA ;hides two 'NOP's | |||
SBC #1 | |||
BMI @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C; and requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|8 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDY #18 | |||
@Y: | |||
DEY | |||
BNE @Y | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers Y | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
LDX #18 | |||
@X: | |||
DEX | |||
BNE @X | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers X | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
SEC | |||
LDA #19 | |||
@A: | |||
SBC #1 | |||
BNE @A</nowiki></pre> || style="padding:2px" | Clobbers A, Z&N, and C | |||
|- | |||
!colspan="2"|9 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers A | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
SEC | |||
LDA #18 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA</nowiki></pre> || style="padding:2px" | Clobbers Z&N, and C | |||
|- | |||
!colspan="2"|12 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHA | |||
PHP | |||
PHA | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers S | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>NOP | |||
PHP | |||
PHA | |||
SEC | |||
LDA #137 | |||
@A = * - 1 | |||
; ^ Hides !NOP #imm | |||
NOP $EA,X ;hides 'NOP' | |||
SBC #1 | |||
BMI @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Requires support for unofficial opcodes | |||
|- | |||
!colspan="2"|13 bytes | |||
|- | |||
| style="padding:2px" |<pre style="margin:2px;padding:3px"><nowiki>PHP | |||
PHA | |||
LDA $00 | |||
SEC | |||
LDA #16 | |||
@A: | |||
SBC #1 | |||
BNE @A | |||
PLA | |||
PLP</nowiki></pre> || style="padding:2px" | Clobbers nothing, requires nothing | |||
|- | |- | ||
|} | |} |
Revision as of 01:21, 14 March 2016
Delay code
Shortest possible CPU code that creates N cycles of delay, depending on constraints.
All branch instructions assume that no page wrap occurs.
Explanations on the requirements:
- @zp_temp means you have a zeropage address that you can write random data into.
- @rts12 means you know a memory address that contains byte $60 (
RTS
). - @rts14 means you know a memory address that contains a harmless 2-cycle instruction that fits your constraints (such as
CLC
,LDA #0
, orNOP
), followed byRTS
. - @rts15 means you know a memory address that contains a
JMP
that jumps to another location that containsRTS
. - Alternatively, @rts15 means you know a memory address that contains a harmless 3-cycle instruction that fits your constraints (such as
LDA $00
), followed byRTS
. - @A, @X, @Y are local labels.
2 cycles
1 bytes | |
---|---|
NOP |
Clobbers nothing, requires nothing |
3 cycles
1 bytes | |
---|---|
PHA |
Clobbers S |
2 bytes | |
LDA $00 |
Clobbers A, and Z&N |
BIT $00 |
Clobbers Z&N, and V |
STA @zptemp |
Requires @zptemp |
NOP $00 |
Requires support for unofficial opcodes |
3 bytes | |
JMP *+3 |
Clobbers nothing, requires nothing |
4 cycles
1 bytes | |
---|---|
PLA |
Clobbers A, S, and Z&N |
2 bytes | |
NOP NOP |
Clobbers nothing, requires nothing |
5 cycles
2 bytes | |
---|---|
NOP PHA |
Clobbers S |
3 bytes | |
NOP LDA $00 |
Clobbers A, and Z&N |
NOP BIT $00 |
Clobbers Z&N, and V |
NOP STA @zptemp |
Requires @zptemp |
NOP NOP $00 |
Requires support for unofficial opcodes |
4 bytes | |
NOP JMP *+3 |
Clobbers nothing, requires nothing |
6 cycles
2 bytes | |
---|---|
PHA PHA |
Clobbers S |
3 bytes | |
NOP NOP NOP |
Clobbers nothing, requires nothing |
7 cycles
2 bytes | |
---|---|
PHP PLP |
Clobbers nothing, requires nothing |
8 cycles
2 bytes | |
---|---|
PLA PLA |
Clobbers A, S, and Z&N |
3 bytes | |
TSX PLA TXS |
Clobbers A, X, and Z&N |
NOP PHA PHA |
Clobbers S |
4 bytes | |
NOP NOP NOP NOP |
Clobbers nothing, requires nothing |
9 cycles
3 bytes | |
---|---|
NOP PHP PLP |
Clobbers nothing, requires nothing |
10 cycles
3 bytes | |
---|---|
PHA PHP PLP |
Clobbers S |
4 bytes | |
PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
11 cycles
3 bytes | |
---|---|
PHA PLA PLA |
Clobbers A, S, and Z&N |
4 bytes | |
NOP NOP PHP PLP |
Clobbers nothing, requires nothing |
12 cycles
3 bytes | |
---|---|
JSR @rts12 |
Requires @rts12 |
PLA PLA PLA |
Clobbers A, S, and Z&N |
4 bytes | |
ROL $00,X ROR $00,X |
Clobbers Z&N |
NOP PHA PHP PLP |
Clobbers S |
5 bytes | |
NOP PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
13 cycles
4 bytes | |
---|---|
PHA PHA PHP PLP |
Clobbers S |
5 bytes | |
NOP NOP NOP PHP PLP |
Clobbers nothing, requires nothing |
14 cycles
3 bytes | |
---|---|
JSR @rts14 |
Requires @rts14 |
4 bytes | |
PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
15 cycles
3 bytes | |
---|---|
JSR @rts15 |
Requires @rts15 |
4 bytes | |
PHA JSR @rts12 |
Clobbers S; and requires @rts12 |
PHA PLA PLA PLA |
Clobbers A, S, and Z&N |
5 bytes | |
LDA $00 JSR @rts12 |
Clobbers A, and Z&N; and requires @rts12 |
PHA TSX PLA TXS PLA |
Clobbers X, and Z&N |
PHP TSX PLA TXS PLP |
Clobbers A, and X |
BIT $00 JSR @rts12 |
Clobbers Z&N, and V; and requires @rts12 |
STA @zptemp JSR @rts12 |
Requires @zptemp, and @rts12 |
NOP PHA PHA PHP PLP |
Clobbers S |
NOP $00 JSR @rts12 |
Requires @rts12, and support for unofficial opcodes |
6 bytes | |
NOP NOP NOP NOP PHP PLP |
Clobbers nothing, requires nothing |
16 cycles
4 bytes | |
---|---|
NOP JSR @rts14 |
Requires @rts14 |
PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
5 bytes | |
NOP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
17 cycles
4 bytes | |
---|---|
NOP JSR @rts15 |
Requires @rts15 |
PHA JSR @rts14 |
Clobbers S; and requires @rts14 |
5 bytes | |
LDA $00 JSR @rts14 |
Clobbers A, and Z&N; and requires @rts14 |
BIT $00 JSR @rts14 |
Clobbers Z&N, and V; and requires @rts14 |
STA @zptemp JSR @rts14 |
Requires @zptemp, and @rts14 |
PHA PHP PLP PHP PLP |
Clobbers S |
NOP $00 JSR @rts14 |
Requires @rts14, and support for unofficial opcodes |
6 bytes | |
PHP PLP PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
18 cycles
4 bytes | |
---|---|
PHA JSR @rts15 |
Clobbers S; and requires @rts15 |
PLA JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
5 bytes | |
LDA $00 JSR @rts15 |
Clobbers A, and Z&N; and requires @rts15 |
BIT $00 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
NOP NOP JSR @rts14 |
Requires @rts14 |
STA @zptemp JSR @rts15 |
Requires @zptemp, and @rts15 |
PHA PHA JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP $00 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
6 bytes | |
NOP NOP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
19 cycles
4 bytes | |
---|---|
PLA JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
5 bytes | |
PHP PLP JSR @rts12 |
Requires @rts12 |
NOP NOP JSR @rts15 |
Requires @rts15 |
PHA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP PHA JSR @rts14 |
Clobbers S; and requires @rts14 |
6 bytes | |
PHP ROL $00,X ROR $00,X PLP |
Clobbers nothing, requires nothing |
20 cycles
5 bytes | |
---|---|
NOP PHA JSR @rts15 |
Clobbers S; and requires @rts15 |
PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
PHA PHA JSR @rts14 |
Clobbers S; and requires @rts14 |
6 bytes | |
NOP LDA $00 JSR @rts15 |
Clobbers A, and Z&N; and requires @rts15 |
TSX PLA PLA PLA PLA TXS |
Clobbers A, X, and Z&N |
NOP BIT $00 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
NOP NOP NOP JSR @rts14 |
Requires @rts14 |
NOP STA @zptemp JSR @rts15 |
Requires @zptemp, and @rts15 |
PHA PHA PHP PLP PHP PLP |
Clobbers S |
NOP NOP $00 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
7 bytes | |
NOP NOP NOP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
21 cycles
5 bytes | |
---|---|
LDY #4 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #4 @X: DEX BNE @X |
Clobbers X, and Z&N |
PHP PLP JSR @rts14 |
Requires @rts14 |
PHA PHA JSR @rts15 |
Clobbers S; and requires @rts15 |
6 bytes | |
PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
22 cycles
5 bytes | |
---|---|
PHP PLP JSR @rts15 |
Requires @rts15 |
PLA PLA JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
6 bytes | |
LDY #3 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #3 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
PHA PHP PLP JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP PHA PHA JSR @rts14 |
Clobbers S; and requires @rts14 |
7 bytes | |
PHP BIT $00 PLP JSR @rts12 |
Requires @rts12 |
PHP PHA TSX PLA TXS PLA PLP |
Clobbers X |
NOP NOP NOP NOP JSR @rts14 |
Requires @rts14 |
NOP PHA PHA PHP PLP PHP PLP |
Clobbers S |
SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
NOP NOP NOP NOP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
23 cycles
5 bytes | |
---|---|
PLA PLA JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
6 bytes | |
NOP LDX #4 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #4 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP PHP PLP JSR @rts14 |
Requires @rts14 |
NOP PHA PHA JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
7 bytes | |
NOP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
24 cycles
6 bytes | |
---|---|
JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP PHP PLP JSR @rts15 |
Requires @rts15 |
PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
PHA LDX #4 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #4 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA PHP PLP JSR @rts14 |
Clobbers S; and requires @rts14 |
7 bytes | |
NOP LDX #3 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #3 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
PHP BIT $00 PLP JSR @rts14 |
Requires @rts14 |
PHA PHP PLP PHP PLP PHP PLP |
Clobbers S |
SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm .byte $0C,$E6,@zptemp ;NOP abs; hides 'INC @zptemp' SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires @zptemp, and support for unofficial opcodes |
8 bytes | |
PHP PLP PHP PLP PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
25 cycles
6 bytes | |
---|---|
PHA PHP PLP JSR @rts15 |
Clobbers S; and requires @rts15 |
LDY #3 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
LDX #3 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
PHA PLA PLA JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
7 bytes | |
PHP BIT $00 PLP JSR @rts15 |
Requires @rts15 |
LDY #2 @Y: PHP PLP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #2 @X: PHP PLP DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP PHP PLP JSR @rts14 |
Requires @rts14 |
PHA PHA PHP PLP JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PHA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
8 bytes | |
NOP NOP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
26 cycles
5 bytes | |
---|---|
LDY #5 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #5 @X: DEX BNE @X |
Clobbers X, and Z&N |
6 bytes | |
JSR @rts12 JSR @rts14 |
Requires @rts12, and @rts14 |
PHA PLA PLA JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
PLA PLA PLA JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
7 bytes | |
NOP JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP NOP PHP PLP JSR @rts15 |
Requires @rts15 |
ROL $00,X ROR $00,X JSR @rts14 |
Clobbers Z&N; and requires @rts14 |
NOP PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP PHA PHP PLP JSR @rts14 |
Clobbers S; and requires @rts14 |
SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
PHP PLP PHP ROL $00,X ROR $00,X PLP |
Clobbers nothing, requires nothing |
27 cycles
6 bytes | |
---|---|
JSR @rts12 JSR @rts15 |
Requires @rts12, and @rts15 |
PLA PLA PLA JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
7 bytes | |
ROL $00,X ROR $00,X JSR @rts15 |
Clobbers Z&N; and requires @rts15 |
PHA JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PHA PHP PLP JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP LDX #3 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
NOP LDY #3 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA PHA PHP PLP JSR @rts14 |
Clobbers S; and requires @rts14 |
8 bytes | |
NOP PHP BIT $00 PLP JSR @rts15 |
Requires @rts15 |
LDA $00 JSR @rts12 JSR @rts12 |
Clobbers A, and Z&N; and requires @rts12 |
PHA TSX PLA PLA PLA PLA TXS PLA |
Clobbers X, and Z&N |
NOP LDY #2 @Y: PHP PLP DEY BNE @Y |
Clobbers Y, and Z&N |
PHP TSX PLA PLA PLA PLA TXS PLP |
Clobbers A, and X |
BIT $00 JSR @rts12 JSR @rts12 |
Clobbers Z&N, and V; and requires @rts12 |
NOP NOP NOP PHP PLP JSR @rts14 |
Requires @rts14 |
STA @zptemp JSR @rts12 JSR @rts12 |
Requires @zptemp, and @rts12 |
PHA PHA PHP PLP PHP PLP PHP PLP |
Clobbers S |
NOP $00 JSR @rts12 JSR @rts12 |
Requires @rts12, and support for unofficial opcodes |
SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EAEA ;hides two 'NOP's NOP SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
9 bytes | |
NOP NOP NOP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
28 cycles
6 bytes | |
---|---|
NOP LDX #5 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #5 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
JSR @rts14 JSR @rts14 |
Requires @rts14 |
7 bytes | |
PHP LDX #4 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #4 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #5 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHA PHP PLP JSR @rts15 |
Clobbers S; and requires @rts15 |
PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
8 bytes | |
PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
29 cycles
6 bytes | |
---|---|
LDX #4 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #4 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
7 bytes | |
PHP PLP PHP PLP JSR @rts15 |
Requires @rts15 |
PHA JSR @rts12 JSR @rts14 |
Clobbers S; and requires @rts12, and @rts14 |
PHA PLA PLA PLA JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
8 bytes | |
PHP LDY #3 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #3 @X: NOP DEX BNE @X PLP |
Clobbers X |
LDA $00 JSR @rts12 JSR @rts14 |
Clobbers A, and Z&N; and requires @rts12, and @rts14 |
BIT $00 JSR @rts12 JSR @rts14 |
Clobbers Z&N, and V; and requires @rts12, and @rts14 |
STA @zptemp JSR @rts12 JSR @rts14 |
Requires @zptemp, @rts12, and @rts14 |
NOP PHA JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PHA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP PHA PHA PHP PLP JSR @rts14 |
Clobbers S; and requires @rts14 |
NOP $00 JSR @rts12 JSR @rts14 |
Requires @rts12, @rts14, and support for unofficial opcodes |
9 bytes | |
PHP PLP PHP BIT $00 PLP JSR @rts12 |
Requires @rts12 |
NOP NOP NOP NOP PHP PLP JSR @rts14 |
Requires @rts14 |
NOP PHA PHA PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
NOP NOP NOP NOP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
30 cycles
6 bytes | |
---|---|
JSR @rts15 JSR @rts15 |
Requires @rts15 |
PLA LDX #5 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #5 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #5 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #5 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP JSR @rts14 JSR @rts14 |
Requires @rts14 |
8 bytes | |
NOP PHP LDY #4 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #4 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #5 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHA JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
9 bytes | |
NOP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
31 cycles
5 bytes | |
---|---|
LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
NOP JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
PLA PLA PLA PLA JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
PHA JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
8 bytes | |
PHP PLP JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP PHP PLP PHP PLP JSR @rts15 |
Requires @rts15 |
SEC LDA #4 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
LDA $00 JSR @rts14 JSR @rts14 |
Clobbers A, and Z&N; and requires @rts14 |
BIT $00 JSR @rts14 JSR @rts14 |
Clobbers Z&N, and V; and requires @rts14 |
STA @zptemp JSR @rts14 JSR @rts14 |
Requires @zptemp, and @rts14 |
PHA PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
PHA PHP LDY #4 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #4 @X: DEX BNE @X PLP |
Clobbers X, and S |
NOP $00 JSR @rts14 JSR @rts14 |
Requires @rts14, and support for unofficial opcodes |
9 bytes | |
NOP PHP LDX #3 @X: NOP DEX BNE @X PLP |
Clobbers X |
NOP PHP LDY #3 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
JMP *+3 JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm .byte $0C,$E6,@zptemp ;NOP abs; hides 'INC @zptemp' SBC #1 BMI @A PLP |
Clobbers A; and requires @zptemp, and support for unofficial opcodes |
PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm .byte $0C,$E6,@zptemp ;NOP abs; hides 'INC @zptemp' SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires @zptemp, and support for unofficial opcodes |
10 bytes | |
PHP PLP PHP PLP PHP PLP PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
32 cycles
7 bytes | |
---|---|
NOP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHA LDX #4 @X: NOP DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #4 @Y: NOP DEY BNE @Y |
Clobbers Y, S, and Z&N |
PLA JSR @rts14 JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
8 bytes | |
NOP NOP NOP LDY #5 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP NOP LDX #5 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PLA PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
9 bytes | |
TYA PHA LDY #4 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHP LDX #2 @X: PHP PLP DEX BNE @X PLP |
Clobbers X |
PHP LDY #2 @Y: PHP PLP DEY BNE @Y PLP |
Clobbers Y |
NOP PHA PHA JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
10 bytes | |
NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
33 cycles
6 bytes | |
---|---|
NOP LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
PHP LDY #5 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #5 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #6 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
8 bytes | |
LDA $00 JSR @rts15 JSR @rts15 |
Clobbers A, and Z&N; and requires @rts15 |
BIT $00 JSR @rts15 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
PHP PLP JSR @rts12 JSR @rts14 |
Requires @rts12, and @rts14 |
NOP NOP JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
STA @zptemp JSR @rts15 JSR @rts15 |
Requires @zptemp, and @rts15 |
NOP PHA JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
NOP $00 JSR @rts15 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
9 bytes | |
NOP PHP PLP JSR @rts12 JSR @rts12 |
Requires @rts12 |
JMP *+3 JSR @rts15 JSR @rts15 |
Requires @rts15 |
JSR @rts14 PHP ROL $00,X ROR $00,X PLP |
Requires @rts14 |
NOP PHA PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
PHP PLP PHP PLP PHP ROL $00,X ROR $00,X PLP |
Clobbers nothing, requires nothing |
34 cycles
6 bytes | |
---|---|
PHA LDX #6 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #6 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDA $00 LDX #6 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
LDA $00 LDY #6 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
BIT $00 LDX #6 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
BIT $00 LDY #6 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
STA @zptemp LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
STA @zptemp LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
PLA JSR @rts15 JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
NOP $00 LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
NOP NOP JSR @rts15 JSR @rts15 |
Requires @rts15 |
JMP *+3 LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
JMP *+3 LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N |
PHA PHA JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
9 bytes | |
NOP NOP NOP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA PHP PLP JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
NOP PLA PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
PHA PHA PHP LDX #4 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHA PHP LDY #4 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA ;hides 'NOP' PHP PLP SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
PHP BIT $00 PLP JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP TYA PHA LDY #4 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP PHP LDY #2 @Y: PHP PLP DEY BNE @Y PLP |
Clobbers Y |
PHP PHA TSX PLA PLA PLA PLA TXS PLA PLP |
Clobbers X |
PHA PHA PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EAEA ;hides two 'NOP's NOP SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EAEA ;hides two 'NOP's NOP SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
11 bytes | |
NOP NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
35 cycles
6 bytes | |
---|---|
PLA LDY #6 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
PLA LDX #6 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
NOP NOP LDX #6 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP LDY #6 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
NOP PHP LDY #5 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #5 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #6 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHP PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
NOP PHA JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
9 bytes | |
PHP SEC LDA #5 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #5 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
NOP BIT $00 JSR @rts15 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
NOP STA @zptemp JSR @rts15 JSR @rts15 |
Requires @zptemp, and @rts15 |
NOP NOP $00 JSR @rts15 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
10 bytes | |
PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
36 cycles
5 bytes | |
---|---|
LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHP LDX #4 @X: NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #4 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHP PLP JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
PHA PHA JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA SEC LDA #6 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
PLA PLA JSR @rts14 JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
9 bytes | |
JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP NOP NOP JSR @rts15 JSR @rts15 |
Requires @rts15 |
LDA $00 SEC LDA #6 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PLA PLA PLA PLA PLA PLA PLA PLA PLA |
Clobbers A, S, and Z&N |
NOP PHA PHA JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
10 bytes | |
NOP NOP NOP NOP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLP |
Clobbers A, and S; and requires support for unofficial opcodes |
PHA PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLA |
Clobbers S, Z&N, and C; and requires support for unofficial opcodes |
11 bytes | |
TYA PHA LDY #2 @Y: PHP PLP DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP PHA PHA PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
12 bytes | |
NOP NOP NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
37 cycles
6 bytes | |
---|---|
LDY #4 @Y: PLA DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
LDX #4 @X: PLA DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
LDX #3 @X: PHP PLP DEX BNE @X |
Clobbers X, and Z&N |
LDY #3 @Y: PHP PLP DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PLA SEC LDA #6 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #5 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #5 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
10 bytes | |
NOP PHP SEC LDA #5 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #5 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
PHA PHA PHP PLP JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
11 bytes | |
NOP PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
38 cycles
6 bytes | |
---|---|
NOP LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
PHP LDY #6 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #6 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
8 bytes | |
PLA PLA JSR @rts15 JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
9 bytes | |
JSR @rts12 JSR @rts12 JSR @rts14 |
Requires @rts12, and @rts14 |
NOP PHP PLP JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
NOP PHA PHA JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PHP PLP JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
10 bytes | |
NOP JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP NOP NOP NOP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHP SEC LDA #4 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #4 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
PHP BIT $00 PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
11 bytes | |
PHA PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm .byte $0C,$E6,@zptemp ;NOP abs; hides 'INC @zptemp' SBC #1 BMI @A PLA PLP |
Requires @zptemp, and support for unofficial opcodes |
12 bytes | |
PHP PLP PHP PLP PHP PLP PHP PLP PHP BIT $00 PLP |
Clobbers nothing, requires nothing |
39 cycles
6 bytes | |
---|---|
PHA LDX #7 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #7 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDA $00 LDY #7 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
LDA $00 LDX #7 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
BIT $00 LDY #7 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
BIT $00 LDX #7 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
STA @zptemp LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
STA @zptemp LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
NOP $00 LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N |
JMP *+3 LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
9 bytes | |
NOP PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
SEC LDA #3 @A: PHP PLP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHP LDY #4 @Y: NOP DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #4 @X: NOP DEX BNE @X PLP |
Clobbers X, and S |
PHA PLA PLA JSR @rts14 JSR @rts14 |
Clobbers A, S, and Z&N; and requires @rts14 |
10 bytes | |
NOP TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP LDX #5 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP NOP PHP LDY #5 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP PHP PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA JSR @rts12 JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
11 bytes | |
PHA TYA PHA LDY #4 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #5 @A: SBC #1 BNE @A PLP |
Clobbers A |
STA @zptemp JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @zptemp, and @rts12 |
NOP $00 JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12, and support for unofficial opcodes |
12 bytes | |
NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
40 cycles
6 bytes | |
---|---|
PLA LDX #7 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #7 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #6 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #6 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #6 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #6 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
JSR @rts12 JSR @rts14 JSR @rts14 |
Requires @rts12, and @rts14 |
PHA PHP PLP JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
10 bytes | |
PHP BIT $00 PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
ROL $00,X ROR $00,X JSR @rts14 JSR @rts14 |
Clobbers Z&N; and requires @rts14 |
NOP PHA PHP PLP JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
11 bytes | |
NOP NOP JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP PHP BIT $00 PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
12 bytes | |
PHP PLP PHP PLP PHP PLP PHP ROL $00,X ROR $00,X PLP |
Clobbers nothing, requires nothing |
41 cycles
5 bytes | |
---|---|
LDX #8 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #8 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHA PHP LDX #6 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHP LDY #6 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDY #6 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP BIT $00 LDX #6 @X: DEX BNE @X PLP |
Clobbers X |
LDA $00 SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
JSR @rts12 JSR @rts14 JSR @rts15 |
Requires @rts12, @rts14, and @rts15 |
PHA PLA PLA JSR @rts15 JSR @rts15 |
Clobbers A, S, and Z&N; and requires @rts15 |
10 bytes | |
NOP NOP PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PLA TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
PHA PHA PHP PLP JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
11 bytes | |
NOP NOP TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
NOP PHA JSR @rts12 JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
PHA PHP SEC LDA #4 @A: NOP SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #4 @A: NOP SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
PHP SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA ;hides 'NOP' PHP PLP SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA ;hides 'NOP' PHP PLP SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
12 bytes | |
PHP PLP PHP BIT $00 PLP JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP PHA TYA PHA LDY #4 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP NOP PHP SEC LDA #5 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA PHA PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EAEA ;hides two 'NOP's NOP SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
13 bytes | |
NOP NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
42 cycles
7 bytes | |
---|---|
PHA PHA LDX #7 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA PHA LDY #7 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
8 bytes | |
NOP NOP NOP LDX #7 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP NOP LDY #7 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
PLA SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
JSR @rts12 JSR @rts15 JSR @rts15 |
Requires @rts12, and @rts15 |
TYA PHA LDY #6 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #6 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #6 @Y: DEY BNE @Y PLP |
Clobbers Y |
JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
10 bytes | |
ROL $00,X ROR $00,X JSR @rts15 JSR @rts15 |
Clobbers Z&N; and requires @rts15 |
NOP PHP SEC LDA #6 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #6 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
NOP PHA PHP PLP JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
11 bytes | |
PHP PHA SEC LDA #5 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
43 cycles
6 bytes | |
---|---|
LDX #6 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #6 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #8 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
JSR @rts14 JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
10 bytes | |
PHA PHA PHP PLP JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PHP SEC LDA #6 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #6 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
PHA JSR @rts12 JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts12, and @rts14 |
11 bytes | |
PHP PLP JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12 |
NOP NOP NOP PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHP LDA $00 SEC LDA #6 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #6 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
NOP PHA PHA PHP PLP JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
12 bytes | |
NOP NOP NOP NOP PHP PLP JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $2808 ;hides 'PHP' and 'PLP'; reads from $2000 SBC #1 BMI @A PLA PLP |
Clobbers S; and requires support for unofficial opcodes |
13 bytes | |
PHA TYA PHA LDY #2 @Y: PHP PLP DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP PHA PHA PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers S |
PHP PLP PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
14 bytes | |
NOP NOP NOP NOP PHP PLP PHP PLP PHP PLP PHP PLP PHP PLP |
Clobbers nothing, requires nothing |
44 cycles
6 bytes | |
---|---|
PHA LDY #8 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA LDX #8 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
7 bytes | |
LDA $00 LDY #8 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
LDA $00 LDX #8 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
BIT $00 LDY #8 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
BIT $00 LDX #8 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
STA @zptemp LDY #8 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
STA @zptemp LDX #8 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
NOP $00 LDY #8 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #8 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDY #8 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
JMP *+3 LDX #8 @X: DEX BNE @X |
Clobbers X, and Z&N |
9 bytes | |
PHP LDY #3 @Y: PHP PLP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #3 @X: PHP PLP DEX BNE @X PLP |
Clobbers X |
JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
NOP PLA SEC LDA #7 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
10 bytes | |
PHP PLP PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
NOP TYA PHA LDY #6 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
11 bytes | |
PHA TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #6 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #5 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
45 cycles
6 bytes | |
---|---|
PLA LDY #8 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
PLA LDX #8 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
NOP LDY #6 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #6 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #6 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #7 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
10 bytes | |
PHA JSR @rts14 JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
11 bytes | |
PHP PLP JSR @rts12 JSR @rts12 JSR @rts14 |
Requires @rts12, and @rts14 |
BIT $00 JSR @rts14 JSR @rts14 JSR @rts14 |
Clobbers Z&N, and V; and requires @rts14 |
STA @zptemp JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @zptemp, and @rts14 |
NOP $00 JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14, and support for unofficial opcodes |
12 bytes | |
PHP PHA SEC LDA #4 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
46 cycles
5 bytes | |
---|---|
LDX #9 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #9 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHA PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA SEC LDA #8 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDX #7 @X: DEX BNE @X PLP |
Clobbers X |
PHP BIT $00 LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y |
LDA $00 SEC LDA #8 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
NOP JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
PLA TYA PHA LDY #6 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
NOP PHP PLP PHP PLP JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHP SEC LDA #3 @A: PHP PLP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #3 @A: PHP PLP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
NOP NOP JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
12 bytes | |
NOP PHA TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHP PLP JSR @rts12 JSR @rts12 JSR @rts12 |
Clobbers S; and requires @rts12 |
13 bytes | |
NOP NOP PHP PHA SEC LDA #5 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
47 cycles
7 bytes | |
---|---|
PHA PHA LDX #8 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA PHA LDY #8 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
8 bytes | |
NOP NOP LDX #6 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP LDY #6 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
PLA SEC LDA #8 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y |
10 bytes | |
NOP JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
NOP PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #6 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
48 cycles
6 bytes | |
---|---|
NOP LDX #9 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #9 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #8 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #8 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #9 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #7 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #7 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
BIT $00 JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
NOP NOP JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
STA @zptemp JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @zptemp, and @rts15 |
PHA PHA JSR @rts14 JSR @rts14 JSR @rts14 |
Clobbers S; and requires @rts14 |
NOP $00 JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
12 bytes | |
JSR @rts12 JSR @rts12 JSR @rts12 JSR @rts12 |
Requires @rts12 |
JMP *+3 JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
NOP NOP NOP JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
13 bytes | |
NOP NOP PHA TYA PHA LDY #5 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHP PHA SEC LDA #4 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers S |
PHP PHA SEC LDA #130 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA ;hides 'NOP' PHP PLP SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
14 bytes | |
NOP NOP NOP PHP PHA SEC LDA #5 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
49 cycles
6 bytes | |
---|---|
LDY #6 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
LDX #6 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
7 bytes | |
LDY #4 @Y: PHP PLP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #4 @X: PHP PLP DEX BNE @X |
Clobbers X, and Z&N |
9 bytes | |
PHA PHA PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHA PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
NOP PLA SEC LDA #8 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
10 bytes | |
NOP TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP LDY #7 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP NOP PHP LDX #7 @X: DEX BNE @X PLP |
Clobbers X |
11 bytes | |
NOP NOP JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHA TYA PHA LDY #6 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHP PLP JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
12 bytes | |
NOP PHP PHA SEC LDA #6 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
50 cycles
6 bytes | |
---|---|
LDX #7 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #7 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHP LDX #6 @X: NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #6 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP SEC LDA #9 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #8 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #8 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PLP JSR @rts14 JSR @rts14 JSR @rts15 |
Requires @rts14, and @rts15 |
NOP PHA JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
12 bytes | |
NOP BIT $00 JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers Z&N, and V; and requires @rts15 |
JSR @rts12 JSR @rts12 JSR @rts12 JSR @rts14 |
Requires @rts12, and @rts14 |
NOP STA @zptemp JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @zptemp, and @rts15 |
PHA PHP PHA SEC LDA #6 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
NOP NOP $00 JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15, and support for unofficial opcodes |
13 bytes | |
PHP PHA LDA $00 SEC LDA #6 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
51 cycles
5 bytes | |
---|---|
LDY #10 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #10 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHA PHP LDX #8 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHP LDY #8 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
SEC LDA #6 @A: PHA SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDY #8 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP BIT $00 LDX #8 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #4 @A: PHP PLP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
NOP NOP TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHP PLP JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
PHA PHA JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
PHA PHA PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA PHA SEC LDA #7 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
12 bytes | |
NOP NOP NOP JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
NOP PHA TYA PHA LDY #6 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP NOP PHP SEC LDA #7 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHP PLP JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
13 bytes | |
NOP NOP PHP PHA SEC LDA #6 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
52 cycles
7 bytes | |
---|---|
NOP LDY #7 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #7 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
SEC LDA #7 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
TYA PHA LDY #8 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP PHP LDY #6 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #6 @X: NOP DEX BNE @X PLP |
Clobbers X |
10 bytes | |
PHP SEC LDA #6 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #6 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
53 cycles
6 bytes | |
---|---|
NOP LDX #10 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #10 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #9 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #9 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #10 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #8 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #8 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #8 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #8 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
NOP PHP PLP JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
NOP PHA PHA JSR @rts15 JSR @rts15 JSR @rts15 |
Clobbers S; and requires @rts15 |
13 bytes | |
PHP PHA SEC LDA #3 @A: PHP PLP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
54 cycles
6 bytes | |
---|---|
PHA LDX #10 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #10 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDA $00 LDX #10 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
LDA $00 LDY #10 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
BIT $00 LDX #10 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
BIT $00 LDY #10 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
STA @zptemp LDX #10 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
STA @zptemp LDY #10 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
NOP $00 LDX #10 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDY #10 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDY #10 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
JMP *+3 LDX #10 @X: DEX BNE @X |
Clobbers X, and Z&N |
9 bytes | |
NOP SEC LDA #7 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHA PHP LDY #8 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHA PHP LDX #8 @X: DEX BNE @X PLP |
Clobbers X, and S |
10 bytes | |
TYA PHA LDY #6 @Y: NOP DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #6 @X: NOP DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #6 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
11 bytes | |
PHA TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP PHP SEC LDA #6 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
55 cycles
6 bytes | |
---|---|
LDY #6 @Y: PLA DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
LDX #6 @X: PLA DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
LDY #6 @Y: NOP NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #6 @X: NOP NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #9 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #9 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #10 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #9 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #9 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
JSR @rts12 JSR @rts14 JSR @rts14 JSR @rts15 |
Requires @rts12, @rts14, and @rts15 |
PHA PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
56 cycles
5 bytes | |
---|---|
LDY #11 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #11 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHA PHP LDY #9 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #9 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA SEC LDA #10 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP LDX #4 @X: PHP PLP DEX BNE @X PLP |
Clobbers X |
PHP LDY #4 @Y: PHP PLP DEY BNE @Y PLP |
Clobbers Y |
LDA $00 SEC LDA #10 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #8 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
NOP TYA PHA LDY #6 @Y: NOP DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHA PHA PHP SEC LDA #8 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA PHA SEC LDA #8 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
12 bytes | |
NOP PHA TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #6 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
JSR @rts14 JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
13 bytes | |
NOP NOP PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
57 cycles
6 bytes | |
---|---|
LDX #8 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #8 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
SEC LDA #136 @A = * - 1 ; ^ Hides DEY SBC #1 BMI @A |
Clobbers A, Z&N, and C |
8 bytes | |
PHP LDY #7 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #7 @X: NOP DEX BNE @X PLP |
Clobbers X |
9 bytes | |
TYA PHA LDY #9 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
10 bytes | |
NOP PHP SEC LDA #9 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #9 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #8 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
58 cycles
6 bytes | |
---|---|
NOP LDX #11 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #11 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDY #10 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #10 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #11 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #9 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #9 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP SEC LDA #4 @A: PHP PLP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #4 @A: PHP PLP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
JSR @rts14 JSR @rts14 JSR @rts15 JSR @rts15 |
Requires @rts14, and @rts15 |
13 bytes | |
NOP NOP PHA TYA PHA LDY #7 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP JSR @rts14 JSR @rts14 JSR @rts14 JSR @rts14 |
Requires @rts14 |
PHA PHA PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
14 bytes | |
NOP NOP NOP PHP PHA SEC LDA #7 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
59 cycles
6 bytes | |
---|---|
PHA LDX #11 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #11 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
NOP LDY #8 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #8 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
SEC LDA #8 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
NOP PHP LDY #7 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #7 @X: NOP DEX BNE @X PLP |
Clobbers X |
10 bytes | |
PHP SEC LDA #7 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #7 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHA TYA PHA LDY #8 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
12 bytes | |
PHP PHA SEC LDA #6 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
60 cycles
6 bytes | |
---|---|
PLA LDX #11 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #11 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #11 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #11 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #10 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #10 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #11 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #10 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #10 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
JSR @rts15 JSR @rts15 JSR @rts15 JSR @rts15 |
Requires @rts15 |
PHA PHP PHA SEC LDA #8 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #8 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
61 cycles
5 bytes | |
---|---|
LDY #12 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #12 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHA PHP LDY #10 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #10 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA SEC LDA #11 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDY #10 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP BIT $00 LDX #10 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #8 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
TXA PHA LDX #7 @X: NOP DEX BNE @X PLA TAX |
Clobbers A, and Z&N |
11 bytes | |
NOP PHP SEC LDA #7 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #7 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA TYA PHA LDY #6 @Y: NOP DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
13 bytes | |
NOP PHP PHA SEC LDA #6 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
62 cycles
7 bytes | |
---|---|
PHA PHA LDY #11 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA PHA LDX #11 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
8 bytes | |
NOP NOP NOP LDX #11 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP NOP LDY #11 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
PLA SEC LDA #11 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TXA PHA LDX #10 @X: DEX BNE @X PLA TAX |
Clobbers A, and Z&N |
PHP LDX #6 @X: NOP NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #6 @Y: NOP NOP DEY BNE @Y PLP |
Clobbers Y |
10 bytes | |
NOP PHP SEC LDA #10 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #10 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #9 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
63 cycles
6 bytes | |
---|---|
NOP LDX #12 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #12 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #12 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #10 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #10 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #10 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #10 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
13 bytes | |
NOP PHA TYA PHA LDY #6 @Y: NOP DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHA PHP PHA SEC LDA #8 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
14 bytes | |
NOP NOP PHP PHA SEC LDA #6 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
64 cycles
6 bytes | |
---|---|
LDY #9 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #9 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHP LDY #8 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #8 @X: NOP DEX BNE @X PLP |
Clobbers X |
9 bytes | |
PHP SEC LDA #136 @A = * - 1 ; ^ Hides DEY SBC #1 BMI @A PLP |
Clobbers A |
PHA SEC LDA #136 @A = * - 1 ; ^ Hides DEY SBC #1 BMI @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHA TYA PHA LDY #9 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
12 bytes | |
NOP PHP PHA SEC LDA #9 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
65 cycles
6 bytes | |
---|---|
LDX #8 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
LDY #8 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #12 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #12 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #12 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #11 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #11 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #9 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA SEC LDA #4 @A: PHP PLP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
66 cycles
5 bytes | |
---|---|
LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
SEC LDA #9 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X, and S |
9 bytes | |
NOP PHP LDY #8 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #8 @X: NOP DEX BNE @X PLP |
Clobbers X |
10 bytes | |
PHP SEC LDA #8 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #8 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHP PHA SEC LDA #7 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
67 cycles
7 bytes | |
---|---|
LDY #6 @Y: PHA PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
LDX #6 @X: PHA PHA DEX BNE @X |
Clobbers X, S, and Z&N |
8 bytes | |
LDY #6 @Y: NOP NOP NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #6 @X: NOP NOP NOP DEX BNE @X |
Clobbers X, and Z&N |
SEC LDA #8 @A: PHA SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #11 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y |
10 bytes | |
NOP PHP SEC LDA #11 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #11 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #10 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
68 cycles
6 bytes | |
---|---|
NOP LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #12 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #12 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
TXA PHA LDX #8 @X: NOP DEX BNE @X PLA TAX |
Clobbers A, and Z&N |
PHA PHP SEC LDA #11 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #11 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
NOP PHP SEC LDA #8 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #8 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA TXA PHA LDX #7 @X: NOP DEX BNE @X PLA TAX PLA |
Clobbers Z&N |
13 bytes | |
NOP PHP PHA SEC LDA #7 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
69 cycles
6 bytes | |
---|---|
PHA LDX #13 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #13 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDA $00 LDX #13 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
LDA $00 LDY #13 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
BIT $00 LDX #13 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
BIT $00 LDY #13 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
STA @zptemp LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
STA @zptemp LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
NOP $00 LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N |
JMP *+3 LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A |
Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes |
9 bytes | |
PHA PHA PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHA PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
SEC LDA #6 @A: PHA PHA SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
LDA $00 SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
NOP TYA PHA LDY #11 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP LDY #11 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP NOP PHP LDX #11 @X: DEX BNE @X PLP |
Clobbers X |
11 bytes | |
PHA TXA PHA LDX #10 @X: DEX BNE @X PLA TAX PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #11 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #10 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
70 cycles
6 bytes | |
---|---|
PLA LDX #13 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #13 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #12 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #12 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #12 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #12 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #10 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #10 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
71 cycles
5 bytes | |
---|---|
LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHP LDX #9 @X: NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #9 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHA SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
LDA $00 SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #11 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
PHP PHA SEC LDA #136 @A = * - 1 ; ^ Hides DEY SBC #1 BMI @A PLA PLP |
Clobbers nothing, requires nothing |
72 cycles
7 bytes | |
---|---|
PHA PHA LDX #13 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA PHA LDY #13 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
8 bytes | |
NOP NOP NOP LDX #13 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP NOP LDY #13 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
PLA SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #12 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHP LDX #8 @X: BIT $00 DEX BNE @X PLP |
Clobbers X |
PHP LDY #8 @Y: BIT $00 DEY BNE @Y PLP |
Clobbers Y |
10 bytes | |
NOP PHP SEC LDA #12 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #12 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #11 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
73 cycles
6 bytes | |
---|---|
NOP LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
PHP SEC LDA #9 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #9 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHP PHA SEC LDA #8 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
74 cycles
6 bytes | |
---|---|
PHA LDY #14 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA LDX #14 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
7 bytes | |
LDA $00 LDY #14 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
LDA $00 LDX #14 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
BIT $00 LDY #14 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
BIT $00 LDX #14 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
STA @zptemp LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
STA @zptemp LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
NOP $00 LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N |
JMP *+3 LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
9 bytes | |
PHA PHP LDY #9 @Y: NOP DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #9 @X: NOP DEX BNE @X PLP |
Clobbers X, and S |
NOP PLA SEC LDA #13 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
10 bytes | |
NOP TYA PHA LDY #12 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHP LDX #6 @X: NOP NOP NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #6 @Y: NOP NOP NOP DEY BNE @Y PLP |
Clobbers Y |
11 bytes | |
PHA TYA PHA LDY #11 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #12 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #11 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
75 cycles
6 bytes | |
---|---|
PLA LDX #14 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #14 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #13 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA TXA PHA LDX #8 @X: NOP DEX BNE @X PLA TAX PLA |
Clobbers Z&N |
PHA PHP PHA SEC LDA #11 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
NOP PHP PHA SEC LDA #8 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
76 cycles
5 bytes | |
---|---|
LDX #15 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #15 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHA PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP BIT $00 LDX #13 @X: DEX BNE @X PLP |
Clobbers X |
LDA $00 SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #12 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
PHA PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLP |
Clobbers A, and S; and requires support for unofficial opcodes |
PHA PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA |
Clobbers S, Z&N, and C; and requires support for unofficial opcodes |
11 bytes | |
TYA PHA LDY #8 @Y: LDA $00 DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHA PHP SEC LDA #9 @A: NOP SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #9 @A: NOP SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
NOP $00 PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
NOP $00 PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
12 bytes | |
NOP PHA TYA PHA LDY #11 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHP SEC LDA #6 @A: NOP NOP NOP SBC #1 BNE @A PLP |
Clobbers A |
13 bytes | |
NOP NOP PHP PHA SEC LDA #11 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
77 cycles
7 bytes | |
---|---|
PHA PHA LDY #14 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA PHA LDX #14 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
8 bytes | |
NOP NOP NOP LDX #14 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP NOP LDY #14 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
PLA SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X |
10 bytes | |
NOP PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #12 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
78 cycles
6 bytes | |
---|---|
LDX #11 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #11 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #15 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #13 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #13 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
13 bytes | |
PHP PLP PHP PHA SEC LDA #136 @A = * - 1 ; ^ Hides DEY SBC #1 BMI @A PLA PLP |
Clobbers nothing, requires nothing |
79 cycles
6 bytes | |
---|---|
PHA LDY #15 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
PHA LDX #15 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
7 bytes | |
LDA $00 LDY #15 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
LDA $00 LDX #15 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
BIT $00 LDY #15 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
BIT $00 LDX #15 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
STA @zptemp LDY #15 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
STA @zptemp LDX #15 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
NOP $00 LDY #15 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #15 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDY #15 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
JMP *+3 LDX #15 @X: DEX BNE @X |
Clobbers X, and Z&N |
9 bytes | |
PHA PHA PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHA PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
NOP PLA SEC LDA #14 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
10 bytes | |
NOP TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP LDY #13 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP NOP PHP LDX #13 @X: DEX BNE @X PLP |
Clobbers X |
11 bytes | |
PHA TYA PHA LDY #12 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #12 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
80 cycles
6 bytes | |
---|---|
PLA LDY #15 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
PLA LDX #15 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
NOP LDY #11 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #11 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #11 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #14 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
12 bytes | |
PHP PHA SEC LDA #9 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
81 cycles
5 bytes | |
---|---|
LDY #16 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #16 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHA PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA SEC LDA #15 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP BIT $00 LDX #14 @X: DEX BNE @X PLP |
Clobbers X |
LDA $00 SEC LDA #15 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
NOP NOP TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHA PHA PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA PHA SEC LDA #13 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
12 bytes | |
NOP PHA TYA PHA LDY #12 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP NOP PHP SEC LDA #13 @A: SBC #1 BNE @A PLP |
Clobbers A |
13 bytes | |
NOP NOP PHP PHA SEC LDA #12 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
82 cycles
6 bytes | |
---|---|
LDY #9 @Y: PLA DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
LDX #9 @X: PLA DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
LDY #9 @Y: NOP NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #9 @X: NOP NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PLA SEC LDA #15 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X |
NOP NOP PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y |
10 bytes | |
NOP PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
83 cycles
6 bytes | |
---|---|
NOP LDX #16 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #16 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #15 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #15 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #16 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #14 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #14 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA PLP |
Clobbers S; and requires support for unofficial opcodes |
13 bytes | |
PHA TYA PHA LDY #8 @Y: LDA $00 DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHP PHA SEC LDA #9 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers S |
NOP $00 PHP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
14 bytes | |
PHP PHA SEC LDA #6 @A: NOP NOP NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
84 cycles
6 bytes | |
---|---|
PHA LDX #16 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #16 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDA $00 LDX #16 @X: DEX BNE @X |
Clobbers A, X, and Z&N |
LDA $00 LDY #16 @Y: DEY BNE @Y |
Clobbers A, Y, and Z&N |
BIT $00 LDY #16 @Y: DEY BNE @Y |
Clobbers Y, Z&N, and V |
BIT $00 LDX #16 @X: DEX BNE @X |
Clobbers X, Z&N, and V |
STA @zptemp LDX #16 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
STA @zptemp LDY #16 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
NOP $00 LDY #16 @Y: DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
NOP $00 LDX #16 @X: DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
JMP *+3 LDX #16 @X: DEX BNE @X |
Clobbers X, and Z&N |
JMP *+3 LDY #16 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
9 bytes | |
SEC LDA #9 @A: NOP NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHA PHA PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHA PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
10 bytes | |
NOP TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP NOP PHP LDY #14 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP NOP PHP LDX #14 @X: DEX BNE @X PLP |
Clobbers X |
11 bytes | |
PHA TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
85 cycles
6 bytes | |
---|---|
LDY #12 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #12 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHP LDY #11 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #11 @X: NOP DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #16 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #15 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #15 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
86 cycles
5 bytes | |
---|---|
LDX #17 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #17 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHA PHP LDY #15 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #15 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA SEC LDA #16 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
NOP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
9 bytes | |
PHP BIT $00 LDX #15 @X: DEX BNE @X PLP |
Clobbers X |
PHP BIT $00 LDY #15 @Y: DEY BNE @Y PLP |
Clobbers Y |
LDA $00 SEC LDA #16 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PLA TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
NOP NOP TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
PHA PHA PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA PHA SEC LDA #14 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
12 bytes | |
NOP PHA TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP NOP PHP SEC LDA #14 @A: SBC #1 BNE @A PLP |
Clobbers A |
13 bytes | |
NOP NOP PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
87 cycles
7 bytes | |
---|---|
NOP LDX #12 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #12 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
SEC LDA #12 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
TYA PHA LDY #15 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP PHP LDY #11 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #11 @X: NOP DEX BNE @X PLP |
Clobbers X |
10 bytes | |
PHP SEC LDA #11 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #11 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
88 cycles
6 bytes | |
---|---|
NOP LDY #17 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #17 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
PHP LDY #16 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #16 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #17 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #15 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #15 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP LDA $00 SEC LDA #15 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #15 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
13 bytes | |
NOP NOP PHA TYA PHA LDY #13 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHA PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
14 bytes | |
NOP NOP NOP PHP PHA SEC LDA #13 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
89 cycles
6 bytes | |
---|---|
LDX #11 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
LDY #11 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDX #11 @X: LDA $00 DEX BNE @X |
Clobbers A, X, and Z&N |
LDY #11 @Y: LDA $00 DEY BNE @Y |
Clobbers A, Y, and Z&N |
LDX #11 @X: BIT $00 DEX BNE @X |
Clobbers X, Z&N, and V |
LDY #11 @Y: BIT $00 DEY BNE @Y |
Clobbers Y, Z&N, and V |
LDY #11 @Y: STA @zptemp DEY BNE @Y |
Clobbers Y, and Z&N; and requires @zptemp |
LDX #11 @X: STA @zptemp DEX BNE @X |
Clobbers X, and Z&N; and requires @zptemp |
LDY #11 @Y: NOP $00 DEY BNE @Y |
Clobbers Y, and Z&N; and requires support for unofficial opcodes |
LDX #11 @X: NOP $00 DEX BNE @X |
Clobbers X, and Z&N; and requires support for unofficial opcodes |
8 bytes | |
LDX #11 @X: JMP *+3 DEX BNE @X |
Clobbers X, and Z&N |
LDY #11 @Y: JMP *+3 DEY BNE @Y |
Clobbers Y, and Z&N |
9 bytes | |
PHP LDY #9 @Y: NOP NOP DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #9 @X: NOP NOP DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #12 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
TXA PHA LDX #11 @X: NOP DEX BNE @X PLA TAX |
Clobbers A, and Z&N |
11 bytes | |
PHA TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP PHP SEC LDA #11 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
90 cycles
6 bytes | |
---|---|
PLA LDX #17 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #17 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDX #17 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP NOP LDY #17 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
NOP PHP LDY #16 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #16 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #17 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #16 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #16 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
91 cycles
5 bytes | |
---|---|
LDY #18 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #18 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $48 ;hides 'PHA' SBC #1 BMI @A |
Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
PHA PHP LDX #16 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA PHP LDY #16 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
SEC LDA #11 @A: PHA SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP BIT $00 LDX #16 @X: DEX BNE @X PLP |
Clobbers X |
PHP BIT $00 LDY #16 @Y: DEY BNE @Y PLP |
Clobbers Y |
LDA $00 SEC LDA #17 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
PLA TYA PHA LDY #15 @Y: DEY BNE @Y PLA TAY |
Clobbers A, S, and Z&N |
11 bytes | |
PHP SEC LDA #9 @A: NOP NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #9 @A: NOP NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
NOP PHA TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
13 bytes | |
NOP NOP PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
92 cycles
6 bytes | |
---|---|
LDY #13 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #13 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
PHP LDX #12 @X: NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #12 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
PLA SEC LDA #17 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #16 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
10 bytes | |
NOP PHP SEC LDA #16 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #16 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #15 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
93 cycles
6 bytes | |
---|---|
NOP LDX #18 @X: DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #18 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
7 bytes | |
PHP LDX #17 @X: DEX BNE @X PLP |
Clobbers X |
PHP LDY #17 @Y: DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #18 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #16 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #16 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
NOP PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
NOP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
11 bytes | |
PHP LDA $00 SEC LDA #16 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #16 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
13 bytes | |
NOP NOP PHA TYA PHA LDY #14 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
PHA PHA PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
14 bytes | |
NOP NOP NOP PHP PHA SEC LDA #14 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
94 cycles
6 bytes | |
---|---|
PHA LDX #18 @X: DEX BNE @X |
Clobbers X, S, and Z&N |
PHA LDY #18 @Y: DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
NOP LDX #13 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
NOP LDY #13 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
SEC LDA #13 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
NOP PHP LDY #12 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #12 @X: NOP DEX BNE @X PLP |
Clobbers X |
10 bytes | |
PHP SEC LDA #12 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #12 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHA TYA PHA LDY #15 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
12 bytes | |
PHP PHA SEC LDA #11 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
95 cycles
6 bytes | |
---|---|
PLA LDX #18 @X: DEX BNE @X |
Clobbers A, X, S, and Z&N |
PLA LDY #18 @Y: DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
7 bytes | |
NOP NOP LDY #18 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP NOP LDX #18 @X: DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
NOP PHP LDY #17 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #17 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #18 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #17 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #17 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #15 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
13 bytes | |
PHP PHA LDA $00 SEC LDA #15 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
96 cycles
5 bytes | |
---|---|
LDX #19 @X: DEX BNE @X |
Clobbers X, and Z&N |
LDY #19 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PHA PHP LDY #17 @Y: DEY BNE @Y PLP |
Clobbers Y, and S |
PHA PHP LDX #17 @X: DEX BNE @X PLP |
Clobbers X, and S |
PHA SEC LDA #18 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
PHP LDY #11 @Y: BIT $00 DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #11 @X: BIT $00 DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #13 @A: NOP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
TYA PHA LDY #12 @Y: NOP DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
11 bytes | |
NOP PHP SEC LDA #12 @A: NOP SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #12 @A: NOP SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA TXA PHA LDX #11 @X: NOP DEX BNE @X PLA TAX PLA |
Clobbers Z&N |
13 bytes | |
NOP PHP PHA SEC LDA #11 @A: NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
97 cycles
6 bytes | |
---|---|
LDX #12 @X: PHA DEX BNE @X |
Clobbers X, S, and Z&N |
LDY #12 @Y: PHA DEY BNE @Y |
Clobbers Y, S, and Z&N |
7 bytes | |
LDX #8 @X: PHP PLP DEX BNE @X |
Clobbers X, and Z&N |
LDY #8 @Y: PHP PLP DEY BNE @Y |
Clobbers Y, and Z&N |
8 bytes | |
PLA SEC LDA #18 @A: SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
TYA PHA LDY #17 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
NOP NOP PHP LDY #17 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP NOP PHP LDX #17 @X: DEX BNE @X PLP |
Clobbers X |
10 bytes | |
NOP PHP SEC LDA #17 @A: SBC #1 BNE @A PLP |
Clobbers A |
NOP PHA SEC LDA #17 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
11 bytes | |
PHP PHA SEC LDA #16 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
98 cycles
6 bytes | |
---|---|
NOP LDY #19 @Y: DEY BNE @Y |
Clobbers Y, and Z&N |
NOP LDX #19 @X: DEX BNE @X |
Clobbers X, and Z&N |
7 bytes | |
PHP LDY #18 @Y: DEY BNE @Y PLP |
Clobbers Y |
PHP LDX #18 @X: DEX BNE @X PLP |
Clobbers X |
SEC LDA #19 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
10 bytes | |
PHA PHP SEC LDA #17 @A: SBC #1 BNE @A PLP |
Clobbers A, and S |
PHA PHA SEC LDA #17 @A: SBC #1 BNE @A PLA |
Clobbers S, Z&N, and C |
11 bytes | |
PHP SEC LDA #11 @A: BIT $00 SBC #1 BNE @A PLP |
Clobbers A |
PHA LDA $00 SEC LDA #17 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
PHP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
13 bytes | |
PHP PHA SEC LDA #9 @A: NOP NOP SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
99 cycles
6 bytes | |
---|---|
LDY #14 @Y: NOP DEY BNE @Y |
Clobbers Y, and Z&N |
LDX #14 @X: NOP DEX BNE @X |
Clobbers X, and Z&N |
8 bytes | |
PHP LDX #13 @X: NOP DEX BNE @X PLP |
Clobbers X |
PHP LDY #13 @Y: NOP DEY BNE @Y PLP |
Clobbers Y |
SEC LDA #12 @A: PHA SBC #1 BNE @A |
Clobbers A, S, Z&N, and C |
9 bytes | |
SEC LDA #8 @A: PHP PLP SBC #1 BNE @A |
Clobbers A, Z&N, and C |
PHP SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLP |
Clobbers A; and requires support for unofficial opcodes |
PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA44 ;hides 'NOP zp' SBC #1 BMI @A PLA |
Clobbers Z&N, and C; and requires support for unofficial opcodes |
10 bytes | |
NOP TYA PHA LDY #17 @Y: DEY BNE @Y PLA TAY |
Clobbers A, and Z&N |
11 bytes | |
PHA TYA PHA LDY #16 @Y: DEY BNE @Y PLA TAY PLA |
Clobbers Z&N |
NOP NOP PHP SEC LDA #17 @A: SBC #1 BNE @A PLP |
Clobbers A |
12 bytes | |
NOP PHP PHA SEC LDA #16 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
100 cycles
6 bytes | |
---|---|
LDY #11 @Y: PLA DEY BNE @Y |
Clobbers A, Y, S, and Z&N |
LDX #11 @X: PLA DEX BNE @X |
Clobbers A, X, S, and Z&N |
7 bytes | |
LDX #11 @X: NOP NOP DEX BNE @X |
Clobbers X, and Z&N |
LDY #11 @Y: NOP NOP DEY BNE @Y |
Clobbers Y, and Z&N |
SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EAEA ;hides two 'NOP's SBC #1 BMI @A |
Clobbers A, Z&N, and C; and requires support for unofficial opcodes |
8 bytes | |
NOP PHP LDY #18 @Y: DEY BNE @Y PLP |
Clobbers Y |
NOP PHP LDX #18 @X: DEX BNE @X PLP |
Clobbers X |
NOP SEC LDA #19 @A: SBC #1 BNE @A |
Clobbers A, Z&N, and C |
9 bytes | |
PHP SEC LDA #18 @A: SBC #1 BNE @A PLP |
Clobbers A |
PHA SEC LDA #18 @A: SBC #1 BNE @A PLA |
Clobbers Z&N, and C |
12 bytes | |
PHA PHP PHA SEC LDA #16 @A: SBC #1 BNE @A PLA PLP |
Clobbers S |
NOP PHP PHA SEC LDA #137 @A = * - 1 ; ^ Hides !NOP #imm NOP $EA,X ;hides 'NOP' SBC #1 BMI @A PLA PLP |
Requires support for unofficial opcodes |
13 bytes | |
PHP PHA LDA $00 SEC LDA #16 @A: SBC #1 BNE @A PLA PLP |
Clobbers nothing, requires nothing |
More
Bisqwit's 6502 delay_n macro set for ca65: http://bisqwit.iki.fi/src/6502-inline_delay.7z