public inbox for archer-commits@sourceware.org
help / color / mirror / Atom feed
From: jkratoch@sourceware.org
To: archer-commits@sourceware.org
Subject: [SCM]  users/jkratoch/dwarf5gcc: Merge remote-tracking branch 'gdb/master' into dwarf5gcc
Date: Fri, 18 Nov 2016 19:20:00 -0000	[thread overview]
Message-ID: <20161118192050.43624.qmail@sourceware.org> (raw)

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 81623 bytes --]

The branch, users/jkratoch/dwarf5gcc has been updated
       via  940be4a3470ffdd54cc46e06ca09a07310083f6e (commit)
       via  8504e0974cf4b67680a11208b16caa2d3c77b838 (commit)
       via  bb050a6932c4b0ea86202fe62bed2d94999f77ad (commit)
       via  cc133f9f118ef4afd93da0ecba48151488c41c74 (commit)
       via  a85db0a6188b89ef49a1bd0f0ed435adc133b3ae (commit)
       via  535aade664ac4170fe82e52c9addd686156220a1 (commit)
       via  ddc5804ebd4b2be29ad4e3e259f5c6e907f34f26 (commit)
       via  1706852c3c6c1d39f949c933d37647d02509b9cb (commit)
       via  59d2699cfd30f9defc454be17415c0a518ece32b (commit)
       via  a4ddf8dc72f0ac10c3459a91949eb1bdb07ed10d (commit)
       via  4d17eaece8b31e642acaf4d77fe961ad8e3aaf50 (commit)
       via  ef0f5d7cc3b2082c94beffa7c9c1a8acd8eaa427 (commit)
       via  aba19b625f34fb3d61263fe8044cf0c6d8804570 (commit)
       via  9d2cdc86574bda0f1013be8cdc166d86b6d032bc (commit)
       via  c2c4ff8d52a2cd3263a547b0384692498714aa1b (commit)
       via  28617675c264213180a599bb4327bf162029636a (commit)
       via  ccfc90a39b78b7bc4173cd9ead49d2aa59695378 (commit)
       via  3f06e55061d0d8f72dfd11f6c432c23f45d9b597 (commit)
       via  6ec49e7c0aeb6d98e379319b565aee2c89388615 (commit)
       via  cd42d70b4d7e92dcc6c533e012ab8af122de7b9e (commit)
       via  470dd0a647c95a2e88c5b0f8df538826b08959a8 (commit)
       via  5443506ee45cb94769db7e76dd2021a96f2f0680 (commit)
       via  3b165252e882c05c8217f888194877224295592d (commit)
       via  f2ff9acd32b4667ee16a03ca8d10fd8b99e22f46 (commit)
       via  66be918f5f9f78d74c70aa332756286ff9d0ccf2 (commit)
       via  7c2683c40f745397e80b6df4edf8265ecb6fd194 (commit)
       via  200069c74f42ffcc726b9995a46971a86286a256 (commit)
       via  19f1935d91bfabbe4176ffdaca95bc789b593153 (commit)
       via  fa98319231a95aca0313878443143d3f92aca5e1 (commit)
       via  256ae5dbc73d1348850f86ee77a0dc3b04bc7cc0 (commit)
       via  33cc7d368f420326606695daafd6292e2779c6af (commit)
       via  41b56feb5063aee4fefb4a991eb796d1e8a7475e (commit)
       via  df433d316277ff5293832d3cd6cbc30b5c38dec0 (commit)
       via  1a2f3d7ff1d79b1290704e48c71e905b987393a6 (commit)
      from  1c666b6929be0eda374b204c2637b36e4547e3c5 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email.

- Log -----------------------------------------------------------------
commit 940be4a3470ffdd54cc46e06ca09a07310083f6e
Merge: 1c666b6 8504e09
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Nov 18 20:20:28 2016 +0100

    Merge remote-tracking branch 'gdb/master' into dwarf5gcc

commit 8504e0974cf4b67680a11208b16caa2d3c77b838
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Fri Nov 18 16:59:00 2016 +0100

    gdb/doc: Add missing comma after xref
    
    Get rid of a warning for missing punctuation after xref.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (GDB/MI Async Records): Add missing comma after
    	xref.

commit bb050a6932c4b0ea86202fe62bed2d94999f77ad
Author: Claudiu Zissulescu <claziss@synopsys.com>
Date:   Thu Nov 17 13:26:54 2016 +0100

    [ARC] Fix and extend features of .cpu directive.
    
    gas/
    2016-11-18  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* testsuite/gas/arc/cl-warn.s: New file.
    	* testsuite/gas/arc/cpu-pseudop-1.d: Likewise.
    	* testsuite/gas/arc/cpu-pseudop-1.s: Likewise.
    	* testsuite/gas/arc/cpu-pseudop-2.d: Likewise.
    	* testsuite/gas/arc/cpu-pseudop-2.s: Likewise.
    	* testsuite/gas/arc/cpu-warn2.s: Likewise.
    	* config/tc-arc.c (selected_cpu): Initialize.
    	(feature_type): New struct.
    	(feature_list): New variable.
    	(arc_check_feature): New function.
    	(arc_select_cpu): Check for .cpu duplicates. Don't overwrite the
    	current cpu features. Check if a feature is available for a given
    	cpu.
    	(md_parse_option): Test if features are available for a given cpu.

commit cc133f9f118ef4afd93da0ecba48151488c41c74
Author: James Clarke <jrtc27@jrtc27.com>
Date:   Fri Nov 18 12:51:40 2016 +0100

    bfd: fix negative GOT offsets for non-local references on sparc64
    
    bfd/ChangeLog:
    
    2016-11-18  James Clarke  <jrtc27@jrtc27.com>
    
    	* elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Don't convert
    	R_SPARC_GOTDATA_OP_HIX22 and R_SPARC_GOTDATA_OP_LOX10 to
    	R_SPARC_GOT* for non-local references. Instead, treat them like
    	R_SPARC_GOTDATA_HIX22/R_SPARC_GOTDATA_LOX10 when filling in the
    	immediate with the calculated relocation.

commit a85db0a6188b89ef49a1bd0f0ed435adc133b3ae
Author: Mark Wielaard <mark@klomp.org>
Date:   Thu Nov 17 01:28:09 2016 +0100

    cxxfilt: Recognize rust_demangling.

commit 535aade664ac4170fe82e52c9addd686156220a1
Author: David Tolnay <dtolnay@gmail.com>
Date:   Wed Nov 16 23:09:27 2016 +0000

    libiberty: Add Rust symbol demangling.
    
    Adds Rust symbol demangler. Rust mangles symbols using GNU_V3 style,
    adding a hash and various special character subtitutions. This adds
    a new rust style to cplus_demangle and adds 3 helper functions
    rust_demangle, rust_demangle_sym and rust_is_mangled.
    
    rust-demangle.c was written by David. Mark did the code formatting to
    GNU style and integration into the gcc/libiberty build system and
    testsuite.
    
    include/ChangeLog:
    
    2016-11-03  David Tolnay <dtolnay@gmail.com>
               Mark Wielaard  <mark@klomp.org>
    
           * demangle.h (DMGL_RUST): New macro.
           (DMGL_STYLE_MASK): Add DMGL_RUST.
           (demangling_styles): Add dlang_rust.
           (RUST_DEMANGLING_STYLE_STRING): New macro.
           (RUST_DEMANGLING): New macro.
           (rust_demangle): New prototype.
           (rust_is_mangled): Likewise.
           (rust_demangle_sym): Likewise.
    
    libiberty/ChangeLog:
    
    2016-11-03  David Tolnay <dtolnay@gmail.com>
               Mark Wielaard  <mark@klomp.org>
    
           * Makefile.in (CFILES): Add rust-demangle.c.
           (REQUIRED_OFILES): Add rust-demangle.o.
           * cplus-dem.c (libiberty_demanglers): Add rust_demangling case.
           (cplus_demangle): Handle RUST_DEMANGLING.
           (rust_demangle): New function.
           * rust-demangle.c: New file.
           * testsuite/Makefile.in (really-check): Add check-rust-demangle.
           (check-rust-demangle): New rule.
           * testsuite/rust-demangle-expected: New file.

commit ddc5804ebd4b2be29ad4e3e259f5c6e907f34f26
Author: Mark Wielaard <mark@klomp.org>
Date:   Tue Nov 15 19:31:59 2016 +0000

    libiberty: demangler crash with missing :? or fold expression component.
    
    When constructing an :? or fold expression that requires a third
    expression only the first and second were explicitly checked to
    not be NULL. Since the third expression is also required in these
    constructs it needs to be explicitly checked and rejected when missing.
    Otherwise the demangler will crash once it tries to d_print the
    NULL component. Added two examples to demangle-expected of strings
    that would crash before this fix.
    
    Found by American Fuzzy Lop (afl) fuzzer.

commit 1706852c3c6c1d39f949c933d37647d02509b9cb
Author: Mark Wielaard <mark@klomp.org>
Date:   Tue Nov 15 19:31:50 2016 +0000

    libiberty: Fix some demangler crashes caused by reading past end of input.
    
    In various situations the cplus_demangle () function could read past the
    end of input causing crashes. Add checks in various places to not advance
    the demangle string location and fail early when end of string is reached.
    Add various examples of input strings to the testsuite that would crash
    test-demangle before the fixes.
    
    Found by using the American Fuzzy Lop (afl) fuzzer.
    
    libiberty/ChangeLog:
    
           * cplus-dem.c (demangle_signature): After 'H', template function,
           no success and don't advance position if end of string reached.
           (demangle_template): After 'z', template name, return zero on
           premature end of string.
           (gnu_special): Guard strchr against searching for zero characters.
           (do_type): If member, only advance mangled string when 'F' found.
           * testsuite/demangle-expected: Add examples of strings that could
           crash the demangler by reading past end of input.

commit 59d2699cfd30f9defc454be17415c0a518ece32b
Author: Mark Wielaard <mark@klomp.org>
Date:   Mon Nov 14 19:46:26 2016 +0000

    libiberty: Add -Wshadow=local to warning flags (if supported).
    
    libiberty/ChangeLog:
    
           * configure.ac (ac_libiberty_warn_cflags): Add -Wshadow=local.
           * configure: Regenerated.

commit a4ddf8dc72f0ac10c3459a91949eb1bdb07ed10d
Author: Jason Merrill <jason@redhat.com>
Date:   Mon Nov 7 23:09:29 2016 +0000

    Implement P0012R1, Make exception specifications part of the type system.
    
    libiberty/
    	* cp-demangle.c (is_fnqual_component_type): New.
    	(d_encoding, d_print_comp_inner, d_print_mod_list): Use it.
    	(FNQUAL_COMPONENT_CASE): New.
    	(d_make_comp, has_return_type, d_print_comp_inner)
    	(d_print_function_type): Use it.
    	(next_is_type_qual): New.
    	(d_cv_qualifiers, d_print_mod): Handle noexcept and throw-spec.
    include/
    	* demangle.h (enum demangle_component_type): Add
    	DEMANGLE_COMPONENT_NOEXCEPT, DEMANGLE_COMPONENT_THROW_SPEC.

