Section 2 CPU
38
7. System control instructions
Addressing Mode/Instruction
Length (Bytes) Condition Code No. of
States*1
Mnemonic
Operand Size
#xx
Rn
@ERn
@(d,ERn)
@–ERn/@ERn+
@aa
@(d,PC)
@@aa
—
Operation IHNZVC
Normal
Advanced
TRAPA TRAPA #xx:2 — 2 PC→@–SP,CCR→@–SP,
EXR→@–SP,<vector>→PC 1————— 7
[9] 8
[9]
RTE RTE — EXR←@SP+,CCR←@SP+,
PC←@SP+ ↕↕↕↕↕↕ 5 [9]
SLEEP SLEEP — Transition to power-down state —————— 2
LDC LDC #xx:8,CCR B 2 #xx:8→CCR ↕↕↕↕↕↕ 1
LDC #xx:8,EXR B 4 #xx:8→EXR —————— 2
LDC Rs,CCR B 2 Rs8→CCR ↕↕↕↕↕↕ 1
LDC Rs,EXR B 2 Rs8→EXR —————— 1
LDC @ERs,CCR W 4 @ERs→CCR ↕↕↕↕↕↕ 3
LDC @ERs,EXR W 4 @ERs→EXR —————— 3
LDC @(d:16,ERs),CCR W 6 @(d:16,ERs)→CCR ↕↕↕↕↕↕ 4
LDC @(d:16,ERs),EXR W 6 @(d:16,ERs)→EXR —————— 4
LDC @(d:32,ERs),CCR W 10 @(d:32,ERs)→CCR ↕↕↕↕↕↕ 6
LDC @(d:32,ERs),EXR W 10 @(d:32,ERs)→EXR —————— 6
LDC @ERs+,CCR W 4 @ERs→CCR,ERs32+2→ERs32 ↕↕↕↕↕↕ 4
LDC @ERs+,EXR W 4 @ERs→EXR,ERs32+2→ERs32 —————— 4
LDC @aa:16,CCR W 6 @aa:16→CCR ↕↕↕↕↕↕ 4
LDC @aa:16,EXR W 6 @aa:16→EXR —————— 4
LDC @aa:32,CCR W 8 @aa:32→CCR ↕↕↕↕↕↕ 5
LDC @aa:32,EXR W 8 @aa:32→EXR —————— 5
STC STC CCR,Rd B 2 CCR→Rd8 —————— 1
STC EXR,Rd B 2 EXR→Rd8 —————— 1
STC CCR,@ERd W 4 CCR→@ERd —————— 3
STC EXR,@ERd W 4 EXR→@ERd —————— 3
STC CCR,@(d:16,ERd) W 6 CCR→@(d:16,ERd) —————— 4
STC EXR,@(d:16,ERd) W 6 EXR→@(d:16,ERd) —————— 4
STC CCR,@(d:32,ERd) W 10 CCR→@(d:32,ERd) —————— 6
STC EXR,@(d:32,ERd) W 10 EXR→@(d:32,ERd) —————— 6
STC CCR,@–ERd W 4 ERd32–2→ERd32,CCR→@ERd —————— 4
STC EXR,@–ERd W 4 ERd32–2→ERd32,EXR→@ERd —————— 4
STC CCR,@aa:16 W 6 CCR→@aa:16 —————— 4
STC EXR,@aa:16 W 6 EXR→@aa:16 —————— 4
STC CCR,@aa:32 W 8 CCR→@aa:32 —————— 5
STC EXR,@aa:32 W 8 EXR→@aa:32 —————— 5
ANDC ANDC #xx:8,CCR B 2 CCR ∧#xx:8→CCR ↕↕↕↕↕↕ 1
ANDC #xx:8,EXR B 4 EXR ∧#xx:8→EXR —————— 2
ORC ORC #xx:8,CCR B 2 CCR ∨#xx:8→CCR ↕↕↕↕↕↕ 1
ORC #xx:8,EXR B 4 EXR ∨#xx:8→EXR —————— 2
XORC XORC #xx:8,CCR B 2 CCR ⊕ #xx:8→CCR ↕↕↕↕↕↕ 1
XORC #xx:8,EXR B 4 EXR ⊕ #xx:8→EXR —————— 2
NOP NOP — 2 PC←PC+2 —————— 1