[PATCH] s390: Rewrite emitted relocations when rewriting instructions

Andreas Krebbel krebbel@linux.ibm.com
Mon Oct 13 11:27:39 GMT 2025


On 10/1/25 3:28 PM, Jens Remus wrote:
> bfd/
> 	* elf64-s390.c (elf_s390_relocate_section): Rewrite emitted
> 	relocations when rewriting instructions.
> 	* elf32-s390.c (elf_s390_relocate_section): Likewise.
>
> ld/testsuite/
> 	* ld-s390/s390.exp: Link gotreloc* and weakundef* tests with
> 	option --emit-relocs.
> 	* ld-s390/gotreloc_31-1.dd: Expect rewritten instructions to be
> 	accompanied by a PC32DBL or NONE relocation respectively.
> 	* ld-s390/gotreloc_31-no-pie-1.dd: Likewise.
> 	* ld-s390/gotreloc_64-no-pie-1.dd: Likewise.
> 	* ld-s390/gotreloc_64-norelro-1.dd: Likewise.
> 	* ld-s390/gotreloc_64-relro-1.dd: Likewise.
> 	* ld-s390/weakundef-1.dd: Likewise.
> 	* ld-s390/weakundef-2.dd: Likewise.

Good catch. Ok, thanks for fixing this!

Andreas




More information about the Binutils mailing list