RISC-V: Support for unlabeled landing pad PLT generation

This patch adds support for generating unlabeled landing pad PLT entries
for the RISC-V architecture. Unlabeled landing pad will place a LPAD
instruction at the PLT entry and PLT header, also PLT header will have
few changes due to the offset is different from the original one.

Ref: https://github.com/riscv-non-isa/riscv-elf-psabi-doc/pull/417
This commit is contained in:
Kito Cheng
2025-06-11 16:33:49 +08:00
committed by Nelson Chu
parent 84eb7d284b
commit 9b4b518ece
6 changed files with 202 additions and 1 deletions

View File

@@ -421,6 +421,7 @@ static inline unsigned int riscv_insn_length (insn_t insn)
/* ABI names for selected x-registers. */
#define X_ZERO 0
#define X_RA 1
#define X_SP 2
#define X_GP 3