Difference between revisions of "S1C88 InstructionSet"

From SublabWiki
Jump to: navigation, search
(Branch)
 
(137 intermediate revisions by 4 users not shown)
Line 1: Line 1:
= Move =
+
= 8-bit arithmetic and logic operation =
 +
== '''ADD''': Addition ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="12" | [[S1C88_ADD|ADD]]
 +
| A,A
 +
|  0
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,B
 +
|  1
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,#nn
 +
|  2,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[HL]
 +
|  3
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[BR:ll]
 +
|  4,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[hhll]
 +
|  5,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX]
 +
|  6
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY]
 +
|  7
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX+dd]
 +
| CE, 0,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY+dd]
 +
| CE, 1,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX+L]
 +
| CE, 2
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY+L]
 +
| CE, 3
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| rowspan="4" | [[S1C88_ADD|ADD]]
 +
| [HL],A
 +
| CE, 4
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],#nn
 +
| CE, 5,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],[IX]
 +
| CE, 6
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],[IY]
 +
| CE, 7
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|}
  
== NOP = No Operation ==
+
== '''ADC''': Addition with carry ==
 
+
{| class="wikitable sortable"
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" colspan="2" | Mnemonic
!Hex
+
! rowspan="2" | Machine Code
!Mnemonic
+
! rowspan="2" | Operation
!Cycles
+
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="12" | [[S1C88_ADC|ADC]]
 +
| A,A
 +
|  8
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,B
 +
|  9
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,#nn
 +
|  A,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[HL]
 +
|  B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[BR:ll]
 +
|  C,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[hhll]
 +
|  D,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX]
 +
|  E
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY]
 +
|  F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX+dd]
 +
| CE, 8,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY+dd]
 +
| CE, 9,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IX+L]
 +
| CE, A
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| A,[IY+L]
 +
| CE, B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| rowspan="4" | [[S1C88_ADC|ADC]]
 +
| [HL],A
 +
| CE, C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],#nn
 +
| CE, D,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],[IX]
 +
| CE, E
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| [HL],[IY]
 +
| CE, F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|FF
 
|[[PM_Opc_NOP|NOP]]
 
|8
 
 
|}
 
|}
  
'''Flags Affected:''' None
+
== '''SUB''': Subtraction ==
 
+
{| class="wikitable sortable"
== MOV = Move Register ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
[[PM_Opc_MOV8|8 Bit Opcode overview]]
+
! rowspan="2" | Operation
 
+
! rowspan="2" | Cycles
[[PM_Opc_MOV16|16 Bit Opcode overview]]
+
! rowspan="2" | Bytes
 
+
! colspan="8" | SC
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|40
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV A, A]]
 
|4
 
 
|-
 
|-
|41
+
| rowspan="12" | [[S1C88_SUB|SUB]]
|[[PM_Opc_MOV8|MOV A, B]]
+
| A,A
|4
+
| 10
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|42
+
| A,B
|[[PM_Opc_MOV8|MOV A, L]]
+
| 11
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|43
+
| A,#nn
|[[PM_Opc_MOV8|MOV A, H]]
+
| 12,nn
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|44 nn
+
| A,[HL]
|[[PM_Opc_MOV8|MOV A, [N+#nn]]]
+
| 13
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|45
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV A, [HL]]]
+
| 14,ll
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|46
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV A, [X]]]
+
| 15,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|47
+
| A,[IX]
|[[PM_Opc_MOV8|MOV A, [Y]]]
+
| 16
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|48
+
| A,[IY]
|[[PM_Opc_MOV8|MOV B, A]]
+
| 17
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|49
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV B, B]]
+
| CE,10,dd
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4A
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV B, L]]
+
| CE,11,dd
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4B
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV B, H]]
+
| CE,12
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4C nn
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV B, [N+#nn]]]
+
| CE,13
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4D
+
| rowspan="4" | [[S1C88_SUB|SUB]]
|[[PM_Opc_MOV8|MOV B, [HL]]]
+
| [HL],A
|8
+
| CE,14
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4E
+
| [HL],#nn
|[[PM_Opc_MOV8|MOV B, [X]]]
+
| CE,15,nn
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|4F
+
| [HL],[IX]
|[[PM_Opc_MOV8|MOV B, [Y]]]
+
| CE,16
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|50
+
| [HL],[IY]
|[[PM_Opc_MOV8|MOV L, A]]
+
| CE,17
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 +
|}
 +
 
 +
== '''SBC''': Subtraction with carry ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|51
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV L, B]]
 
|4
 
 
|-
 
|-
|52
+
| rowspan="12" | [[S1C88_SBC|SBC]]
|[[PM_Opc_MOV8|MOV L, L]]
+
| A,A
|4
+
| 18
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|53
+
| A,B
|[[PM_Opc_MOV8|MOV L, H]]
+
| 19
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|54 nn
+
| A,#nn
|[[PM_Opc_MOV8|MOV L, [N+#nn]]]
+
| 1A,nn
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|55
+
| A,[HL]
|[[PM_Opc_MOV8|MOV L, [HL]]]
+
| 1B
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|56
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV L, [X]]]
+
| 1C,ll
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|57
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV L, [Y]]]
+
| 1D,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|58
+
| A,[IX]
|[[PM_Opc_MOV8|MOV H, A]]
+
| 1E
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|59
+
| A,[IY]
|[[PM_Opc_MOV8|MOV H, B]]
+
| 1F
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5A
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV H, L]]
+
| CE,18,dd
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5B
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV H, H]]
+
| CE,19,dd
|4
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5C nn
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV H, [N+#nn]]]
+
| CE,1A
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5D
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV H, [HL]]]
+
| CE,1B
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5E
+
| rowspan="4" | [[S1C88_SBC|SBC]]
|[[PM_Opc_MOV8|MOV H, [X]]]
+
| [HL],A
|8
+
| CE,1C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|5F
+
| [HL],#nn
|[[PM_Opc_MOV8|MOV H, [Y]]]
+
| CE,1D,nn
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|60
+
| [HL],[IX]
|[[PM_Opc_MOV8|MOV [X], A]]
+
| CE,1E
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|61
+
| [HL],[IY]
|[[PM_Opc_MOV8|MOV [X], B]]
+
| CE,1F
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|62
+
|}
|[[PM_Opc_MOV8|MOV [X], L]]
+
 
|8
+
 
 +
 
 +
== '''AND''': Logical product ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|63
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV [X], H]]
 
|8
 
 
|-
 
