stq
Store Quadword
stq RSp, DQ(RA)
Stores a quadword from two general-purpose registers into memory.
Details
Stores a 128-bit quadword from two consecutive general-purpose registers (RSp and RSp+1) into memory at the address formed by adding the base register (RA) and a 16-byte-aligned displacement. The displacement is a signed 12-bit value left-shifted by 4 bits, providing a range of ±2048 bytes on a 16-byte boundary. This instruction does not modify the condition register or status flags.
Pseudocode Operation
EA ← if RA = 0 then 0 else GPR[RA]
EA ← EA + EXTS(DQ || 0b0000)
MEM(EA, 16) ← GPR[RSp] || GPR[RSp+1]
Programming Note
In versions of the architecture prior to V. 2.07, this instruction was privileged.
Example
stq r4, 0(r4)
Encoding
Binary Layout
1
0
RSp
6
RA
11
DS
16
0
21
0
22
0
23
0
24
0
25
0
26
0
27
0
28
0
29
0
30
0
31
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
Operands
-
RSp
Src Pair -
DQ
Disp -
RA
Base -
disp
Displacement value