CHAPTER 7 DETAILED EXECUTION INSTRUCTIONS
7.64
LDUH (Load Half-word Data in Memory to Register)
Extends with zeros the half-word data at memory address "(R13 + Rj)", loads to "Ri".
■ LDUH (Load Half-word Data in Memory to Register)
Assembler format:
LDUH @(R13, Rj), Ri
extu (( R13 + Rj)) → Ri
Operation:
Flag change:
N, Z, V, and C: Unchanged
Execution cycles:
b cycle(s)
Instruction format:
Example:
LDUH @(R13, R2), R3
160
N
Z
V
C
–
–
–
–
MSB
0
0
0
0
Instruction bit pattern : 0000 0001 0010 0011
R2
0 0 0 0 0 0 0 4
R3
x x x x
x x x x
R13
1 2 3 4 5 6 7 8
12345678
Memory
1234567C
4 3 2 1
Before execution
0
0
0
1
Rj
LSB
Ri
R2
0 0 0 0 0 0 0 4
R3
0 0 0 0 4 3 2 1
R13
1 2 3 4 5 6 7 8
12345678
Memory
1234567C
4 3 2 1
After execution