commit 4d17eaece8b31e642acaf4d77fe961ad8e3aaf50
Author: Mark Wielaard <mjw@redhat.com>
Date:   Fri Nov 4 23:55:01 2016 +0000

    libiberty: Fix -Wimplicit-fallthrough warnings.
    
    Adjust some comments, add some explicit fall through comments or explicit
    returns where necessary to not get implicit-fallthrough warnings.
    
    All fall throughs were deliberate. In one case I added an explicit return
    false for clarity instead of falling through a default case (that also
    would return false).
    
    libiberty/ChangeLog:
    
           * cplus-dem.c (demangle_signature): Move fall through comment.
           (demangle_fund_type): Add fall through comment between 'G' and 'I'.
           * hashtab.c (iterative_hash): Add fall through comments.
           * regex.c (regex_compile): Add Fall through comment after '+'/'?'.
           (byte_re_match_2_internal): Add Fall through comment after jump_n.
           Change "Note fall through" to "Fall through".
           (common_op_match_null_string_p): Return false after set_number_at
           instead of fall through.

commit ef0f5d7cc3b2082c94beffa7c9c1a8acd8eaa427
Author: Jason Merrill <jason@redhat.com>
Date:   Wed Nov 2 01:50:29 2016 +0000

    Implement P0136R1, Rewording inheriting constructors.
    
    libiberty/
    	* cp-demangle.c (d_ctor_dtor_name): Handle inheriting constructor.

commit aba19b625f34fb3d61263fe8044cf0c6d8804570
Author: Mark Wielaard <mjw@redhat.com>
Date:   Tue Nov 1 23:13:10 2016 +0000

    libiberty: Fix memory leak in ada_demangle when symbol cannot be demangled.
    
    When a symbol cannot be demangled in ada_demangle a new demangled VEC
    will be allocated without deleting the demangled VEC already in use.
    
    Running testsuite/test-demangle under valgrind will show the leak for
    this entry in testsuite/demangle-expected:
    
        # Elaborated flag (not demangled)
        --format=gnat
        x_E
        <x_E>
    
     11 bytes in 1 blocks are definitely lost in loss record 1 of 1
        at 0x4C27BE3: malloc (vg_replace_malloc.c:299)
        by 0x413FE7: xmalloc (xmalloc.c:148)
        by 0x4025EC: ada_demangle (cplus-dem.c:930)
        by 0x402C59: cplus_demangle (cplus-dem.c:892)
        by 0x400FEC: main (test-demangle.c:317)
    
    libiberty/ChangeLog:
    
    	* cplus-dem.c (ada_demangle): Initialize demangled to NULL and
    	XDELETEVEC demangled when unknown.

commit 9d2cdc86574bda0f1013be8cdc166d86b6d032bc
Author: Marcel Böhme <boehme.marcel@gmail.com>
Date:   Thu Aug 4 16:53:18 2016 +0000

    PR c++/71696 testcase.
    
    Add libiberty/testsuite/demangle-expected testcase for:
    
    	PR c++/71696
    	* cplus-dem.c: Prevent infinite recursion when there is a cycle
    	in the referencing of remembered mangled types.
    	(work_stuff): New stack to keep track of the remembered mangled
    	types that are currently being processed.
    	(push_processed_type): New method to push currently processed
    	remembered type onto the stack.
    	(pop_processed_type): New method to pop currently processed
    	remembered type from the stack.
    	(work_stuff_copy_to_from): Copy values of new variables.
    	(delete_non_B_K_work_stuff): Free stack memory.
    	(demangle_args): Push/Pop currently processed remembered type.
    	(do_type): Do not demangle a cyclic reference and push/pop
    	referenced remembered type.

commit c2c4ff8d52a2cd3263a547b0384692498714aa1b
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Fri Nov 18 10:02:16 2016 +0000

    [AArch64] Add ARMv8.3 FCMLA and FCADD instructions
    
    Add support for FCMLA and FCADD complex arithmetic SIMD instructions.
    FCMLA has an indexed element variant where the index range has to be
    treated specially because a complex number takes two elements and the
    indexed vector size depends on the other operands.
    
    These complex number SIMD instructions are part of ARMv8.3
    https://community.arm.com/groups/processors/blog/2016/10/27/armv8-a-architecture-2016-additions
    
    include/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* opcode/aarch64.h (enum aarch64_opnd): Add AARCH64_OPND_IMM_ROT1,
    	AARCH64_OPND_IMM_ROT2, AARCH64_OPND_IMM_ROT3.
    	(enum aarch64_op): Add OP_FCMLA_ELEM.
    
    opcodes/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* aarch64-tbl.h (QL_V3SAMEHSD_ROT, QL_ELEMENT_ROT): Define.
    	(aarch64_feature_simd_v8_3, SIMD_V8_3): Define.
    	(aarch64_opcode_table): Add fcmla and fcadd.
    	(AARCH64_OPERANDS): Add IMM_ROT{1,2,3}.
    	* aarch64-asm.h (aarch64_ins_imm_rotate): Declare.
    	* aarch64-asm.c (aarch64_ins_imm_rotate): Define.
    	* aarch64-dis.h (aarch64_ext_imm_rotate): Declare.
    	* aarch64-dis.c (aarch64_ext_imm_rotate): Define.
    	* aarch64-opc.h (enum aarch64_field_kind): Add FLD_rotate{1,2,3}.
    	* aarch64-opc.c (fields): Add FLD_rotate{1,2,3}.
    	(operand_general_constraint_met_p): Rotate and index range check.
    	(aarch64_print_operand): Handle rotate operand.
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis-2.c: Likewise.
    	* aarch64-opc-2.c: Likewise.
    
    gas/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* config/tc-aarch64.c (parse_operands): Handle AARCH64_OPND_IMM_ROT*.
    	* testsuite/gas/aarch64/advsimd-armv8_3.d: New.
    	* testsuite/gas/aarch64/advsimd-armv8_3.s: New.
    	* testsuite/gas/aarch64/illegal-fcmla.s: New.
    	* testsuite/gas/aarch64/illegal-fcmla.l: New.
    	* testsuite/gas/aarch64/illegal-fcmla.d: New.

commit 28617675c264213180a599bb4327bf162029636a
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Fri Nov 18 09:58:38 2016 +0000

    [AArch64] Add ARMv8.3 weaker release consistency load instructions
    
    Add support for ARMv8.3 LDAPRB, LDAPRH and LDAPR weak release
    consistency load instructions. (They are equivalent to LDARB,
    LDARH and LDAR instructions other than the weaker memory ordering
    requirement.)
    
    For more details about weak release consistency see
    https://community.arm.com/groups/processors/blog/2016/10/27/armv8-a-architecture-2016-additions
    
    opcodes/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* aarch64-tbl.h (arch64_opcode_table): Add ldaprb, ldaprh, ldapr.
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis-2.c: Regenerate.
    	* aarch64-opc-2.c: Regenerate.
    
    gas/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* testsuite/gas/aarch64/ldst-exclusive-armv8_3.s: Add ldaprb, ldaprh, ldapr tests.
    	* testsuite/gas/aarch64/ldst-exclusive-armv8_3.d: Likewise.
    	* testsuite/gas/aarch64/illegal-ldapr.s: Likewise.
    	* testsuite/gas/aarch64/illegal-ldapr.d: Likewise.
    	* testsuite/gas/aarch64/illegal-ldapr.l: Likewise.

commit ccfc90a39b78b7bc4173cd9ead49d2aa59695378
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Fri Nov 18 09:53:45 2016 +0000

    [AArch64] Add ARMv8.3 javascript floating-point conversion instruction
    
    Add support for ARMv8.3 FJCVTZS floating-point conversion
    instruction.
    
    For details about javascript floating-point conversion see
    https://community.arm.com/groups/processors/blog/2016/10/27/armv8-a-architecture-2016-additions
    
    opcodes/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* aarch64-tbl.h (arch64_opcode_table): Add fjcvtzs.
    	(QL_FP2INT_W_D, aarch64_feature_fp_v8_3, FP_V8_3): Define.
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis-2.c: Regenerate.
    	* aarch64-opc-2.c: Regenerate.
    
    gas/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* testsuite/gas/aarch64/fp-armv8_3.s: Add fjcvtzs test.
    	* testsuite/gas/aarch64/fp-armv8_3.d: Likewise.
    	* testsuite/gas/aarch64/illegal-fjcvtzs.s: Likewise.
    	* testsuite/gas/aarch64/illegal-fjcvtzs.d: Likewise.
    	* testsuite/gas/aarch64/illegal-fjcvtzs.l: Likewise.
    	* testsuite/gas/aarch64/illegal-nofp-armv8_3.s: Likewise.
    	* testsuite/gas/aarch64/illegal-nofp-armv8_3.d: Likewise.
    	* testsuite/gas/aarch64/illegal-nofp-armv8_3.l: Likewise.

commit 3f06e55061d0d8f72dfd11f6c432c23f45d9b597
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Fri Nov 18 09:49:06 2016 +0000

    [AArch64] Add ARMv8.3 combined pointer authentication load instructions
    
    Add support for ARMv8.3 LDRAA and LDRAB combined pointer authentication and
    load instructions.
    
    These instructions authenticate the base register and load 8 byte from it plus
    a scaled 10-bit offset with optional writeback to update the base register.
    
    A new instruction class (ldst_imm10) and operand type (AARCH64_OPND_ADDR_SIMM10)
    were introduced to handle the special addressing form.
    
    include/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* opcode/aarch64.h (enum aarch64_opnd): Add AARCH64_OPND_ADDR_SIMM10.
    	(enum aarch64_insn_class): Add ldst_imm10.
    
    opcodes/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* aarch64-tbl.h (QL_X1NIL): New.
    	(arch64_opcode_table): Add ldraa, ldrab.
    	(AARCH64_OPERANDS): Add "ADDR_SIMM10".
    	* aarch64-asm.h (aarch64_ins_addr_simm10): Declare.
    	* aarch64-asm.c (aarch64_ins_addr_simm10): Define.
    	* aarch64-dis.h (aarch64_ext_addr_simm10): Declare.
    	* aarch64-dis.c (aarch64_ext_addr_simm10): Define.
    	* aarch64-opc.h (enum aarch64_field_kind): Add FLD_S_simm10.
    	* aarch64-opc.c (fields): Add data for FLD_S_simm10.
    	(operand_general_constraint_met_p): Handle AARCH64_OPND_ADDR_SIMM10.
    	(aarch64_print_operand): Likewise.
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis-2.c: Regenerate.
    	* aarch64-opc-2.c: Regenerate.
    
    gas/
    2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
    
    	* config/tc-aarch64.c (parse_operands): Handle AARCH64_OPND_ADDR_SIMM10.
    	(fix_insn): Likewise.
    	(warn_unpredictable_ldst): Handle ldst_imm10.
    	* testsuite/gas/aarch64/pac.s: Add ldraa and ldrab tests.
    	* testsuite/gas/aarch64/pac.d: Likewise.
    	* testsuite/gas/aarch64/illegal-ldraa.s: New.
    	* testsuite/gas/aarch64/illegal-ldraa.l: New.
    	* testsuite/gas/aarch64/illegal-ldraa.d: New.

commit 6ec49e7c0aeb6d98e379319b565aee2c89388615
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Nov 18 09:27:41 2016 +0000

    Help diagnose problems with the metag target when mixing static and shared binaries.
    
    	PR ld/20675
    	* elf32-metag.c (elf_metag_relocate_section): Replace abort with
    	an informative error message.

commit cd42d70b4d7e92dcc6c533e012ab8af122de7b9e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Nov 18 00:00:20 2016 +0000

    Automatic date update in version.in

