]> git.ipfire.org Git - thirdparty/binutils-gdb.git/log
thirdparty/binutils-gdb.git
3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 6 Jun 2022 00:00:52 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 5 Jun 2022 00:00:54 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 4 Jun 2022 00:00:58 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 3 Jun 2022 00:00:51 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 2 Jun 2022 00:01:08 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agox86: Properly handle IFUNC function pointer reference
H.J. Lu [Tue, 31 May 2022 22:38:19 +0000 (15:38 -0700)] 
x86: Properly handle IFUNC function pointer reference

Update

commit 68c4956b1401de70173848a6bdf620cb42fa9358
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Apr 26 09:08:54 2022 -0700

    x86: Properly handle function pointer reference

to properly handle IFUNC function pointer reference.  Since IFUNC symbol
value is only known at run-time, set pointer_equality_needed for IFUNC
function pointer reference in PDE so that it will be resolved to its PLT
entry directly.

bfd/

PR ld/29216
* elf32-i386.c (elf_i386_scan_relocs): Set pointer_equality_needed
for IFUNC function pointer reference in PDE.
* elf64-x86-64.c (elf_x86_64_scan_relocs): Likewise.

ld/

PR ld/29216
* testsuite/ld-ifunc/ifunc.exp: Run PR ld/29216 test.
* testsuite/ld-ifunc/pr29216.c: New file.

(cherry picked from commit 98a1627f19ca125476d5d58d9999c7a8d381f403)

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 1 Jun 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 31 May 2022 00:00:36 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 30 May 2022 00:00:47 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 29 May 2022 00:00:31 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 28 May 2022 00:00:51 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 27 May 2022 00:00:47 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 26 May 2022 00:00:41 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 25 May 2022 00:00:37 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 24 May 2022 00:00:49 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 23 May 2022 00:00:33 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 22 May 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 21 May 2022 00:01:05 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 20 May 2022 00:01:10 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAArch64: Enable FP16 by default for Armv9-A.
Tamar Christina [Wed, 18 May 2022 09:37:10 +0000 (10:37 +0100)] 
AArch64: Enable FP16 by default for Armv9-A.

In Armv9-A SVE is mandatory, and for SVE FP16 is mandatory.  This fixes a disconnect
between GCC and binutils where GCC has FP16 on by default and gas doesn't.

include/ChangeLog:

2022-05-16  Tamar Christina  <tamar.christina@arm.com>

* opcode/aarch64.h (AARCH64_ARCH_V9_FEATURES): Add AARCH64_FEATURE_F16.

(cherry picked from commit e1e15284481896505eab0cbc556f2348ef8fffbf)
Signed-off-by: Tamar Christina <tamar.christina@arm.com>
3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 19 May 2022 00:00:53 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 18 May 2022 00:00:59 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 17 May 2022 00:01:15 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 16 May 2022 00:01:08 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 15 May 2022 00:00:46 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 14 May 2022 00:00:55 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 13 May 2022 00:00:59 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoPR29142, segv in ar with empty archive and libdeps specified
Alan Modra [Thu, 12 May 2022 02:08:05 +0000 (11:38 +0930)] 
PR29142, segv in ar with empty archive and libdeps specified

PR 29142
* ar.c (main): Properly handle libdeps for zero file_count.

(cherry picked from commit fa445221958a9b8c8c4a804a339bc54cedfd83b9)

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 12 May 2022 00:00:47 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 11 May 2022 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 10 May 2022 00:00:56 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoM68K: avoid quadratic slowdlow in label alignment check
Sergei Trofimovich [Thu, 14 Apr 2022 07:47:00 +0000 (08:47 +0100)] 
M68K: avoid quadratic slowdlow in label alignment check

Before the change tc-m68k maintained a list of seen labels.
Alignment check traversed label list to resolve symbol to label.
This caused quadratic slowdown as each symbol was checked against
each label. Worst affected files are the ones built with debugging
enabled as DWARF generates many labels.

