backends/riscv: Remove unused relocations

Message ID mvmed79hfx4.fsf@suse.de
State Committed
Headers
Series backends/riscv: Remove unused relocations |

Commit Message

Andreas Schwab July 31, 2024, 1:03 p.m. UTC
  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(-)
  

Comments

Aaron Merey Aug. 7, 2024, 1:48 p.m. UTC | #1
On Wed, Jul 31, 2024 at 9:03 AM Andreas Schwab <schwab@suse.de> wrote:
>
> 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.

Thanks Andreas, merged as commit 46c5c98ee7.

Aaron
  

Patch

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)