commit 470dd0a647c95a2e88c5b0f8df538826b08959a8
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Nov 17 12:02:32 2016 -0500

    Makefile: Replace explicit subdir rules with pattern rules
    
    When adding a .c file in subdirectory (e.g. mi/), the current practice
    is to add an explicit rule, such as:
    
      mi-cmd-break.o: $(srcdir)/mi/mi-cmd-break.c
              $(COMPILE) $(srcdir)/mi/mi-cmd-break.c
              $(POSTCOMPILE)
    
    I find it a bit verbose and cumbersome.  Since we now require GNU make,
    we can change those rules with pattern rules, one for each subdirectory.
    For example, the following rule works for all files under mi:
    
      %.o: $(srcdir)/mi/%.c
              $(COMPILE) $<
              $(POSTCOMPILE)
    
    Those pattern rules assume that the source and target files have the
    same stem (foo.c and foo.o).  In one case, common-agent.o is generated
    from common/agent.c, to avoid a conflict with the agent.o in gdb/.  In
    this case, I kept the explicit rule, which takes precedence over the
    pattern rule.  We could also rename common/agent.c to
    common/common-agent.c to get rid of the special case and still avoid the
    clash, as it is done with common/common-regcache.c, for example.
    
    This strategy was the least intrusive I found, as it only requires
    changing the rules, not the target names.
    
    I also considered two other solutions, which I did not like because I
    would have had to change target names a bit everywhere.
    
      - Replicate the source directory structure in the build directory,
        which would generate common/agent.o from common/agent.c.  However,
        something was not right with the dependency tracking (the .deps
        directory).  It's probably not hard to fix, but I did not
        investigate further.
      - Name the object files after the directory they are in, so that
        common/agent.c would generate common_agent.c.
    
    GDBserver can benefit from the same treatment, but I'll do it in another
    patch.
    
    Built-tested with --enable-targets=all.
    
    New in v2:
    
      - Regroup pattern rules for .c -> .o compilation in a single place.
      - Add comment about common-agent.o.
    
    gdb/ChangeLog:
    
    	(PYTHON_CFLAGS): Move up.
    	(%.o: $(srcdir)/arch/%.c): New rule.
    	(%.o: $(srcdir)/cli/%.c): New rule.
    	(%.o: $(srcdir)/common/%.c): New rule.
    	(%.o: $(srcdir)/compile/%.c): New rule.
    	(%.o: $(srcdir)/gdbtk/generic/%.c): New rule.
    	(%.o: $(srcdir)/guile/%.c): New rule.
    	(%.o: $(srcdir)/mi/%.c): New rule.
    	(%.o: $(srcdir)/nat/%.c): New rule.
    	(%.o: $(srcdir)/python/%.c): New rule.
    	(%.o: $(srcdir)/target/%.c): New rule.
    	(%.o: $(srcdir)/tui/%.c): New rule.
    	(cli-cmds.o): Remove.
    	(cli-decode.o): Likewise.
    	(cli-dump.o): Likewise.
    	(cli-interp.o): Likewise.
    	(cli-logging.o): Likewise.
    	(cli-script.o): Likewise.
    	(cli-setshow.o): Likewise.
    	(cli-utils.o): Likewise.
    	(compile.o): Likewise.
    	(compile-c-types.o): Likewise.
    	(compile-c-symbols.o): Likewise.
    	(compile-object-load.o): Likewise.
    	(compile-object-run.o): Likewise.
    	(compile-loc2c.o): Likewise.
    	(compile-c-support.o): Likewise.
    	(gdbtk.o): Likewise.
    	(gdbtk-bp.o): Likewise.
    	(gdbtk-cmds.o): Likewise.
    	(gdbtk-hooks.o): Likewise.
    	(gdbtk-interp.o): Likewise.
    	(gdbtk-main.o): Likewise.
    	(gdbtk-register.o): Likewise.
    	(gdbtk-stack.o): Likewise.
    	(gdbtk-varobj.o): Likewise.
    	(gdbtk-wrapper.o): Likewise.
    	(mi-cmd-break.o): Likewise.
    	(mi-cmd-catch.o): Likewise.
    	(mi-cmd-disas.o): Likewise.
    	(mi-cmd-env.o): Likewise.
    	(mi-cmd-file.o): Likewise.
    	(mi-cmd-info.o): Likewise.
    	(mi-cmds.o): Likewise.
    	(mi-cmd-stack.o): Likewise.
    	(mi-cmd-target.o): Likewise.
    	(mi-cmd-var.o): Likewise.
    	(mi-console.o): Likewise.
    	(mi-getopt.o): Likewise.
    	(mi-interp.o): Likewise.
    	(mi-main.o): Likewise.
    	(mi-out.o): Likewise.
    	(mi-parse.o): Likewise.
    	(mi-symbol-cmds.o): Likewise.
    	(mi-common.o): Likewise.
    	(signals.o): Likewise.
    	(common-utils.o): Likewise.
    	(gdb_vecs.o): Likewise.
    	(xml-utils.o): Likewise.
    	(ptid.o): Likewise.
    	(buffer.o): Likewise.
    	(filestuff.o): Likewise.
    	(format.o): Likewise.
    	(vec.o): Likewise.
    	(print-utils.o): Likewise.
    	(rsp-low.o): Likewise.
    	(errors.o): Likewise.
    	(common-debug.o): Likewise.
    	(cleanups.o): Likewise.
    	(common-exceptions.o
    	(posix-strerror.o): Likewise.
    	(mingw-strerror.o): Likewise.
    	(btrace-common.o): Likewise.
    	(fileio.o): Likewise.
    	(common-regcache.o): Likewise.
    	(signals-state-save-restore.o): Likewise.
    	(new-op.o): Likewise.
    	(waitstatus.o): Likewise.
    	(arm.o): Likewise.
    	(arm-linux.o): Likewise.
    	(arm-get-next-pcs.o): Likewise.
    	(x86-dregs.o): Likewise.
    	(linux-btrace.o): Likewise.
    	(linux-osdata.o): Likewise.
    	(linux-procfs.o): Likewise.
    	(linux-ptrace.o): Likewise.
    	(linux-waitpid.o): Likewise.
    	(mips-linux-watch.o): Likewise.
    	(ppc-linux.o): Likewise.
    	(linux-personality.o): Likewise.
    	(x86-linux.o): Likewise.
    	(x86-linux-dregs.o): Likewise.
    	(amd64-linux-siginfo.o): Likewise.
    	(linux-namespaces.o): Likewise.
    	(aarch64-linux-hw-point.o): Likewise.
    	(aarch64-linux.o): Likewise.
    	(aarch64-insn.o): Likewise.
    	(tui.o): Likewise.
    	(tui-command.o): Likewise.
    	(tui-data.o): Likewise.
    	(tui-disasm.o): Likewise.
    	(tui-file.o): Likewise.
    	(tui-hooks.o): Likewise.
    	(tui-interp.o): Likewise.
    	(tui-io.o): Likewise.
    	(tui-layout.o): Likewise.
    	(tui-out.o): Likewise.
    	(tui-regs.o): Likewise.
    	(tui-source.o): Likewise.
    	(tui-stack.o): Likewise.
    	(tui-win.o): Likewise.
    	(tui-windata.o): Likewise.
    	(tui-wingeneral.o): Likewise.
    	(tui-winsource.o): Likewise.
    	(guile.o): Likewise.
    	(scm-arch.o): Likewise.
    	(scm-auto-load.o): Likewise.
    	(scm-block.o): Likewise.
    	(scm-breakpoint.o): Likewise.
    	(scm-cmd.o): Likewise.
    	(scm-disasm.o): Likewise.
    	(scm-exception.o): Likewise.
    	(scm-frame.o): Likewise.
    	(scm-gsmob.o): Likewise.
    	(scm-iterator.o): Likewise.
    	(scm-lazy-string.o): Likewise.
    	(scm-math.o): Likewise.
    	(scm-objfile.o): Likewise.
    	(scm-param.o): Likewise.
    	(scm-ports.o): Likewise.
    	(scm-pretty-print.o): Likewise.
    	(scm-progspace.o): Likewise.
    	(scm-safe-call.o): Likewise.
    	(scm-string.o): Likewise.
    	(scm-symbol.o): Likewise.
    	(scm-symtab.o): Likewise.
    	(scm-type.o): Likewise.
    	(scm-utils.o): Likewise.
    	(scm-value.o): Likewise.
    	(python.o): Likewise.
    	(py-arch.o): Likewise.
    	(py-auto-load.o): Likewise.
    	(py-block.o): Likewise.
    	(py-bpevent.o): Likewise.
    	(py-breakpoint.o): Likewise.
    	(py-cmd.o): Likewise.
    	(py-continueevent.o): Likewise.
    	(py-xmethods.o): Likewise.
    	(py-event.o): Likewise.
    	(py-evtregistry.o): Likewise.
    	(py-evts.o): Likewise.
    	(py-exitedevent.o): Likewise.
    	(py-finishbreakpoint.o): Likewise.
    	(py-frame.o): Likewise.
    	(py-framefilter.o): Likewise.
    	(py-function.o): Likewise.
    	(py-gdb-readline.o): Likewise.
    	(py-inferior.o): Likewise.
    	(py-infevents.o): Likewise.
    	(py-infthread.o): Likewise.
    	(py-lazy-string.o): Likewise.
    	(py-linetable.o): Likewise.
    	(py-newobjfileevent.o): Likewise.
    	(py-objfile.o): Likewise.
    	(py-param.o): Likewise.
    	(py-prettyprint.o): Likewise.
    	(py-progspace.o): Likewise.
    	(py-signalevent.o): Likewise.
    	(py-stopevent.o): Likewise.
    	(py-symbol.o): Likewise.
    	(py-symtab.o): Likewise.
    	(py-threadevent.o): Likewise.
    	(py-type.o): Likewise.
    	(py-unwind.o): Likewise.
    	(py-utils.o): Likewise.
    	(py-value.o): Likewise.
    	(py-varobj.o): Likewise.

commit 5443506ee45cb94769db7e76dd2021a96f2f0680
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Nov 17 12:02:13 2016 -0500

    Makefile: Replace old suffix rules with pattern rules
    
    As mentioned here [1], suffix rules are obsolete and have been
    superseeded with pattern rules.  People (myself included, before writing
    this patch) are more likely to know what pattern rules are than suffix
    rules.
    
    AFAIK, .SUFFIXES targets are only used for those rules, and can be
    removed as well.
    
    New in v2:
    
      - Replace rule in gdbserver/Makefile.in as well.
    
    [1] https://www.gnu.org/software/make/manual/html_node/Suffix-Rules.html
    
    gdb/ChangeLog:
    
    	* Makefile.in (.c.o): Replace rule with ...
    	(%.o: %.c): ... this one.
    	(.po.gmo): Replace rule with ...
    	(%.gmo: %.po): ... this one.
    	(.po.pox): Replace rule with ...
    	(%.pox: %.po): ... this one.
    	(.y.c): Replace rule with ...
    	(%.c: %.y): ... this one.
    	(.l.c): Replace rule with ...
    	(%.c: %.l): ... this one.
    	(.SUFFIXES): Remove all instances.
    
    gdb/gdbserver/ChangeLog:
    
    	* Makefile.in (.c.o): Replace rule with ...
    	(%.o: %.c): ... this one.

commit 3b165252e882c05c8217f888194877224295592d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Nov 17 12:00:10 2016 -0500

    Remove code that checks for GNU/non-GNU make
    
    Since GNU make is now required to build GDB, we can remove everything
    that checks whether the current make implemention is the GNU one or
    not.  I simply removed the @GMAKE_TRUE@ prefixes and removed the whole
    lines that were prefixed with @GMAKE_FALSE@.
    
    I removed the code in the configure scripts that set those variables.
    
    I also removed the following bits from the configure scripts:
    
      AC_CHECK_PROGS(MAKE, make): GNU make already defines a MAKE variable
        internally to be used when invoking Makefiles recursively.  I don't see
        this variable being used anywhere else (in scripts for example), so I
        think it's safe for removal.
    
      AC_PROG_MAKE_SET: This macro defines a SET_MAKE output variable, which
        is meant to be used in Makefiles to define the MAKE variable when
        using an implementation of make that doesn't already define it.
        Since we are now requiring GNU make, we don't need it anymore.
        Plus, I don't see SET_MAKE being used anywhere, so I don't think it
        was actually doing anything...
    
    gdb/ChangeLog:
    
    	* Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
    	prefixed with @GMAKE_FALSE@.  Update comment related to non-GNU
    	make.
    	* configure.ac: Remove checks for the make program.
    	* configure: Re-generate.
    
    gdb/gdbserver/ChangeLog:
    
    	* Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
    	prefixed with @GMAKE_FALSE@.  Update comment related to non-GNU
    	make.
    	* configure.ac: Remove checks for the make program.
    	* configure: Re-generate.
    
    gdb/testsuite/ChangeLog:
    
    	* Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
    	prefixed with @GMAKE_FALSE@.  Update comment related to non-GNU
    	make.
    	* configure.ac: Remove checks for the make program.
    	* configure: Re-generate.

commit f2ff9acd32b4667ee16a03ca8d10fd8b99e22f46
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Nov 17 11:59:18 2016 -0500

    Document new hard requirement on GNU make
    
    As discussed in [1], it would be benificial for the GDB project to start
    requiring GNU make to build its software.  It would allow using useful
    GNU-specific constructs, such as pattern rules.  It would also allow
    removing the alternative code paths in the Makefiles (guarded by
    GMAKE_TRUE/GMAKE_FALSE), simplifying the Makefile code.
    
    [1] https://sourceware.org/ml/gdb-patches/2016-11/msg00331.html
    
    gdb/ChangeLog:
    
    	* NEWS: Mention requirement of GNU make.

commit 66be918f5f9f78d74c70aa332756286ff9d0ccf2
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 17 14:53:02 2016 +0000

    gdb/c-exp.y: fprintf -> parser_fprintf
    
    Switching GDB to make use of gnulib's C++ namespace support mode
    revealed these direct uses of fprintf in the C parser, where
    parser_fprintf should be used to handle rewiring stderr to gdb_stderr:
    
     ..../src/gdb/c-exp.y: In function ‘void c_print_token(FILE*, int, YYSTYPE)’:
     ..../src/gdb/c-exp.y:3220:45: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
    	  pulongest (value.typed_val_int.val));
    					      ^
     ..../src/gdb/c-exp.y:3231:62: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
       fprintf (file, "tsval<type=%d, %s>", value.tsval.type, copy);
    							       ^
     ..../src/gdb/c-exp.y:3237:57: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
    	fprintf (file, "sval<%s>", copy_name (value.sval));
    							  ^
     ..../src/gdb/c-exp.y:3243:39: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
    	  copy_name (value.tsym.stoken));
    					^
     ..../src/gdb/c-exp.y:3254:39: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
    	  value.ssym.is_a_field_of_this);
    					^
     ..../src/gdb/c-exp.y:3258:70: error: call to ‘fprintf’ declared with attribute warning: The symbol ::fprintf refers to the system function. Use gnulib::fprintf instead. [-Werror]
    	fprintf (file, "bval<%s>", host_address_to_string (value.bval));
                                                                          ^
    
    gdb/ChangeLog:
    2016-11-17  Pedro Alves  <palves@redhat.com>
    
    	* c-exp.y (c_print_token): Use parser_fprintf instead of fprintf.

