stdu
Store Doubleword with Update DS-form
Stores a doubleword from a register to memory and updates the base address register.
Details
Stores a 64-bit doubleword from register RS to memory at the address computed from RA plus the sign-extended displacement, then updates RA with the effective address. The displacement is a 14-bit signed value (DS field), scaled by 8 to form a byte offset. This instruction is commonly used in prologue/epilogue code to allocate/deallocate stack space while storing values. No condition or status registers are affected.
Pseudocode Operation
EA ← (RA) + EXTS(DS || 0b00); M[EA:EA+7] ← (RS); 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
Encoding
Operands
-
RS
Source General Purpose Register -
RA
Base Address General Purpose Register -
disp
Displacement value