]> git.ipfire.org Git - thirdparty/binutils-gdb.git/log
thirdparty/binutils-gdb.git
8 years agoRISC-V: Change CALL macro to use ra as the temporary address register
Michael Clark [Thu, 27 Apr 2017 04:08:46 +0000 (16:08 +1200)] 
RISC-V: Change CALL macro to use ra as the temporary address register

e.g.

    1:  auipc ra, %pcrel_hi(symbol)
        jalr  ra, %pcrel_lo(1b)(ra)

The use of ra instead of t1 for address construction provides an
opportunity for a microarchitecture to elide the write of the
destination address, and instead read the target address as an
immediate spread across the fused auipc+jalr pair. The link
register ra in the jalr overwrites the target address temporary.

8 years agoRISC-V: Allow 32-bit BFD to handle 64-bit objects
Palmer Dabbelt [Mon, 1 May 2017 17:26:32 +0000 (10:26 -0700)] 
RISC-V: Allow 32-bit BFD to handle 64-bit objects

We've been telling people that the riscv32-* and riscv64-* toolchains
are exactly the same, but it turns out we were lying: the riscv32-* BFD
doesn't handle 64-bit objects.  This fixes that difference, so the ports
are actually the same.

bfd/ChangeLog

2017-05-01  Palmer Dabbelt  <palmer@dabbelt.com>

        * config.bfd (riscv32-*): Enable rv64.

8 years agoRISC-V: Resurrect GP-relative disassembly hints
Palmer Dabbelt [Mon, 3 Apr 2017 17:08:29 +0000 (10:08 -0700)] 
RISC-V: Resurrect GP-relative disassembly hints

We missed a "_gp" when changing the GP symbol.  To make sure that
doesn't happen again, we now use the same definition everywhere (thanks,
Nick).

include/ChangeLog:

2017-04-03  Palmer Dabbelt  <palmer@dabbelt.com>

        * elf/riscv.h (RISCV_GP_SYMBOL): New define.

bfd/ChangeLog:

2017-04-03  Palmer Dabbelt  <palmer@dabbelt.com>

        * elfnn-riscv.c (GP_NAME): Delete.
        (riscv_global_pointer_value): Change GP_NAME to RISCV_GP_SYMBOL.
        (_bfd_riscv_relax_lui): Likewise.

opcodes/ChangeLog:

2017-04-03  Palmer Dabbelt  <palmer@dabbelt.com>

        * riscv-dis.c (riscv_disassemble_insn): Change "_gp" to
        RISCV_GP_SYMBOL.

8 years agoRISC-V/bfd: Hook elf_backend_object_p to set the mach type.
Kuan-Lin Chen [Tue, 17 Jan 2017 01:46:28 +0000 (09:46 +0800)] 
RISC-V/bfd: Hook elf_backend_object_p to set the mach type.