The change embeds auxiliary label information right into symbol using
TC_SYMFIELD_TYPE.

Before the change test from PR 29058 did not finish in 10 minutes. After
the change it finishes in 2 seconds.

gas/ChangeLog:

PR 29058
* config/tc-m68k.h (TC_SYMFIELD_TYPE): define as m68k_tc_sy.
* config/tc-m68k.c (m68k_frob_label): Use TC_SYMFIELD_TYPE to
store label information.

(cherry picked from commit c641fe0dcb886dc1b8a235ab2b236275ee46510a)

3 years agoAdjust ld ctf test for 32-bit targets
Alan Modra [Fri, 25 Feb 2022 06:55:26 +0000 (17:25 +1030)] 
Adjust ld ctf test for 32-bit targets

powerpc-linux, and I suspect other 32-bit targets, report "aligned at
0x4" for this test.

* testsuite/ld-ctf/nonrepresentable.d: Accept any alignment.

(cherry picked from commit db120fb808dc24538e89b851d6dda1890aad5a1f)

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 9 May 2022 00:00:45 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 8 May 2022 00:01:01 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 7 May 2022 00:00:45 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 6 May 2022 00:00:58 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 5 May 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 4 May 2022 00:00:52 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 3 May 2022 00:00:59 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 2 May 2022 00:00:37 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 1 May 2022 00:00:44 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 30 Apr 2022 00:00:42 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 29 Apr 2022 00:00:54 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agox86: Properly handle function pointer reference
H.J. Lu [Tue, 26 Apr 2022 16:08:54 +0000 (09:08 -0700)] 
x86: Properly handle function pointer reference

Update

commit ebb191adac4ab45498dec0bfaac62f0a33537ba4
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Feb 9 15:51:22 2022 -0800

    x86: Disallow invalid relocation against protected symbol

to allow function pointer reference and make sure that PLT entry isn't
used for function reference due to function pointer reference.

bfd/

PR ld/29087
* elf32-i386.c (elf_i386_scan_relocs): Don't set
pointer_equality_needed nor check non-canonical reference for
function pointer reference.
* elf64-x86-64.c (elf_x86_64_scan_relocs): Likewise.

ld/

PR ld/29087
* testsuite/ld-x86-64/x86-64.exp: Run PR ld/29087 tests.
* testsuite/ld-x86-64/protected-func-3.c: New file.

(cherry picked from commit 68c4956b1401de70173848a6bdf620cb42fa9358)

3 years agos390: Add DT_JMPREL pointing to .rela.[i]plt with static-pie
Stefan Liebler [Thu, 28 Apr 2022 12:30:55 +0000 (14:30 +0200)] 
s390: Add DT_JMPREL pointing to .rela.[i]plt with static-pie

In static-pie case, there are IRELATIVE-relocs in
.rela.iplt (htab->irelplt), which will later be grouped
to .rela.plt.  On s390, the IRELATIVE relocations are
always located in .rela.iplt - even for non-static case.
Ensure that DT_JMPREL, DT_PLTRELA, DT_PLTRELASZ is added
to the dynamic section even if htab->srelplt->size == 0.
See _bfd_elf_add_dynamic_tags in bfd/elflink.c.

bfd/
elf64-s390.c (elf_s390_size_dynamic_sections):
Enforce DT_JMPREL via htab->elf.dt_jmprel_required.

(cherry picked from commit d942d8db12adf4c9e5c7d9ed6496a779ece7149e)

3 years agos390: Avoid dynamic TLS relocs in PIE
Stefan Liebler [Thu, 28 Apr 2022 12:29:58 +0000 (14:29 +0200)] 
s390: Avoid dynamic TLS relocs in PIE

No dynamic relocs are needed for TLS defined in an executable, the
TP relative offset is known at link time.

Fixes
FAIL: Build pr22263-1

