lhzu
Load Halfword and Zero with Update D-form
lhzu RT,D(RA)
Loads a halfword from memory into a register, zero-extends it to 64 bits, and updates the base address.
Details
The effective address (EA) is calculated as the sum of the contents of register RA and the sign-extended displacement D. The halfword at EA is loaded into RT48:63, with RT0:47 set to zero. The EA is then placed back into RA.
Pseudocode Operation
EA ← (RA) + EXTS(D)
RT ← 480 || MEM(EA, 2)
RA ← EA
Programming Note
The base register (RA) is updated with the effective address after the memory access. RA must not be 0 and must differ from the destination register; violating this constraint produces undefined results.
Example
lhzu r3, 0(r4)
Encoding
Binary Layout
0
0
RT
6
RA
11
D
16
Operands
-
RT
Target General Purpose Register -
RA
Base General Purpose Register -
D
Displacement