C.LDSP

Compressed Load Doubleword from Stack Pointer

C.LDSP rd, offset(x2)

Loads a 64-bit value from the stack pointer (RV64).

Details

Loads a 64-bit doubleword from a stack-pointer-relative address into rd (RV64).

Pseudocode Operation

R[rd] = M[R[2] + offset][63:0];

Example

C.LDSP t0, 0(a0)

Encoding

Binary Layout
?
31:16
011
15:13
c_uimm9sphi
12
rd_n0
11:7
c_uimm9splo
6:2
10
1:0
 
Format CI
Opcode 0x00006002
Extension C

Operands

  • rd
    Destination register (integer)
  • offset
    Offset