bfd/
PR ld/22263
* elf64-s390.c (elf_s390_tls_transition): Use bfd_link_dll
instead of bfd_link_pic for TLS.
(elf_s390_check_relocs): Likewise.
(allocate_dynrelocs): Likewise.
(elf_s390_relocate_section): Likewise.

(cherry picked from commit 26b1426577b5dcb32d149c64cca3e603b81948a9)

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 28 Apr 2022 00:00:51 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 27 Apr 2022 00:00:55 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 26 Apr 2022 00:00:50 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 25 Apr 2022 00:00:44 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 24 Apr 2022 00:00:34 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 23 Apr 2022 00:00:52 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 22 Apr 2022 00:00:51 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 21 Apr 2022 00:00:54 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 20 Apr 2022 00:01:10 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 19 Apr 2022 00:00:57 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 18 Apr 2022 00:00:56 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 17 Apr 2022 00:00:50 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 16 Apr 2022 00:00:50 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 15 Apr 2022 00:00:53 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 14 Apr 2022 00:01:03 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoLoongArch: Update ABI eflag in elf header.
Liuzhen Song [Wed, 13 Apr 2022 09:39:38 +0000 (10:39 +0100)] 
LoongArch: Update ABI eflag in elf header.

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 13 Apr 2022 00:00:45 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 12 Apr 2022 00:01:05 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 11 Apr 2022 00:00:36 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 10 Apr 2022 00:00:57 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 9 Apr 2022 00:00:48 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 8 Apr 2022 00:01:00 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoIBM zSystems: Add support for z16 as CPU name.
Andreas Krebbel [Thu, 7 Apr 2022 05:45:49 +0000 (07:45 +0200)] 
IBM zSystems: Add support for z16 as CPU name.

So far z16 was identified as arch14. After the machine has been
announced we can now add the real name.

(cherry picked from commit 69341966def7f6551bc4452684136831d6a6941c)

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 7 Apr 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 6 Apr 2022 00:00:47 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 5 Apr 2022 00:00:53 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 4 Apr 2022 00:00:32 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 3 Apr 2022 00:00:36 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 2 Apr 2022 00:00:53 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 1 Apr 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 31 Mar 2022 00:00:53 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 30 Mar 2022 00:00:42 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 29 Mar 2022 00:00:38 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 28 Mar 2022 00:00:40 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 27 Mar 2022 00:00:29 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 26 Mar 2022 00:00:48 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 25 Mar 2022 00:00:56 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agolibctf, ld: diagnose corrupted CTF header cth_strlen
Nick Alcock [Fri, 18 Mar 2022 00:49:11 +0000 (00:49 +0000)] 
libctf, ld: diagnose corrupted CTF header cth_strlen

The last section in a CTF dict is the string table, at an offset
represented by the cth_stroff header field.  Its length is recorded in
the next field, cth_strlen, and the two added together are taken as the
size of the CTF dict.  Upon opening a dict, we check that none of the
header offsets exceed this size, and we check when uncompressing a
compressed dict that the result of the uncompression is the same length:
but CTF dicts need not be compressed, and short ones are not.
Uncompressed dicts just use the ctf_size without checking it.  This
field is thankfully almost unused: it is mostly used when reserializing
a dict, which can't be done to dicts read off disk since they're
read-only.

However, when opening an uncompressed foreign-endian dict we have to
copy it out of the mmaped region it is stored in so we can endian-
swap it, and we use ctf_size when doing that.  When the cth_strlen is
corrupt, this can overrun.

Fix this by checking the ctf_size in all uncompressed cases, just as we
already do in the compressed case.  Add a new test.

This came to light because various corrupted-CTF raw-asm tests had an
incorrect cth_strlen: fix all of them so they produce the expected
error again.

libctf/
PR libctf/28933
* ctf-open.c (ctf_bufopen_internal): Always check uncompressed
CTF dict sizes against the section size in case the cth_strlen is
corrupt.

