aboutsummaryrefslogtreecommitdiff
path: root/riscv/insns/c_jalr.h
blob: 12bc7f9ed6fed6c727ff07c15895bc93c8933390 (plain)
1
2
3
4
5
6
7
8
9
require_extension(EXT_ZCA);
require(insn.rvc_rs1() != 0);
reg_t tmp = npc;
set_pc(RVC_RS1 & ~reg_t(1));
WRITE_REG(X_RA, tmp);

if (ZICFILP_xLPE(STATE.v, STATE.prv)) {
  STATE.elp = ZICFILP_IS_LP_EXPECTED(insn.rvc_rs1());
}