Fixed cycle delay: Difference between revisions

From NESdev Wiki
Jump to navigationJump to search
(Updated explanations; added one more loop mode)
(New push&pop engine opened new opportunities)
Line 172: Line 172:
|-
|-
|}
|}
* 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, which is this option is only useful if the entire range of $00-$FF is free for clobbering with random data.
* 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.
* 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.
* 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 $2000</code> do 6 cycles, but weighing 3 bytes with side-effects it would be inferior to 3 &times; <code>NOP</code>.
* Absolute RMW instructions like <code>INC $4018</code> do 6 cycles, but weighing 3 bytes with side-effects it would be inferior to 3 &times; <code>NOP</code>.




Line 1,233: Line 1,233:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28       PLP
48       PHA
08      PHP
F6 F6    INC $F6,X
F6 F6    INC $F6,X
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
Line 1,283: Line 1,283:
28      PLP      /</pre>||Writes in stack
28      PLP      /</pre>||Writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
68       PLA      \ &times; 2
A2 03    LDX #3
48      PHA       /</pre>||Clobbers A, and Z&N
CA       DEX
D0 FD    BNE *-1
AA       TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 1,498: Line 1,500:
|<pre>EA      NOP
|<pre>EA      NOP
08      PHP
08      PHP
28       PLP
48       PHA
08      PHP
F6 F6    INC $F6,X
F6 F6    INC $F6,X
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
Line 1,743: Line 1,745:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28       PLP
48       PHA
08      PHP
26 26    ROL $26
26 26    ROL $26
66 26    ROR $26
66 26    ROR $26
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
Line 1,816: Line 1,818:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>8C       TXA
18       CLC
A2 04   LDX #4
A9 2A   LDA #$2A ;hides 'ROL A'
CA      DEX
90 FD    BCC *-1</pre>||Clobbers A, Z&N, and C
D0 FD    BNE *-1
|-
AA       TAX</pre>||Clobbers A, and Z&N
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
08       PHP
28      PLP
10 FA    BPL *-4</pre>||Clobbers A, and Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 1,867: Line 1,864:
28      PLP
28      PLP
00 00    BRK 0</pre>||Requires dummy interrupt handler; and writes in stack
00 00    BRK 0</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 4</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 1,883: Line 1,875:
08      PHP      \ &times; 3
08      PHP      \ &times; 3
28      PLP      /</pre>||Writes in stack
28      PLP      /</pre>||Writes in stack
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 2,018: Line 2,006:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28       PLP
48       PHA
08      PHP
36 36    ROL $36,X
36 36    ROL $36,X
76 36    ROR $36,X
76 36    ROR $36,X
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>36 36    ROL $36,X
|<pre>8C      TXA
76 36   ROR $36,X
A2 03   LDX #3
68       PLA       \ &times; 2
EA       NOP
48      PHA       /</pre>||Clobbers A, and Z&N
CA       DEX
D0 FC    BNE *-2
AA       TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 2,126: Line 2,116:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 04    LDX #4
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 2,142: Line 2,139:
08      PHP      /
08      PHP      /
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>24 24    BIT $24
|<pre>24 24    BIT $24
Line 2,181: Line 2,174:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA  ... NOP      &times; 3
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 2,458: Line 2,447:
20 xx xx JSR @rts14</pre>||Requires @rts12, @rts14, and support for unofficial opcodes; and writes in stack
20 xx xx JSR @rts14</pre>||Requires @rts12, @rts14, and support for unofficial opcodes; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>68       PLA
68       PLA
8C       TXA
48       PHA
A2 04    LDX #4
68  ... PLA      &times; 5</pre>||Clobbers A, S, and Z&N
CA       DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 2,468: Line 2,459:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 04    LDX #4
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 2,475: Line 2,473:
08      PHP      /
08      PHP      /
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>EA      NOP
F6 F6    INC $F6,X
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>20 xx xx JSR @rts12
|<pre>20 xx xx JSR @rts12
Line 2,489: Line 2,482:
|<pre>48      PHA
|<pre>48      PHA
08      PHP
08      PHP
28       PLP
48       PHA
08      PHP
36 36    ROL $36,X
36 36    ROL $36,X
76 36    ROR $36,X
76 36    ROR $36,X
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
28      PLP</pre>||Clobbers S; and writes in stack
|-
|-
Line 2,504: Line 2,497:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>68      PLA
|<pre>E6 xx    INC @zptemp
48      PHA
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X</pre>||Clobbers A, and Z&N
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 2
36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
Line 2,635: Line 2,621:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 05   LDX #5
10 FD    BPL *-1</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 2,682: Line 2,670:
|<pre>F6 F6    INC $F6,X
|<pre>F6 F6    INC $F6,X
20 xx xx JSR @rts12&times; 2</pre>||Clobbers Z&N; requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
20 xx xx JSR @rts12&times; 2</pre>||Clobbers Z&N; requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
|-
|<pre>EA      NOP
68  ... PLA      &times; 7</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 2,698: Line 2,683:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA      NOP
68      PLA      \ &times; 4
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 2,828: Line 2,809:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 04    LDX #4
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>8C      TXA
A2 82    LDX #130 ;hides 'NOP #imm'
04 EA    NOP $EA ;hides 'NOP'
CA      DEX
30 FA    BMI *-4
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 2,998: Line 2,993:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>A6 A6    LDX $A6
|<pre>A6 A6    LDX $A6
Line 3,013: Line 3,015:
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
20 xx xx JSR @rts14&times; 2</pre>||Requires @rts12, and @rts14; and writes in stack
20 xx xx JSR @rts14&times; 2</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|<pre>68  ... PLA      &times; 8</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
A9 09   LDA #$09 ;hides 'ORA #$EA'
8C      TXA
EA       NOP ;first loop only
A2 04   LDX #4
08      PHP
CA       DEX
28      PLP
D0 FD   BNE *-1
10 FA   BPL *-4
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>08      PHP
08      PHP
8C       TXA
18       CLC
A2 04   LDX #4
A9 2A   LDA #$2A ;hides 'ROL A'
CA      DEX
90 FD    BCC *-1
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 3,074: Line 3,075:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 4
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 3,155: Line 3,152:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 04    LDX #4
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 3,176: Line 3,180:
28      PLP
28      PLP
20 xx xx JSR @rts12&times; 2</pre>||Requires @rts12; and writes in stack
20 xx xx JSR @rts12&times; 2</pre>||Requires @rts12; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 6</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 3,190: Line 3,189:
76 36    ROR $36,X
76 36    ROR $36,X
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 3,364: Line 3,358:
|<pre>EA  ... NOP      &times; 4
|<pre>EA  ... NOP      &times; 4
00 00... BRK 0    &times; 2</pre>||Requires dummy interrupt handler; and writes in stack
00 00... BRK 0    &times; 2</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 3,378: Line 3,379:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>EA       NOP
|<pre>EA  ... NOP     &times; 2
68   ... PLA     &times; 8</pre>||Clobbers A, S, and Z&N
8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>F6 F6    INC $F6,X
|<pre>26 26    ROL $26
68      PLA      \ &times; 4
66 26    ROR $26
48      PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 3
68      PLA      \ &times; 4
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|12 bytes
|-
|<pre>26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 2
36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /</pre>||Clobbers Z&N
76 36    ROR $36,X /</pre>||Clobbers Z&N
Line 3,441: Line 3,434:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>8C       TXA
18       CLC
A2 06   LDX #6
A9 0A   LDA #$0A ;hides 'ASL A'
CA      DEX
90 FD    BCC *-1</pre>||Clobbers A, Z&N, and C
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 3,465: Line 3,459:
28      PLP
28      PLP
00 00... BRK 0    &times; 2</pre>||Requires dummy interrupt handler; and writes in stack
00 00... BRK 0    &times; 2</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28      PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 3,520: Line 3,508:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 7</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|10 bytes
|-
|<pre>68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 3,709: Line 3,688:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>20 xx xx JSR @rts12&times; 3</pre>||Requires @rts12; and writes in stack
|<pre>20 xx xx JSR @rts12&times; 3</pre>||Requires @rts12; and writes in stack
|-
|-
|<pre>68   ... PLA     &times; 9</pre>||Clobbers A, S, and Z&N
|<pre>8C      TXA
A2 FA    LDX #250 ;hides 'NOP'
EA      NOP
E8   ... INX     &times; 2
D0 FA    BNE *-4
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 3,725: Line 3,724:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|11 bytes
|<pre>A5 A5    LDA $A5
|-
8C       TXA
|<pre>EA       NOP
A2 04   LDX #4
F6 F6   INC $F6,X
EA       NOP
68       PLA       \ &times; 4
CA       DEX
48       PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
D0 FC    BNE *-2
AA       TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 3,810: Line 3,810:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 06    LDX #6
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>F6 F6    INC $F6,X
|<pre>F6 F6    INC $F6,X
Line 3,845: Line 3,852:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>48      PHA
48      PHA
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 05   LDX #5
10 FD    BPL *-1
CA      DEX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>08      PHP
08      PHP
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 05   LDX #5
10 FD    BPL *-1
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 3,885: Line 3,896:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|13 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
68      PLA
E6 xx    INC @zptemp
48      PHA
F6 F6... INC $F6,X&times; 5</pre>||Clobbers Z&N; and requires @zptemp, and writable $00-$FF
68  ... PLA      &times; 7</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|11 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|13 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
F6 F6... INC $F6,X&times; 5</pre>||Clobbers Z&N; and requires @zptemp, and writable $00-$FF
|-
|-
!colspan="2"|14 bytes
!colspan="2"|14 bytes
Line 4,026: Line 4,026:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>98      TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
18       CLC
88       DEY
10 FC    BPL *-2</pre>||Clobbers A, Z&N, and C
30 FC    BMI *-2
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 4,060: Line 4,061:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 9</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|12 bytes
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|13 bytes
!colspan="2"|13 bytes
Line 4,130: Line 4,119:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>98      TYA
A0 88    LDY #136 ;hides 'DEY'
88  ... DEY      &times; 2
30 FB    BMI *-3
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 4,144: Line 4,139:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and Y; and writes in stack
28      PLP</pre>||Clobbers A, and Y; and writes in stack
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
20 xx xx JSR @rts14
10 F9    BPL *-5</pre>||Clobbers A, and Z&N; requires @rts12, and @rts14; and writes in stack
|-
|<pre>68  ... PLA      &times; 2
08      PHP
A9 0A    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
!colspan="2"|9 bytes
Line 4,218: Line 4,202:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 05    LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 4,239: Line 4,232:
28      PLP
28      PLP
20 xx xx JSR @rts14&times; 2</pre>||Requires @rts12, and @rts14; and writes in stack
20 xx xx JSR @rts14&times; 2</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 8</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 4,249: Line 4,238:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>08      PHP
08      PHP
48      PHA
48      PHA
18       CLC
8C       TXA
A9 2A   LDA #$2A ;hides 'ROL A'
A2 04   LDX #4
90 FD    BCC *-1
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|14 bytes
!colspan="2"|14 bytes
Line 4,374: Line 4,358:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA       NOP
|<pre>8C       TXA
38      SEC
A2 07   LDX #7
A9 69   LDA #$69 ;hides 'ADC #$EA'
CA       DEX
EA       NOP ;first loop only
D0 FD   BNE *-1
10 FC   BPL *-2</pre>||Clobbers A, Z&N, C, and V
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 4,389: Line 4,373:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
10 FC    BPL *-2</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 4,407: Line 4,386:
|<pre>00 00... BRK 0    &times; 2
|<pre>00 00... BRK 0    &times; 2
20 xx xx JSR @rts14</pre>||Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
20 xx xx JSR @rts14</pre>||Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
|-
|<pre>EA      NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
10 FC    BPL *-2</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 4,422: Line 4,395:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>EA   ... NOP     &times; 3
|<pre>08      PHP
18   ... CLC     &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 FD    BCC *-1
10 FC    BPL *-2</pre>||Clobbers A, Z&N, and C
|-
|<pre>08      PHP
18  ... CLC      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 4,460: Line 4,428:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>68  ... PLA      &times; 10</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|12 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 4
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|14 bytes
!colspan="2"|14 bytes
Line 4,534: Line 4,491:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>8C      TXA
A2 04    LDX #4
EA  ... NOP      &times; 2
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 4,570: Line 4,534:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 8</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|12 bytes
|-
|<pre>F6 F6    INC $F6,X
68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 3
68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|14 bytes
!colspan="2"|14 bytes
Line 4,750: Line 4,695:
10 FB    BPL *-3
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA      NOP
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 4,794: Line 4,746:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 06    LDX #6
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>20 xx xx JSR @rts14&times; 3</pre>||Requires @rts12, and @rts14; and writes in stack
|<pre>20 xx xx JSR @rts14&times; 3</pre>||Requires @rts12, and @rts14; and writes in stack
Line 4,821: Line 4,781:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 10</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|12 bytes
|-
|<pre>68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|14 bytes
!colspan="2"|14 bytes
Line 4,915: Line 4,865:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>20 xx xx JSR @rts15
|<pre>20 xx xx JSR @rts15
Line 4,936: Line 4,893:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 9</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|13 bytes
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 8
10 F4    BPL *-10</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|15 bytes
!colspan="2"|15 bytes
Line 5,090: Line 5,034:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 5,117: Line 5,068:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 5,178: Line 5,136:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>08       PHP
|<pre>EA       NOP
F6 F6    INC $F6,X
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
8C      TXA
A2 06    LDX #6
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
10 FD    BPL *-1
68      PLA
68      PLA
Line 5,208: Line 5,175:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>08      PHP
08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
10 FD    BPL *-1
A2 05   LDX #5
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>68  ... PLA      &times; 11</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|13 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|15 bytes
!colspan="2"|15 bytes
Line 5,273: Line 5,234:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 08   LDX #8
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 5,342: Line 5,305:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 9</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|14 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /
68      PLA      \ &times; 3
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|16 bytes
!colspan="2"|16 bytes
Line 5,504: Line 5,453:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 5,511: Line 5,467:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
A9 09   LDA #$09 ;hides 'ORA #$EA'
98      TYA
EA      NOP ;first loop only
A0 88   LDY #136 ;hides 'DEY'
20 xx xx JSR @rts14
88  ... DEY      &times; 2
10 F9   BPL *-5
30 FB   BMI *-3
68      PLA</pre>||Clobbers Z&N; requires @rts12, and @rts14; and writes in stack
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 07    LDX #7
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 5,535: Line 5,507:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 11</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|14 bytes
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|16 bytes
!colspan="2"|16 bytes
Line 5,641: Line 5,602:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 06   LDX #6
EA      NOP
EA      NOP
18       CLC
CA       DEX
10 FB   BPL *-3</pre>||Clobbers A, Z&N, and C
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 5,671: Line 5,633:
28      PLP</pre>||Clobbers A, and Y; and writes in stack
28      PLP</pre>||Clobbers A, and Y; and writes in stack
|-
|-
|<pre>68       PLA
!colspan="2"|9 bytes
08       PHP
|-
A9 E9   LDA #$E9 ;hides 'SBC #$2A'
|<pre>48       PHA
2A       ROL A ;first loop only
8C       TXA
B0 FC   BCS *-2
A2 07   LDX #7
28       PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
CA       DEX
D0 FD   BNE *-1
AA      TAX
68       PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
|<pre>08       PHP
|-
8C       TXA
|<pre>EA       NOP
A2 07   LDX #7
48       PHA
CA       DEX
38      SEC
D0 FD   BNE *-1
A9 69   LDA #$69 ;hides 'ADC #$EA'
AA       TAX
EA       NOP ;first loop only
10 FC   BPL *-2
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
10 FC    BPL *-2
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 5,709: Line 5,664:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 5,723: Line 5,671:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
F6 F6    INC $F6,X
00 00... BRK 0    &times; 3</pre>||Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 5,732: Line 5,676:
00 00... BRK 0    &times; 2
00 00... BRK 0    &times; 2
20 xx xx JSR @rts14</pre>||Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
20 xx xx JSR @rts14</pre>||Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
10 FC    BPL *-2
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 5,752: Line 5,690:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 10</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|14 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 5
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|16 bytes
!colspan="2"|16 bytes
Line 5,905: Line 5,830:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>98      TYA
A0 88    LDY #136 ;hides 'DEY'
EA      NOP
88      DEY
30 FB    BMI *-3
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 5,915: Line 5,849:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>68  ... PLA      &times; 12</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|14 bytes
|-
|<pre>F6 F6    INC $F6,X
68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
!colspan="2"|15 bytes
|-
|<pre>EA  ... NOP      &times; 3
68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|16 bytes
!colspan="2"|16 bytes
Line 6,040: Line 5,958:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 08    LDX #8
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 08    LDX #8
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 6,093: Line 6,025:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 10</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|14 bytes
|-
|<pre>68      PLA      \ &times; 7
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|17 bytes
!colspan="2"|17 bytes
Line 6,229: Line 6,149:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>A9 2A   LDA #$2A ;hides 'ROL A'
|<pre>8C      TXA
20 xx xx JSR @rts12
A2 09   LDX #9
10 FA   BPL *-4</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
CA      DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 6,242: Line 6,164:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68  ... PLA      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, S, Z&N, and C
|-
|<pre>68      PLA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 6,261: Line 6,172:
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 6,297: Line 6,202:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 12</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|15 bytes
|-
|<pre>68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 8
10 F4    BPL *-10</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|17 bytes
!colspan="2"|17 bytes
Line 6,404: Line 6,295:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>8C      TXA
A2 08    LDX #8
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 6,414: Line 6,312:
|<pre>20 xx xx JSR @rts12
|<pre>20 xx xx JSR @rts12
00 00... BRK 0    &times; 3</pre>||Requires dummy interrupt handler, and @rts12; and writes in stack
00 00... BRK 0    &times; 3</pre>||Requires dummy interrupt handler, and @rts12; and writes in stack
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 08    LDX #8
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 08    LDX #8
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>00 00    BRK 0
|<pre>00 00    BRK 0
Line 6,444: Line 6,357:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 11</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|15 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 7
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|18 bytes
!colspan="2"|18 bytes
Line 6,598: Line 6,499:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 09    LDX #9
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>F6 F6    INC $F6,X
|<pre>F6 F6    INC $F6,X
Line 6,604: Line 6,512:
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 6,616: Line 6,518:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>18      CLC
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts12
10 FA    BPL *-4</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
|-
|-
|<pre>00 00... BRK 0    &times; 4</pre>||Requires dummy interrupt handler; and writes in stack
|<pre>00 00... BRK 0    &times; 4</pre>||Requires dummy interrupt handler; and writes in stack
Line 6,629: Line 6,526:
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|-
|<pre>68   ... PLA     &times; 2
|<pre>48   ... PHA     &times; 2
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
D0 FD    BNE *-1
18      CLC
10 FB    BPL *-3</pre>||Clobbers A, S, Z&N, and C
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A, and S; and writes in stack
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>48      PHA
48      PHA
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 08   LDX #8
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>18       CLC
|<pre>08       PHP
A9 4A   LDA #$4A ;hides 'LSR A'
8C      TXA
36 36    ROL $36,X
A2 08   LDX #8
76 36    ROR $36,X
CA       DEX
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>EA  ... NOP      &times; 3
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 6,692: Line 6,581:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>68  ... PLA      &times; 13</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|16 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /
68      PLA      \ &times; 4
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|18 bytes
!colspan="2"|18 bytes
Line 6,730: Line 6,608:
!colspan="2"|6 bytes
!colspan="2"|6 bytes
|-
|-
|<pre>18       CLC
|<pre>98       TYA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A0 88   LDY #136 ;hides 'DEY'
0A      ASL A ;first loop only
30 FD   BMI *-1
30 FC   BMI *-2</pre>||Clobbers A, Z&N, C, and V
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 6,744: Line 6,622:
88      DEY
88      DEY
10 FD    BPL *-1</pre>||Clobbers Y, and Z&N
10 FD    BPL *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9 2A    LDA #$2A ;hides 'ROL A'
00 00    BRK 0
10 FB    BPL *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
Line 6,762: Line 6,636:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>20 xx xx JSR @rts14
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 6,776: Line 6,646:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
90 FC    BCC *-2</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 6,791: Line 6,655:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|14 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 11</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|16 bytes
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 7
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|18 bytes
!colspan="2"|18 bytes
Line 6,964: Line 6,810:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>68  ... PLA      &times; 2
|<pre>8C       TXA
08       PHP
A2 07   LDX #7
A9 0A   LDA #$0A ;hides 'ASL A'
EA      NOP
D0 FD   BNE *-1
CA      DEX
28       PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
D0 FC   BNE *-2
AA       TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 7,047: Line 6,894:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>C5 C5    CMP $C5
|<pre>48      PHA
48      PHA
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 06   LDX #6
EA      NOP
EA      NOP
18       CLC
CA       DEX
10 FB   BPL *-3
D0 FC   BNE *-2
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
A5 A5    LDA $A5
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 06   LDX #6
EA      NOP
EA      NOP
18       CLC
CA       DEX
10 FB   BPL *-3
D0 FC   BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 7,079: Line 6,928:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
08      PHP
48      PHA
48      PHA
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$EA'
A2 07   LDX #7
EA       NOP ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|14 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 13</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|16 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 6
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|18 bytes
!colspan="2"|18 bytes
Line 7,149: Line 6,986:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 7,195: Line 7,038:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|14 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 12</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|16 bytes
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 11
10 F1    BPL *-13</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|19 bytes
!colspan="2"|19 bytes
Line 7,335: Line 7,165:
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>18       CLC
|<pre>48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
98       TYA
48  ... PHA      &times; 2
A0 88   LDY #136 ;hides 'DEY'
10 FB   BPL *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
30 FD   BMI *-1
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>18       CLC
|<pre>A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
98       TYA
EA  ... NOP      &times; 2
A0 88   LDY #136 ;hides 'DEY'
18      CLC
30 FD   BMI *-1
10 FA   BPL *-4</pre>||Clobbers A, Z&N, and C
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 7,403: Line 7,234:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|14 bytes
|-
|<pre>68  ... PLA      &times; 14</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|16 bytes
|-
|<pre>68      PLA      \ &times; 8
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|19 bytes
!colspan="2"|19 bytes
Line 7,460: Line 7,282:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8      TAY</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 7,469: Line 7,297:
B0 FB    BCS *-3
B0 FB    BCS *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 7,494: Line 7,329:
|-
|-
|<pre>48      PHA
|<pre>48      PHA
A9 2A   LDA #$2A ;hides 'ROL A'
8C      TXA
20 xx xx JSR @rts12
A2 09   LDX #9
10 FA   BPL *-4
CA      DEX
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 7,516: Line 7,353:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|15 bytes
!colspan="2"|20 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 12</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|17 bytes
|-
|<pre>EA      NOP
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 11
10 F1    BPL *-13</pre>||Clobbers A, and Z&N
|-
!colspan="2"|20 bytes
|-
|-
|<pre>C5 C5    CMP $C5
|<pre>C5 C5    CMP $C5
Line 7,667: Line 7,489:
10 FD    BPL *-1
10 FD    BPL *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>E6 xx    INC @zptemp
98      TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8      TAY</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>20 xx xx JSR @rts12
|<pre>20 xx xx JSR @rts12
Line 7,693: Line 7,530:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|15 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 14</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|17 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 8
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|20 bytes
!colspan="2"|20 bytes
Line 7,764: Line 7,590:
18      CLC
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
|-
|<pre>8C      TXA
A2 F8    LDX #248 ;hides 'SED'
E8      INX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, Z&N, and D
|-
|-
|<pre>A6 A6    LDX $A6
|<pre>A6 A6    LDX $A6
Line 7,798: Line 7,630:
30 FD    BMI *-1
30 FD    BMI *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
98      TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8      TAY</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>00 00    BRK 0
|<pre>00 00    BRK 0
Line 7,810: Line 7,648:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 7,820: Line 7,665:
10 FB    BPL *-3
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 7,845: Line 7,697:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 09    LDX #9
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 7,853: Line 7,714:
68      PLA
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 7,875: Line 7,729:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>08      PHP
08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
A2 08   LDX #8
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|15 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 13</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|17 bytes
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|20 bytes
!colspan="2"|20 bytes
Line 8,001: Line 7,844:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 0B    LDX #11
A2 0B    LDX #11
CA      DEX
CA      DEX
Line 8,010: Line 7,859:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 8,025: Line 7,869:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
B0 FC    BCS *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
98       TYA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A0 88   LDY #136 ;hides 'DEY'
0A      ASL A ;first loop only
30 FD   BMI *-1
30 FC   BMI *-2
A8      TAY
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
98       TYA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A0 88   LDY #136 ;hides 'DEY'
0A      ASL A ;first loop only
30 FD   BMI *-1
30 FC   BMI *-2
A8      TAY
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 8,073: Line 7,899:
10 FD    BPL *-1
10 FD    BPL *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9 2A    LDA #$2A ;hides 'ROL A'
00 00    BRK 0
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>20 xx xx JSR @rts14
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 8,098: Line 7,912:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28       PLP
48       PHA
08      PHP
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|15 bytes
|-
|<pre>68  ... PLA      &times; 15</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|18 bytes
|-
|<pre>EA  ... NOP      &times; 2
68      PLA      \ &times; 8
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|20 bytes
!colspan="2"|20 bytes
Line 8,174: Line 7,978:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 08   LDX #8
18       CLC
EA      NOP
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
CA       DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 8,248: Line 8,054:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
8C      TXA
A2 07    LDX #7
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 8,277: Line 8,094:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
C5 C5    CMP $C5
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
A2 06   LDX #6
EA      NOP
EA      NOP
18       CLC
CA       DEX
10 FB   BPL *-3
D0 FC   BNE *-2
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|16 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 13</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|18 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 7
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|21 bytes
!colspan="2"|21 bytes
Line 8,465: Line 8,269:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 8,477: Line 8,288:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 09    LDX #9
CA      DEX
10 FD    BPL *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 8,487: Line 8,306:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA       NOP
|<pre>08       PHP
48      PHA
08      PHP
08      PHP
28       PLP
18       CLC
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|16 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 15</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|18 bytes
|-
|<pre>68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 11
10 F1    BPL *-13</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|21 bytes
!colspan="2"|21 bytes
Line 8,600: Line 8,405:
28      PLP
28      PLP
10 FB    BPL *-3</pre>||Clobbers A, Z&N, and C; and writes in stack
10 FB    BPL *-3</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 F8    LDX #248 ;hides 'SED'
E8      INX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, S, Z&N, and D
|-
|<pre>48      PHA
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 4
|<pre>A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
18       CLC
A2 0B   LDX #11
D0 FC   BNE *-2</pre>||Clobbers A, Z&N, and C
CA       DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>E6 xx    INC @zptemp
|<pre>E6 xx    INC @zptemp
Line 8,641: Line 8,462:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
|<pre>48  ... PHA      &times; 2
EA      NOP ;first loop only
98      TYA
00 00... BRK 0    &times; 2
A0 88   LDY #136 ;hides 'DEY'
10 F8   BPL *-6</pre>||Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
30 FD    BMI *-1
A8      TAY
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>48      PHA
48  ... PHA      &times; 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
30 FC    BMI *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
48      PHA
08      PHP
08      PHP
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
98      TYA
0A      ASL A ;first loop only
A0 88   LDY #136 ;hides 'DEY'
30 FC   BMI *-2
30 FD   BMI *-1
28      PLP</pre>||Clobbers A, and S; and writes in stack
A8      TAY
|-
28      PLP</pre>||Clobbers A, and S; and writes in stack
|<pre>48  ... PHA      &times; 2
A9 2A    LDA #$2A ;hides 'ROL A'
00 00    BRK 0
10 FB    BPL *-3
68      PLA</pre>||Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
98       TYA
EA  ... NOP      &times; 2
A0 88   LDY #136 ;hides 'DEY'
18      CLC
30 FD   BMI *-1
10 FA   BPL *-4
A8      TAY
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
98       TYA
EA  ... NOP      &times; 2
A0 88   LDY #136 ;hides 'DEY'
18      CLC
30 FD   BMI *-1
10 FA   BPL *-4
A8      TAY
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 8,690: Line 8,500:
48      PHA
48      PHA
18      CLC
18      CLC
A9 2A   LDA #$2A ;hides 'ROL A'
A9 0A   LDA #$0A ;hides 'ASL A'
08      PHP
24 24    BIT $24
28      PLP
90 FB    BCC *-3
90 FB    BCC *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|16 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 14</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|18 bytes
|-
|<pre>68      PLA      \ &times; 9
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|22 bytes
!colspan="2"|22 bytes
Line 8,862: Line 8,660:
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 8,882: Line 8,694:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|16 bytes
|-
|<pre>68  ... PLA      &times; 16</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|19 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 11
10 F1    BPL *-13</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|22 bytes
!colspan="2"|22 bytes
Line 8,945: Line 8,743:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 0C    LDX #12
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 8,955: Line 8,759:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 8,970: Line 8,769:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
38      SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and not relocatable code
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 9,002: Line 8,785:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts15
18      CLC
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 9,021: Line 8,799:
B0 FC    BCS *-2
B0 FC    BCS *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>00 00... BRK 0    &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 9,031: Line 8,805:
D0 FC    BNE *-2
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|<pre>EA      NOP
68  ... PLA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 9,054: Line 8,822:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>26 26    ROL $26
66 26    ROR $26
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|17 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 14</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|19 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 9
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|22 bytes
!colspan="2"|22 bytes
Line 9,255: Line 9,004:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 F8    LDX #248 ;hides 'SED'
E8      INX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N, and D; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 9,262: Line 9,019:
18      CLC
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
|-
|<pre>68      PLA
48      PHA
8C      TXA
A2 F8    LDX #248 ;hides 'SED'
E8      INX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, Z&N, and D
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 9,276: Line 9,041:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 9,283: Line 9,055:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>F6 F6    INC $F6,X
48      PHA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8      TAY
68      PLA</pre>||Clobbers Z&N; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>00 00    BRK 0
|<pre>00 00    BRK 0
Line 9,293: Line 9,088:
68      PLA
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
98      TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8      TAY
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 9,305: Line 9,107:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|17 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 16</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|19 bytes
|-
|<pre>68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|22 bytes
!colspan="2"|22 bytes
Line 9,414: Line 9,202:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>18       CLC
|<pre>EA      NOP
A9 0A   LDA #$0A ;hides 'ASL A'
8C       TXA
EA  ... NOP      &times; 3
A2 0C   LDX #12
90 FA   BCC *-4</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>A6 A6    LDX $A6
|<pre>A6 A6    LDX $A6
Line 9,433: Line 9,223:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>98       TYA
|<pre>48      PHA
48       PHA
8C      TXA
A0 0B    LDY #11
A2 0B    LDX #11
88       DEY
CA      DEX
D0 FD    BNE *-1
AA       TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 9,454: Line 9,252:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 9,475: Line 9,259:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
B0 FC    BCS *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
B0 FC    BCS *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|<pre>EA      NOP
48      PHA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 9,511: Line 9,264:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
18       CLC
98       TYA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A0 88   LDY #136 ;hides 'DEY'
0A      ASL A ;first loop only
30 FD   BMI *-1
30 FC   BMI *-2
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|17 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 15</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|19 bytes
|-
|<pre>A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|23 bytes
!colspan="2"|23 bytes
Line 9,677: Line 9,417:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>E6 xx    INC @zptemp
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 09   LDX #9
85 xx    STA @zptemp
EA      NOP
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C; and requires @zptemp
CA      DEX
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 9,706: Line 9,448:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
04 04    NOP $04
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68  ... PLA      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>48       PHA
68       PLA
8C       TXA
48       PHA
A2 08   LDX #8
A9 0A   LDA #$0A ;hides 'ASL A'
EA      NOP
18       CLC
CA       DEX
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 9,748: Line 9,479:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|17 bytes
|-
|<pre>68  ... PLA      &times; 17</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|20 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 8
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|23 bytes
!colspan="2"|23 bytes
Line 9,838: Line 9,558:
28      PLP</pre>||Clobbers Y; requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Clobbers Y; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>68       PLA
68       PLA
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
85 xx    STA @zptemp
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C; and requires @zptemp
D0 FD   BNE *-1
|-
AA       TAX</pre>||Clobbers A, S, and Z&N
|<pre>EA       NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 9,860: Line 9,575:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>18      CLC
|<pre>EA  ... NOP     &times; 2
A9 2A    LDA #$2A ;hides 'ROL A'
8C       TXA
36 36    ROL $36,X
A2 0C   LDX #12
76 36    ROR $36,X
CA       DEX
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C
D0 FD   BNE *-1
|-
AA      TAX</pre>||Clobbers A, and Z&N
!colspan="2"|18 bytes
|-
|<pre>EA       NOP
68      PLA
48      PHA
68   ... PLA     &times; 15</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|20 bytes
|-
|<pre>EA       NOP
A9 09   LDA #$09 ;hides 'ORA #$EA'
EA       NOP ;first loop only
EA  ... NOP      &times; 14
10 EE   BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|24 bytes
!colspan="2"|24 bytes
Line 9,988: Line 9,689:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 10,008: Line 9,715:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 10,043: Line 9,738:
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|-
|<pre>68       PLA
|<pre>08       PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
85 xx    STA @zptemp
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires @zptemp
D0 FB    BNE *-3
|-
|<pre>08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|<pre>20 xx xx JSR @rts15
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 10,065: Line 9,749:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,077: Line 9,755:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 10,105: Line 9,777:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and not relocatable code
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,118: Line 9,784:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 10,136: Line 9,795:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>48   ... PHA     &times; 2
18      CLC
8C      TXA
A9 0A    LDA #$0A ;hides 'ASL A'
A2 0B    LDX #11
EA   ... NOP     &times; 3
CA      DEX
90 FA   BCC *-4</pre>||Clobbers A, Z&N, and C
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 0B    LDX #11
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,162: Line 9,832:
|-
|-
|<pre>48      PHA
|<pre>48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
00 00... BRK 0    &times; 2
10 F8    BPL *-6
68      PLA</pre>||Clobbers Z&N; requires dummy interrupt handler; and writes in stack
|-
|<pre>EA      NOP
48      PHA
08      PHP
08      PHP
48      PHA
48      PHA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
98      TYA
0A      ASL A ;first loop only
A0 88   LDY #136 ;hides 'DEY'
30 FC   BMI *-2
30 FD   BMI *-1
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
28      PLP</pre>||Clobbers S; and writes in stack
Line 10,182: Line 9,845:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
18       CLC
A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
98       TYA
EA  ... NOP      &times; 2
A0 88   LDY #136 ;hides 'DEY'
18      CLC
30 FD   BMI *-1
10 FA   BPL *-4
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|18 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 17</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|20 bytes
|-
|<pre>68      PLA      \ &times; 10
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|24 bytes
!colspan="2"|24 bytes
Line 10,279: Line 9,932:
B0 FA    BCS *-4
B0 FA    BCS *-4
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>8C      TXA
A2 0C    LDX #12
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,287: Line 9,947:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
!colspan="2"|10 bytes
|<pre>EA      NOP
68      PLA
8C      TXA
A2 0C    LDX #12
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|10 bytes
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,298: Line 9,966:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|18 bytes
|<pre>A5 A5   LDA $A5
|-
8C      TXA
|<pre>68      PLA
A2 09    LDX #9
48      PHA
EA      NOP
68  ... PLA      &times; 16</pre>||Clobbers A, S, and Z&N
CA      DEX
|-
D0 FC   BNE *-2
!colspan="2"|21 bytes
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>36 36   ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0   BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|24 bytes
!colspan="2"|24 bytes
Line 10,465: Line 10,126:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 10,470: Line 10,138:
CA      DEX
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
10 FB    BPL *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|<pre>48  ... PHA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 10,497: Line 10,148:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
38       SEC
8C       TXA
A9 0D   LDA #13
A2 0C   LDX #12
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>98       TYA
|<pre>08       PHP
48       PHA
8C       TXA
A0 0C    LDY #12
A2 0C    LDX #12
88       DEY
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,524: Line 10,177:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|<pre>08      PHP
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,553: Line 10,185:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>48      PHA
!colspan="2"|10 bytes
18      CLC
|-
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|<pre>08      PHP
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; writes in stack; and not relocatable code
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and not relocatable code
|-
|<pre>48      PHA
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts15
18      CLC
10 F9    BPL *-5
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
Line 10,621: Line 10,195:
68      PLA
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>00 00... BRK 0    &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 10,636: Line 10,204:
68      PLA
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
28      PLP</pre>||Clobbers S; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28      PLP
08      PHP
48      PHA
48      PHA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A5 A5    LDA $A5
0A       ASL A ;first loop only
A9 0A   LDA #$0A ;hides 'ASL A'
30 FC    BMI *-2
18       CLC
D0 FC    BNE *-2
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>A5 A5    LDA $A5
!colspan="2"|24 bytes
18      CLC
A9 2A    LDA #$2A ;hides 'ROL A'
36 36    ROL $36,X
76 36    ROR $36,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C
|-
|-
!colspan="2"|18 bytes
|<pre>36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
|-
|<pre>68  ... PLA      &times; 18</pre>||Clobbers A, S, and Z&N
!colspan="2"|36 bytes
|-
|-
!colspan="2"|21 bytes
|<pre>EA  ... NOP      &times; 36</pre>||No requirements
|-
|-
|<pre>EA      NOP
|}
68      PLA      \ &times; 10
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|24 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|36 bytes
|-
|<pre>EA  ... NOP      &times; 36</pre>||No requirements
|-
|}




