C.JAL

Compressed Jump and Link

C.JAL offset

Performs a PC-relative jump and stores return address in x1 (ra). RV32 only.

Details

Performs a PC-relative jump and saves the return address in x1 (RV32 only).

Pseudocode Operation

R[1] = PC + 2; PC += sext(offset);

Example

C.JAL func

Encoding

Binary Layout
?
31:16
001
15:13
c_imm12
12:2
01
1:0
 
Format CJ
Opcode 0x00002001
Extension C

Operands

  • offset
    Jump Target