ld/
PR libctf/28933
* testsuite/ld-ctf/diag-strlen-invalid.*: New test,
derived from diag-cttname-invalid.s.
* testsuite/ld-ctf/diag-cttname-invalid.s: Fix incorrect cth_strlen.
* testsuite/ld-ctf/diag-cttname-null.s: Likewise.
* testsuite/ld-ctf/diag-cuname.s: Likewise.
* testsuite/ld-ctf/diag-parlabel.s: Likewise.
* testsuite/ld-ctf/diag-parname.s: Likewise.

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 24 Mar 2022 00:00:46 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agodlltool: Use the output name as basis for deterministic temp prefixes
Nick Clifton [Wed, 23 Mar 2022 11:39:49 +0000 (11:39 +0000)] 
dlltool: Use the output name as basis for deterministic temp prefixes

PR 28885
* dlltool.c (main): use imp_name rather than dll_name when
generating a temporary file name.

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 23 Mar 2022 00:00:44 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 22 Mar 2022 00:00:54 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 21 Mar 2022 00:00:34 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sun, 20 Mar 2022 00:00:44 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Sat, 19 Mar 2022 00:00:29 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Fri, 18 Mar 2022 00:00:50 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Thu, 17 Mar 2022 00:01:05 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoUpdated Serbian (for binutils/) and Russian (for gprof/) translations
Nick Clifton [Wed, 16 Mar 2022 12:48:55 +0000 (12:48 +0000)] 
Updated Serbian (for binutils/) and Russian (for gprof/) translations

3 years agoAutomatic date update in version.in
GDB Administrator [Wed, 16 Mar 2022 00:01:01 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Tue, 15 Mar 2022 00:01:11 +0000 (00:01 +0000)] 
Automatic date update in version.in

3 years agoAutomatic date update in version.in
GDB Administrator [Mon, 14 Mar 2022 00:00:43 +0000 (00:00 +0000)] 
Automatic date update in version.in

3 years agoPR28959, obdump doesn't disassemble mftb instruction
Alan Modra [Sun, 13 Mar 2022 12:24:25 +0000 (22:54 +1030)] 
PR28959, obdump doesn't disassemble mftb instruction

Without a -M cpu option given, powerpc objdump defaults currently to
-Mpower10 but -Many is also given.  Commit 1ff6a3b8e562 regressed
-Many disassembly of instructions that are encoded differently
depending on cpu, such as mftb which has pre- and post-power4
encodings.

PR 28959
* ppc-dis.c (lookup_powerpc): Revert 2021-05-28 change.  Instead
only look at deprecated PPC_OPCODE_RAW bit when -Many.

(cherry picked from commit b508e46bf9c5b2cef5821b399dfc3b8009a81836)

3 years agoPowerPC64 DT_RELR relative reloc addresses
Alan Modra [Wed, 2 Mar 2022 13:34:57 +0000 (00:04 +1030)] 
PowerPC64 DT_RELR relative reloc addresses

Section addresses can change between ppc64_elf_size_stubs and
ppc64_elf_build_stubs due to .eh_frame editing.  The idea of stashing
r_offset final addresses calculated in ppc64_elf_size_stubs for use by
ppc64_elf_build_stubs was never a good idea.  Instead, we need to keep
section/offset pairs.

* elf64-ppc.c (struct ppc_link_hash_table): Delete relr_addr.
Add relr section/offset array.
(append_relr_off): Rewrite.  Update all callers.
(sort_relr): New function.
(ppc64_elf_size_stubs): Adjust to suit new relative reloc stash.
(ppc64_elf_build_stubs): Likewise.

(cherry picked from commit 0aac2413d39d9f6d9e6879a0daa6bd5dea3e0fe3)
(cherry picked from commit e26ff4b5a90a67fc440052f6101464939347b1f2)