8 years agoAutomatic date update in version.in
GDB Administrator [Fri, 5 May 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 4 May 2017 00:01:52 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 2 May 2017 00:01:18 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 1 May 2017 00:01:22 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 30 Apr 2017 00:01:19 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 29 Apr 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 27 Apr 2017 00:01:46 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoPR ld/21334: Always call `_bfd_elf_link_renumber_dynsyms' if required
Maciej W. Rozycki [Wed, 26 Apr 2017 21:23:44 +0000 (22:23 +0100)] 
PR ld/21334: Always call `_bfd_elf_link_renumber_dynsyms' if required

Complement commit e17b0c351f0b ("MIPS/BFD: Respect the ELF gABI dynamic
symbol table sort requirement") and correct an inconsistency in dynamic
symbol accounting data causing an assertion failure in the MIPS backend:

ld: BFD (GNU Binutils) 2.28.51.20170330 assertion fail
../../binutils-gdb/bfd/elfxx-mips.c:3860

in the course of making a GOT entry in a static binary to satisfy a GOT
relocation present in input, due to the local dynamic symbol count not
having been established.

To do so let backends request `_bfd_elf_link_renumber_dynsyms' to be
always called, rather than where a dynamic binary is linked only, and
then make this request in the MIPS backend.

bfd/
PR ld/21334
* elf-bfd.h (elf_backend_data): Add `always_renumber_dynsyms'
member.
* elfxx-target.h [!elf_backend_always_renumber_dynsyms]
(elf_backend_always_renumber_dynsyms): Define.
(elfNN_bed): Initialize `always_renumber_dynsyms' member.
* elfxx-mips.h (elf_backend_always_renumber_dynsyms): Define.
* elflink.c (bfd_elf_size_dynsym_hash_dynstr): Also call
`_bfd_elf_link_renumber_dynsyms' if the backend has requested
it.
(elf_gc_sweep): Likewise.

(backported from commit 23ec1e32b1ab714649a7c25e49b5d721fe3bd3db)

8 years agoELF/BFD: Limit `_bfd_elf_link_renumber_dynsyms' call in section GC
Maciej W. Rozycki [Wed, 26 Apr 2017 21:18:13 +0000 (22:18 +0100)] 
ELF/BFD: Limit `_bfd_elf_link_renumber_dynsyms' call in section GC

Consistently call `_bfd_elf_link_renumber_dynsyms' only if linking a
dynamic binary, complementing code in `bfd_elf_size_dynsym_hash_dynstr'
and commit ccabcbe51e85 ("New attempt at fixing MIPS --gc-sections et
al."), <https://sourceware.org/ml/binutils/2005-08/msg00258.html>.

bfd/
* elflink.c (elf_gc_sweep): Only call
`_bfd_elf_link_renumber_dynsyms' if dynamic sections have been
created.

(backported from commit c46cec3a8cfe02fbe0f6c67ba53abc5369c5c659)

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 26 Apr 2017 00:01:20 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 25 Apr 2017 00:01:25 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoi386: Set ELF_MAXPAGESIZE to 0x1000 for VxWorks
H.J. Lu [Mon, 24 Apr 2017 16:37:10 +0000 (09:37 -0700)] 
i386: Set ELF_MAXPAGESIZE to 0x1000 for VxWorks

commit a27e437177412e5b52999723f3c5d5d0d37b9087
Author: Roland McGrath <roland@gnu.org>
Date:   Thu Jul 28 22:35:15 2011 +0000

    BFD vector for elf32-i386-nacl:

changed ELF_MAXPAGESIZE to 0x10000 for VxWorks.  This patch fixes it
and updated testsuite/ld-i386/vxworks2.sd to add space for program
headers.

bfd/

PR ld/21425
* elf32-i386.c (ELF_MAXPAGESIZE): Set to 0x1000 for VxWorks.

ld/

PR ld/20815
* testsuite/ld-i386/vxworks2.sd: Add space for program headers.

(cherry picked from commit 1587442d37ee4266e54d59bfdc783574f0587aff)

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 24 Apr 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 23 Apr 2017 00:01:20 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 22 Apr 2017 00:01:26 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 20 Apr 2017 00:01:51 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoFix for PR ld/16044: elf32-cris.c h->plt.refcount inconsistency
Hans-Peter Nilsson [Wed, 19 Apr 2017 13:27:31 +0000 (15:27 +0200)] 
Fix for PR ld/16044: elf32-cris.c h->plt.refcount inconsistency

Backport (cherry-pick) from master.

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 19 Apr 2017 00:01:27 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 18 Apr 2017 00:01:26 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 17 Apr 2017 00:01:23 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 16 Apr 2017 00:01:14 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 15 Apr 2017 00:01:16 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoMissing _bfd_error_handler args
Alan Modra [Thu, 13 Apr 2017 01:14:20 +0000 (10:44 +0930)] 
Missing _bfd_error_handler args

* elf32-arm.c (arm_type_of_stub): Supply missing args to "long
branch veneers" error.  Fix double space and format message.
* elf32-avr.c (avr_add_stub): Do not pass NULL as %B arg.
* elf64-ppc.c (tocsave_find): Supply missing %B arg.

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 13 Apr 2017 00:01:34 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 12 Apr 2017 00:01:21 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 11 Apr 2017 00:01:15 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoELF: Check ELF_COMMON_DEF_P for common symbols
H.J. Lu [Fri, 7 Apr 2017 14:40:14 +0000 (07:40 -0700)] 
ELF: Check ELF_COMMON_DEF_P for common symbols

Since common symbols that are turned into definitions don't have the
DEF_REGULAR flag set, we need to check ELF_COMMON_DEF_P for common
symbols.

bfd/

PR ld/19579
PR ld/21306
* elf32-s390.c (elf_s390_finish_dynamic_symbol): Check
ELF_COMMON_DEF_P for common symbols.
* elf64-s390.c (elf_s390_finish_dynamic_symbol): Likewise.
* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
* elflink.c (_bfd_elf_merge_symbol): Revert commits
202ac193bbbecc96a4978d1ac3d17148253f9b01 and
07492f668d2173da7a2bda3707ff0985e0f460b6.

ld/

PR ld/19579
PR ld/21306
* testsuite/ld-elf/pr19579a.c (main): Updated.

(cherry picked from commit 8170f7693bc0a9442c0aa280197925db92d48ca6)

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 10 Apr 2017 00:01:16 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 9 Apr 2017 00:01:17 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 8 Apr 2017 00:01:17 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 6 Apr 2017 00:01:34 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agold/ChangeLog: Correct last entry's date
Maciej W. Rozycki [Wed, 5 Apr 2017 15:43:16 +0000 (16:43 +0100)] 
ld/ChangeLog: Correct last entry's date

8 years agoPR ld/21233: Avoid sweeping forced-undefined symbols in section GC
Maciej W. Rozycki [Mon, 27 Mar 2017 11:39:07 +0000 (12:39 +0100)] 
PR ld/21233: Avoid sweeping forced-undefined symbols in section GC

Complement commit 902e9fc76a0e ("PR ld/20828: Move symbol version
processing ahead of GC symbol sweep"), commit b531344c34b0 ("PR
ld/20828: Reorder the symbol sweep stage of section GC") and commit
81ff47b3a546 ("PR ld/20828: Fix linker script symbols wrongly forced
local with section GC"), and prevent symbols forcibly entered in the
output file with the use of the `--undefined=' or `--require-defined='
linker command line options or the EXTERN linker script command from
being swept in section garbage collection and consequently recorded in
the dynamic symbol table as local entries.  This happens in certain
circumstances, where a symbol reference also exists in one of the static
input files, however only in a section which is garbage-collected and
does not make it to the output file, and the symbol is defined in a
dynamic object present in the link.

For example with the `i386-linux' target and the `pr21233.s' and
`pr21233-l.s' sources, and the `pr21233.ld' linker script included with
this change we get:

$ as -o pr21233-l.o pr21233-l.s
$ ld -shared -T pr21233.ld -o libpr21233.so pr21233-l.o
$ as -o pr21233.o pr21233.s
$ ld --gc-sections -e foo --require-defined=bar -T pr21233.ld -o pr21233 pr21233.o libpr21233.so
$ readelf --dyn-syms pr21233

Symbol table '.dynsym' contains 2 entries:
   Num:    Value  Size Type    Bind   Vis      Ndx Name
     0: 00000000     0 NOTYPE  LOCAL  DEFAULT  UND
     1: 00000000     0 OBJECT  LOCAL  DEFAULT  UND bar
$

which makes the run-time `bar' dependency of the `pr21233' executable
different from its corresponding link-time dependency, i.e. the presence
of `libpr21233.so' and its `bar' symbol is required at the link time,
however at the run time a copy of `libpr21233.so' without `bar' will do.
Similarly with `--undefined=' and EXTERN which do not actually require
the reference to the symbol requested to be satisfied with a definition
at the link time, however once the definition has been pulled at the
link time, so it should at the dynamic load time.

Additionally with the `mips-linux' target we get:

$ ld --gc-sections -e foo --require-defined=bar -T pr21233.ld -o pr21233 pr21233.o libpr21233.so
ld: BFD (GNU Binutils) 2.28.51.20170324 assertion fail .../bfd/elfxx-mips.c:3861
$

as the target is not prepared to handle such a local dynamic symbol.

With this change in effect we get:

$ readelf --dyn-syms pr21233

Symbol table '.dynsym' contains 2 entries:
   Num:    Value  Size Type    Bind   Vis      Ndx Name
     0: 00000000     0 NOTYPE  LOCAL  DEFAULT  UND
     1: 00000000     0 OBJECT  GLOBAL DEFAULT  UND bar
$

instead, for both targets.

ld/
PR ld/21233
* ldlang.c (insert_undefined): Set `mark' for ELF symbols.

(backported from commit 80070c0d3491347f11283c5791b9dd040fedbd4f)

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 5 Apr 2017 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoRISC-V: Avoid a const warning
Palmer Dabbelt [Mon, 3 Apr 2017 16:03:57 +0000 (09:03 -0700)] 
RISC-V: Avoid a const warning

2017-04-03  Palmer Dabbelt  <palmer@dabbelt.com>

       * config/tc-riscv.c (riscv_clear_subsets): Cast argument to free to
       avoid const warnings.

8 years agoAllow ISA subsets to be disabled
Palmer Dabbelt [Wed, 29 Mar 2017 23:05:40 +0000 (16:05 -0700)] 
Allow ISA subsets to be disabled

Without this patch, passing "-march=rv64ic -march=rv64i" results in
you getting a "RV64IC" toolchain, which isn't expected.

gas/ChangeLog:

2017-03-30  Palmer Dabbelt  <palmer@dabbelt.com>

       * config/tc-riscv.c (riscv_clear_subsets): New function.
       (riscv_add_subset): Call riscv_clear_subsets and riscv_set_rvc to
       clear RVC when it's been previously set.

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 4 Apr 2017 00:01:21 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAdd physical memory protection CSRs
Andrew Waterman [Wed, 22 Mar 2017 09:09:56 +0000 (02:09 -0700)] 
Add physical memory protection CSRs

2017-03-27  Andrew Waterman  <andrew@sifive.com>

       * opcode/riscv-opc.h (CSR_PMPCFG0): New define.
       (CSR_PMPCFG1): Likewise.
       (CSR_PMPCFG2): Likewise.
       (CSR_PMPCFG3): Likewise.
       (CSR_PMPADDR0): Likewise.
       (CSR_PMPADDR1): Likewise.
       (CSR_PMPADDR2): Likewise.
       (CSR_PMPADDR3): Likewise.
       (CSR_PMPADDR4): Likewise.
       (CSR_PMPADDR5): Likewise.
       (CSR_PMPADDR6): Likewise.
       (CSR_PMPADDR7): Likewise.
       (CSR_PMPADDR8): Likewise.
       (CSR_PMPADDR9): Likewise.
       (CSR_PMPADDR10): Likewise.
       (CSR_PMPADDR11): Likewise.
       (CSR_PMPADDR12): Likewise.
       (CSR_PMPADDR13): Likewise.
       (CSR_PMPADDR14): Likewise.
       (CSR_PMPADDR15): Likewise.
       (pmpcfg0): Declare register.
       (pmpcfg1): Likewise.
       (pmpcfg2): Likewise.
       (pmpcfg3): Likewise.
       (pmpaddr0): Likewise.
       (pmpaddr1): Likewise.
       (pmpaddr2): Likewise.
       (pmpaddr3): Likewise.
       (pmpaddr4): Likewise.
       (pmpaddr5): Likewise.
       (pmpaddr6): Likewise.
       (pmpaddr7): Likewise.
       (pmpaddr8): Likewise.
       (pmpaddr9): Likewise.
       (pmpaddr10): Likewise.
       (pmpaddr11): Likewise.
       (pmpaddr12): Likewise.
       (pmpaddr13): Likewise.
       (pmpaddr14): Likewise.
       (pmpaddr15): Likewise.

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

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 2 Apr 2017 00:01:14 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 1 Apr 2017 00:01:21 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Fri, 31 Mar 2017 00:01:22 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoSanitize RISC-V GAS help text, documentation
Palmer Dabbelt [Tue, 21 Mar 2017 15:36:44 +0000 (08:36 -0700)] 
Sanitize RISC-V GAS help text, documentation

It looks like I missed the GAS help text when going through all the
documentation last time, so it printed some of the old-format (never
upstream) arguments.  I fixed this, and when I went to check doc/ I
noticed it was missing the '-fpic'/'-fno-pic' options.

2017-03-21  Palmer Dabbbelt  <palmer@dabbelt.com>

        * config/tc-riscv.c (md_show_usage): Remove defuct -m32, -m64,
        -msoft-float, -mhard-float, -mno-rvc, and -mrvc options; and don't
        print an invalid default ISA string.
        * doc/c-riscv.texi (OPTIONS): Add -fpic and -fno-pic options.

8 years agoRISC-V: Fix assembler for c.li, c.andi and c.addiw
Kito Cheng [Tue, 7 Mar 2017 10:15:02 +0000 (18:15 +0800)] 
RISC-V: Fix assembler for c.li, c.andi and c.addiw

 - They can accept 0 in imm field

 2017-03-14  Kito Cheng  <kito.cheng@gmail.com>

       * riscv-opc.c (riscv_opcodes> <c.li>: Use the 'o' immediate encoding.
       <c.andi>: Likewise.
       <c.addiw> Likewise.

8 years agoRISC-V: Fix assembler for c.addi, rd can be x0
Kito Cheng [Tue, 7 Mar 2017 11:56:40 +0000 (19:56 +0800)] 
RISC-V: Fix assembler for c.addi, rd can be x0

opcodes/ChangeLog:

2017-03-14  Kito Cheng  <kito.cheng@gmail.com>

* riscv-opc.c (riscv_opcodes) <c.addi>: Use match_opcode.

8 years agoRISC-V: Define DWARF2_USE_FIXED_ADVANCE_PC.
Kuan-Lin Chen [Thu, 2 Mar 2017 06:54:32 +0000 (14:54 +0800)] 
RISC-V: Define DWARF2_USE_FIXED_ADVANCE_PC.

gas/ChangeLog

2017-03-02  Kuan-Lin Chen  <rufus@andestech.com>

        * config/tc-riscv.h (HWARD2_USE_FIXED_ADVANCE_PC): New define.

8 years agoRISC-V: Fix DW_CFA_advance_loc relocation.
Kuan-Lin Chen [Fri, 10 Feb 2017 06:58:52 +0000 (14:58 +0800)] 
RISC-V: Fix DW_CFA_advance_loc relocation.

gas/ChangeLog:

2017-03-02  Kuan-Lin Chen  <rufus@andestech.com>

        * config/tc-riscv.c (md_apply_fix): Set fx_frag and
        fx_next->fx_frag for CFA_advance_loc relocations.

8 years agoRISC-V: Fix the offset of CFA relocation.
Kuan-Lin Chen [Thu, 2 Feb 2017 07:27:18 +0000 (15:27 +0800)] 
RISC-V: Fix the offset of CFA relocation.

gas/ChangeLog:

2017-03-02  Kuan-Lin Chen  <rufus@andestech.com>

        * config/tc-riscv.c (md_apply_fix): Compute the correct offsets
        for CFA relocations.

8 years agoRISC-V: Fix [dis]assembly of srai/srli
Andrew Waterman [Mon, 13 Mar 2017 19:46:33 +0000 (12:46 -0700)] 
RISC-V: Fix [dis]assembly of srai/srli

These were simple copy/paste errors from the compressed left shift
pattern, which can't have a 0-register.

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 30 Mar 2017 00:01:33 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 29 Mar 2017 00:01:05 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 28 Mar 2017 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoPR21303, objdump doesn't show e200z4 insns
Alan Modra [Sun, 26 Mar 2017 21:49:48 +0000 (08:19 +1030)] 
PR21303, objdump doesn't show e200z4 insns

PR 21303
opcodes/
* ppc-dis.c (struct ppc_mopt): Comment.
(ppc_opts <e200z4>): Move PPC_OPCODE_VLE from .sticky to .cpu.
gas/
* testsuite/gas/ppc/pr21303.d,
* testsuite/gas/ppc/pr21303.s: New test
* testsuite/gas/ppc/ppc.exp: Run it.

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 27 Mar 2017 00:01:18 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 26 Mar 2017 00:00:58 +0000 (00:00 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 25 Mar 2017 00:00:49 +0000 (00:00 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Fri, 24 Mar 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 23 Mar 2017 00:01:32 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 22 Mar 2017 00:01:25 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoS/390: Remove vx2 facility flag
Andreas Krebbel [Tue, 21 Mar 2017 13:24:50 +0000 (14:24 +0100)] 
S/390: Remove vx2 facility flag

This patch removes the vx2 facility flag.  It will not be used by GCC
and was a misnomer anyway.

Committed to mainline and 2.28 branch.

include/ChangeLog:

2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

Backport from mainline
2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* opcode/s390.h (S390_INSTR_FLAG_VX2): Remove.
(S390_INSTR_FLAG_FACILITY_MASK): Adjust value.

gas/ChangeLog:

2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

Backport from mainline
2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* config/tc-s390.c (s390_parse_cpu): Remove S390_INSTR_FLAG_VX2
from cpu_table.  Remove vx2, and novx2 from cpu_flags.

opcodes/ChangeLog:

2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

Backport from mainline
2017-03-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>

* s390-mkopc.c (main): Remove vx2 check.
* s390-opc.txt: Remove vx2 instruction flags.

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 21 Mar 2017 00:01:09 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 20 Mar 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 19 Mar 2017 00:01:20 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 18 Mar 2017 00:01:34 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Fri, 17 Mar 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 16 Mar 2017 00:01:30 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 15 Mar 2017 00:01:23 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 14 Mar 2017 00:01:26 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 13 Mar 2017 00:01:13 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 12 Mar 2017 00:01:21 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 11 Mar 2017 00:01:24 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Fri, 10 Mar 2017 00:01:18 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoUpdate -maltivec and -mvsx options to only enable their oldest instructions.
Peter Bergner [Thu, 9 Mar 2017 02:49:03 +0000 (20:49 -0600)] 
Update -maltivec and -mvsx options to only enable their oldest instructions.

Currently, the -maltivec and -mvsx GAS options enable *all* of the altivec
and vsx instructions respecitively that have ever been added.  This is in
constract to GCC's -maltivec and -mvsx options, which only enable the oldest
(ie, first) set of altivec and vsx instructions.  This patch changes GAS to
mimic GCC's behaviour with respect to -maltivec and -mvsx and it solves a
problem with trying to assemble the lxvx instruction which is different
between POWER8 and POWER9.

opcodes/
* ppc-dis.c (ppc_opts) <altivec>: Do not use PPC_OPCODE_ALTIVEC2;
<vsx>: Do not use PPC_OPCODE_VSX3;

gas/
* testsuite/gas/ppc/altivec2.d (as): Use the -mpower8 option.
(objdump): Use the -Mpower8 option.

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 9 Mar 2017 00:01:25 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAdd support for the new 'lnia' extended mnemonic.
Peter Bergner [Wed, 8 Mar 2017 22:00:54 +0000 (16:00 -0600)] 
Add support for the new 'lnia' extended mnemonic.

opcodes/
Apply from master.
2017-03-08  Peter Bergner  <bergner@vnet.ibm.com>
* ppc-opc.c (powerpc_opcodes) <lnia>: New extended mnemonic.

gas/
Apply from master.
2017-03-08  Peter Bergner  <bergner@vnet.ibm.com>
* testsuite/gas/ppc/power9.d <lnia> New test.
* testsuite/gas/ppc/power9.s: Likewise.

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 8 Mar 2017 00:01:31 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoFix ld uninitialized read of script ASSERT data structure
Alan Modra [Tue, 7 Mar 2017 01:50:00 +0000 (12:20 +1030)] 
Fix ld uninitialized read of script ASSERT data structure

lang_assignment_statement serves both assignments and asserts.

* ldlang.c (open_input_bfds): Check that lang_assignment_statement
is not an assert before referencing defsym.

8 years agoPowerPC64 abort due to dynamic relocs on hidden undefweak
Alan Modra [Tue, 7 Mar 2017 00:34:19 +0000 (11:04 +1030)] 
PowerPC64 abort due to dynamic relocs on hidden undefweak

ppc64_elf_relocate_section lacked a check which meant that it emitted
dynamic relocs against a hidden undefweak symbol for which no dynamic
relocs had been allocated.

PR 21224
PR 20519
* elf64-ppc.c (ppc64_elf_relocate_section): Add missing
dyn_relocs check.

8 years agoDon't decode powerpc insns with invalid fields
Alan Modra [Mon, 6 Mar 2017 09:09:34 +0000 (19:39 +1030)] 
Don't decode powerpc insns with invalid fields

Certain insns have restrictions on fields.  For example, the insn
mentioned in the PR, lqarx, must specify an even general purpose
register as its destination and that register cannot appear in
either of the base or index reg fields.  This holds even when the RA0
field is 0 (meaning a zero rather than r0).

PR 21124
* ppc-opc.c (extract_esync, extract_ls, extract_ral, extract_ram)
(extract_raq, extract_ras, extract_rbx): New functions.
(powerpc_operands): Use opposite corresponding insert function.
(Q_MASK): Define.
(powerpc_opcodes): Apply Q_MASK to all quad insns with even
register restriction.

8 years agoPowerPC VLE typo fix
Alan Modra [Wed, 1 Mar 2017 23:54:14 +0000 (10:24 +1030)] 
PowerPC VLE typo fix

* elf32-ppc.c (ppc_elf_vle_split16): Correct insn mask typo.

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 7 Mar 2017 00:01:28 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Mon, 6 Mar 2017 00:01:19 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sun, 5 Mar 2017 00:01:17 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 4 Mar 2017 00:01:53 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoSet version to 2.28, not a relase.
Tristan Gingold [Thu, 2 Mar 2017 09:35:22 +0000 (10:35 +0100)] 
Set version to 2.28, not a relase.

bfd/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* version.m4: Bump version to 2.28.0
* configure: Regenerate.

binutils/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* configure: Regenerate.

gas/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* configure: Regenerate.

gprof/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* configure: Regenerate.

ld/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* configure: Regenerate.

opcodes/
2017-03-02  Tristan Gingold  <gingold@adacore.com>

* configure: Regenerate.

8 years agoAdd generated files binutils-2_28
Tristan Gingold [Thu, 2 Mar 2017 09:17:52 +0000 (10:17 +0100)] 
Add generated files

8 years agoSync libiberty sources with GCC mainline.
Nick Clifton [Wed, 1 Mar 2017 15:09:29 +0000 (15:09 +0000)] 
Sync libiberty sources with GCC mainline.

Brings in:
  2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>

PR PR c++/70182
* cp-demangle.c (d_unqualified_name): Handle "on" for
operator names.
* testsuite/demangle-expected: Add tests.

 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>

PR c++/77489
* cp-demangle.c (d_discriminator): Handle discriminator >= 10.
* testsuite/demangle-expected: Add tests for discriminator.

 2016-12-13  Jakub Jelinek  <jakub@redhat.com>

PR c++/78761
* cp-demangle.c (cplus_demangle_type): Demangle Dc as decltype(auto).
* testsuite/demangle-expected: Add test for decltype(auto).

8 years agoAutomatic date update in version.in
GDB Administrator [Thu, 2 Mar 2017 00:01:22 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoAutomatic date update in version.in
GDB Administrator [Wed, 1 Mar 2017 00:01:46 +0000 (00:01 +0000)] 
Automatic date update in version.in

8 years agoNios2 dynobj handling fixes
Alan Modra [Tue, 28 Feb 2017 00:08:51 +0000 (10:38 +1030)] 
Nios2 dynobj handling fixes

A number of places in elf32-nios.c created dynamic sections but didn't
set the hash table dynobj.  That meant we could have duplicate dynamic
sections connected to a number of bfds, so size_dynamic_sections
didn't properly discard or allocate contents.

Also, the entire set of dynamic sections was created in check_relocs
on seeing GOT relocs, when only .got related sections are needed,
probably done to hide segfaults later in finish_dynamic_sections.

The patch fixes these issues and makes the assembler emit errors when
nios2 lacks the necessary pc-relative relocs for subtraction
expressions, rather than silently generating bad code.
eg. ld-elf/merge.  I've also tidied uses of elf32_nios2_hash_table and
elf_hash_table.

bfd/
PR 20995
* elf32-nios2.c (nios2_elf32_relocate_section): Use htab
rather than elf32_nios2_hash_table or elf_hash_table.
(create_got_section): Likewise.
(nios2_elf32_finish_dynamic_symbol): Likewise.
(nios2_elf32_adjust_dynamic_symbol): Likewise.
(nios2_elf32_size_dynamic_sections): Likewise.
(nios2_elf32_check_relocs): Delete dynobj, sgot, and srelgot
vars.  Use htab equivalents directly instead.  Don't create
all dynamic sections on needing just the GOT.  Use a goto
rather than a fall-through with reloc test.  Ensure
htab->dynobj is set when making dynamic sreloc section.
(nios2_elf32_finish_dynamic_sections): Delete dynobj, use htab
equivalent directly instead.  Don't segfault on looking for
.dynamic when dynamic sections have not been created.  Don't
segfault on .got.plt being discarded.
(nios2_elf32_size_dynamic_sections): Delete plt and got vars.
Don't set "relocs" on .rela.plt.  Do handle .sbss.  Delete
fixme and another not so relevant comment.
(nios2_elf_add_symbol_hook): Delete dynobj var.  If not
already set, set hash table dynobj on creating .sbss.
gas/
* config/tc-nios2.h (TC_FORCE_RELOCATION_SUB_LOCAL): Define.
ld/
* testsuite/ld-elf/merge.d: xfail for nios.