Line 10,712: Line 10,254:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>18       CLC
|<pre>98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 10,785: Line 10,327:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|19 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 16</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|21 bytes
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|25 bytes
!colspan="2"|25 bytes
Line 10,951: Line 10,477:
18      CLC
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|<pre>68      PLA
8C      TXA
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 11,012: Line 10,552:
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y, and S; and writes in stack
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
|<pre>68      PLA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, S, and Z&N; requires @zptemp; and writes in stack
|-
|<pre>68      PLA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, S, and Z&N; requires support for unofficial opcodes; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>48      PHA
|<pre>EA      NOP
18       CLC
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C       TXA
EA  ... NOP      &times; 3
A2 0C   LDX #12
90 FA   BCC *-4
CA      DEX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>EA      NOP
18       CLC
08      PHP
A9 0A   LDA #$0A ;hides 'ASL A'
8C       TXA
EA  ... NOP      &times; 3
A2 0C   LDX #12
90 FA   BCC *-4
CA      DEX
D0 FD   BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 11,061: Line 10,591:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48       PHA
|<pre>08       PHP
98      TYA
48      PHA
48      PHA
A0 0B    LDY #11
8C      TXA
88       DEY
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
A8      TAY
28      PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
E6 xx    INC @zptemp
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|<pre>EA      NOP
08      PHP
48      PHA
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
48      PHA
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
28      PLP
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
30 FC    BMI *-2
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|19 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 18</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|21 bytes
|-
|<pre>68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|25 bytes
!colspan="2"|25 bytes
Line 11,160: Line 10,634:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 0E    LDX #14
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 11,180: Line 10,660:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 11,247: Line 10,709:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>E6 xx   INC @zptemp
|<pre>48      PHA
8C      TXA
A2 09   LDX #9
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
08      PHP
D0 FB    BNE *-3
28      PLP
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
10 FB    BPL *-3
|-
|<pre>EA      NOP
48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
10 FB    BPL *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|19 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 17</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|22 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 9
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|26 bytes
!colspan="2"|26 bytes
Line 11,444: Line 10,888:
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>48       PHA
48       PHA
98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 11,468: Line 10,912:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>A5 A5    LDA $A5
A5 A5    LDA $A5
98      TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C
A8      TAY</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 11,500: Line 10,944:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28       PLP
48       PHA
08      PHP
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
18      CLC
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|19 bytes
|-
|<pre>68  ... PLA      &times; 19</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|22 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|26 bytes
!colspan="2"|26 bytes
Line 11,606: Line 11,036:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 0E    LDX #14
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 11,617: Line 11,054:
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|-
|<pre>F6 F6    INC $F6,X
!colspan="2"|9 bytes
A9 0A   LDA #$0A ;hides 'ASL A'
|-
EA       NOP
|<pre>48      PHA
18      CLC
8C      TXA
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
A2 0D   LDX #13
CA       DEX
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>18       CLC
|<pre>08       PHP
A9 2A   LDA #$2A ;hides 'ROL A'
8C      TXA
20 xx xx JSR @rts14
A2 0D   LDX #13
90 FA   BCC *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
CA      DEX
D0 FD   BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
38      SEC
08      PHP
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|<pre>98      TYA
48      PHA
A0 0D    LDY #13
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY</pre>||Clobbers A, and Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 0D    LDX #13
A2 0D    LDX #13
CA      DEX
CA      DEX
Line 11,679: Line 11,094:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 11,703: Line 11,102:
68      PLA
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|<pre>20 xx xx JSR @rts15
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 11,718: Line 11,110:
68      PLA
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
00 00    BRK 0
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 11,737: Line 11,121:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|20 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 17</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|22 bytes
|-
|<pre>68      PLA      \ &times; 11
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|26 bytes
!colspan="2"|26 bytes
Line 11,923: Line 11,295:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 0E    LDX #14
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 11,941: Line 11,320:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|20 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 19</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|23 bytes
|-
|<pre>68      PLA
48      PHA
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|26 bytes
!colspan="2"|26 bytes
Line 12,069: Line 11,432:
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and not relocatable code
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and not relocatable code
|-
|-
|<pre>68   ... PLA     &times; 2
|<pre>68       PLA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA      NOP
A2 0E   LDX #14
18       CLC
CA       DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 12,091: Line 11,455:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>18      CLC
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
8C      TXA
EA  ... NOP      &times; 4
A2 0E   LDX #14
90 F9   BCC *-5</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 12,134: Line 11,500:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
98      TYA
48      PHA
48      PHA
A0 0D    LDY #13
8C      TXA
88       DEY
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 12,148: Line 11,523:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>00 00    BRK 0
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>00 00    BRK 0
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
10 FB    BPL *-3
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
18      CLC
10 FA    BPL *-4
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|<pre>48      PHA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
18      CLC
10 FA    BPL *-4
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48       PHA
|<pre>08       PHP
98      TYA
48      PHA
48      PHA
A0 0C    LDY #12
8C      TXA
88       DEY
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
A8       TAY
28       PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
!colspan="2"|27 bytes
08      PHP
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08       PHP
|<pre>EA       NOP
48      PHA
E6 xx    INC @zptemp
18      CLC
36 36   ROL $36,X \ &times; 6
A9 0A    LDA #$0A ;hides 'ASL A'
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
85 xx    STA @zptemp
D0 FB   BNE *-3
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>FE 00 02 INC $0200,X
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
38      SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|20 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 18</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|23 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 11
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|27 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 6
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
Line 12,367: Line 11,659:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 0F    LDX #15
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 12,387: Line 11,685:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>38      SEC
A9 0B    LDA #11
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 12,429: Line 11,715:
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>68      PLA
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 12,492: Line 11,764:
|-
|-
|<pre>08      PHP
|<pre>08      PHP
28      PLP
08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
38      SEC
08       PHP
A9 09   LDA #9
28      PLP
EA       NOP
10 FB   BPL *-3
E9 01    SBC #1
D0 FA   BNE *-4
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|20 bytes
|-
|<pre>68  ... PLA      &times; 20</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|23 bytes
|-
|<pre>68      PLA      \ &times; 3
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|27 bytes
!colspan="2"|27 bytes
Line 12,653: Line 11,911:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 0E    LDX #14
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 12,669: Line 11,934:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
68   ... PLA     &times; 2
68       PLA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA      NOP
A2 0E   LDX #14
18       CLC
CA       DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 12,693: Line 11,959:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>26 26    ROL $26
|<pre>EA  ... NOP      &times; 3
66 26    ROR $26
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0E   LDX #14
EA       NOP
CA       DEX
18      CLC
D0 FD   BNE *-1
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 12,709: Line 11,975:
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 0D    LDX #13
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 12,721: Line 11,996:
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>08      PHP
|<pre>EA      NOP
08      PHP
48      PHA
48      PHA
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
EA  ... NOP      &times; 3
CA      DEX
90 FA   BCC *-4
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|21 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 18</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|23 bytes
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|28 bytes
!colspan="2"|28 bytes
Line 12,889: Line 12,150:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA       NOP
|<pre>8C       TXA
38      SEC
A2 0B   LDX #11
A9 EB   LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
EA      NOP
B0 FB    BCS *-3</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
CA       DEX
|-
D0 FC   BNE *-2
|<pre>68       PLA
AA      TAX</pre>||Clobbers A, and Z&N
38      SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
38       SEC
8C       TXA
A9 0F   LDA #15
A2 0E   LDX #14
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>98       TYA
|<pre>08       PHP
48       PHA
8C       TXA
A0 0E    LDY #14
A2 0E    LDX #14
88       DEY
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 12,931: Line 12,188:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 12,944: Line 12,195:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>04 04    NOP $04
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>68  ... PLA      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
!colspan="2"|10 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 13,010: Line 12,206:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|21 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 20</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|24 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 10
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|28 bytes
!colspan="2"|28 bytes
Line 13,090: Line 12,274:
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>68       PLA
|<pre>98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
48      PHA
48      PHA
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>68       PLA
|<pre>98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
A8      TAY</pre>||Clobbers A, Z&N, and C
|-
|<pre>98      TYA
A0 88    LDY #136 ;hides 'DEY'
24 24    BIT $24
30 FB    BMI *-3
A8      TAY</pre>||Clobbers A, Z&N, and V
|-
|<pre>98      TYA
A0 88    LDY #136 ;hides 'DEY'
85 xx    STA @zptemp
85 xx    STA @zptemp
18      CLC
30 FB   BMI *-3
D0 FA   BNE *-4</pre>||Clobbers A, S, Z&N, and C; and requires @zptemp
A8      TAY</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>68       PLA
|<pre>98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
04 04    NOP $04
04 04    NOP $04
18      CLC
30 FB   BMI *-3
D0 FA   BNE *-4</pre>||Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes
A8      TAY</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>A5 A5   LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
8C       TXA
85 xx    STA @zptemp
A2 0F   LDX #15
18       CLC
CA       DEX
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
D0 FD   BNE *-1
|-
AA      TAX</pre>||Clobbers A, and Z&N
|<pre>20 xx xx JSR @rts12
A9 0A   LDA #$0A ;hides 'ASL A'
EA      NOP
18       CLC
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 13,130: Line 12,321:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|<pre>18  ... CLC      &times; 2
A9 2A    LDA #$2A ;hides 'ROL A'
EA      NOP
00 00    BRK 0
90 FA    BCC *-4</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>68  ... PLA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 13,165: Line 12,338:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>E6 xx    INC @zptemp
|<pre>E6 xx    INC @zptemp
Line 13,212: Line 12,378:
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>48  ... PHA      &times; 2
48  ... PHA      &times; 2
98      TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>48      PHA
48      PHA
08      PHP
08      PHP
A9 0A   LDA #$0A ;hides 'ASL A'
98      TYA
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
28      PLP</pre>||Clobbers A, and S; and writes in stack
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
|-
Line 13,240: Line 12,406:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|21 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 19</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|24 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 2
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|28 bytes
!colspan="2"|28 bytes
Line 13,426: Line 12,576:
18      CLC
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 4
10 F9    BPL *-5</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
|<pre>68      PLA
|<pre>68      PLA
38       SEC
8C       TXA
A9 EB   LDA #$EB ;hides 'SBC #$1A'
A2 0F   LDX #15
1A       NOP ;first loop only
CA       DEX
EA      NOP
D0 FD   BNE *-1
B0 FB   BCS *-3</pre>||Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>38      SEC
|<pre>EA  ... NOP      &times; 2
A9 09    LDA #9
8C       TXA
EA  ... NOP      &times; 2
A2 0F   LDX #15
E9 01    SBC #1
CA       DEX
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
|-
AA      TAX</pre>||Clobbers A, and Z&N
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
24 24   BIT $24
28      PLP
18      CLC
10 F8    BPL *-6</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18       CLC
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 13,507: Line 12,641:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
|<pre>68      PLA
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, S, and Z&N; requires support for unofficial opcodes; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>A9 0A   LDA #$0A ;hides 'ASL A'
|<pre>EA      NOP
EA  ... NOP      &times; 5
48      PHA
18       CLC
8C      TXA
10 F7   BPL *-7</pre>||Clobbers A, Z&N, and C
A2 0E   LDX #14
CA       DEX
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
98       TYA
08       PHP
48       PHA
8C       TXA
A0 0E    LDY #14
A2 0E    LDX #14
88       DEY
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 13,546: Line 12,676:
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|-
|<pre>F6 F6    INC $F6,X
!colspan="2"|11 bytes
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
F6 F6    INC $F6,X
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA       NOP
A2 0D   LDX #13
18      CLC
CA       DEX
D0 FB   BNE *-3
D0 FD   BNE *-1
28      PLP</pre>||Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
|-
|<pre>48      PHA
!colspan="2"|28 bytes
18      CLC
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
90 FA    BCC *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>36 36   ROL $36,X \ &times; 7
18      CLC
76 36   ROR $36,X /</pre>||Clobbers Z&N
A9 2A   LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
90 FA   BCC *-4
28      PLP</pre>||Clobbers A; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
!colspan="2"|42 bytes
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
98      TYA
48      PHA
A0 0D    LDY #13
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
98      TYA
48      PHA
A0 0D    LDY #13
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY
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
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|21 bytes
|-
|<pre>68  ... PLA      &times; 21</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|24 bytes
|-
|<pre>68      PLA      \ &times; 12
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|28 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|42 bytes
|-
|-
|<pre>EA  ... NOP      &times; 42</pre>||No requirements
|<pre>EA  ... NOP      &times; 42</pre>||No requirements
Line 13,683: Line 12,721:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA       NOP
|<pre>8C       TXA
18      CLC
A2 10   LDX #16
A9 69   LDA #$69 ;hides 'ADC #$F8'
CA       DEX
F8       SED ;first loop only
D0 FD   BNE *-1
10 FC   BPL *-2</pre>||Clobbers A, Z&N, C, V, and D
AA       TAX</pre>||Clobbers A, and Z&N
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
08      PHP
28      PLP
B0 FA    BCS *-4</pre>||Clobbers A, Z&N, C, and V; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 13,707: Line 12,739:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
38      SEC
A9 10    LDA #16
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
08      PHP
28      PLP
90 FA    BCC *-4</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>08      PHP
A2 0B    LDX #11
A2 0B    LDX #11
EA      NOP
EA      NOP
Line 13,749: Line 12,768:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
E6 xx    INC @zptemp
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 02 INC $0200,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $200-$2FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 03 INC $0300,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $300-$3FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 04 INC $0400,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $400-$4FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 05 INC $0500,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $500-$5FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 06 INC $0600,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $600-$6FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 07 INC $0700,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $700-$7FF
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 13,798: Line 12,775:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 13,816: Line 12,786:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|22 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 19</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|25 bytes
|-
|<pre>68      PLA      \ &times; 2
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|29 bytes
!colspan="2"|29 bytes
Line 13,996: Line 12,941:
|-
|-
|<pre>48      PHA
|<pre>48      PHA
68       PLA
98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
48      PHA
48      PHA
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 14,018: Line 12,963:
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>8C       TXA
38       SEC
A2 09   LDX #9
A9 10   LDA #16
EA  ... NOP      &times; 2
E9 01    SBC #1
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 14,045: Line 12,991:
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|-
|<pre>68       PLA
|<pre>08       PHP
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9      LDA #45
85 xx    STA @zptemp
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #45
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
68      PLA
68      PLA
Line 14,065: Line 13,004:
D0 FA    BNE *-4
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 14,083: Line 13,015:
10 F9    BPL *-5
10 F9    BPL *-5
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and not relocatable code
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>18      CLC
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 5
18      CLC
10 F7    BPL *-7</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
48      PHA
48      PHA
98       TYA
8C       TXA
48      PHA
A2 0E   LDX #14
A0 0D   LDY #13
CA       DEX
88       DEY
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>00 00    BRK 0
!colspan="2"|12 bytes
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
10 FB    BPL *-3
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48       PHA
|<pre>EA       NOP
08      PHP
08      PHP
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
8C       TXA
08      PHP
A2 0D    LDX #13
28      PLP
CA      DEX
18      CLC
D0 FD   BNE *-1
10 FA    BPL *-4
AA      TAX
68       PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
38      SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB   BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|22 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 21</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|25 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 12
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|29 bytes
!colspan="2"|29 bytes
Line 14,231: Line 13,107:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>08      PHP
|<pre>EA      NOP
A2 88    LDX #136 ;hides 'DEY'
8C      TXA
A2 10    LDX #16
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A2 88    LDX #136 ;hides 'DEY'
EA      NOP
EA      NOP
CA      DEX
CA      DEX
Line 14,240: Line 13,123:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>98       TYA
|<pre>48      PHA
48       PHA
8C      TXA
A0 0F    LDY #15
A2 0F    LDX #15
88       DEY
CA      DEX
D0 FD    BNE *-1
AA       TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 14,268: Line 13,159:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>48      PHA
38      SEC
A9 0B    LDA #11
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 0B    LDA #11
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 14,316: Line 13,175:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
18       CLC
98       TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|22 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 20</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|25 bytes
|-
|<pre>68      PLA      \ &times; 4
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|30 bytes
!colspan="2"|30 bytes
Line 14,485: Line 13,329:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>68       PLA
|<pre>48       PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
20 xx xx JSR @rts12
A2 10   LDX #16
10 FA   BPL *-4</pre>||Clobbers A, S, Z&N, and C; requires @rts12; and writes in stack
CA      DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 10    LDX #16
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 14,505: Line 13,358:
90 FA    BCC *-4
90 FA    BCC *-4
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4</pre>||Clobbers A, Z&N, and C; requires @rts12; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 14,531: Line 13,379:
30 FA    BMI *-4
30 FA    BMI *-4
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 14,563: Line 13,405:
D0 FA    BNE *-4
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 14,586: Line 13,420:
D0 FA    BNE *-4
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires support for unofficial opcodes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 14,615: Line 13,441:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>48       PHA
68       PLA
8C       TXA
48      PHA
A2 0E   LDX #14
A9 0A   LDA #$0A ;hides 'ASL A'
CA       DEX
4C xx xx JMP *+3
D0 FD   BNE *-1
18       CLC
F6 xx   INC @zptemp,X
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, and C; and not relocatable code
AA       TAX
|-
68       PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|<pre>A5 A5    LDA $A5
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 02 INC $0200,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $200-$2FF
|-
|<pre>A5 A5    LDA $A5
18      CLC
A9 0A   LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 03 INC $0300,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $300-$3FF
|-
|<pre>A5 A5    LDA $A5
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
FE 00 04 INC $0400,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $400-$4FF
|-
|<pre>A5 A5    LDA $A5
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 05 INC $0500,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $500-$5FF
|-
|<pre>A5 A5    LDA $A5
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 06 INC $0600,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $600-$6FF
|-
|<pre>A5 A5    LDA $A5
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
FE 00 07 INC $0700,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; and requires writable $700-$7FF
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 14,674: Line 13,459:
68      PLA
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
28      PLP</pre>||Clobbers S; and writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 14,696: Line 13,472:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
|<pre>68      PLA
!colspan="2"|30 bytes
48      PHA
|-
26 26    ROL $26
|<pre>26 26    ROL $26
66 26    ROR $26
66 26    ROR $26
A9 0A   LDA #$0A ;hides 'ASL A'
36 36   ROL $36,X \ &times; 2
EA      NOP
76 36    ROR $36,X /
18      CLC
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C
|-
|-
!colspan="2"|22 bytes
!colspan="2"|44 bytes
|-
|<pre>68  ... PLA      &times; 22</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|25 bytes
|-
|<pre>68      PLA      \ &times; 3
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
!colspan="2"|30 bytes
|-
|<pre>26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 2
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|44 bytes
|-
|-
|<pre>EA  ... NOP      &times; 44</pre>||No requirements
|<pre>EA  ... NOP      &times; 44</pre>||No requirements
Line 14,793: Line 13,547:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>18       CLC
|<pre>8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
EA   ... NOP     &times; 2
EA       NOP
18       CLC
CA       DEX
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 14,824: Line 13,579:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>98       TYA
|<pre>48       PHA
48       PHA
8C       TXA
A0 0B    LDY #11
A2 0B    LDX #11
EA      NOP
EA      NOP
88       DEY
CA       DEX
D0 FC    BNE *-2
D0 FC    BNE *-2
68      PLA
AA      TAX
A8      TAY</pre>||Clobbers A, and Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>08       PHP
48       PHA
8C       TXA
38      SEC
A2 0B   LDX #11
A9 EB   LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
EA      NOP
B0 FB   BCS *-3
CA      DEX
68       PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
D0 FC   BNE *-2
AA      TAX
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA      NOP
!colspan="2"|11 bytes
08      PHP
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|-
|<pre>48   ... PHA     &times; 2
|<pre>08      PHP
A9 0A   LDA #$0A ;hides 'ASL A'
48       PHA
B8       CLV
8C      TXA
50 00    BVC *+2
A2 0E   LDX #14
D0 FA   BNE *-4
CA       DEX
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
D0 FD   BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
|-
|<pre>48      PHA
!colspan="2"|30 bytes
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
B8      CLV
50 00    BVC *+2
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
36 36    ROL $36,X \ &times; 7
85 xx    STA @zptemp
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
18      CLC
D0 FA    BNE *-4
68      PLA</pre>||Clobbers S, Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4
68      PLA</pre>||Clobbers S, Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
98      TYA
48      PHA
A0 0E    LDY #14
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
38      SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA      NOP
08      PHP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|23 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 20</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|26 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 11
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|30 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|-
!colspan="2"|31 bytes
!colspan="2"|31 bytes
Line 15,053: Line 13,726:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA       NOP
|<pre>8C       TXA
38      SEC
A2 11   LDX #17
A9 69   LDA #$69 ;hides 'ADC #$F8'
CA       DEX
F8       SED ;first loop only
D0 FD   BNE *-1
10 FC   BPL *-2</pre>||Clobbers A, Z&N, C, V, and D
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 15,078: Line 13,751:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
Line 15,092: Line 13,760:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
|-
|<pre>EA      NOP
38      SEC
A9 11    LDA #17
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,128: Line 13,790:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,142: Line 13,798:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|10 bytes
|-
|<pre>48      PHA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
A8      TAY
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>48      PHA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
24 24    BIT $24
30 FB    BMI *-3
A8      TAY
68      PLA</pre>||Clobbers Z&N, and V; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
48      PHA
98      TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
85 xx    STA @zptemp
85 xx    STA @zptemp
18       CLC
30 FB    BMI *-3
D0 FA   BNE *-4
A8       TAY
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>48      PHA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
04 04   NOP $04
30 FB    BMI *-3
A8      TAY
68      PLA</pre>||Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
|-
|-
|<pre>20 xx xx JSR @rts12
|<pre>48  ... PHA      &times; 2
48       PHA
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0F   LDX #15
EA      NOP
CA       DEX
18       CLC
D0 FD   BNE *-1
D0 FB   BNE *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
!colspan="2"|11 bytes
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18      CLC
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18  ... CLC      &times; 2
A5 A5   LDA $A5
A9 2A   LDA #$2A ;hides 'ROL A'
8C       TXA
EA       NOP
A2 0F   LDX #15
00 00   BRK 0
CA      DEX
90 FA   BCC *-4
D0 FD   BNE *-1
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 15,187: Line 13,862:
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,217: Line 13,883:
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>48      PHA
48      PHA
08      PHP
08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
98      TYA
A0 88   LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
28      PLP</pre>||Clobbers S; and writes in stack
Line 15,230: Line 13,896:
!colspan="2"|13 bytes
!colspan="2"|13 bytes
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
08      PHP
C5 C5    CMP $C5
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
A5 A5   LDA $A5
98      TYA
A0 88    LDY #136 ;hides 'DEY'
EA      NOP
EA      NOP
18      CLC
30 FC   BMI *-2
D0 FB   BNE *-3
A8      TAY
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|23 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 22</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|26 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 3
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|30 bytes
!colspan="2"|30 bytes
Line 15,335: Line 13,986:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>18       CLC
|<pre>EA       NOP
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
26 26    ROL $26
A2 0C   LDX #12
66 26    ROR $26
EA      NOP
90 F9   BCC *-5</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,407: Line 14,060:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
98      TYA
48      PHA
A0 0F    LDY #15
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 15,434: Line 14,078:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48      PHA
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
48      PHA
08       PHP
8C       TXA
24 24   BIT $24
A2 0F   LDX #15
28      PLP
CA       DEX
18       CLC
D0 FD   BNE *-1
10 F8   BPL *-6
AA      TAX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,454: Line 14,098:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
08      PHP
48      PHA
48      PHA
98       TYA
8C       TXA
48      PHA
A2 0E    LDX #14
A0 0E    LDY #14
CA       DEX
88       DEY
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
A8       TAY
28       PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|31 bytes
|-
|-
|<pre>08       PHP
|<pre>EA       NOP
F6 F6   INC $F6,X
E6 xx   INC @zptemp
48      PHA
36 36    ROL $36,X \ &times; 7
A9 0A   LDA #$0A ;hides 'ASL A'
76 36   ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>FE 00 02 INC $0200,X
48      PHA
36 36   ROL $36,X \ &times; 7
18      CLC
76 36   ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
A9 2A   LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
90 FA   BCC *-4
68      PLA
28      PLP</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>FE 00 03 INC $0300,X
08      PHP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
18      CLC
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>08      PHP
48      PHA
98      TYA
48      PHA
A0 0D    LDY #13
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|23 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 21</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|26 bytes
|-
|<pre>68      PLA      \ &times; 13
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|31 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 7
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
Line 15,665: Line 14,245:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA   ... NOP     &times; 2
|<pre>EA       NOP
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 11   LDX #17
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2</pre>||Clobbers A, Z&N, C, V, and D
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,685: Line 14,266:
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$2A'
!colspan="2"|9 bytes
2A      ROL A ;first loop only
EA      NOP
F6 F6    INC $F6,X
B0 F9    BCS *-5</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>A9 2A   LDA #$2A ;hides 'ROL A'
|<pre>48      PHA
00 00... BRK 0    &times; 2
8C      TXA
10 F9   BPL *-5</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
A2 10   LDX #16
CA      DEX
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>68       PLA
|<pre>08       PHP
38       SEC
8C       TXA
A9 11   LDA #17
A2 10   LDX #16
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>08       PHP
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9      LDA #51
48  ... PHA      &times; 2
20 xx xx JSR delay_a_25_clocks
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
08      PHP
28      PLP
B0 FA    BCS *-4
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
38      SEC
A9 11    LDA #17
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>EA      NOP
08      PHP
18      CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
10 FC    BPL *-2
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #51
20 xx xx JSR delay_a_25_clocks
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
08      PHP
28      PLP
90 FA    BCC *-4
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA      NOP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 15,772: Line 14,301:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|23 bytes
|-
|<pre>68  ... PLA      &times; 23</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|27 bytes
|-
|<pre>68      PLA      \ &times; 3
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|31 bytes
!colspan="2"|31 bytes
Line 15,857: Line 14,371:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>98      TYA
A9 0A   LDA #$0A ;hides 'ASL A'
A0 88   LDY #136 ;hides 'DEY'
00 00    BRK 0
EA   ... NOP     &times; 2
10 FB    BPL *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
30 FB    BMI *-3
|-
A8      TAY</pre>||Clobbers A, and Z&N
|<pre>48   ... PHA     &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,888: Line 14,392:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers S, Z&N, C, V, and D; and writes in stack
68      PLA</pre>||Clobbers S, Z&N, C, V, and D; and writes in stack
|-
|<pre>EA      NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 15,913: Line 14,410:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
|-
|<pre>18  ... CLC      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
26 26    ROL $26
66 26    ROR $26
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 15,961: Line 14,452:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|24 bytes
!colspan="2"|32 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 21</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|27 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 13
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|32 bytes
|-
|-
|<pre>C5 C5    CMP $C5
|<pre>C5 C5    CMP $C5
Line 16,120: Line 14,598:
28      PLP      /
28      PLP      /
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 11    LDX #17
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 16,130: Line 14,615:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
|<pre>68      PLA
|<pre>EA  ... NOP      &times; 2
48      PHA
8C       TXA
A9 0A    LDA #$0A ;hides 'ASL A'
A2 11    LDX #17
EA  ... NOP      &times; 2
CA      DEX
18       CLC
D0 FD   BNE *-1
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 16,167: Line 14,652:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>48       PHA
|<pre>EA       NOP
98      TYA
48      PHA
48      PHA
A0 0F   LDY #15
8C      TXA
88       DEY
A2 10   LDX #16
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
!colspan="2"|11 bytes
48      PHA
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|12 bytes
|-
|-
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
38       SEC
8C       TXA
A9 0B   LDA #11
A2 0F   LDX #15
EA       NOP
CA       DEX
E9 01    SBC #1
D0 FD   BNE *-1
D0 FA   BNE *-4
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|24 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 23</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|27 bytes
|-
|<pre>68      PLA      \ &times; 5
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|32 bytes
!colspan="2"|32 bytes
Line 16,254: Line 14,714:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 16,283: Line 14,749:
10 FC    BPL *-2
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 16,326: Line 14,786:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 10    LDX #16
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>08      PHP
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 10    LDX #16
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
48      PHA
48      PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
A9 69    LDA #$69 ;hides 'ADC #$18'
Line 16,337: Line 14,816:
68      PLA
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 16,353: Line 14,825:
68      PLA
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
08      PHP
28      PLP
90 FA    BCC *-4
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 16,374: Line 14,837:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|24 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 22</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|27 bytes
|-
|<pre>68      PLA      \ &times; 4
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|32 bytes
!colspan="2"|32 bytes
Line 16,524: Line 14,972:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 0D    LDX #13
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 16,537: Line 14,992:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and X; and writes in stack
28      PLP</pre>||Clobbers A, and X; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 16,554: Line 15,004:
10 FB    BPL *-3
10 FB    BPL *-3
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>68  ... PLA      &times; 2
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
10 FC    BPL *-2</pre>||Clobbers A, S, Z&N, C, V, and D
|-
|<pre>48      PHA
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 16,575: Line 15,013:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 16,619: Line 15,045:
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
EA   ... NOP     &times; 2
EA       NOP
18       CLC
CA       DEX
D0 FA   BNE *-4
D0 FC   BNE *-2
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
AA      TAX
|-
68      PLA</pre>||Clobbers Z&N; and writes in stack
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
EA   ... NOP     &times; 2
EA       NOP
18       CLC
CA       DEX
D0 FA   BNE *-4
D0 FC   BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>48       PHA
|<pre>08       PHP
98      TYA
48      PHA
48      PHA
A0 0B    LDY #11
8C      TXA
A2 0B    LDX #11
EA      NOP
EA      NOP
88       DEY
CA       DEX
D0 FC    BNE *-2
D0 FC    BNE *-2
68       PLA
AA       TAX
A8      TAY
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
48      PHA
38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA      NOP
B0 FB    BCS *-3
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
B8      CLV
50 00    BVC *+2
D0 FA    BNE *-4
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
38      SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|24 bytes
|-
|<pre>68  ... PLA      &times; 24</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|28 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 12
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|32 bytes
!colspan="2"|32 bytes
Line 16,816: Line 15,192:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 16,827: Line 15,210:
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$18'
!colspan="2"|9 bytes
18      CLC ;first loop only
EA      NOP
E6 xx    INC @zptemp
90 F9    BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp
|-
|-
|<pre>A9 69   LDA #$69 ;hides 'ADC #$18'
|<pre>48      PHA
18       CLC ;first loop only
8C      TXA
FE 00 02 INC $0200,X
A2 11   LDX #17
90 F9   BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $200-$2FF
CA       DEX
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>A9 69   LDA #$69 ;hides 'ADC #$18'
|<pre>08      PHP
18       CLC ;first loop only
8C      TXA
FE 00 03 INC $0300,X
A2 11   LDX #17
90 F9   BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $300-$3FF
CA       DEX
D0 FD   BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$18'
|<pre>EA  ... NOP      &times; 2
18      CLC ;first loop only
08      PHP
FE 00 04 INC $0400,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $400-$4FF
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$18'
18      CLC ;first loop only
FE 00 05 INC $0500,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $500-$5FF
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$18'
18      CLC ;first loop only
FE 00 06 INC $0600,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $600-$6FF
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$18'
18      CLC ;first loop only
FE 00 07 INC $0700,X
90 F9    BCC *-5</pre>||Clobbers A, Z&N, C, and V; and requires writable $700-$7FF
|-
|<pre>68      PLA
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
!colspan="2"|9 bytes
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
10 FC    BPL *-2
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
10 FC    BPL *-2
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 11    LDX #17
A2 11    LDX #17
CA      DEX
CA      DEX
Line 16,925: Line 15,259:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|25 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 22</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|28 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 4
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|33 bytes
!colspan="2"|33 bytes
Line 17,029: Line 15,346:
|<pre>04 04    NOP $04
|<pre>04 04    NOP $04
EA  ... NOP      &times; 47</pre>||Requires support for unofficial opcodes
EA  ... NOP      &times; 47</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|50 bytes
|-
|<pre>EA  ... NOP      &times; 47
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 17,094: Line 15,416:
28      PLP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and writes in stack
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 17,103: Line 15,432:
30 FA    BMI *-4
30 FA    BMI *-4
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 17,124: Line 15,460:
10 FB    BPL *-3
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48       PHA
|<pre>EA       NOP
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
26 26    ROL $26
66 26    ROR $26
90 F9    BCC *-5
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>08      PHP
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
8C      TXA
A2 0C    LDX #12
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
20 xx xx JSR @rts12
10 FA    BPL *-4
10 FA    BPL *-4
Line 17,188: Line 15,517:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
38      SEC
08      PHP
A9 09   LDA #9
24 24   BIT $24
EA  ... NOP      &times; 2
28      PLP
E9 01   SBC #1
18      CLC
D0 F9   BNE *-5
10 F8   BPL *-6
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|25 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 24</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|28 bytes
|-
|<pre>68      PLA      \ &times; 14
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|33 bytes
!colspan="2"|33 bytes
Line 17,287: Line 15,605:
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>38       SEC
|<pre>EA  ... NOP      &times; 2
A9 0C   LDA #12
8C       TXA
24 24    BIT $24
A2 12   LDX #18
E9 01    SBC #1
CA      DEX
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 17,302: Line 15,628:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, S, Z&N, and C
|-
|<pre>68      PLA
08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
10 FC    BPL *-2
28      PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 17,333: Line 15,644:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>EA   ... NOP     &times; 2
|<pre>EA       NOP
48      PHA
48      PHA
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 11   LDX #17
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA   ... NOP      &times; 2
|<pre>EA      NOP
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18       CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>EA  ... NOP     &times; 2
08      PHP
08      PHP
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 11   LDX #17
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>48      PHA
!colspan="2"|11 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
EA      NOP
F6 F6    INC $F6,X
B0 F9    BCS *-5
68      PLA</pre>||Clobbers Z&N, C, and V; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>08      PHP
A9 2A    LDA #$2A ;hides 'ROL A'
00 00... BRK 0    &times; 2
10 F9    BPL *-5
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
48      PHA
18       CLC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 10   LDX #16
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|25 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 23</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|29 bytes
|-
|<pre>68      PLA      \ &times; 4
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|34 bytes
!colspan="2"|34 bytes
Line 17,475: Line 15,750:
|<pre>B8  ... CLV      &times; 48
|<pre>B8  ... CLV      &times; 48
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 48
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 48
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|51 bytes
|-
|<pre>EA  ... NOP      &times; 48
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 17,499: Line 15,785:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 13    LDX #19
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 17,521: Line 15,813:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 17,541: Line 15,827:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>EA      NOP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 17,580: Line 15,853:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>E6 xx    INC @zptemp
|<pre>48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
98      TYA
18      CLC
A0 88   LDY #136 ;hides 'DEY'
90 00    BCC *+2
EA  ... NOP      &times; 2
18      CLC
30 FB    BMI *-3
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and requires @zptemp
A8      TAY
|-
68      PLA</pre>||Clobbers Z&N; and writes in stack
|<pre>EA  ... NOP      &times; 2
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|<pre>EA      NOP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>F6 F6    INC $F6,X
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 2
18      CLC
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 17,633: Line 15,884:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|25 bytes
|-
|<pre>68  ... PLA      &times; 25</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|29 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 14
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|34 bytes
!colspan="2"|34 bytes
Line 17,723: Line 15,964:
10 FA    BPL *-4</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
10 FA    BPL *-4</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
08       PHP
48       PHA
28       PLP
CA       DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, and C; and writes in stack
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 17,745: Line 15,987:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C    LDX #12
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, Z&N, and C
|-
|<pre>8C      TXA
A2 0C   LDX #12
24 24    BIT $24
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, Z&N, and V
|-
|<pre>8C      TXA
A2 08    LDX #8
08      PHP
08      PHP
28      PLP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; and writes in stack
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 17,764: Line 16,022:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 0C    LDX #12
85 xx    STA @zptemp
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 17,783: Line 16,048:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>8C      TXA
A2 0C    LDX #12
04 04    NOP $04
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 17,792: Line 16,072:
10 F9    BPL *-5
10 F9    BPL *-5
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 17,800: Line 16,087:
D0 FA    BNE *-4
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
|-
|<pre>EA      NOP
68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 17,826: Line 16,098:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA  ... NOP      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|26 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 23</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|29 bytes
|-
|<pre>68      PLA      \ &times; 6
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|34 bytes
!colspan="2"|34 bytes
Line 17,931: Line 16,180:
|<pre>B8  ... CLV      &times; 49
|<pre>B8  ... CLV      &times; 49
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 49
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 49
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|52 bytes
|-
|<pre>EA  ... NOP      &times; 49
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 17,994: Line 16,254:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA      NOP
8C      TXA
A2 13    LDX #19
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 18,013: Line 16,280:
88      DEY
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
|<pre>38      SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A      NOP ;first loop only
EA  ... NOP      &times; 2
B0 FA    BCS *-4</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>68      PLA
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
38       SEC
8C       TXA
A9 13   LDA #19
A2 12   LDX #18
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 18,065: Line 16,322:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|26 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 25</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|29 bytes
|-
|<pre>68      PLA      \ &times; 5
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|34 bytes
!colspan="2"|34 bytes
Line 18,161: Line 16,396:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>A9 0A   LDA #$0A ;hides 'ASL A'
|<pre>8C      TXA
EA   ... NOP     &times; 3
A2 0E   LDX #14
18       CLC
EA       NOP
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, and C
CA       DEX
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 18,177: Line 16,414:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>8C      TXA
|<pre>48      PHA
48      PHA
8C      TXA
A2 0D    LDX #13
A2 0D    LDX #13
EA      NOP
EA      NOP
CA      DEX
CA      DEX
D0 FC    BNE *-2
D0 FC    BNE *-2
68      PLA
AA      TAX
AA      TAX</pre>||Clobbers A, and Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0D   LDX #13
20 xx xx JSR @rts14
EA      NOP
10 FA   BPL *-4
CA      DEX
28      PLP</pre>||Clobbers A; requires @rts12, and @rts14; and writes in stack
D0 FC   BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 18,208: Line 16,440:
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
!colspan="2"|11 bytes
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>08      PHP
08      PHP
48      PHA
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
10 F9    BPL *-5
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>08      PHP
A5 A5    LDA $A5
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
A9 69    LDA #$69 ;hides 'ADC #$18'
18      CLC ;first loop only
18      CLC ;first loop only
Line 18,254: Line 16,455:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 0C   LDX #12
EA   ... NOP     &times; 2
EA       NOP
18       CLC
CA       DEX
D0 FA   BNE *-4
D0 FC   BNE *-2
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|26 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 24</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|30 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 13
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|35 bytes
!colspan="2"|35 bytes
Line 18,353: Line 16,542:
|<pre>B8  ... CLV      &times; 50
|<pre>B8  ... CLV      &times; 50
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 50
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 50
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|53 bytes
|-
|<pre>EA  ... NOP      &times; 50
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 18,420: Line 16,620:
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
|-
|-
|<pre>48       PHA
|<pre>68       PLA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
8C      TXA
0A      ASL A ;first loop only
A2 13   LDX #19
EA      NOP
CA       DEX
48       PHA
D0 FD   BNE *-1
30 FA   BMI *-4</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 18,436: Line 16,636:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 13    LDX #19
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 18,458: Line 16,665:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 18,472: Line 16,673:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>04 04    NOP $04
!colspan="2"|10 bytes
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A      NOP ;first loop only
EA      NOP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
68       PLA
48       PHA
38       SEC
8C       TXA
A9 13   LDA #19
A2 12   LDX #18
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
D0 FD   BNE *-1
|-
AA       TAX
!colspan="2"|10 bytes
68       PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>A5 A5    LDA $A5
38       SEC
A9 0E    LDA #14
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
08      PHP
48      PHA
48      PHA
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 11   LDX #17
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18      CLC
90 00    BCC *+2
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|26 bytes
|-
|<pre>68  ... PLA      &times; 26</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|30 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 5
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|35 bytes
!colspan="2"|35 bytes
Line 18,574: Line 16,740:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 18,594: Line 16,766:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
18      CLC
A9 69    LDA #$69 ;hides 'ADC #$08'
08      PHP ;first loop only
90 FC    BCC *-2</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 18,622: Line 16,782:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 18,637: Line 16,791:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 18,674: Line 16,822:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 18,685: Line 16,841:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|27 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 24</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|30 bytes
|-
|<pre>68      PLA      \ &times; 15
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|36 bytes
!colspan="2"|36 bytes
Line 18,772: Line 16,916:
|<pre>B8  ... CLV      &times; 51
|<pre>B8  ... CLV      &times; 51
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 51
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 51
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|54 bytes
|-
|<pre>EA  ... NOP      &times; 51
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 18,839: Line 16,994:
E9 01    SBC #1
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>8C      TXA
A2 13    LDX #19
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 18,879: Line 17,041:
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>68      PLA
|<pre>EA      NOP
08       PHP
68      PLA
A9 0A   LDA #$0A ;hides 'ASL A'
8C       TXA
08      PHP
A2 13   LDX #19
28       PLP
CA       DEX
D0 FB   BNE *-3
D0 FD   BNE *-1
28       PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
AA       TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 18,898: Line 17,060:
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>A5 A5    LDA $A5
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA   ... NOP     &times; 3
A2 0E   LDX #14
18       CLC
EA       NOP
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, and C
CA       DEX
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 18,912: Line 17,076:
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 12    LDX #18
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 18,924: Line 17,097:
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>EA   ... NOP     &times; 2
|<pre>EA       NOP
08      PHP
08      PHP
48      PHA
48      PHA
38       SEC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 11   LDX #17
F8       SED ;first loop only
CA       DEX
10 FC   BPL *-2
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|27 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 26</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|31 bytes
|-
|<pre>68      PLA      \ &times; 5
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|36 bytes
!colspan="2"|36 bytes
Line 19,001: Line 17,159:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>68       PLA
|<pre>EA       NOP
38       SEC
8C       TXA
A9 14    LDA #20
A2 14    LDX #20
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
D0 FD   BNE *-1
|-
AA       TAX</pre>||Clobbers A, and Z&N
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
18       CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>38       SEC
|<pre>48       PHA
A9 0D   LDA #13
8C      TXA
24 24    BIT $24
A2 13   LDX #19
E9 01    SBC #1
CA      DEX
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>98       TYA
|<pre>08       PHP
48       PHA
8C       TXA
A0 13    LDY #19
A2 13    LDX #19
88       DEY
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 19,050: Line 17,205:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
|<pre>68      PLA
!colspan="2"|11 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|10 bytes
|<pre>08      PHP
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|<pre>EA      NOP
48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
48      PHA
38      SEC
38      SEC
Line 19,106: Line 17,215:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|27 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 25</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|31 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 15
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|36 bytes
!colspan="2"|36 bytes
Line 19,210: Line 17,307:
|<pre>B8  ... CLV      &times; 52
|<pre>B8  ... CLV      &times; 52
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 52
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 52
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|55 bytes
|-
|<pre>EA  ... NOP      &times; 52
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 19,269: Line 17,377:
28      PLP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 19,294: Line 17,416:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>EA      NOP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
Line 19,319: Line 17,434:
D0 FA    BNE *-4
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>F6 F6    INC $F6,X
|<pre>F6 F6    INC $F6,X
Line 19,358: Line 17,467:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>48      PHA
48      PHA
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 08   LDX #8
08      PHP
08      PHP
28      PLP
28      PLP
CA      DEX
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|<pre>08      PHP
48      PHA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
Line 19,385: Line 17,489:
|<pre>08      PHP
|<pre>08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
38      SEC
08      PHP       \ &times; 2
A9 0D   LDA #13
28      PLP      /
EA       NOP
10 F9   BPL *-5
E9 01    SBC #1
D0 FA   BNE *-4
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|27 bytes
|-
|<pre>68  ... PLA      &times; 27</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|31 bytes
|-
|<pre>68      PLA      \ &times; 7
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|36 bytes
!colspan="2"|36 bytes
Line 19,496: Line 17,588:
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|-
|<pre>A9 0A   LDA #$0A ;hides 'ASL A'
|<pre>68      PLA
48       PHA
8C      TXA
20 xx xx JSR @rts14
A2 14   LDX #20
10 F9   BPL *-5</pre>||Clobbers A, S, Z&N, and C; requires @rts12, and @rts14; and writes in stack
CA       DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 19,509: Line 17,610:
F6 xx    INC @zptemp,X
F6 xx    INC @zptemp,X
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
F6 F6    INC $F6,X
28      PLP
90 F9    BCC *-5</pre>||Clobbers A, Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 19,529: Line 17,617:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
28      PLP</pre>||Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>20 xx xx JSR @rts14
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 19,542: Line 17,624:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|<pre>48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
48  ... PHA      &times; 2
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 19,580: Line 17,649:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|37 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
38      SEC
A9 0D    LDA #13
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
E6 xx    INC @zptemp
E6 xx    INC @zptemp
F6 F6   INC $F6,X
36 36   ROL $36,X \ &times; 4
90 F8   BCC *-6</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
76 36   ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|-
|<pre>EA      NOP
|<pre>FE 00 02 INC $0200,X
68      PLA
36 36    ROL $36,X \ &times; 4
A9 0A   LDA #$0A ;hides 'ASL A'
76 36   ROR $36,X /
EA  ... NOP      &times; 3
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|11 bytes
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 4
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>FE 00 04 INC $0400,X
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|28 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 25</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|31 bytes
|-
|<pre>68      PLA      \ &times; 6
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
!colspan="2"|37 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 4
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 4
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 4
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 4
36 36    ROL $36,X \ &times; 4
76 36    ROR $36,X /
76 36    ROR $36,X /
Line 19,706: Line 17,730:
|<pre>B8  ... CLV      &times; 53
|<pre>B8  ... CLV      &times; 53
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 53
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 53
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|56 bytes
|-
|<pre>EA  ... NOP      &times; 53
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 19,730: Line 17,765:
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 19,750: Line 17,791:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08      PHP ;first loop only
EA      NOP
30 FB    BMI *-3</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 19,805: Line 17,834:
|-
|-
|<pre>48      PHA
|<pre>48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA   ... NOP     &times; 3
A2 0E   LDX #14
18       CLC
EA       NOP
D0 F9   BNE *-5
CA       DEX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
D0 FC   BNE *-2
|-
AA      TAX
|<pre>68      PLA
68      PLA</pre>||Clobbers Z&N; and writes in stack
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>48      PHA
|<pre>08      PHP
48      PHA
8C      TXA
8C      TXA
48      PHA
A2 0D    LDX #13
A2 0D    LDX #13
EA      NOP
EA      NOP
CA      DEX
CA      DEX
D0 FC    BNE *-2
D0 FC    BNE *-2
AA      TAX
68      PLA
68      PLA
AA       TAX
28       PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
!colspan="2"|37 bytes
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68      PLA
28      PLP</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|<pre>08      PHP
28      PLP
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
38      SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>08      PHP
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
10 F9    BPL *-5
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|28 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 27</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|32 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 14
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|37 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
Line 19,932: Line 17,903:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 18    LDX #24 ;hides 'CLC'
CA  ... DEX      &times; 2
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 19,948: Line 17,925:
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
18  ... CLC      &times; 2
90 00    BCC *+2
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,019: Line 17,990:
10 F9    BPL *-5
10 F9    BPL *-5
28      PLP</pre>||Clobbers A; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
|-
|<pre>68      PLA
98      TYA
48      PHA
A0 13    LDY #19
88      DEY
D0 FD    BNE *-1
68      PLA
A8      TAY</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 20,057: Line 18,019:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|28 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 26</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|32 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 6
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|38 bytes
!colspan="2"|38 bytes
Line 20,150: Line 18,096:
|<pre>B8  ... CLV      &times; 54
|<pre>B8  ... CLV      &times; 54
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 54
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 54
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|57 bytes
|-
|<pre>EA  ... NOP      &times; 54
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 20,206: Line 18,163:
|-
|-
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 20,217: Line 18,181:
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|-
|<pre>68      PLA
!colspan="2"|9 bytes
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 14   LDX #20
00 00    BRK 0
CA      DEX
90 FB   BCC *-3</pre>||Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
|<pre>08       PHP
|-
8C      TXA
|<pre>EA  ... NOP      &times; 2
38       SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>8C      TXA
48      PHA
A2 14    LDX #20
A2 14    LDX #20
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
AA       TAX</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,265: Line 18,219:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 20,294: Line 18,230:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA      NOP
68      PLA
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 3
18      CLC
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|28 bytes
|-
|<pre>68  ... PLA      &times; 28</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|32 bytes
|-
|<pre>68      PLA      \ &times; 16
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|38 bytes
!colspan="2"|38 bytes
Line 20,383: Line 18,302:
18      CLC
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and writes in stack
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>98      TYA
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
A8      TAY</pre>||Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|<pre>48      PHA
8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,394: Line 18,333:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18  ... CLC      &times; 2
90 00    BCC *+2
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 20,434: Line 18,366:
D0 FB    BNE *-3
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 13    LDX #19
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,460: Line 18,401:
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 3
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA  ... NOP      &times; 3
A2 13   LDX #19
18       CLC
CA       DEX
D0 F9   BNE *-5
D0 FD   BNE *-1
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 20,478: Line 18,420:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|29 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 26</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|33 bytes
|-
|<pre>68      PLA      \ &times; 6
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|38 bytes
!colspan="2"|38 bytes
Line 20,578: Line 18,502:
|<pre>B8  ... CLV      &times; 55
|<pre>B8  ... CLV      &times; 55
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 55
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 55
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|58 bytes
|-
|<pre>EA  ... NOP      &times; 55
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 20,647: Line 18,582:
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|-
|<pre>48       PHA
|<pre>68       PLA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
08       PHP
A2 15   LDX #21
28      PLP
CA       DEX
18      CLC
D0 FD   BNE *-1
D0 FA   BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>EA  ... NOP      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
8C       TXA
08       PHP
A2 15    LDX #21
28      PLP
CA       DEX
18       CLC
D0 FD   BNE *-1
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C; and writes in stack
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,673: Line 18,608:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
48      PHA
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
8C      TXA
48      PHA
A2 14    LDX #20
A2 14    LDX #20
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
AA       TAX</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48       PHA
|<pre>08       PHP
98      TYA
48      PHA
48      PHA
A0 13    LDY #19
8C      TXA
88       DEY
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
AA      TAX
68      PLA
68      PLA
A8       TAY
28       PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|38 bytes
|-
|-
|<pre>A5 A5   LDA $A5
|<pre>36 36   ROL $36,X \ &times; 5
A9 0A   LDA #$0A ;hides 'ASL A'
76 36   ROR $36,X /
18  ... CLC      &times; 2
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
90 00    BCC *+2
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>08      PHP
!colspan="2"|57 bytes
38      SEC
A9 0D    LDA #13
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|12 bytes
|<pre>EA  ... NOP      &times; 57</pre>||No requirements
|-
|-
|<pre>EA      NOP
|}
08      PHP
48      PHA
38      SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|29 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 28</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|33 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 16
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|38 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|57 bytes
|-
|<pre>EA  ... NOP      &times; 57</pre>||No requirements
|-
|}




