[PATCH] backends/riscv: Remove unused relocations

Andreas Schwab schwab@suse.de
Wed Jul 31 13:03:35 GMT 2024


None of these relocations were ever part of any object file.  The
GNU_VTINHERIT and GNU_VTINHERIT relocations were part of the obsolete
--gc-sections support which was never implemented for RISC-V.  The other
relocations are only used internally by libbfd during the relaxation pass
and eliminated before writing the object file.

	* riscv_reloc.def: Remove GNU_VTINHERIT, GNU_VTENTRY, RVC_LUI,
	GPREL_I, GPREL_S, TPREL_I, TPREL_S.
---
 backends/riscv_reloc.def | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/backends/riscv_reloc.def b/backends/riscv_reloc.def
index f52f6489..adae83ce 100644
--- a/backends/riscv_reloc.def
+++ b/backends/riscv_reloc.def
@@ -64,16 +64,9 @@ RELOC_TYPE (SUB8,		REL)
 RELOC_TYPE (SUB16,		REL)
 RELOC_TYPE (SUB32,		REL)
 RELOC_TYPE (SUB64,		REL)
-RELOC_TYPE (GNU_VTINHERIT,	REL)
-RELOC_TYPE (GNU_VTENTRY,	REL)
 RELOC_TYPE (ALIGN,		REL)
 RELOC_TYPE (RVC_BRANCH,		REL)
 RELOC_TYPE (RVC_JUMP,		REL)
-RELOC_TYPE (RVC_LUI,		REL)
-RELOC_TYPE (GPREL_I,		REL)
-RELOC_TYPE (GPREL_S,		REL)
-RELOC_TYPE (TPREL_I,		REL)
-RELOC_TYPE (TPREL_S,		REL)
 RELOC_TYPE (RELAX,		REL)
 RELOC_TYPE (SUB6,		REL)
 RELOC_TYPE (SET6,		REL)
-- 
2.46.0


-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."


More information about the Elfutils-devel mailing list