]> git.ipfire.org Git - thirdparty/binutils-gdb.git/log
thirdparty/binutils-gdb.git
16 months agoAutomatic date update in version.in
GDB Administrator [Thu, 28 Mar 2024 00:03:27 +0000 (00:03 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Wed, 27 Mar 2024 00:02:57 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Tue, 26 Mar 2024 00:02:44 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Mon, 25 Mar 2024 00:01:59 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sun, 24 Mar 2024 00:02:07 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sat, 23 Mar 2024 00:02:02 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Fri, 22 Mar 2024 00:01:44 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Thu, 21 Mar 2024 00:03:33 +0000 (00:03 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Wed, 20 Mar 2024 00:02:39 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Tue, 19 Mar 2024 00:01:57 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Mon, 18 Mar 2024 00:02:28 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sun, 17 Mar 2024 00:00:57 +0000 (00:00 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sat, 16 Mar 2024 00:01:09 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Fri, 15 Mar 2024 00:01:16 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoaarch64: Remove B16B16, SVE2p1 and SME2p1
Andrew Carlotti [Tue, 27 Feb 2024 19:41:29 +0000 (19:41 +0000)] 
aarch64: Remove B16B16, SVE2p1 and SME2p1

Support for these extensions is broken and incomplete in the 2.42
branch, with a number of syntax and opcode bugs.  This patch removes the
flags and documentation, to avoid any further suggestion that this
extension is fully and correctly supported.

16 months agoAutomatic date update in version.in
GDB Administrator [Thu, 14 Mar 2024 00:02:56 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Wed, 13 Mar 2024 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Tue, 12 Mar 2024 00:02:53 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Mon, 11 Mar 2024 00:01:56 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sun, 10 Mar 2024 00:01:16 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoRe: Move bfd_init to bfd.c
Alan Modra [Sat, 9 Mar 2024 09:18:48 +0000 (19:48 +1030)] 
Re: Move bfd_init to bfd.c

Commit b1c95bc4dd73 cleared some bfd static variables, with bad
results since bfd_set_error_program_name is often called before
bfd_init.

* bfd.c (bfd_init): Don't clear _bfd_error_program_name.

(cherry picked from commit 0c947d990a92fd48ac0aa887df7e1e055fa0d680)

16 months agoprint cached error messages using _bfd_error_handler
Alan Modra [Sat, 9 Mar 2024 02:56:19 +0000 (13:26 +1030)] 
print cached error messages using _bfd_error_handler

* format.c (print_warnmsg): Use _bfd_error_handler to print
cached messages.

(cherry picked from commit bd8d76258f86f93b20e6bd94f58033a49eb0d3ec)

16 months agoAutomatic date update in version.in
GDB Administrator [Sat, 9 Mar 2024 00:01:04 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Fri, 8 Mar 2024 00:01:04 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Thu, 7 Mar 2024 00:02:38 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Wed, 6 Mar 2024 00:03:15 +0000 (00:03 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Tue, 5 Mar 2024 00:01:49 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Mon, 4 Mar 2024 00:02:26 +0000 (00:02 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sun, 3 Mar 2024 00:01:49 +0000 (00:01 +0000)] 
Automatic date update in version.in

16 months agoAutomatic date update in version.in
GDB Administrator [Sat, 2 Mar 2024 00:01:03 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Fri, 1 Mar 2024 00:02:06 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoaarch64: Fix the 2nd operand in gcsstr and gcssttr instructions.
Srinath Parvathaneni [Thu, 29 Feb 2024 21:06:25 +0000 (21:06 +0000)] 
aarch64: Fix the 2nd operand in gcsstr and gcssttr instructions.

The assembler wrongly expects plain register name instead of
memory-form 2nd operand for gcsstr and gcssttr instructions.
This patch fixes the issue.

17 months agoAutomatic date update in version.in
GDB Administrator [Thu, 29 Feb 2024 00:02:11 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Wed, 28 Feb 2024 00:01:30 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Tue, 27 Feb 2024 00:01:53 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Mon, 26 Feb 2024 00:01:44 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sun, 25 Feb 2024 00:02:22 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sat, 24 Feb 2024 00:01:32 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Fri, 23 Feb 2024 00:02:01 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Thu, 22 Feb 2024 00:01:53 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Wed, 21 Feb 2024 00:01:41 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Tue, 20 Feb 2024 00:01:09 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Mon, 19 Feb 2024 00:01:30 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sun, 18 Feb 2024 00:00:45 +0000 (00:00 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sat, 17 Feb 2024 00:01:08 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agox86: Display -msse-check= default as none
H.J. Lu [Thu, 15 Feb 2024 23:00:31 +0000 (15:00 -0800)] 
x86: Display -msse-check= default as none

Display -msse-check= default as none for "as --help" since its default
is none, not warning.

PR gas/31389
* config/tc-i386.c (md_show_usage): Change -msse-check= default
to none.

(cherry picked from commit 7a6a03c499ad899c1d1dd93beccbb62795feb1db)

17 months agoAutomatic date update in version.in
GDB Administrator [Fri, 16 Feb 2024 00:00:49 +0000 (00:00 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Thu, 15 Feb 2024 00:01:40 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Wed, 14 Feb 2024 00:01:19 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoPowerPC: Add support for Power11 options
Peter Bergner [Fri, 9 Feb 2024 16:51:30 +0000 (10:51 -0600)] 
PowerPC: Add support for Power11 options

binutils/
* doc/binutils.texi (PowerPC -M option): Mention power11 and pwr11.

gas/
* config/tc-ppc.c: (md_show_usage): Mention -mpower11 and -mpwr11.
* doc/c-ppc.texi: Likewise.

opcodes/
* ppc-dis.c (ppc_opts): Add "power11" and "pwr11" entries.
(powerpc_init_dialect): Default to "power11".

(cherry picked from commit 4199cf1e152daab0460f08cc7dbd1f727ac3e4cc)

17 months agoAutomatic date update in version.in
GDB Administrator [Tue, 13 Feb 2024 00:01:27 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Mon, 12 Feb 2024 00:01:04 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sun, 11 Feb 2024 00:00:47 +0000 (00:00 +0000)] 
Automatic date update in version.in

17 months agox86-64: Add R_X86_64_CODE_6_GOTTPOFF
H.J. Lu [Sat, 3 Feb 2024 22:32:17 +0000 (14:32 -0800)] 
x86-64: Add R_X86_64_CODE_6_GOTTPOFF

For

add %reg1, name@gottpoff(%rip), %reg2

and

add name@gottpoff(%rip), %reg1, %reg2

add

 #define R_X86_64_CODE_6_GOTTPOFF 50

if the instruction starts at 6 bytes before the relocation offset.
They are similar to R_X86_64_GOTTPOFF.  Linker can covert GOTTPOFF to

add $name@tpoff, %reg1, %reg2

Rewrite fx_tcbit, fx_tcbit2 and fx_tcbit3 usage to generate
R_X86_64_GOTPCRELX, R_X86_64_REX_GOTPCRELX, R_X86_64_CODE_4_GOTPCRELX,
R_X86_64_CODE_4_GOTTPOFF, R_X86_64_CODE_4_GOTPC32_TLSDESC and
R_X86_64_CODE_6_GOTTPOFF.

NB: There is no need to check BFD_RELOC_X86_64_CODE_4_GOTTPOFF in
md_assemble since there is only BFD_RELOC_X86_64_GOTTPOFF at this
stage, which will be converted to BFD_RELOC_X86_64_CODE_4_GOTTPOFF
or BFD_RELOC_X86_64_CODE_6_GOTTPOFF in i386_validate_fix.

5 relocations:

 #define R_X86_64_CODE_5_GOTPCRELX 46
 #define R_X86_64_CODE_5_GOTTPOFF 47
 #define R_X86_64_CODE_5_GOTPC32_TLSDESC 48
 #define R_X86_64_CODE_6_GOTPCRELX 49
 #define R_X86_64_CODE_6_GOTPC32_TLSDESC 51

are added for completeness and they are unused.

bfd/

* elf64-x86-64.c (x86_64_elf_howto_table): Add
R_X86_64_CODE_5_GOTPCRELX, R_X86_64_CODE_5_GOTTPOFF,
R_X86_64_CODE_5_GOTPC32_TLSDESC, R_X86_64_CODE_6_GOTPCRELX,
R_X86_64_CODE_6_GOTTPOFF and R_X86_64_CODE_6_GOTPC32_TLSDESC.
(R_X86_64_standard): Updated.
(x86_64_reloc_map): Add R_X86_64_CODE_5_GOTPCRELX,
R_X86_64_CODE_5_GOTTPOFF, R_X86_64_CODE_5_GOTPC32_TLSDESC,
R_X86_64_CODE_6_GOTPCRELX, R_X86_64_CODE_6_GOTTPOFF and
R_X86_64_CODE_6_GOTPC32_TLSDESC.
(elf_x86_64_check_tls_transition): Handle
R_X86_64_CODE_6_GOTTPOFF.
(elf_x86_64_tls_transition): Likewise.
(elf_x86_64_scan_relocs): Handle R_X86_64_CODE_6_GOTTPOFF.
Issue an error for R_X86_64_CODE_5_GOTPCRELX,
R_X86_64_CODE_5_GOTTPOFF, R_X86_64_CODE_5_GOTPC32_TLSDESC,
R_X86_64_CODE_6_GOTPCRELX and R_X86_64_CODE_6_GOTPC32_TLSDESC.
(elf_x86_64_relocate_section): Handle R_X86_64_CODE_6_GOTTPOFF.
* reloc.c (bfd_reloc_code_real): Add
BFD_RELOC_X86_64_CODE_5_GOTPCRELX,
BFD_RELOC_X86_64_CODE_5_GOTTPOFF,
BFD_RELOC_X86_64_CODE_5_GOTPC32_TLSDESC,
BFD_RELOC_X86_64_CODE_6_GOTPCRELX,
BFD_RELOC_X86_64_CODE_6_GOTTPOFF and
BFD_RELOC_X86_64_CODE_6_GOTPC32_TLSDESC.
* bfd-in2.h: Regenerated.
* libbfd.h: Likewise.

elfcpp/

* x86_64.h (R_X86_64_CODE_5_GOTPCRELX): New.
(R_X86_64_CODE_5_GOTTPOFF): Likewise.
(R_X86_64_CODE_5_GOTPC32_TLSDESC): Likewise.
(R_X86_64_CODE_6_GOTPCRELX): Likewise.
(R_X86_64_CODE_6_GOTTPOFF): Likewise.
(R_X86_64_CODE_6_GOTPC32_TLSDESC): Likewise.

gas/

* config/tc-i386.c (tc_i386_fix_adjustable): Handle
BFD_RELOC_X86_64_CODE_6_GOTTPOFF.
(md_assemble): Don't check BFD_RELOC_X86_64_CODE_4_GOTTPOFF.
Allow "add %reg1, foo@gottpoff(%rip), %reg2".
(output_disp): Handle BFD_RELOC_X86_64_CODE_6_GOTTPOFF.  Rewrite
setting fx_tcbitX bits for BFD_RELOC_X86_64_GOTTPOFF,
BFD_RELOC_X86_64_GOTPC32_TLSDESC and BFD_RELOC_32_PCREL.
(md_apply_fix): Handle BFD_RELOC_X86_64_CODE_6_GOTTPOFF.
(i386_validate_fix): Rewrite fx_tcbitX bit checking for
BFD_RELOC_X86_64_GOTTPOFF, BFD_RELOC_X86_64_GOTPC32_TLSDESC and
BFD_RELOC_32_PCREL.
(tc_gen_reloc): Handle BFD_RELOC_X86_64_CODE_6_GOTTPOFF.
* testsuite/gas/i386/x86-64-gottpoff.d: Updated.
* testsuite/gas/i386/x86-64-gottpoff.s: Add tests for
"add %reg1, foo@gottpoff(%rip), %reg2" and
"add foo@gottpoff(%rip), %reg, %reg2".

gold/

* x86_64.cc (Target_x86_64::optimize_tls_reloc): Handle
R_X86_64_CODE_6_GOTTPOFF.
(Target_x86_64::Scan::get_reference_flags): Likewise.
(Target_x86_64::Scan::local): Likewise.
(Target_x86_64::Scan::global): Likewise.
(Target_x86_64::Relocate::relocate): Likewise.
(Target_x86_64::Relocate::relocate_tls): Likewise.
(Target_x86_64::Relocate::tls_ie_to_le): Handle.
R_X86_64_CODE_6_GOTTPOFF.
* testsuite/x86_64_ie_to_le.s: Add tests for
"add %reg1, foo@gottpoff(%rip), %reg2" and
"add foo@gottpoff(%rip), %reg, %reg2".
* testsuite/x86_64_ie_to_le.sh: Updated.

include/

* elf/x86-64.h (elf_x86_64_reloc_type): Add
R_X86_64_CODE_5_GOTPCRELX, R_X86_64_CODE_5_GOTTPOFF,
R_X86_64_CODE_5_GOTPC32_TLSDESC, R_X86_64_CODE_6_GOTPCRELX,
R_X86_64_CODE_6_GOTTPOFF and R_X86_64_CODE_6_GOTPC32_TLSDESC.

ld/

* testsuite/ld-x86-64/tlsbindesc.s: Add R_X86_64_CODE_6_GOTTPOFF
tests.
* testsuite/ld-x86-64/tlsbindesc.d: Updated.
* testsuite/ld-x86-64/tlsbindesc.rd: Likewise.

(cherry picked from commit 5bc71c2a6b8efb27089baa1fecded82be4f550a7)

17 months agoAutomatic date update in version.in
GDB Administrator [Sat, 10 Feb 2024 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agox86/APX: VROUND{P,S}{S,D} encodings require AVX512{F,VL}
Jan Beulich [Fri, 9 Feb 2024 07:38:52 +0000 (08:38 +0100)] 
x86/APX: VROUND{P,S}{S,D} encodings require AVX512{F,VL}

In eea4357967b6 ("x86/APX: VROUND{P,S}{S,D} can generally be encoded") I
failed to add the AVX512* ISA dependency of the two new entries.

17 months agoAutomatic date update in version.in
GDB Administrator [Fri, 9 Feb 2024 00:00:44 +0000 (00:00 +0000)] 
Automatic date update in version.in

17 months agoPR31208, strip can break ELF alignment requirements
Alan Modra [Thu, 8 Feb 2024 20:34:22 +0000 (07:04 +1030)] 
PR31208, strip can break ELF alignment requirements

In https://sourceware.org/pipermail/binutils/2007-August/053261.html
(git commit 3dea8fca8b86) I disabled a then new linker feature that
removed empty PT_LOAD headers in cases where a user specified program
headers, and for objcopy.  This can be a problem for objcopy/strip and
since objcopy operates on sections, any part of a PT_LOAD loading file
contents not covered by a section will be omitted anyway.

PR 31208
* elf.c (_bfd_elf_map_sections_to_segments): Pass remove_empty_load
as true to elf_modify_segment_map for objcopy/strip.

(cherry picked from commit 7f26d260ef76a4cb2873a7815bef187005528c19)

17 months agoPR 31283 windmc: Parse input correctly on big endian hosts
Richard W.M. Jones [Wed, 24 Jan 2024 12:25:23 +0000 (12:25 +0000)] 
PR 31283 windmc: Parse input correctly on big endian hosts

On big endian hosts (eg. s390x) the windmc tool fails to parse even
trivial files:

  $ cat test.mc
  ;
  $ ./binutils/windmc ./test.mc
  In test.mc at line 1: parser: syntax error.
  In test.mc at line 1: fatal: syntax error.

The tool starts by reading the input as Windows CP1252 and then
converting it internally into an array of UTF-16LE, which it then
processes as an array of unsigned short (typedef unichar).

There are lots of ways this is wrong, but in the specific case of big
endian machines the little endian pairs of bytes are byte-swapped.

For example, the ';' character in the input above is first converted
to UTF16-LE byte sequence { 0x3b, 0x00 }, which is then cast to
unsigned short.  On a big endian machine the first unichar appears to
be 0x3b00.  The lexer is unable to recognize this as the comment
character ((unichar)';') and so parsing fails.

The simple fix is to convert the input to UTF-16BE on big endian
machines (and do the reverse conversion when writing the output).

Fixes: https://sourceware.org/bugzilla/show_bug.cgi?id=31283
Signed-off-by: Richard W.M. Jones <rjones@redhat.com>
(cherry picked from commit 3f8f9745c75b333515f399fc2908ede2ed8014e9)

17 months agoAutomatic date update in version.in
GDB Administrator [Thu, 8 Feb 2024 00:02:08 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Wed, 7 Feb 2024 00:02:09 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoLink x86-64 mark-plt-1.so with --no-as-needed
Alan Modra [Tue, 6 Feb 2024 02:29:06 +0000 (12:59 +1030)] 
Link x86-64 mark-plt-1.so with --no-as-needed

Fixes
FAIL: Build mark-plt-1.so
where gcc is built with default --as-needed.

* testsuite/ld-x86-64/x86-64.exp (Build mark-plt-1.so): Pass
--no-as-needed.

(cherry picked from commit 60c95acdaca94eca79b81ec75bfab97826cc0271)

17 months agoAutomatic date update in version.in
GDB Administrator [Tue, 6 Feb 2024 00:02:18 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Mon, 5 Feb 2024 00:01:19 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoLoongArch: gas: Fix the types of symbols referred with %le_*_r in the symtab
Xi Ruoyao [Fri, 2 Feb 2024 13:00:58 +0000 (21:00 +0800)] 
LoongArch: gas: Fix the types of symbols referred with %le_*_r in the symtab

When a symbol is referred with %le_{hi20,lo12,add}_r, it's definitely a
TLS symbol and we should set its type to TLS in the symtab.  Otherwise
when building Perl with gcc-14 -flto, we get:

/usr/bin/ld: PL_current_context: TLS definition in
./miniperl.ltrans0.ltrans.o section .tbss mismatches non-TLS reference
in ./miniperl.ltrans1.ltrans.o

A minimal reproducer:

    $ cat t1.s
    .section .tbss
    .globl x
    x: .word 0
    $ cat t2.s
    f:
      lu12i.w $a0, %le_hi20_r(x)
      add.d   $a0, $a0, $tp, %le_add_r(x)
      li.w    $a1, 1
      st.w    $a1, $a0, %le_lo12_r(x)
    $ gas/as-new t1.s -o t1.o
    $ gas/as-new t2.s -o t2.o
    $ ld/ld-new t1.o t2.o
    ld/ld-new: x: TLS definition in t1.o section .tbss mismatches
    non-TLS reference in t2.o

Unfortunately this was undetected before Binutils-2.42 release because
GCC < 14 does not use %le_*_r, and without LTO it's very rare to have a
TLS LE definition and its reference in two different translation units.
So this fix should be backported to Binutils-2.42 branch too.

Signed-off-by: Xi Ruoyao <xry111@xry111.site>
(cherry picked from commit 029e52bac7f3a6dd8b39f7f3d298b73174da806b)

17 months agoAutomatic date update in version.in
GDB Administrator [Sun, 4 Feb 2024 00:02:12 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Sat, 3 Feb 2024 00:01:07 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agox86: Disallow instructions with length > 15 bytes
H.J. Lu [Thu, 1 Feb 2024 22:42:08 +0000 (14:42 -0800)] 
x86: Disallow instructions with length > 15 bytes

It is a hard error when an instruction length exceeds the limit of 15
bytes:

[hjl@gnu-cfl-3 tmp]$ cat x.s
.text
xacquire lock addq $0x11223344, %fs:(,%eax)
[hjl@gnu-cfl-3 tmp]$ gcc -c x.s
x.s: Assembler messages:
x.s:2: Warning: instruction length of 16 bytes exceeds the limit of 15
[hjl@gnu-cfl-3 tmp]$ objdump -dw x.o

x.o:     file format elf64-x86-64

Disassembly of section .text:

0000000000000000 <.text>:
   0: 64 67 f2 f0 48 81 04 05 00 00 00 00 44 33 22  xacquire lock (bad)
   f: 11                    .byte 0x11
[hjl@gnu-cfl-3 tmp]$

and

[hjl@gnu-cfl-3 tmp]$ cat z.s
addq $0xe0, %fs:0, %rdx
[hjl@gnu-cfl-3 tmp]$ as -o z.o z.s
z.s: Assembler messages:
z.s:1: Warning: instruction length of 16 bytes exceeds the limit of 15
[hjl@gnu-cfl-3 tmp]$ objdump -dw z.o

z.o:     file format elf64-x86-64

Disassembly of section .text:

0000000000000000 <.text>:
   0: 64 62 f4 ec 18 81 04 25 00 00 00 00 e0 00 00  (bad)
...
[hjl@gnu-cfl-3 pr31323]$

Instructions with length > 15 bytes are always invalid.  It is quite easy
to generate invalid instructions with APX now.  We should issue an error
when instruction length exceeds the limit of 15 bytes.

PR gas/31323
* config/tc-i386.c (output_insn): Issue an error when instruction
length exceeds the limit of 15 bytes.
* testsuite/gas/i386/oversized16.l: Updated.
* testsuite/gas/i386/oversized64.l: Likewise.
* testsuite/gas/i386/x86-64-apx-inval.l: New file.
* testsuite/gas/i386/x86-64-apx-inval.s: Likewise.

(cherry picked from commit 46bd909328c3c8f3d6fc7a505b2fad1eea72d872)

17 months agoAutomatic date update in version.in
GDB Administrator [Fri, 2 Feb 2024 00:01:45 +0000 (00:01 +0000)] 
Automatic date update in version.in

17 months agoAutomatic date update in version.in
GDB Administrator [Thu, 1 Feb 2024 00:02:02 +0000 (00:02 +0000)] 
Automatic date update in version.in

17 months agoMention support for AMD/znver5 in GAS
Nick Clifton [Wed, 31 Jan 2024 15:42:14 +0000 (15:42 +0000)] 
Mention support for AMD/znver5 in GAS

17 months agoPR31124: Addendum: Remove PROVIDE of __flmap_init_label, __flmap.
Georg-Johann Lay [Wed, 31 Jan 2024 11:24:22 +0000 (11:24 +0000)] 
PR31124: Addendum: Remove PROVIDE of __flmap_init_label, __flmap.

Supply these symbols as computed by the linker scripts, even when there are weak definitions.
PR 31124
    * scripttempl/avr.sc (__flmap, __flmap_init_label): Remove PROVIDE.

18 months agoAutomatic date update in version.in
GDB Administrator [Wed, 31 Jan 2024 00:02:39 +0000 (00:02 +0000)] 
Automatic date update in version.in

18 months agogas: scfi: add missing ginsn-cofi-1 testcase files
Indu Bhagat [Tue, 30 Jan 2024 08:35:04 +0000 (00:35 -0800)] 
gas: scfi: add missing ginsn-cofi-1 testcase files

Previous commit a58dc5427f0 intended to bring the following two commits
from master branch:

 91cdbed4d7b gas: scfi: untraceable control flow should be a hard error
 16cbeae1b27 x86: testsuite: scfi: adjust COFI testcase

But missed adding the testcase files. Fix the failure by adding the
missing files.

gas/testsuite/
* gas/scfi/x86_64/ginsn-cofi-1.l: New test.
* gas/scfi/x86_64/ginsn-cofi-1.s: Likewise.

18 months agoAutomatic date update in version.in
GDB Administrator [Tue, 30 Jan 2024 00:02:25 +0000 (00:02 +0000)] 
Automatic date update in version.in

18 months agoPR31314, chew crashing on use of uninitialized value
Alan Modra [Mon, 29 Jan 2024 23:08:56 +0000 (09:38 +1030)] 
PR31314, chew crashing on use of uninitialized value

The "drop" call in wrap_comment already increments pc.  Defining DOCDD
in proto.str is a warning fix.

PR 31314
* chew.c (wrap_comment): Don't increment pc.
* proto.str (DOCDD): Define.

(cherry picked from commit e175a2fc60cb9709c4461cdd8596ae05e529d67b)

18 months agoSet version number to 2.42.0 and re-enable development
Nick Clifton [Mon, 29 Jan 2024 16:01:42 +0000 (16:01 +0000)] 
Set version number to 2.42.0 and re-enable development

18 months agoUpdate version number to 2.42 binutils-2_42
Nick Clifton [Mon, 29 Jan 2024 14:51:43 +0000 (14:51 +0000)] 
Update version number to 2.42

18 months agox86: testsuite: scfi: adjust COFI testcase and gas: scfi: untraceable control flow...
Indu Bhagat [Mon, 29 Jan 2024 14:22:06 +0000 (14:22 +0000)] 
x86: testsuite: scfi: adjust COFI testcase and  gas: scfi: untraceable control flow should be a hard error

18 months agoUpdated French translations for GOLD and LD
Nick Clifton [Mon, 29 Jan 2024 11:31:52 +0000 (11:31 +0000)] 
Updated French translations for GOLD and LD

18 months agoLoongArch: update test cases about TLS
Nick Clifton [Mon, 29 Jan 2024 11:22:39 +0000 (11:22 +0000)] 
LoongArch: update test cases about TLS

18 months agoAutomatic date update in version.in
GDB Administrator [Mon, 29 Jan 2024 00:01:47 +0000 (00:01 +0000)] 
Automatic date update in version.in

18 months agoAutomatic date update in version.in
GDB Administrator [Sun, 28 Jan 2024 00:01:20 +0000 (00:01 +0000)] 
Automatic date update in version.in

18 months agoAutomatic date update in version.in
GDB Administrator [Sat, 27 Jan 2024 00:01:30 +0000 (00:01 +0000)] 
Automatic date update in version.in

18 months agoBackport commits 969f5c0e1 (LoongArch: gas: Add support for s9 register) and a0aa6f4a...
mengqinggang [Fri, 26 Jan 2024 10:50:57 +0000 (10:50 +0000)] 
Backport commits 969f5c0e1 (LoongArch: gas: Add support for s9 register) and a0aa6f4ab (LoongArch: ld: Add support for TLS LE symbol with addend) to 2.42 branch.

18 months agoAutomatic date update in version.in
GDB Administrator [Fri, 26 Jan 2024 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

18 months agogas: Update NEWS
Andrew Carlotti [Fri, 19 Jan 2024 17:15:04 +0000 (17:15 +0000)] 
gas: Update NEWS

Groups entries by architecture, and update AArch64 content.

18 months agoaarch64: Update Architecture Extensions documentation
Andrew Carlotti [Mon, 15 Jan 2024 07:26:53 +0000 (07:26 +0000)] 
aarch64: Update Architecture Extensions documentation

Restructure the architecture extensions table, add a new table for architecture
version dependencies, add missing architecture extensions, and improve some
extension descriptions.

18 months agoLoongArch: gas: Start a new frag after instructions that can be relaxed
mengqinggang [Thu, 18 Jan 2024 11:03:11 +0000 (19:03 +0800)] 
LoongArch: gas: Start a new frag after instructions that can be relaxed

For R_LARCH_TLS_{LE_HI20_R,LE_ADD_R,LD_PC_HI20,GD_PC_HI20, DESC_PC_HI20}
relocations, start a new frag to get correct eh_frame Call Frame Information
FDE DW_CFA_advance_loc info.

18 months agoLoongArch: gas: Don't define LoongArch .align
mengqinggang [Sun, 1 Oct 2023 07:29:44 +0000 (15:29 +0800)] 
LoongArch: gas: Don't define LoongArch .align

Gcc may generate "\t.align\t%d,54525952,4\n" before commit
b20c7ee066cb7d952fa193972e8bc6362c6e4063. To write 54525952 (NOP) to object
file, we call s_align_ptwo (-4). It result in alignment padding must be a
multiple of 4 if .align has second parameter.

Use default s_align_ptwo for .align.

18 months agoLoongArch: Fix some test failures about TLS desc and TLS relaxation
Xi Ruoyao [Fri, 19 Jan 2024 16:38:24 +0000 (00:38 +0800)] 
LoongArch: Fix some test failures about TLS desc and TLS relaxation

There are two issues causing 11 test failures:

1. The TLS desc tests are matching the entire disassemble of a linked
   executable.  But if ld is configured --enable-default-hash-style=gnu
   (note that most modern distros use this option), the layout of the
   linked executables will be different and the immediate operands in
   the linked executables will also be different.  So we add
   "--hash-style=both" for these tests to cancel the effect of
   --enable-default-hash-style=gnu, like [x86_64 mark-plt tests].
2. By default objdump disassemble uses [pseudo-instructions] so "addi.w"
   is outputed as "li.w", causing mismatches in TLS relaxation tests.
   We can turn off the pseudo-instruction usage in objdump using "-M
   no-aliases" to fix them.

[x86_64 mark-plt tests]: 16666ccc91295d1568c5c2cb0e7600694840dfd9
[pseudo-instructions]: 17f9439038257b1de0c130a416a9a7645c653cb0

Signed-off-by: Xi Ruoyao <xry111@xry111.site>
18 months agoLoongArch: Do not emit R_LARCH_RELAX for two register macros
mengqinggang [Wed, 10 Jan 2024 01:55:13 +0000 (09:55 +0800)] 
LoongArch: Do not emit R_LARCH_RELAX for two register macros

For two register macros (e.g. la.local $t0, $t1, symbol) used in extreme code
model, do not emit R_LARCH_RELAX relocations.

18 months agoAutomatic date update in version.in
GDB Administrator [Thu, 25 Jan 2024 00:03:06 +0000 (00:03 +0000)] 
Automatic date update in version.in

18 months agoaarch64: Eliminate unused variable warnings with -DNDEBUG
Andrew Carlotti [Tue, 23 Jan 2024 18:22:12 +0000 (18:22 +0000)] 
aarch64: Eliminate unused variable warnings with -DNDEBUG

18 months agoAutomatic date update in version.in
GDB Administrator [Wed, 24 Jan 2024 00:02:16 +0000 (00:02 +0000)] 
Automatic date update in version.in

18 months agoaarch64: Include +predres2 in -march=armv8.9-a
Andrew Carlotti [Wed, 17 Jan 2024 12:37:15 +0000 (12:37 +0000)] 
aarch64: Include +predres2 in -march=armv8.9-a

This matches the dependencies in the architecture, in LLVM, and even in the
original Binutils commit message that mistakenly included it only in armv9.4-a.

18 months ago[PATCH v2] gas/NEWS, ld/NEWS: Announce LoongArch changes in 2.42
Xi Ruoyao [Tue, 23 Jan 2024 15:59:12 +0000 (15:59 +0000)] 
[PATCH v2] gas/NEWS, ld/NEWS: Announce LoongArch changes in 2.42

18 months agox86/APX: also amend the PUSH2/POP2 testcase
Jan Beulich [Mon, 22 Jan 2024 07:52:30 +0000 (08:52 +0100)] 
x86/APX: also amend the PUSH2/POP2 testcase

Commit f530d5f1bab6 ("Update x86/APX: VROUND{P,S}{S,D} can generally be
encoded") took care of only half of the remaining issue. Add #pass here
as well.

18 months agoAutomatic date update in version.in
GDB Administrator [Tue, 23 Jan 2024 00:02:50 +0000 (00:02 +0000)] 
Automatic date update in version.in

18 months agoFix 31252 gprofng causes testsuite parallel jobs fail
Vladimir Mezentsev [Sat, 20 Jan 2024 02:40:21 +0000 (18:40 -0800)] 
Fix 31252 gprofng causes testsuite parallel jobs fail

Before running our tests, we made a fake installation into ./tmpdir.
This installation changes libopcodes.la in the build area.
Gas testing may fail if gas and gprofng tests are run in parallel.

I create a script to run gprofng. Inside this script, LD_LIBRARY_PATH,
GPROFNG_SYSCONFDIR are set.
putenv_libcollector_ld_misc() first uses $GPROFNG_PRELOAD_LIBDIRS to create
directories for SP_COLLECTOR_LIBRARY_PATH ($SP_COLLECTOR_LIBRARY_PATH is used
to set up LD_PRELOAD).

gprofng/ChangeLog
2024-01-19  Vladimir Mezentsev  <vladimir.mezentsev@oracle.com>

PR gprofng/31252
PR gprofng/30808
* src/envsets.cc (putenv_libcollector_ld_misc): Use
$GPROFNG_PRELOAD_LIBDIRS first to build SP_COLLECTOR_LIBRARY_PATH.
* testsuite/config/default.exp: Create a script to run gprofng.
* testsuite/lib/display-lib.exp: Fix typo.