Line 20,770: Line 18,676:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 16   LDX #22
0A       ASL A ;first loop only
CA       DEX
D0 FC   BNE *-2</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 20,810: Line 18,717:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
90 FA    BCC *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 20,847: Line 18,742:
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
36 36    ROL $36,X
76 36    ROR $36,X
90 F8    BCC *-6</pre>||Clobbers A, Z&N, and C
|-
|-
|<pre>00 00    BRK 0
|<pre>00 00    BRK 0
Line 20,862: Line 18,750:
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 14    LDX #20
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 20,886: Line 18,791:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|29 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 27</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|33 bytes
|-
|<pre>68      PLA      \ &times; 8
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|39 bytes
!colspan="2"|39 bytes
Line 20,980: Line 18,870:
|<pre>B8  ... CLV      &times; 56
|<pre>B8  ... CLV      &times; 56
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 56
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 56
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|59 bytes
|-
|<pre>EA  ... NOP      &times; 56
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 21,050: Line 18,951:
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|-
|<pre>E6 xx    INC @zptemp
|<pre>8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 15   LDX #21
08      PHP
CA       DEX
28       PLP
D0 FD   BNE *-1
18      CLC
F6 xx    INC @zptemp,X
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C; requires @zptemp; and writes in stack
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 21,079: Line 18,980:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
48       PHA
68       PLA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
08       PHP
A2 15   LDX #21
28      PLP
CA       DEX
18      CLC
D0 FD   BNE *-1
D0 FA   BNE *-4</pre>||Clobbers A, S, Z&N, and C; and writes in stack
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>EA       NOP
|<pre>EA   ... NOP     &times; 3
A5 A5    LDA $A5
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 15   LDX #21
08      PHP
CA       DEX
28      PLP
D0 FD   BNE *-1
18       CLC
AA      TAX</pre>||Clobbers A, and Z&N
D0 FA   BNE *-4</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 21,126: Line 19,026:
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|-
|<pre>68       PLA
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48       PHA
8C      TXA
8C      TXA
48      PHA
A2 14    LDX #20
A2 14    LDX #20
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA
AA      TAX
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 0D    LDX #13
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>98       TYA
|<pre>EA       NOP
08      PHP
48      PHA
48      PHA
A0 0D   LDY #13
8C      TXA
A5 A5    LDA $A5
A2 13   LDX #19
88       DEY
CA       DEX
D0 FB   BNE *-3
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
A8       TAY</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Writes in stack
|-
|-
|<pre>E6 xx    INC @zptemp
!colspan="2"|39 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
18  ... CLC      &times; 2
90 00    BCC *+2
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
|-
|<pre>48       PHA
|<pre>EA       NOP
18      CLC
36 36   ROL $36,X \ &times; 5
A9 0A   LDA #$0A ;hides 'ASL A'
76 36   ROR $36,X /
08      PHP
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
F6 F6   INC $F6,X
28      PLP
90 F9    BCC *-5
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>08      PHP
!colspan="2"|58 bytes
F6 F6    INC $F6,X
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>20 xx xx JSR @rts14
|<pre>EA  ... NOP      &times; 58</pre>||No requirements
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
|<pre>20 xx xx JSR @rts14
|}
08      PHP
 
A9 0A    LDA #$0A ;hides 'ASL A'
 
