|
|
(38 intermediate revisions by 2 users not shown) |
Line 1: |
Line 1: |
| | Shortest possible CPU code that creates N cycles of delay, depending on constraints. |
|
| |
|
| == Delay code == | | == Code == |
|
| |
|
| Shortest possible CPU code that creates N cycles of delay, depending on constraints.
| | All code samples are written for CA65. |
|
| |
|
| Assumptions: | | Assumptions: |
| * No page wrap occurs during any branch instruction. | | * No page wrap occurs during any branch instruction. If a page wrap occurs, it adds +1 cycle for each loop, completely thwarting the accurate delay. |
| * No interrupt / NMI occurs during the delay code. | | * No interrupt / NMI occurs during the delay code. |
|
| |
|
Line 13: |
Line 14: |
| in order to get the correct delay. | | in order to get the correct delay. |
|
| |
|
| Explanations on the requirements: | | === Explanations on the requirements === |
| * @zptemp means you have a zeropage address that you can write random data into.
| | |
| * @rti means you have a dummy interrupt handler installed that does nothing but <code>RTI</code>.
| |
| * @rts12 means you know a memory address that contains byte $60 (<code>RTS</code>). | | * @rts12 means you know a memory address that contains byte $60 (<code>RTS</code>). |
| * @rts14 means you know a memory address that contains a harmless 2-cycle instruction that fits your constraints (such as <code>CLC</code>, <code>LDA #0</code>, or <code>NOP</code>), followed by <code>RTS</code>.
| | cycle instruction that fits your constraints (such as <code>LDA $00</code>), followed by <code>RTS</code>. |
| * @rts15 means you know a memory address that contains a <code>JMP</code> that jumps to another location that contains <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>.
| | === Instructions, addressing modes, byte counts, cycle counts and notes === |
| * @A, @X, @Y are local labels.
| | |
| | {| class="wikitable testtable" |
| | ! scope="col"| Addressing mode |
| | ! scope="col"| Instruction type |
| | ! scope="col"| Bytes |
| | ! scope="col"| Cycle count |
| | ! scope="col"| Example instruction |
| | ! scope="col"| Notes |
| | |- |
| | ! scope="row"| Implied |
| | ! scope="row"| Inter-register |
| | | 1 || 2 || <code>TAX</code> || <code>NOP</code> has no side effects. Flag-manipulations like <code>CLC</code>, and <code>SEC</code><code>CLV</code> are used when their effects are desired. |
| | |- |
| | ! scope="row"| Implied |
| | ! scope="row"| Stack push |
| | | 1 || 3 || <code>PHA</code> || <code>PHP</code> is only paired with <code>PLP</code>. |
| | |- |
| | ! scope="row"| Implied |
| | ! scope="row"| Stack pop |
| | | 1 || 4 || <code>PLA</code> || |
| | |- |
| | ! scope="row"| Implied |
| | ! scope="row"| Return |
| | | 1 || 6 || <code>RTS</code> || Used indirectly when paired with <code>JSR</code>. Similarly for <code>RTI</code>. |
| | |- |
| | ! scope="row"| Immediate |
| | ! scope="row"| |
| | | 2 || 2 || <code>CMP #$C5</code> || Includes instructions like <code>LDA</code>, <code>LDX</code> and <code>LDY</code>. Other ALU instructions are used in more complex situations. |
| | |- |
| | ! scope="row"| Relative |
| | ! scope="row"| Branch |
| | | 2 || 2—4 || <code>BCC *+2</code> || Branch takes 3 cycles when taken, 2 otherwise. A page crossing adds +1 cycle when branch is taken, but because of difficulties setting that up, we don't use it. |
| | |- |
| | ! scope="row"| Zeropage |
| | ! scope="row"| Read, write |
| | | 2 || 3 || <code>LDA $A5</code> |
| | |- |
| | ! scope="row"| Zeropage |
| | ! scope="row"| RMW |
| | | 2 || 5 || <code>INC @zptemp</code> || Writing to zeropage is only permitted when @zptemp is available. Technically we could save @zptemp into register and restore at end, but it is bytewise inferior to other techniques. |
| | |- |
| | ! scope="row"| Zeropage indexed |
| | ! scope="row"| Read, write |
| | | 2 || 4 || <code>LDA $EA,X</code> || Inferior to 2 × <code>NOP</code>, but useful for hiding additional code to be executed in a loop. |
| | |- |
| | ! scope="row"| Zeropage indexed |
| | ! scope="row"| RMW |
| | | 2 || 6 || <code>INC @zptemp,X</code> || Only doable when X is known to be 0, or when entire zeropage can be clobbered. |
| | |- |
| | ! scope="row"| Indexed indirect |
| | ! scope="row"| Read, write |
| | | 2 || 6 || <code>STA (@ptrtemp,X)</code> || Only doable when X is known to be 0. |
| | |- |
| | ! scope="row"| Indexed indirect |
| | ! scope="row"| RMW |
| | | 2 || 8 || <code>SLO (@ptrtemp,X)</code> || The most cost-effective instruction. Only doable when X is known to be 0, lest we write to a random address. All instructions in this category are unofficial. |
| | |- |
| | ! scope="row"| Indirect indexed |
| | ! scope="row"| Read |
| | | 2 || 5—6 || <code>LDA (@ptrtemp),Y</code> || Never used by this code. |
| | |- |
| | ! scope="row"| Indirect indexed |
| | ! scope="row"| Write |
| | | 2 || 6 || <code>STA (@ptrtemp),Y</code> || Only doable when Y is known to be 0. |
| | |- |
| | ! scope="row"| Indirect indexed |
| | ! scope="row"| RMW |
| | | 2 || 8 || <code>SLO (@ptrtemp),Y</code> || All instructions in this category are unofficial. |
| | |- |
| | ! scope="row"| Absolute |
| | ! scope="row"| Jump |
| | | 3 || 3 || <code>JMP *+3</code> || |
| | |- |
| | ! scope="row"| Absolute |
| | ! scope="row"| Read, write |
| | | 3 || 4 || <code>LDA $2808</code> || Inferior to 2 × <code>NOP</code>, but can be used carefully to hide additional code to be executed in a loop. |
| | |- |
| | ! scope="row"| Absolute |
| | ! scope="row"| RMW |
| | | 3 || 6 || <code>INC $4018</code> || Inferior to 3 × <code>NOP</code>. |
| | |- |
| | ! scope="row"| Absolute indexed |
| | ! scope="row"| Read |
| | | 3 || 4—5 || <code>LDA $0200,X</code> || Inferior to shorter alternatives. |
| | |- |
| | ! scope="row"| Absolute indexed |
| | ! scope="row"| Write |
| | | 3 || 5 || <code>STA $0200,X</code> || Inferior to shorter alternatives. |
| | |- |
| | ! scope="row"| Absolute indexed |
| | ! scope="row"| RMW |
| | | 3 || 7 || <code>INC $4018,X</code> || Only doable when writing into the given address is harmless considering the possible values of X. |
| | |- |
| | ! scope="row"| Absolute indirect |
| | ! scope="row"| Jump |
| | | 3 || 5 || <code>JMP (@ptrtemp)</code> || Inferior to shorter alternatives. |
| | |} |
|
| |
|
| {{#css: | | {{#css: |
Line 34: |
Line 130: |
| |- | | |- |
| |} | | |} |
| | * All instructions cost at least 2 cycles. There is no way to do 1 cycle of delay (though <i>−1 cycles</i> may sometimes appear in branch cost calculations). |
|
| |
|
|
| |
|
| === 3 cycles === | | === 3 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|1 bytes
| |
| |-
| |
| |<pre>48 PHA</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|2 bytes | | !colspan="2"|2 bytes |
| |- | | |- |
| |<pre>A5 00 LDA $00</pre>||Clobbers A, and Z&N | | |<pre>C5 C5 CMP $C5</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>A4 00 LDY $00</pre>||Clobbers Y, and Z&N | | |<pre>24 24 BIT $24</pre>||Clobbers Z&N, and V |
| |- | | |- |
| |<pre>A6 00 LDX $00</pre>||Clobbers X, and Z&N | | |<pre>A5 A5 LDA $A5</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>24 00 BIT $00</pre>||Clobbers Z&N, and V | | |<pre>A6 A6 LDX $A6</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>85 xx STA @zptemp</pre>||Requires @zptemp | | |<pre>A4 A4 LDY $A4</pre>||Clobbers Y, and Z&N |
| |-
| |
| |<pre>04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|3 bytes | | !colspan="2"|3 bytes |
| |- | | |- |
| |<pre>4C xx xx JMP *+3</pre>||Not relocatable code | | |<pre>4C xx xx JMP *+3</pre>||No requirements |
| |- | | |- |
| |} | | |} |
| | * Not relocatable means that the target address is hardcoded into the code. In ROM hacking, it sometimes makes sense to move code blobs around, and a hardcoded address makes it difficult to relocate the code. This restriction does not apply to branches, which use relative addressing. It is also assumed to not apply to <code>JSR</code> instructions, as chances are the JSR target is outside the code being relocated. |
|
| |
|
|
| |
|
| === 4 cycles === | | === 4 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|1 bytes
| |
| |-
| |
| |<pre>68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|2 bytes | | !colspan="2"|2 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2</pre>||No requirements |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
| | * zp-indexed modes such as <code>LDA $00,X</code> also do 4 cycles, but having side effects, these two-byte instructions are inferior to a simple 2 × <code>NOP</code>. |
| | * There is also an unofficial opcode <code>NOP $00,X</code> (34 00), but there is no reason to use this instruction when the official equivalent has the same performance. |
|
| |
|
|
| |
|
| === 5 cycles === | | === 5 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|2 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|3 bytes | | !colspan="2"|3 bytes |
| |-
| |
| |<pre>EA NOP
| |
| A5 00 LDA $00</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A6 00 LDX $00</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A4 00 LDY $00</pre>||Clobbers Y, and Z&N
| |
| |- | | |- |
| |<pre>18 CLC | | |<pre>18 CLC |
Line 102: |
Line 177: |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| | A5 A5 LDA $A5</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| | A6 A6 LDX $A6</pre>||Clobbers X, and Z&N |
| | |- |
| | |<pre>EA NOP |
| | A4 A4 LDY $A4</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 4C xx xx JMP *+3</pre>||Not relocatable code | | 4C xx xx JMP *+3</pre>||No requirements |
| |- | | |- |
| |} | | |} |
| | * abs-indexed modes such as <code>LDA $1234,X</code> cause 4 or 5 cycles of delay, depending whether a page wrap occurred. Because you need extra setup code to make sure that a wrap does occur, you do not see this mode in these samples, outside situations where circumstances permit. |
|
| |
|
|
| |
|
| === 6 cycles === | | === 6 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|2 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|3 bytes | | !colspan="2"|3 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 3</pre>||No requirements |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
| | * zp-indexed RMW instructions such as <code>INC @zptemp,X</code> do 6 cycles. Unless we know the value of X, it might write into any address between $00-$FF. This option is only useful if the entire range of $00-$FF is free for clobbering with random data, or if X has a known value. |
| | * ix instructions like <code>LDA ($00,X)</code> do 6 cycles, but the value of X decides where a pointer is read from, and said pointer can point anywhere. We only do that when the value of X is known. |
| | * iy instructions like <code>LDA ($00),Y</code> also do 5-6 cycles, but in addition to the note above, we cannot predict whether a wrap occurs or not. So we don't use this mode. |
| | * Absolute RMW instructions like <code>INC $4018</code> do 6 cycles, but weighing 3 bytes with side-effects it would be inferior to 3 × <code>NOP</code>. |
|
| |
|
|
| |
|
Line 139: |
Line 212: |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 28 PLP</pre>||Writes in stack | | 28 PLP</pre>||No requirements |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| | |} |
| | * <code>PHP-PLP</code> is very efficient for 7 cycles of delay, but it does modify stack contents. S register remains unchanged though. |
| | * <code>PLA-PHA</code> does not overwrite any bytes in stack. It just writes back the same byte. But it does clobber A and Z+N. It is not interrupt-unsafe either: If an interrupt happens, the stack byte does get temporarily clobbered, but the value is still in A when the interrupt exits, and gets written back in stack. |
| | * abs-indexed RMW instructions such as <code>INC abs,X</code> do 7 cycles. We only do this when either we know the value of X (for instance, <code>INC $4018,X</code> is safe when X is 0—7</code>, or when the entire 256-byte page can be safely overwritten with random data. |
| | |
| | |
| | === 8 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 4</pre>||No requirements |
| EA NOP
| |
| A4 00 LDY $00</pre>||Clobbers Y, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |} |
| EA NOP
| | * Unofficial ix and iy RMW instructions such as <code>SLO ($00,X)</code> or <code>SLO ($00),Y</code> would do 8 cycles for 2 bytes of code. We only do that if we know X or Y to be zero, and we have a known pointer to safely rewritable data. |
| A6 00 LDX $00</pre>||Clobbers X, and Z&N
| | |
| | |
| | === 9 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|3 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 18 CLC
| | 08 PHP |
| 90 00 BCC *+2</pre>||Clobbers C
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |<pre>EA NOP | | |} |
| B8 CLV
| | * Jumping into the middle of another instruction and thereby reusing code is a very efficient way of reducing code size. Note that all code samples using branches on this page require that no page wrap occurs. |
| 50 00 BVC *+2</pre>||Clobbers V
| | |
| | |
| | === 10 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | C5 C5 CMP $C5 |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| | 28 PLP</pre>||No requirements |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
| | * The <code>ROL-ROR</code> sequence preserves the original value of the memory address. Carry is also preserved. |
|
| |
|
|
| |
|
| === 8 cycles === | | === 11 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|2 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|3 bytes
| |
| |-
| |
| |<pre>BA TSX
| |
| 68 PLA
| |
| 9A TXS</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| EA NOP
| | 08 PHP |
| EA NOP
| | 28 PLP</pre>||No requirements |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 9 cycles === | | === 12 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|3 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>20 xx xx JSR @rts12</pre>||Requires @rts12 |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>A2 AE LDX #$AE ;hides 'LDX $FDD0' | | |<pre>36 36 ROL $36,X |
| D0 FD BNE *-1</pre>||Clobbers X, and Z&N
| | 76 36 ROR $36,X</pre>||Clobbers Z&N |
| |-
| |
| |<pre>A0 AC LDY #$AC ;hides 'LDY $FDD0'
| |
| D0 FD BNE *-1</pre>||Clobbers Y, and Z&N
| |
| |- | | |- |
| !colspan="2"|5 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| |
| 18 CLC | | 18 CLC |
| 90 00 BCC *+2</pre>||Clobbers C | | 90 00 BCC *+2 |
| |-
| | 28 PLP</pre>||No requirements |
| |<pre>EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
| | * <code>JSR-RTS</code> causes 12 cycles of delay. But it does write a function return address in the stack, which may be unwanted in some applications. S is not modified. |
| | * Again, <code>ROL-ROR</code> does not have side effects (as long as an interrupt does not happen in the middle), except for Z+N. |
|
| |
|
|
| |
|
| === 10 cycles === | | === 13 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>EA ... NOP × 3 |
| 08 PHP | | 08 PHP |
| 28 PLP</pre>||Clobbers S; and writes in stack | | 28 PLP</pre>||No requirements |
| |- | | |- |
| |<pre>EA NOP | | |} |
| 68 PLA
| | |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| | |
| | === 14 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|4 bytes |
| | |- |
| | |<pre>08 PHP \ × 2 |
| | 28 PLP /</pre>||No requirements |
| |- | | |- |
| !colspan="2"|4 bytes | | |} |
| | |
| | |
| | === 15 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 24 00 BIT $00
| | BA TSX |
| 28 PLP</pre>||Writes in stack | | 28 PLP |
| | 9A TXS |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>26 00 ROL $00 | | |<pre>C5 C5 CMP $C5 |
| 66 00 ROR $00</pre>||Clobbers Z&N
| | 20 xx xx JSR @rts12</pre>||Clobbers Z&N, and C; and requires @rts12 |
| |- | | |- |
| | |<pre>24 24 BIT $24 |
| | 20 xx xx JSR @rts12</pre>||Clobbers Z&N, and V; and requires @rts12 |
| | |- |
| | |<pre>A5 A5 LDA $A5 |
| | 20 xx xx JSR @rts12</pre>||Clobbers A, and Z&N; and requires @rts12 |
| | |- |
| | |<pre>A4 A4 LDY $A4 |
| | 20 xx xx JSR @rts12</pre>||Clobbers Y, and Z&N; and requires @rts12 |
| | |- |
| | !colspan="2"|6 bytes |
| | |- |
| | |<pre>08 PHP |
| | 28 PLP |
| | EA ... NOP × 4</pre>||No requirements |
| | |- |
| | |} |
| | |
| | |
| | === 16 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP \ × 2 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 11 cycles === | | === 17 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>08 PHP |
| | 48 PHA |
| | A5 A5 LDA $A5 |
| 68 PLA | | 68 PLA |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| !colspan="2"|4 bytes | | |} |
| | |
| | |
| | === 18 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| EA NOP
| | 08 PHP \ × 2 |
| 08 PHP | | 28 PLP /</pre>||No requirements |
| 28 PLP</pre>||Writes in stack | |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| | |} |
| | |
| | |
| | === 19 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>A2 02 LDX #2 | | |<pre>08 PHP |
| @X:
| | 28 PLP |
| CA DEX
| | 20 xx xx JSR @rts12</pre>||Requires @rts12 |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 02 LDY #2
| |
| @Y: | |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |- | | |- |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 36 36 ROL $36,X |
| EA NOP
| | 76 36 ROR $36,X |
| 18 CLC
| | 28 PLP</pre>||No requirements |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP | | |} |
| EA NOP
| | |
| EA NOP
| | |
| B8 CLV
| | === 20 cycles === |
| 50 00 BVC *+2</pre>||Clobbers V
| | {| class="wikitable testtable" |
| | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A9 2A LDA #$2A ;hides 'ROL A' |
| EA NOP
| | 38 SEC |
| EA NOP
| | 10 FC BPL *-2</pre>||Clobbers A, Z&N, and C |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 3 |
| EA NOP
| | 08 PHP \ × 2 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 12 cycles === | | === 21 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack | | |<pre>18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 90 FD BCC *-1</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>68 PLA | | |<pre>A2 04 LDX #4 |
| 68 PLA
| | CA DEX |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|4 bytes
| | |<pre>A0 04 LDY #4 |
| |-
| | 88 DEY |
| |<pre>36 00 ROL $00,X | | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP \ × 3 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 13 cycles === | | === 22 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|2 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>00 00 BRK 0</pre>||Requires @rti; and writes in stack | | |<pre>18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 38 SEC |
| | 10 FC BPL *-2</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| !colspan="2"|4 bytes
| | |<pre>A2 02 LDX #2 |
| | EA NOP |
| | CA DEX |
| | 10 FC BPL *-2</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A0 03 LDY #3 |
| 48 PHA
| | EA NOP |
| 08 PHP
| | 88 DEY |
| 28 PLP</pre>||Clobbers S; and writes in stack
| | D0 FC BNE *-2</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|7 bytes |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>08 PHP |
| | BA TSX |
| | 08 PHP |
| | 28 ... PLP × 2 |
| | 9A TXS |
| | 28 PLP</pre>||Clobbers X |
| | |- |
| | |<pre>08 PHP |
| | C5 C5 CMP $C5 |
| | 28 PLP |
| | 20 xx xx JSR @rts12</pre>||Requires @rts12 |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|8 bytes |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP \ × 2 |
| EA NOP
| | 28 PLP / |
| EA NOP | | EA ... NOP × 4</pre>||No requirements |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| | |} |
| | |
| | |
| | === 23 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>18 ... CLC × 2 |
| 26 00 ROL $00
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 66 00 ROR $00</pre>||Clobbers X, and Z&N
| | 90 FD BCC *-1</pre>||Clobbers A, Z&N, and C |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N; and not relocatable code
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A2 04 LDX #4 |
| EA NOP
| | CA DEX |
| EA NOP
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A0 04 LDY #4 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|7 bytes |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP \ × 3 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 14 cycles === | | === 24 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>A9 0A LDA #$0A ;hides 'ASL A' |
| 28 PLP
| | 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>68 PLA | | !colspan="2"|6 bytes |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>20 xx xx JSR @rts12× 2</pre>||Requires @rts12 |
| |-
| |
| |<pre>EA NOP | |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A6 A6 LDX $A6 |
| EA NOP
| | A2 04 LDX #4 |
| EA NOP
| | CA DEX |
| EA NOP
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| EA NOP
| | |- |
| EA NOP
| | |<pre>A4 A4 LDY $A4 |
| EA NOP</pre>||No requirements
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|8 bytes |
| | |- |
| | |<pre>08 PHP |
| | C5 C5 CMP $C5 |
| | 28 PLP \ × 2 |
| | 08 PHP / |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 15 cycles === | | === 25 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack | | |<pre>98 TYA |
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| | A2 04 LDX #4 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|4 bytes
| | |<pre>EA ... NOP × 2 |
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>48 PHA | | !colspan="2"|8 bytes |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |- | | |- |
| |<pre>68 PLA | | |<pre>EA ... NOP × 2 |
| 68 PLA
| | 08 PHP \ × 3 |
| 68 PLA
| | 28 PLP /</pre>||No requirements |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| | |} |
| | |
| | |
| | === 26 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>A5 00 LDA $00 | | |<pre>18 CLC |
| 20 xx xx JSR @rts12</pre>||Clobbers A, and Z&N; requires @rts12; and writes in stack
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A2 04 LDX #4 |
| BA TSX
| | CA DEX |
| 68 PLA
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| 9A TXS
| |
| 68 PLA</pre>||Clobbers X, and Z&N; and writes in stack
| |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>A0 05 LDY #5 |
| 20 xx xx JSR @rts12</pre>||Clobbers Y, and Z&N; requires @rts12; and writes in stack
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>08 PHP | | !colspan="2"|7 bytes |
| BA TSX
| |
| 68 PLA
| |
| 9A TXS
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |- | | |- |
| |<pre>68 PLA | | |<pre>EA NOP |
| 48 PHA
| | 20 xx xx JSR @rts12× 2</pre>||Requires @rts12 |
| BA TSX
| |
| 68 PLA
| |
| 9A TXS</pre>||Clobbers A, X, and Z&N
| |
| |- | | |- |
| |<pre>24 00 BIT $00 | | !colspan="2"|8 bytes |
| 20 xx xx JSR @rts12</pre>||Clobbers Z&N, and V; requires @rts12; and writes in stack
| |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>08 PHP |
| 20 xx xx JSR @rts12</pre>||Requires @zptemp, and @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA | | 48 PHA |
| 48 PHA
| | 36 36 ROL $36,X |
| 08 PHP
| | 76 36 ROR $36,X |
| 28 PLP</pre>||Clobbers S; and writes in stack | | 68 PLA |
| |-
| | 28 PLP</pre>||No requirements |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12, and support for unofficial opcodes; and writes in stack
| |
| |- | | |- |
| | |} |
| | |
| | |
| | === 27 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A5 A5 LDA $A5 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>A5 00 LDA $00 | | !colspan="2"|7 bytes |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>48 PHA |
| 36 00 ROL $00,X
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 76 00 ROR $00,X</pre>||Clobbers X, and Z&N
| | 38 SEC |
| | 10 FC BPL *-2 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>08 PHP |
| 36 00 ROL $00,X
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 76 00 ROR $00,X</pre>||Clobbers Y, and Z&N
| | 38 SEC |
| | 10 FC BPL *-2 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>24 00 BIT $00 | | |<pre>24 2C BIT <$2C ;hides 'BIT $FDA2' |
| 36 00 ROL $00,X
| | A2 FD LDX #253 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| | E8 INX |
| | D0 FA BNE *-4</pre>||Clobbers X, Z&N, and V |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>24 2C BIT <$2C ;hides 'BIT $FDA0' |
| 36 00 ROL $00,X
| | A0 FD LDY #253 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| | C8 INY |
| | D0 FA BNE *-4</pre>||Clobbers Y, Z&N, and V |
| |- | | |- |
| |<pre>04 00 NOP $00 | | |<pre>A4 AC LDY <$AC ;hides 'LDY $82A2' |
| 36 00 ROL $00,X
| | A2 82 LDX #130 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| | CA DEX |
| |-
| | 30 FA BMI *-4</pre>||Clobbers X, Y, and Z&N |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N, and C
| |
| |- | | |- |
| !colspan="2"|8 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 3 |
| EA NOP
| | A2 04 LDX #4 |
| EA NOP
| | CA DEX |
| EA NOP
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 3 |
| EA NOP
| | A0 04 LDY #4 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>24 24 BIT $24 |
| EA NOP
| | 20 xx xx JSR @rts12× 2</pre>||Clobbers Z&N, and V; and requires @rts12 |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>20 xx xx JSR @rts12 |
| EA NOP
| | 08 PHP |
| EA NOP
| | BA TSX |
| EA NOP
| | 28 PLP |
| EA NOP
| | 9A TXS |
| EA NOP
| | 28 PLP</pre>||Clobbers X; and requires @rts12 |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|9 bytes | | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 3 |
| EA NOP
| | 08 PHP \ × 3 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 16 cycles === | | === 28 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>38 ... SEC × 2 |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| !colspan="2"|4 bytes
| | |<pre>EA NOP |
| | A2 04 LDX #4 |
| | CA DEX |
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | A0 05 LDY #5 |
| |-
| | 88 DEY |
| |<pre>A5 00 LDA $00
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| 00 00 BRK 0</pre>||Clobbers A, and Z&N; requires @rti; and writes in stack
| |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | !colspan="2"|7 bytes |
| 00 00 BRK 0</pre>||Clobbers Y, and Z&N; requires @rti; and writes in stack
| |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>48 PHA |
| 00 00 BRK 0</pre>||Clobbers X, and Z&N; requires @rti; and writes in stack
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 90 FD BCC *-1 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>24 00 BIT $00 | | |<pre>08 PHP |
| 00 00 BRK 0</pre>||Clobbers Z&N, and V; requires @rti; and writes in stack
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 90 FD BCC *-1 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>08 PHP |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| | A2 04 LDX #4 |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP | |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |<pre>A2 03 LDX #3
| |
| @X:
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N | | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>A0 03 LDY #3 | | |<pre>08 PHP |
| @Y:
| | A0 04 LDY #4 |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FD BNE *-1 |
| |-
| | 28 PLP</pre>||Clobbers Y |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |- | | |- |
| !colspan="2"|8 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP \ × 4 |
| EA NOP
| | 28 PLP /</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 17 cycles === | | === 29 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|3 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>18 CLC |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | EA NOP |
| | 90 FC BCC *-2</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| !colspan="2"|4 bytes
| | |<pre>A2 04 LDX #4 |
| | EA NOP |
| | CA DEX |
| | D0 FC BNE *-2</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A0 04 LDY #4 |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| | EA NOP |
| | 88 DEY |
| | D0 FC BNE *-2</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|8 bytes |
| EA NOP
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 38 SEC |
| | 10 FC BPL *-2 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>08 PHP |
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 38 SEC |
| | 10 FC BPL *-2 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>A5 00 LDA $00 | | |<pre>08 PHP |
| 20 xx xx JSR @rts14</pre>||Clobbers A, and Z&N; requires @rts14; and writes in stack
| | A2 02 LDX #2 |
| | EA NOP |
| | CA DEX |
| | 10 FC BPL *-2 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>08 PHP |
| 20 xx xx JSR @rts14</pre>||Clobbers Y, and Z&N; requires @rts14; and writes in stack
| | A0 03 LDY #3 |
| | EA NOP |
| | 88 DEY |
| | D0 FC BNE *-2 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | !colspan="2"|9 bytes |
| 20 xx xx JSR @rts14</pre>||Clobbers X, and Z&N; requires @rts14; and writes in stack
| |
| |- | | |- |
| |<pre>24 00 BIT $00 | | |<pre>08 PHP |
| 20 xx xx JSR @rts14</pre>||Clobbers Z&N, and V; requires @rts14; and writes in stack | | 28 PLP |
| | 08 PHP |
| | C5 C5 CMP $C5 |
| | 28 PLP |
| | 20 xx xx JSR @rts12</pre>||Requires @rts12 |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | !colspan="2"|10 bytes |
| 20 xx xx JSR @rts14</pre>||Requires @zptemp, and @rts14; and writes in stack
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>08 PHP |
| 08 PHP | | C5 C5 CMP $C5 |
| 28 PLP | | 28 PLP |
| 08 PHP | | 08 PHP |
| 28 PLP</pre>||Clobbers S; and writes in stack | | 36 36 ROL $36,X |
| | 76 36 ROR $36,X |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |<pre>EA NOP | | |} |
| 68 PLA
| | |
| 68 PLA
| | |
| 68 PLA
| | === 30 cycles === |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| | {| class="wikitable testtable" |
| | !colspan="2"|7 bytes |
| | |- |
| | |<pre>98 TYA |
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>04 00 NOP $00 | | |<pre>EA ... NOP × 2 |
| 20 xx xx JSR @rts14</pre>||Requires @rts14, and support for unofficial opcodes; and writes in stack
| | A2 04 LDX #4 |
| | CA DEX |
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|6 bytes
| | |<pre>EA ... NOP × 2 |
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>08 PHP | | !colspan="2"|8 bytes |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>68 PLA | | |<pre>48 PHA |
| 48 PHA | | 18 ... CLC × 2 |
| 26 00 ROL $00
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 66 00 ROR $00</pre>||Clobbers A, and Z&N
| | 90 FD BCC *-1 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| !colspan="2"|7 bytes
| | |<pre>08 PHP |
| | 18 ... CLC × 2 |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 90 FD BCC *-1 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| A4 00 LDY $00
| | 08 PHP |
| 36 00 ROL $00,X
| | A2 04 LDX #4 |
| 76 00 ROR $00,X</pre>||Clobbers Y, and Z&N
| | CA DEX |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| A6 00 LDX $00
| | 08 PHP |
| 36 00 ROL $00,X
| | A0 04 LDY #4 |
| 76 00 ROR $00,X</pre>||Clobbers X, and Z&N
| | 88 DEY |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>18 CLC | | !colspan="2"|9 bytes |
| 90 00 BCC *+2 | | |- |
| 36 00 ROL $00,X
| | |<pre>08 PHP |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| | 48 PHA |
| | 18 CLC |
| | A9 6A LDA #$6A ;hides 'ROR A' |
| | 90 FD BCC *-1 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |<pre>EA NOP | | |} |
| 24 00 BIT $00
| | |
| 36 00 ROL $00,X
| | |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| | === 31 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>18 CLC |
| 85 xx STA @zptemp
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 36 00 ROL $00,X
| | 90 FD BCC *-1</pre>||Clobbers A, Z&N, and C |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A2 05 LDX #5 |
| 04 00 NOP $00
| | CA DEX |
| 36 00 ROL $00,X
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|8 bytes
| | |<pre>A0 06 LDY #6 |
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|6 bytes |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |- | | |- |
| !colspan="2"|9 bytes
| | |<pre>48 PHA |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 10 FD BPL *-1 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 10 FD BPL *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers A |
| EA NOP
| | |- |
| EA NOP
| | !colspan="2"|8 bytes |
| 18 CLC
| | |- |
| 90 00 BCC *+2</pre>||Clobbers C
| | |<pre>08 PHP |
| | 28 PLP |
| | 20 xx xx JSR @rts12× 2</pre>||Requires @rts12 |
| |- | | |- |
| |<pre>EA NOP
| | !colspan="2"|9 bytes |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A6 A6 LDX $A6 |
| EA NOP
| | A2 04 LDX #4 |
| EA NOP
| | CA DEX |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers X |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A4 A4 LDY $A4 |
| EA NOP
| | A0 04 LDY #4 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers Y |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|10 bytes | | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 36 36 ROL $36,X \ × 2 |
| EA NOP
| | 76 36 ROR $36,X / |
| EA NOP
| | 28 PLP</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 18 cycles === | | === 32 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A2 05 LDX #5 ;hides 'ORA zp' |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| | CA DEX ;first loop only |
| | CA DEX |
| | D0 FB BNE *-3</pre>||Clobbers A, X, and Z&N |
| |- | | |- |
| |<pre>68 PLA | | |<pre>A0 05 LDY #5 ;hides 'ORA zp' |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| | 88 DEY ;first loop only |
| | 88 DEY |
| | D0 FB BNE *-3</pre>||Clobbers A, Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|7 bytes |
| 48 PHA
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>A9 2A LDA #$2A ;hides 'ROL A' |
| | EA ... NOP × 3 |
| | 10 FA BPL *-4</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>A5 00 LDA $00 | | !colspan="2"|8 bytes |
| 20 xx xx JSR @rts15</pre>||Clobbers A, and Z&N; requires @rts15; and writes in stack
| |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>EA NOP |
| 20 xx xx JSR @rts15</pre>||Clobbers Y, and Z&N; requires @rts15; and writes in stack
| | 98 TYA |
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>A6 A6 LDX $A6 |
| 20 xx xx JSR @rts15</pre>||Clobbers X, and Z&N; requires @rts15; and writes in stack
| | A2 04 LDX #4 |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts15</pre>||Clobbers Z&N, and V; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP | | EA NOP |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | CA DEX |
| | D0 FC BNE *-2</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>A4 A4 LDY $A4 |
| 20 xx xx JSR @rts15</pre>||Requires @zptemp, and @rts15; and writes in stack
| | A0 04 LDY #4 |
| | EA NOP |
| | 88 DEY |
| | D0 FC BNE *-2</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|9 bytes |
| A5 00 LDA $00
| |
| 00 00 BRK 0</pre>||Clobbers A, and Z&N; requires @rti; and writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| A4 00 LDY $00
| | 98 TYA |
| 00 00 BRK 0</pre>||Clobbers Y, and Z&N; requires @rti; and writes in stack
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 68 PLA</pre>||Clobbers Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| A6 00 LDX $00
| | 98 TYA |
| 00 00 BRK 0</pre>||Clobbers X, and Z&N; requires @rti; and writes in stack
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>18 CLC | | |<pre>EA ... NOP × 2 |
| 90 00 BCC *+2
| | 08 PHP |
| 00 00 BRK 0</pre>||Clobbers C; requires @rti; and writes in stack
| | A2 04 LDX #4 |
| | CA DEX |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>B8 CLV | | |<pre>EA ... NOP × 2 |
| 50 00 BVC *+2
| | 08 PHP |
| 00 00 BRK 0</pre>||Clobbers V; requires @rti; and writes in stack
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|10 bytes |
| 85 xx STA @zptemp
| |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>08 PHP |
| 48 PHA | | 48 PHA |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| | 18 ... CLC × 2 |
| |-
| | A9 6A LDA #$6A ;hides 'ROR A' |
| |<pre>EA NOP
| | 90 FD BCC *-1 |
| 68 PLA
| |
| 68 PLA | | 68 PLA |
| 68 PLA
| | 28 PLP</pre>||No requirements |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |- | | |- |
| | |} |
| | |
| | |
| | === 33 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>18 ... CLC × 2 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 08 PHP
| | 90 FD BCC *-1</pre>||Clobbers A, Z&N, and C |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A2 05 LDX #5 |
| 68 PLA
| | CA DEX |
| 48 PHA
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| A0 03 LDY #3 | | A0 06 LDY #6 |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |-
| |
| |<pre>EA NOP
| |
| A2 03 LDX #3
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| EA NOP
| | 18 CLC |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 36 00 ROL $00,X
| | 10 FD BPL *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| !colspan="2"|9 bytes | | |<pre>08 PHP |
| | 18 CLC |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | |<pre>08 PHP |
| | A2 04 LDX #4 |
| | CA DEX |
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers X |
| | |- |
| | |<pre>08 PHP |
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| | |- |
| | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP |
| EA NOP
| | 28 PLP |
| EA NOP
| | 20 xx xx JSR @rts12× 2</pre>||Requires @rts12 |
| EA NOP
| | |- |
| EA NOP
| | !colspan="2"|10 bytes |
| EA NOP
| | |- |
| EA NOP
| | |<pre>08 PHP \ × 2 |
| EA NOP</pre>||No requirements
| | 28 PLP / |
| | 08 PHP |
| | 36 36 ROL $36,X |
| | 76 36 ROR $36,X |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 19 cycles === | | === 34 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>A9 0A LDA #$0A ;hides 'ASL A' |
| 20 xx xx JSR @rts15</pre>||Clobbers A, S, and Z&N; requires @rts15; and writes in stack
| | 18 CLC |
| | 10 FC BPL *-2</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A0 88 LDY #136 ;hides 'DEY' |
| 48 PHA
| | 88 DEY |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| | 30 FC BMI *-2</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|7 bytes |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>A6 A6 LDX $A6 |
| | A2 05 LDX #5 |
| | CA DEX |
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>08 PHP | | !colspan="2"|8 bytes |
| 28 PLP
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>C5 C5 CMP $C5 |
| EA NOP
| | 48 PHA |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 10 FD BPL *-1 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A5 A5 LDA $A5 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>68 PLA | | !colspan="2"|9 bytes |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| 48 PHA | | 48 PHA |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 38 SEC |
| | 10 FC BPL *-2 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| | |} |
| | |
| | |
| | === 35 cycles === |
| | {| class="wikitable testtable" |
| !colspan="2"|6 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>A9 2A LDA #$2A ;hides 'ROL A' |
| 36 00 ROL $00,X
| | 08 PHP |
| 76 00 ROR $00,X
| | 28 PLP |
| 28 PLP</pre>||Writes in stack
| | 10 FB BPL *-3</pre>||Clobbers A, Z&N, and C |
| | |- |
| | |<pre>A2 F8 LDX #248 ;hides 'SED' |
| | E8 ... INX × 2 |
| | D0 FB BNE *-3</pre>||Clobbers X, Z&N, and D |
| |- | | |- |
| |<pre>68 PLA | | |<pre>A0 88 LDY #136 ;hides 'DEY' |
| 48 PHA
| | 88 ... DEY × 2 |
| 36 00 ROL $00,X
| | 30 FB BMI *-3</pre>||Clobbers Y, and Z&N |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>98 TYA |
| A0 03 LDY #3 | | A0 06 LDY #6 |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>EA ... NOP × 2 |
| A2 03 LDX #3 | | A2 05 LDX #5 |
| @X:
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|8 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| 18 CLC
| | 38 ... SEC × 2 |
| 90 00 BCC *+2
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 36 00 ROL $00,X
| | 10 FD BPL *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 38 ... SEC × 2 |
| 24 00 BIT $00
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 36 00 ROL $00,X
| | 10 FD BPL *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP |
| 85 xx STA @zptemp
| | A2 04 LDX #4 |
| 36 00 ROL $00,X
| | CA DEX |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP |
| 04 00 NOP $00
| | A0 05 LDY #5 |
| 36 00 ROL $00,X
| | 88 DEY |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| !colspan="2"|9 bytes | | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 48 PHA |
| 4C xx xx JMP *+3
| | 18 CLC |
| 36 00 ROL $00,X | | A9 2A LDA #$2A ;hides 'ROL A' |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| | 90 FD BCC *-1 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| | |- |
| | |} |
| | |
| | |
| | === 36 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|5 bytes |
| | |- |
| | |<pre>A9 E9 LDA #$E9 ;hides 'SBC #$2A' |
| | 2A ROL A ;first loop only |
| | B0 FC BCS *-2</pre>||Clobbers A, Z&N, C, and V |
| | |- |
| | |<pre>A2 07 LDX #7 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| | |- |
| | |<pre>A0 06 LDY #6 |
| | 88 DEY |
| | 10 FD BPL *-1</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|6 bytes |
| | |- |
| | |<pre>38 SEC |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 38 SEC |
| | 10 FC BPL *-2</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| !colspan="2"|10 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| EA NOP | | EA NOP |
| | 90 FC BCC *-2 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| | |- |
| | |<pre>08 PHP |
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| EA NOP | | EA NOP |
| | 90 FC BCC *-2 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | |<pre>08 PHP |
| | A2 04 LDX #4 |
| EA NOP | | EA NOP |
| EA NOP
| | CA DEX |
| EA NOP
| | D0 FC BNE *-2 |
| EA NOP
| | 28 PLP</pre>||Clobbers X |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| | A0 04 LDY #4 |
| EA NOP | | EA NOP |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FC BNE *-2 |
| EA NOP
| | 28 PLP</pre>||Clobbers Y |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|9 bytes |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>20 xx xx JSR @rts12× 3</pre>||Requires @rts12 |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|11 bytes | | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 48 PHA |
| EA NOP
| | 18 CLC |
| EA NOP
| | A9 2A LDA #$2A ;hides 'ROL A' |
| EA NOP
| | 38 SEC |
| EA NOP
| | 10 FC BPL *-2 |
| EA NOP
| | 68 PLA |
| EA NOP
| | 28 PLP</pre>||No requirements |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 20 cycles === | | === 37 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|7 bytes |
| | |- |
| | |<pre>A5 A5 LDA $A5 |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 18 CLC |
| | 10 FC BPL *-2</pre>||Clobbers A, Z&N, and C |
| | |- |
| | |<pre>A2 04 LDX #4 |
| | EA ... NOP × 2 |
| | CA DEX |
| | D0 FB BNE *-3</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>08 PHP | | |<pre>A0 04 LDY #4 |
| 28 PLP
| | EA ... NOP × 2 |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| | 88 DEY |
| | D0 FB BNE *-3</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| !colspan="2"|5 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 48 PHA
| | 98 TYA |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| | A0 06 LDY #6 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>68 PLA | | !colspan="2"|9 bytes |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 48 PHA
| | 98 TYA |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 68 PLA</pre>||Clobbers Z&N |
| |- | | |- |
| !colspan="2"|6 bytes
| | |<pre>08 PHP |
| | 98 TYA |
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| A5 00 LDA $00
| | 08 PHP |
| 20 xx xx JSR @rts15</pre>||Clobbers A, and Z&N; requires @rts15; and writes in stack
| | A2 04 LDX #4 |
| | CA DEX |
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| A4 00 LDY $00
| | 08 PHP |
| 20 xx xx JSR @rts15</pre>||Clobbers Y, and Z&N; requires @rts15; and writes in stack
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|10 bytes |
| A6 00 LDX $00
| |
| 20 xx xx JSR @rts15</pre>||Clobbers X, and Z&N; requires @rts15; and writes in stack
| |
| |- | | |- |
| |<pre>BA TSX | | |<pre>08 PHP |
| | 48 PHA |
| | 18 ... CLC × 2 |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 90 FD BCC *-1 |
| 68 PLA | | 68 PLA |
| 68 PLA
| | 28 PLP</pre>||No requirements |
| 68 PLA
| |
| 68 PLA
| |
| 9A TXS</pre>||Clobbers A, X, and Z&N
| |
| |- | | |- |
| |<pre>18 CLC | | |} |
| 90 00 BCC *+2
| | |
| 20 xx xx JSR @rts15</pre>||Clobbers C; requires @rts15; and writes in stack
| | |
| | === 38 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>B8 CLV | | |<pre>38 SEC |
| 50 00 BVC *+2
| | A9 69 LDA #$69 ;hides 'ADC #$EA' |
| 20 xx xx JSR @rts15</pre>||Clobbers V; requires @rts15; and writes in stack
| | EA NOP ;first loop only |
| | B0 FC BCS *-2</pre>||Clobbers A, Z&N, C, and V |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A2 07 LDX #7 |
| EA NOP
| | CA DEX |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 85 xx STA @zptemp
| | A0 06 LDY #6 |
| 20 xx xx JSR @rts15</pre>||Requires @zptemp, and @rts15; and writes in stack
| | 88 DEY |
| |-
| | 10 FD BPL *-1</pre>||Clobbers Y, and Z&N |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15, and support for unofficial opcodes; and writes in stack
| |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| EA NOP
| | 18 CLC |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 08 PHP
| | 90 FD BCC *-1 |
| 28 PLP
| | 68 PLA</pre>||Clobbers Z&N, and C |
| 08 PHP
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 18 CLC |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 68 PLA
| | 90 FD BCC *-1 |
| 48 PHA
| | 28 PLP</pre>||Clobbers A |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A2 05 LDX #5 |
| A2 03 LDX #3 | |
| @X:
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | A0 06 LDY #6 |
| A0 03 LDY #3 | |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| !colspan="2"|8 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>26 00 ROL $00 | | |<pre>08 PHP |
| 66 00 ROR $00
| | 48 PHA |
| 26 00 ROL $00
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 66 00 ROR $00</pre>||Clobbers Z&N
| | 10 FD BPL *-1 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| !colspan="2"|10 bytes
| | |} |
| |-
| | |
| |<pre>EA NOP
| | |
| EA NOP
| | === 39 cycles === |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |} | |
| | |
| | |
| === 21 cycles === | |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>A9 4A LDA #$4A ;hides 'LSR A' |
| 68 PLA
| | D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| | |- |
| | !colspan="2"|7 bytes |
| |- | | |- |
| !colspan="2"|5 bytes
| | |<pre>A6 A6 LDX $A6 |
| | A2 07 LDX #7 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>A0 04 LDY #4 | | |<pre>A4 A4 LDY $A4 |
| @Y:
| | A0 06 LDY #6 |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| | 10 FD BPL *-1</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|8 bytes |
| | |- |
| | |<pre>98 TYA |
| | A0 88 LDY #136 ;hides 'DEY' |
| | 88 ... DEY × 2 |
| | 30 FB BMI *-3 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>A2 04 LDX #4 | | |<pre>08 PHP |
| @X:
| | A2 05 LDX #5 ;hides 'ORA zp' |
| | CA DEX ;first loop only |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N | | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers A, and X |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 28 PLP | | A0 05 LDY #5 ;hides 'ORA zp' |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | 88 DEY ;first loop only |
| | 88 DEY |
| | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers A, and Y |
| | |- |
| | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 48 PHA
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| | EA ... NOP × 3 |
| | 10 FA BPL *-4 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| | |- |
| | |<pre>08 PHP |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | EA ... NOP × 3 |
| | 10 FA BPL *-4 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 48 PHA | | 48 PHA |
| 48 PHA
| | 98 TYA |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| | A0 05 LDY #5 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 68 PLA</pre>||Clobbers Z&N |
| |- | | |- |
| !colspan="2"|6 bytes
| | |<pre>08 PHP |
| | A6 A6 LDX $A6 |
| | A2 04 LDX #4 |
| | EA NOP |
| | CA DEX |
| | D0 FC BNE *-2 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 48 PHA
| | A4 A4 LDY $A4 |
| 68 PLA
| | A0 04 LDY #4 |
| 48 PHA
| | EA NOP |
| 68 PLA
| | 88 DEY |
| 28 PLP</pre>||Writes in stack | | D0 FC BNE *-2 |
| | 28 PLP</pre>||Clobbers Y |
| | |- |
| | !colspan="2"|11 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>08 PHP |
| 48 PHA | | 48 PHA |
| | 98 TYA |
| | A0 04 LDY #4 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| 68 PLA | | 68 PLA |
| 48 PHA
| | 28 PLP</pre>||No requirements |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|9 bytes | | |} |
| |- | | |
| |<pre>EA NOP | | |
| | === 40 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| | |- |
| | |<pre>A2 05 LDX #5 ;hides 'ORA zp' |
| EA NOP | | EA NOP |
| 18 CLC
| | CA DEX |
| 90 00 BCC *+2
| | D0 FB BNE *-3</pre>||Clobbers A, X, and Z&N |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A0 05 LDY #5 ;hides 'ORA zp' |
| EA NOP | | EA NOP |
| EA NOP
| | 88 DEY |
| 24 00 BIT $00
| | D0 FB BNE *-3</pre>||Clobbers A, Y, and Z&N |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|7 bytes |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>98 TYA |
| EA NOP
| | A0 06 LDY #6 |
| EA NOP
| | 88 DEY |
| 04 00 NOP $00
| | 10 FD BPL *-1 |
| 36 00 ROL $00,X
| | A8 TAY</pre>||Clobbers A, and Z&N |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|10 bytes
| | |<pre>EA ... NOP × 2 |
| | A2 07 LDX #7 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| EA NOP
| | A0 06 LDY #6 |
| EA NOP
| | 88 DEY |
| 4C xx xx JMP *+3
| | 10 FD BPL *-1</pre>||Clobbers Y, and Z&N |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |- | | |- |
| !colspan="2"|11 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| EA NOP
| | 18 ... CLC × 2 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 90 FD BCC *-1 |
| EA NOP
| | 68 PLA</pre>||Clobbers Z&N, and C |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC | |
| 90 00 BCC *+2</pre>||Clobbers C | |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 18 ... CLC × 2 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 90 FD BCC *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers A |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP |
| EA NOP
| | A2 05 LDX #5 |
| EA NOP
| | CA DEX |
| EA NOP
| | 10 FD BPL *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers X |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 08 PHP |
| EA NOP
| | A0 06 LDY #6 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | 28 PLP</pre>||Clobbers Y |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |- | | |- |
| !colspan="2"|12 bytes | | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 48 PHA |
| EA NOP
| | 18 CLC |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 10 FD BPL *-1 |
| EA NOP
| | 68 PLA |
| EA NOP
| | 28 PLP</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 22 cycles === | | === 41 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|5 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>38 SEC |
| 28 PLP
| | A9 4A LDA #$4A ;hides 'LSR A' |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| | D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A2 08 LDX #8 |
| 08 PHP | | CA DEX |
| 28 PLP
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |- | | |- |
| |<pre>68 PLA
| | |<pre>A0 08 LDY #8 |
| 68 PLA
| |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 03 LDY #3 | |
| @Y:
| |
| EA NOP
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>A2 03 LDX #3 | | !colspan="2"|7 bytes |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 08 PHP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 28 PLP
| | 18 CLC |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| | 10 FC BPL *-2 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| 68 PLA
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 68 PLA
| | 18 CLC |
| 68 PLA
| | 10 FC BPL *-2 |
| 68 PLA
| | 28 PLP</pre>||Clobbers A |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| 48 PHA
| | A0 88 LDY #136 ;hides 'DEY' |
| 48 PHA
| | 88 DEY |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| | 30 FC BMI *-2 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 24 00 BIT $00
| | A6 A6 LDX $A6 |
| 28 PLP | | A2 05 LDX #5 |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| | CA DEX |
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers X |
| | |- |
| | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 48 PHA | | 48 PHA |
| BA TSX
| | A5 A5 LDA $A5 |
| 68 PLA
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 9A TXS
| | 10 FD BPL *-1 |
| 68 PLA | | 68 PLA |
| 28 PLP</pre>||Clobbers X; and writes in stack | | 28 PLP</pre>||No requirements |
| | |- |
| | |} |
| | |
| | |
| | === 42 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| | |- |
| | |<pre>A5 A5 LDA $A5 |
| | A9 4A LDA #$4A ;hides 'LSR A' |
| | D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C |
| | |- |
| | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| | A2 05 LDX #5 ;hides 'ORA zp' |
| EA NOP | | EA NOP |
| | CA DEX |
| | D0 FB BNE *-3</pre>||Clobbers A, X, and Z&N |
| | |- |
| | |<pre>EA NOP |
| | A0 05 LDY #5 ;hides 'ORA zp' |
| EA NOP | | EA NOP |
| EA NOP
| | 88 DEY |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | D0 FB BNE *-3</pre>||Clobbers A, Y, and Z&N |
| | |- |
| | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 08 PHP | | 08 PHP |
| 36 00 ROL $00,X
| | 28 PLP |
| 76 00 ROR $00,X
| | 10 FB BPL *-3 |
| 28 PLP</pre>||Clobbers S; and writes in stack
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| !colspan="2"|8 bytes
| | |<pre>08 PHP |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 08 PHP |
| | 28 PLP |
| | 10 FB BPL *-3 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | |<pre>08 PHP |
| | A2 F8 LDX #248 ;hides 'SED' |
| | E8 ... INX × 2 |
| | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 24 00 BIT $00
| | A0 88 LDY #136 ;hides 'DEY' |
| 36 00 ROL $00,X
| | 88 ... DEY × 2 |
| 76 00 ROR $00,X
| | 30 FB BMI *-3 |
| 28 PLP</pre>||Writes in stack | | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>26 00 ROL $00 | | !colspan="2"|9 bytes |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |- | | |- |
| !colspan="2"|11 bytes | | |<pre>48 PHA |
| | 98 TYA |
| | A0 06 LDY #6 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY |
| | 68 PLA</pre>||Clobbers Z&N |
| | |- |
| | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 48 PHA |
| EA NOP
| | 38 ... SEC × 2 |
| EA NOP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| EA NOP
| | 10 FD BPL *-1 |
| EA NOP
| | 68 PLA |
| EA NOP
| | 28 PLP</pre>||No requirements |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 23 cycles === | | === 43 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>38 ... SEC × 2 |
| 68 PLA
| | A9 4A LDA #$4A ;hides 'LSR A' |
| 20 xx xx JSR @rts15</pre>||Clobbers A, S, and Z&N; requires @rts15; and writes in stack
| | D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A2 05 LDX #5 |
| 08 PHP
| | EA NOP |
| 28 PLP
| | CA DEX |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| | 10 FC BPL *-2</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|6 bytes
| | |<pre>A0 06 LDY #6 |
| |-
| | EA NOP |
| |<pre>EA NOP | |
| A0 04 LDY #4 | |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | | D0 FC BNE *-2</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|7 bytes |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>48 PHA |
| 08 PHP | | A9 E9 LDA #$E9 ;hides 'SBC #$2A' |
| 28 PLP | | 2A ROL A ;first loop only |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| | B0 FC BCS *-2 |
| | 68 PLA</pre>||Clobbers Z&N, C, and V |
| | |- |
| | |<pre>08 PHP |
| | A9 E9 LDA #$E9 ;hides 'SBC #$2A' |
| | 2A ROL A ;first loop only |
| | B0 FC BCS *-2 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | |<pre>08 PHP |
| | A2 07 LDX #7 |
| | CA DEX |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 24 00 BIT $00
| | A0 06 LDY #6 |
| 28 PLP | | 88 DEY |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|8 bytes |
| 48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |- | | |- |
| |<pre>68 PLA | | |<pre>48 PHA |
| 68 PLA
| | 38 SEC |
| 68 PLA
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 68 PLA
| | 38 SEC |
| 68 PLA | | 10 FC BPL *-2 |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| 08 PHP | |
| 48 PHA | | 48 PHA |
| | 18 CLC |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | EA NOP |
| | 90 FC BCC *-2 |
| 68 PLA | | 68 PLA |
| 48 PHA
| | 28 PLP</pre>||No requirements |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack | |
| |- | | |- |
| |<pre>EA NOP | | |} |
| 68 PLA
| | |
| 48 PHA
| | |
| 68 PLA
| | === 44 cycles === |
| 48 PHA
| | {| class="wikitable testtable" |
| 68 PLA
| | !colspan="2"|6 bytes |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|10 bytes
| | |<pre>A9 0A LDA #$0A ;hides 'ASL A' |
| | EA ... NOP × 2 |
| | 10 FB BPL *-3</pre>||Clobbers A, Z&N, and C |
| |- | | |- |
| |<pre>EA NOP | | |<pre>A0 88 LDY #136 ;hides 'DEY' |
| EA NOP | | EA NOP |
| EA NOP
| | 88 DEY |
| 18 CLC
| | 30 FB BMI *-3</pre>||Clobbers Y, and Z&N |
| 90 00 BCC *+2
| | |- |
| 36 00 ROL $00,X
| | !colspan="2"|7 bytes |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| | |- |
| | |<pre>A6 A6 LDX $A6 |
| | A2 08 LDX #8 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>24 00 BIT $00 | | !colspan="2"|9 bytes |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00</pre>||Clobbers Z&N, and V
| |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>C5 C5 CMP $C5 |
| 26 00 ROL $00
| | 48 PHA |
| 66 00 ROR $00
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 26 00 ROL $00
| | 18 CLC |
| 66 00 ROR $00</pre>||Clobbers Z&N; and requires @zptemp
| | 10 FC BPL *-2 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>04 00 NOP $00 | | |<pre>08 PHP |
| 26 00 ROL $00
| | A5 A5 LDA $A5 |
| 66 00 ROR $00
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 26 00 ROL $00
| | 18 CLC |
| 66 00 ROR $00</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| | 10 FC BPL *-2 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| !colspan="2"|11 bytes
| | |<pre>08 PHP |
| | A2 04 LDX #4 |
| | EA ... NOP × 2 |
| | CA DEX |
| | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>4C xx xx JMP *+3 | | |<pre>08 PHP |
| 26 00 ROL $00
| | A0 04 LDY #4 |
| 66 00 ROR $00
| | EA ... NOP × 2 |
| 26 00 ROL $00
| | 88 DEY |
| 66 00 ROR $00</pre>||Clobbers Z&N; and not relocatable code
| | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| !colspan="2"|12 bytes | | !colspan="2"|10 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | 48 PHA |
| EA NOP
| | 98 TYA |
| EA NOP
| | A0 06 LDY #6 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | A8 TAY |
| EA NOP
| | 68 PLA</pre>||Clobbers Z&N |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP
| | !colspan="2"|11 bytes |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| EA NOP
| | 48 PHA |
| EA NOP
| | 98 TYA |
| EA NOP
| | A0 05 LDY #5 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | A8 TAY |
| EA NOP
| | 68 PLA |
| EA NOP
| | 28 PLP</pre>||No requirements |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 24 cycles === | | === 45 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|4 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>A9 4A LDA #$0A ;hides 'ASL A' | | |<pre>98 TYA |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| | A0 08 LDY #8 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| | |- |
| | |<pre>EA ... NOP × 2 |
| | A2 08 LDX #8 |
| | CA DEX |
| | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| !colspan="2"|5 bytes | | |<pre>EA ... NOP × 2 |
| | A0 08 LDY #8 |
| | 88 DEY |
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 68 PLA
| | 38 SEC |
| 68 PLA | | A9 69 LDA #$69 ;hides 'ADC #$EA' |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| | EA NOP ;first loop only |
| | B0 FC BCS *-2 |
| | 68 PLA</pre>||Clobbers Z&N, C, and V |
| |- | | |- |
| !colspan="2"|6 bytes
| | |<pre>08 PHP |
| |-
| | 38 SEC |
| |<pre>20 xx xx JSR @rts12 | | A9 69 LDA #$69 ;hides 'ADC #$EA' |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| | EA NOP ;first loop only |
| | B0 FC BCS *-2 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| 08 PHP | | 08 PHP |
| 28 PLP | | A2 07 LDX #7 |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| | CA DEX |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| |
| 08 PHP | | 08 PHP |
| 28 PLP | | A0 06 LDY #6 |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| | 88 DEY |
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers Y |
| | |- |
| | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>68 PLA | | |<pre>08 PHP |
| | 48 PHA |
| | 18 CLC |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 90 FD BCC *-1 |
| 68 PLA | | 68 PLA |
| 68 PLA
| | 28 PLP</pre>||No requirements |
| 68 PLA
| | |- |
| 68 PLA
| | |} |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| | |
| | |
| | === 46 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|5 bytes |
| | |- |
| | |<pre>A2 08 LDX #8 |
| | CA DEX |
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>48 PHA | | |<pre>A0 09 LDY #9 |
| A0 04 LDY #4 | |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack | | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| | |- |
| | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| A2 04 LDX #4
| | A9 4A LDA #$4A ;hides 'LSR A' |
| @X:
| | D0 FD BNE *-1 |
| CA DEX
| | 68 PLA</pre>||Clobbers Z&N, and C |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack | |
| |- | | |- |
| |<pre>48 PHA | | |<pre>08 PHP |
| 08 PHP | | A9 4A LDA #$4A ;hides 'LSR A' |
| 28 PLP | | D0 FD BNE *-1 |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| !colspan="2"|7 bytes | | !colspan="2"|9 bytes |
| |- | | |- |
| |<pre>A6 00 LDX $00 | | |<pre>08 PHP |
| A2 04 LDX #4 | | A6 A6 LDX $A6 |
| @X:
| | A2 07 LDX #7 |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N | | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>A4 00 LDY $00 | | |<pre>08 PHP |
| A0 04 LDY #4 | | A4 A4 LDY $A4 |
| @Y:
| | A0 06 LDY #6 |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>08 PHP | | !colspan="2"|10 bytes |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 08 PHP
| | 98 TYA |
| 48 PHA
| | A0 88 LDY #136 ;hides 'DEY' |
| 68 PLA
| | 88 ... DEY × 2 |
| 48 PHA
| | 30 FB BMI *-3 |
| 68 PLA | | A8 TAY |
| 28 PLP</pre>||Clobbers S; and writes in stack
| | 68 PLA</pre>||Clobbers Z&N |
| |- | | |- |
| !colspan="2"|8 bytes | | !colspan="2"|11 bytes |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 28 PLP
| | 48 PHA |
| 08 PHP
| | A9 2A LDA #$2A ;hides 'ROL A' |
| 26 00 ROL $00
| | EA ... NOP × 3 |
| 66 00 ROR $00
| | 10 FA BPL *-4 |
| 28 PLP</pre>||Writes in stack
| | 68 PLA |
| |-
| | 28 PLP</pre>||No requirements |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| === 25 cycles === | | === 47 cycles === |
| {| class="wikitable testtable" | | {| class="wikitable testtable" |
| !colspan="2"|5 bytes | | !colspan="2"|8 bytes |
| |- | | |- |
| |<pre>20 xx xx JSR @rts12 | | |<pre>98 TYA |
| 00 00 BRK 0</pre>||Requires @rti, and @rts12; and writes in stack
| | A0 06 LDY #6 |
| |-
| | EA NOP |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 00 00 BRK 0</pre>||Clobbers Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>A0 03 LDY #3
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack | | D0 FC BNE *-2 |
| | A8 TAY</pre>||Clobbers A, and Z&N |
| |- | | |- |
| |<pre>A2 03 LDX #3 | | |<pre>EA ... NOP × 3 |
| @X:
| | A2 08 LDX #8 |
| 48 PHA
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack | | D0 FD BNE *-1</pre>||Clobbers X, and Z&N |
| |- | | |- |
| |<pre>68 PLA | | |<pre>08 PHP |
| A2 04 LDX #4 | | A2 05 LDX #5 ;hides 'ORA zp' |
| @X:
| | EA NOP |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N | | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers A, and X |
| |- | | |- |
| |<pre>68 PLA | | |<pre>EA ... NOP × 3 |
| A0 04 LDY #4 | | A0 08 LDY #8 |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N | | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| |- | | |- |
| |<pre>48 PHA | | |<pre>08 PHP |
| 68 PLA
| | A0 05 LDY #5 ;hides 'ORA zp' |
| 68 PLA
| | EA NOP |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| | 88 DEY |
| | D0 FB BNE *-3 |
| | 28 PLP</pre>||Clobbers A, and Y |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|9 bytes |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |- | | |- |
| !colspan="2"|7 bytes
| | |<pre>48 PHA |
| | 98 TYA |
| | A0 06 LDY #6 |
| | 88 DEY |
| | 10 FD BPL *-1 |
| | A8 TAY |
| | 68 PLA</pre>||Clobbers Z&N |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 24 00 BIT $00
| | 98 TYA |
| 28 PLP | | A0 06 LDY #6 |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| | 88 DEY |
| | 10 FD BPL *-1 |
| | A8 TAY |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| EA NOP
| | 08 PHP |
| A2 04 LDX #4 | | A2 07 LDX #7 |
| @X:
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N | | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers X |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA ... NOP × 2 |
| EA NOP
| | 08 PHP |
| A0 04 LDY #4 | | A0 06 LDY #6 |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| | 10 FD BPL *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| |<pre>EA NOP | | !colspan="2"|10 bytes |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>08 PHP |
| 08 PHP | |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA | | 48 PHA |
| 08 PHP
| | 18 ... CLC × 2 |
| 28 PLP
| | A9 0A LDA #$0A ;hides 'ASL A' |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| | 90 FD BCC *-1 |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA | | 68 PLA |
| 68 PLA
| | 28 PLP</pre>||No requirements |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |- | | |- |
| !colspan="2"|8 bytes | | |} |
| | |
| | |
| | === 48 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A2 08 LDX #8 |
| 08 PHP | | CA DEX |
| 48 PHA
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>EA NOP |
| EA NOP
| | A0 09 LDY #9 |
| 68 PLA
| | 88 DEY |
| 48 PHA
| | D0 FD BNE *-1</pre>||Clobbers Y, and Z&N |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |- | | |- |
| !colspan="2"|10 bytes | | !colspan="2"|7 bytes |
| |- | | |- |
| |<pre>24 00 BIT $00 | | |<pre>48 PHA |
| 26 00 ROL $00
| | 38 SEC |
| 66 00 ROR $00
| | A9 4A LDA #$4A ;hides 'LSR A' |
| 36 00 ROL $00,X
| | D0 FD BNE *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| | 68 PLA</pre>||Clobbers Z&N, and C |
| |- | | |- |
| |<pre>85 xx STA @zptemp | | |<pre>08 PHP |
| 26 00 ROL $00
| | 38 SEC |
| 66 00 ROR $00
| | A9 4A LDA #$4A ;hides 'LSR A' |
| 36 00 ROL $00,X
| | D0 FD BNE *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>04 00 NOP $00 | | |<pre>08 PHP |
| 26 00 ROL $00
| | A2 08 LDX #8 |
| 66 00 ROR $00
| | CA DEX |
| 36 00 ROL $00,X
| | D0 FD BNE *-1 |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| | 28 PLP</pre>||Clobbers X |
| | |- |
| | |<pre>08 PHP |
| | A0 08 LDY #8 |
| | 88 DEY |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers Y |
| |- | | |- |
| !colspan="2"|11 bytes | | !colspan="2"|9 bytes |
| | |- |
| | |<pre>08 PHP |
| | 48 PHA |
| | A9 0A LDA #$0A ;hides 'ASL A' |
| | 18 CLC |
| | 10 FC BPL *-2 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| | |- |
| | |} |
| | |
| | |
| | === 49 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|4 bytes |
| |- | | |- |
| |<pre>4C xx xx JMP *+3 | | |<pre>A0 88 LDY #136 ;hides 'DEY' |
| 26 00 ROL $00
| | 30 FD BMI *-1</pre>||Clobbers Y, and Z&N |
| 66 00 ROR $00
| | |- |
| 36 00 ROL $00,X
| | !colspan="2"|7 bytes |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |- | | |- |
| |<pre>18 CLC | | |<pre>18 CLC |
| 90 00 BCC *+2 | | A9 2A LDA #$2A ;hides 'ROL A' |
| 26 00 ROL $00
| | 08 PHP |
| 66 00 ROR $00
| | 28 PLP |
| 26 00 ROL $00
| | 90 FB BCC *-3</pre>||Clobbers A, Z&N, and C |
| 66 00 ROR $00</pre>||Clobbers Z&N, and C
| | |- |
| | |<pre>A6 A6 LDX $A6 |
| | A2 08 LDX #8 |
| | CA DEX |
| | 10 FD BPL *-1</pre>||Clobbers X, and Z&N |
| | |- |
| | !colspan="2"|8 bytes |
| | |- |
| | |<pre>C5 C5 CMP $C5 |
| | 48 PHA |
| | A9 4A LDA #$4A ;hides 'LSR A' |
| | D0 FD BNE *-1 |
| | 68 PLA</pre>||Clobbers Z&N, and C |
| | |- |
| | |<pre>08 PHP |
| | A5 A5 LDA $A5 |
| | A9 4A LDA #$4A ;hides 'LSR A' |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers A |
| | |- |
| | !colspan="2"|10 bytes |
| |- | | |- |
| !colspan="2"|13 bytes
| | |<pre>08 PHP |
| | 48 PHA |
| | A9 2A LDA #$2A ;hides 'ROL A' |
| | 08 PHP |
| | 28 PLP |
| | 10 FB BPL *-3 |
| | 68 PLA |
| | 28 PLP</pre>||No requirements |
| |- | | |- |
| |<pre>EA NOP | | |} |
| | |
| | |
| | === 50 cycles === |
| | {| class="wikitable testtable" |
| | !colspan="2"|6 bytes |
| | |- |
| | |<pre>A9 E9 LDA #$E9 ;hides 'SBC #$2A' |
| | 2A ROL A ;first loop only |
| EA NOP | | EA NOP |
| | B0 FB BCS *-3</pre>||Clobbers A, Z&N, C, and V |
| | |- |
| | |<pre>A2 07 LDX #7 |
| EA NOP | | EA NOP |
| | CA DEX |
| | D0 FC BNE *-2</pre>||Clobbers X, and Z&N |
| | |- |
| | |<pre>A0 06 LDY #6 |
| EA NOP | | EA NOP |
| EA NOP
| | 88 DEY |
| EA NOP
| | 10 FC BPL *-2</pre>||Clobbers Y, and Z&N |
| EA NOP
| | |- |
| EA NOP
| | !colspan="2"|7 bytes |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |- | | |- |
| |<pre>EA NOP | | |<pre>98 TYA |
| EA NOP
| | A0 09 LDY #9 |
| EA NOP
| | 88 DEY |
| EA NOP
| | D0 FD BNE *-1 |
| EA NOP
| | A8 TAY</pre>||Clobbers A, and Z&N |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 26 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|4 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 68 PLA
| |
| 68 PLA
| |
| 20 xx xx JSR @rts15</pre>||Clobbers A, S, and Z&N; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 20 xx xx JSR @rts14</pre>||Clobbers Z&N; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 27 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts12, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 20 xx xx JSR @rts15</pre>||Clobbers A, S, and Z&N; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 20 xx xx JSR @rts15</pre>||Clobbers Z&N; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 03 LDY #3
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 03 LDX #3
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>A2 82 LDX #130 ;hides 'NOP #imm'
| |
| @X = * - 1
| |
| 04 EA NOP $EA ;hides 'NOP'
| |
| CA DEX
| |
| 30 xx BMI @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A0 82 LDY #130 ;hides 'NOP #imm'
| |
| @Y = * - 1
| |
| 04 EA NOP $EA ;hides 'NOP'
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers A, and Z&N; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>08 PHP
| |
| BA TSX
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 9A TXS
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers Z&N, and V; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @zptemp, and @rts12; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 28 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 29 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers Z&N, and V; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 03 LDX #3
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 03 LDY #3
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Clobbers A, and Z&N; requires @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Clobbers Z&N, and V; requires @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Requires @zptemp, @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts12, @rts14, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 08 PHP
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 28 PLP</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 30 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 31 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>B8 CLV
| |
| 50 00 BVC *+2
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers V; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers Z&N, and V; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @zptemp, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 08 PHP
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 28 PLP</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 32 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 05 LDY #5 ;hides 'ORA zp'
| |
| @Y = * - 1
| |
| 88 DEY ;first round only
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 05 LDX #5 ;hides 'ORA zp'
| |
| @X = * - 1
| |
| CA DEX ;first round only
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers A, S, and Z&N; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>A0 FA LDY #250 ;hides 'NOP'
| |
| @Y = * - 1
| |
| EA NOP
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A2 FA LDX #250 ;hides 'NOP'
| |
| @X = * - 1
| |
| EA NOP
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 03 LDY #3
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 03 LDX #3
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 33 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers Z&N, and V; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts12, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @zptemp, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 34 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 82 LDX #130 ;hides 'NOP #imm'
| |
| @X = * - 1
| |
| 04 EA NOP $EA ;hides 'NOP'
| |
| CA DEX
| |
| 30 xx BMI @X
| |
| 28 PLP</pre>||Clobbers X; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 82 LDY #130 ;hides 'NOP #imm'
| |
| @Y = * - 1
| |
| 04 EA NOP $EA ;hides 'NOP'
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 03 LDX #3
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 03 LDY #3
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 35 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and D
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>B8 CLV
| |
| 50 00 BVC *+2
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers V; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @zptemp, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 36 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| EA NOP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Clobbers S; requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 28 PLP
| |
| 08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 37 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 04 LDY #4
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 04 LDX #4
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 68 PLA
| |
| 68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 05 LDX #5
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 05 LDY #5
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 38 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and @rts12; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 39 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|4 bytes
| |
| |-
| |
| |<pre>A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 05 LDX #5 ;hides 'ORA zp'
| |
| @X = * - 1
| |
| CA DEX ;first round only
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 05 LDY #5 ;hides 'ORA zp'
| |
| @Y = * - 1
| |
| 88 DEY ;first round only
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 FA LDY #250 ;hides 'NOP'
| |
| @Y = * - 1
| |
| EA NOP
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 FA LDX #250 ;hides 'NOP'
| |
| @X = * - 1
| |
| EA NOP
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 04 LDX #4
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @zptemp, and @rts12; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts12</pre>||Requires @rts12, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 40 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 05 LDY #5 ;hides 'ORA zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 05 LDX #5 ;hides 'ORA zp'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1</pre>||Clobbers A, S, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 41 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 06 LDX #6
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts12, @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 42 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 05 LDX #5 ;hides 'ORA zp'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 05 LDY #5 ;hides 'ORA zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers Z&N, and V; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts12, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 43 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 44 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 04 LDY #4
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 04 LDX #4
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>B8 CLV
| |
| 50 00 BVC *+2
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers V; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @zptemp, and @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 45 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 46 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 47 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>BA TSX
| |
| 68 PLA
| |
| 9A TXS
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 05 LDX #5 ;hides 'ORA zp'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 05 LDY #5 ;hides 'ORA zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers A, S, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 20 xx xx JSR @rts14</pre>||Requires @rti, and @rts14; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 48 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers Z&N, and V; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @zptemp, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15, and support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 49 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|4 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 50 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 07 LDY #7
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 07 LDX #7
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 51 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| EA NOP
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts14, and @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Clobbers S; requires @rts15; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15
| |
| 20 xx xx JSR @rts15</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 06 LDY #6
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14
| |
| 20 xx xx JSR @rts14</pre>||Requires @rts14; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$0A ;hides 'ASL A'
| |
| 10 FD BPL *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 52 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 07 LDX #7
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 53 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 54 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 68 PLA
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| BA TSX
| |
| 68 PLA
| |
| 9A TXS
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 07 LDX #7
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 55 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and D
| |
| |-
| |
| |<pre>A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and D
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 56 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 00 00 BRK 0
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, S, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 06 LDX #6
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 57 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 08 LDX #8
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 08 LDY #8
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, C, and D
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 07 LDY #7
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 58 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 59 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, Z&N, and D
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, Z&N, and D
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 07 LDX #7
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 60 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|15 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 61 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, C, and D
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0A LDX #10
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 07 LDY #7
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; requires @rts12; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; requires @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 62 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 88 LDX #136 ;hides 'DEY'
| |
| @X = * - 1
| |
| CA DEX
| |
| 30 xx BMI @X</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, and D
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, Z&N, and D
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A, and S; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 63 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 28 PLP</pre>||Clobbers A; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 24 00 BIT $00
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 64 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 08 LDY #8
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, C, and D; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, C, and D
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts15
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 00 00 BRK 0
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 09 LDY #9
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti, and @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|16 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 65 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 08 LDY #8
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 08 LDX #8
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts12
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 66 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, Z&N, and D; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 67 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| 48 PHA
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| 48 PHA
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 06 LDX #6
| |
| @X:
| |
| EA NOP
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A0 06 LDY #6
| |
| @Y:
| |
| EA NOP
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 68 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 08 LDY #8
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>20 xx xx JSR @rts15
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 07 LDY #7
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 20 xx xx JSR @rts12
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; requires @rts12; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 07 LDA #7
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|17 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 69 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 88 LDX #136 ;hides 'DEY'
| |
| @X = * - 1
| |
| CA DEX
| |
| 30 xx BMI @X
| |
| 28 PLP</pre>||Clobbers X, and Y; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0A LDY #10
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 70 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0C LDX #12
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 20 xx xx JSR @rts15
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rts15; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 30 xx BMI @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 00 00 BRK 0
| |
| 08 PHP
| |
| 48 PHA
| |
| A9 4A LDA #$4A ;hides 'LSR A'
| |
| D0 FD BNE *-1
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0A LDA #10
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 71 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 72 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 88 LDX #136 ;hides 'DEY'
| |
| @X = * - 1
| |
| CA DEX
| |
| 30 xx BMI @X
| |
| 28 PLP</pre>||Clobbers X, Y, and S; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|18 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 73 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N, and D; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 74 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 08 LDX #8
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 08 LDY #8
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 75 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 08 LDY #8
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3</pre>||Not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 76 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 0F LDY #15
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 08 LDX #8
| |
| @X:
| |
| A5 00 LDA $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|19 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 77 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2</pre>||Clobbers C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| B8 CLV
| |
| 50 00 BVC *+2</pre>||Clobbers V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp</pre>||Requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00</pre>||Requires support for unofficial opcodes
| |
| |-
| |
| |}
| |
| | |
| | |
| === 78 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0
| |
| 00 00 BRK 0</pre>||Requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 28 PLP
| |
| 08 PHP
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 F8 LDA #248 ;hides 'SED'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP</pre>||No requirements
| |
| |-
| |
| |}
| |
| | |
| | |
| === 79 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 48 PHA
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| A5 00 LDA $00
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| A6 00 LDX $00
| |
| 30 xx BMI @Y</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 24 00 BIT $00
| |
| 30 xx BMI @Y</pre>||Clobbers Y, Z&N, and V
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 85 xx STA @zptemp
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 04 00 NOP $00
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 0F LDY #15
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 80 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 88 LDX #136 ;hides 'DEY'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| 30 xx BMI @X</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 0F LDY #15
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|20 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 81 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 82 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 48 PHA
| |
| 30 xx BMI @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 09 LDY #9
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 09 LDX #9
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 83 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0F LDY #15
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 08 LDX #8
| |
| @X:
| |
| A5 00 LDA $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 06 LDA #6
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 84 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|21 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 85 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 86 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 24 00 BIT $00
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 87 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 F8 LDX #248 ;hides 'SED'
| |
| @X = * - 1
| |
| 68 PLA
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, Z&N, and D
| |
| |-
| |
| |<pre>A0 F8 LDY #248 ;hides 'SED'
| |
| @Y = * - 1
| |
| 68 PLA
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, Z&N, and D
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0C LDX #12
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 88 LDX #136 ;hides 'DEY'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| 30 xx BMI @X
| |
| 28 PLP</pre>||Clobbers X, and Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 88 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|22 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 89 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 68 PLA
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| EA NOP
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| |<pre>A2 0B LDX #11
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 09 LDY #9
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 09 LDX #9
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 90 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 91 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 10 LDX #16
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 92 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 0D LDY #13
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0D LDX #13
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0C LDX #12
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|23 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 93 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 94 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 0C LDX #12
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 0F LDX #15
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 95 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0F LDA #15
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 96 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 13 LDX #19
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| EA NOP
| |
| EA NOP
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0A LDX #10 ;hides 'ASL A'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|24 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 97 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 08 LDX #8
| |
| @X:
| |
| 08 PHP
| |
| 28 PLP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 08 LDY #8
| |
| @Y:
| |
| 08 PHP
| |
| 28 PLP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| A5 00 LDA $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| A4 00 LDY $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and V
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and V
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| 85 xx STA @zptemp
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 85 xx STA @zptemp
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| 04 00 NOP $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 04 00 NOP $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 98 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 13 LDX #19
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 09 LDA #9
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 99 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, C, and V
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| 85 xx STA @zptemp
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| 04 00 NOP $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 100 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 0B LDY #11
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 0B LDX #11
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|25 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 101 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 102 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 0B LDX #11
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 103 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 13 LDX #19
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0C LDY #12
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 104 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0C LDX #12
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0C LDY #12
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|26 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 105 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 0D LDX #13
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 0D LDY #13
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 13 LDX #19
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 106 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0C LDA #12
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 107 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0B LDX #11
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |}
| |
| | |
| | |
| === 108 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|27 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 109 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 0C LDX #12
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A0 0C LDY #12
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| A9 F4 LDA #244 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 0E LDX #14
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 0E LDY #14
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0B LDA #11
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 110 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 111 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 14 LDX #20
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 12 LDX #18
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>4C xx xx JMP *+3
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and not relocatable code
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 26 00 ROL $00
| |
| 66 00 ROR $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |}
| |
| | |
| | |
| === 112 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|28 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 113 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 08 LDA #8
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| 90 00 BCC *+2
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and C
| |
| |-
| |
| |<pre>EA NOP
| |
| 24 00 BIT $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N, and V
| |
| |-
| |
| |<pre>EA NOP
| |
| 85 xx STA @zptemp
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 04 00 NOP $00
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |}
| |
| | |
| | |
| === 114 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 115 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 116 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| A9 F4 LDA #244 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 18 CLC
| |
| A9 F4 LDA #244 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 13 LDY #19
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|29 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 117 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A0 0D LDY #13 ;hides 'ORA abs'
| |
| @Y = * - 1
| |
| A5 00 LDA $0
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 0D LDX #13 ;hides 'ORA abs'
| |
| @X = * - 1
| |
| A5 00 LDA $0
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 118 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0B LDY #11
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0E LDA #14
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 119 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 08 PHP
| |
| 28 PLP
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 68 PLA
| |
| 48 PHA
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 120 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|30 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 121 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 14 LDY #20
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 122 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 11 LDX #17
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 123 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 F4 LDA #244 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 0D LDY #13
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 124 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|4 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0D LDX #13 ;hides 'ORA abs'
| |
| @X = * - 1
| |
| A5 00 LDA $0
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0D LDY #13 ;hides 'ORA abs'
| |
| @Y = * - 1
| |
| A5 00 LDA $0
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|31 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 125 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 126 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 08 PHP
| |
| 28 PLP
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 17 LDX #23
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 127 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 12 LDY #18
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 12 LDX #18
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 128 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 15 LDY #21
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|32 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 129 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 10 LDX #16
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 68 PLA
| |
| 68 PLA
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 16 LDX #22
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 130 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 131 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 36 00 ROL $00,X
| |
| 76 00 ROR $00,X</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 132 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>BA TSX
| |
| 68 PLA
| |
| 9A TXS
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 10 LDX #16
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|33 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 133 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 134 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 13 LDY #19
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 13 LDX #19
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 12 LDX #18
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 135 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 136 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|34 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 137 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| A5 00 LDA $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| A4 00 LDY $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and V
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and V
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 85 xx STA @zptemp
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 85 xx STA @zptemp
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 04 00 NOP $00
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 04 00 NOP $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 13 LDY #19
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 13 LDX #19
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 138 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 12 LDY #18
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 139 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| BA TSX
| |
| 68 PLA
| |
| 9A TXS
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, C, and V
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 85 xx STA @zptemp
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires @zptemp
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 04 00 NOP $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 19 LDX #25
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 140 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|35 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 141 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 13 LDX #19
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 13 LDY #19
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 142 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 98 LDX #152 ;hides 'TYA'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| CA DEX
| |
| 30 xx BMI @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 1A LDX #26 ;hides 'NOP'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A0 1A LDY #26 ;hides 'NOP'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 143 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 12 LDA #18
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 144 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; requires @rti; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|36 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 145 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 12 LDY #18
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 12 LDX #18
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 10 LDX #16
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 12 LDY #18
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 146 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 85 xx STA @zptemp
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 04 00 NOP $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 147 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 12 LDX #18
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 12 LDY #18
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 10 LDX #16
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 148 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 19 LDY #25
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 19 LDA #25
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|37 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 149 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 98 LDX #152 ;hides 'TYA'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| CA DEX
| |
| 30 xx BMI @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1A LDY #26 ;hides 'NOP'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1A LDX #26 ;hides 'NOP'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 150 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 151 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 152 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|38 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 153 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 EA LDY #234 ;hides 'NOP'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 EA LDX #234 ;hides 'NOP'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 11 LDA #17
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 154 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 1C LDX #28
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 10 LDX #16
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 155 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 16 LDX #22
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>18 CLC
| |
| A9 EA LDA #234 ;hides 'NOP'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 48 PHA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 156 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| !colspan="2"|39 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA
| |
| 68 PLA</pre>||Clobbers A, S, and Z&N
| |
| |-
| |
| |}
| |
| | |
| | |
| === 157 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 EA LDX #234 ;hides 'NOP'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 EA LDY #234 ;hides 'NOP'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 16 LDX #22
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 158 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 159 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 18 CLC
| |
| A9 EA LDA #234 ;hides 'NOP'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 1D LDX #29
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 15 LDY #21
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 160 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 EA LDX #234 ;hides 'NOP'
| |
| @X = * - 1
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 EA LDY #234 ;hides 'NOP'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 161 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1E LDY #30
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1E LDX #30
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 162 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 17 LDY #23
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 17 LDX #23
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 16 LDX #22
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| A9 EA LDA #234 ;hides 'NOP'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 18 CLC
| |
| A9 EA LDA #234 ;hides 'NOP'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 163 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 164 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 EA LDY #234 ;hides 'NOP'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 0D LDX #13
| |
| @X:
| |
| 08 PHP
| |
| 28 PLP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 0D LDY #13
| |
| @Y:
| |
| 08 PHP
| |
| 28 PLP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 165 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 166 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 16 LDY #22
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 167 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 168 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 15 LDX #21
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 15 LDA #21
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 169 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 18 LDX #24
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 18 LDY #24
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 EA LDA #234 ;hides 'NOP'
| |
| @A = * - 1
| |
| 69 01 ADC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 170 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 C8 LDY #200 ;hides 'INY'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A2 5A LDX #90 ;hides 'NOP'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| 10 xx BPL @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1E LDA #30
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 171 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 EA LDY #234 ;hides 'NOP'
| |
| @Y = * - 1
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 172 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 13 LDY #19
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 13 LDX #19
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 13 LDX #19
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 13 LDY #19
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 173 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 16 LDY #22
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 0D LDA #13
| |
| @A:
| |
| 08 PHP
| |
| 28 PLP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 174 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 175 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 176 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 177 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 16 LDX #22
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and V
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 85 xx STA @zptemp
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 04 00 NOP $00
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 C8 LDY #200 ;hides 'INY'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A0 10 LDY #16
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 5A LDX #90 ;hides 'NOP'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| 10 xx BPL @X
| |
| 28 PLP</pre>||Clobbers X; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 21 LDX #33
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 178 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 179 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 15 LDX #21 ;hides 'ORA zp,X'
| |
| @X = * - 1
| |
| CA DEX ;first round only
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>A0 15 LDY #21 ;hides 'ORA zp,X'
| |
| @Y = * - 1
| |
| 88 DEY ;first round only
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A2 D8 LDX #216 ;hides 'CLD'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and D
| |
| |-
| |
| |<pre>A0 D8 LDY #216 ;hides 'CLD'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and D
| |
| |-
| |
| |<pre>A0 88 LDY #136 ;hides 'DEY'
| |
| @Y = * - 1
| |
| 00 00 BRK 0
| |
| 30 xx BMI @Y</pre>||Clobbers Y, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 14 LDY #20 ;hides 'NOP zp,X'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A2 14 LDX #20 ;hides 'NOP zp,X'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 13 LDX #19
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 13 LDY #19
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, C, and V
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 85 xx STA @zptemp
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires @zptemp
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 04 00 NOP $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 10 LDA #16
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 180 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 181 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 14 LDA #20 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 C8 LDY #200 ;hides 'INY'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 182 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 EC LDX #236 ;hides 'CPX abs'
| |
| @X = * - 1
| |
| E6 xx INC @zptemp
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and C; and requires @zptemp
| |
| |-
| |
| |<pre>A0 EC LDY #236 ;hides 'CPX abs'
| |
| @Y = * - 1
| |
| E6 xx INC @zptemp
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, and C; and requires @zptemp
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 183 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 20 LDY #32
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 184 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers A, Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 16 LDX #22
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 16 LDY #22
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 185 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 17 LDY #23
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 17 LDX #23
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 186 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 D8 LDX #216 ;hides 'CLD'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 D8 LDY #216 ;hides 'CLD'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 85 xx STA @zptemp
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 04 00 NOP $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 187 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 17 LDX #23
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 188 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 14 LDA #20 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 C8 LDY #200 ;hides 'INY'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 13 LDA #19
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 189 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 EC LDY #236 ;hides 'CPX abs'
| |
| @Y = * - 1
| |
| E6 xx INC @zptemp
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; requires @zptemp; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 EC LDX #236 ;hides 'CPX abs'
| |
| @X = * - 1
| |
| E6 xx INC @zptemp
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 23 LDX #35
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 190 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1B LDX #27
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 191 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 192 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1B LDX #27
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 193 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 16 LDA #22
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 194 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>00 00 BRK 0
| |
| 08 PHP
| |
| A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| 88 DEY
| |
| 30 xx BMI @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; requires @rti; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 24 LDY #36
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 17 LDX #23
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 17 LDY #23
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 195 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 14 LDA #20 ;hides 'NOP zp,X'
| |
| @A = * - 1
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 196 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 25 LDX #37
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 197 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 1C LDY #28
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1C LDX #28
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 198 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 23 LDY #35
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 23 LDA #35
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 199 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 48 PHA
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| A5 00 LDA $00
| |
| D0 xx BNE @X</pre>||Clobbers A, X, and Z&N
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| A4 00 LDY $00
| |
| D0 xx BNE @X</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 24 00 BIT $00
| |
| D0 xx BNE @X</pre>||Clobbers X, Z&N, and V
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 85 xx STA @zptemp
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires @zptemp
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 16 LDY #22
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 04 00 NOP $00
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1B LDX #27
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 24 LDX #36
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 200 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 201 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 202 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 48 PHA
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 26 LDX #38
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 203 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 17 LDY #23
| |
| @Y:
| |
| A5 00 LDA $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 204 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1C LDX #28
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1C LDY #28
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 25 LDY #37
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 205 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 25 LDA #37
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 206 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 24 00 BIT $00
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 207 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 E9 LDX #233 ;hides 'SBC #imm'
| |
| @X = * - 1
| |
| 24 EA BIT $EA ;hides 'NOP'
| |
| E8 INX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, Z&N, C, and V
| |
| |-
| |
| |<pre>A0 E9 LDY #233 ;hides 'SBC #imm'
| |
| @Y = * - 1
| |
| 24 EA BIT $EA ;hides 'NOP'
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, Z&N, C, and V
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 208 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1B LDY #27
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 209 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 1A LDY #26
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A2 1A LDX #26
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 27 LDX #39
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 210 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 28 LDX #40
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 211 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 26 LDY #38
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 26 LDA #38
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 212 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1A LDX #26
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 11 LDX #17
| |
| @X:
| |
| 08 PHP
| |
| 28 PLP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 08 PHP
| |
| 28 PLP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 213 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1C LDA #28
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 214 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 E9 LDY #233 ;hides 'SBC #imm'
| |
| @Y = * - 1
| |
| 24 EA BIT $EA ;hides 'NOP'
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 E9 LDX #233 ;hides 'SBC #imm'
| |
| @X = * - 1
| |
| 24 EA BIT $EA ;hides 'NOP'
| |
| E8 INX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 1D LDY #29
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 1D LDX #29
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 215 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 1C LDY #28
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 216 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 68 PLA
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 217 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 1B LDX #27
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 1B LDY #27
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 18 LDY #24
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 18 LDX #24
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 18 LDX #24
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 18 LDY #24
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 218 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 27 LDY #39
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 27 LDA #39
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 219 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1B LDA #27
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 29 LDX #41
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 220 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 221 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 2C LDX #44
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 2A LDY #42
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 28 LDY #40
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 222 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 11 LDY #17
| |
| @Y:
| |
| 68 PLA
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 11 LDX #17
| |
| @X:
| |
| 68 PLA
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24 ;hides 'CLC'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 223 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 2C LDX #44
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 11 LDY #17
| |
| @Y:
| |
| 68 PLA
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1D LDA #29
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 28 LDA #40
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 224 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 68 PLA
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| EA NOP
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 98 LDY #152 ;hides 'TYA'
| |
| @Y = * - 1
| |
| EA NOP
| |
| 88 DEY
| |
| 30 xx BMI @Y</pre>||Clobbers A, Y, and Z&N
| |
| |-
| |
| |<pre>A0 E4 LDY #228 ;hides 'CPX zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, Z&N, C, and V
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 64 LDY #100 ;hides 'NOP zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| C8 INY
| |
| 10 xx BPL @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 18 LDY #24
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 18 LDX #24
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 225 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 20 LDY #32
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| 24 00 BIT $00
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 226 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>18 CLC
| |
| A9 64 LDA #100 ;hides 'NOP zp'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| 10 xx BPL @A</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 227 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| 68 PLA
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 228 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2C LDX #44
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 29 LDY #41
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 29 LDA #41
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 229 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 2B LDX #43
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 1F LDY #31
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 230 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 2C LDX #44
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 231 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 E4 LDY #228 ;hides 'CPX zp'
| |
| @Y = * - 1
| |
| EA NOP
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 E8 LDX #232 ;hides 'INX'
| |
| @X = * - 1
| |
| EA NOP
| |
| EA NOP
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 2A LDX #42
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2A LDA #42
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 232 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 21 LDY #33
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 21 LDX #33
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 233 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 18 CLC
| |
| A9 64 LDA #100 ;hides 'NOP zp'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| 10 xx BPL @A
| |
| 28 PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 18 CLC
| |
| A9 64 LDA #100 ;hides 'NOP zp'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| 10 xx BPL @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 18 LDX #24 ;hides 'CLC'
| |
| @X = * - 1
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 18 LDA #24
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 234 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 20 LDY #32
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2B LDY #43
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 235 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 1A LDX #26
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A0 1A LDY #26
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 236 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 237 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 2D LDX #45
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 238 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2B LDA #43
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 239 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 21 LDX #33
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 21 LDY #33
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2C LDY #44
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 240 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 18 CLC
| |
| A9 64 LDA #100 ;hides 'NOP zp'
| |
| @A = * - 1
| |
| EA NOP
| |
| 69 01 ADC #1
| |
| 10 xx BPL @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Requires support for unofficial opcodes; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2C LDA #44
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 241 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 242 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A0 CA LDY #202 ;hides 'DEX'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y</pre>||Clobbers X, Y, and Z&N
| |
| |-
| |
| |<pre>A2 4A LDX #74 ;hides 'LSR A'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| 10 xx BPL @X</pre>||Clobbers A, X, Z&N, and C
| |
| |-
| |
| |<pre>A0 4A LDY #74 ;hides 'LSR A'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| 10 xx BPL @Y</pre>||Clobbers A, Y, Z&N, and C
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 243 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 20 LDX #32
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 20 LDA #32
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 244 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 1B LDY #27
| |
| @Y:
| |
| 68 PLA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>A2 1B LDX #27
| |
| @X:
| |
| 68 PLA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 2E LDX #46
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 1A LDY #26
| |
| @Y:
| |
| EA NOP
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 245 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 246 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>8C TXA
| |
| 48 PHA
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2D LDY #45
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 1A LDA #26
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2D LDA #45
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 247 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 2F LDX #47
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 248 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 21 LDA #33
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 249 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 1F LDX #31
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>A0 1F LDY #31
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 4A LDX #74 ;hides 'LSR A'
| |
| @X = * - 1
| |
| E8 INX
| |
| E8 INX
| |
| 10 xx BPL @X
| |
| 28 PLP</pre>||Clobbers A, and X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 4A LDY #74 ;hides 'LSR A'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| 10 xx BPL @Y
| |
| 28 PLP</pre>||Clobbers A, and Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 CA LDY #202 ;hides 'DEX'
| |
| @Y = * - 1
| |
| C8 INY
| |
| C8 INY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers X, and Y; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 22 LDX #34
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 22 LDY #34
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 250 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 21 LDY #33
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 251 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 32 LDY #50
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 32 LDX #50
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 1F LDA #31
| |
| @A:
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A4 00 LDY $00
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A6 00 LDX $00
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>A5 00 LDA $00
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2E LDY #46
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 252 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 1F LDX #31
| |
| @X:
| |
| 48 PHA
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 1F LDY #31
| |
| @Y:
| |
| 48 PHA
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>A0 54 LDY #84 ;hides 'NOP zp,X'
| |
| @Y = * - 1
| |
| 88 DEY ;first round only
| |
| C8 INY
| |
| C8 INY
| |
| 10 xx BPL @Y</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| |<pre>A2 54 LDX #84 ;hides 'NOP zp,X'
| |
| @X = * - 1
| |
| CA DEX ;first round only
| |
| E8 INX
| |
| E8 INX
| |
| 10 xx BPL @X</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 253 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>A2 24 LDX #36
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A0 24 LDY #36
| |
| @Y:
| |
| EA NOP
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 32 LDA #50
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>08 PHP
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A5 00 LDA $00
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 8C TXA
| |
| 48 PHA
| |
| A2 1A LDX #26
| |
| @X:
| |
| EA NOP
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 68 PLA
| |
| AA TAX
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Clobbers S; and writes in stack
| |
| |-
| |
| !colspan="2"|14 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2E LDA #46
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 254 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| A2 32 LDX #50
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, S, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| A0 32 LDY #50
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, S, and Z&N; and writes in stack
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>A6 00 LDX $00
| |
| A2 32 LDX #50
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| |<pre>A4 00 LDY $00
| |
| A0 32 LDY #50
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| !colspan="2"|9 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X, and S; and writes in stack
| |
| |-
| |
| |<pre>48 PHA
| |
| 48 PHA
| |
| 08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y, and S; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 68 PLA
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| A2 30 LDX #48
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>48 PHA
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| EA NOP
| |
| 08 PHP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|12 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| 48 PHA
| |
| 38 SEC
| |
| A9 2F LDA #47
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
| | |
| | |
| === 255 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|6 bytes
| |
| |-
| |
| |<pre>68 PLA
| |
| A2 32 LDX #50
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers A, X, S, and Z&N
| |
| |-
| |
| |<pre>68 PLA
| |
| A0 32 LDY #50
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers A, Y, S, and Z&N
| |
| |-
| |
| !colspan="2"|7 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| A0 24 LDY #36 | |
| @Y:
| |
| EA NOP
| |
| 88 DEY | |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N | |
| |-
| |
| |<pre>EA NOP
| |
| A2 24 LDX #36
| |
| @X:
| |
| EA NOP
| |
| CA DEX
| |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| |
| |-
| |
| !colspan="2"|8 bytes
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A0 31 LDY #49
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>EA NOP
| |
| 08 PHP
| |
| A2 31 LDX #49
| |
| @X:
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 24 LDA #36
| |
| @A:
| |
| EA NOP
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |- | | |- |
| !colspan="2"|9 bytes | | !colspan="2"|8 bytes |
| |-
| |
| |<pre>08 PHP
| |
| 38 SEC
| |
| A9 31 LDA #49
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |- | | |- |
| |<pre>48 PHA | | |<pre>48 PHA |
| 38 SEC | | 38 ... SEC × 2 |
| A9 31 LDA #49 | | A9 4A LDA #$4A ;hides 'LSR A' |
| @A:
| | D0 FD BNE *-1 |
| E9 01 SBC #1
| | 68 PLA</pre>||Clobbers Z&N, and C |
| D0 xx BNE @A | |
| 68 PLA</pre>||Clobbers Z&N, and C; and writes in stack | |
| |- | | |- |
| !colspan="2"|12 bytes
| | |<pre>08 PHP |
| | 38 ... SEC × 2 |
| | A9 4A LDA #$4A ;hides 'LSR A' |
| | D0 FD BNE *-1 |
| | 28 PLP</pre>||Clobbers A |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 48 PHA
| | A2 05 LDX #5 |
| 38 SEC
| |
| A9 22 LDA #34
| |
| @A:
| |
| EA NOP | | EA NOP |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack
| |
| |-
| |
| |}
| |
|
| |
|
| |
| === 256 cycles ===
| |
| {| class="wikitable testtable"
| |
| !colspan="2"|5 bytes
| |
| |-
| |
| |<pre>A0 33 LDY #51
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y</pre>||Clobbers Y, and Z&N
| |
| |-
| |
| |<pre>A2 33 LDX #51
| |
| @X:
| |
| CA DEX | | CA DEX |
| D0 xx BNE @X</pre>||Clobbers X, and Z&N
| | 10 FC BPL *-2 |
| |-
| | 28 PLP</pre>||Clobbers X |
| !colspan="2"|9 bytes
| |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| A2 1F LDX #31
| | A0 06 LDY #6 |
| @X:
| |
| 24 00 BIT $00
| |
| CA DEX
| |
| D0 xx BNE @X
| |
| 28 PLP</pre>||Clobbers X; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| A0 1F LDY #31 | |
| @Y:
| |
| 24 00 BIT $00
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 28 PLP</pre>||Clobbers Y; and writes in stack
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| 48 PHA
| |
| 48 PHA
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, S, Z&N, and C; and writes in stack
| |
| |-
| |
| !colspan="2"|10 bytes
| |
| |-
| |
| |<pre>38 SEC
| |
| A9 17 LDA #23
| |
| @A:
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP | | EA NOP |
| E9 01 SBC #1
| |
| D0 xx BNE @A</pre>||Clobbers A, Z&N, and C
| |
| |-
| |
| !colspan="2"|11 bytes
| |
| |-
| |
| |<pre>98 TYA
| |
| 48 PHA
| |
| EA NOP
| |
| EA NOP
| |
| A0 30 LDY #48
| |
| @Y:
| |
| 88 DEY | | 88 DEY |
| D0 xx BNE @Y | | D0 FC BNE *-2 |
| 68 PLA
| | 28 PLP</pre>||Clobbers Y |
| A8 TAY</pre>||Clobbers A, and Z&N; and writes in stack
| |
| |- | | |- |
| !colspan="2"|12 bytes | | !colspan="2"|9 bytes |
| |-
| |
| |<pre>48 PHA
| |
| EA NOP
| |
| 98 TYA
| |
| 48 PHA
| |
| A0 2F LDY #47
| |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA
| |
| A8 TAY
| |
| 68 PLA</pre>||Clobbers Z&N; and writes in stack
| |
| |-
| |
| |<pre>08 PHP
| |
| EA NOP
| |
| EA NOP
| |
| EA NOP
| |
| 38 SEC
| |
| A9 30 LDA #48
| |
| @A:
| |
| E9 01 SBC #1
| |
| D0 xx BNE @A
| |
| 28 PLP</pre>||Clobbers A; and writes in stack
| |
| |-
| |
| !colspan="2"|13 bytes
| |
| |- | | |- |
| |<pre>08 PHP | | |<pre>08 PHP |
| 48 PHA | | 48 PHA |
| 98 TYA
| | A9 E9 LDA #$E9 ;hides 'SBC #$2A' |
| 48 PHA
| | 2A ROL A ;first loop only |
| A0 2E LDY #46
| | B0 FC BCS *-2 |
| @Y:
| |
| 88 DEY
| |
| D0 xx BNE @Y
| |
| 68 PLA | | 68 PLA |
| A8 TAY
| | 28 PLP</pre>||No requirements |
| 68 PLA
| |
| 28 PLP</pre>||Writes in stack | |
| |- | | |- |
| |} | | |} |
|
| |
|
|
| |
|
| == More == | | == Sanity checks == |
| Bisqwit's 6502 delay_n macro set for ca65: http://bisqwit.iki.fi/src/6502-inline_delay.7z
| | |
| | It is possible to verify on compile time that no page wrap occurs, |
| | by replacing all branches with these macros: |
| | <pre>.macro branch_check opc, dest |
| | opc dest |
| | .assert >* = >(dest), warning, "branch_check: failed, crosses page" |
| | .endmacro |
| | .macro bccnw dest |
| | branch_check bcc, dest |
| | .endmacro |
| | .macro bcsnw dest |
| | branch_check bcs, dest |
| | .endmacro |
| | .macro beqnw dest |
| | branch_check beq, dest |
| | .endmacro |
| | .macro bnenw dest |
| | branch_check bne, dest |
| | .endmacro |
| | .macro bminw dest |
| | branch_check bmi, dest |
| | .endmacro |
| | .macro bplnw dest |
| | branch_check bpl, dest |
| | .endmacro |
| | .macro bvcnw dest |
| | branch_check bvc, dest |
| | .endmacro |
| | .macro bvsnw dest |
| | branch_check bvs, dest |
| | .endmacro</pre> |
| | |
| | == See also == |
| | |
| | * [[Cycle counting]] |
| | * [[Delay code]] for functions that produce runtime-determined amount of delay |
| | * Bisqwit’s “vending machine” for producing a ca65-compatible delay_n macro for arbitrary number of cycles, with more fine-grained configurable constraints: http://bisqwit.iki.fi/utils/nesdelay.php The samples on this page are excerpts from files generated by this online tool. |