[binutils-gdb] bfd/s12z: put relocations next to each other
Jan Beulich
jbeulich@sourceware.org
Mon Dec 15 10:32:43 GMT 2025
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=c7cfe60caee78d7fa7ab9b863969e6a17a9b48ca
commit c7cfe60caee78d7fa7ab9b863969e6a17a9b48ca
Author: Jan Beulich <jbeulich@suse.com>
Date: Mon Dec 15 11:29:54 2025 +0100
bfd/s12z: put relocations next to each other
It's not helpful to have two separate "sections", each with a single
relocation.
Diff:
---
bfd/bfd-in2.h | 11 +++++------
bfd/libbfd.h | 2 +-
bfd/reloc.c | 13 ++++++-------
3 files changed, 12 insertions(+), 14 deletions(-)
diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
index c9360bd917a..afd33b529a4 100644
--- a/bfd/bfd-in2.h
+++ b/bfd/bfd-in2.h
@@ -5816,11 +5816,6 @@ enum bfd_reloc_code_real
follows a matching LO8XG part. */
BFD_RELOC_M68HC12_HI8XG,
- /* Freescale S12Z reloc.
- This is a 15 bit relative address. If the most significant bits are
- all zero then it may be truncated to 8 bits. */
- BFD_RELOC_S12Z_15_PCREL,
-
/* NS CR16 Relocations. */
BFD_RELOC_CR16_NUM8,
BFD_RELOC_CR16_NUM16,
@@ -7197,9 +7192,13 @@ enum bfd_reloc_code_real
BFD_RELOC_CKCORE_PCREL_BLOOP_IMM4BY4,
BFD_RELOC_CKCORE_PCREL_BLOOP_IMM12BY4,
- /* S12Z relocations. */
+ /* Freescale S12Z relocations. */
BFD_RELOC_S12Z_OPR,
+ /* This is a 15 bit relative address. If the most significant bits are
+ all zero then it may be truncated to 8 bits. */
+ BFD_RELOC_S12Z_15_PCREL,
+
/* LARCH relocations. */
BFD_RELOC_LARCH_TLS_DTPMOD32,
BFD_RELOC_LARCH_TLS_DTPREL32,
diff --git a/bfd/libbfd.h b/bfd/libbfd.h
index d61e02a882c..ab131d3fb4e 100644
--- a/bfd/libbfd.h
+++ b/bfd/libbfd.h
@@ -2616,7 +2616,6 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_M68HC12_10_PCREL",
"BFD_RELOC_M68HC12_LO8XG",
"BFD_RELOC_M68HC12_HI8XG",
- "BFD_RELOC_S12Z_15_PCREL",
"BFD_RELOC_CR16_NUM8",
"BFD_RELOC_CR16_NUM16",
"BFD_RELOC_CR16_NUM32",
@@ -3382,6 +3381,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_CKCORE_PCREL_BLOOP_IMM4BY4",
"BFD_RELOC_CKCORE_PCREL_BLOOP_IMM12BY4",
"BFD_RELOC_S12Z_OPR",
+ "BFD_RELOC_S12Z_15_PCREL",
"BFD_RELOC_LARCH_TLS_DTPMOD32",
"BFD_RELOC_LARCH_TLS_DTPREL32",
"BFD_RELOC_LARCH_TLS_DTPMOD64",
diff --git a/bfd/reloc.c b/bfd/reloc.c
index 165060d96ce..8be035956b3 100644
--- a/bfd/reloc.c
+++ b/bfd/reloc.c
@@ -5592,12 +5592,6 @@ ENUMDOC
Motorola 68HC12/XGATE reloc.
This is the 8 bit high part of an absolute address and immediately
follows a matching LO8XG part.
-ENUM
- BFD_RELOC_S12Z_15_PCREL
-ENUMDOC
- Freescale S12Z reloc.
- This is a 15 bit relative address. If the most significant bits are
- all zero then it may be truncated to 8 bits.
ENUM
BFD_RELOC_CR16_NUM8
@@ -7768,7 +7762,12 @@ ENUMDOC
ENUM
BFD_RELOC_S12Z_OPR
ENUMDOC
- S12Z relocations.
+ Freescale S12Z relocations.
+ENUM
+ BFD_RELOC_S12Z_15_PCREL
+ENUMDOC
+ This is a 15 bit relative address. If the most significant bits are
+ all zero then it may be truncated to 8 bits.
ENUM
BFD_RELOC_LARCH_TLS_DTPMOD32
More information about the Binutils-cvs
mailing list