commit 7c2683c40f745397e80b6df4edf8265ecb6fd194
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 17 14:43:02 2016 +0000

    gdb/ctf.c: Get rid of mkdir redefinition
    
    Making GDB use gnulib's C++ namespace support shows this build error
    on mingw:
    
     ../../src/gdb/ctf.c: In function 'void ctf_start(trace_file_writer*, const char*)':
     ../../src/gdb/ctf.c:309:46: error: no match for call to '(const gnulib::_gl_mkdir_wrapper) (const char*&)'
      #define mkdir(pathname, mode) mkdir (pathname)
    					       ^
     ../../src/gdb/ctf.c:327:15: note: in expansion of macro 'mkdir'
        if (gnulib::mkdir (dirname, hmode) && errno != EEXIST)
    		^
     ../../src/gdb/ctf.c:309:46: note: candidate: gnulib::_gl_mkdir_wrapper::type {aka int (*)(const char*, short unsigned int)} <conversion>
      #define mkdir(pathname, mode) mkdir (pathname)
    					       ^
     ../../src/gdb/ctf.c:327:15: note: in expansion of macro 'mkdir'
        if (gnulib::mkdir (dirname, hmode) && errno != EEXIST)
    		^
     ../../src/gdb/ctf.c:309:46: note:   candidate expects 3 arguments, 2 provided
      #define mkdir(pathname, mode) mkdir (pathname)
    					       ^
     ../../src/gdb/ctf.c:327:15: note: in expansion of macro 'mkdir'
        if (gnulib::mkdir (dirname, hmode) && errno != EEXIST)
    		^
    
    The problem is the '#define mkdir ...'
    
    Fortunately, we can just remove it, since gnulib's sys/stat.h
    replacement already takes care of the Windows mkdir prototype quirk:
    
    ~~~
     /* mingw's _mkdir() function has 1 argument, but we pass 2 arguments.
        Additionally, it declares _mkdir (and depending on compile flags, an
        alias mkdir), only in the nonstandard includes <direct.h> and <io.h>,
        which are included above.  */
     # if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
    
     #  if !GNULIB_defined_rpl_mkdir
     static int
     rpl_mkdir (char const *name, mode_t mode)
     {
       return _mkdir (name);
     }
    ~~~
    
    That's sys_stat.in.h, part of the sys_stat module, which we explictly
    pull in nowadays.  It wasn't being pulled when this macro was added:
    
      https://sourceware.org/ml/gdb-patches/2013-03/msg00736.html
    
    That patch was partially reverted meanwhile here:
    
      https://sourceware.org/ml/gdb-patches/2013-12/msg00023.html
    
    But the mkdir macro had been left behind unnoticed.
    
    gdb/ChangeLog:
    2016-11-17  Pedro Alves  <palves@redhat.com>
    
    	* ctf.c [USE_WIN32API] (mkdir): Delete.

commit 200069c74f42ffcc726b9995a46971a86286a256
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 16 11:38:49 2016 +0000

    gdb/ada-lang.c: one malloc -> unique_ptr<[]>
    
    Switching gdb to use gnulib's C++ namespace mode reveals we're calling
    malloc instead of xmalloc here:
    
     ..../src/gdb/ada-lang.c: In function ‘value* ada_value_primitive_packed_val(value*, const gdb_byte*, long int, int, int, type*)’:
     ..../src/gdb/ada-lang.c:2592:50: error: call to ‘malloc’ declared with attribute warning: The symbol ::malloc refers to the system function. Use gnulib::malloc instead. [-Werror]
    	staging = (gdb_byte *) malloc (staging_len);
    						   ^
    
    We're unconditionaly using the result afterwards -- so it's not a case
    of gracefully handling huge allocations.
    
    Since we want to get rid of all cleanups, fix this by switching to
    new[] and unique_ptr<[]> instead, while at it.
    
    Regtested on Fedora 23.
    
    gdb/ChangeLog:
    2016-11-16  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_value_primitive_packed_val): Use unique_ptr and
    	new gdb_byte[] instead of malloc and cleanups.

commit 19f1935d91bfabbe4176ffdaca95bc789b593153
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 17 00:23:17 2016 +0000

    gdb/tracepoint.c: Don't use printf_vma
    
    I noticed that bfd's printf_vma prints to stdout directly:
    
      bfd-in2.h:202:#define printf_vma(x) fprintf_vma(stdout,x)
    
    This is a bad idea in gdb, where we should use
    gdb_stdout/gdb_stderr/gdb_stdlog, etc., to support redirection.
    
    Eliminate uses of sprintf_vma too while at it.
    
    Tested on Fedora 23, w/ gdbserver.
    
    gdb/ChangeLog:
    2016-11-17  Pedro Alves  <palves@redhat.com>
    
    	* tracepoint.c (collection_list::add_memrange): Add gdbarch
    	parameter.  Use paddress instead of printf_vma.  Adjust recursive
    	calls.
    	(collection_list::stringify): Use paddress and phex_nz instead of
    	sprintf_vma.  Adjust add_memrange call.
    	* tracepoint.h (collection_list::add_memrange): Add gdbarch
    	parameter.

commit fa98319231a95aca0313878443143d3f92aca5e1
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 17 00:00:19 2016 +0000

    Automatic date update in version.in

