aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/py-frame.c
diff options
context:
space:
mode:
authorJens Remus <jremus@linux.ibm.com>2025-10-16 11:09:06 +0200
committerJens Remus <jremus@linux.ibm.com>2025-10-16 11:09:06 +0200
commit5a7173cd46252fbbac5c7b30efebd2d66aad5eb3 (patch)
tree612a0abf2f00e70b0b884f682383255ad7f0c938 /gdb/python/py-frame.c
parentbedc0be59330aaef361387481a073a725830adab (diff)
downloadbinutils-5a7173cd46252fbbac5c7b30efebd2d66aad5eb3.zip
binutils-5a7173cd46252fbbac5c7b30efebd2d66aad5eb3.tar.gz
binutils-5a7173cd46252fbbac5c7b30efebd2d66aad5eb3.tar.bz2
s390: Do not rewrite insns and their relocs in linker if --no-relax
Under certain conditions the linker rewrites: - GOT access using lgrl to larl, changing the GOTENT to a PC32DBL reloc - GOT access using lg to larl, changing the GOT20 to a PC32DBL reloc - Relative long addressing instructions of weak symbols, which definitively resolve to zero to either (1) load address of zero, (2) a NOP, or (3) a trapping instruction, changing the relocation to a NONE reloc. Suppress rewriting of non-TLS instructions and related relocations in linker if option --no-relax is specified. This aligns with LLVM linker behavior on s390. Like x86-64 do not actually enable the linker relaxation option by default, as other targets would do using ENABLE_RELAXATION or TARGET_ENABLE_RELAXATION in their linker emulation scripts. Instead perform linker instruction/relocation rewrites by default unless linker option --no-relax is explicitly specified by the user. This ensures no functional change unless --no-relax is used. bfd/ * elf64-s390.c (elf_s390_relocate_section): Do not rewrite non-TLS instructions and related relocations if --no-relax. * elf32-s390.c (elf_s390_relocate_section): Likewise. ld/testsuite/ * ld-s390/s390.exp: New tests. Same as gotreloc_*-1a and weakundef-*a, but with linker option --no-relax, to verify suppression of linker non-TLS insn and reloc rewrites. * ld-s390/gotreloc_31-1b.dd: Likewise. * ld-s390/gotreloc_31-no-pie-1b.dd: Likewise. * ld-s390/gotreloc_64-no-pie-1b.dd: Likewise. * ld-s390/gotreloc_64-norelro-1b.dd: Likewise. * ld-s390/gotreloc_64-relro-1b.dd: Likewise. * ld-s390/weakundef-1b.d: Likewise. Check for expected reloc overflows. * ld-s390/weakundef-2b.d: Likewise. Signed-off-by: Jens Remus <jremus@linux.ibm.com>
Diffstat (limited to 'gdb/python/py-frame.c')
0 files changed, 0 insertions, 0 deletions