|-
|64 nn
+
| rowspan="12" | [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [X], [N+#nn]]]
+
| A,A
|16
+
| 20
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|65
+
| A,B
|[[PM_Opc_MOV8|MOV [X], [HL]]]
+
| 21
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|66
+
| A,#nn
|[[PM_Opc_MOV8|MOV [X], [X]]]
+
| 22,nn
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|67
+
| A,[HL]
|[[PM_Opc_MOV8|MOV [X], [Y]]]
+
| 23
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|68
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV [HL], A]]
+
| 24,ll
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|69
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV [HL], B]]
+
| 25,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6A
+
| A,[IX]
|[[PM_Opc_MOV8|MOV [HL], L]]
+
| 26
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6B
+
| A,[IY]
|[[PM_Opc_MOV8|MOV [HL], H]]
+
| 27
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6C nn
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV [HL], [N+#nn]]]
+
| CE,20,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6D
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV [HL], [HL]]]
+
| CE,21,dd
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6E
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV [HL], [X]]]
+
| CE,22
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|6F
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV [HL], [Y]]]
+
| CE,23
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|70
+
| [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [Y], A]]
+
| B,#nn
|8
+
| CE,B0,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|71
+
| [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [Y], B]]
+
| H,#nn
|8
+
| CE,B2,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|72
+
| [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [Y], L]]
+
| [BR:ll],#nn
|8
+
| D8,ll,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|73
+
| rowspan="4" | [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [Y], H]]
+
| [HL],A
|8
+
| CE,24
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|74 nn
+
| [HL],#nn
|[[PM_Opc_MOV8|MOV [Y], [N+#nn]]]
+
| CE,25,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|75
+
| [HL],[IX]
|[[PM_Opc_MOV8|MOV [Y], [HL]]]
+
| CE,26
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|76
+
| [HL],[IY]
|[[PM_Opc_MOV8|MOV [Y], [X]]]
+
| CE,27
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|77
+
| [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [Y], [Y]]]
+
| L,#nn
|12
+
| CE,B1,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↓ || – || – || ↓
 
|-
 
|-
|78 nn
+
| [[S1C88_AND|AND]]
|[[PM_Opc_MOV8|MOV [N+#nn], A]]
+
| SC,#nn
|12
+
| 9C,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| ↓ || ↓ || ↓ || ↓ || ↓ || ↓ || ↓ || ↓
 
|-
 
|-
|79 nn
+
|}
|[[PM_Opc_MOV8|MOV [N+#nn], B]]
+
 
|12
+
== '''OR''': Logical sum ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|7A nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV [N+#nn], L]]
 
|12
 
 
|-
 
|-
|7B nn
+
| rowspan="12" | [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV [N+#nn], H]]
+
| A,A
|12
+
| 28
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|7D nn
+
| A,B
|[[PM_Opc_MOV8|MOV [N+#nn], [HL]]]
+
| 29
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|7E nn
+
| A,#nn
|[[PM_Opc_MOV8|MOV [N+#nn], [X]]]
+
| 2A,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|7F nn
+
| A,[HL]
|[[PM_Opc_MOV8|MOV [N+#nn], [Y]]]
+
| 2B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|9F nn
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV F, #nn]]
+
| 2C,ll
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B0 nn
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV A, #nn]]
+
| 2D,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B1 nn
+
| A,[IX]
|[[PM_Opc_MOV8|MOV B, #nn]]
+
| 2E
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B2 nn
+
| A,[IY]
|[[PM_Opc_MOV8|MOV L, #nn]]
+
| 2F
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B3 nn
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV H, #nn]]
+
| CE,28,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B4 nn
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV N, #nn]]
+
| CE,29,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B5 nn
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV [HL], #nn]]
+
| CE,2A
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B6 nn
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV [X], #nn]]
+
| CE,2B
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|B7 nn
+
| [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV [Y], #nn]]
+
| B,#nn
|12
+
| CE,B4,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|DD nn nn
+
| [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV [N+#nn], #nn]]
+
| H,#nn
|16
+
| CE,B6,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE C4 nn
+
| [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV U, #nn]]
+
| [BR:ll],#nn
|16
+
| D9,ll,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE C5 nn
+
| rowspan="4" | [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV I, #nn]]
+
| [HL],A
|12
+
| CE,2C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE C6 nn
+
| [HL],#nn
|[[PM_Opc_MOV8|MOV XI, #nn]]
+
| CE,2D,nn
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE C7 nn
+
| [HL],[IX]
|[[PM_Opc_MOV8|MOV YI, #nn]]
+
| CE,2E
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE 40 ss
+
| [HL],[IY]
|[[PM_Opc_MOV8|MOV A, [X+#ss]]]
+
| CE,2F
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE 41 ss
+
| [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV A, [Y+#ss]]]
+
| L,#nn
|16
+
| CE,B5,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↑ || – || – || ↑
 
|-
 
|-
|CE 42
+
| [[S1C88_OR|OR]]
|[[PM_Opc_MOV8|MOV A, [X+L]]]
+
| SC,#nn
|16
+
| 9D,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| ↑ || ↑ || ↑ || ↑ || ↑ || ↑ || ↑ || ↑
 
|-
 
|-
|CE 43
+
|}
|[[PM_Opc_MOV8|MOV A, [Y+L]]]
+
 
|16
+
== '''XOR''': Exclusive OR ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CE 48 ss
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV B, [X+#ss]]]
 
|16
 
 
|-
 
|-
|CE 49 ss
+
| rowspan="12" | [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV B, [Y+#ss]]]
+
| A,A
|16
+
| 38
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4A
+
| A,B
|[[PM_Opc_MOV8|MOV B, [X+L]]]
+
| 39
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4B
+
| A,#nn
|[[PM_Opc_MOV8|MOV B, [Y+L]]]
+
| 3A,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 50 ss
+
| A,[HL]
|[[PM_Opc_MOV8|MOV L, [X+#ss]]]
+
| 3B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 51 ss
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV L, [Y+#ss]]]
+
| 3C,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 52
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV L, [X+L]]]
+
| 3D,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 53
+
| A,[IX]
|[[PM_Opc_MOV8|MOV L, [Y+L]]]
+
| 3E
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 58 ss
+
| A,[IY]
|[[PM_Opc_MOV8|MOV H, [X+#ss]]]
+
| 3F
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 59 ss
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV H, [Y+#ss]]]
+
| CE,38,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 5A
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV H, [X+L]]]
+
| CE,39,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 5B
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV H, [Y+L]]]
+
| CE,3A
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 44 ss
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV [X+#ss], A]]
+
| CE,3B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 45 ss
+
| [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [Y+#ss], A]]
+
| B,#nn
|16
+
| CE,B8,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 46
+
| [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [X+L], A]]
+
| H,#nn
|16
+
| CE,BA,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 47
+
| [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [Y+L], A]]
+
| [BR:ll],#nn
|16
+
| DA,ll,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4C ss
+
| rowspan="4" | [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [X+#ss], B]]
+
| [HL],A
|16
+
| CE,3C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4D ss
+
| [HL],#nn
|[[PM_Opc_MOV8|MOV [Y+#ss], B]]
+
| CE,3D,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4E
+
| [HL],[IX]
|[[PM_Opc_MOV8|MOV [X+L], B]]
+
| CE,3E
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 4F
+
| [HL],[IY]
|[[PM_Opc_MOV8|MOV [Y+L], B]]
+
| CE,3F
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 54 ss
+
| [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [X+#ss], L]]
+
| L,#nn
|16
+
| CE,B9,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CE 55 ss
+
| [[S1C88_XOR|XOR]]
|[[PM_Opc_MOV8|MOV [Y+#ss], L]]
+
| SC,#nn
|16
+
| 9E,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 56
+
|}
|[[PM_Opc_MOV8|MOV [X+L], L]]
+
 
|16
+
== '''CP''': Comparison ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CE 57
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV [Y+L], L]]
 
|16
 
 
|-
 
|-
|CE 5C ss
+
| rowspan="12" | [[S1C88_CP|CP]]
|[[PM_Opc_MOV8|MOV [X+#ss], H]]
+
| A,A
|16
+
| 30
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 5D ss
+
| A,B
|[[PM_Opc_MOV8|MOV [Y+#ss], H]]
+
| 31
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 5E
+
| A,#nn
|[[PM_Opc_MOV8|MOV [X+L], H]]
+
| 32,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 5F
+
| A,[HL]
|[[PM_Opc_MOV8|MOV [Y+L], H]]
+
| 33
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 60 ss
+
| A,[BR:ll]
|[[PM_Opc_MOV8|MOV [HL], [X+#ss]]]
+
| 34,ll
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 61 ss
+
| A,[hhll]
|[[PM_Opc_MOV8|MOV [HL], [Y+#ss]]]
+
| 35,ll,hh
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 62
+
| A,[IX]
|[[PM_Opc_MOV8|MOV [HL], [X+L]]]
+
| 36
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 63
+
| A,[IY]
|[[PM_Opc_MOV8|MOV [HL], [Y+L]]]
+
| 37
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 68 ss
+
| A,[IX+dd]
|[[PM_Opc_MOV8|MOV [X], [X+#ss]]]
+
| CE,30,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 69 ss
+
| A,[IY+dd]
|[[PM_Opc_MOV8|MOV [X], [Y+#ss]]]
+
| CE,31,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 6A
+
| A,[IX+L]
|[[PM_Opc_MOV8|MOV [X], [X+L]]]
+
| CE,32
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 6B
+
| A,[IY+L]
|[[PM_Opc_MOV8|MOV [X], [Y+L]]]
+
| CE,33
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 78 ss
+
| [[S1C88_CP|CP]]
|[[PM_Opc_MOV8|MOV [Y], [X+#ss]]]
+
| B,#nn
|20
+
| CE,BC,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 79 ss
+
| [[S1C88_CP|CP]]
|[[PM_Opc_MOV8|MOV [Y], [Y+#ss]]]
+
| H,#nn
|20
+
| CE,BE,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 7A
+
| [[S1C88_CP|CP]]
|[[PM_Opc_MOV8|MOV [Y], [X+L]]]
+
| BR,#hh
|20
+
| CE,BF,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 7B
+
| [[S1C88_CP|CP]]
|[[PM_Opc_MOV8|MOV [Y], [Y+L]]]
+
| [BR:ll],#nn
|20
+
| DB,ll,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|B8 nn nn
+
| rowspan="4" | [[S1C88_CP|CP]]
|[[PM_Opc_MOV16|MOV BA, [#nnnn]]]
+
| [HL],A
|20
+
| CE,34
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|B9 nn nn
+
| [HL],#nn
|[[PM_Opc_MOV16|MOV HL, [#nnnn]]]
+
| CE,35,nn
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|BA nn nn
+
| [HL],[IX]
|[[PM_Opc_MOV16|MOV X, [#nnnn]]]
+
| CE,36
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|BB nn nn
+
| [HL],[IY]
|[[PM_Opc_MOV16|MOV Y, [#nnnn]]]
+
| CE,37
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF 78 nn nn
+
| [[S1C88_CP|CP]]
|[[PM_Opc_MOV16|MOV SP, [#nnnn]]]
+
| L,#nn
|24
+
| CE,BD,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|BC nn nn
+
|}
|[[PM_Opc_MOV16|MOV [#nnnn], BA]]
+
 
|20
+
== '''BIT''': Bit test ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|BD nn nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV16|MOV [#nnnn], HL]]
 
|20
 
 
|-
 
|-
|BE nn nn
+
| rowspan="2" | [[S1C88_BIT|BIT]]
|[[PM_Opc_MOV16|MOV [#nnnn], X]]
+
| A,B
|20
+
| 94
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|BF nn nn
+
| A,#nn
|[[PM_Opc_MOV16|MOV [#nnnn], Y]]
+
| 96,nn
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CF 7C nn nn
+
| [[S1C88_BIT|BIT]]
|[[PM_Opc_MOV16|MOV [#nnnn], SP]]
+
| B,#nn
|24
+
| 97,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|C4 nn nn
+
| [[S1C88_BIT|BIT]]
|[[PM_Opc_MOV16|MOV BA, #nnnn]]
+
| [HL],#nn
|12
+
| 95,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|C5 nn nn
+
| [[S1C88_BIT|BIT]]
|[[PM_Opc_MOV16|MOV HL, #nnnn]]
+
| [BR:ll],#nn
|12
+
| DC,ll,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|C6 nn nn
+
|}
|[[PM_Opc_MOV16|MOV X, #nnnn]]
+
 
|12
+
== '''INC''': 1 increment ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|C7 nn nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV16|MOV Y, #nnnn]]
 
|12
 
 
|-
 
|-
|CF 6E nn nn
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV16|MOV SP, #nnnn]]
+
| A
|16
+
| 80
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE C0
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, N]]
+
| B
|8
+
| 81
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE C1
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, F]]
+
| H
|8
+
| 83
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE C8
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, V]]
+
| [BR:ll]
|8
+
| 85,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE C9
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, I]]
+
| [HL]
|8
+
| 86
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE CA
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, XI]]
+
| L
|8
+
| 82
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE CB
+
| [[S1C88_INC|INC]]
|[[PM_Opc_MOV8|MOV A, YI]]
+
| BR
|8
+
| 84
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE C2
+
|}
|[[PM_Opc_MOV8|MOV N, A]]
+
 
|8
+
== '''DEC''': 1 decrement ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CE C3
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV F, A]]
 
|12
 
 
|-
 
|-
|CE CC
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV U, A]]
+
| A
|12
+
| 88
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE CD
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV I, A]]
+
| B
|8
+
| 89
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE CE
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV XI, A]]
+
| H
|8
+
| 8B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE CF
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV YI, A]]
+
| [BR:ll]
|8
+
| 8D,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE D0 nn nn
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV A, [#nnnn]]]
+
| [HL]
|20
+
| 8E
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE D1 nn nn
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV B, [#nnnn]]]
+
| L
|20
+
| 8A
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE D2 nn nn
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_MOV8|MOV L, [#nnnn]]]
+
| BR
|20
+
| 8C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE D3 nn nn
+
|}
|[[PM_Opc_MOV8|MOV H, [#nnnn]]]
+
 
|20
+
== '''MLT''': Multiplication ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CE D4 nn nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV [#nnnn], A]]
 
|20
 
 
|-
 
|-
|CE D5 nn nn
+
| [[S1C88_MLT|MLT]]
|[[PM_Opc_MOV8|MOV [#nnnn], B]]
+
|
|20
+
| CE,D8
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || 0 || 0 || ↕
 
|-
 
|-
|CE D6 nn nn
+
|}
|[[PM_Opc_MOV8|MOV [#nnnn], L]]
+
 
|20
+
== '''DIV''': Division ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CE D7 nn nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV8|MOV [#nnnn], H]]
 
|20
 
 
|-
 
|-
|CF 70 ss
+
| [[S1C88_DIV|DIV]]
|[[PM_Opc_MOV16|MOV BA, [SP+#ss]]]
+
|  
|24
+
| CE,D9
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || 0 || ↕
 
|-
 
|-
|CF 71 ss
+
|}
|[[PM_Opc_MOV16|MOV HL, [SP+#ss]]]
+
 
|24
+
== '''CPL''': Complement of 1 ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CF 72 ss
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV16|MOV X, [SP+#ss]]]
 
|24
 
 
|-
 
|-
|CF 73 ss
+
| [[S1C88_CPL|CPL]]
|[[PM_Opc_MOV16|MOV Y, [SP+#ss]]]
+
| A
|24
+
| CE,A0
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CF 74 ss
+
| [[S1C88_CPL|CPL]]
|[[PM_Opc_MOV16|MOV [SP+#ss], BA]]
+
| B
|24
+
| CE,A1
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CF 75 ss
+
| [[S1C88_CPL|CPL]]
|[[PM_Opc_MOV16|MOV [SP+#ss], HL]]
+
| [HL]
|24
+
| CE,A3
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CF 76 ss
+
| [[S1C88_CPL|CPL]]
|[[PM_Opc_MOV16|MOV [SP+#ss], X]]
+
| [BR:ll]
|24
+
| CE,A2,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || – || ↕
 
|-
 
|-
|CF 77 ss
+
|}
|[[PM_Opc_MOV16|MOV [SP+#ss], Y]]
+
 
|24
+
== '''NEG''': Complement of 2 ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CF C0
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV16|MOV BA, [HL]]]
 
|20
 
 
|-
 
|-
|CF C1
+
| [[S1C88_NEG|NEG]]
|[[PM_Opc_MOV16|MOV HL, [HL]]]
+
| A
|20
+
| CE,A4
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF C2
+
| [[S1C88_NEG|NEG]]
|[[PM_Opc_MOV16|MOV X, [HL]]]
+
| B
|20
+
| CE,A5
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF C3
+
| [[S1C88_NEG|NEG]]
|[[PM_Opc_MOV16|MOV Y, [HL]]]
+
| [HL]
|20
+
| CE,A7
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF D0
+
| [[S1C88_NEG|NEG]]
|[[PM_Opc_MOV16|MOV BA, [X]]]
+
| [BR:ll]
|20
+
| CE,A6,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || ★ || ★ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF D1
+
|}
|[[PM_Opc_MOV16|MOV HL, [X]]]
+
 
|20
+
= 8-bit transfer =
 +
== '''LD''': Load ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|CF D2
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_MOV16|MOV X, [X]]]
 
|20
 
 
|-
 
|-
|CF D3
+
| rowspan="11" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV Y, [X]]]
+
| IY,[hhll]
|20
+
| BB,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D8
+
| IY,#mmnn
|[[PM_Opc_MOV16|MOV BA, [Y]]]
+
| C7,nn,mm
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D9
+
| IY,[SP+dd]
|[[PM_Opc_MOV16|MOV HL, [Y]]]
+
| CE,73,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DA
+
| IY,[HL]
|[[PM_Opc_MOV16|MOV X, [Y]]]
+
| CE,C3
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DB
+
| IY,[IX]
|[[PM_Opc_MOV16|MOV Y, [Y]]]
+
| CE,D3
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF C4
+
| IY,[IY]
|[[PM_Opc_MOV16|MOV [HL], BA]]
+
| CE,DB
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF C5
+
| IY,BA
|[[PM_Opc_MOV16|MOV [HL], HL]]
+
| CE,EC
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF C6
+
| IY,HL
|[[PM_Opc_MOV16|MOV [HL], X]]
+
| CE,ED
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF C7
+
| IY,IX
|[[PM_Opc_MOV16|MOV [HL], Y]]
+
| CE,EE
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D4
+
| IY,IY
|[[PM_Opc_MOV16|MOV [X], BA]]
+
| CE,EF
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D5
+
| IY,SP
|[[PM_Opc_MOV16|MOV [X], HL]]
+
| CE,FE
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D6
+
| rowspan="6" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV [X], X]]
+
| SP,#mmnn
|20
+
| CE,6E,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF D7
+
| SP,[hhll]
|[[PM_Opc_MOV16|MOV [X], Y]]
+
| CE,78,ll,hh
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DC
+
| SP,BA
|[[PM_Opc_MOV16|MOV [Y], BA]]
+
| CE,F0
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DD
+
| SP,HL
|[[PM_Opc_MOV16|MOV [Y], HL]]
+
| CE,F1
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DE
+
| SP,IX
|[[PM_Opc_MOV16|MOV [Y], X]]
+
| CE,F2
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF DF
+
| SP,IY
|[[PM_Opc_MOV16|MOV [Y], Y]]
+
| CE,F3
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E0
+
| rowspan="12" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV BA, BA]]
+
| BA,[hhll]
|8
+
| B8,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E1
+
| BA,#mmnn
|[[PM_Opc_MOV16|MOV BA, HL]]
+
| C4,nn,mm
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E2
+
| BA,[SP+dd]
|[[PM_Opc_MOV16|MOV BA, X]]
+
| CE,70,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E3
+
| BA,[HL]
|[[PM_Opc_MOV16|MOV BA, Y]]
+
| CE,C0
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E4
+
| BA,[IX]
|[[PM_Opc_MOV16|MOV HL, BA]]
+
| CE,D0
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E5
+
| BA,[IY]
|[[PM_Opc_MOV16|MOV HL, HL]]
+
| CE,D8
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E6
+
| BA,BA
|[[PM_Opc_MOV16|MOV HL, X]]
+
| CE,E0
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E7
+
| BA,HL
|[[PM_Opc_MOV16|MOV HL, Y]]
+
| CE,E1
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E8
+
| BA,IX
|[[PM_Opc_MOV16|MOV X, BA]]
+
| CE,E2
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF E9
+
| BA,IY
|[[PM_Opc_MOV16|MOV X, HL]]
+
| CE,E3
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF EA
+
| BA,SP
|[[PM_Opc_MOV16|MOV X, X]]
+
| CE,F8
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF EB
+
| BA,PC
|[[PM_Opc_MOV16|MOV X, Y]]
+
| CE,F9
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF EC
+
| rowspan="2" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV Y, BA]]
+
| BR,#hh
|8
+
| B4,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF ED
+
| BR,A
|[[PM_Opc_MOV16|MOV Y, HL]]
+
| CE,C2
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF EE
+
| rowspan="4" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV Y, X]]
+
| [IX+L],A
|8
+
| CE,46
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF EF
+
| [IX+L],B
|[[PM_Opc_MOV16|MOV Y, Y]]
+
| CE,4E
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F0
+
| [IX+L],L
|[[PM_Opc_MOV16|MOV SP, BA]]
+
| CE,56
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F1
+
| [IX+L],H
|[[PM_Opc_MOV16|MOV SP, HL]]
+
| CE,5E
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F2
+
| rowspan="12" | [[S1C88_LD|LD]]
|[[PM_Opc_MOV16|MOV SP, X]]
+
| HL,[hhll]
|8
+
| B9,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F3
+
| HL,#mmnn
|[[PM_Opc_MOV16|MOV SP, Y]]
+
| C5,nn,mm
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F4
+
| HL,[SP+dd]
|[[PM_Opc_MOV16|MOV HL, SP]]
+
| CE,71,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F5
+
| HL,[HL]
|[[PM_Opc_MOV16|MOV HL, PC]]
+
| CE,C1
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F8
+
| HL,[IX]
|[[PM_Opc_MOV16|MOV BA, SP]]
+
| CE,D1
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF F9
+
| HL,[IY]
|[[PM_Opc_MOV16|MOV BA, PC]]
+
| CE,D9
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF FA
+
| HL,BA
|[[PM_Opc_MOV16|MOV X, SP]]
+
| CE,E4
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF FE
+
| HL,HL
|[[PM_Opc_MOV16|MOV Y, SP]]
+
| CE,E5
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|}
+
| HL,IX
 
+
| CE,E6
'''Flags Affected:''' None
+
| ?PSEUDOCODE
 
+
| ?CYCLES
= Arithmetic =
+
| 2
 
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
== ADD = Addition ==
+
|-
 
+
| HL,IY
[[PM_Opc_ADD8|8 Bit Opcode overview]]
+
| CE,E7
 
+
| ?PSEUDOCODE
[[PM_Opc_ADD16|16 Bit Opcode overview]]
+
| ?CYCLES
 
+
| 2
{| border="1" style="text-align:left" class="sortable"
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
!Hex
+
|-
!Mnemonic
+
| HL,SP
!Cycles
+
| CE,F4
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| HL,PC
 +
| CE,F5
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| rowspan="4" | [[S1C88_LD|LD]]
 +
| [IY+L],A
 +
| CE,47
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [IY+L],B
 +
| CE,4F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [IY+L],L
 +
| CE,57
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – || – ||  – || –
 +
|-
 +
| [IY+L],H
 +
| CE,5F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| rowspan="2" | [[S1C88_LD|LD]]
 +
| YP,#pp
 +
| CE,C7,pp
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| YP,A
 +
| CE,CF
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| rowspan="17" | [[S1C88_LD|LD]]
 +
| [IY],A
 +
| 70
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [IY],B
 +
| 71
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [IY],L
 +
| 72
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [IY],H
 +
| 73
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|00
+
| [IY],[BR:ll]
|[[PM_Opc_ADD8|ADD A, A]]
+
| 74,ll
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|01
+
| [IY],[HL]
|[[PM_Opc_ADD8|ADD A, B]]
+
| 75
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|02 nn
+
| [IY],[IX]
|[[PM_Opc_ADD8|ADD A, #nn]]
+
| 76
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|03
+
| [IY],[IY]
|[[PM_Opc_ADD8|ADD A, [HL]]]
+
| 77
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|04 nn
+
| [IY],#nn
|[[PM_Opc_ADD8|ADD A, [N+#nn]]]
+
| B7,nn
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|05 nn nn
+
| [IY],[IX+dd]
|[[PM_Opc_ADD8|ADD A, [#nnnn]]]
+
| CE,78,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|06
+
| [IY],[IY+dd]
|[[PM_Opc_ADD8|ADD A, [X]]]
+
| CE,79,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|07
+
| [IY],[IX+L]
|[[PM_Opc_ADD8|ADD A, [Y]]]
+
| CE,7A
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|C0 nn nn
+
| [IY],[IY+L]
|[[PM_Opc_ADD16|ADD BA, #nnnn]]
+
| CE,7B
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|C1 nn nn
+
| [IY],BA
|[[PM_Opc_ADD16|ADD HL, #nnnn]]
+
| CE,DC
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|C2 nn nn
+
| [IY],HL
|[[PM_Opc_ADD16|ADD X, #nnnn]]
+
| CE,DD
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|C3 nn nn
+
| [IY],IX
|[[PM_Opc_ADD16|ADD Y, #nnnn]]
+
| CE,DE
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 68 nn nn
+
| [IY],IY
|[[PM_Opc_ADD16|ADD SP, #nnnn]]
+
| CE,DF
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 00 ss
+
| rowspan="8" | [[S1C88_LD|LD]]
|[[PM_Opc_ADD8|ADD A, [X+#ss]]]
+
| [BR:ll],A
|16
+
| 78,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 01 ss
+
| [BR:ll],B
|[[PM_Opc_ADD8|ADD A, [Y+#ss]]]
+
| 79,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 02
+
| [BR:ll],L
|[[PM_Opc_ADD8|ADD A, [X+L]]]
+
| 7A,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 03
+
| [BR:ll],H
|[[PM_Opc_ADD8|ADD A, [Y+L]]]
+
| 7B,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 04
+
| [BR:ll],[HL]
|[[PM_Opc_ADD8|ADD [HL], A]]
+
| 7D,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 05 nn
+
| [BR:ll],[IX]
|[[PM_Opc_ADD8|ADD [HL], #nn]]
+
| 7E,ll
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 06
+
| [BR:ll],[IY]
|[[PM_Opc_ADD8|ADD [HL], [X]]]
+
| 7F,ll
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 07
+
| [BR:ll],#nn
|[[PM_Opc_ADD8|ADD [HL], [Y]]]
+
| DD,ll,nn
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 00
+
| rowspan="4" | [[S1C88_LD|LD]]
|[[PM_Opc_ADD16|ADD BA, BA]]
+
| [SP+dd],BA
|16
+
| CE,74,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 01
+
| [SP+dd],HL
|[[PM_Opc_ADD16|ADD BA, HL]]
+
| CE,75,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 02
+
| [SP+dd],IX
|[[PM_Opc_ADD16|ADD BA, X]]
+
| CE,76,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 03
+
| [SP+dd],IY
|[[PM_Opc_ADD16|ADD BA, Y]]
+
| CE,77,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 20
+
| rowspan="4" | [[S1C88_LD|LD]]
|[[PM_Opc_ADD16|ADD HL, BA]]
+
| [IY+dd],A
|16
+
| CE,45,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 21
+
| [IY+dd],B
|[[PM_Opc_ADD16|ADD HL, HL]]
+
| CE,4D,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 22
+
| [IY+dd],L
|[[PM_Opc_ADD16|ADD HL, X]]
+
| CE,55,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 23
+
| [IY+dd],H
|[[PM_Opc_ADD16|ADD HL, Y]]
+
| CE,5D,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 40
+
| rowspan="20" | [[S1C88_LD|LD]]
|[[PM_Opc_ADD16|ADD X, BA]]
+
| A,A
|16
+
| 40
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 41
+
| A,B
|[[PM_Opc_ADD16|ADD X, HL]]
+
| 41
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 42
+
| A,L
|[[PM_Opc_ADD16|ADD Y, BA]]
+
| 42
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 43
+
| A,H
|[[PM_Opc_ADD16|ADD Y, HL]]
+
| 43
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 44
+
| A,[BR:ll]
|[[PM_Opc_ADD16|ADD SP, BA]]
+
| 44,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 45
+
| A,[HL]
|[[PM_Opc_ADD16|ADD SP, HL]]
+
| 45
|16
+
| ?PSEUDOCODE
|}
+
| ?CYCLES
 
+
| 1
'''Flags Affected:''' All
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
 
== SUB = Subtraction ==
 
 
 
[[PM_Opc_SUB8|8 Bit Opcode overview]]
 
 
 
[[PM_Opc_SUB16|16 Bit Opcode overview]]
 
 
 
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|10
+
| A,[IX]
|[[PM_Opc_SUB8|SUB A, A]]
+
| 46
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|11
+
| A,[IY]
|[[PM_Opc_SUB8|SUB A, B]]
+
| 47
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|12 nn
+
| A,#nn
|[[PM_Opc_SUB8|SUB A, #nn]]
+
| B0,nn
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|13
+
| A,[IX+dd]
|[[PM_Opc_SUB8|SUB A, [HL]]]
+
| CE,40,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|14 nn
+
| A,[IY+dd]
|[[PM_Opc_SUB8|SUB A, [N+#nn]]]
+
| CE,41,dd
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|15 nn nn
+
| A,[IX+L]
|[[PM_Opc_SUB8|SUB A, [#nnnn]]]
+
| CE,42
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|16
+
| A,[IY+L]
|[[PM_Opc_SUB8|SUB A, [X]]]
+
| CE,43
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|17
+
| A,BR
|[[PM_Opc_SUB8|SUB A, [Y]]]
+
| CE,C0
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D0 nn nn
+
| A,SC
|[[PM_Opc_SUB16|SUB BA, #nnnn]]
+
| CE,C1
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D1 nn nn
+
| A,NB
|[[PM_Opc_SUB16|SUB HL, #nnnn]]
+
| CE,C8
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D2 nn nn
+
| A,EP
|[[PM_Opc_SUB16|SUB X, #nnnn]]
+
| CE,C9
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D3 nn nn
+
| A,XP
|[[PM_Opc_SUB16|SUB Y, #nnnn]]
+
| CE,CA
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 6A nn nn
+
| A,YP
|[[PM_Opc_SUB16|SUB SP, #nnnn]]
+
| CE,CB
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 10 ss
+
| A,[hhll]
|[[PM_Opc_SUB8|SUB A, [X+#ss]]]
+
| CE,D0,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 11 ss
+
| rowspan="11" | [[S1C88_LD|LD]]
|[[PM_Opc_SUB8|SUB A, [Y+#ss]]]
+
| IX,[hhll]
|16
+
| BA,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 12
+
| IX,#mmnn
|[[PM_Opc_SUB8|SUB A, [X+L]]]
+
| C6,nn,mm
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 13
+
| IX,[SP+dd]
|[[PM_Opc_SUB8|SUB A, [Y+L]]]
+
| CE,72,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 14
+
| IX,[HL]
|[[PM_Opc_SUB8|SUB [HL], A]]
+
| CE,C2
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 15 nn
+
| IX,[IX]
|[[PM_Opc_SUB8|SUB [HL], #nn]]
+
| CE,D2
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 16
+
| IX,[IY]
|[[PM_Opc_SUB8|SUB [HL], [X]]]
+
| CE,DA
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 17
+
| IX,BA
|[[PM_Opc_SUB8|SUB [HL], [Y]]]
+
| CE,E8
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 08
+
| IX,HL
|[[PM_Opc_SUB16|SUB BA, BA]]
+
| CE,E9
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 09
+
| IX,IX
|[[PM_Opc_SUB16|SUB BA, HL]]
+
| CE,EA
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0A
+
| IX,IY
|[[PM_Opc_SUB16|SUB BA, X]]
+
| CE,EB
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0B
+
| IX,SP
|[[PM_Opc_SUB16|SUB BA, Y]]
+
| CE,FA
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 28
+
| rowspan="14" | [[S1C88_LD|LD]]
|[[PM_Opc_SUB16|SUB HL, BA]]
+
| B,A
|16
+
| 48
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 29
+
| B,B
|[[PM_Opc_SUB16|SUB HL, HL]]
+
| 49
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2A
+
| B,L
|[[PM_Opc_SUB16|SUB HL, X]]
+
| 4A
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2B
+
| B,H
|[[PM_Opc_SUB16|SUB HL, Y]]
+
| 4B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 48
+
| B,[BR:ll]
|[[PM_Opc_SUB16|SUB X, BA]]
+
| 4C,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 49
+
| B,[HL]
|[[PM_Opc_SUB16|SUB X, HL]]
+
| 4D
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 4A
+
| B,[IX]
|[[PM_Opc_SUB16|SUB Y, BA]]
+
| 4E
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 4B
+
| B,[IY]
|[[PM_Opc_SUB16|SUB Y, HL]]
+
| 4F
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 4C
+
| B,#nn
|[[PM_Opc_SUB16|SUB SP, BA]]
+
| B1,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 4D
+
| B,[IX+dd]
|[[PM_Opc_SUB16|SUB SP, HL]]
+
| CE,48,dd
|16
+
| ?PSEUDOCODE
|}
+
| ?CYCLES
 
+
| 3
'''Flags Affected:''' All
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
 
== ADC = Addition with Carry ==
 
 
 
[[PM_Opc_ADC8|8 Bit Opcode overview]]
 
 
 
[[PM_Opc_ADC16|16 Bit Opcode overview]]
 
 
 
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|08
+
| B,[IY+dd]
|[[PM_Opc_ADC8|ADC A, A]]
+
| CE,49,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|09
+
| B,[IX+L]
|[[PM_Opc_ADC8|ADC A, B]]
+
| CE,4A
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0A nn
+
| B,[IY+L]
|[[PM_Opc_ADC8|ADC A, #nn]]
+
| CE,4B
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0B
+
| B,[hhll]
|[[PM_Opc_ADC8|ADC A, [HL]]]
+
| CE,D1,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0C nn
+
| rowspan="14" | [[S1C88_LD|LD]]
|[[PM_Opc_ADC8|ADC A, [N+#nn]]]
+
| H,A
|12
+
| 58
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0D nn nn
+
| H,B
|[[PM_Opc_ADC8|ADC A, [#nnnn]]]
+
| 59
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0E
+
| H,L
|[[PM_Opc_ADC8|ADC A, [X]]]
+
| 5A
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|0F
+
| H,H
|[[PM_Opc_ADC8|ADC A, [Y]]]
+
| 5B
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 08 ss
+
| H,[BR:ll]
|[[PM_Opc_ADC8|ADC A, [X+#ss]]]
+
| 5C,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 09 ss
+
| H,[HL]
|[[PM_Opc_ADC8|ADC A, [Y+#ss]]]
+
| 5D
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0A
+
| H,[IX]
|[[PM_Opc_ADC8|ADC A, [X+L]]]
+
| 5E
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0B
+
| H,[IY]
|[[PM_Opc_ADC8|ADC A, [Y+L]]]
+
| 5F
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0C
+
| H,#nn
|[[PM_Opc_ADC8|ADC [HL], A]]
+
| B3,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0D nn
+
| H,[IX+dd]
|[[PM_Opc_ADC8|ADC [HL], #nn]]
+
| CE,58,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0E
+
| H,[IY+dd]
|[[PM_Opc_ADC8|ADC [HL], [X]]]
+
| CE,59,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 0F
+
| H,[IX+L]
|[[PM_Opc_ADC8|ADC [HL], [Y]]]
+
| CE,5A
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 04
+
| H,[IY+L]
|[[PM_Opc_ADC16|ADC BA, BA]]
+
| CE,5B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 05
+
| H,[hhll]
|[[PM_Opc_ADC16|ADC BA, HL]]
+
| CE,D3,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 06
+
| rowspan="17" | [[S1C88_LD|LD]]
|[[PM_Opc_ADC16|ADC BA, X]]
+
| [HL],A
|16
+
| 68
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 07
+
| [HL],B
|[[PM_Opc_ADC16|ADC BA, Y]]
+
| 69
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 24
+
| [HL],L
|[[PM_Opc_ADC16|ADC HL, BA]]
+
| 6A
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 25
+
| [HL],H
|[[PM_Opc_ADC16|ADC HL, HL]]
+
| 6B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 26
+
| [HL],[BR:ll]
|[[PM_Opc_ADC16|ADC HL, X]]
+
| 6C,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 27
+
| [HL],[HL]
|[[PM_Opc_ADC16|ADC HL, Y]]
+
| 6D
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 60 nn nn
+
| [HL],[IX]
|[[PM_Opc_ADC16|ADC BA, #nnnn]]
+
| 6E
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 61 nn nn
+
| [HL],[IY]
|[[PM_Opc_ADC16|ADC HL, #nnnn]]
+
| 6F
|16
+
| ?PSEUDOCODE
|}
+
| ?CYCLES
 
+
| 1
'''Flags Affected:''' All
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
 
== SBC = Subtraction with Carry ==
 
 
 
[[PM_Opc_SBC8|8 Bit Opcode overview]]
 
 
 
[[PM_Opc_SBC16|16 Bit Opcode overview]]
 
 
 
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|18
+
| [HL],#nn
|[[PM_Opc_SBC8|SBC A, A]]
+
| B5,nn
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|19
+
| [HL],[IX+dd]
|[[PM_Opc_SBC8|SBC A, B]]
+
| CE,60,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1A nn
+
| [HL],[IY+dd]
|[[PM_Opc_SBC8|SBC A, #nn]]
+
| CE,61,dd
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1B
+
| [HL],[IX+L]
|[[PM_Opc_SBC8|SBC A, [HL]]]
+
| CE,62
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1C nn
+
| [HL],[IY+L]
|[[PM_Opc_SBC8|SBC A, [N+#nn]]]
+
| CE,63
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1D nn nn
+
| [HL],BA
|[[PM_Opc_SBC8|SBC A, [#nnnn]]]
+
| CE,C4
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1E
+
| [HL],HL
|[[PM_Opc_SBC8|SBC A, [X]]]
+
| CE,C5
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|1F
+
| [HL],IX
|[[PM_Opc_SBC8|SBC A, [Y]]]
+
| CE,C6
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 18 ss
+
| [HL],IY
|[[PM_Opc_SBC8|SBC A, [X+#ss]]]
+
| CE,C7
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 19 ss
+
| rowspan="14" | [[S1C88_LD|LD]]
|[[PM_Opc_SBC8|SBC A, [Y+#ss]]]
+
| L,A
|16
+
| 50
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1A
+
| L,B
|[[PM_Opc_SBC8|SBC A, [X+L]]]
+
| 51
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1B
+
| L,L
|[[PM_Opc_SBC8|SBC A, [Y+L]]]
+
| 52
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1C
+
| L,H
|[[PM_Opc_SBC8|SBC [HL], A]]
+
| 53
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1D nn
+
| L,[BR:ll]
|[[PM_Opc_SBC8|SBC [HL], #nn]]
+
| 54,ll
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1E
+
| L,[HL]
|[[PM_Opc_SBC8|SBC [HL], [X]]]
+
| 55
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 1F
+
| L,[IX]
|[[PM_Opc_SBC8|SBC [HL], [Y]]]
+
| 56
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0C
+
| L,[IY]
|[[PM_Opc_SBC16|SBC BA, BA]]
+
| 57
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0D
+
| L,#nn
|[[PM_Opc_SBC16|SBC BA, HL]]
+
| B2,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0E
+
| L,[IX+dd]
|[[PM_Opc_SBC16|SBC BA, X]]
+
| CE,50,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 0F
+
| L,[IY+dd]
|[[PM_Opc_SBC16|SBC BA, Y]]
+
| CE,51,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2C
+
| L,[IX+L]
|[[PM_Opc_SBC16|SBC HL, BA]]
+
| CE,52
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2D
+
| L,[IY+L]
|[[PM_Opc_SBC16|SBC HL, HL]]
+
| CE,53
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2E
+
| L,[hhll]
|[[PM_Opc_SBC16|SBC HL, X]]
+
| CE,D2,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 2F
+
| rowspan="9" | [[S1C88_LD|LD]]
|[[PM_Opc_SBC16|SBC HL, Y]]
+
| [hhll],BA
|16
+
| BC,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 62 nn nn
+
| [hhll],HL
|[[PM_Opc_SBC16|SBC BA, #nnnn]]
+
| BD,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 63 nn nn
+
| [hhll],IX
|[[PM_Opc_SBC16|SBC HL, #nnnn]]
+
| BE,ll,hh
|16
+
| ?PSEUDOCODE
|}
+
| ?CYCLES
 
+
| 3
'''Flags Affected:''' All
+
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
 
== CMP = Compare ==
 
 
 
[[PM_Opc_CMP8|8 Bit Opcode overview]]
 
 
 
[[PM_Opc_CMP16|16 Bit Opcode overview]]
 
 
 
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|30
+
| [hhll],IY
|[[PM_Opc_CMP8|CMP A, A]]
+
| BF,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|31
+
| [hhll],A
|[[PM_Opc_CMP8|CMP A, B]]
+
| CE,D4,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|32 nn
+
| [hhll],B
|[[PM_Opc_CMP8|CMP A, #nn]]
+
| CE,D5,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|33
+
| [hhll],L
|[[PM_Opc_CMP8|CMP A, [HL]]]
+
| CE,D6,ll,hh
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|34 nn
+
| [hhll],H
|[[PM_Opc_CMP8|CMP A, [N+#nn]]]
+
| CE,D7,ll,hh
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|35 nn nn
+
| [hhll],SP
|[[PM_Opc_CMP8|CMP A, [#nnnn]]]
+
| CE,7C,ll,hh
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|36
+
| rowspan="2" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP8|CMP A, [X]]]
+
| XP,#pp
|8
+
| CE,C6,pp
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|37
+
| XP,A
|[[PM_Opc_CMP8|CMP A, [Y]]]
+
| CE,CE
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D4 nn nn
+
| rowspan="2" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP16|CMP BA, #nnnn]]
+
| EP,#pp
|12
+
| CE,C5,pp
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D5 nn nn
+
| EP,A
|[[PM_Opc_CMP16|CMP HL, #nnnn]]
+
| CE,CD
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D6 nn nn
+
| rowspan="17" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP16|CMP X, #nnnn]]
+
| [IX],A
|12
+
| 60
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|D7 nn nn
+
| [IX],B
|[[PM_Opc_CMP16|CMP Y, #nnnn]]
+
| 61
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 6C nn nn
+
| [IX],L
|[[PM_Opc_CMP16|CMP SP, #nnnn]]
+
| 62
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|DB nn nn
+
| [IX],H
|[[PM_Opc_CMP8|CMP [N+#nn], #nn]]
+
| 63
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 30 ss
+
| [IX],[BR:ll]
|[[PM_Opc_CMP8|CMP A, [X+#ss]]]
+
| 64,ll
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 31 ss
+
| [IX],[HL]
|[[PM_Opc_CMP8|CMP A, [Y+#ss]]]
+
| 65
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 32
+
| [IX],[IX]
|[[PM_Opc_CMP8|CMP A, [X+L]]]
+
| 66
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 33
+
| [IX],[IY]
|[[PM_Opc_CMP8|CMP A, [Y+L]]]
+
| 67
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 34
+
| [IX],#nn
|[[PM_Opc_CMP8|CMP [HL], A]]
+
| B6,nn
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 35 nn
+
| [IX],[IX+dd]
|[[PM_Opc_CMP8|CMP [HL], #nn]]
+
| CE,68,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 36
+
| [IX],[IY+dd]
|[[PM_Opc_CMP8|CMP [HL], [X]]]
+
| CE,69,dd
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE 37
+
| [IX],[IX+L]
|[[PM_Opc_CMP8|CMP [HL], [Y]]]
+
| CE,6A
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE BC nn
+
| [IX],[IY+L]
|[[PM_Opc_CMP8|CMP B, #nn]]
+
| CE,6B
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE BD nn
+
| [IX],BA
|[[PM_Opc_CMP8|CMP L, #nn]]
+
| CE,D4
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE BE nn
+
| [IX],HL
|[[PM_Opc_CMP8|CMP H, #nn]]
+
| CE,D5
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CE BF nn
+
| [IX],IX
|[[PM_Opc_CMP8|CMP N, #nn]]
+
| CE,D6
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 18
+
| [IX],IY
|[[PM_Opc_CMP16|CMP BA, BA]]
+
| CE,D7
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 19
+
| rowspan="4" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP16|CMP BA, HL]]
+
| [IX+dd],A
|16
+
| CE,44,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 1A
+
| [IX+dd],B
|[[PM_Opc_CMP16|CMP BA, X]]
+
| CE,4C,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 1B
+
| [IX+dd],L
|[[PM_Opc_CMP16|CMP BA, Y]]
+
| CE,54,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 38
+
| [IX+dd],H
|[[PM_Opc_CMP16|CMP HL, BA]]
+
| CE,5C,dd
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 39
+
| rowspan="2" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP16|CMP HL, HL]]
+
| SC,#nn
|16
+
| 9F,nn
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF 3A
+
| SC,A
|[[PM_Opc_CMP16|CMP HL, X]]
+
| CE,C3
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CF 3B
+
| rowspan="2" | [[S1C88_LD|LD]]
|[[PM_Opc_CMP16|CMP HL, Y]]
+
| NB,#bb
|16
+
| CE,C4,bb
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 5C
+
| NB,A
|[[PM_Opc_CMP16|CMP SP, BA]]
+
| CE,CC
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 
|-
 
|-
|CF 5D
 
|[[PM_Opc_CMP16|CMP SP, HL]]
 
|16
 
 
|}
 
|}
  
'''Flags Affected:''' All
+
== '''EX''': Byte exchange ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="2" | [[S1C88_EX|EX]]
 +
| A,B
 +
| CC
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| A,[HL]
 +
| CD
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|}
  
== INC = Increase Register by 1 ==
+
== '''SWAP''': Nibble exchange ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_SWAP|SWAP]]
 +
| A
 +
| F6
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
| [[S1C88_SWAP|SWAP]]
 +
| [HL]
 +
| F7
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – ||  – ||  – ||  – ||  – ||  – || –
 +
|-
 +
|}
  
[[PM_Opc_INC8|8 Bit Opcode overview]]
+
= Rotate/shift =
 +
== '''RL''': Rotate to left ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_RL|RL]]
 +
| A
 +
| CE,90
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RL|RL]]
 +
| B
 +
| CE,91
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RL|RL]]
 +
| [HL]
 +
| CE,93
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RL|RL]]
 +
| [BR:ll]
 +
| CE,92,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
|}
  
[[PM_Opc_INC16|16 Bit Opcode overview]]
+
== '''RLC''': Rotate to left with carry ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_RLC|RLC]]
 +
| A
 +
| CE,94
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RLC|RLC]]
 +
| B
 +
| CE,95
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RLC|RLC]]
 +
| [HL]
 +
| CE,97
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
| [[S1C88_RLC|RLC]]
 +
| [BR:ll]
 +
| CE,96,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 +
|-
 +
|}
  
{| border="1" style="text-align:left" class="sortable"
+
== '''RR''': Rotate to right ==
!Hex
+
{| class="wikitable sortable"
!Mnemonic
+
! rowspan="2" colspan="2" | Mnemonic
!Cycles
+
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|80
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_INC8|INC A]]
 
|8
 
 
|-
 
|-
|81
+
| [[S1C88_RR|RR]]
|[[PM_Opc_INC8|INC B]]
+
| A
|8
+
| CE,98
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|82
+
| [[S1C88_RR|RR]]
|[[PM_Opc_INC8|INC L]]
+
| B
|8
+
| CE,99
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|83
+
| [[S1C88_RR|RR]]
|[[PM_Opc_INC8|INC H]]
+
| [HL]
|8
+
| CE,9B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|84
+
| [[S1C88_RR|RR]]
|[[PM_Opc_INC8|INC N]]
+
| [BR:ll]
|8
+
| CE,9A,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|85 nn
+
|}
|[[PM_Opc_INC8|INC [N+#nn]]]
+
 
|16
+
== '''RRC''': Rotate to right with carry ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|86
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_INC8|INC [HL]]]
 
|12
 
 
|-
 
|-
|87
+
| [[S1C88_RRC|RRC]]
|[[PM_Opc_INC16|INC SP]]
+
| A
|8
+
| CE,9C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|90
+
| [[S1C88_RRC|RRC]]
|[[PM_Opc_INC16|INC BA]]
+
| B
|8
+
| CE,9D
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|91
+
| [[S1C88_RRC|RRC]]
|[[PM_Opc_INC16|INC HL]]
+
| [HL]
|8
+
| CE,9F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|92
+
| [[S1C88_RRC|RRC]]
|[[PM_Opc_INC16|INC X]]
+
| [BR:ll]
|8
+
| CE,9E,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|93
 
|[[PM_Opc_INC16|INC Y]]
 
|8
 
 
|}
 
|}
  
'''Flags Affected:''' Zero
+
== '''SLA''': Arithmetic shift to left ==
 
+
{| class="wikitable sortable"
== DEC = Decrease Register by 1 ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
[[PM_Opc_DEC8|8 Bit Opcode overview]]
+
! rowspan="2" | Operation
 
+
! rowspan="2" | Cycles
[[PM_Opc_DEC16|16 Bit Opcode overview]]
+
! rowspan="2" | Bytes
 
+
! colspan="8" | SC
{| border="1" style="text-align:left" class="sortable"
 
!Hex
 
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|88
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_DEC8|DEC A]]
 
|8
 
 
|-
 
|-
|89
+
| [[S1C88_SLA|SLA]]
|[[PM_Opc_DEC8|DEC B]]
+
| A
|8
+
| CE,80
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|8A
+
| [[S1C88_SLA|SLA]]
|[[PM_Opc_DEC8|DEC L]]
+
| B
|8
+
| CE,81
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|8B
+
| [[S1C88_SLA|SLA]]
|[[PM_Opc_DEC8|DEC H]]
+
| [HL]
|8
+
| CE,83
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|8C
+
| [[S1C88_SLA|SLA]]
|[[PM_Opc_DEC8|DEC N]]
+
| [BR:ll]
|8
+
| CE,82,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|8D nn
+
|}
|[[PM_Opc_DEC8|DEC [N+#nn]]]
+
 
|16
+
== '''SLL''': Logical shift to left ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|8E
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_DEC8|DEC [HL]]]
 
|12
 
 
|-
 
|-
|8F
+
| [[S1C88_SLL|SLL]]
|[[PM_Opc_DEC16|DEC SP]]
+
| A
|8
+
| CE,84
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|98
+
| [[S1C88_SLL|SLL]]
|[[PM_Opc_DEC16|DEC BA]]
+
| B
|8
+
| CE,85
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|99
+
| [[S1C88_SLL|SLL]]
|[[PM_Opc_DEC16|DEC HL]]
+
| [HL]
|8
+
| CE,87
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|9A
+
| [[S1C88_SLL|SLL]]
|[[PM_Opc_DEC16|DEC X]]
+
| [BR:ll]
|8
+
| CE,86,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || – || ↕ || ↕
 
|-
 
|-
|9B
 
|[[PM_Opc_DEC16|DEC Y]]
 
|8
 
 
|}
 
|}
  
'''Flags Affected:''' Zero
+
== '''SRA''': Arithmetic shift to right ==
 
+
{| class="wikitable sortable"
== NEG = Negate ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Operation
!Hex
+
! rowspan="2" | Cycles
!Mnemonic
+
! rowspan="2" | Bytes
!Cycles
+
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_SRA|SRA]]
 +
| A
 +
| CE,88
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || 0 || ↕ || ↕
 
|-
 
|-
|CE A4
+
| [[S1C88_SRA|SRA]]
|[[PM_Opc_NEG|NEG A]]
+
| B
|12
+
| CE,89
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || 0 || ↕ || ↕
 
|-
 
|-
|CE A5
+
| [[S1C88_SRA|SRA]]
|[[PM_Opc_NEG|NEG B]]
+
| [HL]
|12
+
| CE,8B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || 0 || ↕ || ↕
 
|-
 
|-
|CE A6
+
| [[S1C88_SRA|SRA]]
|[[PM_Opc_NEG|NEG [N+#nn]]]
+
| [BR:ll]
|20
+
| CE,8A,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || 0 || ↕ || ↕
 
|-
 
|-
|CE A7
 
|[[PM_Opc_NEG|NEG [HL]]]
 
|16
 
 
|}
 
|}
  
'''Flags Affected:''' All
+
== '''SRL''': Logical shift to right ==
 
+
{| class="wikitable sortable"
== MUL = Multiply ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Operation
!Hex
+
! rowspan="2" | Cycles
!Mnemonic
+
! rowspan="2" | Bytes
!Cycles
+
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_SRL|SRL]]
 +
| A
 +
| CE,8C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || 0 || – || ↕ || ↕
 +
|-
 +
| [[S1C88_SRL|SRL]]
 +
| B
 +
| CE,8D
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || 0 || – || ↕ || ↕
 +
|-
 +
| [[S1C88_SRL|SRL]]
 +
| [HL]
 +
| CE,8F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || 0 || – || ↕ || ↕
 +
|-
 +
| [[S1C88_SRL|SRL]]
 +
| [BR:ll]
 +
| CE,8E,ll
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || 0 || – || ↕ || ↕
 
|-
 
|-
|CE D8
 
|[[PM_Opc_MUL|MUL L, A]]
 
|48
 
 
|}
 
|}
  
'''Flags Affected:''' All
+
= Auxiliary operation =
 
+
== '''PACK''': Pack ==
== DIV = Divide ==
+
{| class="wikitable sortable"
 
+
! rowspan="2" colspan="2" | Mnemonic
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Machine Code
!Hex
+
! rowspan="2" | Operation
!Mnemonic
+
! rowspan="2" | Cycles
!Cycles
+
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_PACK|PACK]]
 +
|
 +
| DE
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || –
 
|-
 
|-
|CE D9
 
|[[PM_Opc_DIV|DIV HL, A]]
 
|52
 
 
|}
 
|}
  
'''Flags Affected:''' All
+
== '''UPCK''': Unpack ==
 
+
{| class="wikitable sortable"
'''Note:''' Can throw Division by Zero
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
= Logic =
+
! rowspan="2" | Operation
 
+
! rowspan="2" | Cycles
== TST = Test Bits ==
+
! rowspan="2" | Bytes
 
+
! colspan="8" | SC
{| border="1" style="text-align:left" class="sortable"
+
|-
!Hex
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
!Mnemonic
 
!Cycles
 
 
|-
 
|-
|94
+
| [[S1C88_UPCK|UPCK]]
|[[PM_Opc_TST|TST A, B]]
+
|  
|8
+
| DF
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || –
 
|-
 
|-
|95 nn
+
|}
|[[PM_Opc_TST|TST [HL], #nn]]
+
 
|12
+
== '''SEP''': Code extension ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|96 nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_TST|TST A, #nn]]
 
|8
 
 
|-
 
|-
|97 nn
+
| [[S1C88_SEP|SEP]]
|[[PM_Opc_TST|TST B, #nn]]
+
|  
|8
+
| CE,A8
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 
|-
 
|-
|DC nn nn
 
|[[PM_Opc_TST|TST [N+#nn], #nn]]
 
|16
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Sign
+
= 16-bit arithmetic operation =
 
+
== '''ADD''': Addition ==
== AND = Logical AND ==
+
{| class="wikitable sortable"
 
+
! rowspan="2" colspan="2" | Mnemonic
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Machine Code
!Hex
+
! rowspan="2" | Operation
!Mnemonic
+
! rowspan="2" | Cycles
!Cycles
+
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|20
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_AND|AND A, A]]
 
|8
 
 
|-
 
|-
|21
+
| rowspan="3" | [[S1C88_ADD|ADD]]
|[[PM_Opc_AND|AND A, B]]
+
| IX,#mmnn
|8
+
| C2,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|22 nn
+
| IX,BA
|[[PM_Opc_AND|AND A, #nn]]
+
| CE,40
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|23
+
| IX,HL
|[[PM_Opc_AND|AND A, [HL]]]
+
| CE,41
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|24 nn
+
| rowspan="5" | [[S1C88_ADD|ADD]]
|[[PM_Opc_AND|AND A, [N+#nn]]]
+
| BA,#mmnn
|12
+
| C0,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|25 nn nn
+
| BA,BA
|[[PM_Opc_AND|AND A, [#nnnn]]]
+
| CE, 0
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|26
+
| BA,HL
|[[PM_Opc_AND|AND A, [X]]]
+
| CE, 1
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|27
+
| BA,IX
|[[PM_Opc_AND|AND A, [Y]]]
+
| CE, 2
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|9C nn
+
| BA,IY
|[[PM_Opc_AND|AND F, #nn]]
+
| CE, 3
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B0 nn
+
| rowspan="3" | [[S1C88_ADD|ADD]]
|[[PM_Opc_AND|AND B, #nn]]
+
| SP,BA
|12
+
| CE,44
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B1 nn
+
| SP,HL
|[[PM_Opc_AND|AND L, #nn]]
+
| CE,45
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B2 nn
+
| SP,#mmnn
|[[PM_Opc_AND|AND H, #nn]]
+
| CE,68,nn,mm
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|D8 nn nn
+
| rowspan="3" | [[S1C88_ADD|ADD]]
|[[PM_Opc_AND|AND [N+#nn], #nn]]
+
| IY,#mmnn
|20
+
| C3,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 20 ss
+
| IY,BA
|[[PM_Opc_AND|AND A, [X+#ss]]]
+
| CE,42
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 21 ss
+
| IY,HL
|[[PM_Opc_AND|AND A, [Y+#ss]]]
+
| CE,43
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 22
+
| rowspan="5" | [[S1C88_ADD|ADD]]
|[[PM_Opc_AND|AND A, [X+L]]]
+
| HL,#mmnn
|16
+
| C1,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 23
+
| HL,BA
|[[PM_Opc_AND|AND A, [Y+L]]]
+
| CE,20
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 24
+
| HL,HL
|[[PM_Opc_AND|AND [HL], A]]
+
| CE,21
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 25 nn
+
| HL,IX
|[[PM_Opc_AND|AND [HL], #nn]]
+
| CE,22
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 26
+
| HL,IY
|[[PM_Opc_AND|AND [HL], [X]]]
+
| CE,23
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 27
 
|[[PM_Opc_AND|AND [HL], [Y]]]
 
|20
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Sign
+
== '''ADC''': Addition with carry ==
 
+
{| class="wikitable sortable"
== OR = Logical Inclusive-OR ==
+
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="5" | [[S1C88_ADC|ADC]]
 +
| BA,BA
 +
| CE, 4
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,HL
 +
| CE, 5
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,IX
 +
| CE, 6
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,IY
 +
| CE, 7
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,#mmnn
 +
| CE,60,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| rowspan="5" | [[S1C88_ADC|ADC]]
 +
| HL,BA
 +
| CE,24
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| HL,HL
 +
| CE,25
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| HL,IX
 +
| CE,26
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| HL,IY
 +
| CE,27
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| HL,#mmnn
 +
| CE,61,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
|}
  
{| border="1" style="text-align:left" class="sortable"
+
== '''SUB''': Subtraction ==
!Hex
+
{| class="wikitable sortable"
!Mnemonic
+
! rowspan="2" colspan="2" | Mnemonic
!Cycles
+
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|28
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_OR|OR A, A]]
 
|8
 
 
|-
 
|-
|29
+
| rowspan="3" | [[S1C88_SUB|SUB]]
|[[PM_Opc_OR|OR A, B]]
+
| IX,#mmnn
|8
+
| D2,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2A nn
+
| IX,BA
|[[PM_Opc_OR|OR A, #nn]]
+
| CE,48
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2B
+
| IX,HL
|[[PM_Opc_OR|OR A, [HL]]]
+
| CE,49
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2C nn
+
| rowspan="5" | [[S1C88_SUB|SUB]]
|[[PM_Opc_OR|OR A, [N+#nn]]]
+
| BA,#mmnn
|12
+
| D0,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2D nn nn
+
| BA,BA
|[[PM_Opc_OR|OR A, [#nnnn]]]
+
| CE, 8
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2E
+
| BA,HL
|[[PM_Opc_OR|OR A, [X]]]
+
| CE, 9
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|2F
+
| BA,IX
|[[PM_Opc_OR|OR A, [Y]]]
+
| CE, A
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|9D nn
+
| BA,IY
|[[PM_Opc_OR|OR F, #nn]]
+
| CE, B
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B4 nn
+
| rowspan="3" | [[S1C88_SUB|SUB]]
|[[PM_Opc_OR|OR B, #nn]]
+
| SP,BA
|12
+
| CE,4C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B5 nn
+
| SP,HL
|[[PM_Opc_OR|OR L, #nn]]
+
| CE,4D
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B6 nn
+
| SP,#mmnn
|[[PM_Opc_OR|OR H, #nn]]
+
| CE,6A,nn,mm
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|D9 nn nn
+
| rowspan="3" | [[S1C88_SUB|SUB]]
|[[PM_Opc_OR|OR [N+#nn], #nn]]
+
| IY,#mmnn
|20
+
| D3,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 28 ss
+
| IY,BA
|[[PM_Opc_OR|OR A, [X+#ss]]]
+
| CE,4A
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 29 ss
+
| IY,HL
|[[PM_Opc_OR|OR A, [Y+#ss]]]
+
| CE,4B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2A
+
| rowspan="5" | [[S1C88_SUB|SUB]]
|[[PM_Opc_OR|OR A, [X+L]]]
+
| HL,#mmnn
|16
+
| D1,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2B
+
| HL,BA
|[[PM_Opc_OR|OR A, [Y+L]]]
+
| CE,28
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2C
+
| HL,HL
|[[PM_Opc_OR|OR [HL], A]]
+
| CE,29
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2D nn
+
| HL,IX
|[[PM_Opc_OR|OR [HL], #nn]]
+
| CE,2A
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2E
+
| HL,IY
|[[PM_Opc_OR|OR [HL], [X]]]
+
| CE,2B
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 2F
 
|[[PM_Opc_OR|OR [HL], [Y]]]
 
|20
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Sign
+
== '''SBC''': Subtraction with carry ==
 
+
{| class="wikitable sortable"
== XOR = Logical Exclusive-OR ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Operation
!Hex
+
! rowspan="2" | Cycles
!Mnemonic
+
! rowspan="2" | Bytes
!Cycles
+
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="5" | [[S1C88_SBC|SBC]]
 +
| BA,BA
 +
| CE, C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,HL
 +
| CE, D
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,IX
 +
| CE, E
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,IY
 +
| CE, F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| BA,#mmnn
 +
| CE,62,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| rowspan="5" | [[S1C88_SBC|SBC]]
 +
| HL,BA
 +
| CE,2C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 +
|-
 +
| HL,HL
 +
| CE,2D
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|38
+
| HL,IX
|[[PM_Opc_XOR|XOR A, A]]
+
| CE,2E
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|39
+
| HL,IY
|[[PM_Opc_XOR|XOR A, B]]
+
| CE,2F
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|3A nn
+
| HL,#mmnn
|[[PM_Opc_XOR|XOR A, #nn]]
+
| CE,63,nn,mm
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|3B
+
|}
|[[PM_Opc_XOR|XOR A, [HL]]]
+
 
|8
+
== '''CP''': Comparison ==
 +
{| class="wikitable sortable"
 +
! rowspan="2" colspan="2" | Mnemonic
 +
! rowspan="2" | Machine Code
 +
! rowspan="2" | Operation
 +
! rowspan="2" | Cycles
 +
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 
|-
 
|-
|3C nn
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
|[[PM_Opc_XOR|XOR A, [N+#nn]]]
 
|12
 
 
|-
 
|-
|3D nn nn
+
| [[S1C88_CP|CP]]
|[[PM_Opc_XOR|XOR A, [#nnnn]]]
+
| IX,#mmnn
|16
+
| D6,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|3E
+
| rowspan="5" | [[S1C88_CP|CP]]
|[[PM_Opc_XOR|XOR A, [X]]]
+
| BA,#mmnn
|8
+
| D4,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|3F
+
| BA,BA
|[[PM_Opc_XOR|XOR A, [Y]]]
+
| CE,18
|8
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|9E nn
+
| BA,HL
|[[PM_Opc_XOR|XOR F, #nn]]
+
| CE,19
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B8 nn
+
| BA,IX
|[[PM_Opc_XOR|XOR B, #nn]]
+
| CE,1A
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE B9 nn
+
| BA,IY
|[[PM_Opc_XOR|XOR L, #nn]]
+
| CE,1B
|12
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE BA nn
+
| [[S1C88_CP|CP]]
|[[PM_Opc_XOR|XOR H, #nn]]
+
| IY,#mmnn
|12
+
| D7,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|DA nn nn
+
| rowspan="5" | [[S1C88_CP|CP]]
|[[PM_Opc_XOR|XOR [N+#nn], #nn]]
+
| HL,#mmnn
|20
+
| D5,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 38 ss
+
| HL,BA
|[[PM_Opc_XOR|XOR A, [X+#ss]]]
+
| CE,38
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 39 ss
+
| HL,HL
|[[PM_Opc_XOR|XOR A, [Y+#ss]]]
+
| CE,39
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3A
+
| HL,IX
|[[PM_Opc_XOR|XOR A, [X+L]]]
+
| CE,3A
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3B
+
| HL,IY
|[[PM_Opc_XOR|XOR A, [Y+L]]]
+
| CE,3B
|16
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3C
+
| rowspan="3" | [[S1C88_CP|CP]]
|[[PM_Opc_XOR|XOR [HL], A]]
+
| SP,BA
|16
+
| CE,5C
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3D nn
+
| SP,HL
|[[PM_Opc_XOR|XOR [HL], #nn]]
+
| CE,5D
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3E
+
| SP,#mmnn
|[[PM_Opc_XOR|XOR [HL], [X]]]
+
| CE,6C,nn,mm
|20
+
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 4
 +
| – || – || – || – || ↕ || ↕ || ↕ || ↕
 
|-
 
|-
|CE 3F
 
|[[PM_Opc_XOR|XOR [HL], [Y]]]
 
|20
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Sign
+
== '''INC''': 1 increment ==
 
+
{| class="wikitable sortable"
== NOT = Logical NOT ==
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Operation
!Hex
+
! rowspan="2" | Cycles
!Mnemonic
+
! rowspan="2" | Bytes
!Cycles
+
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_INC|INC]]
 +
| IX
 +
| 92
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 +
|-
 +
| [[S1C88_INC|INC]]
 +
| BA
 +
| 90
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE A0
+
| [[S1C88_INC|INC]]
|[[PM_Opc_NOT|NOT A]]
+
| HL
|12
+
| 91
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE A1
+
| [[S1C88_INC|INC]]
|[[PM_Opc_NOT|NOT B]]
+
| IY
|12
+
| 93
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE A2
+
| [[S1C88_INC|INC]]
|[[PM_Opc_NOT|NOT [N+#nn]]]
+
| SP
|20
+
| 87
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE A3
 
|[[PM_Opc_NOT|NOT [HL]]]
 
|16
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Sign
+
== '''DEC''': 1 decrement ==
 
+
{| class="wikitable sortable"
= Shift & Rotate =
+
! rowspan="2" colspan="2" | Mnemonic
 
+
! rowspan="2" | Machine Code
== SHL = Shift Left ==
+
! rowspan="2" | Operation
 
+
! rowspan="2" | Cycles
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Bytes
!Hex
+
! colspan="8" | SC
!Mnemonic
+
|-
!Cycles
+
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| [[S1C88_DEC|DEC]]
 +
| IX
 +
| 9A
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 +
|-
 +
| [[S1C88_DEC|DEC]]
 +
| BA
 +
| 98
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE 84
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_SHL|SHL A]]
+
| HL
|12
+
| 99
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE 85
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_SHL|SHL B]]
+
| IY
|12
+
| 9B
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE 86
+
| [[S1C88_DEC|DEC]]
|[[PM_Opc_SHL|SHL [N+#nn]]]
+
| SP
|20
+
| 8F
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 1
 +
| – || – || – || – || – || – || – || ↕
 
|-
 
|-
|CE 87
 
|[[PM_Opc_SHL|SHL [HL]]]
 
|16
 
 
|}
 
|}
  
'''Flags Affected:''' Zero, Carry, Sign
+
= 16-bit transfer =
 
+
== '''LD''': Load ==
== SAL = Shift Arithmetic Left ==
+
{| class="wikitable sortable"
 
+
! rowspan="2" colspan="2" | Mnemonic
{| border="1" style="text-align:left" class="sortable"
+
! rowspan="2" | Machine Code
!Hex
+
! rowspan="2" | Operation
!Mnemonic
+
! rowspan="2" | Cycles
!Cycles
+
! rowspan="2" | Bytes
 +
! colspan="8" | SC
 +
|-
 +
! I1 !! I0 !! U !! D !! N !! V !! C !! Z
 +
|-
 +
| rowspan="11" | [[S1C88_LD|LD]]
 +
| IY,[hhll]
 +
| BB,ll,hh
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,#mmnn
 +
| C7,nn,mm
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,[SP+dd]
 +
| CE,73,dd
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 3
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,[HL]
 +
| CE,C3
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,[IX]
 +
| CE,D3
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,[IY]
 +
| CE,DB
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,BA
 +
| CE,EC
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,HL
 +
| CE,ED
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,IX
 +
| CE,EE
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,IY
 +
| CE,EF
 +
| ?PSEUDOCODE
 +
| ?CYCLES
 +
| 2
 +
| – || – || – || – || – || – || – || –
 +
|-
 +
| IY,SP
 +
| CE,FE
 +
| ?PSEUDOCODE
 +
| ?CYCLES