08      PHP
28      PLP
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires @rts12, and @rts14; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
28      PLP
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
|<pre>EA      NOP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18  ... CLC      &times; 2
90 00    BCC *+2
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|29 bytes
|-
|<pre>68  ... PLA      &times; 29</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|33 bytes
|-
|<pre>68      PLA      \ &times; 7
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
!colspan="2"|39 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|58 bytes
|-
|<pre>EA  ... NOP      &times; 58</pre>||No requirements
|-
|}
 
 
=== 117 cycles ===
=== 117 cycles ===
{| class="wikitable testtable"
{| class="wikitable testtable"
Line 21,321: Line 19,145:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 10   LDX #16
0A       ASL A ;first loop only
EA      NOP
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V
CA       DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 21,338: Line 19,164:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>8C      TXA
|<pre>48      PHA
48       PHA
8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C       TXA
A2 15    LDX #21
A2 15    LDX #21
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
AA       TAX</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 21,367: Line 19,201:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
!colspan="2"|10 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA       NOP
|<pre>08       PHP
48      PHA
48      PHA
38      SEC
38      SEC
A9 15   LDA #21
A9 14   LDA #20
E9 01    SBC #1
E9 01    SBC #1
D0 FB    BNE *-3
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA
|-
|<pre>EA      NOP
08      PHP
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>18  ... CLC      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA      NOP
36 36    ROL $36,X
76 36    ROR $36,X
90 F8    BCC *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|30 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 27</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|34 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 15
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|40 bytes
!colspan="2"|40 bytes
Line 21,491: Line 19,286:
|<pre>B8  ... CLV      &times; 57
|<pre>B8  ... CLV      &times; 57
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 57
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 57
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|60 bytes
|-
|<pre>EA  ... NOP      &times; 57
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 21,554: Line 19,360:
D0 FA    BNE *-4
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 16    LDX #22
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 21,562: Line 19,375:
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>68       PLA
|<pre>48       PHA
48       PHA
8C       TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 18   LDX #24 ;hides 'CLC'
18   ... CLC     &times; 2
CA   ... DEX     &times; 2
90 00   BCC *+2
D0 FB   BNE *-3
18       CLC
AA       TAX
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
Line 21,614: Line 19,427:
!colspan="2"|13 bytes
!colspan="2"|13 bytes
|-
|-
|<pre>EA       NOP
|<pre>EA   ... NOP     &times; 2
08      PHP
28      PLP
08      PHP
08      PHP
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
08      PHP
A2 13   LDX #19
28       PLP
CA       DEX
D0 FB   BNE *-3
D0 FD   BNE *-1
AA      TAX
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|30 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 29</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|34 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 7
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|40 bytes
!colspan="2"|40 bytes
Line 21,724: Line 19,521:
28      PLP
28      PLP
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 16    LDX #22
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
|<pre>EA  ... NOP      &times; 2
EA  ... NOP      &times; 4
8C       TXA
18       CLC
A2 16    LDX #22
D0 F8   BNE *-6</pre>||Clobbers A, Z&N, and C
CA      DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 21,770: Line 19,576:
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
48      PHA
8C      TXA
A2 15    LDX #21
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
8C      TXA
48      PHA
A2 15    LDX #21
A2 15    LDX #21
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68       PLA
AA       TAX
AA       TAX</pre>||Clobbers A, and Z&N; and writes in stack
28       PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>EA  ... NOP      &times; 3
Line 21,791: Line 19,606:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
68      PLA</pre>||Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
28      PLP</pre>||Clobbers A, and S; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48      PHA
|<pre>08      PHP
48      PHA
8C      TXA
8C      TXA
48      PHA
A2 14    LDX #20
A2 14    LDX #20
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA
AA      TAX
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
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
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|30 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 28</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|34 bytes
|-
|<pre>68      PLA      \ &times; 17
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|40 bytes
!colspan="2"|40 bytes
Line 21,941: Line 19,710:
|<pre>B8  ... CLV      &times; 58
|<pre>B8  ... CLV      &times; 58
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 58
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 58
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|61 bytes
|-
|<pre>EA  ... NOP      &times; 58
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 21,971: Line 19,751:
!colspan="2"|7 bytes
!colspan="2"|7 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 17   LDX #23
0A       ASL A ;first loop only
CA       DEX
B0 FC   BCS *-2</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 22,036: Line 19,817:
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|-
!colspan="2"|12 bytes
|<pre>48      PHA
98      TYA
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
A8      TAY
68      PLA</pre>||Clobbers Z&N; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>EA       NOP
|<pre>48  ... PHA      &times; 2
68      PLA
8C      TXA
48      PHA
A2 15    LDX #21
A9 0A   LDA #$0A ;hides 'ASL A'
CA       DEX
18  ... CLC      &times; 2
D0 FD    BNE *-1
90 00   BCC *+2
AA      TAX
18       CLC
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
D0 F8   BNE *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5   LDA $A5
8C      TXA
A2 15   LDX #21
CA       DEX
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 22,068: Line 19,867:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
!colspan="2"|30 bytes
|-
|<pre>68  ... PLA      &times; 30</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|35 bytes
|-
|<pre>68      PLA      \ &times; 7
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|40 bytes
!colspan="2"|40 bytes
Line 22,209: Line 19,993:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 16    LDX #22
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 22,216: Line 20,007:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>8C      TXA
A2 0C    LDX #12 ;hides 'NOP abs'
44 00    NOP $0
CA      DEX
10 FA    BPL *-4
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 16    LDX #22
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|-
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>18      CLC
|<pre>EA  ... NOP      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
8C       TXA
EA  ... NOP      &times; 4
A2 16    LDX #22
18       CLC
CA      DEX
D0 F8   BNE *-6</pre>||Clobbers A, Z&N, and C
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>48  ... PHA      &times; 2
|<pre>48  ... PHA      &times; 2
Line 22,235: Line 20,042:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>C5 C5    CMP $C5
|<pre>EA  ... NOP      &times; 2
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
08      PHP
A2 15   LDX #21
28      PLP
CA       DEX
18       CLC
D0 FD   BNE *-1
D0 FA   BNE *-4
AA      TAX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
08      PHP
48      PHA
48      PHA
8C      TXA
8C      TXA
48      PHA
A2 14    LDX #20
A2 14    LDX #20
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA
AA      TAX
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|31 bytes
!colspan="2"|41 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
68      PLA
E6 xx    INC @zptemp
48      PHA
36 36    ROL $36,X \ &times; 5
68  ... PLA      &times; 28</pre>||Clobbers A, S, and Z&N
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|-
!colspan="2"|35 bytes
|<pre>FE 00 02 INC $0200,X
|-
|<pre>EA      NOP
68      PLA      \ &times; 17
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|41 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 5
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
76 36    ROR $36,X /
Line 22,362: Line 20,144:
|<pre>B8  ... CLV      &times; 59
|<pre>B8  ... CLV      &times; 59
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 59
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 59
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|62 bytes
|-
|<pre>EA  ... NOP      &times; 59
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 22,368: Line 20,161:
=== 122 cycles ===
=== 122 cycles ===
{| class="wikitable testtable"
{| class="wikitable testtable"
!colspan="2"|6 bytes
!colspan="2"|5 bytes
|-
|-
|<pre>EA      NOP
|<pre>A9      LDA #95
A9      LDA #93
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
Line 22,417: Line 20,209:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>38      SEC
|<pre>EA      NOP
A9 11    LDA #17
8C       TXA
EA      NOP
A2 17   LDX #23
E9 01    SBC #1
CA       DEX
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
|-
AA       TAX</pre>||Clobbers A, and Z&N
|<pre>68       PLA
08      PHP
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC   BNE *-2
28       PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
48      PHA
8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 16   LDX #22
0A       ASL A ;first loop only
CA       DEX
D0 FC   BNE *-2
D0 FD   BNE *-1
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
18       CLC
8C       TXA
A9 69   LDA #$69 ;hides 'ADC #$F8'
A2 16   LDX #22
F8       SED ;first loop only
CA       DEX
EA      NOP
D0 FD   BNE *-1
10 FB   BPL *-3
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 22,467: Line 20,254:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
90 FA    BCC *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
Line 22,487: Line 20,265:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|31 bytes
|-
|<pre>EA      NOP
68  ... PLA      &times; 30</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|35 bytes
|-
|<pre>68      PLA      \ &times; 9
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|41 bytes
!colspan="2"|41 bytes
Line 22,523: Line 20,281:
=== 123 cycles ===
=== 123 cycles ===
{| class="wikitable testtable"
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #96
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
!colspan="2"|6 bytes
|-
|-
Line 22,534: Line 20,297:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>EA      NOP
A9      LDA #94
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
Line 22,572: Line 20,331:
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>08      PHP
|<pre>A5 A5    LDA $A5
8C      TXA
A2 17    LDX #23
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
48      PHA
A9      LDA #82
A9      LDA #82
Line 22,578: Line 20,344:
68      PLA
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA  ... NOP      &times; 4
A2 15   LDX #21
18       CLC
CA       DEX
D0 F8   BNE *-6</pre>||Clobbers A, Z&N, and C
D0 FD   BNE *-1
|-
F6 xx    INC @zptemp,X
|<pre>E6 xx    INC @zptemp
AA       TAX
48      PHA
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28      PLP
18      CLC
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 22,613: Line 20,365:
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>48  ... PHA      &times; 3
48  ... PHA      &times; 2
8C      TXA
A9 0A   LDA #$0A ;hides 'ASL A'
A2 15   LDX #21
08      PHP
CA       DEX
28      PLP
D0 FD   BNE *-1
18       CLC
AA      TAX
D0 FA   BNE *-4
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
68      PLA</pre>||Clobbers S, Z&N, and C; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>EA       NOP
|<pre>EA   ... NOP     &times; 3
C5 C5    CMP $C5
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
08      PHP
A2 15   LDX #21
28      PLP
CA       DEX
18       CLC
D0 FD   BNE *-1
D0 FA   BNE *-4
AA      TAX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 22,655: Line 20,405:
!colspan="2"|13 bytes
!colspan="2"|13 bytes
|-
|-
|<pre>48       PHA
|<pre>08       PHP
98      TYA
48      PHA
48      PHA
A0 0D    LDY #13
8C      TXA
A5 A5   LDA $A5
A2 0D    LDX #13
88       DEY
C5 C5   CMP $C5
CA       DEX
D0 FB    BNE *-3
D0 FB    BNE *-3
AA      TAX
68      PLA
68      PLA
A8       TAY
28       PLP</pre>||Writes in stack
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|42 bytes
|-
|-
|<pre>08      PHP
|<pre>C5 C5    CMP $C5
48      PHA
36 36   ROL $36,X \ &times; 10
18      CLC
76 36   ROR $36,X /</pre>||Clobbers Z&N, and C
A9 0A   LDA #$0A ;hides 'ASL A'
08      PHP
F6 F6   INC $F6,X
28      PLP
90 F9    BCC *-5
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|-
|<pre>20 xx xx JSR @rts14
|<pre>24 24    BIT $24
08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
28      PLP
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
48      PHA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|14 bytes
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
48      PHA
38      SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|31 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 29</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|35 bytes
|-
|<pre>68      PLA      \ &times; 8
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
!colspan="2"|42 bytes
|-
|<pre>C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and C
|-
|<pre>24 24    BIT $24
36 36    ROL $36,X \ &times; 10
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
Line 22,800: Line 20,492:
|<pre>B8  ... CLV      &times; 60
|<pre>B8  ... CLV      &times; 60
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 60
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 60
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|63 bytes
|-
|<pre>EA  ... NOP      &times; 60
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 22,810: Line 20,513:
|<pre>A2 E8    LDX #232 ;hides 'INX'
|<pre>A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #97
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
!colspan="2"|6 bytes
!colspan="2"|6 bytes
Line 22,817: Line 20,525:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|<pre>68      PLA
A9      LDA #93
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, S, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
Line 22,833: Line 20,537:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>A5 A5    LDA $A5
A9      LDA #94
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 22,855: Line 20,555:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>EA       NOP
|<pre>8C       TXA
38      SEC
A2 11   LDX #17
A9 69   LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
EA      NOP
EA      NOP
10 FB    BPL *-3</pre>||Clobbers A, Z&N, C, V, and D
CA       DEX
|-
D0 FC    BNE *-2
|<pre>EA       NOP
AA       TAX</pre>||Clobbers A, and Z&N
F6 F6    INC $F6,X
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28      PLP
00 00    BRK 0
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|<pre>EA      NOP
38      SEC
A9 11    LDA #17
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 22,975: Line 20,656:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>EA  ... NOP      &times; 3
|<pre>48      PHA
48      PHA
8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 10   LDX #16
0A       ASL A ;first loop only
EA      NOP
CA       DEX
D0 FC    BNE *-2
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA      NOP
|<pre>08      PHP
08      PHP
8C       TXA
18       CLC
A2 10   LDX #16
A9 69   LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
EA      NOP
EA      NOP
10 FB   BPL *-3
CA      DEX
D0 FC   BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 23,007: Line 20,690:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>48      PHA
|<pre>08      PHP
48      PHA
8C      TXA
8C      TXA
48      PHA
A2 15    LDX #21
A2 15    LDX #21
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA
AA      TAX
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C; and requires @zptemp
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>EA      NOP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|31 bytes
|-
|<pre>68  ... PLA      &times; 31</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|36 bytes
|-
|<pre>36 36    ROL $36,X
76 36    ROR $36,X
68      PLA      \ &times; 16
48      PHA      /</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|42 bytes
!colspan="2"|42 bytes
Line 23,070: Line 20,717:
=== 125 cycles ===
=== 125 cycles ===
{| class="wikitable testtable"
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #98
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
!colspan="2"|6 bytes
|-
|-
Line 23,090: Line 20,742:
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
|-
|<pre>68      PLA
!colspan="2"|7 bytes
A9      LDA #94
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, S, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
!colspan="2"|7 bytes
|<pre>8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>EA  ... NOP      &times; 2
Line 23,110: Line 20,764:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
A9      LDA #94
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,128: Line 20,778:
B0 FC    BCS *-2
B0 FC    BCS *-2
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA      NOP
38      SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,166: Line 20,810:
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|11 bytes
!colspan="2"|42 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|-
|<pre>F6 F6    INC $F6,X
!colspan="2"|43 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
68      PLA
C5 C5    CMP $C5
A9 0A   LDA #$0A ;hides 'ASL A'
36 36   ROL $36,X \ &times; 10
EA  ... NOP      &times; 4
76 36   ROR $36,X /</pre>||Clobbers Z&N, and C
18      CLC
D0 F8   BNE *-6</pre>||Clobbers A, S, Z&N, and C
|-
|-
!colspan="2"|12 bytes
|<pre>EA      NOP
|-
24 24    BIT $24
|<pre>EA  ... NOP      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
EA  ... NOP      &times; 4
18      CLC
D0 F8    BNE *-6</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|32 bytes
|-
|<pre>EA      NOP
68      PLA
48      PHA
68  ... PLA      &times; 29</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|36 bytes
|-
|<pre>EA      NOP
68      PLA      \ &times; 8
48      PHA      /
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 14
10 EE    BPL *-16</pre>||Clobbers A, and Z&N
|-
!colspan="2"|42 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
!colspan="2"|43 bytes
|-
|<pre>EA      NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and C
|-
|<pre>EA      NOP
24 24    BIT $24
36 36    ROL $36,X \ &times; 10
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
Line 23,287: Line 20,891:
|<pre>B8  ... CLV      &times; 61
|<pre>B8  ... CLV      &times; 61
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 61
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 61
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|64 bytes
|-
|<pre>EA  ... NOP      &times; 61
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 23,302: Line 20,917:
88      DEY
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #99
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
!colspan="2"|7 bytes
!colspan="2"|7 bytes
Line 23,309: Line 20,927:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9      LDA #92
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,375: Line 20,988:
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|-
|<pre>A5 A5    LDA $A5
|<pre>EA      NOP
38       SEC
8C       TXA
A9 18   LDA #24
A2 11   LDX #17
E9 01    SBC #1
EA      NOP
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
CA      DEX
D0 FC   BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,414: Line 21,029:
!colspan="2"|11 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>68      PLA
|<pre>EA  ... NOP      &times; 2
48      PHA
48      PHA
A9 0A   LDA #$0A ;hides 'ASL A'
8C      TXA
EA  ... NOP      &times; 4
A2 16   LDX #22
18       CLC
CA       DEX
D0 F8   BNE *-6</pre>||Clobbers A, Z&N, and C
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|12 bytes
!colspan="2"|12 bytes
|-
|-
|<pre>EA      NOP
|<pre>EA      NOP
08      PHP
48      PHA
48      PHA
8C      TXA
8C      TXA
48      PHA
A2 15    LDX #21
A2 15    LDX #21
CA      DEX
CA      DEX
D0 FD    BNE *-1
D0 FD    BNE *-1
68      PLA
AA      TAX
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
68      PLA
28      PLP</pre>||Clobbers S; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
38      SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|32 bytes
!colspan="2"|42 bytes
|-
|-
|<pre>EA      NOP
|<pre>36 36    ROL $36,X \ &times; 6
68  ... PLA      &times; 31</pre>||Clobbers A, S, and Z&N
76 36    ROR $36,X /
|-
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
!colspan="2"|36 bytes
|-
|<pre>68      PLA      \ &times; 18
48      PHA      /</pre>||Clobbers A, and Z&N
|-
!colspan="2"|42 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
|-
!colspan="2"|63 bytes
!colspan="2"|63 bytes
Line 23,482: Line 21,067:
{| class="wikitable testtable"
{| class="wikitable testtable"
!colspan="2"|5 bytes
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #100
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 23,505: Line 21,093:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
48      PHA
A9      LDA #93
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,523: Line 21,106:
!colspan="2"|8 bytes
!colspan="2"|8 bytes
|-
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
|<pre>EA      NOP
EA      NOP
8C       TXA
08       PHP
A2 18    LDX #24
28      PLP
CA       DEX
18       CLC
D0 FD   BNE *-1
D0 F9   BNE *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
AA      TAX</pre>||Clobbers A, and Z&N
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,543: Line 21,126:
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>68      PLA
38      SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V
|-
|<pre>68      PLA
08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
28      PLP</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>48      PHA
48      PHA
8C      TXA
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
A2 17   LDX #23
0A       ASL A ;first loop only
CA       DEX
B0 FC   BCS *-2
D0 FD   BNE *-1
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
|<pre>EA  ... NOP      &times; 2
|<pre>08      PHP
38       SEC
8C       TXA
A9 18   LDA #24
A2 17   LDX #23
E9 01    SBC #1
CA      DEX
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
D0 FD   BNE *-1
|-
AA       TAX
|<pre>EA  ... NOP      &times; 2
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
Line 23,596: Line 21,162:
68      PLA
68      PLA
28      PLP</pre>||Writes in stack
28      PLP</pre>||Writes in stack
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
18  ... CLC      &times; 3
90 00    BCC *+2
18      CLC
D0 F7    BNE *-7</pre>||Clobbers A, Z&N, and C
|-
!colspan="2"|32 bytes
|-
|<pre>68      PLA
48      PHA
68  ... PLA      &times; 30</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|37 bytes
|-
|<pre>68      PLA      \ &times; 8
48      PHA      /
36 36    ROL $36,X
76 36    ROR $36,X
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA      NOP ;first loop only
EA  ... NOP      &times; 12
10 F0    BPL *-14</pre>||Clobbers A, and Z&N
|-
|-
!colspan="2"|43 bytes
!colspan="2"|43 bytes
Line 23,698: Line 21,241:
|<pre>B8  ... CLV      &times; 62
|<pre>B8  ... CLV      &times; 62
50 00    BVC *+2</pre>||Clobbers V
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 62
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 62
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|65 bytes
|-
|<pre>EA  ... NOP      &times; 62
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|-
|}
|}
Line 23,704: Line 21,258:
=== 128 cycles ===
=== 128 cycles ===
{| class="wikitable testtable"
{| class="wikitable testtable"
!colspan="2"|7 bytes
!colspan="2"|5 bytes
|-
|-
|<pre>38       SEC
|<pre>A9      LDA #101
A9 19   LDA #25
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
E9 01   SBC #1
|-
D0 FB   BNE *-3</pre>||Clobbers A, Z&N, C, and V
|<pre>68       PLA
A2 E8   LDX #232 ;hides 'INX'
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
!colspan="2"|6 bytes
|-
|<pre>8C      TXA
A2 E8   LDX #232 ;hides 'INX'
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA      NOP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,722: Line 21,297:
D0 FD    BNE *-1
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>A2 0D    LDX #13 ;hides 'ORA abs'
E6 xx    INC @zptemp
CA      DEX
10 FA    BPL *-4</pre>||Clobbers A, X, and Z&N; and requires @zptemp
|-
|<pre>A0 0D    LDY #13 ;hides 'ORA abs'
E6 xx    INC @zptemp
88      DEY
10 FA    BPL *-4</pre>||Clobbers A, Y, and Z&N; and requires @zptemp
|-
|-
|<pre>48      PHA
|<pre>48      PHA
Line 23,742: Line 21,307:
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>A2 14    LDX #20 ;hides 'NOP zp,X'
04 EA    NOP $EA ;hides 'NOP'
CA  ... DEX      &times; 2
D0 F9    BNE *-5</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
|-
|<pre>A0 14    LDY #20 ;hides 'NOP zp,X'
04 EA    NOP $EA ;hides 'NOP'
88  ... DEY      &times; 2
D0 F9    BNE *-5</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
|-
|<pre>A2 09    LDX #9 ;hides 'ORA #imm'
A5 68    LDA $68 ;hides 'PLA'
EA      NOP
CA      DEX
10 F9    BPL *-5</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>A0 09    LDY #9 ;hides 'ORA #imm'
A5 68    LDA $68 ;hides 'PLA'
EA      NOP
88      DEY
10 F9    BPL *-5</pre>||Clobbers A, Y, S, and Z&N
|-
|-
!colspan="2"|9 bytes
!colspan="2"|9 bytes
Line 23,784: Line 21,325:
30 FA    BMI *-4
30 FA    BMI *-4
28      PLP</pre>||Clobbers A; and writes in stack
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>A2 0B    LDX #11
F6 F6    INC $F6,X
CA      DEX
D0 FB    BNE *-3
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|-
|<pre>08      PHP
|<pre>08      PHP
Line 23,800: Line 21,335:
!colspan="2"|10 bytes
!colspan="2"|10 bytes
|-
|-
|<pre>A2 05    LDX #5 ;hides 'ORA zp'
|<pre>48      PHA
CA       DEX ;first loop only
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD   BPL *-1
20 xx xx JSR @rts15
CA       DEX
90 FA   BCC *-4
D0 F7    BNE *-7</pre>||Clobbers A, X, Z&N, and C
68       PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|-
|<pre>A0 05    LDY #5 ;hides 'ORA zp'
|<pre>48      PHA
88       DEY ;first loop only
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD   BPL *-1
EA      NOP
88       DEY
00 00    BRK 0
D0 F7    BNE *-7</pre>||Clobbers A, Y, Z&N, and C
90 FA   BCC *-4
68       PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
|<pre>A2 0B   LDX #11
|<pre>48      PHA
EA  ... NOP      &times; 3
08      PHP
CA       DEX
48      PHA
D0 FA   BNE *-4
A9 E9   LDA #$E9 ;hides 'SBC #$0A'
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp
0A       ASL A ;first loop only
D0 FC   BNE *-2
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
|-
|<pre>A2 09    LDX #9 ;hides 'ORA #imm'
!colspan="2"|11 bytes
FE B5 02 INC $02B5,X ;hides 'LDA $02,X'
A5 A5    LDA $A5
CA      DEX
D0 F7    BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $200-$2FF, and writable $300-$3FF
|-
|-
|<pre>A0 09   LDY #9 ;hides 'ORA #imm'
|<pre>08      PHP
FE B5 02 INC $02B5,X ;hides 'LDA $02,X'
24 24   BIT $24
A5 A5    LDA $A5
48      PHA
88       DEY
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
D0 F7   BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $200-$2FF, and writable $300-$3FF
0A       ASL A ;first loop only
D0 FC   BNE *-2
68      PLA
28      PLP</pre>||Writes in stack
|-
|-
|<pre>A2 09   LDX #9 ;hides 'ORA #imm'
!colspan="2"|43 bytes
FE B5 03 INC $03B5,X ;hides 'LDA $03,X'
|-
A5 A5    LDA $A5
|<pre>EA      NOP
CA      DEX
36 36   ROL $36,X \ &times; 6
D0 F7    BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $300-$3FF, and writable $400-$4FF
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|64 bytes
|-
|<pre>EA  ... NOP      &times; 64</pre>||No requirements
|-
|}
 
 
=== 129 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|-
|<pre>A0 09    LDY #9 ;hides 'ORA #imm'
|<pre>A9      LDA #102
FE B5 03 INC $03B5,X ;hides 'LDA $03,X'
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
A5 A5    LDA $A5
88      DEY
D0 F7    BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $300-$3FF, and writable $400-$4FF
|-
|-
|<pre>A2 09    LDX #9 ;hides 'ORA #imm'
!colspan="2"|6 bytes
FE B5 04 INC $04B5,X ;hides 'LDA $04,X'
A5 A5    LDA $A5
CA      DEX
D0 F7    BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $400-$4FF, and writable $500-$5FF
|-
|-
|<pre>A0 09   LDY #9 ;hides 'ORA #imm'
|<pre>E6 xx   INC @zptemp
FE B5 04 INC $04B5,X ;hides 'LDA $04,X'
A2 E8    LDX #232 ;hides 'INX'
A5 A5    LDA $A5
D0 FD   BNE *-1</pre>||Clobbers X, and Z&N; and requires @zptemp
88      DEY
D0 F7   BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $400-$4FF, and writable $500-$5FF
|-
|-
|<pre>A2 09   LDX #9 ;hides 'ORA #imm'
|<pre>A2 10   LDX #16
FE B5 05 INC $05B5,X ;hides 'LDA $05,X'
48      PHA
A5 A5    LDA $A5
CA      DEX
CA      DEX
D0 F7   BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $500-$5FF, and writable $600-$6FF
D0 FC   BNE *-2</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|-
|<pre>A0 09   LDY #9 ;hides 'ORA #imm'
|<pre>A0 10   LDY #16
FE B5 05 INC $05B5,X ;hides 'LDA $05,X'
48      PHA
A5 A5    LDA $A5
88      DEY
88      DEY
D0 F7   BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $500-$5FF, and writable $600-$6FF
D0 FC   BNE *-2</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|-
|<pre>A2 09   LDX #9 ;hides 'ORA #imm'
|<pre>A0 88   LDY #136 ;hides 'DEY'
FE B5 07 INC $07B5,X ;hides 'LDA $07,X'
68  ... PLA      &times; 2
A5 A5   LDA $A5
30 FB   BMI *-3</pre>||Clobbers A, Y, S, and Z&N
CA      DEX
D0 F7    BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $00-$FF, and writable $700-$7FF
|-
|-
|<pre>A0 09    LDY #9 ;hides 'ORA #imm'
!colspan="2"|7 bytes
FE B5 07 INC $07B5,X ;hides 'LDA $07,X'
A5 A5    LDA $A5
88      DEY
D0 F7    BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $00-$FF, and writable $700-$7FF
|-
|-
|<pre>A2 09   LDX #9 ;hides 'ORA #imm'
|<pre>A6 A6   LDX $A6
FE B5 06 INC $06B5,X ;hides 'LDA $06,X'
A2 19   LDX #25
A5 A5   LDA $A5
CA      DEX
CA      DEX
D0 F7   BNE *-7</pre>||Clobbers A, X, and Z&N; and requires writable $600-$6FF, and writable $700-$7FF
D0 FD   BNE *-1</pre>||Clobbers X, and Z&N
|-
|-
|<pre>A0 09   LDY #9 ;hides 'ORA #imm'
|<pre>A4 A4   LDY $A4
FE B5 06 INC $06B5,X ;hides 'LDA $06,X'
A0 19   LDY #25
A5 A5   LDA $A5
88      DEY
88      DEY
D0 F7   BNE *-7</pre>||Clobbers A, Y, and Z&N; and requires writable $600-$6FF, and writable $700-$7FF
D0 FD   BNE *-1</pre>||Clobbers Y, and Z&N
|-
|-
|<pre>48      PHA
|<pre>48      PHA
18       CLC
A9       LDA #95
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR delay_a_25_clocks
20 xx xx JSR @rts15
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
90 FA    BCC *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|-
|<pre>48       PHA
|<pre>08       PHP
18       CLC
A9       LDA #95
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR delay_a_25_clocks
EA      NOP
28       PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
90 FA    BCC *-4
68       PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|-
!colspan="2"|11 bytes
|<pre>00 00   BRK 0
|-
|<pre>08      PHP
24 24   BIT $24
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
0A      ASL A ;first loop only
D0 FC    BNE *-2
B0 FC    BCS *-2</pre>||Clobbers A, Z&N, C, and V; requires dummy interrupt handler; and writes in stack
68      PLA
28      PLP</pre>||Writes in stack
|-
|-
|<pre>BA      TSX
!colspan="2"|8 bytes
A0 09    LDY #9 ;hides 'ORA #imm'
A5 68    LDA $68 ;hides 'PLA'
A5 A5    LDA $A5
88      DEY
D0 F8    BNE *-6
9A      TXS</pre>||Clobbers A, X, Y, and Z&N; and unsafe for interrupts
|-
|-
!colspan="2"|12 bytes
|<pre>38      SEC
A9 12   LDA #18
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
|-
|-
|<pre>A2 05   LDX #5 ;hides 'ORA zp'
|<pre>8C      TXA
AD EA EA LDA $EAEA ;hides two 'NOP's
A2 1A   LDX #26 ;hides 'NOP'
68      PLA      \ &times; 2
CA  ... DEX      &times; 2
48      PHA      /
10 FB   BPL *-3
CA      DEX
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
D0 F5   BNE *-9</pre>||Clobbers A, X, and Z&N
|-
|-
|<pre>A0 05   LDY #5 ;hides 'ORA zp'
|<pre>68      PLA
AD EA EA LDA $EAEA ;hides two 'NOP's
8C      TXA
68      PLA       \ &times; 2
A2 18    LDX #24
48       PHA      /
CA      DEX
88       DEY
D0 FD    BNE *-1
D0 F5   BNE *-9</pre>||Clobbers A, Y, and Z&N
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 69   LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
EA       NOP
10 FB    BPL *-3
68      PLA</pre>||Clobbers Z&N, C, V, and D; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD   BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
EA      NOP
10 FB    BPL *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|-
|<pre>A2 01   LDX #1
|<pre>EA      NOP
08      PHP
A2 11   LDX #17
EA      NOP
EA      NOP
CA      DEX
D0 FC    BNE *-2
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 11    LDY #17
A0 11    LDY #17
EA      NOP
EA      NOP
88      DEY
88      DEY
D0 FC    BNE *-2
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #88
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 17    LDX #23
CA      DEX
CA      DEX
D0 F6   BNE *-8</pre>||Clobbers X, Y, and Z&N
D0 FD   BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|-
!colspan="2"|16 bytes
!colspan="2"|11 bytes
|-
|-
|<pre>18  ... CLC      &times; 2
|<pre>08      PHP
A9 0A   LDA #$0A ;hides 'ASL A'
48      PHA
EA  ... NOP      &times; 9
8C      TXA
18       CLC
A2 16   LDX #22
10 F3   BPL *-11</pre>||Clobbers A, Z&N, and C
CA       DEX
D0 FD   BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
|-
!colspan="2"|32 bytes
!colspan="2"|44 bytes
|-
|-
|<pre>68  ... PLA      &times; 32</pre>||Clobbers A, S, and Z&N
|<pre>C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and C
|-
|-
!colspan="2"|64 bytes
|<pre>24 24    BIT $24
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and V
|-
|<pre>E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>EA      NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>EA      NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>EA      NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>EA      NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>EA      NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>EA      NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>04 04    NOP $04
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|45 bytes
|-
|<pre>4C xx xx JMP *+3
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|46 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
26 26... ROL $26  &times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|65 bytes
|-
|<pre>18  ... CLC      &times; 63
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 63
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 63
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 63
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|66 bytes
|-
|<pre>EA  ... NOP      &times; 63
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 130 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|-
|<pre>EA  ... NOP      &times; 64</pre>||No requirements
|<pre>A9      LDA #103
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp
|-
|<pre>48  ... PHA      &times; 2
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>68      PLA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>68      PLA
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #96
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #96
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
08      PHP
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 18    LDY #24
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|44 bytes
|-
|<pre>26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|65 bytes
|-
|<pre>EA  ... NOP      &times; 65</pre>||No requirements
|-
|}
 
 
=== 131 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #104
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #97
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #97
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 12    LDX #18
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>48      PHA
08      PHP
A0 18    LDY #24
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
A4 A4    LDY $A4
A0 18    LDY #24
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #90
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>00 00    BRK 0
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
|-
|<pre>00 00    BRK 0
08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
8C      TXA
A2 11    LDX #17
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 11    LDX #17
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
F6 F6    INC $F6,X
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 10    LDX #16
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|44 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
!colspan="2"|45 bytes
|-
|<pre>EA      NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and C
|-
|<pre>EA      NOP
24 24    BIT $24
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and V
|-
|<pre>FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 5
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>EA      NOP
04 04    NOP $04
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|46 bytes
|-
|<pre>EA      NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|47 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
26 26... ROL $26  &times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|66 bytes
|-
|<pre>18  ... CLC      &times; 64
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 64
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 64
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 64
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|67 bytes
|-
|<pre>EA  ... NOP      &times; 64
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 132 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #105
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
03 xx    SLO (@ptrtemp,X)</pre>||Clobbers A, X, Z&N, and C; and requires @ptrtemp, and support for unofficial opcodes
|-
|<pre>68  ... PLA      &times; 2
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1</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'
D0 FD    BNE *-1</pre>||Clobbers A, X, and Z&N; and unsafe for interrupts
|-
|<pre>A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp
|-
|<pre>F6 F6    INC $F6,X
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|<pre>48      PHA
A9      LDA #98
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #98
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|<pre>48  ... PHA      &times; 2
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>08      PHP
A2 1A    LDX #26 ;hides 'NOP'
CA  ... DEX      &times; 2
10 FB    BPL *-3
28      PLP</pre>||Clobbers X; requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
A0 1A    LDY #26 ;hides 'NOP'
88  ... DEY      &times; 2
10 FB    BPL *-3
28      PLP</pre>||Clobbers Y; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 18    LDY #24
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #91
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>08      PHP
48      PHA
18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|44 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|66 bytes
|-
|<pre>EA  ... NOP      &times; 66</pre>||No requirements
|-
|}
 
 
=== 133 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #106
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>EA      NOP
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>38      SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #99
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #99
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>E6 xx    INC @zptemp
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>8C      TXA
A2 10    LDX #16
48      PHA
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #92
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>20 xx xx JSR @rts15
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires @rts12, and @rts15; and writes in stack
|-
|<pre>20 xx xx JSR @rts15
08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires @rts12, and @rts15; and writes in stack
|-
|<pre>EA      NOP
00 00    BRK 0
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
|-
|<pre>EA      NOP
00 00    BRK 0
08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
24 24    BIT $24
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|45 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
!colspan="2"|46 bytes
|-
|<pre>C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and C
|-
|<pre>24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
|-
|<pre>04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|47 bytes
|-
|<pre>4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|48 bytes
|-
|<pre>EA  ... NOP      &times; 2
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
26 26... ROL $26  &times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|67 bytes
|-
|<pre>18  ... CLC      &times; 65
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 65
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 65
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 65
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|68 bytes
|-
|<pre>EA  ... NOP      &times; 65
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 134 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #107
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>A0 13    LDY #19
EA      NOP
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #100
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #100
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>08      PHP
A2 12    LDX #18
EA      NOP
CA      DEX
D0 FC    BNE *-2
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 12    LDY #18
EA      NOP
88      DEY
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5</pre>||Clobbers A, Z&N, C, and V; requires @rts12, and @rts14; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #93
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
68      PLA</pre>||Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
|-
|<pre>08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 17    LDX #23
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|45 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|67 bytes
|-
|<pre>EA  ... NOP      &times; 67</pre>||No requirements
|-
|}
 
 
=== 135 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #108
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>68      PLA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>68      PLA
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #101
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #101
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
48      PHA
A9      LDA #94
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
08      PHP
28      PLP
30 FA    BMI *-4
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|46 bytes
|-
|<pre>C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N, and C
|-
|<pre>24 24    BIT $24
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
|-
|<pre>E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>EA      NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>EA      NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>EA      NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>EA      NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>EA      NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>EA      NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>04 04    NOP $04
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|47 bytes
|-
|<pre>4C xx xx JMP *+3
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|49 bytes
|-
|<pre>EA  ... NOP      &times; 3
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
26 26... ROL $26  &times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|68 bytes
|-
|<pre>18  ... CLC      &times; 66
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 66
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 66
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 66
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|69 bytes
|-
|<pre>EA  ... NOP      &times; 66
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 136 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #109
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #102
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #102
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$08'
08      PHP ;first loop only
EA  ... NOP      &times; 2
30 FA    BMI *-4</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>38      SEC
A9 13    LDA #19
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
E6 xx    INC @zptemp
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>68  ... PLA      &times; 2
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
|<pre>48      PHA
08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48      PHA
08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
A2 10    LDX #16
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 10    LDY #16
C5 C5    CMP $C5
88      DEY
D0 FB    BNE *-3
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #95
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>00 00    BRK 0
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
|-
|<pre>00 00    BRK 0
08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
38      SEC
A9 12    LDA #18
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
38      SEC
A9 12    LDA #18
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 1A    LDX #26 ;hides 'NOP'
CA  ... DEX      &times; 2
10 FB    BPL *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
EA      NOP
10 FB    BPL *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|46 bytes
|-
|<pre>26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|68 bytes
|-
|<pre>EA  ... NOP      &times; 68</pre>||No requirements
|-
|}
 
 
=== 137 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #110
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>00 00    BRK 0
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N; requires dummy interrupt handler; and writes in stack
|-
|<pre>A2 11    LDX #17
48      PHA
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>A0 11    LDY #17
48      PHA
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>A2 11    LDX #17
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers X, Z&N, and C
|-
|<pre>A0 11    LDY #17
C5 C5    CMP $C5
88      DEY
D0 FB    BNE *-3</pre>||Clobbers Y, Z&N, and C
|-
|<pre>A2 11    LDX #17
24 24    BIT $24
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers X, Z&N, and V
|-
|<pre>A0 11    LDY #17
24 24    BIT $24
88      DEY
D0 FB    BNE *-3</pre>||Clobbers Y, Z&N, and V
|-
|<pre>A2 11    LDX #17
A5 A5    LDA $A5
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers A, X, and Z&N
|-
|<pre>A0 11    LDY #17
A5 A5    LDA $A5
88      DEY
D0 FB    BNE *-3</pre>||Clobbers A, Y, and Z&N
|-
|<pre>A2 11    LDX #17
A4 A4    LDY $A4
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers X, Y, and Z&N
|-
|<pre>A2 11    LDX #17
85 xx    STA @zptemp
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers X, and Z&N; and requires @zptemp
|-
|<pre>A0 11    LDY #17
85 xx    STA @zptemp
88      DEY
D0 FB    BNE *-3</pre>||Clobbers Y, and Z&N; and requires @zptemp
|-
|<pre>48      PHA
A9      LDA #103
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #103
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>A2 11    LDX #17
04 04    NOP $04
CA      DEX
D0 FB    BNE *-3</pre>||Clobbers X, and Z&N; and requires support for unofficial opcodes
|-
|<pre>A0 11    LDY #17
04 04    NOP $04
88      DEY
D0 FB    BNE *-3</pre>||Clobbers Y, and Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>A6 A6    LDX $A6
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 13    LDY #19
EA      NOP
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
|<pre>08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #96
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|46 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
!colspan="2"|47 bytes
|-
|<pre>EA      NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N, and C
|-
|<pre>EA      NOP
24 24    BIT $24
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N, and V
|-
|<pre>FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 10
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>EA      NOP
04 04    NOP $04
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|48 bytes
|-
|<pre>EA      NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|69 bytes
|-
|<pre>18  ... CLC      &times; 67
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 67
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 67
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 67
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|70 bytes
|-
|<pre>EA  ... NOP      &times; 67
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 138 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #111
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>EA      NOP
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
!colspan="2"|7 bytes
|-
|<pre>38      SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #104
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #104
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
48      PHA
A9      LDA #97
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|<pre>48      PHA
08      PHP
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
8C      TXA
A2 12    LDX #18
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 12    LDX #18
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>00 00    BRK 0
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 11    LDX #17
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|46 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|69 bytes
|-
|<pre>EA  ... NOP      &times; 69</pre>||No requirements
|-
|}
 
 
=== 139 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #112
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>48      PHA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48      PHA
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>A6 A6    LDX $A6
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #105
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #105
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
48      PHA
10 FB    BPL *-3</pre>||Clobbers A, S, Z&N, C, V, and D; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4</pre>||Clobbers A, Z&N, C, V, and D; and requires @zptemp
|-
|<pre>38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4</pre>||Clobbers A, Z&N, C, V, and D; and requires support for unofficial opcodes
|-
|<pre>08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
03 xx    SLO (@ptrtemp,X)
28      PLP</pre>||Clobbers A, and X; requires @ptrtemp, and support for unofficial opcodes; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
BA      TSX
68      PLA
9A      TXS
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers A, and X; writes in stack; and unsafe for interrupts
|-
|<pre>08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #98
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A0 19    LDY #25
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|47 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
!colspan="2"|48 bytes
|-
|<pre>C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and C
|-
|<pre>24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and V
|-
|<pre>04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|49 bytes
|-
|<pre>4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|70 bytes
|-
|<pre>18  ... CLC      &times; 68
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 68
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 68
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 68
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|71 bytes
|-
|<pre>EA  ... NOP      &times; 68
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 140 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #113
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>68      PLA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>68      PLA
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #106
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #106
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
08      PHP
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #99
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>E6 xx    INC @zptemp
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>20 xx xx JSR @rts15
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires @rts12, and @rts15; and writes in stack
|-
|<pre>EA      NOP
00 00    BRK 0
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
38      SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
8C      TXA
A2 11    LDX #17
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|47 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N
|-
!colspan="2"|70 bytes
|-
|<pre>EA  ... NOP      &times; 70</pre>||No requirements
|-
|}
 
 
=== 141 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #114
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #107
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #107
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
EA      NOP
08      PHP
28      PLP
30 F9    BMI *-5</pre>||Clobbers A, Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 13    LDY #19
EA      NOP
88      DEY
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>04 04    NOP $04
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>00 00    BRK 0
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
|-
|<pre>8C      TXA
A2 11    LDX #17
48      PHA
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>8C      TXA
A2 11    LDX #17
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, Z&N, and C
|-
|<pre>8C      TXA
A2 11    LDX #17
24 24    BIT $24
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, Z&N, and V
|-
|<pre>8C      TXA
A2 11    LDX #17
85 xx    STA @zptemp
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #100
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>8C      TXA
A2 11    LDX #17
04 04    NOP $04
CA      DEX
D0 FB    BNE *-3
AA      TAX</pre>||Clobbers A, and Z&N; and requires support for unofficial opcodes
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|10 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|<pre>48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
68      PLA</pre>||Clobbers Z&N, C, and V; requires @rts12, and @rts14; and writes in stack
|-
|<pre>08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
28      PLP</pre>||Clobbers A; requires @rts12, and @rts14; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
8C      TXA
A2 18    LDX #24
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|48 bytes
|-
|<pre>C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and C
|-
|<pre>24 24    BIT $24
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and V
|-
|<pre>E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>EA      NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>EA      NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>EA      NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>EA      NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>EA      NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>EA      NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>04 04    NOP $04
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|49 bytes
|-
|<pre>4C xx xx JMP *+3
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|71 bytes
|-
|<pre>18  ... CLC      &times; 69
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 69
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 69
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 69
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|72 bytes
|-
|<pre>EA  ... NOP      &times; 69
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 142 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #115
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4</pre>||Clobbers X, and Z&N
|-
|<pre>A0 18    LDY #24 ;hides 'CLC'
EA      NOP
88  ... DEY      &times; 2
10 FA    BPL *-4</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #108
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #108
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 1A    LDY #26
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #101
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|48 bytes
|-
|<pre>26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 11
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|71 bytes
|-
|<pre>EA  ... NOP      &times; 71</pre>||No requirements
|-
|}
 
 
=== 143 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #116
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>EA      NOP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #109
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #109
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
F6 F6    INC $F6,X
28      PLP
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #102
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
38      SEC
A9 13    LDA #19
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 13    LDA #19
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>00 00    BRK 0
08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
B0 FC    BCS *-2
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 12    LDA #18
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|48 bytes
|-
|<pre>E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
!colspan="2"|49 bytes
|-
|<pre>EA      NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and C
|-
|<pre>EA      NOP
24 24    BIT $24
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N, and V
|-
|<pre>FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ &times; 6
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
|<pre>EA      NOP
04 04    NOP $04
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires support for unofficial opcodes
|-
!colspan="2"|50 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9
4C xx xx JMP *+3</pre>||Clobbers Z&N; and not relocatable code
|-
!colspan="2"|72 bytes
|-
|<pre>18  ... CLC      &times; 70
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 70
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 70
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 70
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|73 bytes
|-
|<pre>EA  ... NOP      &times; 70
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 144 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #117
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>48      PHA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48      PHA
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>A6 A6    LDX $A6
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #110
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #110
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>F6 F6    INC $F6,X
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, support for unofficial opcodes, and writable $00-$FF
|-
|<pre>00 00    BRK 0
08      PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A2 11    LDX #17
24 24    BIT $24
CA      DEX
D0 FB    BNE *-3
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 11    LDY #17
C5 C5    CMP $C5
88      DEY
D0 FB    BNE *-3
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #103
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|48 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 12
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|72 bytes
|-
|<pre>EA  ... NOP      &times; 72</pre>||No requirements
|-
|}
 
 
=== 145 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #118
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>A2 12    LDX #18
48      PHA
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>A0 12    LDY #18
48      PHA
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|<pre>A2 10    LDX #16
68      PLA
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>A0 10    LDY #16
68      PLA
88      DEY
D0 FC    BNE *-2</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #111
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #111
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
08      PHP
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #104
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
8C      TXA
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
08      PHP
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 12    LDX #18
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|49 bytes
|-
|<pre>EA      NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires @zptemp
|-
|<pre>FE 00 02 INC $0200,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $200-$2FF
|-
|<pre>FE 00 03 INC $0300,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $300-$3FF
|-
|<pre>FE 00 04 INC $0400,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $400-$4FF
|-
|<pre>FE 00 05 INC $0500,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $500-$5FF
|-
|<pre>FE 00 06 INC $0600,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $600-$6FF
|-
|<pre>FE 00 07 INC $0700,X
36 36    ROL $36,X \ &times; 7
76 36    ROR $36,X /
36 36... ROL $36,X&times; 9</pre>||Clobbers Z&N; and requires writable $700-$7FF
|-
!colspan="2"|73 bytes
|-
|<pre>18  ... CLC      &times; 71
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 71
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 71
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 71
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|74 bytes
|-
|<pre>EA  ... NOP      &times; 71
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 146 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #119
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #112
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #112
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>04 04    NOP $04
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
|<pre>48      PHA
08      PHP
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48      PHA
08      PHP
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>8C      TXA
A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A6 A6    LDX $A6
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A4 A4    LDY $A4
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #105
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
68      PLA</pre>||Clobbers Z&N, C, V, and D; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
28      PLP</pre>||Clobbers A; requires @zptemp; and writes in stack
|-
|<pre>48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
68      PLA</pre>||Clobbers Z&N, C, V, and D; requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 11    LDA #17
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|49 bytes
|-
|<pre>EA      NOP
36 36    ROL $36,X \ &times; 12
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|73 bytes
|-
|<pre>EA  ... NOP      &times; 73</pre>||No requirements
|-
|}
 
 
=== 147 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #120
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp
|-
|<pre>F6 F6    INC $F6,X
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|<pre>48      PHA
A9      LDA #113
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #113
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|<pre>EA      NOP
A2 10    LDX #16
68      PLA
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>EA      NOP
A0 10    LDY #16
68      PLA
88      DEY
D0 FC    BNE *-2</pre>||Clobbers A, Y, S, and Z&N
|-
|<pre>68      PLA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
|-
|<pre>68      PLA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 1B    LDY #27
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #106
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|74 bytes
|-
|<pre>18  ... CLC      &times; 72
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 72
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 72
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 72
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|75 bytes
|-
|<pre>EA  ... NOP      &times; 72
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 148 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #121
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>A2 15    LDX #21
EA      NOP
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>A0 15    LDY #21
EA      NOP
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
|<pre>18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A      TXS ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V
|-
!colspan="2"|7 bytes
|-
|<pre>38      SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #114
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #114
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #107
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48      PHA
08      PHP
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
EA      NOP
08      PHP
28      PLP
30 F9    BMI *-5
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
EA      NOP
08      PHP
28      PLP
30 F9    BMI *-5
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>00 00    BRK 0
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
8C      TXA
A2 11    LDX #17
C5 C5    CMP $C5
CA      DEX
D0 FB    BNE *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 11    LDX #17
24 24    BIT $24
CA      DEX
D0 FB    BNE *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N, and V; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 11    LDX #17
85 xx    STA @zptemp
CA      DEX
D0 FB    BNE *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 11    LDX #17
04 04    NOP $04
CA      DEX
D0 FB    BNE *-3
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 13    LDX #19
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A      ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
68      PLA
28      PLP</pre>||Requires @rts12, and @rts14; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
48      PHA
8C      TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Clobbers S; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
8C      TXA
A2 19    LDX #25
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|74 bytes
|-
|<pre>EA  ... NOP      &times; 74</pre>||No requirements
|-
|}
 
 
=== 149 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #122
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>48      PHA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48      PHA
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>A6 A6    LDX $A6
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #115
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #115
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>F6 F6    INC $F6,X
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V; and requires @zptemp, support for unofficial opcodes, and writable $00-$FF
|-
|<pre>F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 18    LDY #24 ;hides 'CLC'
EA      NOP
88  ... DEY      &times; 2
10 FA    BPL *-4
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #108
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|75 bytes
|-
|<pre>18  ... CLC      &times; 73
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 73
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 73
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 73
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|76 bytes
|-
|<pre>EA  ... NOP      &times; 73
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 150 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #123
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>68      PLA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>68      PLA
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 2
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #116
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #116
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>EA      NOP
08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA      NOP
08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #109
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP
F6 F6    INC $F6,X
28      PLP
D0 F9    BNE *-5
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 13    LDA #19
EA      NOP
E9 01    SBC #1
D0 FA    BNE *-4
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|60 bytes
|-
|<pre>26 26    ROL $26  \ &times; 15
66 26    ROR $26  /</pre>||Clobbers Z&N
|-
!colspan="2"|75 bytes
|-
|<pre>EA  ... NOP      &times; 75</pre>||No requirements
|-
|}
 
 
=== 151 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1E    LDY #30
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #124
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|<pre>48      PHA
A9      LDA #117
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #117
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>48      PHA
18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A      TXS ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
D0 F9    BNE *-5</pre>||Clobbers A, Z&N, and C; and writes in stack
|-
|<pre>A5 A5    LDA $A5
18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A      TXS ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V
|-
|<pre>48      PHA
08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48      PHA
08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
38      SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A6 A6    LDX $A6
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A4 A4    LDY $A4
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #110
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|10 bytes
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>F6 F6    INC $F6,X
48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
8C      TXA
A2 1A    LDX #26
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|76 bytes
|-
|<pre>18  ... CLC      &times; 74
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 74
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 74
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 74
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|77 bytes
|-
|<pre>EA  ... NOP      &times; 74
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 152 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9      LDA #125
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X</pre>||Clobbers X, and Z&N; and requires @zptemp
|-
|<pre>F6 F6    INC $F6,X
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
|-
|<pre>48      PHA
A9      LDA #118
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #118
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>68      PLA
18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A      TXS ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V
|-
|<pre>48  ... PHA      &times; 2
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|<pre>EA      NOP
68      PLA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>EA      NOP
68      PLA
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 15    LDX #21
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA  ... NOP      &times; 3
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #111
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|76 bytes
|-
|<pre>EA  ... NOP      &times; 76</pre>||No requirements
|-
|}
 
 
=== 153 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A2 EA    LDX #234 ;hides 'NOP'
E8      INX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>A0 EA    LDY #234 ;hides 'NOP'
C8      INY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
|<pre>A9      LDA #126
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|6 bytes
|-
|<pre>18      CLC
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08      PHP ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>38      SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #119
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #119
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|<pre>48      PHA
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #112
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48      PHA
08      PHP
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>04 04    NOP $04
48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>04 04    NOP $04
08      PHP
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires support for unofficial opcodes; and writes in stack
|-
|<pre>C5 C5    CMP $C5
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>08      PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, C, and V; and writes in stack
|-
|<pre>48      PHA
08      PHP
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
8C      TXA
A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
68      PLA
28      PLP</pre>||Requires @zptemp; and writes in stack
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8      SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 11    LDA #17
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|77 bytes
|-
|<pre>18  ... CLC      &times; 75
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 75
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 75
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 75
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|78 bytes
|-
|<pre>EA  ... NOP      &times; 75
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 154 cycles ===
{| class="wikitable testtable"
!colspan="2"|6 bytes
|-
|<pre>EA      NOP
A9      LDA #125
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
|-
|<pre>48      PHA
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48      PHA
A0 1E    LDY #30
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
|<pre>A2 11    LDX #17
68      PLA
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>A0 11    LDY #17
68      PLA
88      DEY
D0 FC    BNE *-2</pre>||Clobbers A, Y, S, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>A6 A6    LDX $A6
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 1E    LDY #30
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #120
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #120
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
00 00... BRK 0    &times; 2
10 F9    BPL *-5</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>68      PLA
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>EA  ... NOP      &times; 2
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #113
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>EA      NOP
48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA      NOP
08      PHP
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A0 1C    LDY #28
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|77 bytes
|-
|<pre>EA  ... NOP      &times; 77</pre>||No requirements
|-
|}
 
 
=== 155 cycles ===
{| class="wikitable testtable"
!colspan="2"|6 bytes
|-
|<pre>A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
EA      NOP
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>A2 16    LDX #22
EA      NOP
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>A0 16    LDY #22
EA      NOP
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>48      PHA
A9      LDA #121
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #121
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>08      PHP
A2 15    LDX #21
EA      NOP
CA      DEX
D0 FC    BNE *-2
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 15    LDY #21
EA      NOP
88      DEY
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #114
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>E6 xx    INC @zptemp
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>48      PHA
08      PHP
48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Clobbers S; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
48      PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A      ASL A ;first loop only
EA      NOP
08      PHP
28      PLP
30 F9    BMI *-5
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|78 bytes
|-
|<pre>18  ... CLC      &times; 76
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 76
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 76
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 76
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|79 bytes
|-
|<pre>EA  ... NOP      &times; 76
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 156 cycles ===
{| class="wikitable testtable"
!colspan="2"|5 bytes
|-
|<pre>A9 69    LDA #$69 ;hides 'ADC #$38'
38      SEC ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>A2 1F    LDX #31
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A0 1F    LDY #31
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>48      PHA
A9      LDA #122
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #122
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48      PHA
08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48      PHA
08      PHP
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
A6 A6    LDX $A6
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A4 A4    LDY $A4
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX</pre>||Clobbers A, and Z&N; and requires @zptemp
|-
|<pre>08      PHP
48      PHA
A9      LDA #115
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>EA      NOP
68      PLA
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N
|-
!colspan="2"|10 bytes
|-
|<pre>EA  ... NOP      &times; 3
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>F6 F6    INC $F6,X
48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers Z&N, C, and V; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
|-
|<pre>F6 F6    INC $F6,X
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, and C; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA</pre>||Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
28      PLP</pre>||Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA</pre>||Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A, and S; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>EA  ... NOP      &times; 2
48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA      NOP
08      PHP
48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|52 bytes
|-
|<pre>36 36    ROL $36,X \ &times; 13
76 36    ROR $36,X /</pre>||Clobbers Z&N
|-
!colspan="2"|78 bytes
|-
|<pre>EA  ... NOP      &times; 78</pre>||No requirements
|-
|}
 
 
=== 157 cycles ===
{| class="wikitable testtable"
!colspan="2"|6 bytes
|-
|<pre>68      PLA
A2 EA    LDX #234 ;hides 'NOP'
E8      INX
D0 FC    BNE *-2</pre>||Clobbers A, X, S, and Z&N
|-
|<pre>68      PLA
A0 EA    LDY #234 ;hides 'NOP'
C8      INY
D0 FC    BNE *-2</pre>||Clobbers A, Y, S, and Z&N
|-
|<pre>68      PLA
A9      LDA #126
20 xx xx JSR delay_a_25_clocks</pre>||Clobbers A, S, Z&N, C, and V; and requires delay_a_25_clocks
|-
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 EA    LDX #234 ;hides 'NOP'
E8      INX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>EA      NOP
A2 16    LDX #22
EA      NOP
CA      DEX
D0 FC    BNE *-2</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 16    LDY #22
EA      NOP
88      DEY
D0 FC    BNE *-2</pre>||Clobbers Y, and Z&N
|-
|<pre>48      PHA
A9      LDA #123
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #123
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #116
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>08      PHP
48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
38      SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|79 bytes
|-
|<pre>18  ... CLC      &times; 77
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 77
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 77
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 77
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|80 bytes
|-
|<pre>EA  ... NOP      &times; 77
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 158 cycles ===
{| class="wikitable testtable"
!colspan="2"|6 bytes
|-
|<pre>18      CLC
A9 69    LDA #$69 ;hides 'ADC #$38'
38      SEC ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>EA      NOP
A2 1F    LDX #31
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>EA      NOP
A0 1F    LDY #31
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
!colspan="2"|7 bytes
|-
|<pre>08      PHP
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 1E    LDY #30
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #124
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #124
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, S, and Z&N; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>A5 A5    LDA $A5
8C      TXA
A2 1E    LDX #30
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
|<pre>08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
28      PLP</pre>||Clobbers A; requires @rts12, and @rts14; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #117
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
D0 F9    BNE *-5
68      PLA</pre>||Clobbers Z&N, and C; and writes in stack
|-
|<pre>08      PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08      PHP      \ &times; 2
28      PLP      /
D0 F9    BNE *-5
28      PLP</pre>||Clobbers A; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA      TAX
68      PLA</pre>||Clobbers Z&N; requires @zptemp; and writes in stack
|-
|<pre>48  ... PHA      &times; 3
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers S, and Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>EA  ... NOP      &times; 3
48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
48      PHA
38      SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Clobbers S; requires support for unofficial opcodes; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>EA  ... NOP      &times; 2
08      PHP
48      PHA
8C      TXA
A2 1B    LDX #27
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|79 bytes
|-
|<pre>EA  ... NOP      &times; 79</pre>||No requirements
|-
|}
 
 
=== 159 cycles ===
{| class="wikitable testtable"
!colspan="2"|6 bytes
|-
|<pre>48      PHA
A9 69    LDA #$69 ;hides 'ADC #$38'
38      SEC ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, S, Z&N, C, and V; and writes in stack
|-
|<pre>48      PHA
A2 1F    LDX #31
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, S, and Z&N; and writes in stack
|-
|<pre>48      PHA
A0 1F    LDY #31
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, S, and Z&N; and writes in stack
|-
!colspan="2"|7 bytes
|-
|<pre>A5 A5    LDA $A5
A9 69    LDA #$69 ;hides 'ADC #$38'
38      SEC ;first loop only
D0 FC    BNE *-2</pre>||Clobbers A, Z&N, C, and V
|-
|<pre>A6 A6    LDX $A6
A2 1F    LDX #31
CA      DEX
D0 FD    BNE *-1</pre>||Clobbers X, and Z&N
|-
|<pre>A4 A4    LDY $A4
A0 1F    LDY #31
88      DEY
D0 FD    BNE *-1</pre>||Clobbers Y, and Z&N
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
|-
|<pre>48      PHA
A9      LDA #125
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #125
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
|<pre>A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18      CLC
D0 FA    BNE *-4</pre>||Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|8 bytes
|-
|<pre>8C      TXA
A2 16    LDX #22
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX</pre>||Clobbers A, and Z&N
|-
!colspan="2"|9 bytes
|-
|<pre>08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28      PLP</pre>||Clobbers X; requires @zptemp; and writes in stack
|-
|<pre>08      PHP
F6 F6    INC $F6,X
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
|-
|<pre>08      PHP
48      PHA
A9      LDA #118
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X, and S; and writes in stack
|-
|<pre>48  ... PHA      &times; 2
08      PHP
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y, and S; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
8C      TXA
A2 15    LDX #21
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
|<pre>08      PHP
8C      TXA
A2 15    LDX #21
EA      NOP
CA      DEX
D0 FC    BNE *-2
AA      TAX
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>EA  ... NOP      &times; 3
08      PHP
A0 1D    LDY #29
88      DEY
D0 FD    BNE *-1
28      PLP</pre>||Clobbers Y; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 1C    LDX #28
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|80 bytes
|-
|<pre>18  ... CLC      &times; 78
90 00    BCC *+2</pre>||Clobbers C
|-
|<pre>B8  ... CLV      &times; 78
50 00    BVC *+2</pre>||Clobbers V
|-
|<pre>EA  ... NOP      &times; 78
85 xx    STA @zptemp</pre>||Requires @zptemp
|-
|<pre>EA  ... NOP      &times; 78
04 04    NOP $04</pre>||Requires support for unofficial opcodes
|-
!colspan="2"|81 bytes
|-
|<pre>EA  ... NOP      &times; 78
4C xx xx JMP *+3</pre>||Not relocatable code
|-
|}
 
 
=== 160 cycles ===
{| class="wikitable testtable"
!colspan="2"|7 bytes
|-
|<pre>8C      TXA
A2 1F    LDX #31
CA      DEX
D0 FD    BNE *-1
AA      TAX</pre>||Clobbers A, and Z&N
|-
|<pre>08      PHP
A2 EA    LDX #234 ;hides 'NOP'
E8      INX
D0 FC    BNE *-2
28      PLP</pre>||Clobbers X; and writes in stack
|-
|<pre>08      PHP
A0 EA    LDY #234 ;hides 'NOP'
C8      INY
D0 FC    BNE *-2
28      PLP</pre>||Clobbers Y; and writes in stack
|-
|<pre>48      PHA
A9      LDA #126
20 xx xx JSR delay_a_25_clocks
68      PLA</pre>||Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
|-
|<pre>08      PHP
A9      LDA #126
20 xx xx JSR delay_a_25_clocks
28      PLP</pre>||Clobbers A; requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|9 bytes
|-
|<pre>48      PHA
38      SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3
68      PLA</pre>||Clobbers Z&N, C, and V; and writes in stack
|-
|<pre>08      PHP
38      SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3
28      PLP</pre>||Clobbers A; and writes in stack
|-
|<pre>A2 15    LDX #21
EA      NOP
CA      DEX
10 FC    BPL *-2
9D 03 1F STA $1F03,X ; Reads $702, writes $2002</pre>||Clobbers X, and Z&N
|-
|<pre>A0 15    LDY #21
EA      NOP
88      DEY
10 FC    BPL *-2
99 03 1F STA $1F03,Y ; Reads $702, writes $2002</pre>||Clobbers Y, and Z&N
|-
|<pre>08      PHP
48      PHA
A9      LDA #119
20 xx xx JSR delay_a_25_clocks
68      PLA
28      PLP</pre>||Requires delay_a_25_clocks; and writes in stack
|-
!colspan="2"|10 bytes
|-
|<pre>48      PHA
18      CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
68      PLA</pre>||Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
|-
!colspan="2"|11 bytes
|-
|<pre>48      PHA
A5 A5    LDA $A5
8C      TXA
A2 1D    LDX #29
CA      DEX
D0 FD    BNE *-1
AA      TAX
68      PLA</pre>||Clobbers Z&N; and writes in stack
|-
!colspan="2"|12 bytes
|-
|<pre>08      PHP
04 04    NOP $04
48      PHA
18      CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A      NOP ;first loop only
D0 FC    BNE *-2
68      PLA
28      PLP</pre>||Requires support for unofficial opcodes; and writes in stack
|-
|<pre>08      PHP
C5 C5    CMP $C5
48      PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68      PLA
28      PLP</pre>||Requires dummy interrupt handler; and writes in stack
|-
!colspan="2"|13 bytes
|-
|<pre>08      PHP
48      PHA
8C      TXA
A2 18    LDX #24 ;hides 'CLC'
EA      NOP
CA  ... DEX      &times; 2
10 FA    BPL *-4
AA      TAX
68      PLA
28      PLP</pre>||Writes in stack
|-
!colspan="2"|64 bytes
|-
|<pre>26 26    ROL $26  \ &times; 16
66 26    ROR $26  /</pre>||Clobbers Z&N
|-
!colspan="2"|80 bytes
|-
|<pre>EA  ... NOP      &times; 80</pre>||No requirements
|-
|-
|}
|}

Revision as of 15:17, 19 March 2016

Delay code

Shortest possible CPU code that creates N cycles of delay, depending on constraints.

All code samples are written for CA65.

Assumptions:

  • 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. Code samples where an interrupt could cause data corruption are separately indicated.

It is possible to verify on compile time that no page wrap occurs, by replacing all branches with these macros:

.macro branch_check opc, dest
    opc dest
    .assert >* = >(dest), warning, "branch_check: failed, crosses page"
.endmacro
.macro Jcc dest
        branch_check bcc, dest
.endmacro
.macro Jcs dest
        branch_check bcs, dest
.endmacro
.macro Jeq dest
        branch_check beq, dest
.endmacro
.macro Jne dest
        branch_check bne, dest
.endmacro
.macro Jmi dest
        branch_check bmi, dest
.endmacro
.macro Jpl dest
        branch_check bpl, dest
.endmacro
.macro Jvc dest
        branch_check bvc, dest
.endmacro
.macro Jvs dest
        branch_check bvs, dest
.endmacro

It is permissible for DMA to steal cycles during the loops. If you are expecting that to happen, you have to manually adjust the delay cycle count (and it is in fact possible to do so) in order to get the correct delay.

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 RTI.
  • @rts12 means you know a memory address that contains byte $60 (RTS).
  • @rts14 means you know a memory address that contains a harmless 2-cycle instruction that fits your constraints (such as CLC, LDA #0, or NOP), followed by RTS.
  • @rts15 means you know a memory address that contains a JMP that jumps to another location that contains RTS. Alternatively, it means you know a memory address that contains a harmless 3-cycle instruction that fits your constraints (such as LDA $00), followed by RTS.
  • delay_a_25_clocks, delay_256a_16_clocks, delay_256a_x_33_clocks, delay_256a_x_31_clocks, and delay_256x_a_30_clocks are defined at Delay code.
  • "Unsafe for interrupts" means that even though the S register is not clobbered, data corruption will occur if an interrupt/NMI happens in the middle of the delay code.

{{#css:

 .testtable td{padding:2px} .testtable td pre{padding:2px;margin:2px}

}}


2 cycles

1 bytes
EA       NOP
No requirements
  • All instructions cost at least 2 cycles. There is no way to do 1 cycle of delay (though −1 cycles may sometimes appear in branch cost calculations).


3 cycles

1 bytes
48       PHA
Clobbers S; and writes in stack
2 bytes
C5 C5    CMP $C5
Clobbers Z&N, and C
24 24    BIT $24
Clobbers Z&N, and V
A5 A5    LDA $A5
Clobbers A, and Z&N
A6 A6    LDX $A6
Clobbers X, and Z&N
A4 A4    LDY $A4
Clobbers Y, and Z&N
85 xx    STA @zptemp
Requires @zptemp
04 04    NOP $04
Requires support for unofficial opcodes
3 bytes
4C xx xx JMP *+3
Not relocatable code
  • 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 JSR instructions, as chances are the JSR target is outside the code being relocated.


4 cycles

1 bytes
68       PLA
Clobbers A, S, and Z&N
2 bytes
EA   ... NOP      × 2
No requirements
  • zp-indexed modes such as LDA $00,X also do 4 cycles, but having side effects, these two-byte instructions are inferior to a simple 2 × NOP.
  • There is also an unofficial opcode NOP $00,X (34 00), but there is no reason to use this instruction when the official equivalent has the same performance.


5 cycles

2 bytes
E6 xx    INC @zptemp
Clobbers Z&N; and requires @zptemp
EA       NOP
48       PHA
Clobbers S; and writes in stack
3 bytes
18       CLC
90 00    BCC *+2
Clobbers C
B8       CLV
50 00    BVC *+2
Clobbers V
EA       NOP
A5 A5    LDA $A5
Clobbers A, and Z&N
EA       NOP
A6 A6    LDX $A6
Clobbers X, and Z&N
EA       NOP
A4 A4    LDY $A4
Clobbers Y, and Z&N
EA       NOP
85 xx    STA @zptemp
Requires @zptemp
EA       NOP
04 04    NOP $04
Requires support for unofficial opcodes
4 bytes
EA       NOP
4C xx xx JMP *+3
Not relocatable code
  • abs-indexed modes such as LDA $1234,X 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

2 bytes
F6 F6    INC $F6,X
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
48   ... PHA      × 2
Clobbers S; and writes in stack
EA       NOP
68       PLA
Clobbers A, S, and Z&N
3 bytes
EA   ... NOP      × 3
No requirements
  • zp-indexed RMW instructions such as INC @zptemp,X 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 LDA ($00,X) 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 LDA ($00),Y 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 INC $4018 do 6 cycles, but weighing 3 bytes with side-effects it would be inferior to 3 × NOP.


7 cycles

2 bytes
08       PHP
28       PLP
Writes in stack
68       PLA
48       PHA
Clobbers A, and Z&N
3 bytes
EA       NOP
E6 xx    INC @zptemp
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
Clobbers Z&N; and requires writable $700-$7FF
4 bytes
18   ... CLC      × 2
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 2
50 00    BVC *+2
Clobbers V
A6 A6    LDX $A6
EA   ... NOP      × 2
Clobbers X, and Z&N
A4 A4    LDY $A4
EA   ... NOP      × 2
Clobbers Y, and Z&N
85 xx    STA @zptemp
EA   ... NOP      × 2
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 2
Requires support for unofficial opcodes
5 bytes
4C xx xx JMP *+3
EA   ... NOP      × 2
Not relocatable code
  • PHP-PLP is very efficient for 7 cycles of delay, but it does modify stack contents. S register remains unchanged though.
  • PLA-PHA does not overwrite any bytes in stack. It just writes back the same byte. But it does clobber A and Z+N.
  • abs-indexed RMW instructions such as INC abs,X do 7 cycles. We only do this either we know the value of X, or when the entire 256-byte page can be safely overwritten with random data.


8 cycles

2 bytes
68   ... PLA      × 2
Clobbers A, S, and Z&N
3 bytes
BA       TSX
68       PLA
9A       TXS
Clobbers A, X, and Z&N; and unsafe for interrupts
EA       NOP
F6 F6    INC $F6,X
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
EA       NOP
48   ... PHA      × 2
Clobbers S; and writes in stack
4 bytes
EA   ... NOP      × 4
No requirements
  • Unofficial ix and iy RMW instructions such as SLO ($00,X) or SLO ($00),Y 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.


9 cycles

3 bytes
EA       NOP
08       PHP
28       PLP
Writes in stack
EA       NOP
68       PLA
48       PHA
Clobbers A, and Z&N
4 bytes
A2 AE    LDX #$AE  ;hides 'LDX $FDD0'
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 AC    LDY #$AC  ;hides 'LDY $FDD0'
D0 FD    BNE *-1
Clobbers Y, and Z&N
EA   ... NOP      × 2
E6 xx    INC @zptemp
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
Clobbers Z&N; and requires writable $700-$7FF
5 bytes
18   ... CLC      × 3
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 3
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 3
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 3
Requires support for unofficial opcodes
6 bytes
4C xx xx JMP *+3
EA   ... NOP      × 3
Not relocatable code
  • 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.


10 cycles

3 bytes
48       PHA
08       PHP
28       PLP
Clobbers S; and writes in stack
EA       NOP
68   ... PLA      × 2
Clobbers A, S, and Z&N
4 bytes
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N
08       PHP
24 24    BIT $24
28       PLP
Writes in stack
5 bytes
EA   ... NOP      × 5
No requirements
  • The ROL-ROR sequence preserves the original value of the memory address. Carry is also preserved.


11 cycles

3 bytes
68   ... PLA      × 2
48       PHA
Clobbers A, S, and Z&N
4 bytes
EA   ... NOP      × 2
08       PHP
28       PLP
Writes in stack
EA   ... NOP      × 2
68       PLA
48       PHA
Clobbers A, and Z&N
E6 xx    INC @zptemp
F6 F6    INC $F6,X
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
5 bytes
A2 02    LDX #2
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 02    LDY #2
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
E6 xx    INC @zptemp
EA   ... NOP      × 3
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 2
FE 00 02 INC $0200,X
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 2
FE 00 03 INC $0300,X
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 2
FE 00 04 INC $0400,X
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 2
FE 00 05 INC $0500,X
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 2
FE 00 06 INC $0600,X
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 2
FE 00 07 INC $0700,X
Clobbers Z&N; and requires writable $700-$7FF
6 bytes
18   ... CLC      × 4
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 4
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 4
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 4
Requires support for unofficial opcodes
7 bytes
4C xx xx JMP *+3
EA   ... NOP      × 4
Not relocatable code


12 cycles

3 bytes
20 xx xx JSR @rts12
Requires @rts12; and writes in stack
68   ... PLA      × 3
Clobbers A, S, and Z&N
4 bytes
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N
08       PHP
E6 xx    INC @zptemp
28       PLP
Requires @zptemp; and writes in stack
48   ... PHA      × 4
Clobbers S; and writes in stack
5 bytes
08       PHP
18       CLC
90 00    BCC *+2
28       PLP
Writes in stack
6 bytes
EA   ... NOP      × 6
No requirements
  • JSR-RTS 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, ROL-ROR does not have side effects (as long as an interrupt does not happen in the middle), except for Z+N.


13 cycles

2 bytes
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
4 bytes
08       PHP
F6 F6    INC $F6,X
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
F6 F6    INC $F6,X
68       PLA
48       PHA
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
48   ... PHA      × 2
08       PHP
28       PLP
Clobbers S; and writes in stack
EA       NOP
68   ... PLA      × 2
48       PHA
Clobbers A, S, and Z&N
5 bytes
EA   ... NOP      × 3
08       PHP
28       PLP
Writes in stack
EA   ... NOP      × 3
68       PLA
48       PHA
Clobbers A, and Z&N
EA       NOP
E6 xx    INC @zptemp
F6 F6    INC $F6,X
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
6 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N, and V
A6 A6    LDX $A6
26 26    ROL $26
66 26    ROR $26
Clobbers X, and Z&N
A4 A4    LDY $A4
26 26    ROL $26
66 26    ROR $26
Clobbers Y, and Z&N
85 xx    STA @zptemp
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 3
FE 00 02 INC $0200,X
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 3
FE 00 03 INC $0300,X
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 3
FE 00 04 INC $0400,X
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 3
FE 00 05 INC $0500,X
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 3
FE 00 06 INC $0600,X
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 3
FE 00 07 INC $0700,X
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires support for unofficial opcodes
7 bytes
18   ... CLC      × 5
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 5
50 00    BVC *+2
Clobbers V
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and not relocatable code
85 xx    STA @zptemp
EA   ... NOP      × 5
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 5
Requires support for unofficial opcodes
8 bytes
4C xx xx JMP *+3
EA   ... NOP      × 5
Not relocatable code


14 cycles

3 bytes
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
4 bytes
08       PHP       \ × 2
28       PLP       /
Writes in stack
68       PLA       \ × 2
48       PHA       /
Clobbers A, and Z&N
5 bytes
EA       NOP
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N
7 bytes
EA   ... NOP      × 7
No requirements


15 cycles

3 bytes
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
EA       NOP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
4 bytes
68       PLA
48       PHA
68   ... PLA      × 2
Clobbers A, S, and Z&N
48       PHA
20 xx xx JSR @rts12
Clobbers S; requires @rts12; and writes in stack
5 bytes
08       PHP
BA       TSX
28       PLP
9A       TXS
28       PLP
Clobbers X; and writes in stack
68       PLA
48       PHA
BA       TSX
68       PLA
9A       TXS
Clobbers A, X, and Z&N; and unsafe for interrupts
EA       NOP
08       PHP
F6 F6    INC $F6,X
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
EA       NOP
F6 F6    INC $F6,X
68       PLA
48       PHA
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
C5 C5    CMP $C5
20 xx xx JSR @rts12
Clobbers Z&N, and C; requires @rts12; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts12
Clobbers Z&N, and V; requires @rts12; and writes in stack
A5 A5    LDA $A5
20 xx xx JSR @rts12
Clobbers A, and Z&N; requires @rts12; and writes in stack
A4 A4    LDY $A4
20 xx xx JSR @rts12
Clobbers Y, and Z&N; requires @rts12; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts12
Requires @zptemp, and @rts12; and writes in stack
04 04    NOP $04
20 xx xx JSR @rts12
Requires @rts12, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 5
Clobbers S; and writes in stack
6 bytes
C5 C5    CMP $C5
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and V
08       PHP
28       PLP
EA   ... NOP      × 4
Writes in stack
A5 A5    LDA $A5
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers A, and Z&N
A6 A6    LDX $A6
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers X, and Z&N
A4 A4    LDY $A4
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Y, and Z&N
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires @zptemp
04 04    NOP $04
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires support for unofficial opcodes
7 bytes
4C xx xx JMP *+3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and not relocatable code
FE 00 02 INC $0200,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
EA   ... NOP      × 4
Clobbers Z&N; and requires writable $700-$7FF
8 bytes
18   ... CLC      × 6
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 6
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 6
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 6
Requires support for unofficial opcodes
9 bytes
4C xx xx JMP *+3
EA   ... NOP      × 6
Not relocatable code


16 cycles

3 bytes
48       PHA
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
4 bytes
EA       NOP
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
C5 C5    CMP $C5
00 00    BRK 0
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
24 24    BIT $24
00 00    BRK 0
Clobbers Z&N, and V; requires dummy interrupt handler; and writes in stack
A5 A5    LDA $A5
00 00    BRK 0
Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
A6 A6    LDX $A6
00 00    BRK 0
Clobbers X, and Z&N; requires dummy interrupt handler; and writes in stack
A4 A4    LDY $A4
00 00    BRK 0
Clobbers Y, and Z&N; requires dummy interrupt handler; and writes in stack
85 xx    STA @zptemp
00 00    BRK 0
Requires @zptemp, and dummy interrupt handler; and writes in stack
04 04    NOP $04
00 00    BRK 0
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
68   ... PLA      × 4
Clobbers A, S, and Z&N
5 bytes
EA       NOP
08       PHP       \ × 2
28       PLP       /
Writes in stack
EA       NOP
68       PLA       \ × 2
48       PHA       /
Clobbers A, and Z&N
A2 03    LDX #3
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 03    LDY #3
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
6 bytes
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N
8 bytes
EA   ... NOP      × 8
No requirements


17 cycles

3 bytes
68       PLA
00 00    BRK 0
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
4 bytes
EA       NOP
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
EA   ... NOP      × 2
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
48       PHA
20 xx xx JSR @rts14
Clobbers S; requires @rts12, and @rts14; and writes in stack
5 bytes
E6 xx    INC @zptemp
20 xx xx JSR @rts12
Clobbers Z&N; requires @zptemp, and @rts12; and writes in stack
C5 C5    CMP $C5
20 xx xx JSR @rts14
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts14
Clobbers Z&N, and V; requires @rts12, and @rts14; and writes in stack
A5 A5    LDA $A5
20 xx xx JSR @rts14
Clobbers A, and Z&N; requires @rts12, and @rts14; and writes in stack
A6 A6    LDX $A6
20 xx xx JSR @rts14
Clobbers X, and Z&N; requires @rts12, and @rts14; and writes in stack
A4 A4    LDY $A4
20 xx xx JSR @rts14
Clobbers Y, and Z&N; requires @rts12, and @rts14; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts14
Requires @zptemp, @rts12, and @rts14; and writes in stack
04 04    NOP $04
20 xx xx JSR @rts14
Requires @rts12, @rts14, and support for unofficial opcodes; and writes in stack
48       PHA
08       PHP       \ × 2
28       PLP       /
Clobbers S; and writes in stack
EA       NOP
68       PLA
48       PHA
68   ... PLA      × 2
Clobbers A, S, and Z&N
6 bytes
08       PHP
26 26    ROL $26
66 26    ROR $26
28       PLP
Writes in stack
68       PLA
48       PHA
26 26    ROL $26
66 26    ROR $26
Clobbers A, and Z&N
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires @zptemp
7 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and V
EA       NOP
A6 A6    LDX $A6
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers X, and Z&N
EA       NOP
A4 A4    LDY $A4
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Y, and Z&N
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires support for unofficial opcodes
8 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and not relocatable code
9 bytes
18   ... CLC      × 7
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 7
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 7
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 7
Requires support for unofficial opcodes
10 bytes
4C xx xx JMP *+3
EA   ... NOP      × 7
Not relocatable code


18 cycles

4 bytes
E6 xx    INC @zptemp
00 00    BRK 0
Clobbers Z&N; requires @zptemp, and dummy interrupt handler; and writes in stack
48       PHA
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
68       PLA
20 xx xx JSR @rts14
Clobbers A, S, and Z&N; requires @rts12, and @rts14; and writes in stack
EA       NOP
48       PHA
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
5 bytes
F6 F6    INC $F6,X
20 xx xx JSR @rts12
Clobbers Z&N; requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
EA   ... NOP      × 2
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
C5 C5    CMP $C5
20 xx xx JSR @rts15
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts15
Clobbers Z&N, and V; requires @rts12, and @rts15; and writes in stack
A5 A5    LDA $A5
20 xx xx JSR @rts15
Clobbers A, and Z&N; requires @rts12, and @rts15; and writes in stack
A6 A6    LDX $A6
20 xx xx JSR @rts15
Clobbers X, and Z&N; requires @rts12, and @rts15; and writes in stack
A4 A4    LDY $A4
20 xx xx JSR @rts15
Clobbers Y, and Z&N; requires @rts12, and @rts15; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts15
Requires @zptemp, @rts12, and @rts15; and writes in stack
A9       LDA #0
20 xx xx JSR delay_256a_16_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks, and delay_256a_16_clocks
04 04    NOP $04
20 xx xx JSR @rts15
Requires @rts12, @rts15, and support for unofficial opcodes; and writes in stack
18       CLC
90 00    BCC *+2
00 00    BRK 0
Clobbers C; requires dummy interrupt handler; and writes in stack
B8       CLV
50 00    BVC *+2
00 00    BRK 0
Clobbers V; requires dummy interrupt handler; and writes in stack
EA       NOP
A5 A5    LDA $A5
00 00    BRK 0
Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
EA       NOP
A6 A6    LDX $A6
00 00    BRK 0
Clobbers X, and Z&N; requires dummy interrupt handler; and writes in stack
EA       NOP
A4 A4    LDY $A4
00 00    BRK 0
Clobbers Y, and Z&N; requires dummy interrupt handler; and writes in stack
EA       NOP
85 xx    STA @zptemp
00 00    BRK 0
Requires @zptemp, and dummy interrupt handler; and writes in stack
EA       NOP
04 04    NOP $04
00 00    BRK 0
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
EA       NOP
68   ... PLA      × 4
Clobbers A, S, and Z&N
48   ... PHA      × 2
20 xx xx JSR @rts12
Clobbers S; requires @rts12; and writes in stack
6 bytes
EA   ... NOP      × 2
08       PHP       \ × 2
28       PLP       /
Writes in stack
EA   ... NOP      × 2
68       PLA       \ × 2
48       PHA       /
Clobbers A, and Z&N
EA       NOP
A2 03    LDX #3
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 03    LDY #3
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
F6 F6... INC $F6,X× 3
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
7 bytes
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N
9 bytes
EA   ... NOP      × 9
No requirements


19 cycles

4 bytes
F6 F6    INC $F6,X
00 00    BRK 0
Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
68       PLA
20 xx xx JSR @rts15
Clobbers A, S, and Z&N; requires @rts12, and @rts15; and writes in stack
48   ... PHA      × 2
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
5 bytes
08       PHP
28       PLP
20 xx xx JSR @rts12
Requires @rts12; and writes in stack
EA   ... NOP      × 3
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
68       PLA
48       PHA
68   ... PLA      × 3
Clobbers A, S, and Z&N
6 bytes
08       PHP
36 36    ROL $36,X
76 36    ROR $36,X
28       PLP
Writes in stack
68       PLA
48       PHA
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers A, and Z&N
7 bytes
A6 A6    LDX $A6
A2 03    LDX #3
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 03    LDY #3
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $700-$7FF
8 bytes
C5 C5    CMP $C5
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and C
24 24    BIT $24
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and V
04 04    NOP $04
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires support for unofficial opcodes
9 bytes
4C xx xx JMP *+3
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and not relocatable code
10 bytes
18   ... CLC      × 8
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 8
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 8
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 8
Requires support for unofficial opcodes
11 bytes
4C xx xx JMP *+3
EA   ... NOP      × 8
Not relocatable code


20 cycles

4 bytes
08       PHP
28       PLP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
5 bytes
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C
E6 xx    INC @zptemp
20 xx xx JSR @rts15
Clobbers Z&N; requires @zptemp, @rts12, and @rts15; and writes in stack
F6 F6    INC $F6,X
20 xx xx JSR @rts14
Clobbers Z&N; requires @zptemp, @rts12, @rts14, and writable $00-$FF; and writes in stack
68   ... PLA      × 5
Clobbers A, S, and Z&N
48   ... PHA      × 2
20 xx xx JSR @rts14
Clobbers S; requires @rts12, and @rts14; and writes in stack
EA       NOP
48       PHA
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
6 bytes
BA       TSX
68   ... PLA      × 4
9A       TXS
Clobbers A, X, and Z&N; and unsafe for interrupts
08       PHP
48       PHA
F6 F6    INC $F6,X
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
F6 F6    INC $F6,X
68       PLA       \ × 2
48       PHA       /
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
EA   ... NOP      × 3
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
18       CLC
90 00    BCC *+2
20 xx xx JSR @rts15
Clobbers C; requires @rts12, and @rts15; and writes in stack
B8       CLV
50 00    BVC *+2
20 xx xx JSR @rts15
Clobbers V; requires @rts12, and @rts15; and writes in stack
EA       NOP
A5 A5    LDA $A5
20 xx xx JSR @rts15
Clobbers A, and Z&N; requires @rts12, and @rts15; and writes in stack
EA       NOP
A6 A6    LDX $A6
20 xx xx JSR @rts15
Clobbers X, and Z&N; requires @rts12, and @rts15; and writes in stack
EA       NOP
A4 A4    LDY $A4
20 xx xx JSR @rts15
Clobbers Y, and Z&N; requires @rts12, and @rts15; and writes in stack
EA       NOP
85 xx    STA @zptemp
20 xx xx JSR @rts15
Requires @zptemp, @rts12, and @rts15; and writes in stack
EA       NOP
04 04    NOP $04
20 xx xx JSR @rts15
Requires @rts12, @rts15, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP       \ × 2
28       PLP       /
Clobbers S; and writes in stack
7 bytes
EA   ... NOP      × 3
08       PHP       \ × 2
28       PLP       /
Writes in stack
8C       TXA
A2 03    LDX #3
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 03    LDX #3
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 03    LDY #3
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
EA       NOP
F6 F6... INC $F6,X× 3
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
8 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N
10 bytes
EA   ... NOP      × 10
No requirements


21 cycles

4 bytes
68   ... PLA      × 2
00 00    BRK 0
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
5 bytes
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
Clobbers A, Z&N, and C
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
28       PLP
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
F6 F6    INC $F6,X
20 xx xx JSR @rts15
Clobbers Z&N; requires @zptemp, @rts12, @rts15, and writable $00-$FF; and writes in stack
EA       NOP
F6 F6    INC $F6,X
00 00    BRK 0
Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
EA       NOP
48   ... PHA      × 2
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
6 bytes
08       PHP       \ × 3
28       PLP       /
Writes in stack
68       PLA       \ × 3
48       PHA       /
Clobbers A, and Z&N
8 bytes
EA   ... NOP      × 2
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $700-$7FF
9 bytes
C5 C5    CMP $C5
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and C
24 24    BIT $24
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and V
04 04    NOP $04
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires support for unofficial opcodes
10 bytes
4C xx xx JMP *+3
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and not relocatable code
11 bytes
18   ... CLC      × 9
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 9
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 9
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 9
Requires support for unofficial opcodes
12 bytes
4C xx xx JMP *+3
EA   ... NOP      × 9
Not relocatable code


22 cycles

5 bytes
08       PHP
28       PLP
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
EA       NOP
08       PHP
28       PLP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
68   ... PLA      × 2
20 xx xx JSR @rts14
Clobbers A, S, and Z&N; requires @rts12, and @rts14; and writes in stack
6 bytes
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C
A2 03    LDX #3
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 03    LDY #3
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
EA       NOP
F6 F6    INC $F6,X
20 xx xx JSR @rts14
Clobbers Z&N; requires @zptemp, @rts12, @rts14, and writable $00-$FF; and writes in stack
EA       NOP
68   ... PLA      × 5
Clobbers A, S, and Z&N
48       PHA
08       PHP
28       PLP
20 xx xx JSR @rts12
Clobbers S; requires @rts12; and writes in stack
7 bytes
08       PHP
BA       TSX
08       PHP
28   ... PLP      × 2
9A       TXS
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
48       PHA
F6 F6    INC $F6,X
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
EA       NOP
F6 F6    INC $F6,X
68       PLA       \ × 2
48       PHA       /
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
08       PHP
24 24    BIT $24
28       PLP
20 xx xx JSR @rts12
Requires @rts12; and writes in stack
48       PHA
08       PHP
36 36    ROL $36,X
76 36    ROR $36,X
28       PLP
Clobbers S; and writes in stack
8 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N
08       PHP
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
28       PLP
Writes in stack
11 bytes
EA   ... NOP      × 11
No requirements


23 cycles

5 bytes
A9 2A    LDA #$2A ;hides 'ROL A'
48       PHA
10 FC    BPL *-2
Clobbers A, S, Z&N, and C; and writes in stack
68   ... PLA      × 2
20 xx xx JSR @rts15
Clobbers A, S, and Z&N; requires @rts12, and @rts15; and writes in stack
48       PHA
08       PHP
28       PLP
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
6 bytes
18   ... CLC      × 2
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
Clobbers A, Z&N, and C
EA       NOP
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
EA       NOP
08       PHP
28       PLP
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
EA       NOP
F6 F6    INC $F6,X
20 xx xx JSR @rts15
Clobbers Z&N; requires @zptemp, @rts12, @rts15, and writable $00-$FF; and writes in stack
08       PHP
24 24    BIT $24
28       PLP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
68       PLA
48       PHA
68   ... PLA      × 4
Clobbers A, S, and Z&N
EA       NOP
48   ... PHA      × 2
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
7 bytes
EA       NOP
08       PHP       \ × 3
28       PLP       /
Writes in stack
EA       NOP
68       PLA       \ × 3
48       PHA       /
Clobbers A, and Z&N
8 bytes
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 3
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
9 bytes
E6 xx    INC @zptemp
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 2
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 2
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 2
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 2
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 2
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 2
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $700-$7FF
10 bytes
C5 C5    CMP $C5
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires support for unofficial opcodes
11 bytes
4C xx xx JMP *+3
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and not relocatable code
12 bytes
18   ... CLC      × 10
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 10
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 10
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 10
Requires support for unofficial opcodes
13 bytes
4C xx xx JMP *+3
EA   ... NOP      × 10
Not relocatable code


24 cycles

4 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C
5 bytes
48       PHA
68   ... PLA      × 2
00 00    BRK 0
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
6 bytes
20 xx xx JSR @rts12× 2
Requires @rts12; and writes in stack
EA   ... NOP      × 2
08       PHP
28       PLP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
68   ... PLA      × 6
Clobbers A, S, and Z&N
48       PHA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
08       PHP       \ × 3
28       PLP       /
Clobbers S; and writes in stack
8 bytes
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
08       PHP
48       PHA
26 26    ROL $26
66 26    ROR $26
68       PLA
28       PLP
Writes in stack
12 bytes
EA   ... NOP      × 12
No requirements


25 cycles

5 bytes
20 xx xx JSR @rts12
00 00    BRK 0
Requires dummy interrupt handler, and @rts12; and writes in stack
68   ... PLA      × 3
00 00    BRK 0
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
6 bytes
36 36    ROL $36,X
76 36    ROR $36,X
00 00    BRK 0
Clobbers Z&N; requires dummy interrupt handler; and writes in stack
08       PHP
E6 xx    INC @zptemp
28       PLP
00 00    BRK 0
Requires @zptemp, and dummy interrupt handler; and writes in stack
68       PLA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
Clobbers A, S, Z&N, and C
A2 03    LDX #3
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 03    LDY #3
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
68       PLA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
48       PHA
08       PHP
28       PLP
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
48       PHA
68   ... PLA      × 2
20 xx xx JSR @rts14
Clobbers A, S, and Z&N; requires @rts12, and @rts14; and writes in stack
48   ... PHA      × 4
00 00    BRK 0
Clobbers S; requires dummy interrupt handler; and writes in stack
7 bytes
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
20 xx xx JSR @rts12
08       PHP
F6 F6    INC $F6,X
28       PLP
Requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
EA   ... NOP      × 2
08       PHP
28       PLP
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
08       PHP
24 24    BIT $24
28       PLP
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
48       PHA
A9       LDA #0
20 xx xx JSR delay_256a_16_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks, and delay_256a_16_clocks; and writes in stack
08       PHP
A9       LDA #0
20 xx xx JSR delay_256a_16_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks, and delay_256a_16_clocks; and writes in stack
EA       NOP
08       PHP
24 24    BIT $24
28       PLP
00 00    BRK 0
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
08       PHP
28       PLP
20 xx xx JSR @rts12
Clobbers S; requires @rts12; and writes in stack
8 bytes
EA   ... NOP      × 2
08       PHP       \ × 3
28       PLP       /
Writes in stack
9 bytes
EA       NOP
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 3
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
10 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 3
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 3
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 3
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 3
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 3
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 3
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires support for unofficial opcodes
11 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and not relocatable code
13 bytes
18   ... CLC      × 11
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 11
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 11
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 11
Requires support for unofficial opcodes
14 bytes
4C xx xx JMP *+3
EA   ... NOP      × 11
Not relocatable code


26 cycles

4 bytes
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
5 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
6 bytes
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
48       PHA
68   ... PLA      × 2
20 xx xx JSR @rts15
Clobbers A, S, and Z&N; requires @rts12, and @rts15; and writes in stack
7 bytes
EA       NOP
20 xx xx JSR @rts12× 2
Requires @rts12; and writes in stack
EA       NOP
68   ... PLA      × 6
Clobbers A, S, and Z&N
8 bytes
08       PHP
48       PHA
36 36    ROL $36,X
76 36    ROR $36,X
68       PLA
28       PLP
Writes in stack
8C       TXA
A2 03    LDX #3
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
EA       NOP
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
13 bytes
EA   ... NOP      × 13
No requirements


27 cycles

5 bytes
A9       LDA #0
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
00 00    BRK 0
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, S, Z&N, and C; and writes in stack
6 bytes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C
20 xx xx JSR @rts12
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
00 00    BRK 0
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
7 bytes
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
08       PHP
F6 F6    INC $F6,X
28       PLP
20 xx xx JSR @rts14
Requires @zptemp, @rts12, @rts14, and writable $00-$FF; and writes in stack
A2 82    LDX #130 ;hides 'NOP #imm'
04 EA    NOP $EA ;hides 'NOP'
CA       DEX
30 FA    BMI *-4
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 82    LDY #130 ;hides 'NOP #imm'
04 EA    NOP $EA ;hides 'NOP'
88       DEY
30 FA    BMI *-4
Clobbers Y, and Z&N; and requires support for unofficial opcodes
68       PLA
48       PHA
68   ... PLA      × 5
Clobbers A, S, and Z&N
48   ... PHA      × 2
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
48       PHA
20 xx xx JSR @rts12× 2
Clobbers S; requires @rts12; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
F6 F6    INC $F6,X
28       PLP       \ × 2
08       PHP       /
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts12× 2
Clobbers Z&N, and V; requires @rts12; and writes in stack
20 xx xx JSR @rts12
08       PHP
BA       TSX
28       PLP
9A       TXS
28       PLP
Clobbers X; requires @rts12; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts12× 2
Requires @zptemp, and @rts12; and writes in stack
EA   ... NOP      × 3
08       PHP
28       PLP
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
04 04    NOP $04
20 xx xx JSR @rts12× 2
Requires @rts12, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP       \ × 3
28       PLP       /
Clobbers S; and writes in stack
9 bytes
08       PHP
48       PHA
A9 6A    LDA #$6A ;hides 'ROR A'
38       SEC
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
10 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires @zptemp
04 04    NOP $04
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
11 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
FE 00 02 INC $0200,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $700-$7FF
14 bytes
18   ... CLC      × 12
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 12
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 12
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 12
Requires support for unofficial opcodes
15 bytes
4C xx xx JMP *+3
EA   ... NOP      × 12
Not relocatable code


28 cycles

5 bytes
A9       LDA #1
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
EA       NOP
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, S, Z&N, and C
6 bytes
EA   ... NOP      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C
EA       NOP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
7 bytes
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
F6 F6    INC $F6,X
28       PLP
20 xx xx JSR @rts15
Requires @zptemp, @rts12, @rts15, and writable $00-$FF; and writes in stack
68   ... PLA      × 7
Clobbers A, S, and Z&N
48   ... PHA      × 2
08       PHP
28       PLP
20 xx xx JSR @rts15
Clobbers S; requires @rts12, and @rts15; and writes in stack
8 bytes
08       PHP       \ × 4
28       PLP       /
Writes in stack
68       PLA       \ × 4
48       PHA       /
Clobbers A, and Z&N
10 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
14 bytes
EA   ... NOP      × 14
No requirements


29 cycles

5 bytes
A9       LDA #2
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
48       PHA
00 00... BRK 0    × 2
Clobbers S; requires dummy interrupt handler; and writes in stack
6 bytes
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
90 FC    BCC *-2
Clobbers A, Z&N, and C
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 04    LDY #4
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
20 xx xx JSR @rts14
20 xx xx JSR @rts15
Requires @rts12, @rts14, and @rts15; and writes in stack
C5 C5    CMP $C5
00 00... BRK 0    × 2
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
24 24    BIT $24
00 00... BRK 0    × 2
Clobbers Z&N, and V; requires dummy interrupt handler; and writes in stack
A5 A5    LDA $A5
00 00... BRK 0    × 2
Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
85 xx    STA @zptemp
00 00... BRK 0    × 2
Requires @zptemp, and dummy interrupt handler; and writes in stack
EA       NOP
00 00    BRK 0
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
04 04    NOP $04
00 00... BRK 0    × 2
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
7 bytes
EA       NOP
20 xx xx JSR @rts12
20 xx xx JSR @rts15
Requires @rts12, and @rts15; and writes in stack
EA       NOP
00 00    BRK 0
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
48       PHA
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Clobbers S; requires @rts12, and @rts14; and writes in stack
8 bytes
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 03    LDX #3
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 03    LDY #3
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
E6 xx    INC @zptemp
20 xx xx JSR @rts12× 2
Clobbers Z&N; requires @zptemp, and @rts12; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Clobbers Z&N, and V; requires @rts12, and @rts14; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Requires @zptemp, @rts12, and @rts14; and writes in stack
04 04    NOP $04
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Requires @rts12, @rts14, and support for unofficial opcodes; and writes in stack
68       PLA
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
EA       NOP
48       PHA
20 xx xx JSR @rts12× 2
Clobbers S; requires @rts12; and writes in stack
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA       NOP
08       PHP
F6 F6    INC $F6,X
28       PLP       \ × 2
08       PHP       /
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
20 xx xx JSR @rts12
08       PHP
26 26    ROL $26
66 26    ROR $26
28       PLP
Requires @rts12; and writes in stack
48       PHA
08       PHP
48       PHA
36 36    ROL $36,X
76 36    ROR $36,X
68       PLA
28       PLP
Clobbers S; and writes in stack
10 bytes
08       PHP
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
28       PLP
Writes in stack
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
11 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
12 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
15 bytes
18   ... CLC      × 13
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 13
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 13
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 13
Requires support for unofficial opcodes
16 bytes
4C xx xx JMP *+3
EA   ... NOP      × 13
Not relocatable code


30 cycles

5 bytes
A9       LDA #3
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
68       PLA
00 00... BRK 0    × 2
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
6 bytes
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
EA   ... NOP      × 2
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
EA       NOP
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, S, Z&N, and C
68       PLA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
EA       NOP
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
8 bytes
48       PHA
18   ... CLC      × 2
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18   ... CLC      × 2
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
F6 F6    INC $F6,X
20 xx xx JSR @rts12× 2
Clobbers Z&N; requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
20 xx xx JSR @rts12× 2
Clobbers S; requires @rts12; and writes in stack
9 bytes
08       PHP
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
10 bytes
F6 F6... INC $F6,X× 5
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
11 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
15 bytes
EA   ... NOP      × 15
No requirements


31 cycles

5 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
Clobbers A, Z&N, and C
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 06    LDY #6
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
6 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; and writes in stack
E6 xx    INC @zptemp
00 00... BRK 0    × 2
Clobbers Z&N; requires @zptemp, and dummy interrupt handler; and writes in stack
EA       NOP
48       PHA
00 00... BRK 0    × 2
Clobbers S; requires dummy interrupt handler; and writes in stack
7 bytes
EA       NOP
20 xx xx JSR @rts14
20 xx xx JSR @rts15
Requires @rts12, @rts14, and @rts15; and writes in stack
18       CLC
90 00    BCC *+2
00 00... BRK 0    × 2
Clobbers C; requires dummy interrupt handler; and writes in stack
B8       CLV
50 00    BVC *+2
00 00... BRK 0    × 2
Clobbers V; requires dummy interrupt handler; and writes in stack
EA       NOP
85 xx    STA @zptemp
00 00... BRK 0    × 2
Requires @zptemp, and dummy interrupt handler; and writes in stack
EA   ... NOP      × 2
00 00    BRK 0
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
EA       NOP
04 04    NOP $04
00 00... BRK 0    × 2
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48       PHA
20 xx xx JSR @rts14× 2
Clobbers S; requires @rts12, and @rts14; and writes in stack
8 bytes
08       PHP
28       PLP
20 xx xx JSR @rts12× 2
Requires @rts12; and writes in stack
EA   ... NOP      × 2
00 00    BRK 0
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
68       PLA
48       PHA
68   ... PLA      × 6
Clobbers A, S, and Z&N
48       PHA
08       PHP
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 04    LDY #4
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
8C       TXA
A2 82    LDX #130 ;hides 'NOP #imm'
04 EA    NOP $EA ;hides 'NOP'
CA       DEX
30 FA    BMI *-4
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
48       PHA
08       PHP       \ × 4
28       PLP       /
Clobbers S; and writes in stack
10 bytes
08       PHP
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
28       PLP
Writes in stack
68       PLA
48       PHA
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers A, and Z&N
11 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
12 bytes
EA   ... NOP      × 2
C5 C5    CMP $C5
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
EA   ... NOP      × 2
24 24    BIT $24
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
EA   ... NOP      × 2
04 04    NOP $04
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
13 bytes
EA   ... NOP      × 2
4C xx xx JMP *+3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
16 bytes
18   ... CLC      × 14
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 14
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 14
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 14
Requires support for unofficial opcodes
17 bytes
4C xx xx JMP *+3
EA   ... NOP      × 14
Not relocatable code


32 cycles

5 bytes
A9       LDA #5
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 05    LDX #5 ;hides 'ORA zp'
CA       DEX ;first loop only
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, and Z&N
A0 05    LDY #5 ;hides 'ORA zp'
88       DEY ;first loop only
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, and Z&N
F6 F6    INC $F6,X
00 00... BRK 0    × 2
Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
68   ... PLA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, S, Z&N, and C
48   ... PHA      × 2
00 00... BRK 0    × 2
Clobbers S; requires dummy interrupt handler; and writes in stack
7 bytes
A9 2A    LDA #$2A ;hides 'ROL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
Clobbers A, Z&N, and C
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
EA       NOP
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
A2 FA    LDX #250 ;hides 'NOP'
EA       NOP
E8   ... INX      × 2
D0 FA    BNE *-4
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 FA    LDY #250 ;hides 'NOP'
EA       NOP
C8   ... INY      × 2
D0 FA    BNE *-4
Clobbers Y, and Z&N; and requires support for unofficial opcodes
EA   ... NOP      × 3
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
68       PLA
20 xx xx JSR @rts14× 2
Clobbers A, S, and Z&N; requires @rts12, and @rts14; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
A6 A6    LDX $A6
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 04    LDY #4
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
EA   ... NOP      × 2
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 03    LDX #3
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 03    LDY #3
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
28       PLP
20 xx xx JSR @rts12
08       PHP
F6 F6    INC $F6,X
28       PLP
Requires @zptemp, @rts12, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #0
20 xx xx JSR delay_256a_16_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks, and delay_256a_16_clocks; and writes in stack
EA       NOP
48   ... PHA      × 2
20 xx xx JSR @rts12× 2
Clobbers S; requires @rts12; and writes in stack
10 bytes
08       PHP
48       PHA
18   ... CLC      × 2
A9 2A    LDA #$2A ;hides 'ROL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
11 bytes
EA       NOP
F6 F6... INC $F6,X× 5
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
12 bytes
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N
16 bytes
EA   ... NOP      × 16
No requirements


33 cycles

5 bytes
A9       LDA #6
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18   ... CLC      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
Clobbers A, Z&N, and C
EA       NOP
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 06    LDY #6
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
28       PLP
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
7 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
20 xx xx JSR @rts15× 2
Clobbers S; requires @rts12, and @rts15; and writes in stack
8 bytes
8C       TXA
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
08       PHP
28       PLP
20 xx xx JSR @rts12
20 xx xx JSR @rts14
Requires @rts12, and @rts14; and writes in stack
24 24    BIT $24
20 xx xx JSR @rts15× 2
Clobbers Z&N, and V; requires @rts12, and @rts15; and writes in stack
85 xx    STA @zptemp
20 xx xx JSR @rts15× 2
Requires @zptemp, @rts12, and @rts15; and writes in stack
04 04    NOP $04
20 xx xx JSR @rts15× 2
Requires @rts12, @rts15, and support for unofficial opcodes; and writes in stack
9 bytes
EA       NOP
08       PHP
28       PLP
20 xx xx JSR @rts12× 2
Requires @rts12; and writes in stack
10 bytes
08       PHP       \ × 2
28       PLP       /
08       PHP
36 36    ROL $36,X
76 36    ROR $36,X
28       PLP
Writes in stack
12 bytes
EA   ... NOP      × 2
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
13 bytes
C5 C5    CMP $C5
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
14 bytes
4C xx xx JMP *+3
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
17 bytes
18   ... CLC      × 15
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 15
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 15
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 15
Requires support for unofficial opcodes
18 bytes
4C xx xx JMP *+3
EA   ... NOP      × 15
Not relocatable code


34 cycles

5 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
Clobbers Y, and Z&N
6 bytes
48       PHA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
68   ... PLA      × 2
00 00... BRK 0    × 2
Clobbers A, S, and Z&N; requires dummy interrupt handler; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
48       PHA
A9       LDA #0
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #0
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
EA       NOP
F6 F6    INC $F6,X
00 00... BRK 0    × 2
Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
08       PHP
28       PLP
00 00    BRK 0
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers S, Z&N, and C; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A, and S; and writes in stack
EA       NOP
48   ... PHA      × 2
00 00... BRK 0    × 2
Clobbers S; requires dummy interrupt handler; and writes in stack
8 bytes
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
F6 F6    INC $F6,X
20 xx xx JSR @rts14× 2
Clobbers Z&N; requires @zptemp, @rts12, @rts14, and writable $00-$FF; and writes in stack
EA   ... NOP      × 4
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48   ... PHA      × 2
20 xx xx JSR @rts14× 2
Clobbers S; requires @rts12, and @rts14; and writes in stack
9 bytes
08       PHP
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
EA   ... NOP      × 2
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
12 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
17 bytes
EA   ... NOP      × 17
No requirements


35 cycles

5 bytes
A9       LDA #8
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
10 FB    BPL *-3
Clobbers A, Z&N, and C; and writes in stack
A0 88    LDY #136 ;hides 'DEY'
88   ... DEY      × 2
30 FB    BMI *-3
Clobbers Y, and Z&N
A2 F8    LDX #248 ;hides 'SED'
E8   ... INX      × 2
D0 FB    BNE *-3
Clobbers X, Z&N, and D
68       PLA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
Clobbers A, S, Z&N, and C
68       PLA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
7 bytes
8C       TXA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
48       PHA
A9       LDA #1
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #1
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
EA       NOP
08       PHP
28       PLP
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
8 bytes
EA   ... NOP      × 2
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
28       PLP
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
E6 xx    INC @zptemp
20 xx xx JSR @rts15× 2
Clobbers Z&N; requires @zptemp, @rts12, and @rts15; and writes in stack
EA       NOP
48       PHA
20 xx xx JSR @rts15× 2
Clobbers S; requires @rts12, and @rts15; and writes in stack
9 bytes
08       PHP
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
68       PLA
28       PLP
Writes in stack
12 bytes
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 5
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
13 bytes
E6 xx    INC @zptemp
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 2
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 2
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 2
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 2
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 2
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 2
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
14 bytes
C5 C5    CMP $C5
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N, and V
04 04    NOP $04
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires support for unofficial opcodes
15 bytes
4C xx xx JMP *+3
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and not relocatable code
18 bytes
18   ... CLC      × 16
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 16
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 16
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 16
Requires support for unofficial opcodes
19 bytes
4C xx xx JMP *+3
EA   ... NOP      × 16
Not relocatable code


36 cycles

5 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
6 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C
7 bytes
48       PHA
A9       LDA #2
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #2
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
28       PLP
00 00... BRK 0    × 2
Clobbers S; requires dummy interrupt handler; and writes in stack
8 bytes
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
90 FC    BCC *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
90 FC    BCC *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 04    LDY #4
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
F6 F6    INC $F6,X
20 xx xx JSR @rts15× 2
Clobbers Z&N; requires @zptemp, @rts12, @rts15, and writable $00-$FF; and writes in stack
08       PHP
28       PLP
20 xx xx JSR @rts14
20 xx xx JSR @rts15
Requires @rts12, @rts14, and @rts15; and writes in stack
08       PHP
24 24    BIT $24
28       PLP
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
20 xx xx JSR @rts15× 2
Clobbers S; requires @rts12, and @rts15; and writes in stack
9 bytes
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
20 xx xx JSR @rts12× 3
Requires @rts12; and writes in stack
8C       TXA
A2 FA    LDX #250 ;hides 'NOP'
EA       NOP
E8   ... INX      × 2
D0 FA    BNE *-4
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
EA       NOP
68       PLA
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
08       PHP
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
18       CLC
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
A5 A5    LDA $A5
8C       TXA
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
12 bytes
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N
18 bytes
EA   ... NOP      × 18
No requirements


37 cycles

5 bytes
A9       LDA #10
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, S, Z&N, and C; and writes in stack
48       PHA
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
Clobbers Y, S, and Z&N; and writes in stack
A2 04    LDX #4
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 04    LDY #4
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C
A2 04    LDX #4
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N
A0 04    LDY #4
EA   ... NOP      × 2
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N
48       PHA
A9       LDA #3
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #3
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA       NOP ;first loop only
00 00    BRK 0
10 FA    BPL *-4
Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
28       PLP
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
EA   ... NOP      × 2
08       PHP
28       PLP
00 00... BRK 0    × 2
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers S, Z&N, and C; and writes in stack
48   ... PHA      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A, and S; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
EA       NOP
08       PHP
28       PLP
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
10 bytes
08       PHP
48       PHA
18   ... CLC      × 2
A9 2A    LDA #$2A ;hides 'ROL A'
90 FD    BCC *-1
68       PLA
28       PLP
Writes in stack
13 bytes
EA       NOP
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 5
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
14 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 3
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 3
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 3
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 3
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 3
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 3
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
15 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
19 bytes
18   ... CLC      × 17
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 17
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 17
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 17
Requires support for unofficial opcodes
20 bytes
4C xx xx JMP *+3
EA   ... NOP      × 17
Not relocatable code


38 cycles

5 bytes
A9       LDA #11
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
10 FC    BPL *-2
Clobbers A, Z&N, C, and V
EA       NOP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, S, Z&N, and C
7 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
98       TYA
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
A8       TAY
Clobbers A, and Z&N
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 06    LDY #6
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
20 xx xx JSR @rts12
00 00... BRK 0    × 2
Requires dummy interrupt handler, and @rts12; and writes in stack
8 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
13 bytes
EA       NOP
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N
19 bytes
EA   ... NOP      × 19
No requirements


39 cycles

4 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
6 bytes
00 00... BRK 0    × 3
Requires dummy interrupt handler; and writes in stack
48       PHA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #5
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #5
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
88   ... DEY      × 2
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N
08       PHP
A2 05    LDX #5 ;hides 'ORA zp'
CA       DEX ;first loop only
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers A, and X; and writes in stack
08       PHP
A0 05    LDY #5 ;hides 'ORA zp'
88       DEY ;first loop only
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers A, and Y; and writes in stack
9 bytes
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 2A    LDA #$2A ;hides 'ROL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
20 xx xx JSR @rts15
20 xx xx JSR @rts12× 2
Requires @rts12, and @rts15; and writes in stack
08       PHP
A2 FA    LDX #250 ;hides 'NOP'
EA       NOP
E8   ... INX      × 2
D0 FA    BNE *-4
28       PLP
Clobbers X; requires support for unofficial opcodes; and writes in stack
08       PHP
A0 FA    LDY #250 ;hides 'NOP'
EA       NOP
C8   ... INY      × 2
D0 FA    BNE *-4
28       PLP
Clobbers Y; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 05    LDY #5
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 04    LDX #4
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 04    LDY #4
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
EA   ... NOP      × 2
08       PHP
28       PLP
20 xx xx JSR @rts14× 2
Requires @rts12, and @rts14; and writes in stack
48       PHA
20 xx xx JSR @rts12× 3
Clobbers S; requires @rts12; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 04    LDX #4
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
14 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
15 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
Clobbers Z&N; and requires writable $700-$7FF
20 bytes
18   ... CLC      × 18
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 18
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 18
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 18
Requires support for unofficial opcodes
21 bytes
4C xx xx JMP *+3
EA   ... NOP      × 18
Not relocatable code


40 cycles

5 bytes
A9       LDA #13
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 05    LDX #5 ;hides 'ORA zp'
EA       NOP
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, and Z&N
A0 05    LDY #5 ;hides 'ORA zp'
EA       NOP
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, and Z&N
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V
7 bytes
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #6
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #6
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00... BRK 0    × 2
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
8 bytes
48       PHA
18   ... CLC      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18   ... CLC      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 06    LDY #6
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
00 00... BRK 0    × 2
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
9 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
14 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N
20 bytes
EA   ... NOP      × 20
No requirements


41 cycles

5 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
28       PLP
Clobbers Y; and writes in stack
EA       NOP
00 00... BRK 0    × 3
Requires dummy interrupt handler; and writes in stack
8 bytes
48       PHA
08       PHP
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
8C       TXA
A2 04    LDX #4
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N
08       PHP
A6 A6    LDX $A6
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
20 xx xx JSR @rts12
20 xx xx JSR @rts14
20 xx xx JSR @rts15
Requires @rts12, @rts14, and @rts15; and writes in stack
08       PHP
48       PHA
A9       LDA #0
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Clobbers S; and writes in stack
10 bytes
08       PHP
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
14 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
15 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
16 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
21 bytes
18   ... CLC      × 19
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 19
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 19
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 19
Requires support for unofficial opcodes
22 bytes
4C xx xx JMP *+3
EA   ... NOP      × 19
Not relocatable code


42 cycles

5 bytes
A9       LDA #15
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C; and writes in stack
6 bytes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
7 bytes
EA       NOP
A2 05    LDX #5 ;hides 'ORA zp'
EA       NOP
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, and Z&N
EA       NOP
A0 05    LDY #5 ;hides 'ORA zp'
EA       NOP
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, and Z&N
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #8
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #8
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
48       PHA
00 00... BRK 0    × 3
Clobbers S; requires dummy interrupt handler; and writes in stack
8 bytes
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
EA       NOP
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
A2 F8    LDX #248 ;hides 'SED'
E8   ... INX      × 2
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 88    LDY #136 ;hides 'DEY'
88   ... DEY      × 2
30 FB    BMI *-3
28       PLP
Clobbers Y; and writes in stack
24 24    BIT $24
00 00... BRK 0    × 3
Clobbers Z&N, and V; requires dummy interrupt handler; and writes in stack
85 xx    STA @zptemp
00 00... BRK 0    × 3
Requires @zptemp, and dummy interrupt handler; and writes in stack
EA       NOP
00 00... BRK 0    × 2
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
04 04    NOP $04
00 00... BRK 0    × 3
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
20 xx xx JSR @rts14× 3
Requires @rts12, and @rts14; and writes in stack
20 xx xx JSR @rts12
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
08       PHP
48       PHA
A9       LDA #1
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
00 00... BRK 0    × 2
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
10 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Writes in stack
14 bytes
F6 F6... INC $F6,X× 7
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
15 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N
21 bytes
EA   ... NOP      × 21
No requirements


43 cycles

5 bytes
A9       LDA #16
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C
6 bytes
EA   ... NOP      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 06    LDY #6
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
00 00... BRK 0    × 3
Requires dummy interrupt handler; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
20 xx xx JSR @rts15
20 xx xx JSR @rts14× 2
Requires @rts12, @rts14, and @rts15; and writes in stack
08       PHP
48       PHA
A9       LDA #2
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
90 FC    BCC *-2
68       PLA
28       PLP
Writes in stack
15 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
16 bytes
EA   ... NOP      × 2
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and C
EA   ... NOP      × 2
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and V
EA   ... NOP      × 2
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
17 bytes
EA   ... NOP      × 2
4C xx xx JMP *+3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
22 bytes
18   ... CLC      × 20
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 20
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 20
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 20
Requires support for unofficial opcodes
23 bytes
4C xx xx JMP *+3
EA   ... NOP      × 20
Not relocatable code


44 cycles

5 bytes
A9       LDA #17
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
10 FB    BPL *-3
Clobbers A, Z&N, and C
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
88       DEY
30 FB    BMI *-3
Clobbers Y, and Z&N
48       PHA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
48       PHA
A9       LDA #10
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #10
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
E6 xx    INC @zptemp
00 00... BRK 0    × 3
Clobbers Z&N; requires @zptemp, and dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers S, Z&N, and C; and writes in stack
68       PLA
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
28       PLP
Clobbers A, and S; and writes in stack
48       PHA
08       PHP
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
28       PLP
Clobbers Y, and S; and writes in stack
EA       NOP
48       PHA
00 00... BRK 0    × 3
Clobbers S; requires dummy interrupt handler; and writes in stack
9 bytes
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 04    LDX #4
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 04    LDY #4
EA   ... NOP      × 2
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
20 xx xx JSR @rts14
20 xx xx JSR @rts15× 2
Requires @rts12, @rts14, and @rts15; and writes in stack
08       PHP
48       PHA
A9       LDA #3
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
A9 09    LDA #$09 ;hides 'ORA #$EA'
EA       NOP ;first loop only
00 00    BRK 0
10 FA    BPL *-4
68       PLA
Clobbers Z&N; requires dummy interrupt handler; and writes in stack
18       CLC
90 00    BCC *+2
00 00... BRK 0    × 3
Clobbers C; requires dummy interrupt handler; and writes in stack
B8       CLV
50 00    BVC *+2
00 00... BRK 0    × 3
Clobbers V; requires dummy interrupt handler; and writes in stack
EA       NOP
85 xx    STA @zptemp
00 00... BRK 0    × 3
Requires @zptemp, and dummy interrupt handler; and writes in stack
EA   ... NOP      × 2
00 00... BRK 0    × 2
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
EA       NOP
04 04    NOP $04
00 00... BRK 0    × 3
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 06    LDX #6
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
EA       NOP
20 xx xx JSR @rts14× 3
Requires @rts12, and @rts14; and writes in stack
EA       NOP
20 xx xx JSR @rts12
20 xx xx JSR @rts15× 2
Requires @rts12, and @rts15; and writes in stack
EA   ... NOP      × 2
00 00... BRK 0    × 2
08       PHP       \ × 2
28       PLP       /
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 05    LDX #5
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
15 bytes
EA       NOP
F6 F6... INC $F6,X× 7
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
16 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N
22 bytes
EA   ... NOP      × 22
No requirements


45 cycles

5 bytes
A9       LDA #18
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
EA       NOP
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C
68       PLA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #11
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #11
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
10 FC    BPL *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
F6 F6    INC $F6,X
00 00... BRK 0    × 3
Clobbers Z&N; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
00 00... BRK 0    × 3
Clobbers S; requires dummy interrupt handler; and writes in stack
9 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
68       PLA
28       PLP
Writes in stack
16 bytes
EA   ... NOP      × 2
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
17 bytes
EA   ... NOP      × 3
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and C
EA   ... NOP      × 3
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and V
EA   ... NOP      × 3
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
18 bytes
26 26... ROL $26  × 9
Clobbers Z&N
23 bytes
18   ... CLC      × 21
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 21
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 21
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 21
Requires support for unofficial opcodes
24 bytes
4C xx xx JMP *+3
EA   ... NOP      × 21
Not relocatable code


46 cycles

5 bytes
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 09    LDY #9
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #19
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
68       PLA
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; and writes in stack
8 bytes
08       PHP
28       PLP
00 00... BRK 0    × 3
Requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #5
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
88   ... DEY      × 2
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N; and writes in stack
EA   ... NOP      × 3
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA       NOP
20 xx xx JSR @rts14
20 xx xx JSR @rts15× 2
Requires @rts12, @rts14, and @rts15; and writes in stack
11 bytes
08       PHP
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
68       PLA
28       PLP
Writes in stack
16 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N
23 bytes
EA   ... NOP      × 23
No requirements


47 cycles

5 bytes
A9       LDA #20
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68   ... PLA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C
7 bytes
BA       TSX
68       PLA
9A       TXS
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, X, Z&N, and C; and unsafe for interrupts
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
EA       NOP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
F6 F6    INC $F6,X
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #13
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #13
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
A0 88    LDY #136 ;hides 'DEY'
88       DEY
30 FC    BMI *-2
Clobbers Y, and Z&N; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
68       PLA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
EA       NOP
68       PLA
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
8 bytes
8C       TXA
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
A2 05    LDX #5 ;hides 'ORA zp'
EA       NOP
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers A, and X; and writes in stack
08       PHP
A0 05    LDY #5 ;hides 'ORA zp'
EA       NOP
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers A, and Y; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #6
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
08       PHP
28       PLP
00 00... BRK 0    × 2
20 xx xx JSR @rts14
Requires dummy interrupt handler, @rts12, and @rts14; and writes in stack
EA       NOP
48   ... PHA      × 2
00 00... BRK 0    × 3
Clobbers S; requires dummy interrupt handler; and writes in stack
10 bytes
08       PHP
48       PHA
18   ... CLC      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
90 FD    BCC *-1
68       PLA
28       PLP
Writes in stack
16 bytes
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 7
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
17 bytes
EA   ... NOP      × 3
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 2
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 2
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 2
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 2
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 2
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 2
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
18 bytes
C5 C5    CMP $C5
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
19 bytes
EA       NOP
26 26... ROL $26  × 9
Clobbers Z&N
24 bytes
18   ... CLC      × 22
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 22
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 22
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 22
Requires support for unofficial opcodes
25 bytes
4C xx xx JMP *+3
EA   ... NOP      × 22
Not relocatable code


48 cycles

5 bytes
A9       LDA #21
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 09    LDY #9
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
EA       NOP
68       PLA
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
88       DEY
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N
9 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
16 bytes
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N
24 bytes
EA   ... NOP      × 24
No requirements


49 cycles

4 bytes
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, and Z&N
5 bytes
A9       LDA #22
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
90 FC    BCC *-2
Clobbers A, S, Z&N, and C; and writes in stack
A2 06    LDX #6
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
7 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
24 24    BIT $24
90 FB    BCC *-3
Clobbers A, Z&N, C, and V
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
90 FB    BCC *-3
Clobbers A, Z&N, and C; and writes in stack
A6 A6    LDX $A6
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
90 FB    BCC *-3
Clobbers A, Z&N, and C; and requires @zptemp
48       PHA
A9       LDA #15
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #15
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
90 FB    BCC *-3
Clobbers A, Z&N, and C; and requires support for unofficial opcodes
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers S, Z&N, and C; and writes in stack
EA       NOP
68   ... PLA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A, and S; and writes in stack
8 bytes
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
26 26    ROL $26
66 26    ROR $26
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
08       PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; and writes in stack
68       PLA
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #8
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 07    LDY #7
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
48       PHA
08       PHP
28       PLP
00 00... BRK 0    × 3
Clobbers S; requires dummy interrupt handler; and writes in stack
10 bytes
08       PHP
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
17 bytes
EA       NOP
E6 xx    INC @zptemp
F6 F6... INC $F6,X× 7
Clobbers Z&N; and requires @zptemp, and writable $00-$FF
18 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA   ... NOP      × 3
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 3
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 3
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 3
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 3
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 3
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
19 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
20 bytes
EA   ... NOP      × 2
26 26... ROL $26  × 9
Clobbers Z&N
25 bytes
18   ... CLC      × 23
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 23
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 23
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 23
Requires support for unofficial opcodes
26 bytes
4C xx xx JMP *+3
EA   ... NOP      × 23
Not relocatable code


50 cycles

5 bytes
A9       LDA #23
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA       NOP
B0 FB    BCS *-3
Clobbers A, Z&N, C, and V
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 07    LDY #7
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
8C       TXA
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9       LDA #16
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #16
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA   ... NOP      × 2
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 06    LDY #6
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Writes in stack
17 bytes
EA       NOP
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N
25 bytes
EA   ... NOP      × 25
No requirements


51 cycles

5 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
Clobbers A, Z&N, C, and V
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
Clobbers X, and Z&N
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
Clobbers Y, and Z&N
7 bytes
20 xx xx JSR @rts12
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C; requires @rts12; and writes in stack
48       PHA
A9       LDA #17
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #17
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68   ... PLA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, S, Z&N, and C
8 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
36 36    ROL $36,X
76 36    ROR $36,X
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
88       DEY
30 FB    BMI *-3
28       PLP
Clobbers Y; and writes in stack
48       PHA
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #10
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
20 xx xx JSR @rts12
00 00... BRK 0    × 3
Requires dummy interrupt handler, and @rts12; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
00 00    BRK 0
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
10 FD    BPL *-1
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
18 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
04 04    NOP $04
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
19 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
FE 00 02 INC $0200,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
21 bytes
EA   ... NOP      × 3
26 26... ROL $26  × 9
Clobbers Z&N
26 bytes
18   ... CLC      × 24
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 24
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 24
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 24
Requires support for unofficial opcodes
27 bytes
4C xx xx JMP *+3
EA   ... NOP      × 24
Not relocatable code


52 cycles

5 bytes
A9       LDA #25
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
48       PHA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, S, and Z&N; and writes in stack
6 bytes
A4 A4    LDY $A4
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, and Z&N
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
7 bytes
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
EA       NOP
10 FB    BPL *-3
Clobbers A, Z&N, C, and V
EA       NOP
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
48       PHA
A9       LDA #18
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #18
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
90 FC    BCC *-2
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
00 00... BRK 0    × 4
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers S, Z&N, and C; and writes in stack
48   ... PHA      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A, and S; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #11
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
18 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N
26 bytes
EA   ... NOP      × 26
No requirements


53 cycles

5 bytes
A9       LDA #26
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
68       PLA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers A, Y, S, and Z&N
6 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, and Z&N
EA       NOP
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
Clobbers X, and Z&N
EA       NOP
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
Clobbers Y, and Z&N
7 bytes
08       PHP
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 09    LDY #9
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #19
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #19
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Writes in stack
18 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
19 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
20 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
22 bytes
EA   ... NOP      × 4
26 26... ROL $26  × 9
Clobbers Z&N
27 bytes
18   ... CLC      × 25
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 25
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 25
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 25
Requires support for unofficial opcodes
28 bytes
4C xx xx JMP *+3
EA   ... NOP      × 25
Not relocatable code


54 cycles

5 bytes
A9       LDA #27
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
E6 xx    INC @zptemp
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, and Z&N; and requires @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
10 FB    BPL *-3
Clobbers A, S, Z&N, and C; and writes in stack
48       PHA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
Clobbers Y, S, and Z&N; and writes in stack
A0 88    LDY #136 ;hides 'DEY'
68       PLA
88       DEY
30 FB    BMI *-3
Clobbers A, Y, S, and Z&N
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
Clobbers A, Z&N, and C
A6 A6    LDX $A6
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #20
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #20
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
8C       TXA
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
BA       TSX
68       PLA
9A       TXS
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A, and X; writes in stack; and unsafe for interrupts
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
EA       NOP
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
EA       NOP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #13
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
00 00... BRK 0    × 4
Requires dummy interrupt handler; and writes in stack
EA       NOP
48   ... PHA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers S, Z&N, and C; and writes in stack
EA       NOP
48   ... PHA      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 08    LDY #8
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 07    LDX #7
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
18 bytes
36 36... ROL $36,X× 9
Clobbers Z&N
27 bytes
EA   ... NOP      × 27
No requirements


55 cycles

5 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
Clobbers X, Z&N, and D
A0 F8    LDY #248 ;hides 'SED'
C8       INY
D0 FC    BNE *-2
Clobbers Y, Z&N, and D
6 bytes
F6 F6    INC $F6,X
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48   ... PHA      × 2
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, S, and Z&N; and writes in stack
A2 06    LDX #6
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 06    LDY #6
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #21
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #21
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 09    LDY #9
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Writes in stack
19 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
20 bytes
EA   ... NOP      × 2
C5 C5    CMP $C5
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and C
EA   ... NOP      × 2
24 24    BIT $24
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and V
EA   ... NOP      × 2
04 04    NOP $04
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
21 bytes
EA   ... NOP      × 2
4C xx xx JMP *+3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
22 bytes
26 26    ROL $26
66 26    ROR $26
26 26... ROL $26  × 9
Clobbers Z&N
28 bytes
18   ... CLC      × 26
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 26
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 26
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 26
Requires support for unofficial opcodes
29 bytes
4C xx xx JMP *+3
EA   ... NOP      × 26
Not relocatable code


56 cycles

5 bytes
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #29
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
08       PHP
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
28       PLP
Clobbers Y; and writes in stack
7 bytes
E6 xx    INC @zptemp
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
Clobbers A, Z&N, C, and V; and requires @zptemp
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
48       PHA
A9       LDA #22
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #22
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, S, and Z&N; and writes in stack
8 bytes
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, and Z&N
48       PHA
08       PHP
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
08       PHP
28       PLP
90 FB    BCC *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
24 24    BIT $24
90 FB    BCC *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 06    LDX #6
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
48       PHA
A9       LDA #15
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Clobbers S; and writes in stack
10 bytes
08       PHP
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Writes in stack
19 bytes
EA       NOP
36 36... ROL $36,X× 9
Clobbers Z&N
28 bytes
EA   ... NOP      × 28
No requirements


57 cycles

5 bytes
A9       LDA #30
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
A2 08    LDX #8
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 08    LDY #8
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #23
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #23
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, S, and Z&N
8 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA       NOP
B0 FB    BCS *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
EA       NOP
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA       NOP
B0 FB    BCS *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 07    LDY #7
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9       LDA #16
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Writes in stack
20 bytes
C5 C5    CMP $C5
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36... ROL $36,X× 9
Clobbers Z&N, and V
85 xx    STA @zptemp
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
21 bytes
4C xx xx JMP *+3
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
22 bytes
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
29 bytes
18   ... CLC      × 27
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 27
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 27
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 27
Requires support for unofficial opcodes
30 bytes
4C xx xx JMP *+3
EA   ... NOP      × 27
Not relocatable code


58 cycles

5 bytes
A9       LDA #31
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
38       SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A       NOP ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
7 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
28       PLP
Clobbers Y; and writes in stack
8 bytes
E6 xx    INC @zptemp
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, and Z&N; and requires @zptemp
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
Clobbers A, and Z&N
20 xx xx JSR @rts12
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; requires @rts12; and writes in stack
08       PHP
48       PHA
A9       LDA #17
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
20 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N
29 bytes
EA   ... NOP      × 29
No requirements


59 cycles

5 bytes
A9       LDA #32
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
Clobbers A, Z&N, and C; and writes in stack
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C
48       PHA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
68       PLA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
Clobbers A, X, S, Z&N, and D
68       PLA
A0 F8    LDY #248 ;hides 'SED'
C8       INY
D0 FC    BNE *-2
Clobbers A, Y, S, Z&N, and D
7 bytes
EA   ... NOP      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
8C       TXA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
AA       TAX
Clobbers A, Z&N, and D
A6 A6    LDX $A6
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #25
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #25
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
28       PLP
Clobbers Y, and S; and writes in stack
8 bytes
08       PHP
A4 A4    LDY $A4
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
28       PLP
Clobbers Y; and writes in stack
F6 F6    INC $F6,X
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
EA       NOP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
EA   ... NOP      × 2
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
EA       NOP
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
48       PHA
A9       LDA #18
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 09    LDX #9
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
28       PLP
00 00... BRK 0    × 4
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 08    LDX #8
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
20 bytes
E6 xx    INC @zptemp
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
21 bytes
EA       NOP
C5 C5    CMP $C5
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36... ROL $36,X× 9
Clobbers Z&N, and V
EA   ... NOP      × 2
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA   ... NOP      × 2
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA   ... NOP      × 2
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA   ... NOP      × 2
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA   ... NOP      × 2
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA   ... NOP      × 2
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
22 bytes
EA       NOP
4C xx xx JMP *+3
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
23 bytes
EA       NOP
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
30 bytes
18   ... CLC      × 28
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 28
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 28
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 28
Requires support for unofficial opcodes
31 bytes
4C xx xx JMP *+3
EA   ... NOP      × 28
Not relocatable code


60 cycles

5 bytes
A9       LDA #33
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #26
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #26
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9       LDA #19
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
68       PLA
28       PLP
Writes in stack
20 bytes
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N
30 bytes
EA   ... NOP      × 30
No requirements


61 cycles

5 bytes
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #34
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
Clobbers A, Z&N, and C; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
E6 xx    INC @zptemp
90 FB    BCC *-3
Clobbers A, Z&N, and C; and requires @zptemp
48       PHA
A9       LDA #27
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #27
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C
8 bytes
8C       TXA
A2 08    LDX #8
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
08       PHP
E6 xx    INC @zptemp
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
28       PLP
Clobbers Y; requires @zptemp; and writes in stack
48   ... PHA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
48       PHA
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
28       PLP
Clobbers A, and S; and writes in stack
48       PHA
08       PHP
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 09    LDY #9
88       DEY
10 FD    BPL *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #20
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 07    LDX #7
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
08       PHP
EA       NOP
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
EA       NOP
08       PHP
28       PLP
00 00... BRK 0    × 4
Requires dummy interrupt handler; and writes in stack
EA       NOP
48   ... PHA      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 06    LDX #6
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
21 bytes
EA       NOP
E6 xx    INC @zptemp
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
22 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
23 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
24 bytes
EA   ... NOP      × 2
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
31 bytes
18   ... CLC      × 29
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 29
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 29
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 29
Requires support for unofficial opcodes
32 bytes
4C xx xx JMP *+3
EA   ... NOP      × 29
Not relocatable code


62 cycles

5 bytes
A2 88    LDX #136 ;hides 'DEY'
CA       DEX
30 FC    BMI *-2
Clobbers X, Y, and Z&N
A9       LDA #35
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
00 00    BRK 0
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
Clobbers Y, and Z&N; requires dummy interrupt handler; and writes in stack
7 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
68       PLA
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 F8    LDY #248 ;hides 'SED'
C8       INY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
68       PLA
48       PHA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
Clobbers A, X, Z&N, and D
68       PLA
48       PHA
A0 F8    LDY #248 ;hides 'SED'
C8       INY
D0 FC    BNE *-2
Clobbers A, Y, Z&N, and D
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
EA       NOP
68       PLA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
EA       NOP
68       PLA
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
8 bytes
EA       NOP
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 09    LDX #9
CA       DEX
10 FD    BPL *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9       LDA #21
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
28       PLP
68       PLA
28       PLP
Writes in stack
21 bytes
EA       NOP
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N
31 bytes
EA   ... NOP      × 31
No requirements


63 cycles

5 bytes
A9       LDA #36
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
6 bytes
EA       NOP
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires support for unofficial opcodes
7 bytes
38       SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and not relocatable code
08       PHP
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #29
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #29
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68   ... PLA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C
8 bytes
EA   ... NOP      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
Clobbers A, Z&N, and C; and writes in stack
68       PLA
8C       TXA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
AA       TAX
Clobbers A, S, Z&N, and D
48       PHA
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
E6 xx    INC @zptemp
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
Clobbers Z&N, C, and V; requires @zptemp; and writes in stack
08       PHP
E6 xx    INC @zptemp
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
28       PLP
Clobbers A; requires @zptemp; and writes in stack
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
28       PLP
Clobbers A; requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9       LDA #22
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
Clobbers S, and Z&N; and writes in stack
48       PHA
08       PHP
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
28       PLP
Clobbers A, and S; and writes in stack
10 bytes
48       PHA
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
24 24    BIT $24
90 FB    BCC *-3
68       PLA
28       PLP
Writes in stack
22 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
23 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
25 bytes
EA   ... NOP      × 3
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
32 bytes
18   ... CLC      × 30
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 30
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 30
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 30
Requires support for unofficial opcodes
33 bytes
4C xx xx JMP *+3
EA   ... NOP      × 30
Not relocatable code


64 cycles

5 bytes
A9       LDA #37
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 09    LDY #9
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA   ... NOP      × 2
B0 FA    BCS *-4
Clobbers A, Z&N, C, and V
48       PHA
A9       LDA #30
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #30
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
18       CLC
10 FA    BPL *-4
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, and C; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 3
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 08    LDX #8
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 08    LDY #8
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
68       PLA
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #23
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA       NOP
B0 FB    BCS *-3
68       PLA
28       PLP
Writes in stack
22 bytes
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N
32 bytes
EA   ... NOP      × 32
No requirements


65 cycles

5 bytes
A9       LDA #38
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
A2 08    LDX #8
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 08    LDY #8
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
68       PLA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #31
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #31
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
38       SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A       NOP ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
38       SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A       NOP ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, and C; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; and writes in stack
9 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
28       PLP
Writes in stack
22 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
23 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
24 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
26 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
26 26... ROL $26  × 9
Clobbers Z&N
33 bytes
18   ... CLC      × 31
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 31
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 31
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 31
Requires support for unofficial opcodes
34 bytes
4C xx xx JMP *+3
EA   ... NOP      × 31
Not relocatable code


66 cycles

5 bytes
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #39
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
7 bytes
48       PHA
A9       LDA #32
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #32
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
38       SEC
A9 09    LDA #9
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires @zptemp
04 04    NOP $04
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires support for unofficial opcodes
68   ... PLA      × 2
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C
48       PHA
08       PHP
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N, and D; and writes in stack
EA   ... NOP      × 2
68       PLA
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C
68       PLA
48       PHA
8C       TXA
A2 F8    LDX #248 ;hides 'SED'
E8       INX
D0 FC    BNE *-2
AA       TAX
Clobbers A, Z&N, and D
08       PHP
A6 A6    LDX $A6
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #25
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
F6 F6    INC $F6,X
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
Clobbers Z&N; requires @zptemp, and writable $00-$FF; and writes in stack
00 00    BRK 0
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
D0 FD    BNE *-1
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$EA'
EA       NOP ;first loop only
EA       NOP
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
22 bytes
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N
33 bytes
EA   ... NOP      × 33
No requirements


67 cycles

5 bytes
A9       LDA #40
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
7 bytes
BA       TSX
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
9A       TXS
Clobbers A, X, Z&N, and C; and writes in stack
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
F6 F6    INC $F6,X
90 FB    BCC *-3
Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
A0 06    LDY #6
F6 F6    INC $F6,X
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #33
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #33
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A2 06    LDX #6
48   ... PHA      × 2
CA       DEX
D0 FB    BNE *-3
Clobbers X, S, and Z&N; and writes in stack
A0 06    LDY #6
48   ... PHA      × 2
88       DEY
D0 FB    BNE *-3
Clobbers Y, S, and Z&N; and writes in stack
A2 06    LDX #6
EA       NOP
68       PLA
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, S, and Z&N
A0 06    LDY #6
EA       NOP
68       PLA
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, S, and Z&N
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and requires @zptemp
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and requires support for unofficial opcodes
8 bytes
EA       NOP
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
A6 A6    LDX $A6
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 09    LDY #9
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 0B    LDY #11
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #26
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
28       PLP
Writes in stack
23 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
24 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
25 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
26 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
34 bytes
18   ... CLC      × 32
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 32
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 32
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 32
Requires support for unofficial opcodes
35 bytes
4C xx xx JMP *+3
EA   ... NOP      × 32
Not relocatable code


68 cycles

5 bytes
A9       LDA #41
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #34
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #34
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
EA       NOP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
8C       TXA
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #27
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 08    LDX #8
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
48       PHA
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
10 FA    BPL *-4
68       PLA
28       PLP
Writes in stack
23 bytes
EA       NOP
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N
34 bytes
EA   ... NOP      × 34
No requirements


69 cycles

5 bytes
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
Clobbers Y, and Z&N
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, Z&N, and C
A9       LDA #42
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
10 FA    BPL *-4
Clobbers A, Z&N, and C; and writes in stack
A6 A6    LDX $A6
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
08       PHP
A2 88    LDX #136 ;hides 'DEY'
CA       DEX
30 FC    BMI *-2
28       PLP
Clobbers X, and Y; and writes in stack
48       PHA
A9       LDA #35
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #35
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires @zptemp, and writable $00-$FF
00 00    BRK 0
08       PHP
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
28       PLP
Clobbers Y; requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
EA   ... NOP      × 2
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
24 bytes
C5 C5    CMP $C5
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
25 bytes
4C xx xx JMP *+3
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
26 bytes
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
35 bytes
18   ... CLC      × 33
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 33
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 33
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 33
Requires support for unofficial opcodes
36 bytes
4C xx xx JMP *+3
EA   ... NOP      × 33
Not relocatable code


70 cycles

5 bytes
A9       LDA #43
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #36
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #36
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 0C    LDY #12
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
28       PLP
Clobbers A; requires @zptemp; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
9 bytes
48       PHA
38       SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; writes in stack; and not relocatable code
08       PHP
38       SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #29
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA   ... NOP      × 2
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
E6 xx    INC @zptemp
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
30 FC    BMI *-2
68       PLA
28       PLP
Requires @zptemp; and writes in stack
08       PHP
48       PHA
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68       PLA
28       PLP
Requires @rts12, and @rts14; and writes in stack
48       PHA
08       PHP
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
48       PHA
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
30 FD    BMI *-1
A8       TAY
68       PLA
28       PLP
Writes in stack
24 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N
35 bytes
EA   ... NOP      × 35
No requirements


71 cycles

5 bytes
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #44
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, Z&N, and C
7 bytes
48       PHA
A9       LDA #37
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #37
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 09    LDY #9
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA   ... NOP      × 2
B0 FA    BCS *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA   ... NOP      × 2
B0 FA    BCS *-4
28       PLP
Clobbers A; and writes in stack
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #30
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
A5 A5    LDA $A5
8C       TXA
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
24 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
25 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
26 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
27 bytes
EA       NOP
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
36 bytes
18   ... CLC      × 34
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 34
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 34
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 34
Requires support for unofficial opcodes
37 bytes
4C xx xx JMP *+3
EA   ... NOP      × 34
Not relocatable code


72 cycles

5 bytes
A9       LDA #45
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
Clobbers Y, S, and Z&N; and writes in stack
48       PHA
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, Z&N, and C; and writes in stack
7 bytes
A4 A4    LDY $A4
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
Clobbers Y, and Z&N
A6 A6    LDX $A6
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, Z&N, and C
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
48       PHA
A9       LDA #38
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #38
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
EA       NOP
68       PLA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
8 bytes
EA       NOP
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
48       PHA
08       PHP
A2 88    LDX #136 ;hides 'DEY'
CA       DEX
30 FC    BMI *-2
28       PLP
Clobbers X, Y, and S; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 08    LDX #8
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 08    LDY #8
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #31
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
38       SEC
A9 EB    LDA #$EB ;hides 'SBC #$1A'
1A       NOP ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
48       PHA
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
24 bytes
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N
36 bytes
EA   ... NOP      × 36
No requirements


73 cycles

5 bytes
A9       LDA #46
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
7 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
Clobbers A, and Z&N
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #39
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #39
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
9 bytes
08       PHP
48       PHA
A9       LDA #32
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; requires @zptemp; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; requires @zptemp; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
10 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
25 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
26 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
27 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
28 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
37 bytes
18   ... CLC      × 35
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 35
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 35
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 35
Requires support for unofficial opcodes
38 bytes
4C xx xx JMP *+3
EA   ... NOP      × 35
Not relocatable code


74 cycles

5 bytes
A9       LDA #47
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #40
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #40
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, Z&N, and C
68       PLA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
BA       TSX
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
9A       TXS
28       PLP
Clobbers A, and X; and writes in stack
08       PHP
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
F6 F6    INC $F6,X
90 FB    BCC *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
F6 F6    INC $F6,X
90 FB    BCC *-3
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
A0 06    LDY #6
F6 F6    INC $F6,X
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #33
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 09    LDY #9
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 08    LDX #8
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 08    LDY #8
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 0B    LDX #11
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
25 bytes
EA       NOP
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N
37 bytes
EA   ... NOP      × 37
No requirements


75 cycles

5 bytes
A9       LDA #48
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #41
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #41
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #34
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 09    LDX #9
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
26 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
27 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
29 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
38 bytes
18   ... CLC      × 36
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 36
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 36
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 36
Requires support for unofficial opcodes
39 bytes
4C xx xx JMP *+3
EA   ... NOP      × 36
Not relocatable code


76 cycles

5 bytes
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #49
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
30 FC    BMI *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
08       PHP
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
28       PLP
Clobbers Y; and writes in stack
08       PHP
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers A, and X; and writes in stack
48       PHA
A9       LDA #42
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #42
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
D0 FC    BNE *-2
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and requires @zptemp
04 04    NOP $04
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
Clobbers A, S, and Z&N; and writes in stack
48       PHA
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
Clobbers A, and Z&N
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
10 FA    BPL *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
48       PHA
A9       LDA #35
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
18       CLC
D0 FC    BNE *-2
28       PLP
68       PLA
28       PLP
Writes in stack
26 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N
38 bytes
EA   ... NOP      × 38
No requirements


77 cycles

5 bytes
A9       LDA #50
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #43
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #43
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
03 xx    SLO (@ptrtemp,X)
Clobbers A, X, Z&N, and C; and requires @ptrtemp, and support for unofficial opcodes
A0 0A    LDY #10 ;hides 'ASL A'
88       DEY
D0 FC    BNE *-2
13 xx    SLO (@ptrtemp,Y)
Clobbers A, Y, Z&N, and C; and requires @ptrtemp, and support for unofficial opcodes
48   ... PHA      × 2
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
68       PLA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
EA       NOP
68       PLA
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
68       PLA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
8 bytes
EA       NOP
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 0D    LDY #13
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #36
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
68       PLA
28       PLP
Requires @zptemp; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 0C    LDA #12
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
26 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
27 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
28 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
30 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X
76 36    ROR $36,X
26 26... ROL $26  × 9
Clobbers Z&N
39 bytes
18   ... CLC      × 37
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 37
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 37
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 37
Requires support for unofficial opcodes
40 bytes
4C xx xx JMP *+3
EA   ... NOP      × 37
Not relocatable code


78 cycles

5 bytes
A9       LDA #51
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 0B    LDY #11
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
30 FC    BMI *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
38       SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #44
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #44
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
68       PLA
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, Z&N, and C
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #37
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
EA   ... NOP      × 2
B0 FA    BCS *-4
68       PLA
28       PLP
Writes in stack
26 bytes
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
39 bytes
EA   ... NOP      × 39
No requirements


79 cycles

5 bytes
A9       LDA #52
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
A0 88    LDY #136 ;hides 'DEY'
48       PHA
30 FC    BMI *-2
Clobbers Y, S, and Z&N; and writes in stack
6 bytes
A0 88    LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
Clobbers Y, Z&N, and C
A0 88    LDY #136 ;hides 'DEY'
24 24    BIT $24
30 FB    BMI *-3
Clobbers Y, Z&N, and V
A0 88    LDY #136 ;hides 'DEY'
A5 A5    LDA $A5
30 FB    BMI *-3
Clobbers A, Y, and Z&N
A0 88    LDY #136 ;hides 'DEY'
A6 A6    LDX $A6
30 FB    BMI *-3
Clobbers X, Y, and Z&N
A0 88    LDY #136 ;hides 'DEY'
85 xx    STA @zptemp
30 FB    BMI *-3
Clobbers Y, and Z&N; and requires @zptemp
A0 88    LDY #136 ;hides 'DEY'
04 04    NOP $04
30 FB    BMI *-3
Clobbers Y, and Z&N; and requires support for unofficial opcodes
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
18       CLC
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
48       PHA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
A6 A6    LDX $A6
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and requires @zptemp
48       PHA
A9       LDA #45
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #45
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and requires support for unofficial opcodes
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
08       PHP
28       PLP
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
18       CLC
D0 F9    BNE *-5
Clobbers A, Z&N, and C; and not relocatable code
68       PLA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48       PHA
08       PHP
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
28       PLP
Clobbers Y, and S; and writes in stack
48       PHA
08       PHP
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers A, X, and S; and writes in stack
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A4 A4    LDY $A4
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
28       PLP
Clobbers Y; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers A, and X; and writes in stack
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
48       PHA
A9       LDA #38
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
27 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
28 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
29 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
30 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
40 bytes
18   ... CLC      × 38
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 38
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 38
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 38
Requires support for unofficial opcodes
41 bytes
4C xx xx JMP *+3
EA   ... NOP      × 38
Not relocatable code


80 cycles

5 bytes
A9       LDA #53
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 88    LDX #136 ;hides 'DEY'
EA       NOP
CA       DEX
30 FB    BMI *-3
Clobbers X, Y, and Z&N
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
30 FC    BMI *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
68       PLA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #46
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #46
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
9 bytes
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #39
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; requires @zptemp; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 09    LDA #9
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
27 bytes
EA       NOP
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
40 bytes
EA   ... NOP      × 40
No requirements


81 cycles

5 bytes
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #54
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
48       PHA
30 FB    BMI *-3
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
E6 xx    INC @zptemp
90 FA    BCC *-4
Clobbers A, Z&N, C, and V; and requires @zptemp
48       PHA
A9       LDA #47
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #47
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
18       CLC
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and requires @zptemp
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts15
90 FA    BCC *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and requires support for unofficial opcodes
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
00 00    BRK 0
90 FA    BCC *-4
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
08       PHP
28       PLP
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
4C xx xx JMP *+3
18       CLC
D0 F9    BNE *-5
Clobbers A, Z&N, and C; and not relocatable code
08       PHP
A6 A6    LDX $A6
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #40
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; and writes in stack
10 bytes
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 3
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
F6 F6    INC $F6,X
90 FB    BCC *-3
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 0C    LDX #12
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
28 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
29 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
30 bytes
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
41 bytes
18   ... CLC      × 39
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 39
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 39
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 39
Requires support for unofficial opcodes
42 bytes
4C xx xx JMP *+3
EA   ... NOP      × 39
Not relocatable code


82 cycles

5 bytes
A9       LDA #55
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A0 88    LDY #136 ;hides 'DEY'
48       PHA
30 FC    BMI *-2
Clobbers Y, S, and Z&N; and writes in stack
A2 09    LDX #9
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 09    LDY #9
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
A2 09    LDX #9
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N
A0 09    LDY #9
EA   ... NOP      × 2
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N
48       PHA
A9       LDA #48
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #48
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
18       CLC
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
8C       TXA
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #41
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 0D    LDA #13
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
28 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N
41 bytes
EA   ... NOP      × 41
No requirements


83 cycles

5 bytes
A9       LDA #56
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
Clobbers A, Z&N, C, V, and D
EA       NOP
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 10    LDA #16
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #49
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #49
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
98       TYA
A0 88    LDY #136 ;hides 'DEY'
48       PHA
30 FC    BMI *-2
A8       TAY
Clobbers A, S, and Z&N; and writes in stack
8 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
A8       TAY
Clobbers A, Z&N, and C
98       TYA
A0 88    LDY #136 ;hides 'DEY'
24 24    BIT $24
30 FB    BMI *-3
A8       TAY
Clobbers A, Z&N, and V
98       TYA
A0 88    LDY #136 ;hides 'DEY'
85 xx    STA @zptemp
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N; and requires @zptemp
98       TYA
A0 88    LDY #136 ;hides 'DEY'
04 04    NOP $04
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N; and requires support for unofficial opcodes
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #42
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
10 bytes
E6 xx    INC @zptemp
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp; and writes in stack
08       PHP
E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
28       PLP
Clobbers A; requires @zptemp; and writes in stack
04 04    NOP $04
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
04 04    NOP $04
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
68       PLA
Clobbers S, and Z&N; and writes in stack
48       PHA
08       PHP
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
28       PLP
Clobbers A, and S; and writes in stack
11 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
10 FA    BPL *-4
68       PLA
28       PLP
Writes in stack
28 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
29 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X
76 36    ROR $36,X
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
30 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
31 bytes
EA       NOP
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
42 bytes
18   ... CLC      × 40
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 40
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 40
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 40
Requires support for unofficial opcodes
43 bytes
4C xx xx JMP *+3
EA   ... NOP      × 40
Not relocatable code


84 cycles

5 bytes
A9       LDA #57
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12; and writes in stack
48       PHA
A9       LDA #50
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #50
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68   ... PLA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
30 FC    BMI *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
E6 xx    INC @zptemp
28       PLP
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires @zptemp; and writes in stack
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #43
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
08       PHP
A2 0A    LDX #10 ;hides 'ASL A'
CA       DEX
D0 FC    BNE *-2
03 xx    SLO (@ptrtemp,X)
28       PLP
Clobbers A, and X; requires @ptrtemp, and support for unofficial opcodes; and writes in stack
08       PHP
A0 0A    LDY #10 ;hides 'ASL A'
88       DEY
D0 FC    BNE *-2
13 xx    SLO (@ptrtemp,Y)
28       PLP
Clobbers A, and Y; requires @ptrtemp, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 0E    LDY #14
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
28 bytes
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N
42 bytes
EA   ... NOP      × 42
No requirements


85 cycles

5 bytes
A9       LDA #58
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 0C    LDY #12
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9       LDA #51
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #51
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0B    LDY #11
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #44
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
29 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
30 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
31 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
32 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
43 bytes
18   ... CLC      × 41
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 41
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 41
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 41
Requires support for unofficial opcodes
44 bytes
4C xx xx JMP *+3
EA   ... NOP      × 41
Not relocatable code


86 cycles

5 bytes
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #59
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #52
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #52
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
Clobbers A, S, Z&N, C, V, and D; and writes in stack
8 bytes
A5 A5    LDA $A5
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
Clobbers A, Z&N, C, V, and D
08       PHP
A0 88    LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
28       PLP
Clobbers Y; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12; and writes in stack
00 00    BRK 0
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
48       PHA
30 FC    BMI *-2
A8       TAY
Clobbers A, S, and Z&N; and writes in stack
48       PHA
08       PHP
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
8C       TXA
A2 09    LDX #9
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires @zptemp; and writes in stack
08       PHP
48       PHA
A9       LDA #45
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
08       PHP
28       PLP
18       CLC
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 0D    LDX #13
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
29 bytes
EA       NOP
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N
43 bytes
EA   ... NOP      × 43
No requirements


87 cycles

5 bytes
A9       LDA #60
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
A2 F8    LDX #248 ;hides 'SED'
68       PLA
E8       INX
D0 FB    BNE *-3
Clobbers A, X, S, Z&N, and D
A0 F8    LDY #248 ;hides 'SED'
68       PLA
C8       INY
D0 FB    BNE *-3
Clobbers A, Y, S, Z&N, and D
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C
EA       NOP
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
EA       NOP
A0 0C    LDY #12
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
48       PHA
A9       LDA #53
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #53
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 88    LDX #136 ;hides 'DEY'
EA       NOP
CA       DEX
30 FB    BMI *-3
28       PLP
Clobbers X, and Y; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 0F    LDY #15
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #46
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
11 bytes
08       PHP
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
68       PLA
28       PLP
Writes in stack
30 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
31 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
33 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
44 bytes
18   ... CLC      × 42
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 42
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 42
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 42
Requires support for unofficial opcodes
45 bytes
4C xx xx JMP *+3
EA   ... NOP      × 42
Not relocatable code


88 cycles

5 bytes
A9       LDA #61
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
Clobbers A, Z&N, C, V, and D
EA       NOP
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 11    LDA #17
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #54
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #54
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
E6 xx    INC @zptemp
90 FA    BCC *-4
68       PLA
Clobbers Z&N, C, and V; requires @zptemp; and writes in stack
08       PHP
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
E6 xx    INC @zptemp
90 FA    BCC *-4
28       PLP
Clobbers A; requires @zptemp; and writes in stack
08       PHP
48       PHA
A9       LDA #47
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
10 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires @zptemp; and writes in stack
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
20 xx xx JSR @rts15
90 FA    BCC *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires support for unofficial opcodes; and writes in stack
48       PHA
18       CLC
A9 2A    LDA #$2A ;hides 'ROL A'
EA       NOP
00 00    BRK 0
90 FA    BCC *-4
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
11 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
08       PHP
28       PLP
18       CLC
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; and writes in stack
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
30 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
44 bytes
EA   ... NOP      × 44
No requirements


89 cycles

5 bytes
A9       LDA #62
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
A0 88    LDY #136 ;hides 'DEY'
68       PLA
30 FC    BMI *-2
Clobbers A, Y, S, and Z&N
6 bytes
A0 88    LDY #136 ;hides 'DEY'
EA   ... NOP      × 2
30 FB    BMI *-3
Clobbers Y, and Z&N
A2 0A    LDX #10 ;hides 'ASL A'
EA       NOP
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, Z&N, and C
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
A2 0B    LDX #11
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
F6 F6    INC $F6,X
90 FA    BCC *-4
Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #55
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #55
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
A2 09    LDX #9
EA   ... NOP      × 2
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 09    LDY #9
EA   ... NOP      × 2
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #48
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
30 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
31 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
32 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
34 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
45 bytes
18   ... CLC      × 43
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 43
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 43
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 43
Requires support for unofficial opcodes
46 bytes
4C xx xx JMP *+3
EA   ... NOP      × 43
Not relocatable code


90 cycles

5 bytes
A9       LDA #63
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #56
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #56
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
Clobbers Z&N, C, V, and D; and writes in stack
08       PHP
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 10    LDA #16
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
48       PHA
A9       LDA #49
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
C5 C5    CMP $C5
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N, and C; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
24 24    BIT $24
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N, and V; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
85 xx    STA @zptemp
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
04 04    NOP $04
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
48       PHA
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
12 bytes
08       PHP
E6 xx    INC @zptemp
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
28       PLP
Requires @zptemp; and writes in stack
04 04    NOP $04
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
68       PLA
28       PLP
Clobbers S; and writes in stack
13 bytes
08       PHP
48       PHA
A5 A5    LDA $A5
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA       NOP
30 FC    BMI *-2
A8       TAY
68       PLA
28       PLP
Writes in stack
30 bytes
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
45 bytes
EA   ... NOP      × 45
No requirements


91 cycles

5 bytes
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #64
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA   ... NOP      × 2
30 FA    BMI *-4
Clobbers A, Z&N, C, and V
48       PHA
A9       LDA #57
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #57
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
D0 FA    BNE *-4
Clobbers A, S, Z&N, and C
48       PHA
08       PHP
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
EA       NOP
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
08       PHP
A6 A6    LDX $A6
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 10    LDY #16
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
28       PLP
Clobbers A; requires @rts12; and writes in stack
08       PHP
48       PHA
A9       LDA #50
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
E6 xx    INC @zptemp
28       PLP
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires @zptemp; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
E6 xx    INC @zptemp
28       PLP
10 F9    BPL *-5
28       PLP
Clobbers A; requires @zptemp; and writes in stack
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
38       SEC
A9 09    LDA #9
EA   ... NOP      × 2
E9 01    SBC #1
D0 F9    BNE *-5
28       PLP
Clobbers A; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 0E    LDX #14
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
31 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
32 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
33 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
34 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
46 bytes
18   ... CLC      × 44
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 44
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 44
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 44
Requires support for unofficial opcodes
47 bytes
4C xx xx JMP *+3
EA   ... NOP      × 44
Not relocatable code


92 cycles

5 bytes
A9       LDA #65
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 0D    LDY #13
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #58
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #58
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
Clobbers A, S, Z&N, C, V, and D
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0C    LDY #12
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #51
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 0F    LDA #15
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
31 bytes
EA       NOP
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
46 bytes
EA   ... NOP      × 46
No requirements


93 cycles

5 bytes
A9       LDA #66
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #59
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #59
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA   ... NOP      × 2
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N
9 bytes
08       PHP
48       PHA
A9       LDA #52
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
Clobbers S, Z&N, C, V, and D; and writes in stack
48       PHA
08       PHP
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
28       PLP
Clobbers A, and S; and writes in stack
10 bytes
24 24    BIT $24
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
Clobbers Z&N, C, V, and D; and writes in stack
08       PHP
A5 A5    LDA $A5
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12; and writes in stack
00 00    BRK 0
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
38       SEC
A9 10    LDA #16
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
11 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
32 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
33 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
34 bytes
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
47 bytes
18   ... CLC      × 45
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 45
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 45
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 45
Requires support for unofficial opcodes
48 bytes
4C xx xx JMP *+3
EA   ... NOP      × 45
Not relocatable code


94 cycles

5 bytes
A9       LDA #67
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
48       PHA
A9       LDA #60
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #60
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
38       SEC
A9 0D    LDA #13
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP       \ × 2
28       PLP       /
10 F9    BPL *-5
Clobbers A, Z&N, and C; and writes in stack
68       PLA
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 0C    LDY #12
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #53
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 0F    LDX #15
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
32 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N
47 bytes
EA   ... NOP      × 47
No requirements


95 cycles

5 bytes
A9       LDA #68
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and writes in stack
68       PLA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #61
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #61
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
Clobbers Z&N, C, V, and D; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 11    LDA #17
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
48       PHA
A9       LDA #54
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48   ... PHA      × 2
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
E6 xx    INC @zptemp
90 FA    BCC *-4
68       PLA
28       PLP
Requires @zptemp; and writes in stack
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
12 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
B8       CLV
50 00    BVC *+2
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
32 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
33 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 2
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
34 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
35 bytes
EA       NOP
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
48 bytes
18   ... CLC      × 46
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 46
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 46
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 46
Requires support for unofficial opcodes
49 bytes
4C xx xx JMP *+3
EA   ... NOP      × 46
Not relocatable code


96 cycles

5 bytes
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #69
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #62
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #62
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
8C       TXA
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
08       PHP
A0 88    LDY #136 ;hides 'DEY'
EA   ... NOP      × 2
30 FB    BMI *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
A2 0A    LDX #10 ;hides 'ASL A'
EA       NOP
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers A, and X; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
08       PHP
A2 0B    LDX #11
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
48       PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
F6 F6    INC $F6,X
90 FA    BCC *-4
68       PLA
Clobbers Z&N, C, and V; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
F6 F6    INC $F6,X
90 FA    BCC *-4
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #55
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 0B    LDX #11
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
32 bytes
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N
48 bytes
EA   ... NOP      × 48
No requirements


97 cycles

5 bytes
A9       LDA #70
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0C    LDX #12
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 0C    LDY #12
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and writes in stack
A2 0C    LDX #12
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
Clobbers X, Z&N, and C
A0 0C    LDY #12
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
Clobbers Y, Z&N, and C
A2 0C    LDX #12
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
Clobbers X, Z&N, and V
A0 0C    LDY #12
24 24    BIT $24
88       DEY
D0 FB    BNE *-3
Clobbers Y, Z&N, and V
A2 08    LDX #8
08       PHP
28       PLP
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N; and writes in stack
A0 08    LDY #8
08       PHP
28       PLP
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and writes in stack
A2 0C    LDX #12
A5 A5    LDA $A5
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, and Z&N
A0 0C    LDY #12
A5 A5    LDA $A5
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, and Z&N
A2 0C    LDX #12
A4 A4    LDY $A4
CA       DEX
D0 FB    BNE *-3
Clobbers X, Y, and Z&N
A2 0C    LDX #12
85 xx    STA @zptemp
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N; and requires @zptemp
A0 0C    LDY #12
85 xx    STA @zptemp
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and requires @zptemp
48       PHA
A9       LDA #63
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #63
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A2 0C    LDX #12
04 04    NOP $04
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 0C    LDY #12
04 04    NOP $04
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and requires support for unofficial opcodes
8 bytes
EA       NOP
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 11    LDY #17
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #56
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
33 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
34 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
35 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
36 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
49 bytes
18   ... CLC      × 47
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 47
50 00    BVC *+2
Clobbers V
85 xx    STA @zptemp
EA   ... NOP      × 47
Requires @zptemp
04 04    NOP $04
EA   ... NOP      × 47
Requires support for unofficial opcodes
50 bytes
EA   ... NOP      × 47
4C xx xx JMP *+3
Not relocatable code


98 cycles

5 bytes
A9       LDA #71
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #64
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #64
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and writes in stack
48       PHA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA   ... NOP      × 2
30 FA    BMI *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
A5 A5    LDA $A5
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA   ... NOP      × 2
30 FA    BMI *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #57
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
11 bytes
EA       NOP
48       PHA
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts12
10 FA    BPL *-4
68       PLA
28       PLP
Requires @rts12; and writes in stack
12 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
E6 xx    INC @zptemp
28       PLP
10 F9    BPL *-5
68       PLA
28       PLP
Requires @zptemp; and writes in stack
00 00    BRK 0
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
18       CLC
D0 FB    BNE *-3
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
04 04    NOP $04
30 FA    BMI *-4
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
13 bytes
08       PHP
48       PHA
38       SEC
A9 09    LDA #9
EA   ... NOP      × 2
E9 01    SBC #1
D0 F9    BNE *-5
68       PLA
28       PLP
Writes in stack
33 bytes
EA       NOP
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N
49 bytes
EA   ... NOP      × 49
No requirements


99 cycles

5 bytes
A9       LDA #72
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 0E    LDY #14
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
48       PHA
A9       LDA #65
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #65
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
EA   ... NOP      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; and writes in stack
08       PHP
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0D    LDY #13
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
68       PLA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #58
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68       PLA
Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
28       PLP
Clobbers A, and S; requires dummy interrupt handler; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 10    LDX #16
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
34 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
35 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
37 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
50 bytes
18   ... CLC      × 48
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 48
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 48
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 48
04 04    NOP $04
Requires support for unofficial opcodes
51 bytes
EA   ... NOP      × 48
4C xx xx JMP *+3
Not relocatable code


100 cycles

5 bytes
A9       LDA #73
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0B    LDX #11
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 0B    LDY #11
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #66
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #66
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #59
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
EA   ... NOP      × 2
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
48       PHA
08       PHP
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
24 24    BIT $24
48       PHA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
34 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
50 bytes
EA   ... NOP      × 50
No requirements


101 cycles

5 bytes
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #74
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #67
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #67
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
48       PHA
30 FA    BMI *-4
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
38       SEC
A9 0E    LDA #14
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
8C       TXA
A2 0C    LDX #12
48       PHA
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
48       PHA
08       PHP
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
8C       TXA
A2 0C    LDX #12
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, Z&N, and C
8C       TXA
A2 0C    LDX #12
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, Z&N, and V
8C       TXA
A2 08    LDX #8
08       PHP
28       PLP
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 0C    LDX #12
85 xx    STA @zptemp
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
28       PLP
Clobbers A; requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9       LDA #60
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
8C       TXA
A2 0C    LDX #12
04 04    NOP $04
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
EA       NOP
68       PLA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP       \ × 2
28       PLP       /
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 3
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
38       SEC
A9 0D    LDA #13
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
EA   ... NOP      × 2
18       CLC
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
34 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
35 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
36 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
38 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
51 bytes
18   ... CLC      × 49
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 49
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 49
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 49
04 04    NOP $04
Requires support for unofficial opcodes
52 bytes
EA   ... NOP      × 49
4C xx xx JMP *+3
Not relocatable code


102 cycles

5 bytes
A9       LDA #75
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #68
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #68
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
A2 0B    LDX #11
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
EA       NOP
A0 0B    LDY #11
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
8 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
EA       NOP
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
A6 A6    LDX $A6
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 0E    LDY #14
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 12    LDY #18
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #61
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
10 FC    BPL *-2
68       PLA
28       PLP
Writes in stack
34 bytes
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
51 bytes
EA   ... NOP      × 51
No requirements


103 cycles

5 bytes
A9       LDA #76
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$08'
08       PHP ;first loop only
90 FC    BCC *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #69
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #69
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
18       CLC
D0 FA    BNE *-4
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
8C       TXA
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
48       PHA
A9       LDA #62
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
11 bytes
08       PHP
48       PHA
A9 69    LDA #$69 ;hides 'ADC #$18'
18       CLC ;first loop only
F6 F6    INC $F6,X
90 FA    BCC *-4
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 0C    LDX #12
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
35 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
36 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
37 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
38 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
52 bytes
18   ... CLC      × 50
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 50
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 50
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 50
04 04    NOP $04
Requires support for unofficial opcodes
53 bytes
EA   ... NOP      × 50
4C xx xx JMP *+3
Not relocatable code


104 cycles

5 bytes
A9       LDA #77
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #70
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #70
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
00 00    BRK 0
10 FA    BPL *-4
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
00 00    BRK 0
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
00 00    BRK 0
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
68       PLA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
EA   ... NOP      × 2
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 0C    LDX #12
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0C    LDY #12
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #63
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
35 bytes
EA       NOP
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
52 bytes
EA   ... NOP      × 52
No requirements


105 cycles

5 bytes
A9       LDA #78
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 0D    LDX #13
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 0D    LDY #13
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
68       PLA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #71
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #71
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #64
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; and writes in stack
10 bytes
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA   ... NOP      × 2
30 FA    BMI *-4
68       PLA
28       PLP
Writes in stack
36 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
37 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
38 bytes
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
53 bytes
18   ... CLC      × 51
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 51
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 51
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 51
04 04    NOP $04
Requires support for unofficial opcodes
54 bytes
EA   ... NOP      × 51
4C xx xx JMP *+3
Not relocatable code


106 cycles

5 bytes
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #79
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
EA       NOP
30 FB    BMI *-3
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
48       PHA
A9       LDA #72
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #72
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0E    LDY #14
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
48   ... PHA      × 2
18       CLC
D0 FA    BNE *-4
Clobbers A, S, Z&N, and C; and writes in stack
9 bytes
A5 A5    LDA $A5
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
28       PLP
Clobbers A; requires @rts12, and @rts15; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9       LDA #65
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 2
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; and writes in stack
A5 A5    LDA $A5
8C       TXA
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 12    LDX #18
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
48       PHA
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
10 FB    BPL *-3
68       PLA
28       PLP
Clobbers S; requires dummy interrupt handler; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 11    LDX #17
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
36 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N
53 bytes
EA   ... NOP      × 53
No requirements


107 cycles

5 bytes
A9       LDA #80
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 18    LDX #24 ;hides 'CLC'
CA   ... DEX      × 2
D0 FB    BNE *-3
Clobbers X, and Z&N
A0 18    LDY #24 ;hides 'CLC'
88   ... DEY      × 2
D0 FB    BNE *-3
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #73
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #73
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$08'
08       PHP ;first loop only
90 FC    BCC *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
9 bytes
48       PHA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #66
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 12    LDA #18
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
36 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
37 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 3
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
38 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
39 bytes
EA       NOP
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
54 bytes
18   ... CLC      × 52
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 52
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 52
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 52
04 04    NOP $04
Requires support for unofficial opcodes
55 bytes
EA   ... NOP      × 52
4C xx xx JMP *+3
Not relocatable code


108 cycles

5 bytes
A9       LDA #81
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #74
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #74
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #67
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
10 bytes
48       PHA
38       SEC
A9 0E    LDA #14
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 0E    LDA #14
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 08    LDX #8
08       PHP
28       PLP
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
10 FA    BPL *-4
68       PLA
28       PLP
Requires @rts12, and @rts14; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 0D    LDA #13
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
36 bytes
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N
54 bytes
EA   ... NOP      × 54
No requirements


109 cycles

5 bytes
A9       LDA #82
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
A2 0C    LDX #12
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 0C    LDY #12
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
A6 A6    LDX $A6
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #75
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #75
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
EA       NOP
30 FB    BMI *-3
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
18       CLC
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
18       CLC
A9 F4    LDA #244 ;hides 'NOP zp,X'
EA       NOP
69 01    ADC #1
D0 F9    BNE *-5
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
68       PLA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #68
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 13    LDY #19
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
37 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
38 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
39 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
40 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
55 bytes
18   ... CLC      × 53
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 53
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 53
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 53
04 04    NOP $04
Requires support for unofficial opcodes
56 bytes
EA   ... NOP      × 53
4C xx xx JMP *+3
Not relocatable code


110 cycles

5 bytes
A9       LDA #83
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #76
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #76
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #69
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 0E    LDX #14
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 0D    LDX #13
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
37 bytes
EA       NOP
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N
55 bytes
EA   ... NOP      × 55
No requirements


111 cycles

5 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and writes in stack
48       PHA
A9       LDA #77
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #77
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
CA   ... DEX      × 2
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N
48       PHA
08       PHP
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 14    LDY #20
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #70
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
28       PLP
Clobbers A; requires @rts12, and @rts14; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
00 00    BRK 0
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
00 00    BRK 0
10 F9    BPL *-5
28       PLP
Clobbers A; requires @zptemp, and dummy interrupt handler; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
00 00    BRK 0
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
00 00    BRK 0
10 F9    BPL *-5
28       PLP
Clobbers A; requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
11 bytes
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
38 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
39 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
41 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
56 bytes
18   ... CLC      × 54
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 54
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 54
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 54
04 04    NOP $04
Requires support for unofficial opcodes
57 bytes
EA   ... NOP      × 54
4C xx xx JMP *+3
Not relocatable code


112 cycles

5 bytes
A9       LDA #85
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #78
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #78
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
68       PLA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
EA       NOP
68       PLA
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
8 bytes
EA       NOP
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 0D    LDX #13
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 0D    LDY #13
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #71
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 13    LDA #19
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
38 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
56 bytes
EA   ... NOP      × 56
No requirements


113 cycles

5 bytes
A9       LDA #86
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 10    LDY #16
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #79
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #79
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; and writes in stack
98       TYA
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
A8       TAY
Clobbers A, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #72
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48   ... PHA      × 2
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
48       PHA
08       PHP
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; and writes in stack
11 bytes
24 24    BIT $24
48       PHA
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A5 A5    LDA $A5
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
48       PHA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
10 FA    BPL *-4
68       PLA
28       PLP
Requires @rts12, and @rts15; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
10 FA    BPL *-4
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
12 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
38 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
39 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 8
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
40 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
42 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
57 bytes
18   ... CLC      × 55
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 55
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 55
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 55
04 04    NOP $04
Requires support for unofficial opcodes
58 bytes
EA   ... NOP      × 55
4C xx xx JMP *+3
Not relocatable code


114 cycles

5 bytes
A9       LDA #87
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
48       PHA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A5 A5    LDA $A5
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
A6 A6    LDX $A6
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #80
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #80
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A2 18    LDX #24 ;hides 'CLC'
CA   ... DEX      × 2
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 18    LDY #24 ;hides 'CLC'
88   ... DEY      × 2
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
68       PLA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #73
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
38 bytes
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
57 bytes
EA   ... NOP      × 57
No requirements


115 cycles

5 bytes
A9       LDA #88
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V
68       PLA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #81
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #81
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #74
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
00 00    BRK 0
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 0E    LDA #14
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
39 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
40 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
41 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
42 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
58 bytes
18   ... CLC      × 56
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 56
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 56
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 56
04 04    NOP $04
Requires support for unofficial opcodes
59 bytes
EA   ... NOP      × 56
4C xx xx JMP *+3
Not relocatable code


116 cycles

5 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 17    LDY #23
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #82
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #82
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
48       PHA
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #75
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
08       PHP
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
18       CLC
10 F9    BPL *-5
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
18       CLC
10 F9    BPL *-5
28       PLP
Clobbers A; requires @rts12, and @rts15; and writes in stack
48       PHA
18       CLC
A9 F4    LDA #244 ;hides 'NOP zp,X'
EA       NOP
69 01    ADC #1
D0 F9    BNE *-5
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
18       CLC
A9 F4    LDA #244 ;hides 'NOP zp,X'
EA       NOP
69 01    ADC #1
D0 F9    BNE *-5
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 0D    LDX #13
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
AA       TAX
28       PLP
Clobbers A; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
39 bytes
EA       NOP
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
58 bytes
EA   ... NOP      × 58
No requirements


117 cycles

5 bytes
A9       LDA #90
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 0D    LDX #13 ;hides 'ORA abs'
A5 A5    LDA $A5
CA       DEX
D0 FA    BNE *-4
Clobbers A, X, and Z&N
A0 0D    LDY #13 ;hides 'ORA abs'
A5 A5    LDA $A5
88       DEY
D0 FA    BNE *-4
Clobbers A, Y, and Z&N
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
F6 F6    INC $F6,X
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #83
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #83
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A2 0C    LDX #12 ;hides 'NOP abs'
44 00    NOP $0
CA       DEX
10 FA    BPL *-4
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 0C    LDY #12 ;hides 'NOP abs'
44 00    NOP $0
88       DEY
10 FA    BPL *-4
Clobbers Y, and Z&N; and requires support for unofficial opcodes
EA       NOP
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V
48   ... PHA      × 2
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
8 bytes
8C       TXA
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #76
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
40 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
41 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
42 bytes
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
59 bytes
18   ... CLC      × 57
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 57
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 57
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 57
04 04    NOP $04
Requires support for unofficial opcodes
60 bytes
EA   ... NOP      × 57
4C xx xx JMP *+3
Not relocatable code


118 cycles

5 bytes
A9       LDA #91
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V
EA       NOP
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 17    LDY #23
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
A5 A5    LDA $A5
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #77
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
CA   ... DEX      × 2
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
18       CLC
10 F9    BPL *-5
68       PLA
28       PLP
Requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
85 xx    STA @zptemp
00 00    BRK 0
10 F9    BPL *-5
68       PLA
28       PLP
Requires @zptemp, and dummy interrupt handler; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
04 04    NOP $04
00 00    BRK 0
10 F9    BPL *-5
68       PLA
28       PLP
Requires dummy interrupt handler, and support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$5A'
5A       NOP ;first loop only
EA       NOP
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
13 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
8C       TXA
A2 13    LDX #19
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
40 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N
59 bytes
EA   ... NOP      × 59
No requirements


119 cycles

5 bytes
A9       LDA #92
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A0 88    LDY #136 ;hides 'DEY'
08       PHP
28       PLP
30 FB    BMI *-3
Clobbers Y, and Z&N; and writes in stack
A0 88    LDY #136 ;hides 'DEY'
68       PLA
48       PHA
30 FB    BMI *-3
Clobbers A, Y, and Z&N
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
48       PHA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
7 bytes
A5 A5    LDA $A5
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V
A6 A6    LDX $A6
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 17    LDY #23
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #85
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #85
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
48       PHA
08       PHP
28       PLP
D0 FA    BNE *-4
Clobbers A, S, Z&N, and C; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
24 24    BIT $24
28       PLP
D0 F9    BNE *-5
Clobbers A, Z&N, and C; and writes in stack
68       PLA
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #78
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 15    LDY #21
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
40 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
41 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 4
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
42 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
43 bytes
EA       NOP
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
60 bytes
18   ... CLC      × 58
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 58
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 58
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 58
04 04    NOP $04
Requires support for unofficial opcodes
61 bytes
EA   ... NOP      × 58
4C xx xx JMP *+3
Not relocatable code


120 cycles

5 bytes
A9       LDA #93
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 11    LDY #17
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V
7 bytes
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9       LDA #86
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #86
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 10    LDY #16
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9       LDA #79
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; and writes in stack
48       PHA
98       TYA
A0 88    LDY #136 ;hides 'DEY'
F6 F6    INC $F6,X
30 FB    BMI *-3
A8       TAY
68       PLA
Clobbers Z&N; requires @zptemp, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
48       PHA
08       PHP
48       PHA
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; and writes in stack
13 bytes
08       PHP
24 24    BIT $24
48       PHA
38       SEC
A9 14    LDA #20
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
40 bytes
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N
60 bytes
EA   ... NOP      × 60
No requirements


121 cycles

5 bytes
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #94
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
08       PHP
28       PLP
30 FA    BMI *-4
Clobbers A, Z&N, C, and V; and writes in stack
E6 xx    INC @zptemp
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V; and requires @zptemp
48       PHA
A9       LDA #87
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #87
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
A5 A5    LDA $A5
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
90 FA    BCC *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
00 00    BRK 0
90 FA    BCC *-4
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
48       PHA
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; and writes in stack
48       PHA
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
24 24    BIT $24
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A5 A5    LDA $A5
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #80
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
8C       TXA
A2 0C    LDX #12 ;hides 'NOP abs'
44 00    NOP $0
CA       DEX
10 FA    BPL *-4
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
EA       NOP
68       PLA
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
28       PLP
18       CLC
D0 FA    BNE *-4
68       PLA
Clobbers S, Z&N, and C; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 14    LDX #20
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
41 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
42 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
43 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
44 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
61 bytes
18   ... CLC      × 59
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 59
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 59
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 59
04 04    NOP $04
Requires support for unofficial opcodes
62 bytes
EA   ... NOP      × 59
4C xx xx JMP *+3
Not relocatable code


122 cycles

5 bytes
A9       LDA #95
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
EA       NOP
10 FB    BPL *-3
Clobbers A, Z&N, C, V, and D
EA       NOP
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
EA       NOP
A0 11    LDY #17
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
F6 F6    INC $F6,X
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #88
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #88
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V
8 bytes
EA       NOP
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
9 bytes
48       PHA
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #81
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 15    LDA #21
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
41 bytes
EA       NOP
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N
61 bytes
EA   ... NOP      × 61
No requirements


123 cycles

5 bytes
A9       LDA #96
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
38       SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 17    LDY #23
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #82
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
08       PHP
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
90 FB    BCC *-3
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
12 bytes
EA   ... NOP      × 3
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
18       CLC
10 F9    BPL *-5
68       PLA
28       PLP
Requires @rts12, and @rts15; and writes in stack
08       PHP
48       PHA
18       CLC
A9 F4    LDA #244 ;hides 'NOP zp,X'
EA       NOP
69 01    ADC #1
D0 F9    BNE *-5
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
13 bytes
08       PHP
48       PHA
8C       TXA
A2 0D    LDX #13
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
28       PLP
Writes in stack
42 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
43 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
45 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
62 bytes
18   ... CLC      × 60
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 60
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 60
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 60
04 04    NOP $04
Requires support for unofficial opcodes
63 bytes
EA   ... NOP      × 60
4C xx xx JMP *+3
Not relocatable code


124 cycles

4 bytes
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers X, and Z&N
5 bytes
A9       LDA #97
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A4 A4    LDY $A4
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #90
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #90
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; requires dummy interrupt handler; and writes in stack
68   ... PLA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V
8 bytes
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
A2 0D    LDX #13 ;hides 'ORA abs'
A5 A5    LDA $A5
CA       DEX
D0 FA    BNE *-4
28       PLP
Clobbers A, and X; and writes in stack
08       PHP
A0 0D    LDY #13 ;hides 'ORA abs'
A5 A5    LDA $A5
88       DEY
D0 FA    BNE *-4
28       PLP
Clobbers A, and Y; and writes in stack
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
F6 F6    INC $F6,X
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #83
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
08       PHP
A2 0C    LDX #12 ;hides 'NOP abs'
44 00    NOP $0
CA       DEX
10 FA    BPL *-4
28       PLP
Clobbers X; requires support for unofficial opcodes; and writes in stack
08       PHP
A0 0C    LDY #12 ;hides 'NOP abs'
44 00    NOP $0
88       DEY
10 FA    BPL *-4
28       PLP
Clobbers Y; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 3
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
48   ... PHA      × 2
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 16    LDY #22
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
42 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
62 bytes
EA   ... NOP      × 62
No requirements


125 cycles

5 bytes
A9       LDA #98
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 1A    LDX #26 ;hides 'NOP'
CA   ... DEX      × 2
10 FB    BPL *-3
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 1A    LDY #26 ;hides 'NOP'
88   ... DEY      × 2
10 FB    BPL *-3
Clobbers Y, and Z&N; and requires support for unofficial opcodes
68       PLA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #91
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #91
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 17    LDY #23
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
42 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
43 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 9
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
44 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
46 bytes
26 26    ROL $26   \ × 2
66 26    ROR $26   /
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
63 bytes
18   ... CLC      × 61
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 61
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 61
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 61
04 04    NOP $04
Requires support for unofficial opcodes
64 bytes
EA   ... NOP      × 61
4C xx xx JMP *+3
Not relocatable code


126 cycles

5 bytes
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #99
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #92
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #92
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A0 88    LDY #136 ;hides 'DEY'
08       PHP
28       PLP
30 FB    BMI *-3
28       PLP
Clobbers Y; and writes in stack
20 xx xx JSR @rts15
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; requires @rts12, and @rts15; and writes in stack
EA       NOP
00 00    BRK 0
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
EA       NOP
68   ... PLA      × 2
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, S, Z&N, C, and V
48       PHA
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A, and S; and writes in stack
48       PHA
08       PHP
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
24 24    BIT $24
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; and writes in stack
EA       NOP
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
08       PHP
A5 A5    LDA $A5
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; and writes in stack
08       PHP
A6 A6    LDX $A6
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
48       PHA
A9       LDA #85
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
24 24    BIT $24
28       PLP
D0 F9    BNE *-5
68       PLA
Clobbers Z&N, and C; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 15    LDX #21
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
42 bytes
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
63 bytes
EA   ... NOP      × 63
No requirements


127 cycles

5 bytes
A9       LDA #100
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
48       PHA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
6 bytes
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 12    LDY #18
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #93
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #93
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
Clobbers A, Z&N, C, and V; requires dummy interrupt handler; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 11    LDY #17
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #86
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
43 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
44 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
45 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
46 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
64 bytes
18   ... CLC      × 62
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 62
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 62
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 62
04 04    NOP $04
Requires support for unofficial opcodes
65 bytes
EA   ... NOP      × 62
4C xx xx JMP *+3
Not relocatable code


128 cycles

5 bytes
A9       LDA #101
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
68       PLA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
6 bytes
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA       NOP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
08       PHP
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #94
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #94
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
9 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
08       PHP
28       PLP
30 FA    BMI *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
08       PHP
28       PLP
30 FA    BMI *-4
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #87
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
90 FA    BCC *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts15; and writes in stack
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
EA       NOP
00 00    BRK 0
90 FA    BCC *-4
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
24 24    BIT $24
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Writes in stack
43 bytes
EA       NOP
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
64 bytes
EA   ... NOP      × 64
No requirements


129 cycles

5 bytes
A9       LDA #102
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
E6 xx    INC @zptemp
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers X, and Z&N; and requires @zptemp
A2 10    LDX #16
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 10    LDY #16
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
A0 88    LDY #136 ;hides 'DEY'
68   ... PLA      × 2
30 FB    BMI *-3
Clobbers A, Y, S, and Z&N
7 bytes
A6 A6    LDX $A6
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #95
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #95
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
Clobbers A, Z&N, C, and V; requires dummy interrupt handler; and writes in stack
8 bytes
38       SEC
A9 12    LDA #18
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
8C       TXA
A2 1A    LDX #26 ;hides 'NOP'
CA   ... DEX      × 2
10 FB    BPL *-3
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
68       PLA
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
EA       NOP
10 FB    BPL *-3
68       PLA
Clobbers Z&N, C, V, and D; and writes in stack
EA   ... NOP      × 2
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
EA       NOP
10 FB    BPL *-3
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 11    LDY #17
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
F6 F6    INC $F6,X
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #88
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 3
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 16    LDX #22
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
44 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
45 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
46 bytes
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
65 bytes
18   ... CLC      × 63
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 63
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 63
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 63
04 04    NOP $04
Requires support for unofficial opcodes
66 bytes
EA   ... NOP      × 63
4C xx xx JMP *+3
Not relocatable code


130 cycles

5 bytes
A9       LDA #103
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
48   ... PHA      × 2
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
68       PLA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #96
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #96
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Writes in stack
44 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N
65 bytes
EA   ... NOP      × 65
No requirements


131 cycles

5 bytes
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #104
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
7 bytes
48       PHA
A9       LDA #97
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #97
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
8 bytes
8C       TXA
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
48       PHA
08       PHP
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A4 A4    LDY $A4
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #90
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
F6 F6    INC $F6,X
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires @zptemp, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 10    LDX #16
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
44 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
45 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 5
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
46 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
47 bytes
EA       NOP
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
66 bytes
18   ... CLC      × 64
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 64
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 64
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 64
04 04    NOP $04
Requires support for unofficial opcodes
67 bytes
EA   ... NOP      × 64
4C xx xx JMP *+3
Not relocatable code


132 cycles

5 bytes
A9       LDA #105
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
03 xx    SLO (@ptrtemp,X)
Clobbers A, X, Z&N, and C; and requires @ptrtemp, and support for unofficial opcodes
68   ... PLA      × 2
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
7 bytes
BA       TSX
68       PLA
9A       TXS
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers A, X, and Z&N; and unsafe for interrupts
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #98
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #98
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48   ... PHA      × 2
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
08       PHP
A2 1A    LDX #26 ;hides 'NOP'
CA   ... DEX      × 2
10 FB    BPL *-3
28       PLP
Clobbers X; requires support for unofficial opcodes; and writes in stack
08       PHP
A0 1A    LDY #26 ;hides 'NOP'
88   ... DEY      × 2
10 FB    BPL *-3
28       PLP
Clobbers Y; requires support for unofficial opcodes; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 18    LDY #24
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #91
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Writes in stack
44 bytes
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N
66 bytes
EA   ... NOP      × 66
No requirements


133 cycles

5 bytes
A9       LDA #106
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
38       SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #99
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #99
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
E6 xx    INC @zptemp
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
8C       TXA
A2 10    LDX #16
48       PHA
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #92
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
20 xx xx JSR @rts15
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires @rts12, and @rts15; and writes in stack
20 xx xx JSR @rts15
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires @rts12, and @rts15; and writes in stack
EA       NOP
00 00    BRK 0
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
EA       NOP
00 00    BRK 0
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Clobbers S; and writes in stack
11 bytes
08       PHP
24 24    BIT $24
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Writes in stack
45 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
46 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
47 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
48 bytes
EA   ... NOP      × 2
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
67 bytes
18   ... CLC      × 65
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 65
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 65
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 65
04 04    NOP $04
Requires support for unofficial opcodes
68 bytes
EA   ... NOP      × 65
4C xx xx JMP *+3
Not relocatable code


134 cycles

5 bytes
A9       LDA #107
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 13    LDY #19
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #100
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #100
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
8 bytes
08       PHP
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 12    LDY #18
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
Clobbers A, Z&N, C, and V; requires @rts12, and @rts14; and writes in stack
68       PLA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #93
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
68       PLA
Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 17    LDX #23
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
45 bytes
EA       NOP
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N
67 bytes
EA   ... NOP      × 67
No requirements


135 cycles

5 bytes
A9       LDA #108
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #101
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #101
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA       NOP
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
08       PHP
48       PHA
A9       LDA #94
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
08       PHP
28       PLP
30 FA    BMI *-4
68       PLA
28       PLP
Writes in stack
46 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
47 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
49 bytes
EA   ... NOP      × 3
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
26 26... ROL $26  × 9
Clobbers Z&N
68 bytes
18   ... CLC      × 66
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 66
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 66
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 66
04 04    NOP $04
Requires support for unofficial opcodes
69 bytes
EA   ... NOP      × 66
4C xx xx JMP *+3
Not relocatable code


136 cycles

5 bytes
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #109
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #102
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #102
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
EA   ... NOP      × 2
30 FA    BMI *-4
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
38       SEC
A9 13    LDA #19
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
Clobbers A, Z&N, C, and V
08       PHP
E6 xx    INC @zptemp
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers X; requires @zptemp; and writes in stack
68   ... PLA      × 2
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
48       PHA
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A2 10    LDX #16
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 10    LDY #16
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #95
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
00 00    BRK 0
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
Clobbers Z&N, C, and V; requires dummy interrupt handler; and writes in stack
00 00    BRK 0
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
10 bytes
48       PHA
38       SEC
A9 12    LDA #18
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
EA   ... NOP      × 3
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
38       SEC
A9 12    LDA #18
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
48       PHA
8C       TXA
A2 1A    LDX #26 ;hides 'NOP'
CA   ... DEX      × 2
10 FB    BPL *-3
AA       TAX
68       PLA
Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
EA       NOP
10 FB    BPL *-3
68       PLA
28       PLP
Writes in stack
46 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
68 bytes
EA   ... NOP      × 68
No requirements


137 cycles

5 bytes
A9       LDA #110
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
00 00    BRK 0
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
Clobbers X, and Z&N; requires dummy interrupt handler; and writes in stack
A2 11    LDX #17
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 11    LDY #17
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A2 11    LDX #17
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
Clobbers X, Z&N, and C
A0 11    LDY #17
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
Clobbers Y, Z&N, and C
A2 11    LDX #17
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
Clobbers X, Z&N, and V
A0 11    LDY #17
24 24    BIT $24
88       DEY
D0 FB    BNE *-3
Clobbers Y, Z&N, and V
A2 11    LDX #17
A5 A5    LDA $A5
CA       DEX
D0 FB    BNE *-3
Clobbers A, X, and Z&N
A0 11    LDY #17
A5 A5    LDA $A5
88       DEY
D0 FB    BNE *-3
Clobbers A, Y, and Z&N
A2 11    LDX #17
A4 A4    LDY $A4
CA       DEX
D0 FB    BNE *-3
Clobbers X, Y, and Z&N
A2 11    LDX #17
85 xx    STA @zptemp
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N; and requires @zptemp
A0 11    LDY #17
85 xx    STA @zptemp
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and requires @zptemp
48       PHA
A9       LDA #103
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #103
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A2 11    LDX #17
04 04    NOP $04
CA       DEX
D0 FB    BNE *-3
Clobbers X, and Z&N; and requires support for unofficial opcodes
A0 11    LDY #17
04 04    NOP $04
88       DEY
D0 FB    BNE *-3
Clobbers Y, and Z&N; and requires support for unofficial opcodes
8 bytes
EA       NOP
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
A6 A6    LDX $A6
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 13    LDY #19
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
48   ... PHA      × 2
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #96
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
46 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
47 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 10
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires support for unofficial opcodes
48 bytes
EA       NOP
4C xx xx JMP *+3
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and not relocatable code
69 bytes
18   ... CLC      × 67
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 67
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 67
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 67
04 04    NOP $04
Requires support for unofficial opcodes
70 bytes
EA   ... NOP      × 67
4C xx xx JMP *+3
Not relocatable code


138 cycles

5 bytes
A9       LDA #111
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
7 bytes
38       SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #104
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #104
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
8C       TXA
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
48       PHA
A9       LDA #97
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
48       PHA
08       PHP
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A, and S; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
00 00    BRK 0
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
46 bytes
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
69 bytes
EA   ... NOP      × 69
No requirements


139 cycles

5 bytes
A9       LDA #112
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #105
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #105
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
48       PHA
10 FB    BPL *-3
Clobbers A, S, Z&N, C, V, and D; and writes in stack
8 bytes
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
Clobbers A, Z&N, C, V, and D; and requires @zptemp
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
Clobbers A, Z&N, C, V, and D; and requires support for unofficial opcodes
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
03 xx    SLO (@ptrtemp,X)
28       PLP
Clobbers A, and X; requires @ptrtemp, and support for unofficial opcodes; and writes in stack
68       PLA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
BA       TSX
68       PLA
9A       TXS
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers A, and X; writes in stack; and unsafe for interrupts
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #98
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 19    LDY #25
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
47 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
48 bytes
C5 C5    CMP $C5
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
04 04    NOP $04
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
49 bytes
4C xx xx JMP *+3
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
70 bytes
18   ... CLC      × 68
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 68
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 68
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 68
04 04    NOP $04
Requires support for unofficial opcodes
71 bytes
EA   ... NOP      × 68
4C xx xx JMP *+3
Not relocatable code


140 cycles

5 bytes
A9       LDA #113
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #106
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #106
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #99
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
E6 xx    INC @zptemp
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
20 xx xx JSR @rts15
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires @rts12, and @rts15; and writes in stack
EA       NOP
00 00    BRK 0
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
48       PHA
38       SEC
A9 18    LDA #24
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Clobbers S; and writes in stack
13 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 11    LDX #17
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
47 bytes
EA       NOP
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N
70 bytes
EA   ... NOP      × 70
No requirements


141 cycles

5 bytes
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #114
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #107
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #107
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
8 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
08       PHP
28       PLP
30 F9    BMI *-5
Clobbers A, Z&N, C, and V; and writes in stack
08       PHP
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 13    LDY #19
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
04 04    NOP $04
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
00 00    BRK 0
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N; requires dummy interrupt handler; and writes in stack
8C       TXA
A2 11    LDX #17
48       PHA
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
8C       TXA
A2 11    LDX #17
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, Z&N, and C
8C       TXA
A2 11    LDX #17
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, Z&N, and V
8C       TXA
A2 11    LDX #17
85 xx    STA @zptemp
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #100
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
8C       TXA
A2 11    LDX #17
04 04    NOP $04
CA       DEX
D0 FB    BNE *-3
AA       TAX
Clobbers A, and Z&N; and requires support for unofficial opcodes
EA       NOP
68       PLA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
A5 A5    LDA $A5
8C       TXA
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
08       PHP
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
28       PLP
Clobbers A; requires @zptemp; and writes in stack
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
68       PLA
Clobbers Z&N, C, and V; requires @rts12, and @rts14; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
28       PLP
Clobbers A; requires @rts12, and @rts14; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
48   ... PHA      × 2
08       PHP
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A, and S; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA   ... NOP      × 2
08       PHP
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
00 00    BRK 0
B0 FA    BCS *-4
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 18    LDX #24
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
48 bytes
C5 C5    CMP $C5
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
24 24    BIT $24
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
E6 xx    INC @zptemp
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
EA       NOP
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $200-$2FF
EA       NOP
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $300-$3FF
EA       NOP
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $400-$4FF
EA       NOP
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $500-$5FF
EA       NOP
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $600-$6FF
EA       NOP
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N; and requires writable $700-$7FF
04 04    NOP $04
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
49 bytes
4C xx xx JMP *+3
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and not relocatable code
71 bytes
18   ... CLC      × 69
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 69
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 69
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 69
04 04    NOP $04
Requires support for unofficial opcodes
72 bytes
EA   ... NOP      × 69
4C xx xx JMP *+3
Not relocatable code


142 cycles

5 bytes
A9       LDA #115
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
Clobbers X, and Z&N
A0 18    LDY #24 ;hides 'CLC'
EA       NOP
88   ... DEY      × 2
10 FA    BPL *-4
Clobbers Y, and Z&N
48       PHA
A9       LDA #108
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #108
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
8 bytes
EA       NOP
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
9 bytes
48       PHA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 1A    LDY #26
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #101
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
48 bytes
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 11
76 36    ROR $36,X /
Clobbers Z&N
71 bytes
EA   ... NOP      × 71
No requirements


143 cycles

5 bytes
A9       LDA #116
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
EA       NOP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
7 bytes
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #109
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #109
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
F6 F6    INC $F6,X
28       PLP
D0 F9    BNE *-5
Clobbers A, Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #102
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
38       SEC
A9 13    LDA #19
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 13    LDA #19
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
28       PLP
Clobbers A; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
00 00    BRK 0
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
B0 FC    BCS *-2
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 12    LDA #18
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
48 bytes
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
49 bytes
EA       NOP
C5 C5    CMP $C5
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and C
EA       NOP
24 24    BIT $24
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N, and V
FE 00 02 INC $0200,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
26 26    ROL $26
66 26    ROR $26
36 36    ROL $36,X \ × 6
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
EA       NOP
04 04    NOP $04
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires support for unofficial opcodes
50 bytes
EA       NOP
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
4C xx xx JMP *+3
Clobbers Z&N; and not relocatable code
72 bytes
18   ... CLC      × 70
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 70
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 70
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 70
04 04    NOP $04
Requires support for unofficial opcodes
73 bytes
EA   ... NOP      × 70
4C xx xx JMP *+3
Not relocatable code


144 cycles

5 bytes
A9       LDA #117
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #110
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #110
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
F6 F6    INC $F6,X
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires @zptemp, support for unofficial opcodes, and writable $00-$FF
00 00    BRK 0
08       PHP
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
28       PLP
Clobbers X; requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 11    LDX #17
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 11    LDY #17
C5 C5    CMP $C5
88       DEY
D0 FB    BNE *-3
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #103
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
48 bytes
36 36    ROL $36,X \ × 12
76 36    ROR $36,X /
Clobbers Z&N
72 bytes
EA   ... NOP      × 72
No requirements


145 cycles

5 bytes
A9       LDA #118
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 12    LDX #18
48       PHA
CA       DEX
D0 FC    BNE *-2
Clobbers X, S, and Z&N; and writes in stack
A0 12    LDY #18
48       PHA
88       DEY
D0 FC    BNE *-2
Clobbers Y, S, and Z&N; and writes in stack
A2 10    LDX #16
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 10    LDY #16
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #111
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #111
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
9 bytes
48       PHA
38       SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #104
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
11 bytes
48       PHA
08       PHP
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Clobbers S; and writes in stack
12 bytes
08       PHP
48       PHA
8C       TXA
A2 12    LDX #18
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
28       PLP
Writes in stack
49 bytes
EA       NOP
E6 xx    INC @zptemp
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires @zptemp
FE 00 02 INC $0200,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $200-$2FF
FE 00 03 INC $0300,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $300-$3FF
FE 00 04 INC $0400,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $400-$4FF
FE 00 05 INC $0500,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $500-$5FF
FE 00 06 INC $0600,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $600-$6FF
FE 00 07 INC $0700,X
36 36    ROL $36,X \ × 7
76 36    ROR $36,X /
36 36... ROL $36,X× 9
Clobbers Z&N; and requires writable $700-$7FF
73 bytes
18   ... CLC      × 71
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 71
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 71
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 71
04 04    NOP $04
Requires support for unofficial opcodes
74 bytes
EA   ... NOP      × 71
4C xx xx JMP *+3
Not relocatable code


146 cycles

5 bytes
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #119
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
48       PHA
A9       LDA #112
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #112
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
04 04    NOP $04
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires support for unofficial opcodes
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, S, Z&N, C, and V; and writes in stack
48       PHA
08       PHP
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
AA       TAX
Clobbers A, and Z&N
08       PHP
A6 A6    LDX $A6
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #105
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
68       PLA
Clobbers Z&N, C, V, and D; requires @zptemp; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
28       PLP
Clobbers A; requires @zptemp; and writes in stack
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
68       PLA
Clobbers Z&N, C, V, and D; requires support for unofficial opcodes; and writes in stack
08       PHP
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
38       SEC
A9 11    LDA #17
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5
28       PLP
Clobbers A; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
49 bytes
EA       NOP
36 36    ROL $36,X \ × 12
76 36    ROR $36,X /
Clobbers Z&N
73 bytes
EA   ... NOP      × 73
No requirements


147 cycles

5 bytes
A9       LDA #120
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #113
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #113
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
A2 10    LDX #16
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
EA       NOP
A0 10    LDY #16
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
68       PLA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and requires support for unofficial opcodes
68       PLA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, S, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
EA       NOP
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 1B    LDY #27
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #106
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 1A    LDA #26
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
74 bytes
18   ... CLC      × 72
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 72
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 72
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 72
04 04    NOP $04
Requires support for unofficial opcodes
75 bytes
EA   ... NOP      × 72
4C xx xx JMP *+3
Not relocatable code


148 cycles

5 bytes
A9       LDA #121
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
A2 15    LDX #21
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 15    LDY #21
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A       TXS ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V
7 bytes
38       SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #114
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #114
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
E6 xx    INC @zptemp
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #107
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
10 bytes
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
08       PHP
28       PLP
30 F9    BMI *-5
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
08       PHP
28       PLP
30 F9    BMI *-5
28       PLP
Clobbers A; and writes in stack
00 00    BRK 0
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; requires dummy interrupt handler; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 11    LDX #17
C5 C5    CMP $C5
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N, and C; and writes in stack
48       PHA
8C       TXA
A2 11    LDX #17
24 24    BIT $24
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N, and V; and writes in stack
48       PHA
8C       TXA
A2 11    LDX #17
85 xx    STA @zptemp
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
48       PHA
8C       TXA
A2 11    LDX #17
04 04    NOP $04
CA       DEX
D0 FB    BNE *-3
AA       TAX
68       PLA
Clobbers Z&N; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
12 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 13    LDX #19
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
28       PLP
Requires @zptemp; and writes in stack
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$2A'
2A       ROL A ;first loop only
20 xx xx JSR @rts14
B0 F9    BCS *-5
68       PLA
28       PLP
Requires @rts12, and @rts14; and writes in stack
48   ... PHA      × 2
08       PHP
48       PHA
8C       TXA
A2 E8    LDX #232 ;hides 'INX'
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Clobbers S; and writes in stack
13 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
8C       TXA
A2 19    LDX #25
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
74 bytes
EA   ... NOP      × 74
No requirements


149 cycles

5 bytes
A9       LDA #122
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
48       PHA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A6 A6    LDX $A6
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #115
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #115
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
F6 F6    INC $F6,X
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V; and requires @zptemp, support for unofficial opcodes, and writable $00-$FF
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
68       PLA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 18    LDY #24 ;hides 'CLC'
EA       NOP
88   ... DEY      × 2
10 FA    BPL *-4
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #108
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
75 bytes
18   ... CLC      × 73
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 73
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 73
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 73
04 04    NOP $04
Requires support for unofficial opcodes
76 bytes
EA   ... NOP      × 73
4C xx xx JMP *+3
Not relocatable code


150 cycles

5 bytes
A9       LDA #123
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
68       PLA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
68       PLA
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
7 bytes
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 2
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 2
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #116
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #116
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
EA       NOP
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA       NOP
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
08       PHP
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
9 bytes
48       PHA
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #109
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP
F6 F6    INC $F6,X
28       PLP
D0 F9    BNE *-5
68       PLA
Clobbers Z&N, and C; requires @zptemp, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 13    LDA #19
EA       NOP
E9 01    SBC #1
D0 FA    BNE *-4
68       PLA
28       PLP
Writes in stack
60 bytes
26 26    ROL $26   \ × 15
66 26    ROR $26   /
Clobbers Z&N
75 bytes
EA   ... NOP      × 75
No requirements


151 cycles

5 bytes
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1E    LDY #30
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9       LDA #124
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
48       PHA
A9       LDA #117
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #117
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
48       PHA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A       TXS ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP       \ × 2
28       PLP       /
D0 F9    BNE *-5
Clobbers A, Z&N, and C; and writes in stack
A5 A5    LDA $A5
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A       TXS ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V
48       PHA
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
A5 A5    LDA $A5
38       SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A6 A6    LDX $A6
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #110
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
F6 F6    INC $F6,X
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
48   ... PHA      × 3
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA   ... NOP      × 2
08       PHP
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 1A    LDX #26
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
76 bytes
18   ... CLC      × 74
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 74
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 74
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 74
04 04    NOP $04
Requires support for unofficial opcodes
77 bytes
EA   ... NOP      × 74
4C xx xx JMP *+3
Not relocatable code


152 cycles

5 bytes
A9       LDA #125
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
Clobbers X, and Z&N; and requires @zptemp
F6 F6    INC $F6,X
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N; and requires @zptemp, and writable $00-$FF
48       PHA
A9       LDA #118
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #118
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
68       PLA
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$9A'
9A       TXS ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V
48   ... PHA      × 2
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48   ... PHA      × 2
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
EA       NOP
68       PLA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers A, X, S, and Z&N
EA       NOP
68       PLA
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers A, Y, S, and Z&N
8 bytes
8C       TXA
A2 15    LDX #21
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
EA   ... NOP      × 3
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA   ... NOP      × 3
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
9 bytes
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #111
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 1B    LDA #27
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
76 bytes
EA   ... NOP      × 76
No requirements


153 cycles

5 bytes
A2 EA    LDX #234 ;hides 'NOP'
E8       INX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 EA    LDY #234 ;hides 'NOP'
C8       INY
D0 FC    BNE *-2
Clobbers Y, and Z&N
A9       LDA #126
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
6 bytes
18       CLC
A9 E9    LDA #$E9 ;hides 'SBC #$08'
08       PHP ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
7 bytes
38       SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #119
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #119
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts14; and writes in stack
48       PHA
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
48       PHA
A9       LDA #112
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48       PHA
08       PHP
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; requires dummy interrupt handler; and writes in stack
10 bytes
04 04    NOP $04
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
04 04    NOP $04
08       PHP
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires support for unofficial opcodes; and writes in stack
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires dummy interrupt handler; and writes in stack
08       PHP
A5 A5    LDA $A5
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28       PLP
Clobbers A; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, C, and V; and writes in stack
48       PHA
08       PHP
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
AA       TAX
28       PLP
Clobbers A; and writes in stack
12 bytes
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
85 xx    STA @zptemp
10 FA    BPL *-4
68       PLA
28       PLP
Requires @zptemp; and writes in stack
08       PHP
48       PHA
38       SEC
A9 69    LDA #$69 ;hides 'ADC #$F8'
F8       SED ;first loop only
04 04    NOP $04
10 FA    BPL *-4
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
13 bytes
08       PHP
48       PHA
38       SEC
A9 11    LDA #17
24 24    BIT $24
E9 01    SBC #1
D0 F9    BNE *-5
68       PLA
28       PLP
Writes in stack
77 bytes
18   ... CLC      × 75
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 75
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 75
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 75
04 04    NOP $04
Requires support for unofficial opcodes
78 bytes
EA   ... NOP      × 75
4C xx xx JMP *+3
Not relocatable code


154 cycles

6 bytes
EA       NOP
A9       LDA #125
20 xx xx JSR delay_a_25_clocks
Clobbers A, Z&N, C, and V; and requires delay_a_25_clocks
48       PHA
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 1E    LDY #30
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
A2 11    LDX #17
68       PLA
CA       DEX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
A0 11    LDY #17
68       PLA
88       DEY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
7 bytes
A6 A6    LDX $A6
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 1E    LDY #30
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
48       PHA
A9       LDA #120
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #120
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
A9 0A    LDA #$0A ;hides 'ASL A'
00 00... BRK 0    × 2
10 F9    BPL *-5
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
68       PLA
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
9 bytes
EA   ... NOP      × 2
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #113
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
EA       NOP
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA       NOP
08       PHP
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 1C    LDY #28
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
77 bytes
EA   ... NOP      × 77
No requirements


155 cycles

6 bytes
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
D0 FB    BNE *-3
Clobbers A, Z&N, C, and V
A2 16    LDX #22
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
A0 16    LDY #22
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
7 bytes
8C       TXA
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9       LDA #121
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #121
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
08       PHP
A2 15    LDX #21
EA       NOP
CA       DEX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 15    LDY #21
EA       NOP
88       DEY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
9 bytes
48       PHA
38       SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 1D    LDA #29
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
08       PHP
48       PHA
A9       LDA #114
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
E6 xx    INC @zptemp
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp, and dummy interrupt handler; and writes in stack
48   ... PHA      × 2
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
48       PHA
08       PHP
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
12 bytes
08       PHP
48       PHA
A9 E9    LDA #$E9 ;hides 'SBC #$0A'
0A       ASL A ;first loop only
EA       NOP
08       PHP
28       PLP
30 F9    BMI *-5
68       PLA
28       PLP
Writes in stack
78 bytes
18   ... CLC      × 76
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 76
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 76
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 76
04 04    NOP $04
Requires support for unofficial opcodes
79 bytes
EA   ... NOP      × 76
4C xx xx JMP *+3
Not relocatable code


156 cycles

5 bytes
A9 69    LDA #$69 ;hides 'ADC #$38'
38       SEC ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
A2 1F    LDX #31
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A0 1F    LDY #31
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
48       PHA
A9       LDA #122
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #122
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
00 00    BRK 0
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
48       PHA
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48       PHA
08       PHP
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
9 bytes
08       PHP
A6 A6    LDX $A6
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A4 A4    LDY $A4
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
Clobbers A, and Z&N; and requires @zptemp
08       PHP
48       PHA
A9       LDA #115
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
EA       NOP
68       PLA
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N
10 bytes
EA   ... NOP      × 3
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
F6 F6    INC $F6,X
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers Z&N, C, and V; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A; requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
F6 F6    INC $F6,X
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, and C; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
08       PHP
F6 F6    INC $F6,X
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28       PLP
Clobbers A; requires @zptemp, dummy interrupt handler, and writable $00-$FF; and writes in stack
48   ... PHA      × 3
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
Clobbers S, Z&N, C, and V; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 2
08       PHP
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
28       PLP
Clobbers A, and S; requires support for unofficial opcodes; and writes in stack
48   ... PHA      × 3
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
Clobbers S, Z&N, and C; requires dummy interrupt handler; and writes in stack
48   ... PHA      × 2
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
28       PLP
Clobbers A, and S; requires dummy interrupt handler; and writes in stack
11 bytes
EA   ... NOP      × 2
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
EA   ... NOP      × 2
08       PHP
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
12 bytes
EA       NOP
08       PHP
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
52 bytes
36 36    ROL $36,X \ × 13
76 36    ROR $36,X /
Clobbers Z&N
78 bytes
EA   ... NOP      × 78
No requirements


157 cycles

6 bytes
68       PLA
A2 EA    LDX #234 ;hides 'NOP'
E8       INX
D0 FC    BNE *-2
Clobbers A, X, S, and Z&N
68       PLA
A0 EA    LDY #234 ;hides 'NOP'
C8       INY
D0 FC    BNE *-2
Clobbers A, Y, S, and Z&N
68       PLA
A9       LDA #126
20 xx xx JSR delay_a_25_clocks
Clobbers A, S, Z&N, C, and V; and requires delay_a_25_clocks
7 bytes
8C       TXA
A2 EA    LDX #234 ;hides 'NOP'
E8       INX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
EA       NOP
A2 16    LDX #22
EA       NOP
CA       DEX
D0 FC    BNE *-2
Clobbers X, and Z&N
EA       NOP
A0 16    LDY #22
EA       NOP
88       DEY
D0 FC    BNE *-2
Clobbers Y, and Z&N
48       PHA
A9       LDA #123
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #123
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
9 bytes
48       PHA
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 2
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 2
08       PHP
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
08       PHP
48       PHA
A9       LDA #116
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
08       PHP
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
08       PHP
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
11 bytes
08       PHP
48       PHA
38       SEC
A9 1C    LDA #28
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
28       PLP
Writes in stack
79 bytes
18   ... CLC      × 77
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 77
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 77
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 77
04 04    NOP $04
Requires support for unofficial opcodes
80 bytes
EA   ... NOP      × 77
4C xx xx JMP *+3
Not relocatable code


158 cycles

6 bytes
18       CLC
A9 69    LDA #$69 ;hides 'ADC #$38'
38       SEC ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
EA       NOP
A2 1F    LDX #31
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
EA       NOP
A0 1F    LDY #31
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
7 bytes
08       PHP
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 1E    LDY #30
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #124
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #124
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
8 bytes
48       PHA
8C       TXA
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, S, and Z&N; and writes in stack
9 bytes
A5 A5    LDA $A5
8C       TXA
A2 1E    LDX #30
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
28       PLP
Clobbers A; requires @rts12, and @rts14; and writes in stack
08       PHP
48       PHA
A9       LDA #117
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP       \ × 2
28       PLP       /
D0 F9    BNE *-5
68       PLA
Clobbers Z&N, and C; and writes in stack
08       PHP
A9 0A    LDA #$0A ;hides 'ASL A'
08       PHP       \ × 2
28       PLP       /
D0 F9    BNE *-5
28       PLP
Clobbers A; and writes in stack
11 bytes
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
AA       TAX
68       PLA
Clobbers Z&N; requires @zptemp; and writes in stack
48   ... PHA      × 3
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers S, and Z&N; and writes in stack
12 bytes
EA   ... NOP      × 3
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
F6 F6    INC $F6,X
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires @zptemp, support for unofficial opcodes, and writable $00-$FF; and writes in stack
48   ... PHA      × 2
08       PHP
48       PHA
38       SEC
A9 E9    LDA #$E9 ;hides 'SBC #$3A'
3A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Clobbers S; requires support for unofficial opcodes; and writes in stack
13 bytes
EA   ... NOP      × 2
08       PHP
48       PHA
8C       TXA
A2 1B    LDX #27
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
79 bytes
EA   ... NOP      × 79
No requirements


159 cycles

6 bytes
48       PHA
A9 69    LDA #$69 ;hides 'ADC #$38'
38       SEC ;first loop only
D0 FC    BNE *-2
Clobbers A, S, Z&N, C, and V; and writes in stack
48       PHA
A2 1F    LDX #31
CA       DEX
D0 FD    BNE *-1
Clobbers X, S, and Z&N; and writes in stack
48       PHA
A0 1F    LDY #31
88       DEY
D0 FD    BNE *-1
Clobbers Y, S, and Z&N; and writes in stack
7 bytes
A5 A5    LDA $A5
A9 69    LDA #$69 ;hides 'ADC #$38'
38       SEC ;first loop only
D0 FC    BNE *-2
Clobbers A, Z&N, C, and V
A6 A6    LDX $A6
A2 1F    LDX #31
CA       DEX
D0 FD    BNE *-1
Clobbers X, and Z&N
A4 A4    LDY $A4
A0 1F    LDY #31
88       DEY
D0 FD    BNE *-1
Clobbers Y, and Z&N
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts15
D0 FA    BNE *-4
Clobbers A, Z&N, and C; requires @rts12, and @rts15; and writes in stack
48       PHA
A9       LDA #125
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #125
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
18       CLC
D0 FA    BNE *-4
Clobbers A, Z&N, and C; requires dummy interrupt handler; and writes in stack
8 bytes
8C       TXA
A2 16    LDX #22
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
Clobbers A, and Z&N
9 bytes
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
F6 xx    INC @zptemp,X
28       PLP
Clobbers X; requires @zptemp; and writes in stack
08       PHP
F6 F6    INC $F6,X
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; requires @zptemp, and writable $00-$FF; and writes in stack
08       PHP
48       PHA
A9       LDA #118
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
48   ... PHA      × 2
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X, and S; and writes in stack
48   ... PHA      × 2
08       PHP
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y, and S; and writes in stack
10 bytes
48       PHA
8C       TXA
A2 15    LDX #21
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
08       PHP
8C       TXA
A2 15    LDX #21
EA       NOP
CA       DEX
D0 FC    BNE *-2
AA       TAX
28       PLP
Clobbers A; and writes in stack
EA   ... NOP      × 3
08       PHP
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
28       PLP
Clobbers X; and writes in stack
EA   ... NOP      × 3
08       PHP
A0 1D    LDY #29
88       DEY
D0 FD    BNE *-1
28       PLP
Clobbers Y; and writes in stack
11 bytes
08       PHP
48       PHA
8C       TXA
A2 1C    LDX #28
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
28       PLP
Writes in stack
80 bytes
18   ... CLC      × 78
90 00    BCC *+2
Clobbers C
B8   ... CLV      × 78
50 00    BVC *+2
Clobbers V
EA   ... NOP      × 78
85 xx    STA @zptemp
Requires @zptemp
EA   ... NOP      × 78
04 04    NOP $04
Requires support for unofficial opcodes
81 bytes
EA   ... NOP      × 78
4C xx xx JMP *+3
Not relocatable code


160 cycles

7 bytes
8C       TXA
A2 1F    LDX #31
CA       DEX
D0 FD    BNE *-1
AA       TAX
Clobbers A, and Z&N
08       PHP
A2 EA    LDX #234 ;hides 'NOP'
E8       INX
D0 FC    BNE *-2
28       PLP
Clobbers X; and writes in stack
08       PHP
A0 EA    LDY #234 ;hides 'NOP'
C8       INY
D0 FC    BNE *-2
28       PLP
Clobbers Y; and writes in stack
48       PHA
A9       LDA #126
20 xx xx JSR delay_a_25_clocks
68       PLA
Clobbers Z&N, C, and V; requires delay_a_25_clocks; and writes in stack
08       PHP
A9       LDA #126
20 xx xx JSR delay_a_25_clocks
28       PLP
Clobbers A; requires delay_a_25_clocks; and writes in stack
9 bytes
48       PHA
38       SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3
68       PLA
Clobbers Z&N, C, and V; and writes in stack
08       PHP
38       SEC
A9 1E    LDA #30
E9 01    SBC #1
D0 FB    BNE *-3
28       PLP
Clobbers A; and writes in stack
A2 15    LDX #21
EA       NOP
CA       DEX
10 FC    BPL *-2
9D 03 1F STA $1F03,X ; Reads $702, writes $2002
Clobbers X, and Z&N
A0 15    LDY #21
EA       NOP
88       DEY
10 FC    BPL *-2
99 03 1F STA $1F03,Y ; Reads $702, writes $2002
Clobbers Y, and Z&N
08       PHP
48       PHA
A9       LDA #119
20 xx xx JSR delay_a_25_clocks
68       PLA
28       PLP
Requires delay_a_25_clocks; and writes in stack
10 bytes
48       PHA
18       CLC
A9 0A    LDA #$0A ;hides 'ASL A'
20 xx xx JSR @rts14
D0 FA    BNE *-4
68       PLA
Clobbers Z&N, and C; requires @rts12, and @rts14; and writes in stack
11 bytes
48       PHA
A5 A5    LDA $A5
8C       TXA
A2 1D    LDX #29
CA       DEX
D0 FD    BNE *-1
AA       TAX
68       PLA
Clobbers Z&N; and writes in stack
12 bytes
08       PHP
04 04    NOP $04
48       PHA
18       CLC
A9 EB    LDA #$EB ;hides 'SBC #$7A'
7A       NOP ;first loop only
D0 FC    BNE *-2
68       PLA
28       PLP
Requires support for unofficial opcodes; and writes in stack
08       PHP
C5 C5    CMP $C5
48       PHA
A9 0A    LDA #$0A ;hides 'ASL A'
00 00    BRK 0
D0 FB    BNE *-3
68       PLA
28       PLP
Requires dummy interrupt handler; and writes in stack
13 bytes
08       PHP
48       PHA
8C       TXA
A2 18    LDX #24 ;hides 'CLC'
EA       NOP
CA   ... DEX      × 2
10 FA    BPL *-4
AA       TAX
68       PLA
28       PLP
Writes in stack
64 bytes
26 26    ROL $26   \ × 16
66 26    ROR $26   /
Clobbers Z&N
80 bytes
EA   ... NOP      × 80
No requirements


See also