LD SP, s
Set Stack Pointer from register
7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | |
---|---|---|---|---|---|---|---|---|
\(SP \longleftarrow HL\) | ||||||||
LD SP,HL | ||||||||
1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 | F9 |
\(SP \longleftarrow IX\) | ||||||||
LD SP, IX | ||||||||
1 | 1 | 0 | 1 | 1 | 1 | 0 | 1 | DD |
1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 | F9 |
\(SP \longleftarrow IY\) | ||||||||
LD SP, IY | ||||||||
1 | 1 | 1 | 1 | 1 | 1 | 0 | 1 | FD |
1 | 1 | 1 | 1 | 1 | 0 | 0 | 1 | F9 |
Flags Affected
None. |
Opcode Matrix
HL | IX | IY | |
---|---|---|---|
SP |
LD SP, HL
F916 |
LD SP, IX
DDF926 |
LD SP, IY
FDF926 |
Instruction
Opcode hexSize bytesCycle count
| Register |
Last modified November 16, 2021: Update flag rendering so it can be reused for the Z80 (06001ea)