119530 Commits

Author SHA1 Message Date
Xi Ruoyao
a8563dba75 LoongArch: Fix broken DESC => IE transition for 2.43 branch
If code compiled with -fPIC -mtls-dialect=desc is linked into a PDE or
PIE, and the code refers to external DSO symbols, we can produce broken
link unit as check_relocs expects DESC => IE transition to happen and
emits a TLS IE entry in the GOT, but a too early "continue" in
relax_section actually jumps over the DESC => IE transition so the code
sequence is unchanged and still expecting a TLS descriptor (instead of
an IE entry) in the GOT.

The bug is already fixed in master branch by commit 5c3d09c1855b
("LoongArch: Optimize the relaxation process") so this fix is only
needed for the 2.43 branch.

Reported-by: Icenowy Zheng <uwu@icenowy.me>
Closes: https://gcc.gnu.org/PR118114
Tested-by: Icenowy Zheng <uwu@icenowy.me>
Signed-off-by: Xi Ruoyao <xry111@xry111.site>
2024-12-28 16:28:27 +08:00
GDB Administrator
e2d776f7b9 Automatic date update in version.in 2024-12-28 00:02:36 +00:00
GDB Administrator
0cdfcb9b8c Automatic date update in version.in 2024-12-27 00:02:07 +00:00
GDB Administrator
923497873f Automatic date update in version.in 2024-12-26 00:01:55 +00:00
GDB Administrator
551c1430e5 Automatic date update in version.in 2024-12-25 00:00:52 +00:00
GDB Administrator
b194ae062e Automatic date update in version.in 2024-12-24 00:00:58 +00:00
GDB Administrator
33990e5ced Automatic date update in version.in 2024-12-23 00:01:14 +00:00
GDB Administrator
fdef3910ed Automatic date update in version.in 2024-12-22 00:00:48 +00:00
GDB Administrator
44da930420 Automatic date update in version.in 2024-12-21 00:01:50 +00:00
GDB Administrator
8f2c68b59c Automatic date update in version.in 2024-12-20 00:01:58 +00:00
Jan Beulich
808a2dae2f x86-64: correct CODE_5 relocs
Two of them had their numbers swapped; luckily they aren't really in use
just yet. Correct indentation as well while at it.
2024-12-19 10:41:20 +01:00
GDB Administrator
1ec1931df8 Automatic date update in version.in 2024-12-19 00:02:45 +00:00
GDB Administrator
5a912df92d Automatic date update in version.in 2024-12-18 00:01:11 +00:00
Nick Clifton
5f8987d399 nm: Avoid potential segmentation fault when displaying symbols without version info.
PR 32467
2024-12-17 09:18:57 +00:00
GDB Administrator
36a68f94e5 Automatic date update in version.in 2024-12-17 00:02:22 +00:00
GDB Administrator
b6da720d9f Automatic date update in version.in 2024-12-16 00:01:49 +00:00
GDB Administrator
e2622c0a84 Automatic date update in version.in 2024-12-15 00:00:57 +00:00
GDB Administrator
bcf18c37bf Automatic date update in version.in 2024-12-14 00:01:50 +00:00
GDB Administrator
834b779ad2 Automatic date update in version.in 2024-12-13 00:01:10 +00:00
GDB Administrator
469cb3e5e6 Automatic date update in version.in 2024-12-12 00:01:16 +00:00
GDB Administrator
30cc652cd5 Automatic date update in version.in 2024-12-11 00:02:20 +00:00
GDB Administrator
b1a59f5d69 Automatic date update in version.in 2024-12-10 00:00:44 +00:00
GDB Administrator
2c9f7154ba Automatic date update in version.in 2024-12-09 00:01:44 +00:00
GDB Administrator
f4db8582fa Automatic date update in version.in 2024-12-08 00:00:58 +00:00
GDB Administrator
b4e222dd8d Automatic date update in version.in 2024-12-07 00:00:48 +00:00
GDB Administrator
ca82d88556 Automatic date update in version.in 2024-12-06 00:00:48 +00:00
GDB Administrator
37a4f5ae09 Automatic date update in version.in 2024-12-05 00:00:55 +00:00
GDB Administrator
5348e2a9c9 Automatic date update in version.in 2024-12-04 00:01:15 +00:00
GDB Administrator
05763fb0af Automatic date update in version.in 2024-12-03 00:00:57 +00:00
GDB Administrator
ff69fa7c0a Automatic date update in version.in 2024-12-02 00:01:36 +00:00
GDB Administrator
9263a7409a Automatic date update in version.in 2024-12-01 00:03:07 +00:00
GDB Administrator
70d3c8d023 Automatic date update in version.in 2024-11-30 00:01:27 +00:00
GDB Administrator
37057ea0fa Automatic date update in version.in 2024-11-29 00:00:33 +00:00
GDB Administrator
5ac471bc08 Automatic date update in version.in 2024-11-28 00:02:20 +00:00
Alan Modra
46873460b6 PR32387 ppc64 TLS optimization bug with -fno-plt code
The inline plt code emitted by gcc is incompatible with the
linker/ld.so --tls-get-addr-optimize scheme.  This is the runtime
optimisation where the first call to __tls_get_addr results in
__tls_get_addr updating the tls_index pair, then the special linker
stub using that to short-circuit second and subsequent calls for a
given tls symbol.  Enabled by default when the linker sees
__tls_get_addr_opt is preseent, and enabled in ld.so when DT_PPC64_OPT
has PPC64_OPT_TLS set.  Note that this is distinct from link-time tls
optimisation.

	PR 32387
	* elf64-ppc.c (ppc64_elf_check_relocs): Disable tls_get_addr_opt
	on detecting inline plt calls to __tls_get_addr.