commit 256ae5dbc73d1348850f86ee77a0dc3b04bc7cc0
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Mon Oct 31 12:47:42 2016 -0700

    Stash frame id of current frame before stashing frame id for previous frame
    
    This patch ensures that the frame id for the current frame is stashed
    before that of the previous frame (to the current frame).
    
    First, it should be noted that the frame id for the current frame is
    not stashed by get_current_frame().  The current frame's frame id is
    lazily computed and stashed via calls to get_frame_id().  However,
    it's possible for get_prev_frame() to be called without first stashing
    the current frame.
    
    The frame stash is used not only to speed up frame lookups, but
    also to detect cycles.  When attempting to compute the frame id
    for a "previous" frame (in get_prev_frame_if_no_cycle), a cycle
    is detected if the computed frame id is already in the stash.
    
    If it should happen that a previous frame id is stashed which should
    represent a cycle for the current frame, then an assertion failure
    will trigger should get_frame_id() be later called to determine
    the frame id for the current frame.
    
    As of late 2016, with the "Tweak meaning of VALUE_FRAME_ID" patch in
    place, this actually occurs when running the
    gdb.dwarf2/dw2-dup-frame.exp test.  While attempting to generate a
    backtrace, the python frame filter code is invoked, leading to
    frame_info_to_frame_object() (in python/py-frame.c) being called.
    That function will potentially call get_prev_frame() before
    get_frame_id() is called.  The call to get_prev_frame() can eventually
    end up in get_prev_frame_if_no_cycle() which, in turn, calls
    compute_frame_id(), after which the frame id is stashed for the
    previous frame.
    
    If the frame id for the current frame is stashed, the cycle detection
    code (which relies on the frame stash) in get_prev_frame_if_no_cycle()
    will be triggered for a cycle starting with the current frame.  If the
    current frame's id is not stashed, the cycle detecting code can't
    operate as designed.  Instead, when get_frame_id() is called on the
    current frame at some later point, the current frame's id will found
    to be already in the stash, triggering an assertion failure.
    
    Below is an in depth examination of the failure which lead to this change.
    I've shortened pathnames for brevity and readability.
    
    Here's the portion of the log file showing the failure/internal error:
    
    (gdb) break stop_frame
    Breakpoint 1 at 0x40059a: file dw2-dup-frame.c, line 22.
    (gdb) run
    Starting program: testsuite/outputs/gdb.dwarf2/dw2-dup-frame/dw2-dup-frame
    
    Breakpoint 1, stop_frame () at dw2-dup-frame.c:22
    22	}
    (gdb) bt
    gdb/frame.c:544: internal-error: frame_id get_frame_id(frame_info*): Assertion `stashed' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n)
    FAIL: gdb.dwarf2/dw2-dup-frame.exp: backtrace from stop_frame (GDB internal error)
    
    Here's a partial backtrace from the internal error, showing the frames
    which I think are relevant, plus several extra to provide context:
    
        #0  internal_error (
    	file=0x932b98 "gdb/frame.c", line=544,
    	fmt=0x932b20 "%s: Assertion `%s' failed.")
    	at gdb/common/errors.c:54
        #1  0x000000000072207e in get_frame_id (fi=0xe5a760)
    	at gdb/frame.c:544
        #2  0x00000000004eb50d in frame_info_to_frame_object (frame=0xe5a760)
    	at gdb/python/py-frame.c:390
        #3  0x00000000004ef5be in bootstrap_python_frame_filters (frame=0xe5a760,
    	frame_low=0, frame_high=-1)
    	at gdb/python/py-framefilter.c:1453
        #4  0x00000000004ef7a9 in gdbpy_apply_frame_filter (
    	extlang=0x8857e0 <extension_language_python>, frame=0xe5a760, flags=7,
    	args_type=CLI_SCALAR_VALUES, out=0xf6def0, frame_low=0, frame_high=-1)
    	at gdb/python/py-framefilter.c:1548
        #5  0x00000000005f2c5a in apply_ext_lang_frame_filter (frame=0xe5a760,
    	flags=7, args_type=CLI_SCALAR_VALUES, out=0xf6def0, frame_low=0,
    	frame_high=-1)
    	at gdb/extension.c:572
        #6  0x00000000005ea896 in backtrace_command_1 (count_exp=0x0, show_locals=0,
    	no_filters=0, from_tty=1)
    	at gdb/stack.c:1834
    
    Examination of the code in frame_info_to_frame_object(), which is in
    python/py-frame.c, is key to understanding this problem:
    
          if (get_prev_frame (frame) == NULL
    	  && get_frame_unwind_stop_reason (frame) != UNWIND_NO_REASON
    	  && get_next_frame (frame) != NULL)
    	{
    	  frame_obj->frame_id = get_frame_id (get_next_frame (frame));
    	  frame_obj->frame_id_is_next = 1;
    	}
          else
    	{
    	  frame_obj->frame_id = get_frame_id (frame);
    	  frame_obj->frame_id_is_next = 0;
    	}
    
    I will first note that the frame id for frame has not been computed yet.  (This
    was verified by placing a breakpoint on compute_frame_id().)
    
    The call to get_prev_frame() causes the the frame id to (eventually) be
    computed for the previous frame.  Here's a backtrace showing how we
    get there:
    
        #0  compute_frame_id (fi=0x10e2810)
    	at gdb/frame.c:496
        #1  0x0000000000724a67 in get_prev_frame_if_no_cycle (this_frame=0xe5a760)
    	at gdb/frame.c:1871
        #2  0x0000000000725136 in get_prev_frame_always_1 (this_frame=0xe5a760)
    	at gdb/frame.c:2045
        #3  0x000000000072516b in get_prev_frame_always (this_frame=0xe5a760)
    	at gdb/frame.c:2061
        #4  0x000000000072570f in get_prev_frame (this_frame=0xe5a760)
    	at gdb/frame.c:2303
        #5  0x00000000004eb471 in frame_info_to_frame_object (frame=0xe5a760)
    	at gdb/python/py-frame.c:381
    
    For this particular case, we end up in the else clause of the code above
    which calls get_frame_id (frame).  It's at this point that the frame id
    for frame is computed.  Again, here's a backtrace:
    
        #0  compute_frame_id (fi=0xe5a760)
    	at gdb/frame.c:496
        #1  0x000000000072203d in get_frame_id (fi=0xe5a760)
    	at gdb/frame.c:539
        #2  0x00000000004eb50d in frame_info_to_frame_object (frame=0xe5a760)
    	at gdb/python/py-frame.c:390
    
    The test in question, dw2-dup-frame.exp, deliberately creates a broken
    (cyclic) stack.  So, in this instance, the frame id for the prev
    `frame' will be the same as that for `frame'.  But that particular
    frame id ended up in the stash during the previous frame operation.
    When, just a few lines later, we compute the frame id for `frame', the
    id in question is already in the stash, thus triggering the assertion
    failure.
    
    I considered two other solutions to solving this problem:
    
    We could prevent get_prev_frame() from being called before
    get_frame_id() in frame_info_to_frame_object().  (See above for the
    snippet of code where this happens.) A call to get_frame_id (frame)
    could be placed ahead of that code snippet above.  I have tested this
    approach and, while it does work, I can't be certain that
    get_prev_frame() isn't called ahead of stashing the current frame
    somewhere else in GDB, but in a less obvious way.
    
    Another approach is to stash the current frame's id by calling
    get_frame_id() in get_current_frame().  This approach is conceptually
    simpler, but when importing a python unwinder, has the unwelcome side
    effect of causing the unwinder to be called during import.
    
    A cleaner looking fix would be to place this code after code
    corresponding to the "Don't compute the frame id of the current frame
    yet..." comment in get_prev_frame_if_no_cycle().  Sadly, this does not
    work though; by the time we get to this point, the frame state for the
    prev frame has been modified just enough to cause an internal error to
    occur when attempting to compute the (current) frame id for inline
    frames.  (The unexpected failure count increases by roughly 130
    failures.)  Therefore, I decided to place it as early as possible
    in get_prev_frame().
    
    gdb/ChangeLog:
    
    	* frame.c (get_prev_frame): Stash frame id for current frame
    	prior to computing frame id for previous frame.

commit 33cc7d368f420326606695daafd6292e2779c6af
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Sep 27 22:45:19 2016 -0700

    Make gdb.PendingFrame.read_register handle "user" registers.
    
    The C function, pending_framepy_read_register(), which implements
    the python interface gdb.PendingFrame.read_register does not handle
    the so called "user" registers like "pc".  An assertion error is
    triggered due to the user registers having numbers larger than or
    equal to gdbarch_num_regs(gdbarch).
    
    With the VALUE_FRAME_ID tweak in place, the call to
    get_frame_register_value() can simply be replaced by a call to
    value_of_register(), which handles both real registers as well as the
    user registers.
    
    gdb/ChangeLog:
    
    	* python/py-unwind.c (pending_framepy_read_register): Use
    	value_of_register() instead of get_frame_register_value().

commit 41b56feb5063aee4fefb4a991eb796d1e8a7475e
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Sep 27 21:18:44 2016 -0700

    Change meaning of VALUE_FRAME_ID; rename to VALUE_NEXT_FRAME_ID
    
    The VALUE_FRAME_ID macro provides access to a member in struct value
    that's used to hold the frame id that's used when determining a
    register's value or when assigning to a register.  The underlying
    member has a long and obscure name.  I won't refer to it here, but
    will simply refer to VALUE_FRAME_ID as if it's the struct value member
    instead of being a convenient macro.
    
    At the moment, without this patch in place, VALUE_FRAME_ID is set in
    value_of_register_lazy() and several other locations to hold the frame
    id of the frame passed to those functions.
    
    VALUE_FRAME_ID is used in the lval_register case of
    value_fetch_lazy().  To fetch the register's value, it calls
    get_frame_register_value() which, in turn, calls
    frame_unwind_register_value() with frame->next.
    
    A python based unwinder may wish to determine the value of a register
    or evaluate an expression containing a register.  When it does this,
    value_fetch_lazy() will be called under some circumstances.  It will
    attempt to determine the frame id associated with the frame passed to
    it.  In so doing, it will end up back in the frame sniffer of the very
    same python unwinder that's attempting to learn the value of a
    register as part of the sniffing operation.  This recursion is not
    desirable.
    
    As noted above, when value_fetch_lazy() wants to fetch a register's
    value, it does so (indirectly) by unwinding from frame->next.
    
    With this in mind, a solution suggests itself:  Change VALUE_FRAME_ID
    to hold the frame id associated with the next frame.  Then, when it
    comes time to obtain the value associated with the register, we can
    simply unwind from the frame corresponding to the frame id stored in
    VALUE_FRAME_ID.  This neatly avoids the python unwinder recursion
    problem by changing when the "next" operation occurs.  Instead of the
    "next" operation occuring when the register value is fetched, it
    occurs earlier on when assigning a frame id to VALUE_FRAME_ID.
    (Thanks to Pedro for this suggestion.)
    
    This patch implements this idea.
    
    It builds on the patch "Distinguish sentinel frame from null frame".
    Without that work in place, it's necessary to check for null_id at
    several places and then obtain the sentinel frame.
    
    It also renames most occurences of VALUE_FRAME_ID to
    VALUE_NEXT_FRAME_ID to reflect the new meaning of this field.
    
    There are several uses of VALUE_FRAME_ID which were not changed.  In
    each case, the original meaning of VALUE_FRAME_ID is required to get
    correct results.  In all but one of these uses, either
    put_frame_register_bytes() or get_frame_register_bytes() is being
    called with the frame value obtained from VALUE_FRAME_ID.  Both of
    these functions perform some unwinding by performing a "->next"
    operation on the frame passed to it.  If we were to use the new
    VALUE_NEXT_FRAME_ID macro, this would effectively do two "->next"
    operations, which is not what we want.
    
    The VALUE_FRAME_ID macro has been redefined in terms of
    VALUE_NEXT_FRAME_ID.  It simply fetches the previous frame's id,
    providing this id as the value of the macro.
    
    gdb/ChangeLog:
    
    	* value.h (VALUE_FRAME_ID): Rename to VALUE_NEXT_FRAME_ID. Update
    	comment.  Create new VALUE_FRAME_ID which is defined in terms of
    	VALUE_NEXT_FRAME_ID.
    	(deprecated_value_frame_id_hack): Rename to
    	deprecated_value_next_frame_id_hack.
    	* dwarf2loc.c, findvar.c, frame-unwind.c, sentinel-frame.c,
    	valarith.c, valops.c, value.c: Adjust nearly all occurences of
    	VALUE_FRAME_ID to VALUE_NEXT_FRAME_ID.	Add comments for those
    	which did not change.
    	* value.c (struct value): Rename frame_id field to next_frame_id.
    	Update comment.
    	(deprecated_value_frame_id_hack): Rename to
    	deprecated_value_next_frame_id_hack.
    	(value_fetch_lazy): Call frame_unwind_register_value()
    	instead of get_frame_register_value().
    	* frame.c (get_prev_frame_id_by_id): New function.
    	* frame.h (get_prev_frame_id_by_id): Declare.
    	* dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Make
    	VALUE_NEXT_FRAME_ID refer to the next frame.
    	* findvar.c (value_of_register_lazy): Likewise.
    	(default_value_from_register): Likewise.
    	(value_from_register): Likewise.
    	* frame_unwind.c (frame_unwind_got_optimized): Likewise.
    	* sentinel-frame.c (sentinel_frame_prev_register): Likewise.
    	* value.h (VALUE_FRAME_ID): Update comment describing this macro.

commit df433d316277ff5293832d3cd6cbc30b5c38dec0
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Sep 27 20:33:38 2016 -0700

    Distinguish sentinel frame from null frame.
    
    This patch replaces the `current_frame' static global in frame.c with
    `sentinel_frame'.  It also makes the sentinel frame id unique and
    different from the null frame.
    
    By itself, there is not much point to this patch, but it makes
    the code cleaner for the VALUE_FRAME_ID changes in another patch.
    Since we now allow "navigation" to the sentinel frame, it removes
    the necessity of adding special cases to other parts of GDB.
    
    Note that a new function, get_next_frame_sentinel_okay, is introduced
    in this patch.  It will be used by the VALUE_FRAME_ID changes that
    I've made.
    
    Thanks to Pedro Alves for this suggestion.
    
    gdb/ChangeLog:
    
        	* frame.h (enum frame_id_stack_status): Add FID_STACK_SENTINEL.
        	(struct frame_id): Increase number of bits required for storing
        	stack status to 3 from 2.
        	(sentinel_frame_id): New declaration.
        	(get_next_frame_sentinel_okay): Declare.
        	(frame_find_by_id_sentinel_okay): Declare.
        	* frame.c (current_frame): Rename this static global to...
        	(sentinel_frame): ...this static global, which has also been
        	moved an earlier location in the file.
        	(fprint_frame_id): Add case for sentinel frame id.
        	(get_frame_id): Return early for sentinel frame.
        	(sentinel_frame_id): Define.
        	(frame_find_by_id): Add case for sentinel_frame_id.
        	(create_sentinel_frame): Use sentinel_frame_id for this_id.value
        	instead of null_frame_id.
        	(get_current_frame): Add local declaration for `current_frame'.
        	Remove local declaration for `sentinel_frame.'
        	(get_next_frame_sentinel_okay): New function.
        	(reinit_frame_cache): Use `sentinel_frame' in place of
        	`current_frame'.

commit 1a2f3d7ff1d79b1290704e48c71e905b987393a6
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Mon Sep 26 15:00:37 2016 -0700

    Extend test gdb.python/py-recurse-unwind.exp
    
    This patch modifies the unwinder (sniffer) defined in
    py-recurse-unwind.py so that, depending upon the value of one of its
    class variables, it will take different paths through the code,
    testing different functionality.
    
    The original test attempted to obtain the value of an undefined
    symbol.
    
    This somewhat expanded test checks to see if 'pc' can be read via
    gdb.PendingFrame.read_register() and also via gdb.parse_and_eval().
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-recurse-unwind.c (main): Add loop.
    	* gdb.python/py-recurse-unwind.py (TestUnwinder): Add calls
    	to read_register() and gdb.parse_and_eval().  Make each code
    	call a separate case that can be individually tested.
    	* gdb.python/py-recurse-unwind.exp (cont_and_backtrace): New
    	proc. Call cont_and_backtrace for each of the code paths that
    	we want to test in the unwinder.

-----------------------------------------------------------------------

Summary of changes:
 bfd/ChangeLog                                      |   14 +
 bfd/elf32-metag.c                                  |   11 +-
 bfd/elfxx-sparc.c                                  |   22 +-
 bfd/version.h                                      |    2 +-
 binutils/ChangeLog                                 |    4 +
 binutils/cxxfilt.c                                 |    1 +
 gas/ChangeLog                                      |   56 +
 gas/config/tc-aarch64.c                            |   24 +
 gas/config/tc-arc.c                                |   77 +-
 gas/testsuite/gas/aarch64/advsimd-armv8_3.d        |   33 +
 gas/testsuite/gas/aarch64/advsimd-armv8_3.s        |   36 +
 gas/testsuite/gas/aarch64/fp-armv8_3.d             |   10 +
 gas/testsuite/gas/aarch64/fp-armv8_3.s             |    5 +
 gas/testsuite/gas/aarch64/illegal-fcmla.d          |    2 +
 gas/testsuite/gas/aarch64/illegal-fcmla.l          |   17 +
 gas/testsuite/gas/aarch64/illegal-fcmla.s          |   25 +
 gas/testsuite/gas/aarch64/illegal-fjcvtzs.d        |    2 +
 gas/testsuite/gas/aarch64/illegal-fjcvtzs.l        |    8 +
 gas/testsuite/gas/aarch64/illegal-fjcvtzs.s        |   14 +
 gas/testsuite/gas/aarch64/illegal-ldapr.d          |    2 +
 gas/testsuite/gas/aarch64/illegal-ldapr.l          |   16 +
 gas/testsuite/gas/aarch64/illegal-ldapr.s          |   25 +
 gas/testsuite/gas/aarch64/illegal-ldraa.d          |    2 +
 gas/testsuite/gas/aarch64/illegal-ldraa.l          |   35 +
 gas/testsuite/gas/aarch64/illegal-ldraa.s          |   44 +
 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.d   |    2 +
 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.l   |    3 +
 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.s   |    6 +
 gas/testsuite/gas/aarch64/ldst-exclusive-armv8_3.d |   20 +
 gas/testsuite/gas/aarch64/ldst-exclusive-armv8_3.s |   22 +
 gas/testsuite/gas/aarch64/pac.d                    |   22 +
 gas/testsuite/gas/aarch64/pac.s                    |   23 +
 gas/testsuite/gas/arc/cl-warn.s                    |    5 +
 gas/testsuite/gas/arc/cpu-pseudop-1.d              |   12 +
 gas/testsuite/gas/arc/cpu-pseudop-1.s              |    6 +
 gas/testsuite/gas/arc/cpu-pseudop-2.d              |   11 +
 gas/testsuite/gas/arc/cpu-pseudop-2.s              |    5 +
 gas/testsuite/gas/arc/cpu-warn2.s                  |    4 +
 gdb/ChangeLog                                      |  290 ++
 gdb/Makefile.in                                    |  835 +----
 gdb/NEWS                                           |    5 +
 gdb/ada-lang.c                                     |   14 +-
 gdb/c-exp.y                                        |   28 +-
 gdb/configure                                      |   97 -
 gdb/configure.ac                                   |   11 -
 gdb/ctf.c                                          |    5 -
 gdb/doc/ChangeLog                                  |    5 +
 gdb/doc/gdb.texinfo                                |    2 +-
 gdb/dwarf2loc.c                                    |   21 +-
 gdb/findvar.c                                      |   26 +-
 gdb/frame-unwind.c                                 |    3 +-
 gdb/frame.c                                        |  121 +-
 gdb/frame.h                                        |   16 +-
 gdb/gdbserver/ChangeLog                            |   13 +
 gdb/gdbserver/Makefile.in                          |   36 +-
 gdb/gdbserver/configure                            |   97 -
 gdb/gdbserver/configure.ac                         |   11 -
 gdb/python/py-unwind.c                             |    7 +-
 gdb/sentinel-frame.c                               |    2 +-
 gdb/testsuite/ChangeLog                            |   18 +
 gdb/testsuite/Makefile.in                          |   88 +-
 gdb/testsuite/configure                            |   99 -
 gdb/testsuite/configure.ac                         |   11 -
 gdb/testsuite/gdb.python/py-recurse-unwind.c       |    6 +-
 gdb/testsuite/gdb.python/py-recurse-unwind.exp     |   63 +-
 gdb/testsuite/gdb.python/py-recurse-unwind.py      |   29 +-
 gdb/tracepoint.c                                   |   60 +-
 gdb/tracepoint.h                                   |    3 +-
 gdb/valarith.c                                     |    2 +-
 gdb/valops.c                                       |   13 +-
 gdb/value.c                                        |   47 +-
 gdb/value.h                                        |   16 +-
 include/ChangeLog                                  |   28 +
 include/demangle.h                                 |   33 +-
 include/opcode/aarch64.h                           |    7 +
 libiberty/ChangeLog                                |   66 +
 libiberty/Makefile.in                              |   13 +
 libiberty/configure                                |    3 +-
 libiberty/configure.ac                             |    3 +-
 libiberty/cp-demangle.c                            |  197 +-
 libiberty/cplus-dem.c                              |   69 +-
 libiberty/hashtab.c                                |   20 +-
 libiberty/regex.c                                  |    8 +-
 libiberty/rust-demangle.c                          |  348 ++
 libiberty/testsuite/Makefile.in                    |    7 +-
 libiberty/testsuite/demangle-expected              |   47 +
 libiberty/testsuite/rust-demangle-expected         |  161 +
 opcodes/ChangeLog                                  |   50 +
 opcodes/aarch64-asm-2.c                            | 1038 +++---
 opcodes/aarch64-asm.c                              |   74 +-
 opcodes/aarch64-asm.h                              |    2 +
 opcodes/aarch64-dis-2.c                            | 4551 ++++++++++----------
 opcodes/aarch64-dis.c                              |   63 +
 opcodes/aarch64-dis.h                              |    2 +
 opcodes/aarch64-opc-2.c                            |  117 +-
 opcodes/aarch64-opc.c                              |   64 +-
 opcodes/aarch64-opc.h                              |    4 +
 opcodes/aarch64-tbl.h                              |   54 +
 98 files changed, 5515 insertions(+), 4242 deletions(-)
 create mode 100644 gas/testsuite/gas/aarch64/advsimd-armv8_3.d
 create mode 100644 gas/testsuite/gas/aarch64/advsimd-armv8_3.s
 create mode 100644 gas/testsuite/gas/aarch64/fp-armv8_3.d
 create mode 100644 gas/testsuite/gas/aarch64/fp-armv8_3.s
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fcmla.d
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fcmla.l
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fcmla.s
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fjcvtzs.d
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fjcvtzs.l
 create mode 100644 gas/testsuite/gas/aarch64/illegal-fjcvtzs.s
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldapr.d
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldapr.l
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldapr.s
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldraa.d
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldraa.l
 create mode 100644 gas/testsuite/gas/aarch64/illegal-ldraa.s
 create mode 100644 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.d
 create mode 100644 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.l
 create mode 100644 gas/testsuite/gas/aarch64/illegal-nofp-armv8_3.s
 create mode 100644 gas/testsuite/gas/aarch64/ldst-exclusive-armv8_3.d
 create mode 100644 gas/testsuite/gas/aarch64/ldst-exclusive-armv8_3.s
 create mode 100644 gas/testsuite/gas/arc/cl-warn.s
 create mode 100644 gas/testsuite/gas/arc/cpu-pseudop-1.d
 create mode 100644 gas/testsuite/gas/arc/cpu-pseudop-1.s
 create mode 100644 gas/testsuite/gas/arc/cpu-pseudop-2.d
 create mode 100644 gas/testsuite/gas/arc/cpu-pseudop-2.s
 create mode 100644 gas/testsuite/gas/arc/cpu-warn2.s
 create mode 100644 libiberty/rust-demangle.c
 create mode 100644 libiberty/testsuite/rust-demangle-expected

First 500 lines of diff:
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index fcc5b1c..8a18a6d 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,17 @@
+2016-11-18  James Clarke  <jrtc27@jrtc27.com>
+
+	* elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Don't convert
+	R_SPARC_GOTDATA_OP_HIX22 and R_SPARC_GOTDATA_OP_LOX10 to
+	R_SPARC_GOT* for non-local references. Instead, treat them like
+	R_SPARC_GOTDATA_HIX22/R_SPARC_GOTDATA_LOX10 when filling in the
+	immediate with the calculated relocation.
+
+2016-11-18  Nick Clifton  <nickc@redhat.com>
+
+	PR ld/20675
+	* elf32-metag.c (elf_metag_relocate_section): Replace abort with
+	an informative error message.
+
 2016-11-15  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
 
 	PR ld/20789
diff --git a/bfd/elf32-metag.c b/bfd/elf32-metag.c
index 1557a37..ac78324 100644
--- a/bfd/elf32-metag.c
+++ b/bfd/elf32-metag.c
@@ -1820,7 +1820,7 @@ elf_metag_relocate_section (bfd *output_bfd,
 	      }
 
 	    if (tls_type == GOT_UNKNOWN)
-	      abort();
+	      abort ();
 
 	    if ((off & 1) != 0)
 	      off &= ~1;
@@ -1880,7 +1880,14 @@ elf_metag_relocate_section (bfd *output_bfd,
 		    else
 		      {
 			/* We don't support changing the TLS model.  */
-			abort ();
+			/* PR 20675 */
+			if (bfd_link_pic (info))
+			  _bfd_error_handler (_("%B(%A): multiple TLS models are not supported"),
+					      input_bfd, input_section, name);
+			else
+			  _bfd_error_handler (_("%B(%A): shared library symbol %s encountered whilst performing a static link"),
+					      input_bfd, input_section, name);
+			return FALSE;
 		      }
 
 		    cur_off += 8;
diff --git a/bfd/elfxx-sparc.c b/bfd/elfxx-sparc.c
index db8058f..e1c7b22 100644
--- a/bfd/elfxx-sparc.c
+++ b/bfd/elfxx-sparc.c
@@ -3164,14 +3164,12 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
 	case R_SPARC_GOTDATA_OP_HIX22:
 	case R_SPARC_GOTDATA_OP_LOX10:
 	  if (SYMBOL_REFERENCES_LOCAL (info, h))
-	    r_type = (r_type == R_SPARC_GOTDATA_OP_HIX22
-		      ? R_SPARC_GOTDATA_HIX22
-		      : R_SPARC_GOTDATA_LOX10);
-	  else
-	    r_type = (r_type == R_SPARC_GOTDATA_OP_HIX22
-		      ? R_SPARC_GOT22
-		      : R_SPARC_GOT10);
-	  howto = _bfd_sparc_elf_howto_table + r_type;
+	    {
+	      r_type = (r_type == R_SPARC_GOTDATA_OP_HIX22
+			? R_SPARC_GOTDATA_HIX22
+			: R_SPARC_GOTDATA_LOX10);
+	      howto = _bfd_sparc_elf_howto_table + r_type;
+	    }
 	  break;
 
 	case R_SPARC_GOTDATA_OP:
@@ -3193,6 +3191,8 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
 	  relocation = gdopoff (info, relocation);
 	  break;
 
+	case R_SPARC_GOTDATA_OP_HIX22:
+	case R_SPARC_GOTDATA_OP_LOX10:
 	case R_SPARC_GOT10:
 	case R_SPARC_GOT13:
 	case R_SPARC_GOT22:
@@ -4017,7 +4017,8 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
 	  r = bfd_reloc_ok;
 	}
       else if (r_type == R_SPARC_HIX22
-	       || r_type == R_SPARC_GOTDATA_HIX22)
+	       || r_type == R_SPARC_GOTDATA_HIX22
+	       || r_type == R_SPARC_GOTDATA_OP_HIX22)
 	{
 	  bfd_vma x;
 
@@ -4036,7 +4037,8 @@ _bfd_sparc_elf_relocate_section (bfd *output_bfd,
 				  relocation);
 	}
       else if (r_type == R_SPARC_LOX10
-	       || r_type == R_SPARC_GOTDATA_LOX10)
+	       || r_type == R_SPARC_GOTDATA_LOX10
+	       || r_type == R_SPARC_GOTDATA_OP_LOX10)
 	{
 	  bfd_vma x;
 
diff --git a/bfd/version.h b/bfd/version.h
index e6f720e..c74b66c 100644
--- a/bfd/version.h
+++ b/bfd/version.h
@@ -1,4 +1,4 @@
-#define BFD_VERSION_DATE 20161116
+#define BFD_VERSION_DATE 20161118
 #define BFD_VERSION @bfd_version@
 #define BFD_VERSION_STRING  @bfd_version_package@ @bfd_version_string@
 #define REPORT_BUGS_TO @report_bugs_to@
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 3347bdb..bbeec9c 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,7 @@
+2016-11-16  Mark Wielaard  <mark@klomp.org>
+
+	* cxxfilt.c (main): Recognize rust_demangling.
+
 2016-11-14  Rudy  <jacky.chouchou@yandex.ru>
 
 	PR binutils/20814
diff --git a/binutils/cxxfilt.c b/binutils/cxxfilt.c
index d5863ee..21e5b0d 100644
--- a/binutils/cxxfilt.c
+++ b/binutils/cxxfilt.c
@@ -241,6 +241,7 @@ main (int argc, char **argv)
     case gnat_demangling:
     case gnu_v3_demangling:
     case dlang_demangling:
+    case rust_demangling:
     case auto_demangling:
       valid_symbols = standard_symbol_characters ();
       break;
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 613833b..c95decc 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,59 @@
+2016-11-18  Claudiu Zissulescu  <claziss@synopsys.com>
+
+	* testsuite/gas/arc/cl-warn.s: New file.
+	* testsuite/gas/arc/cpu-pseudop-1.d: Likewise.
+	* testsuite/gas/arc/cpu-pseudop-1.s: Likewise.
+	* testsuite/gas/arc/cpu-pseudop-2.d: Likewise.
+	* testsuite/gas/arc/cpu-pseudop-2.s: Likewise.
+	* testsuite/gas/arc/cpu-warn2.s: Likewise.
+	* config/tc-arc.c (selected_cpu): Initialize.
+	(feature_type): New struct.
+	(feature_list): New variable.
+	(arc_check_feature): New function.
+	(arc_select_cpu): Check for .cpu duplicates. Don't overwrite the
+	current cpu features. Check if a feature is available for a given
+	cpu.
+	(md_parse_option): Test if features are available for a given cpu.
+
+2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* config/tc-aarch64.c (parse_operands): Handle AARCH64_OPND_IMM_ROT*.
+	* testsuite/gas/aarch64/advsimd-armv8_3.d: New.
+	* testsuite/gas/aarch64/advsimd-armv8_3.s: New.
+	* testsuite/gas/aarch64/illegal-fcmla.s: New.
+	* testsuite/gas/aarch64/illegal-fcmla.l: New.
+	* testsuite/gas/aarch64/illegal-fcmla.d: New.
+
+2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* testsuite/gas/aarch64/ldst-exclusive-armv8_3.s: Add ldaprb, ldaprh, ldapr tests.
+	* testsuite/gas/aarch64/ldst-exclusive-armv8_3.d: Likewise.
+	* testsuite/gas/aarch64/illegal-ldapr.s: Likewise.
+	* testsuite/gas/aarch64/illegal-ldapr.d: Likewise.
+	* testsuite/gas/aarch64/illegal-ldapr.l: Likewise.
+
+2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* testsuite/gas/aarch64/fp-armv8_3.s: Add fjcvtzs test.
+	* testsuite/gas/aarch64/fp-armv8_3.d: Likewise.
+	* testsuite/gas/aarch64/illegal-fjcvtzs.s: Likewise.
+	* testsuite/gas/aarch64/illegal-fjcvtzs.d: Likewise.
+	* testsuite/gas/aarch64/illegal-fjcvtzs.l: Likewise.
+	* testsuite/gas/aarch64/illegal-nofp-armv8_3.s: Likewise.
+	* testsuite/gas/aarch64/illegal-nofp-armv8_3.d: Likewise.
+	* testsuite/gas/aarch64/illegal-nofp-armv8_3.l: Likewise.
+
+2016-11-18  Szabolcs Nagy  <szabolcs.nagy@arm.com>
+
+	* config/tc-aarch64.c (parse_operands): Handle AARCH64_OPND_ADDR_SIMM10.
+	(fix_insn): Likewise.
+	(warn_unpredictable_ldst): Handle ldst_imm10.
+	* testsuite/gas/aarch64/pac.s: Add ldraa and ldrab tests.
+	* testsuite/gas/aarch64/pac.d: Likewise.
+	* testsuite/gas/aarch64/illegal-ldraa.s: New.
+	* testsuite/gas/aarch64/illegal-ldraa.l: New.
+	* testsuite/gas/aarch64/illegal-ldraa.d: New.
+
 2016-11-15  Nick Clifton  <nickc@redhat.com>
 
 	PR gas/20803
diff --git a/gas/config/tc-aarch64.c b/gas/config/tc-aarch64.c
index e65daa0..7c518c7 100644
--- a/gas/config/tc-aarch64.c
+++ b/gas/config/tc-aarch64.c
@@ -5561,6 +5561,9 @@ parse_operands (char *str, const aarch64_opcode *opcode)
 	case AARCH64_OPND_SVE_UIMM7:
 	case AARCH64_OPND_SVE_UIMM8:
 	case AARCH64_OPND_SVE_UIMM8_53:
+	case AARCH64_OPND_IMM_ROT1:
+	case AARCH64_OPND_IMM_ROT2:
+	case AARCH64_OPND_IMM_ROT3:
 	  po_imm_nc_or_fail ();
 	  info->imm.value = val;
 	  break;
@@ -6024,6 +6027,25 @@ parse_operands (char *str, const aarch64_opcode *opcode)
 					      /* skip_p */ 0);
 	  break;
 
+	case AARCH64_OPND_ADDR_SIMM10:
+	  po_misc_or_fail (parse_address (&str, info));
+	  if (info->addr.pcrel || info->addr.offset.is_reg
+	      || !info->addr.preind || info->addr.postind)
+	    {
+	      set_syntax_error (_("invalid addressing mode"));
+	      goto failure;
+	    }
+	  if (inst.reloc.type != BFD_RELOC_UNUSED)
+	    {
+	      set_syntax_error (_("relocation not allowed"));
+	      goto failure;
+	    }
+	  assign_imm_if_const_or_fixup_later (&inst.reloc, info,
+					      /* addr_off_p */ 1,
+					      /* need_libopcodes_p */ 1,
+					      /* skip_p */ 0);
+	  break;
+
 	case AARCH64_OPND_ADDR_UIMM12:
 	  po_misc_or_fail (parse_address (&str, info));
 	  if (info->addr.pcrel || info->addr.offset.is_reg
@@ -6481,6 +6503,7 @@ warn_unpredictable_ldst (aarch64_instruction *instr, char *str)
     {
     case ldst_pos:
     case ldst_imm9:
+    case ldst_imm10:
     case ldst_unscaled:
     case ldst_unpriv:
       /* Loading/storing the base register is unpredictable if writeback.  */
@@ -7350,6 +7373,7 @@ fix_insn (fixS *fixP, uint32_t flags, offsetT value)
     case AARCH64_OPND_ADDR_SIMM7:
     case AARCH64_OPND_ADDR_SIMM9:
     case AARCH64_OPND_ADDR_SIMM9_2:
+    case AARCH64_OPND_ADDR_SIMM10:
     case AARCH64_OPND_ADDR_UIMM12:
       /* Immediate offset in an address.  */
       insn = get_aarch64_insn (buf);
diff --git a/gas/config/tc-arc.c b/gas/config/tc-arc.c
index 06aee48..376ac43 100644
--- a/gas/config/tc-arc.c
+++ b/gas/config/tc-arc.c
@@ -451,7 +451,23 @@ static const struct cpu_type
 };
 
 /* Information about the cpu/variant we're assembling for.  */
-static struct cpu_type selected_cpu;
+static struct cpu_type selected_cpu = { 0, 0, 0, 0, 0 };
+
+/* A table with options.  */
+static const struct feature_type
+{
+  unsigned feature;
+  unsigned cpus;
+  const char *name;
+}
+  feature_list[] =
+{
+  { ARC_CD, ARC_OPCODE_ARCV2, "code-density" },
+  { ARC_NPS400, ARC_OPCODE_ARC700, "nps400" },
+  { ARC_SPFP, ARC_OPCODE_ARCFPX, "single-precision FPX" },
+  { ARC_DPFP, ARC_OPCODE_ARCFPX, "double-precision FPX" },
+  { ARC_FPUDA, ARC_OPCODE_ARCv2EM, "double assist FP" }
+};
 
 /* Used by the arc_reloc_op table.  Order is important.  */
 #define O_gotoff  O_md1     /* @gotoff relocation.  */
@@ -775,6 +791,27 @@ md_number_to_chars_midend (char *buf, unsigned long long val, int n)
     }
 }
 
+/* Check if a feature is allowed for a specific CPU.  */
+
+static void
+arc_check_feature (void)
+{
+  unsigned i;
+
+  if (!selected_cpu.features
+      || !selected_cpu.name)
+    return;
+  for (i = 0; (i < ARRAY_SIZE (feature_list)); i++)
+    {
+      if ((selected_cpu.features & feature_list[i].feature)
+	  && !(selected_cpu.flags & feature_list[i].cpus))
+	{
+	  as_bad (_("invalid %s option for %s cpu"), feature_list[i].name,
+		  selected_cpu.name);
+	}
+    }
+}
+
 /* Select an appropriate entry from CPU_TYPES based on ARG and initialise
    the relevant static global variables.  Parameter SEL describes where
    this selection originated from.  */
@@ -790,6 +827,10 @@ arc_select_cpu (const char *arg, enum mach_selection_type sel)
   gas_assert (sel != MACH_SELECTION_FROM_DEFAULT
               || mach_selection_mode == MACH_SELECTION_NONE);
 
+  if ((mach_selection_mode == MACH_SELECTION_FROM_CPU_DIRECTIVE)
+      && (sel == MACH_SELECTION_FROM_CPU_DIRECTIVE))
+    as_bad (_("Multiple .cpu directives found"));
+
   /* Look for a matching entry in CPU_TYPES array.  */
   for (i = 0; cpu_types[i].name; ++i)
     {
@@ -807,22 +848,25 @@ arc_select_cpu (const char *arg, enum mach_selection_type sel)
                   && selected_cpu.mach != cpu_types[i].mach)
                 {
                   as_warn (_("Command-line value overrides \".cpu\" directive"));
-                  return;
                 }
+	      return;
             }
 
-          /* Initialise static global data about selected machine type.  */
-          selected_cpu.flags = cpu_types[i].flags;
-          selected_cpu.name = cpu_types[i].name;
-          selected_cpu.features = cpu_types[i].features;
-          selected_cpu.mach = cpu_types[i].mach;
-          cpu_flags = cpu_types[i].eflags;
+	  /* Initialise static global data about selected machine type.  */
+	  selected_cpu.flags = cpu_types[i].flags;
+	  selected_cpu.name = cpu_types[i].name;
+	  selected_cpu.features |= cpu_types[i].features;
+	  selected_cpu.mach = cpu_types[i].mach;
+	  cpu_flags = cpu_types[i].eflags;
           break;
         }
     }
 
   if (!cpu_types[i].name)
     as_fatal (_("unknown architecture: %s\n"), arg);
+
+  /* Check if set features are compatible with the chosen CPU.  */
+  arc_check_feature ();
   gas_assert (cpu_flags != 0);
   selected_cpu.eflags = (arc_initial_eflag & ~EF_ARC_MACH_MSK) | cpu_flags;
   mach_selection_mode = sel;
@@ -3304,11 +3348,8 @@ md_parse_option (int c, const char *arg ATTRIBUTE_UNUSED)
       break;
 
     case OPTION_CD:
-      /* This option has an effect only on ARC EM.  */
-      if (selected_cpu.flags & ARC_OPCODE_ARCv2EM)
-	selected_cpu.features |= ARC_CD;
-      else
-	as_warn (_("Code density option invalid for selected CPU"));
+      selected_cpu.features |= ARC_CD;
+      arc_check_feature ();
       break;
 
     case OPTION_RELAX:
@@ -3317,22 +3358,22 @@ md_parse_option (int c, const char *arg ATTRIBUTE_UNUSED)
 
     case OPTION_NPS400:
       selected_cpu.features |= ARC_NPS400;
+      arc_check_feature ();
       break;
 
     case OPTION_SPFP:
       selected_cpu.features |= ARC_SPFP;
+      arc_check_feature ();
       break;
 
     case OPTION_DPFP:
       selected_cpu.features |= ARC_DPFP;
+      arc_check_feature ();
       break;
 
     case OPTION_FPUDA:
-      /* This option has an effect only on ARC EM.  */
-      if (selected_cpu.flags & ARC_OPCODE_ARCv2EM)
-	selected_cpu.features |= ARC_FPUDA;
-      else
-	as_warn (_("FPUDA invalid for selected CPU"));
+      selected_cpu.features |= ARC_FPUDA;
+      arc_check_feature ();
       break;
 
     /* Dummy options are accepted but have no effect.  */
diff --git a/gas/testsuite/gas/aarch64/advsimd-armv8_3.d b/gas/testsuite/gas/aarch64/advsimd-armv8_3.d
new file mode 100644
index 0000000..0e477e4
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/advsimd-armv8_3.d
@@ -0,0 +1,33 @@
+#as: -march=armv8.3-a
+#objdump: -dr
+
+.*:     file format .*
+
+Disassembly of section \.text:
+
+0000000000000000 <.*>:
+[^:]+:	6ec3c441 	fcmla	v1.2d, v2.2d, v3.2d, #0
+[^:]+:	6ec3cc41 	fcmla	v1.2d, v2.2d, v3.2d, #90
+[^:]+:	6ec3d441 	fcmla	v1.2d, v2.2d, v3.2d, #180
+[^:]+:	6ec3dc41 	fcmla	v1.2d, v2.2d, v3.2d, #270
+[^:]+:	2e83cc41 	fcmla	v1.2s, v2.2s, v3.2s, #90
+[^:]+:	6e83cc41 	fcmla	v1.4s, v2.4s, v3.4s, #90
+[^:]+:	2e43cc41 	fcmla	v1.4h, v2.4h, v3.4h, #90
+[^:]+:	6e43cc41 	fcmla	v1.8h, v2.8h, v3.8h, #90
+[^:]+:	6f831041 	fcmla	v1.4s, v2.4s, v3.s\[0\], #0
+[^:]+:	6f833041 	fcmla	v1.4s, v2.4s, v3.s\[0\], #90
+[^:]+:	6f835041 	fcmla	v1.4s, v2.4s, v3.s\[0\], #180
+[^:]+:	6f837041 	fcmla	v1.4s, v2.4s, v3.s\[0\], #270
+[^:]+:	6f833841 	fcmla	v1.4s, v2.4s, v3.s\[1\], #90
+[^:]+:	2f433041 	fcmla	v1.4h, v2.4h, v3.h\[0\], #90
+[^:]+:	2f633041 	fcmla	v1.4h, v2.4h, v3.h\[1\], #90
+[^:]+:	6f433041 	fcmla	v1.8h, v2.8h, v3.h\[0\], #90
+[^:]+:	6f633041 	fcmla	v1.8h, v2.8h, v3.h\[1\], #90
+[^:]+:	6f433841 	fcmla	v1.8h, v2.8h, v3.h\[2\], #90
+[^:]+:	6f633841 	fcmla	v1.8h, v2.8h, v3.h\[3\], #90
+[^:]+:	6ec3e441 	fcadd	v1.2d, v2.2d, v3.2d, #90
+[^:]+:	6ec3f441 	fcadd	v1.2d, v2.2d, v3.2d, #270
+[^:]+:	2e83e441 	fcadd	v1.2s, v2.2s, v3.2s, #90
+[^:]+:	6e83e441 	fcadd	v1.4s, v2.4s, v3.4s, #90
+[^:]+:	2e43e441 	fcadd	v1.4h, v2.4h, v3.4h, #90
+[^:]+:	6e43e441 	fcadd	v1.8h, v2.8h, v3.8h, #90
diff --git a/gas/testsuite/gas/aarch64/advsimd-armv8_3.s b/gas/testsuite/gas/aarch64/advsimd-armv8_3.s
new file mode 100644
index 0000000..bfb94e5
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/advsimd-armv8_3.s
@@ -0,0 +1,36 @@
+/* Test file for ARMv8.3 complex arithmetics instructions.  */
+	.text
+
+	/* Three-same operands FCMLA.  */
+	fcmla	v1.2d, v2.2d, v3.2d, #0
+	fcmla	v1.2d, v2.2d, v3.2d, #90
+	fcmla	v1.2d, v2.2d, v3.2d, #180
+	fcmla	v1.2d, v2.2d, v3.2d, #270
+
+	fcmla	v1.2s, v2.2s, v3.2s, #90
+	fcmla	v1.4s, v2.4s, v3.4s, #90
+	fcmla	v1.4h, v2.4h, v3.4h, #90
+	fcmla	v1.8h, v2.8h, v3.8h, #90
+
+	/* Indexed element FCMLA.  */
+	fcmla	v1.4s, v2.4s, v3.s[0], #0
+	fcmla	v1.4s, v2.4s, v3.s[0], #90
+	fcmla	v1.4s, v2.4s, v3.s[0], #180
+	fcmla	v1.4s, v2.4s, v3.s[0], #270
+	fcmla	v1.4s, v2.4s, v3.s[1], #90
+
+	fcmla	v1.4h, v2.4h, v3.h[0], #90
+	fcmla	v1.4h, v2.4h, v3.h[1], #90
+	fcmla	v1.8h, v2.8h, v3.h[0], #90
+	fcmla	v1.8h, v2.8h, v3.h[1], #90
+	fcmla	v1.8h, v2.8h, v3.h[2], #90
+	fcmla	v1.8h, v2.8h, v3.h[3], #90
+
+	/* Three-same operands FADD.  */
+	fcadd	v1.2d, v2.2d, v3.2d, #90
+	fcadd	v1.2d, v2.2d, v3.2d, #270
+
+	fcadd	v1.2s, v2.2s, v3.2s, #90
+	fcadd	v1.4s, v2.4s, v3.4s, #90
+	fcadd	v1.4h, v2.4h, v3.4h, #90
+	fcadd	v1.8h, v2.8h, v3.8h, #90
diff --git a/gas/testsuite/gas/aarch64/fp-armv8_3.d b/gas/testsuite/gas/aarch64/fp-armv8_3.d
new file mode 100644
index 0000000..9be6fca
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/fp-armv8_3.d
@@ -0,0 +1,10 @@
+#objdump: -dr
+#as: -march=armv8.3-a
+
+.*:     file .*
+
+Disassembly of section \.text:
+
+0000000000000000 <.*>:
+   0:	1e7e0041 	fjcvtzs	w1, d2
+   4:	1e7e00e7 	fjcvtzs	w7, d7
diff --git a/gas/testsuite/gas/aarch64/fp-armv8_3.s b/gas/testsuite/gas/aarch64/fp-armv8_3.s


hooks/post-receive
--
Repository for Project Archer.


             reply	other threads:[~2016-11-18 19:20 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-18 19:20 jkratoch [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-01-02 21:49 jkratoch
2016-12-24 20:30 jkratoch
2016-12-17 15:04 jkratoch
2016-11-28 20:19 jkratoch
2016-11-23 22:20 jkratoch
2016-11-20 20:10 jkratoch
2016-11-19  8:49 jkratoch
2016-11-16 17:58 jkratoch
2016-11-13 16:02 jkratoch
2016-11-07 22:51 jkratoch
2016-11-06 18:03 jkratoch
2016-11-02 20:55 jkratoch
2016-11-02 20:46 jkratoch

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161118192050.43624.qmail@sourceware.org \
    --to=jkratoch@sourceware.org \
    --cc=archer-commits@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).