ld

Load Doubleword

ld RT, DS(RA)

Loads a doubleword (64 bits) from memory.

Details

The doubleword in storage addressed by EA is loaded into RT. The effective address (EA) is the sum of RA and disp, sign-extended to 64 bits.

Pseudocode Operation

if 'ld' then
    EA ← (RA|0) + EXTS64(DS||0b00)
    RT ← MEM(EA, 8)

Programming Note

The ld instruction loads a doubleword from memory into a register. Ensure the address is properly aligned to avoid alignment faults. This instruction operates at user privilege level and will raise an exception if the EA is out of bounds or access permissions are violated.

Example

ld r3, 16(r4)

Encoding

Binary Layout
0
0
RT
6
RA
11
DS
16
0
21
31
31
 
Format DS-form
Opcode 0xE8000000
Extension Base

Operands

  • RT
    Target Register
  • DS
    Displacement (14-bit Signed, Multiple of 4)
  • RA
    Base Register
  • disp
    Displacement value