(cherry picked from commit 1686dc7079f1c03bdaffd2f779b92aa2b7ad97b5)
2024-11-27 20:54:25 +10:30
GDB Administrator
2a0332b1d2 Automatic date update in version.in 2024-11-27 00:03:11 +00:00
GDB Administrator
bf181a1d7a Automatic date update in version.in 2024-11-26 00:03:39 +00:00
GDB Administrator
c365a127b2 Automatic date update in version.in 2024-11-25 00:03:44 +00:00
GDB Administrator
55d152f1f4 Automatic date update in version.in 2024-11-24 00:03:58 +00:00
GDB Administrator
785a1aaba1 Automatic date update in version.in 2024-11-23 00:03:25 +00:00
GDB Administrator
119b9da32c Automatic date update in version.in 2024-11-22 00:03:21 +00:00
GDB Administrator
78336e2592 Automatic date update in version.in 2024-11-21 00:02:39 +00:00
GDB Administrator
4dbf0681c9 Automatic date update in version.in 2024-11-20 00:02:11 +00:00
Sam James
059f365433
ld: fix -std=gnu23 compatibility wrt _Bool
GCC trunk now defaults to -std=gnu23. We return false in a few places
which can't work when true/false are a proper type (_Bool). Return NULL
where appropriate instead of false. All callers handle this appropriately.

ChangeLog:
	PR ld/32372

	* pdb.c (add_stream): Return NULL.

(cherry picked from commit bf447eec6d7b69cba652127e2f38f102de38de39)
2024-11-19 06:41:06 +00:00
Sam James
74401db8de
binutils: fix -std=gnu23 compatibility wrt _Bool
GCC trunk now defaults to -std=gnu23. We return false in a few places
which can't work when true/false are a proper type (_Bool). Return NULL
where appropriate instead of false. All callers handle this appropriately.

ChangeLog:
	PR ld/32372

	* prdbg.c (visibility_name): Return NULL.

(cherry picked from commit eeff15bc88b89abed1cdb4d3b1b2cc7b4cec6fe7)
2024-11-19 06:40:54 +00:00
Sam James
3a88870559
opcodes: fix -std=gnu23 compatibility wrt static_assert
static_assert is declared in C23 so we can't reuse that identifier:
* Define our own static_assert conditionally;

* Rename "static assert" hacks to _N as we do already in some places
  to avoid a conflict.

ChangeLog:
	PR ld/32372

        * i386-gen.c (static_assert): Define conditionally.
        * mips-formats.h (MAPPED_INT): Rename identifier.
        (MAPPED_REG): Rename identifier.
        (OPTIONAL_MAPPED_REG): Rename identifier.
        * s390-opc.c (static_assert): Define conditionally.

(cherry picked from commit 8ebe62f3f0d27806b1bf69f301f5e188b4acd2b4)
2024-11-19 06:40:43 +00:00
Sam James
cf23d68350
bfd: fix -std=gnu23 compatibility wrt _Bool
GCC trunk now defaults to -std=gnu23. We return false in a few places
which can't work when true/false are a proper type (_Bool). Return NULL
where appropriate instead of false. All callers handle this appropriately.

ChangeLog:
	PR ld/32372

	* elf32-ppc.c (ppc_elf_tls_setup): Return NULL.
        * elf32-xtensa.c (translate_reloc_bfd_fix): Ditto.
        (translate_reloc): Ditto.
        * elf64-ppc.c (update_local_sym_info): Ditto.
        * mach-o.c (bfd_mach_o_lookup_uuid_command): Ditto.
        * xsym.c (bfd_sym_read_name_table): Ditto.

(cherry picked from commit 931e4f9b09512bb9012204bb2e4060ab6d9b9b46)
2024-11-19 06:40:35 +00:00
GDB Administrator
c6782bf043 Automatic date update in version.in 2024-11-19 00:02:24 +00:00
Jens Remus
d607533365 s390: Add arch15 Concurrent-Functions Facility insns
opcodes/
	* s390-opc.txt: Add arch15 Concurrent-Functions Facility
	instructions.
	* s390-opc.c (INSTR_SSF_RRDRD2, MASK_SSF_RRDRD2): New SSF
	instruction format variant.

gas/testsuite/
	* gas/s390/zarch-arch15.d: Tests for arch15 Concurrent-Functions
	Facility instructions.
	* gas/s390/zarch-arch15.s: Likewise.

Signed-off-by: Jens Remus <jremus@linux.ibm.com>
(cherry picked from commit 76445f36a2f9e41b1744d0327e7ec243cb7fac12)
2024-11-18 11:05:32 +01:00
Jens Remus
0b9975f647 s390: Add arch15 instruction names
opcodes/
	* s390-opc.txt: Add arch15 instruction names.

Signed-off-by: Jens Remus <jremus@linux.ibm.com>
(cherry picked from commit b0588b2173bf9aeff9eadc0cc024c4c69e69114d)
2024-11-18 11:05:27 +01:00