lxvrdx

Load VSX Vector Rightmost Doubleword Indexed X-form

lxvrdx XT,RA,RB

Loads a doubleword from memory into the rightmost element of a VSX vector register.

Details

The lxvrdx instruction loads a doubleword from memory into the rightmost element of a VSX vector register. The address is calculated by adding the contents of two general-purpose registers, RA and RB. If RA is zero, it is treated as zero. The loaded data is placed into doubleword element 1 of VSR[XT], with doubleword element 0 being set to zero.

Pseudocode Operation

if MSR.VSX=0 then
    VSX_Unavailable()
EA = ((RA=0) ? 0 : GPR[RA]) + GPR[RB]
VSR[32×TX+T] = EXTZ128(MEM(EA,8))

Programming Note

The lxvrdx instruction is used to load a doubleword from memory into the rightmost element of a VSX vector register. Ensure that the VSX facility is enabled in the MSR register; otherwise, a VSX_Unavailable exception will be raised. The address calculation uses two general-purpose registers, RA and RB, where RA can be zero. Be cautious of alignment requirements for optimal performance and to avoid potential exceptions.

Example

lxvrdx vs1, r4, r5

Encoding

Binary Layout
0
0
T
6
RA
11
RB
16
109
21
TX
26
 
Format X-form
Opcode 0x7C0000DA
Extension VSX
Registers Altered MSR

Operands

  • XT
    Target VSX Vector Register
  • RA
    Source General Purpose Register (address base)
  • RB
    Source General Purpose Register (offset)