]> git.ipfire.org Git - thirdparty/binutils-gdb.git/log
thirdparty/binutils-gdb.git
8 years agoAutomatic date update in version.in
GDB Administrator [Sat, 13 May 2017 00:01:35 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

8 years agoFix PR21404 - assertion fail when calculating symbol size
Senthil Kumar Selvaraj [Mon, 24 Apr 2017 09:47:14 +0000 (15:17 +0530)] 
Fix PR21404 - assertion fail when calculating symbol size

Fix a host of problems related to adjustment of
symbol values and sizes when relaxing for avr.

1. Adjust symbol size first before adjusting symbol
value. Otherwise, a symbol whose value just got adjusted to the
relaxed address also ends up getting resized. See pr21404-1.s.

2. Reduce symbol sizes only if their span is below an
alignment boundary. Otherwise, the size gets decremented once when the
actual instruction is relaxed and padding bytes are added, and again
when the padding bytes are deleted (if padding ends up being unnecessary).
pr21404-2.s addresses that, and this bug is really the root cause of PR21404.

3. Adjust all symbol values before an alignment boundary.
Previous code did not adjust symbol values if they fell in the
would-be padded area, resulting in incorrect symbol values in some
cases (see pr21404-3.s).

4. Increase symbol sizes if alignment directives require so.
As pr21404-4.s shows
.global nonzero_sym
L1:
    jmp  L1
nonzero_sym:
    nop
    nop
    .p2align 2
.size nonzero_sym, .-nonzero_sym

The two nops satisfy the 4 byte alignment at assembly time and
therefore the size of nonzero_sym is 4. Relaxation shortens
the 4 byte jmp to a 2 byte rjmp, and to satisfy 4 byte alignment
the code places 2 extra padding bytes after the nops, increasing
nonzero_sym's size by 2. This wasn't handled before.

If the assembly code does not have any align directives, then the
boundary is the section size, and symbol values and sizes == boundary
should also get adjusted. To handle that case, add a did_pad variable
and use that to determine whether it should use < boundary or <= boundary.

Also get rid of reloc_toaddr, which is now redundant.  toaddr is now not
adjusted to handle the above case - the newly added
did_pad variable does the job.

pr21404-{5,6,7,8} are the same testcases written for local symbols, as
the code handles them slightly differently.

bfd/ChangeLog
2017-05-01  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

PR ld/21404
* elf32-avr.c (avr_should_move_sym): New function.
(avr_should_reduce_sym_size): Likewise.
(avr_should_increase_sym_size): Likewise.
(elf32_avr_relax_delete_bytes): Adjust symbol values
and sizes by calling new functions.

ld/ChangeLog
2017-04-28  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

PR ld/21404
* testsuite/ld-avr/pr21404-1.d: New test.
* testsuite/ld-avr/pr21404-1.s: New test.
* testsuite/ld-avr/pr21404-2.d: New test.
* testsuite/ld-avr/pr21404-2.s: New test.
* testsuite/ld-avr/pr21404-3.d: New test.
* testsuite/ld-avr/pr21404-3.s: New test.
* testsuite/ld-avr/pr21404-4.d: New test.
* testsuite/ld-avr/pr21404-4.s: New test.
* testsuite/ld-avr/pr21404-5.d: New test.
* testsuite/ld-avr/pr21404-5.s: New test.
* testsuite/ld-avr/pr21404-6.d: New test.
* testsuite/ld-avr/pr21404-6.s: New test.
* testsuite/ld-avr/pr21404-7.d: New test.
* testsuite/ld-avr/pr21404-7.s: New test.
* testsuite/ld-avr/pr21404-8.d: New test.
* testsuite/ld-avr/pr21404-8.s: New test.

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

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

8 years agoAutomatic date update in version.in
GDB Administrator [Tue, 9 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 [Mon, 8 May 2017 00:01:42 +0000 (00:01 +0000)] 
Automatic date update in version.in

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

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

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