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/index: DWARF-5: .debug_names index consumer
Date: Wed, 28 Jun 2017 21:21:00 -0000	[thread overview]
Message-ID: <20170628212154.70625.qmail@sourceware.org> (raw)

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

The branch, users/jkratoch/index has been updated
  discards  458882a19f9d084b9a10444dc0d867085171162a (commit)
  discards  eeb6810fc7fd76359517d882d861447ad063b37c (commit)
  discards  17ceeb59d9c75ab41e5a3e6a2d89c5eb03324538 (commit)
  discards  e2936bef9ce99169f039e0e1b994852fee28582c (commit)
  discards  157966fcdc971d7686a57d8ee81fd51f9da9668e (commit)
  discards  b1ba635f9cb13a3655e633b1e3728d6b3b9bd78f (commit)
  discards  8349711e0442dffafc803193e71cfd96683324b0 (commit)
       via  2e95764753977d499d61d925a0886c0b4f19102f (commit)
       via  d60714a3a1e2329fab05042bd3be248ddaf20d98 (commit)
       via  6d34e133d6c5081761aea128791fe8c11a654fa5 (commit)
       via  0cece0b84e139eefe775579aa194bacea9bc0f10 (commit)
       via  17b528bc016dd508ebc7baf01808c33c7610d575 (commit)
       via  53c0ab91b7e4b657b9d43be08dfcd323adec5c48 (commit)
       via  4cca419b6d63715cf03067abcc7de1cdc01882a6 (commit)
       via  328ce951b2513a102711bb640496a2f1b5f8d3dd (commit)
       via  47fdcf63c04b5c220974affc8ff1d9ef8a041919 (commit)
       via  6e75794e9da0e12b44c36272e16d18449d25a03d (commit)
       via  bc491f2e76df1f2cec877eb07e88209b609ddecf (commit)
       via  88305e1b9f4592a2ab129015ce409fcc16613ebb (commit)
       via  65a55fbbd949868f7df3c65d39eb8d4455515132 (commit)
       via  c604a79ad4d47070bbcc0bc082188fb16892ceef (commit)
       via  41664b45ab6387184bd0e7512fcf7a72c58744e7 (commit)
       via  819e1f86976dbbd13e0de004cdd3e3089e4c3fc0 (commit)
       via  c7d289d129cde92c0d351446c5072c5f744040fe (commit)
       via  38bf472a15210c222bb3885820e763c47760a704 (commit)
       via  9991e9d77fe04c4fde9b88964c6f25119a781e0d (commit)
       via  6da67eb10df978c1237ca863990f38cdd4ca2e95 (commit)
       via  23732b1e32dd58f7c731d9aee56ff0b22a645d53 (commit)
       via  a4d1e79aaa4b9d994cd9790fc3b756748dc5571c (commit)
       via  2d68166e8704569eeceb76ac743ea1e7cca2af26 (commit)
       via  8268c77870de3c27ef598348f3023ba159fd0fca (commit)
       via  6806377956c76c23ae96a3844e29412ae117e07a (commit)
       via  db665f427ca781d631d9e29b1bb744fb11ffcbba (commit)
       via  ea9aafc41a764e4e2dbb88a7b031e886b481b99a (commit)
       via  79cb3f75debfeb1355f8883143f0f6dc98f70080 (commit)
       via  b0bd097ef63edac71b6720e850b9a04605a87f7f (commit)
       via  2438385a4dea36eba111ee931a2fe2d159c676c8 (commit)
       via  daba08c913105615c5e57dddcfcfa5d8c4237eb9 (commit)
       via  7575e6a752ecfa66a41a5d4636ed79524cb50ccb (commit)
       via  1284e99a6ce362d342d6468e5caa39ddab574721 (commit)
       via  b1a2d7a0e57abc06e6ec99c88ca9992780f45f71 (commit)
       via  a6cbf936e3dce68114d28cdf60d510a3f78a6d40 (commit)
       via  7211ae501eb0de1044983f2dfb00091a58fbd66c (commit)
       via  dc819143fe1d44970a3da4b9ebc7828fa2337115 (commit)
       via  ab27f80c5dceaa23c4ba7f62c0d5d22a5d5dd7a1 (commit)
       via  1f473e3d0ad285195934e6a077c7ed32afe66437 (commit)
       via  b417536f2350881ad28952b3906a025a54d241bd (commit)
       via  0630b49c470ca2e3c3f74da4c7e4ff63440dd71f (commit)
       via  515a4464176efc6ac31c83bd40b5c67f61c3b044 (commit)
       via  873c08142c4c377d2d3ed0b1b1b9e262ddc06c61 (commit)
       via  8b5a7a6e8ceb34f8e82aa361ee91ec25e0049774 (commit)
       via  d1435379df189d1c358ebd9776af8824a9158533 (commit)
       via  04e15b4a9462cb1ae819e878a6009829aab8020b (commit)
       via  cfd14a500e0485374596234de4db10e88ebc7618 (commit)
       via  0602cdad745472ed2561d8096a4bb021c8d0301d (commit)
       via  a3aea05a66ec325ddd19b0c8dbe504958a295cd3 (commit)
       via  fd52715cfa77b7e06f4ab5eadfe7946d22180adc (commit)
       via  93ec5e23766a9f75aa4950748cf73964028a8d1b (commit)
       via  49fa50ef9c59aa6d03bc2e33a25b2d832a9e692b (commit)
       via  cf9bdae906f897ae13563c03c65f325cad05bf1c (commit)
       via  46adbd17408fda28aca5320e2247ede30b7e9649 (commit)
       via  57963c05b9911c3555add356a7cd9952d391dfe4 (commit)
       via  cc75e0fdaeb179efc66ddd1cb1b6da40e6adacc1 (commit)
       via  07809eafc959a0c588663c0c949eaf8044a1b40a (commit)
       via  f076f0349cb958b451872ce4a7987821533c2f49 (commit)
       via  d7e2ebe7e73105766a854f4f0e3a5c509fd0e82a (commit)
       via  2d3392bd42e16b5c8894c357f250dbde245e96fe (commit)
       via  5cc4ca837deac7dc962d8a3741aa120c50ab41da (commit)
       via  b21351faa29dfa6deab3afcb5a2ee78548239274 (commit)
       via  0cda1e190dffc804d1f1ffc4bd849ffdca694914 (commit)
       via  bff0500d7abc215bbc6d4e9332047c023f4ce2cb (commit)
       via  ced40572e478927f43a849d5c39f794868da8d38 (commit)
       via  173205ca3356cab0590c2debaac97107fb9a7fcd (commit)
       via  926770baf44bb47c41e85486957f4ae70b694837 (commit)
       via  9bdfdbf929d581cf845ffc815ae94a39d9f7b032 (commit)
       via  94f78a777c396fa1ce2f40d34afed1b6b5012196 (commit)
       via  4aa57d6a2bfc4e48fa6a685bfa164db5ae2e1c1c (commit)
       via  7ee7ff7015840f2d0156bf386a050bd728d22fc4 (commit)
       via  7e57d19e48f94ff9a19a9413cf25d1887e3a7f52 (commit)
       via  0e158763b0c5671cd40cdd2faee48d6659489ddd (commit)
       via  0dd5cbc56307afaf6a366a8e78ef25cf9cefe514 (commit)
       via  b4cbbe8f7294070cc93a71ace78f134965ddad82 (commit)
       via  790ba5c89893f31dabb6d8e85c8d4be61c52ad99 (commit)
       via  0056441823b1b1b2488dcf069b4feb55b00137ba (commit)
       via  5d8763a38211dd79459485ba0be4f76849ef8200 (commit)
       via  922109c7182858b005f55f6ac69bb6af145fc710 (commit)
       via  84da4cf89efed1df483914d06210daae79ce3eb8 (commit)
       via  d4c6ce5b011b03c7e4a84b530cba1f9b56441131 (commit)
      from  458882a19f9d084b9a10444dc0d867085171162a (commit)

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

- Log -----------------------------------------------------------------
commit 2e95764753977d499d61d925a0886c0b4f19102f
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:28 2017 +0200

    DWARF-5: .debug_names index consumer
    
    Hi,
    
    it is not regression-free against no-index but it is regression-free against
    .gdb_index.  That is because .gdb_index is not regression-free against
    no-index.
    
    Some testcases needed to be updated as they were missing .debug_aranges.
    While that does not matter for no-index (as GDB builds the mapping internally
    during dwarf2_build_psymtabs_hard) and neither for .gdb_index (as GDB uses that
    internally built mapping which it stores into .gdb_index) it does matter for
    .debug_names as that simply assumes existing .debug_aranges from GCC.
    
    I tried some performance checking but the index handling speed is negligible
    compared to the CU expansion associated with it.  .debug_names looked even as
    a bit faster to me than .gdb_index which rather surprised me but I did not
    investigate it more.
    
    
    Jan
    
    
    gdb/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* defs.h (elf_sym_fns_debug_names): New declaration.
    	* dwarf2read.c (mapped_debug_names): New.
    	(struct dwarf2_per_objfile): Add debug_names, debug_aranges and
    	debug_names_table.
    	(dwarf2_elf_names): Add debug_names and debug_aranges.
    	(struct dwz_file): Add debug_names.
    	(dwarf2_locate_sections): Add debug_names and debug_aranges.
    	(locate_dwz_sections): Add debug_names.
    	(create_signatured_type_table_from_debug_names)
    	(create_addrmap_from_aranges): New.
    	(dwarf2_read_index): Update function comment.
    	(read_debug_names_from_section, create_cus_from_debug_names_list)
    	(create_cus_from_debug_names, dwarf2_read_debug_names): New.
    	(dwarf5_djb_hash): Function renamed from DebugNamesNameTable::djb_hash.
    	(dw2_debug_names_iterator): New.
    	(read_indirect_string_at_offset): New declaration.
    	(mapped_debug_names::namei_to_name)
    	(dw2_debug_names_iterator::find_vec_in_debug_names)
    	(dw2_debug_names_iterator::find_vec_in_debug_names)
    	(dw2_debug_names_iterator::next, dw2_debug_names_lookup_symbol)
    	(dw2_debug_names_dump, dw2_debug_names_expand_symtabs_for_function)
    	(dw2_debug_names_expand_symtabs_matching, dwarf2_debug_names_functions):
    	New.
    	(dwarf2_initialize_objfile): Return also elf_sym_fns_debug_names.
    	(dwarf2_free_objfile): Delete also debug_names_table;
    	(debug_names::djb_hash): Rename it to dwarf5_djb_hash.
    	(debug_names::build): Update djb_hash caller.
    	* elfread.c (elf_sym_fns_debug_names): New.
    	* psymtab.h (dwarf2_debug_names_functions): New declaration.
    	* symfile.h (struct dwarf2_debug_sections): Add debug_names and
    	debug_aranges.
    	* xcoffread.c (dwarf2_xcoff_names): Add debug_names and debug_aranges.
    
    gdb/testsuite/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gdb.base/maint.exp (check for .gdb_index): Check also for
    	.debug_names.
    	* gdb.dlang/watch-loc.c (.debug_aranges): New.
    	* gdb.dwarf2/dw2-case-insensitive-debug.S: Likewise.
    	* gdb.dwarf2/gdb-index.exp (check if index present, .gdb_index used)
    	(.gdb_index used after symbol reloading): Support also .debug_names.
    	* gdb.mi/dw2-ref-missing-frame-func.c (.debug_aranges): New.

commit d60714a3a1e2329fab05042bd3be248ddaf20d98
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:27 2017 +0200

    Refactor: Move some generic code out of .gdb_index code
    
    Hi,
    
    just for the next patch.
    
    
    Jan
    
    
    gdb/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf2read.c (create_cu_from_index_list): New from ...
    	(create_cus_from_index_list): ... this function, use it.
    	(dw_expand_symtabs_matching_file_matcher)
    	(dw2_expand_symtabs_matching_one): New from ...
    	(dw2_expand_symtabs_matching): ... this function, use them.

commit 6d34e133d6c5081761aea128791fe8c11a654fa5
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:26 2017 +0200

    Code cleanup: dwarf2_initialize_objfile return value
    
    Hi,
    
    dwarf2_initialize_objfile was returning boolean whether it is psymtabs or
    .gdb_index while now it needs to return also whether it is .debug_names.
    
    
    Jan
    
    
    gdb/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move here
    	declarations from elfread.c.
    	(dwarf2_initialize_objfile): Change return value.
    	* elfread.c (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index): Move these
    	declarations to defs.h.
    	(elf_symfile_read): Adjust dwarf2_initialize_objfile caller.
    	* symfile.h (dwarf2_initialize_objfile): Change return type.

commit 0cece0b84e139eefe775579aa194bacea9bc0f10
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:26 2017 +0200

    DWARF-5: .debug_names index producer
    
    Hi,
    
    there are two FIXME lines I do not have a real answer for.
    
    Also I am not sure if the -dwarf-4 option for former .gdb_index should be named
    that way.  And contrib/gdb-add-index.sh (incl. cc-with-tweaks.sh) has no
    commandline option for that -dwarf-4 GDB option.
    
    
    Jan
    
    
    gdb/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* contrib/gdb-add-index.sh (index): Rename to ...
    	(index4): ... here.
    	(index5, debugstr, debugstrmerge, debugstrerr): New variables.
    	Support also .debug_names and .debug_str.
    	* dwarf2read.c: Include cmath, locale, set, list.
    	(INDEX_SUFFIX): Rename to ...
    	(INDEX4_SUFFIX): ... here.
    	(INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
    	(file_write, file_write, file_write): New.
    	(data_buf::append_unsigned_leb128, data_buf::empty): New.
    	(data_buf::file_write): Use ::file_write.
    	(data_buf::operator const char *, debug_names, check_dwarf64_offsets):
    	New.
    	(psyms_seen_size, write_gdbindex): New from write_psymtabs_to_index
    	code.
    	(write_debug_names): New.
    	(write_psymtabs_to_index): New parameter is_dwarf5.  Support
    	filename_str and out_file_str.  Move code to write_gdbindex, possibly
    	call write_debug_names.
    	(save_gdb_index_command): New parameter -dwarf-4.
    	(_initialize_dwarf2_read): Document the new parameter -dwarf-4.
    
    gdb/doc/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gdb.texinfo (Index Files): Document .debug_names and -dwarf-4.
    	(Index Section Format): Mention .debug_names.

commit 17b528bc016dd508ebc7baf01808c33c7610d575
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:25 2017 +0200

    cc-with-tweaks.sh: Use gdb-add-index.sh
    
    Hi,
    
    currently contrib/cc-with-tweaks.sh is calling for its -i option objcopy itself
    instead of using contrib/gdb-add-index.sh which does the same.
    
    With DWARF-5 .debug_names the commands are more complicated (as now also
    .debug_str needs to be modified) and so I have decided to rather reuse
    contrib/gdb-add-index.sh instead of duplicating its code
    in contrib/cc-with-tweaks.sh.
    
    The problem is when no index is produced whether contrib/cc-with-tweaks.sh
    should fail or not.  As originally contrib/cc-with-tweaks.sh was more quiet
    (=successful) than contrib/gdb-add-index.sh and so after this patch the
    testsuite runs with an index would "regress".  I have tried to keep the
    behavior unchanged.  Some cases still error with:
    	Ada is not currently supported by the index
    But some cases (such as some trivial gdb.dwarf2/ testcases with no DWARF data
    to index) produce no index while the testcases still PASS now instead of:
    	-PASS: gdb.arch/i386-bp_permanent.exp: stack pointer value matches
    	+gdb compile failed, gdb-add-index.sh: No index was created for /quadgdb/testsuite.unix.-m64/outputs/gdb.arch/i386-bp_permanent/i386-bp_permanent
    	+gdb-add-index.sh: [Was there no debuginfo? Was there already an index?]
    	+UNTESTED: gdb.arch/i386-bp_permanent.exp: failed to compile
    
    
    Jan
    
    
    gdb/ChangeLog
    2017-05-26  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* contrib/cc-with-tweaks.sh (t, GDB_ADD_INDEX): New variables.
    	<$want_index>: Call $GDB_ADD_INDEX.

commit 53c0ab91b7e4b657b9d43be08dfcd323adec5c48
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:25 2017 +0200

    binutils

commit 4cca419b6d63715cf03067abcc7de1cdc01882a6
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Jun 28 23:07:25 2017 +0200

    gccidx

commit 328ce951b2513a102711bb640496a2f1b5f8d3dd
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jun 28 11:07:04 2017 -0700

    Don't call bfd_get_file_size in _bfd_generic_get_section_contents
    
    Since it is impossible to read beyond the end of normal files, we only
    need to check archive element size in _bfd_generic_get_section_contents
    
    	* libbfd.c (_bfd_generic_get_section_contents): Don't call
    	bfd_get_file_size.  Check archive element size.
    	(_bfd_generic_get_section_contents_in_window): Likewise.

commit 47fdcf63c04b5c220974affc8ff1d9ef8a041919
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jun 28 11:00:13 2017 -0700

    Change bfd_get_size/bfd_get_file_size to ufile_ptr
    
    bfd_get_size and bfd_get_file_size should return the unsigned file
    size.  Otherwise they return negative values for file >= 2GB with
    32-bit ufile_ptr.
    
    bfd/
    
    	* bfd-in2.h: Regenerated.
    	* bfdio.c (bfd_get_size): Change return type to ufile_ptr.
    	(bfd_get_file_size): Likewise.
    
    binutils/
    
    	* objdump.c (dump_relocs_in_section): Cast to ufile_ptr when
    	comparing against bfd_get_file_size return.

commit 6e75794e9da0e12b44c36272e16d18449d25a03d
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Jun 28 15:19:02 2017 +0100

    gdb/command.h: Include common/scoped_restore.h
    
    command.h depends on scoped_restore:
    
      extern scoped_restore_tmpl<int> prevent_dont_repeat (void);
    
    But doesn't include the corresponding header
    ("common/scoped_restore.h").  We haven't noticed a problem because
    utils.h includes scoped_restore.h, and defs.h includes utils.h.
    
    However, a patch that makes "symtab.h" include "completer.h", exposed
    the issue:
     https://sourceware.org/ml/gdb-patches/2017-06/msg00023.html.
    
    Without this fix that would break building all .o files like this:
    
     In file included from src/gdb/completer.h:21:0,
                      from src/gdb/symtab.h:28,
                      from src/gdb/language.h:26,
                      from src/gdb/frame.h:72,
                      from src/gdb/gdbarch.h:39,
                      from src/gdb/defs.h:636,
                      from src/gdb/top.c:20:
     src/gdb/command.h:434:8: error: ‘scoped_restore_tmpl’ does not name a type
      extern scoped_restore_tmpl<int> prevent_dont_repeat (void);
             ^
     Makefile:1911: recipe for target 'top.o' failed
    
    because defs.h includes gdbarch.h before it includes utils.h.
    
    gdb/ChangeLog:
    2017-06-28  Pedro Alves  <palves@redhat.com>
    
    	* command.h: Include "common/scoped_restore.h".

commit bc491f2e76df1f2cec877eb07e88209b609ddecf
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jun 28 14:48:55 2017 +0100

    Use obstack_grow_str
    
    We already have macro obstack_grow_str, which is helpful to shorten the
    code.
    
    gdb:
    
    2017-06-28  Yao Qi  <yao.qi@linaro.org>
    
    	* mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
    	instead of obstack_grow.

commit 88305e1b9f4592a2ab129015ce409fcc16613ebb
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jun 28 14:52:12 2017 +0100

    Add support for version 2 of the GNU Build Attribute note specification.
    
    	* objcopy.c (merge_gnu_build_notes): Add support for version 2 notes.
    	* readelf.c (print_gnu_build_attribute_name): Likewise.

commit 65a55fbbd949868f7df3c65d39eb8d4455515132
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Wed Jun 28 11:09:01 2017 +0100

    [AArch64] Add dot product support for AArch64 to binutils
    
    gas/
    	* config/tc-aarch64.c (aarch64_reg_parse_32_64): Accept 4B.
    	(aarch64_features): Added dotprod.
    	* doc/c-aarch64.texi: Added dotprod.
    	* testsuite/gas/aarch64/dotproduct.d: New.
    	* testsuite/gas/aarch64/dotproduct.s: New.
    
    opcodes/
    	* aarch64-asm.c (aarch64_ins_reglane): Added 4B dotprod.
    	* aarch64-dis.c (aarch64_ext_reglane): Likewise.
    	* aarch64-tbl.h (QL_V3DOT, QL_V2DOT): New.
    	(aarch64_feature_dotprod, DOT_INSN): New.
    	(udot, sdot): New.
    	* aarch64-dis-2.c: Regenerated.
    
    include/
    	* opcode/aarch64.h: (AARCH64_FEATURE_DOTPROD): New.
    	(aarch64_insn_class): Added dotprod.

commit c604a79ad4d47070bbcc0bc082188fb16892ceef
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Jun 28 11:00:55 2017 +0100

    [ARM] Assembler and disassembler support Dot Product Extension
    
      This patch add assembler and disassembler support for new Dot Product
      Extension.
    
      The support can be enabled through the new "+dotprod" extension.
    
    include/
    	* opcode/arm.h (FPU_NEON_EXT_DOTPROD): New macro.
    	(FPU_ARCH_DOTPROD_NEON_VFP_ARMV8): New macro.
    
    gas/
    	* config/tc-arm.c (fpu_neon_ext_dotprod): New variable.
    	(neon_scalar_for_mul): Improve comments.
    	(do_neon_dotproduct): New function to encode Dot Product instructions.
    	(do_neon_dotproduct_s): Wrapper function for signed Dot Product
    	instructions.
    	(do_neon_dotproduct_u): Wrapper function for unsigned Dot Product
    	instructions.
    	(insns): New entries for vsdot and vudot.
    	(arm_extensions): New entry for "dotprod".
    	* doc/c-arm.texi: Document new "dotprod" extension.
    	* testsuite/gas/arm/dotprod.s: New test source.
    	* testsuite/gas/arm/dotprod-illegal.s: New test source.
    	* testsuite/gas/arm/dotprod.d: New test.
    	* testsuite/gas/arm/dotprod-thumb2.d: New test.
    	* testsuite/gas/arm/dotprod-illegal.d: New test.
    	* testsuite/gas/arm/dotprod-legacy-arch.d: New test.
    	* testsuite/gas/arm/dotprod-illegal.l: New error file.
    	* testsuite/gas/arm/dotprod-legacy-arch.l: New error file.
    
    opcodes/
    	* arm-dis.c (coprocessor_opcodes): New entries for vsdot and vudot.

commit 41664b45ab6387184bd0e7512fcf7a72c58744e7
Author: Doug Gilmore <Doug.Gilmore@imgtec.com>
Date:   Wed Jun 28 02:54:22 2017 +0100

    Fix PR 21337: segfault when re-reading symbols.
    
    Fix issue exposed by commit 3e29f34.
    
    The basic issue is that section data referenced through an objfile
    pointer can also be referenced via the program-space data pointer,
    although via a separate mapping mechanism, which is set up by
    update_section_map.  Thus once section data attached to an objfile
    pointer is released, the section map associated with the program-space
    data pointer must be marked dirty to ensure that update_section_map is
    called to prevent stale data being referenced.  For the matter at hand
    this marking is being done via a call to objfiles_changed.
    
    Before commit 3e29f34 objfiles_changed could be called after all of
    the objfile pointers were processed in reread_symbols since section
    data references via the program-space data pointer would not occur in
    the calls of read_symbols performed by reread_symbols.
    
    With commit 3e29f34 MIPS target specific calls to find_pc_section were
    added to the code for DWARF information processing, which is called
    via read_symbols.  Thus in reread_symbols the call to objfiles_changed
    needs to be called before calling read_symbols, otherwise stale
    section data can be referenced.
    
    Thanks to Luis Machado for providing text for the main comment
    associated with the change.
    
    gdb/
    2017-06-28  Doug Gilmore  <Doug.Gilmore@imgtec.com>
        PR gdb/21337
        * symfile.c (reread_symbols): Call objfiles_changed just before
        read_symbols.
    
    gdb/testsuite/
    2017-06-28  Doug Gilmore  <Doug.Gilmore@imgtec.com>
        PR gdb/21337
        * gdb.base/reread-readsym.exp: New file.
        * gdb.base/reread-readsym.c: New file.

commit 819e1f86976dbbd13e0de004cdd3e3089e4c3fc0
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Jun 28 02:07:36 2017 +0100

    MIPS: Add new Imagination interAptiv MR2 GAS and LD tests
    
    Add GAS tests to verify Imagination interAptiv MR2 instruction assembly,
    disassembly and ELF object file flags.
    
    Add LD tests to verify Imagination interAptiv MR2 ELF object file
    link-time compatibility and flag merging/propagation.  Use the framework
    enhancement added with commit 7575e6a752ec ("MIPS/LD/testsuite:
    mips-elf-flags: Add MIPS ABI Flags handling").
    
    	gas/
    	* testsuite/gas/mips/elf_mach_interaptiv-mr2.d: New test.
    	* testsuite/gas/mips/save-err.d: New test.
    	* testsuite/gas/mips/save-sub.d: New test.
    	* testsuite/gas/mips/interaptiv-mr2@save.d: New test.
    	* testsuite/gas/mips/mips1@save-sub.d: New test.
    	* testsuite/gas/mips/mips2@save-sub.d: New test.
    	* testsuite/gas/mips/mips3@save-sub.d: New test.
    	* testsuite/gas/mips/mips4@save-sub.d: New test.
    	* testsuite/gas/mips/mips5@save-sub.d: New test.
    	* testsuite/gas/mips/mips32@save-sub.d: New test.
    	* testsuite/gas/mips/mips64@save-sub.d: New test.
    	* testsuite/gas/mips/mips16@save-sub.d: New test.
    	* testsuite/gas/mips/mips16e@save-sub.d: New test.
    	* testsuite/gas/mips/r3000@save-sub.d: New test.
    	* testsuite/gas/mips/r3900@save-sub.d: New test.
    	* testsuite/gas/mips/r4000@save-sub.d: New test.
    	* testsuite/gas/mips/vr5400@save-sub.d: New test.
    	* testsuite/gas/mips/interaptiv-mr2@save-sub.d: New test.
    	* testsuite/gas/mips/sb1@save-sub.d: New test.
    	* testsuite/gas/mips/octeon2@save-sub.d: New test.
    	* testsuite/gas/mips/octeon3@save-sub.d: New test.
    	* testsuite/gas/mips/xlr@save-sub.d: New test.
    	* testsuite/gas/mips/r5900@save-sub.d: New test.
    	* testsuite/gas/mips/mips16e2-copy.d: New test.
    	* testsuite/gas/mips/mips16e2-copy-err.d: New test.
    	* testsuite/gas/mips/save.d: Remove `MIPS16e' from the `name'
    	option.  Adjust for trailing padding change.
    	* testsuite/gas/mips/mips16e2-copy-err.l: New stderr output.
    	* testsuite/gas/mips/save-sub.s: New test source.
    	* testsuite/gas/mips/mips16e2-copy.s: New test source.
    	* testsuite/gas/mips/mips16e2-copy-err.s: New test source.
    	* testsuite/gas/mips/save.s: Update description, change trailing
    	padding and remove trailing white space.
    	* testsuite/gas/mips/mips.exp: Expand `save' and `save-err'
    	tests across the regular MIPS interAptiv MR2 architecture.  Run
    	the new tests.
    
    	ld/
    	* testsuite/ld-mips-elf/mips-elf-flags.exp: Add interAptiv MR2
    	tests.

commit c7d289d129cde92c0d351446c5072c5f744040fe
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Jun 28 02:07:36 2017 +0100

    MIPS: Add Imagination interAptiv MR2 GAS test infrastructure
    
    Define a new regular MIPS and MIPS16 interAptiv MR2 test architecture
    and adjust existing tests now run against these architectures
    accordingly.
    
    This change causes new test failures:
    
    FAIL: MIPS jal-svr4pic (interaptiv-mr2)
    FAIL: MIPS jal-svr4pic noreorder (interaptiv-mr2)
    
    with the `mips-sgi-irix5' and `mips-sgi-irix6' targets, which are
    consistent with the remaining architecture results for these cases, that
    do not take into account the lack of R_MIPS_JALR relocations produced by
    GAS for these targets.  As a preexisting issue these failures are not
    addressed with this change.
    
    	gas/
    	* testsuite/gas/mips/mips.exp (interaptiv-mr2): New architecture.
    	(mips16e2-interaptiv-mr2): Likewise.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro.d: New
    	test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-t.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-e.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-t.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-e.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64.d: New
    	test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-sub.d: New
    	test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.d: New
    	test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64-sub.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e2-mt-sub.d:
    	New test.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-asmacro.d:
    	New test.
    	* testsuite/gas/mips/interaptiv-mr2@mcu.d: New test.
    	* testsuite/gas/mips/interaptiv-mr2@isa-override-1.d: New test.
    	* testsuite/gas/mips/interaptiv-mr2@isa-override-2.d: New test.
    	* testsuite/gas/mips/attr-gnu-4-5.d: Ignore any number of ASE
    	flag lines present rather than just one.
    	* testsuite/gas/mips/attr-gnu-4-6.d: Likewise.
    	* testsuite/gas/mips/attr-gnu-4-7.d: Likewise.
    	* testsuite/gas/mips/attr-none-o32-fp64-nooddspreg.d: Likewise.
    	* testsuite/gas/mips/attr-none-o32-fp64.d: Likewise.
    	* testsuite/gas/mips/attr-none-o32-fpxx.d: Likewise.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro.l: New
    	stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-t.l:
    	New stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-e.l:
    	New stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-t.l:
    	New stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-e.l:
    	New stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-sub.l: New
    	stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.l: New
    	stderr output.
    	* testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64-sub.l:
    	New stderr output.
    	* testsuite/gas/mips/interaptiv-mr2@isa-override-1.l: New stderr
    	output.
    	* testsuite/gas/mips/interaptiv-mr2@isa-override-2.l: New stderr
    	output.

commit 38bf472a15210c222bb3885820e763c47760a704
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Jun 28 02:07:36 2017 +0100

    MIPS: Add Imagination interAptiv MR2 MIPS32r3 processor support
    
    Add support for the Imagination interAptiv MR2 MIPS32r3 processor with
    the MIPS16e2 ASE as per documentation, including in particular:
    
    1. Support for implementation-specific interAptiv MR2 COPYW and UCOPYW
       MIPS16e2 instructions[1], for assembly and disassembly,
    
    2. Support for implementation-specific interAptiv MR2 SAVE and RESTORE
       regular MIPS instructions[2], for assembly and disassembly,
    
    3. ELF binary file annotation for the interAptiv MR2 MIPS architecture
       extension.
    
    4. Support for interAptiv MR2 architecture selection for assembly, in
       the form of the `-march=interaptiv-mr2' command-line option and its
       corresponding `arch=interaptiv-mr2' setting for the `.set' and
       `.module' pseudo-ops.
    
    5. Support for interAptiv MR2 architecture selection for disassembly,
       in the form of the `mips:interaptiv-mr2' target architecture, for
       use e.g. with the `-m' command-line option for `objdump'.
    
    Parts of this change by Matthew Fortune and Andrew Bennett.
    
    References:
    
    [1] "MIPS32 interAptiv Multiprocessing System Software User's Manual",
        Imagination Technologies Ltd., Document Number: MD00904, Revision
        02.01, June 15, 2016, Section 24.3 "MIPS16e2 Implementation Specific
        Instructions", pp. 878-883
    
    [2] same, Chapter 25 "Implementation-specific Instructions", pp. 911-917
    
    	include/
    	* elf/mips.h (E_MIPS_MACH_IAMR2): New macro.
    	(AFL_EXT_INTERAPTIV_MR2): Likewise.
    	* opcode/mips.h: Document new operand codes defined.
    	(INSN_INTERAPTIV_MR2): New macro.
    	(INSN_CHIP_MASK): Adjust accordingly.
    	(CPU_INTERAPTIV_MR2): New macro.
    	(cpu_is_member) <CPU_INTERAPTIV_MR2>: New case.
    	(MIPS16_ALL_ARGS): Rename to...
    	(MIPS_SVRS_ALL_ARGS): ... this.
    	(MIPS16_ALL_STATICS): Rename to...
    	(MIPS_SVRS_ALL_STATICS): ... this.
    
    	bfd/
    	* archures.c (bfd_mach_mips_interaptiv_mr2): New macro.
    	* cpu-mips.c (I_interaptiv_mr2): New enum value.
    	(arch_info_struct): Add "mips:interaptiv-mr2" entry.
    	* elfxx-mips.c (_bfd_elf_mips_mach) <E_MIPS_MACH_IAMR2>: New
    	case.
    	(mips_set_isa_flags) <bfd_mach_mips_interaptiv_mr2>: Likewise.
    	(bfd_mips_isa_ext) <bfd_mach_mips_interaptiv_mr2>: Likewise.
    	(print_mips_isa_ext) <AFL_EXT_INTERAPTIV_MR2>: Likewise.
    	(mips_mach_extensions): Add `bfd_mach_mipsisa32r3' and
    	`bfd_mach_mips_interaptiv_mr2' entries.
    	* bfd-in2.h: Regenerate.
    
    	opcodes/
    	* mips-formats.h (INT_BIAS): New macro.
    	(INT_ADJ): Redefine in INT_BIAS terms.
    	* mips-dis.c (mips_arch_choices): Add "interaptiv-mr2" entry.
    	(mips_print_save_restore): New function.
    	(print_insn_arg) <OP_SAVE_RESTORE_LIST>: Update comment.
    	(validate_insn_args) <OP_SAVE_RESTORE_LIST>: Remove `abort'
    	call.
    	(print_insn_args): Handle OP_SAVE_RESTORE_LIST.
    	(print_mips16_insn_arg): Call `mips_print_save_restore' for
    	OP_SAVE_RESTORE_LIST handling, factored out from here.
    	* mips-opc.c (decode_mips_operand) <'-'> <'m'>: New case.
    	(RD_31, RD_SP, WR_SP, MOD_SP, IAMR2): New macros.
    	(mips_builtin_opcodes): Add "restore" and "save" entries.
    	* mips16-opc.c (decode_mips16_operand) <'n', 'o'>: New cases.
    	(IAMR2): New macro.
    	(mips16_opcodes): Add "copyw" and "ucopyw" entries.
    
    	binutils/
    	* readelf.c (get_machine_flags) <E_MIPS_MACH_IAMR2>: New case.
    	(print_mips_isa_ext) <AFL_EXT_INTERAPTIV_MR2>: Likewise.
    	* NEWS: Mention Imagination interAptiv MR2 processor support.
    
    	gas/
    	* config/tc-mips.c (validate_mips_insn): Handle
    	OP_SAVE_RESTORE_LIST specially.
    	(mips_encode_save_restore, mips16_encode_save_restore): New
    	functions.
    	(match_save_restore_list_operand): Factor out SAVE/RESTORE
    	operand insertion into the instruction word or halfword to these
    	new functions.
    	(mips_cpu_info_table): Add "interaptiv-mr2" entry.
    
    	* doc/c-mips.texi (MIPS Options): Add `interaptiv-mr2' to the
    	`-march=' argument list.

commit 9991e9d77fe04c4fde9b88964c6f25119a781e0d
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jun 28 00:00:40 2017 +0000

    Automatic date update in version.in

commit 6da67eb10df978c1237ca863990f38cdd4ca2e95
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jun 27 16:32:57 2017 +0100

    completion_list_add_name wrapper functions
    
    Replace macros with functions.
    
    gdb/ChangeLog:
    2017-06-27  Pedro Alves  <palves@redhat.com>
    
    	* symtab.c (COMPLETION_LIST_ADD_SYMBOL)
    	(MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
    	(completion_list_add_symbol, completion_list_add_msymbol):
    	... these new functions.
    	(add_symtab_completions)
    	(default_make_symbol_completion_list_break_on_1): Adjust.

commit 23732b1e32dd58f7c731d9aee56ff0b22a645d53
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jun 27 16:22:08 2017 +0100

    objfile_per_bfd_storage non-POD
    
    A following patch will want to add a std::vector to
    objfile_per_bfd_storage.  That makes it non-trivially
    constructible/destructible.  Since objfile_per_bfd_storage objects are
    allocated on an obstack, we need to call their ctors/dtors manually.
    This is what this patch does.  And then since we can now rely on
    ctors/dtors being run, make objfile_per_bfd_storage::storage_obstack
    be an auto_obstack.
    
    gdb/ChangeLog:
    2017-06-27  Pedro Alves  <palves@redhat.com>
    
    	* objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
    	bfd_zalloc.  Call objfile_per_bfd_storage's ctor.
    	(free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
    	dtor.
    	* objfiles.h (objfile_per_bfd_storage): Add ctor.  Make
    	'storage_obstack' field an auto_obstack.  In-class initialize all
    	non-bitfield fields.  Make minsyms_read bool.
    	* symfile.c (read_symbols): Adjust.

commit a4d1e79aaa4b9d994cd9790fc3b756748dc5571c
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Tue Jun 27 13:10:16 2017 +0100

    Remove MAX_REGISTER_SIZE from remote-sim.c
    
    gdb/
    	* remote-sim.c (gdbsim_fetch_register): Use byte_vector.
    	(gdbsim_store_register): Likewise.

commit 2d68166e8704569eeceb76ac743ea1e7cca2af26
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jun 27 12:11:22 2017 +0100

    Remove debugging accidentally left in tekhex.c.
    
    	* tekhex.c (pass_over): Revert accidental conversion of a local
    	array to a static array.

commit 8268c77870de3c27ef598348f3023ba159fd0fca
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jun 27 11:07:14 2017 +0100

    Eliminate make_cleanup_obstack_free, introduce auto_obstack
    
    This commit eliminates make_cleanup_obstack_free, replacing it with a
    new auto_obstack type that inherits obstack to add cdtors.
    
    These changes in the parsers may not be obvious:
    
     -  obstack_init (&name_obstack);
     -  make_cleanup_obstack_free (&name_obstack);
     +  name_obstack.clear ();
    
    Here, the 'name_obstack' variable is a global.  The change means that
    the obstack's contents from a previous parse will stay around until
    the next parsing starts.  I.e., memory won't be reclaimed until then.
    I don't think that's a problem, these objects don't really grow much
    at all.
    
    The other option I tried was to add a separate type that is like
    auto_obstack but manages an external obstack, just for those cases.  I
    like the current approach better as that other approach adds more
    boilerplate and yet another type to learn.
    
    gdb/ChangeLog:
    2017-06-27  Pedro Alves  <palves@redhat.com>
    
    	* c-exp.y (name_obstack): Now an auto_obstack.
    	(yylex): Use auto_obstack::clear.
    	(c_parse): Use auto_obstack::clear instead of reinitializing and
    	freeing the obstack.
    	* c-lang.c (evaluate_subexp_c): Use auto_obstack.
    	* d-exp.y (name_obstack): Now an auto_obstack.
    	(yylex): Use auto_obstack::clear.
    	(d_parse): Use auto_obstack::clear instead of reinitializing and
    	freeing the obstack.
    	* dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
    	auto_obstack.
    	* dwarf2read.c (create_addrmap_from_index)
    	(dwarf2_build_psymtabs_hard)
    	(update_enumeration_type_from_children): Likewise.
    	* gdb_obstack.h (auto_obstack): New type.
    	* go-exp.y (name_obstack): Now an auto_obstack.
    	(build_packaged_name): Use auto_obstack::clear.
    	(go_parse): Use auto_obstack::clear instead of reinitializing and
    	freeing the obstack.
    	* linux-tdep.c (linux_make_mappings_corefile_notes): Use
    	auto_obstack.
    	* printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
    	* rust-exp.y (work_obstack): Now an auto_obstack.
    	(rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
    	reinitializing and freeing the obstack.
    	* utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
    	(host_char_to_target): Use auto_obstack.
    	* utils.h (make_cleanup_obstack_free): Delete declaration.
    	* valprint.c (generic_emit_char, generic_printstr): Use
    	auto_obstack.

commit 6806377956c76c23ae96a3844e29412ae117e07a
Author: Senthil Kumar Selvaraj <senthil_kumar.selvaraj@atmel.com>
Date:   Tue Jun 27 14:46:08 2017 +0530

    Fix PR 13402
    
    Fix incorrect adjustment of diff relocs when relaxing, and thus the
    resulting source line to address mismatch.
    
    Fix two issues when adjusting diff relocs to account for
    deleted bytes.
    
    1. Don't adjust the difference if the end address is the shrinked
    insn's address i.e. use < instead of <=. The relaxation code deletes
    count bytes from or after shrinked_insn_address, so the difference
    between start_address and end_address should remain unchanged in this
    case.
    
    2. Adjust the reloc addend if the difference is to be adjusted and
    symval + reloc addend is past the shrinked insn address. This is
    because for a typical sym1 - sym2 diff reloc, sym1 is .text +
    irel->r_addend, and the addend should be reduced to account for the
    shrinked insn.
    
    For example, assume the reloc value is .text + 0x8 with .text = 0, the
    diff value in the object file = 0x4, and shrinked_insn_address = 0x4
    with count = 0x2. Then the existing code writes 0x2 into the object
    file to account for the deleted bytes, as shrinked_insn_address lies
    between 0x8 and 0x8 - 0x4 = 0x4, but leaves the addend as is. The next
    time the reloc is looked at, the code sees if a shrinked_insn_address
    lies between 0x8 and 0x8 - 0x2 = 0x6, instead of 0x6 and 0x4. If there
    happens to be one, then the diff value in the object file ends up
    getting reduced again.
    
    bfd/
    
    2017-06-27  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
    
    	PR ld/13402
    	* elf32-avr.c (elf32_avr_adjust_diff_reloc_value): Adjust
    	reloc addend if necessary. Adjust diff only if
    	shrinked_insn_address < end_address.
    
    ld/
    
    2017-06-27  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
    
    	PR ld/13402
    	* testsuite/ld-avr/pr13402.d: New test.
    	* testsuite/ld-avr/pr13402.s: New test.

commit db665f427ca781d631d9e29b1bb744fb11ffcbba
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Jun 27 10:55:36 2017 +0200

    darwin: Do not add a dummy thread
    
    Starting a process on macOS/Darwin currently leads to this error:
    
    /Users/simark/src/binutils-gdb/gdb/darwin-nat.c:383: internal-error: void darwin_check_new_threads(struct inferior *): Assertion `tp' failed.
    
    with the corresponding partial backtrace (sorry, taken with lldb,
    because well, gdb is broken :)):
    
        frame #9: 0x000000010004605a gdb`darwin_check_new_threads(inf=0x0000000100edf670) at darwin-nat.c:383
        frame #10: 0x0000000100045848 gdb`darwin_init_thread_list(inf=0x0000000100edf670) at darwin-nat.c:1710
        frame #11: 0x00000001000452f8 gdb`darwin_ptrace_him(pid=8375) at darwin-nat.c:1792
        frame #12: 0x0000000100041d95 gdb`fork_inferior(...) at fork-inferior.c:440
        frame #13: 0x0000000100043f82 gdb`darwin_create_inferior(...) at darwin-nat.c:1841
        frame #14: 0x000000010034ac32 gdb`run_command_1(args=0x0000000000000000, from_tty=1, tbreak_at_main=1) at infcmd.c:611
    
    The issue was introduced by commit
    
      "Share fork_inferior et al with gdbserver"
    
    because it changed the place where the dummy thread (pid, 0, 0) is added,
    relative to the call to the init_trace_fun callback.  In this callback, darwin
    checks for new threads in the program (there should be exactly one) in order to
    update this dummy thread with the right tid.  Previously, things happened in
    this order:
    
     - fork_inferior calls fork()
     - fork_inferior adds dummy thread
     - fork_inferior calls init_trace_fun callback, which updates the dummy
       thread info
    
    Following the commit mentioned above, the new thread is added in the
    darwin-nat code, after having called fork_inferior (in
    darwin_create_inferior).  So gdb tries to do things in this order:
    
     - fork_inferior calls fork()
     - fork_inferior calls init_trace_fun callback, which tries to update
       the dummy thread info
     - darwin_create_inferior adds the dummy thread
    
    The error happens while trying to update the dummy thread that has not
    been added yet.
    
    I don't think this dummy thread is necessary for darwin.  Previously, it
    was fork_inferior that was adding this thread, for all targets, so
    darwin had to deal with it.  Now that it's done by targets themselves,
    we can just skip that on darwin.  darwin_check_new_threads called
    indirectly by init_trace_fun/darwin_ptrace_him will simply notice the
    new thread and add it with the right information.
    
    My level of testing was: try to start a process and try to attach to a
    process, and it seems to work somewhat like it did before.  I tried to
    run the testsuite, but it leaves a huge amount of zombie processes that
    launchd doesn't seem to reap, leading to exhaustion of system resources
    (number of processes).
    
    gdb/ChangeLog:
    
    	* darwin-nat.c (darwin_check_new_threads): Don't handle dummy
    	thread.
    	(darwin_init_thread_list): Don't update dummy thread.
    	(darwin_create_inferior, darwin_attach): Don't add a dummy thread.

commit ea9aafc41a764e4e2dbb88a7b031e886b481b99a
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jun 27 14:43:49 2017 +0930

    Warning fix
    
    	PR binutils/21665
    	* libbfd.c (_bfd_generic_get_section_contents): Warning fix.
    	(_bfd_generic_get_section_contents_in_window): Likewise.

commit 79cb3f75debfeb1355f8883143f0f6dc98f70080
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 04:23:54 2017 +0100

    MIPS/GAS/testsuite: Drop the `mips16e-' prefix from SAVE/RESTORE tests
    
    In preparation to running these tests against regular MIPS instructions.
    
    	gas/
    	* testsuite/gas/mips/mips16e-save.d: Rename to...
    	* testsuite/gas/mips/save.d: ... this.
    	* testsuite/gas/mips/mips16e-save-err.d: Update the
    	`error-output' option and rename to...
    	* testsuite/gas/mips/save-err.d: ... this.
    	* testsuite/gas/mips/mips16e-save-err.l: Rename to...
    	* testsuite/gas/mips/save-err.l: ... this.
    	* testsuite/gas/mips/mips16e-save.s: Rename to...
    	* testsuite/gas/mips/save.s: ... this.
    	* testsuite/gas/mips/mips16e-save-err.s: Rename to...
    	* testsuite/gas/mips/save-err.s: ... this.
    	* testsuite/gas/mips/mips.exp: Rename `mips16e-save' and
    	`mips16e-save-err' invocations to `save' and `save-err'
    	respectively and reorder these tests away from MIPS16 tests.

commit b0bd097ef63edac71b6720e850b9a04605a87f7f
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 04:23:54 2017 +0100

    MIPS/GAS/testsuite: Run SAVE/RESTORE tests across all MIPS16e architectures
    
    	gas/
    	* testsuite/gas/mips/mips16e-save.d: Remove `-mmips:isa32
    	-mmips:16' from `objdump' flags and `-march=mips32 -mips16' from
    	`as' flags.
    	* testsuite/gas/mips/mips16e-save-err.d: Remove `-march=mips32'
    	from `as' flags.
    	* testsuite/gas/mips/mips16e-save.s: Remove the `.set mips16'
    	pseudo-op.
    	* testsuite/gas/mips/mips16e-save-err.s: Likewise.
    	* testsuite/gas/mips/mips.exp: Run SAVE/RESTORE tests across all
    	MIPS16e architectures.

commit 2438385a4dea36eba111ee931a2fe2d159c676c8
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 04:23:54 2017 +0100

    MIPS/GAS/testsuite: Convert `mips16e-save-err' list test to a dump test
    
    	gas/
    	* testsuite/gas/mips/mips16e-save-err.d: New test.
    	* gas/testsuite/gas/mips/mips.exp: Fold `mips16e-save-err' list
    	test into the new test.

commit daba08c913105615c5e57dddcfcfa5d8c4237eb9
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 04:23:53 2017 +0100

    MIPS/GAS/testsuite: Capitalize the name of the `mips16e-save' test
    
    For consistency with the subsequent changes in this area.
    
    	gas/
    	* testsuite/gas/mips/mips16e-save.d: Capitalize the `name'
    	option.

commit 7575e6a752ecfa66a41a5d4636ed79524cb50ccb
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 02:58:27 2017 +0100

    MIPS/LD/testsuite: mips-elf-flags: Add MIPS ABI Flags handling
    
    Complement commit 351cdf24d223 ("[MIPS] Implement O32 FPXX, FP64 and
    FP64A ABI extensions") and add optional MIPS ABI Flags handling to
    `good_combination' in the `mips-elf-flags.exp' test script.  This lets
    callers of this procedure request to examine MIPS ABI Flags in addition
    to the `e_flags' member of the ELF file header so as to verify that
    flags are merged correctly by LD.  The presence of further arguments
    triggers this verification, in which case `readelf' is called with the
    `-A' option additionally specified and the ISA member, the ISA Extension
    member and the ASEs member will be examined as per the arguments.
    
    Unlike with `readelf -h' output consider a failure to retrieve the
    member requested a test case failure rather than an unresolved result.
    This is because unlike with the `e_flags' member of the ELF file header
    which is always there in any valid ELF file the MIPS ABI Flags structure
    is optional in LD output and the absence of this structure when expected
    is surely a bug in LD.
    
    	ld/
    	* testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
    	Add an `args' final argument and examination code for `readelf
    	-A' output.  Update procedure description accordingly.

commit 1284e99a6ce362d342d6468e5caa39ddab574721
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 02:58:27 2017 +0100

    MIPS/LD/testsuite: mips-elf-flags: Use `remote_exec' to call `readelf'
    
    For ELF file header flag verification done in `good_combination' in the
    `mips-elf-flags.exp' test script the version of `readelf' built along
    with the rest of binutils has to be used rather than any such executable
    already present on the build system, so that flags recognized by the
    tool match those supported by LD being tested.  Use `remote_exec' as
    elsewhere in the LD test framework and also with GAS and LD used here,
    getting and arranging for extra reporting of `readelf' calls included in
    test logs on this occasion as well.
    
    	ld/
    	* testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
    	Use `remote_exec' to call `readelf'.  Log the command issued.

commit b1a2d7a0e57abc06e6ec99c88ca9992780f45f71
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jun 27 02:58:27 2017 +0100

    MIPS/LD/testsuite: mips-elf-flags: Use `-h' only with `readelf'
    
    For the purpose of link-time object compatibility handling verification
    code in the `good_combination' procedure from the `mips-elf-flags.exp'
    test script only examines the `e_flags' member of the ELF file header
    and ignores data from any ELF program or section headers present.  Use
    `readelf -h' rather than `readelf --headers' then to obtain data for
    examination, avoiding unnecessary processing to extract this extraneous
    information.
    
    	ld/
    	* testsuite/ld-mips-elf/mips-elf-flags.exp (good_combination):
    	Use `readelf -h' rather than `readelf --headers'.

commit a6cbf936e3dce68114d28cdf60d510a3f78a6d40
Author: Kuan-Lin Chen <rufus@andestech.com>
Date:   Thu Jun 8 11:54:14 2017 -0700

    RISC-V: Use pc-relative relocation for FDE initial location
    
    The symbol address in .eh_frame may be adjusted in
    _bfd_elf_discard_section_eh_frame, and the content of .eh_frame will be
    adjusted in _bfd_elf_write_section_eh_frame. Therefore, we cannot insert
    a relocation whose addend symbol is in .eh_frame. Othrewise, the value
    may be adjusted twice.
    
    bfd/ChangeLog
    2017-06-26  Kuan-Lin Chen  <rufus@andestech.com>
    
    	* elfnn-riscv.c (perform_relocation): Support the new
    	R_RISCV_32_PCREL relocation.
    	(riscv_elf_relocate_section): Likewise.
    	* elfxx-riscv.c (howto_table): Likewise.
    	(riscv_reloc_map): Likewise.
    	* bfd-in2.h (BFD_RELOC_RISCV_32_PCREL): New relocation.
    	* libbfd.h: Regenerate.
    
    gas/ChangeLog
    2017-06-26  Kuan-Lin Chen  <rufus@andestech.com>
    
    	* config/tc-riscv.c (md_apply_fix) [BFD_RELOC_32]: Convert to a
    	R_RISCV_32_PCREL relocation.
    
    include/ChangeLog
    2017-06-26  Kuan-Lin Chen  <rufus@andestech.com>
    
    	* elf/riscv.h (R_RISCV_32_PCREL): New.

commit 7211ae501eb0de1044983f2dfb00091a58fbd66c
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jun 27 09:45:04 2017 +0930

    More fixes for bfd_get_section_contents change
    
    	PR binutils/21665
    	* libbfd.c (_bfd_generic_get_section_contents): Delete abort.
    	Use unsigned file pointer type, and remove cast.
    	* libbfd.c (_bfd_generic_get_section_contents_in_window): Likewise.
    	Add "count", not "sz".

commit dc819143fe1d44970a3da4b9ebc7828fa2337115
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jun 27 00:01:02 2017 +0000

    Automatic date update in version.in

commit ab27f80c5dceaa23c4ba7f62c0d5d22a5d5dd7a1
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jun 27 00:21:25 2017 +0100

    Fix GDB regressions caused by previous bfd_get_section_contents changes
    
    Ref: https://sourceware.org/ml/binutils/2017-06/msg00343.html
    
    bfd/ChangeLog:
    2017-06-26  Pedro Alves  <palves@redhat.com>
    
    	PR binutils/21665
    	* libbfd.c (_bfd_generic_get_section_contents): Add "count", not
    	"sz".

commit 1f473e3d0ad285195934e6a077c7ed32afe66437
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jun 26 15:47:16 2017 -0700

    Add a missing line to _bfd_generic_get_section_contents_in_window
    
    	PR binutils/21665
    	* libbfd.c (_bfd_generic_get_section_contents_in_window): Add
    	a missing line.

commit b417536f2350881ad28952b3906a025a54d241bd
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Jun 26 19:20:50 2017 +0100

    MIPS/BFD: Consistently mark the LSI CW4010 as a MIPS II processor
    
    Make BFD agree with GAS and mark the LSI MiniRISC CW4010 processor core
    (for an odd reason referred to as LSI R4010 across our code base) as a
    MIPS II processor in BFD as well, fixing a bug that has been there since
    forever and addressing linker warnings like:
    
    $ as -m4010 empty.s -o 4010.o
    $ ld -r 4010.o -o 4010-r.o
    ld: 4010.o: warning: Inconsistent ISA between e_flags and .MIPS.abiflags
    $
    
    due to the ISA level being recorded as MIPS III in ELF file header's
    `e_flags' vs MIPS II in the MIPS ABI Flags section:
    
    $ readelf -Ah 4010.o
    ELF Header:
      Magic:   7f 45 4c 46 01 02 01 00 00 00 00 00 00 00 00 00
      Class:                             ELF32
      Data:                              2's complement, big endian
      Version:                           1 (current)
      OS/ABI:                            UNIX - System V
      ABI Version:                       0
      Type:                              REL (Relocatable file)
      Machine:                           MIPS R3000
      Version:                           0x1
      Entry point address:               0x0
      Start of program headers:          0 (bytes into file)
      Start of section headers:          348 (bytes into file)
      Flags:                             0x20821000, 4010, o32, mips3
      Size of this header:               52 (bytes)
      Size of program headers:           0 (bytes)
      Number of program headers:         0
      Size of section headers:           40 (bytes)
      Number of section headers:         11
      Section header string table index: 10
    Attribute Section: gnu
    File Attributes
      Tag_GNU_MIPS_ABI_FP: Hard float (double precision)
    
    MIPS ABI Flags Version: 0
    
    ISA: MIPS2
    GPR size: 32
    CPR1 size: 32
    CPR2 size: 0
    FP ABI: Hard float (double precision)
    ISA Extension: LSI R4010
    ASEs:
    	None
    FLAGS 1: 00000000
    FLAGS 2: 00000000
    $
    
    Available documentation[1][2] clearly indicates the LSI CW4010 processor
    is only backwards compatible with the MIPS R4000 processor as far as the
    latter's 32-bit instructions are concerned and consequently can only be
    considered a MIPS II ISA implementation (with vendor extensions).
    
    This fixes an LD testsuite failure:
    
    FAIL: MIPS incompatible objects:  "-march=r4010 -32"      "-march=r4650 -32"
    
    triggered for the `mips-sgi-irix5' and `mips-sgi-irix6' targets.
    
    References:
    
    [1] Paul Cobb, Bob Caulk, Joe Cesana, "The MiniRISC CW4010: A
        Superscalar MIPS Processor ASIC Core", LSI Logic, July 1995,
        presented at Hot Chips VII, Stanford University, Stanford,
        California, August 1995
    
    [2] "MiniRISC MR4010 Superscalar Microprocessor Reference Device", LSI
        Logic, November 1996, Doc. No. DB09-000028-00, Order No. C15017
    
    	bfd/
    	* cpu-mips.c (arch_info_struct): Mark the 4010 32-bit.
    	* elfxx-mips.c (mips_set_isa_flags) <bfd_mach_mips4010>: Set
    	E_MIPS_ARCH_2 rather than E_MIPS_ARCH_3 in `e_flags'.
    	(mips_mach_extensions): Mark `bfd_mach_mips4010' as extending
    	`bfd_mach_mips6000' rather than `bfd_mach_mips4000'.
    
    	ld/
    	* testsuite/ld-mips-elf/lsi-4010-isa.d: New test.
    	* ld/testsuite/ld-mips-elf/mips-elf.exp: Run the new test.

commit 0630b49c470ca2e3c3f74da4c7e4ff63440dd71f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jun 26 09:24:49 2017 -0700

    Check file size before getting section contents
    
    Don't check the section size in bfd_get_full_section_contents since
    the size of a decompressed section may be larger than the file size.
    Instead, check file size in _bfd_generic_get_section_contents.
    
    	PR binutils/21665
    	* compress.c (bfd_get_full_section_contents): Don't check the
    	file size here.
    	* libbfd.c (_bfd_generic_get_section_contents): Check for and
    	reject a section whoes size + offset is greater than the size
    	of the entire file.
    	(_bfd_generic_get_section_contents_in_window): Likewise.

commit 515a4464176efc6ac31c83bd40b5c67f61c3b044
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Jun 26 16:08:55 2017 +0100

    LD: Fix .startof.SECNAME/.sizeof.SECNAME tests for MIPS/IRIX
    
    Correct .startof.SECNAME/.sizeof.SECNAME tests for MIPS/IRIX targets,
    complementing commit dc74becf498f ("ld: Add tests for -Ur") and commit
    da614360f520 ("ld: Add tests for .startof.SECNAME/.sizeof.SECNAME") with
    subsequent updates, and in reference to commit cbd0eecf261c ("Always
    define referenced __start_SECNAME/__stop_SECNAME") and commit
    7dba9362c172 ("Rewrite __start and __stop symbol handling").
    
    These targets set the STT_OBJECT type for non-function symbol
    references, according to `elf_frob_symbol' code in gas/config/obj-elf.c:
    
      /* The Irix 5 and 6 assemblers set the type of any common symbol and
         any undefined non-function symbol to STT_OBJECT.  We try to be
         compatible, since newer Irix 5 and 6 linkers care.  However, we
         only set undefined symbols to be STT_OBJECT if we are on Irix,
         because that is the only time gcc will generate the necessary
         .global directives to mark functions.  */
    
      if (S_IS_COMMON (symp))
        symbol_get_bfdsym (symp)->flags |= BSF_OBJECT;
    
      if (strstr (TARGET_OS, "irix") != NULL
          && ! S_IS_DEFINED (symp)
          && (symbol_get_bfdsym (symp)->flags & BSF_FUNCTION) == 0)
        symbol_get_bfdsym (symp)->flags |= BSF_OBJECT;
    
    and consequently entries in the symbol table listing from `readelf'
    produced with these tests do not match the NOTYPE pattern expected,
    causing test suite failures:
    
    FAIL: ld-elf/sizeofa
    FAIL: ld-elf/sizeofc
    FAIL: ld-elf/startofa
    FAIL: ld-elf/startofc
    
    specifically with the `mips-sgi-irix5' and `mips-sgi-irix6' targets.
    
    Given that it does not matter for the feature covered by these tests
    whether the type of the symbols produced is STT_NOTYPE or STT_OBJECT
    adjust the problematic cases to accept either type, removing the
    failures observed.
    
    	ld/
    	* testsuite/ld-elf/sizeofa.d: Also accept the OBJECT type for
    	the symbols examined.
    	* testsuite/ld-elf/sizeofc.d: Likewise.
    	* testsuite/ld-elf/startofa.d: Likewise.
    	* testsuite/ld-elf/startofc.d: Likewise.

commit 873c08142c4c377d2d3ed0b1b1b9e262ddc06c61
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Jun 26 15:08:36 2017 +0200

    record-full: Remove unused function netorder16
    
    clang shows this warning:
    
      /home/emaisin/src/binutils-gdb/gdb/record-full.c:2344:1: error: unused function 'netorder16' [-Werror,-Wunused-function]
      netorder16 (uint16_t input)
      ^
    
    Remove this function, which, AFAIK, has never been used.  Note that GCC
    doesn't warn about this, because the function is marked as inline.
    According to gcc's man page, it should ideed not warn:
    
      -Wunused-function
        Warn whenever a static function is declared but not defined or a non-inline static function is unused.  This warning is enabled by -Wall.
    
    So it's probably not a GCC bug that it doesn't find this unused function, but a
    different definition of "unused".
    
    gdb/ChangeLog:
    
    	* record-full.c (netorder16): Remove.

commit 8b5a7a6e8ceb34f8e82aa361ee91ec25e0049774
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Jun 26 15:08:35 2017 +0200

    vec: Silence -Wunused-function warnings on clang
    
    clang has a too aggressive (or broken, depends on how you want to see
    it) -Wunused-function warning, which is triggered by the functions
    defined by DEF_VEC_* but not used in the current source file.  Normally,
    it won't warn about unused static inline functions defined in header
    files, because it's expected that a source file won't use all functions
    defined in a header file it includes.  However, if the DEF_VEC_* macro
    is used in a source file, it considers those functions as defined in the
    source file, which leads it to think that we should remove those
    functions.  It is therefore missing a check to see whether those
    functions are resulting from macro expansion.  A bug already exists for
    that:
    
      https://bugs.llvm.org//show_bug.cgi?id=22712
    
    It's quite easy to silence this warning in a localized way, that is in
    the DEF_VEC_* macros.
    
    gdb/ChangeLog:
    
    	* common/diagnostics.h: Define macros for GCC.
    	(DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
    	* common/vec.h: Include diagnostics.h.
    	(DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
    	(DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
    	warning.

commit d1435379df189d1c358ebd9776af8824a9158533
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Jun 26 15:08:35 2017 +0200

    ada-lex: Ignore warnings about register keyword
    
    Some older versions of flex (such as the one shipped with macOS) generate
    code that use the register keyword, which clang warns about.  This patch
    makes the compiler ignore those warnings for the portion of the code
    generated by flex.
    
    gdb/ChangeLog:
    
    	* common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
    	New macro.
    	* ada-lex.l: Ignore deprecated register warnings.

commit 04e15b4a9462cb1ae819e878a6009829aab8020b
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jun 26 15:46:34 2017 +0100

    Fix address violation parsing a corrupt texhex format file.
    
    	PR binutils/21670
    	* tekhex.c (getvalue): Check for the source pointer exceeding the
    	end pointer before the first byte is read.

commit cfd14a500e0485374596234de4db10e88ebc7618
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jun 26 15:25:08 2017 +0100

    Fix address violations when atempting to parse fuzzed binaries.
    
    	PR binutils/21665
    bfd	* opncls.c (get_build_id): Check that the section is beig enough
    	to contain the whole note.
    	* compress.c (bfd_get_full_section_contents): Check for and reject
    	a section whoes size is greater than the size of the entire file.
    	* elf32-v850.c (v850_elf_copy_notes): Allow for the ouput to not
    	contain a notes section.
    
    binutils* objdump.c (disassemble_section): Skip any section that is bigger
    	than the entire file.

commit 0602cdad745472ed2561d8096a4bb021c8d0301d
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jun 26 13:25:41 2017 +0100

    Produce a consistent warning message when attempting to run a tool on a directory.
    
    	PR binutils/21659
    	* bucomm.c (get_file_size): Explicitly warn if the file is a
    	directory.

commit a3aea05a66ec325ddd19b0c8dbe504958a295cd3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jun 26 05:11:07 2017 -0700

    Check unsupported .symver with common symbol
    
    The .symver directive on common symbol creates a new common symbol,
    which shouldn't be allowed, similar to alias on common symbol:
    
    $ cat y.S
    	.comm	bar,8,8
    	 .set bar1,bar
    $ as -o y.o y.S
    y.S: Assembler messages:
    y.S:2: Error: `bar1' can't be equated to common symbol 'bar'
    $
    
    	PR gas/21661
    	* config/obj-elf.c (obj_elf_symver): Don't allow .symver with
    	common symbol.
    	(elf_frob_symbol): Likewise.
    	* testsuite/gas/elf/elf.exp: Run pr21661.
    	* testsuite/gas/elf/pr21661.d: New file.
    	* testsuite/gas/elf/pr21661.s: Likewise.

commit fd52715cfa77b7e06f4ab5eadfe7946d22180adc
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Jun 26 11:07:17 2017 +0200

    Add pgste marker changelog

commit 93ec5e23766a9f75aa4950748cf73964028a8d1b
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Jun 26 11:01:58 2017 +0200

    S/390: Fix testsuite segfault added with recent pgste patch.
    
    The recent pgste patch caused several testcases to fail with a
    segfault.  Fixed with this patch by adding NULL pointer checks.
    
    regression-tested on s390x.
    
    bfd/ChangeLog:
    
    2017-06-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf64-s390.c (elf_s390_additional_program_headers): Add NULL
    	pointer checks.
    	(elf_s390_modify_segment_map): Likewise.
    	(bfd_elf_s390_set_options): Lisewise.

commit 49fa50ef9c59aa6d03bc2e33a25b2d832a9e692b
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jun 26 09:28:51 2017 +0100

    Fix compile time warning building gas for arm-wince target.
    
    	* config/tc-arm.c (fpu_any): Only define for ELF based targets.

commit cf9bdae906f897ae13563c03c65f325cad05bf1c
Author: claziss <claziss@synopsys.com>
Date:   Wed Jun 7 15:57:56 2017 +0200

    Update check conditions for illegal placed instructions.
    
    ARC cpus do not accept any jump or instructions with long immediate
    into the delay slots.
    
    gas/
    2017-06-07  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* /config/tc-arc.c (is_br_jmp_insn_p): Update macro with known
    	instructions to be accounted as jumps.
    	(assemble_insn): Check for limms into the delay slots.  Emit an
    	error if so.
    	* testsuite/gas/arc/asm-errors-3.d: New file.
    	* testsuite/gas/arc/asm-errors-3.err: Likewise.
    	* testsuite/gas/arc/asm-errors-3.s: Likewise.

commit 46adbd17408fda28aca5320e2247ede30b7e9649
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jun 26 00:00:38 2017 +0000

    Automatic date update in version.in

commit 57963c05b9911c3555add356a7cd9952d391dfe4
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jun 26 09:10:22 2017 +0930

    Don't attach linker created section to --just-syms bfd
    
    All sections on a --just-syms bfd are discarded from the output, so
    attaching linker created sections to such a bfd results in errors.
    In other cases, like the .note.GNU-stack check, it's wrong to have a
    --just-syms object potentially affect the output.
    
    bfd/
    	* elflink.c (_bfd_elf_link_create_dynstrtab): Don't make dynobj
    	a --just-syms bfd.
    	(_bfd_elf_size_group_sections): Skip --just-syms bfds.
    	(bfd_elf_size_dynamic_sections): Ignore .note.GNU-stack and
    	.preinit_array on --just-syms bfds.
    	(_bfd_elf_gc_mark_extra_sections): Skip --just-syms bfds.
    	(elf_gc_sweep, bfd_elf_parse_eh_frame_entries): Likewise.
    	(bfd_elf_gc_sections, bfd_elf_discard_info): Likewise.
    ld/
    	* emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Skip
    	--just-syms bfds when looking for a place to attach .note.gnu.build-id
    	and .eh_frame_hdr sections.  Delete dead code.

commit cc75e0fdaeb179efc66ddd1cb1b6da40e6adacc1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jun 25 12:57:13 2017 +0200

    main: Don't add int to string
    
    clang shows this warning:
    
      /home/emaisin/src/binutils-gdb/gdb/main.c:227:56: error: adding 'int' to a string does not append to the string [-Werror,-Wstring-plus-int]
                    char *tmp_sys_gdbinit = xstrdup (SYSTEM_GDBINIT + datadir_len);
                                                     ~~~~~~~~~~~~~~~^~~~~~~~~~~~~
      /home/emaisin/src/binutils-gdb/gdb/main.c:227:56: note: use array indexing to silence this warning
                    char *tmp_sys_gdbinit = xstrdup (SYSTEM_GDBINIT + datadir_len);
                                                                    ^
                                                     &              [            ]
    
    It's quite easy to get rid of it by using &foo[len] instead of foo + len.
    I think this warning is relevant to keep enabled, because it can be an
    easy mistake to do.
    
    This warning is already discussed here in GCC bugzilla:
    
      https://gcc.gnu.org/ml/gcc-patches/2017-06/msg00729.html
    
    and a patch series for it was submitted very recently.
    
    gdb/ChangeLog:
    
    	* main.c (get_init_files): Replace "SYSTEM_GDBINIT +
    	datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".

commit 07809eafc959a0c588663c0c949eaf8044a1b40a
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jun 25 12:49:19 2017 +0200

    dtrace-probe: Put semicolon after while on its own line
    
    clang shows this warning.
    
      /home/emaisin/src/binutils-gdb/gdb/dtrace-probe.c:424:52: error: while loop has empty body [-Werror,-Wempty-body]
                while (*p++ != '\0' && p - strtab < strtab_size);
                                                                ^
      /home/emaisin/src/binutils-gdb/gdb/dtrace-probe.c:424:52: note: put the semicolon on a separate line to silence this warning
    
    Putting the semicolon on its own line is not a big sacrifice to get rid of this
    warning.  I think it's also useful to keep this, because it can catch errors
    like this:
    
      while (something);
        {
          ...
        }
    
    although gcc would warn about it in a different way (misleading indentation).
    
    This warning is already discussed here in the GCC bugzilla:
    
      https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62184
    
    gdb/ChangeLog:
    
    	* dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
    	its own line.

commit f076f0349cb958b451872ce4a7987821533c2f49
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jun 25 12:38:59 2017 +0200

    x86-dregs: Print debug registers one per line
    
    This get around this warning given by clang...
    
      /home/emaisin/src/binutils-gdb/gdb/nat/x86-dregs.c:209:7: error: variable 'i' is incremented both in the loop header and in the loop body [-Werror,-Wfor-loop-analysis]
            i++;
            ^
      /home/emaisin/src/binutils-gdb/gdb/nat/x86-dregs.c:199:32: note: incremented here
        ALL_DEBUG_ADDRESS_REGISTERS (i)
                                   ^
    
    ... I decided in the end to simply print the debug registers one per
    line.  I don't think it particularly helps readability to have them two
    per line anyway.
    
    gdb/ChangeLog:
    
    	* nat/x86-dregs.c (x86_show_dr): Print registers one per line.

commit d7e2ebe7e73105766a854f4f0e3a5c509fd0e82a
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date:   Sun Jun 25 11:39:34 2017 +0200

    Sync libiberty with upstream GCC.
    
    libiberty/ChangeLog:
    
    	* d-demangle.c (dlang_identifier): Prefix mangled init symbols
    	with `initializer for'.
    	* testsuite/demangle-expected: Update tests.
    
    	* d-demangle.c (dlang_call_convention_p): Move declaration
    	before dlang_type.
    	(dlang_type): Handle function types.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_parse_real): Remove stack buffer, write
    	the demangled hexadecimal directly to string.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_hexdigit): New function.
    	(ascii2hex): Remove function.
    	(dlang_parse_string): Update to call dlang_hexdigit.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (strtol): Remove declaration.
    	Updated all callers to use dlang_number.
    	(dlang_number): New function.
    	(dlang_value): Moved check for ISDIGIT into dlang_parse_integer.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_parse_symbol): Remove function.
    	(dlang_parse_qualified): New function.
    	(dlang_parse_mangle): New function.
    	(dlang_type): Update to call dlang_parse_qualified.
    	(dlang_identifier): Update to call either dlang_parse_qualified or
    	dlang_parse_mangle.
    	(dlang_type_modifier_p): Remove function.
    	(dlang_call_convention_p): Don't allow type modifiers in mangle.
    	(dlang_template_args): Update to call dlang_identifier.
    	(dlang_demangle): Update to call dlang_parse_mangle.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_value): Add comment explaining why cases for
    	digits are required.
    	* testsuite/d-demangle-expected: Update integer value tests.
    
    	* d-demangle.c (dlang_parse_symbol): Skip over anonymous symbols.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_identifier): Handle template constraint symbols.
    	(dlang_parse_template): Only advance if template symbol prefix is
    	followed by a digit.
    	* testsuite/d-demangle-expected: Add tests.
    
    	* d-demangle.c (dlang_attributes): Handle scope attributes.
    	* testsuite/d-demangle-expected: Add tests.

commit 2d3392bd42e16b5c8894c357f250dbde245e96fe
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date:   Sun Jun 25 11:39:05 2017 +0200

    Sync libiberty with upstream GCC.
    
    libiberty/ChangeLog:
    
    	PR demangler/80513
    	* cp-demangle.c (d_number): Check for overflow.
    	* cplus-dem.c (consume_count): Fix overflow check.
    	(gnu_special): Check for underscore after thunk delta.
    	* testsuite/demangle-expected: Add tests for overflows and invalid
    	characters in thunks.
    
    	* cp-demangle.c (MAX_RECURSION_COUNT): New constant.
    	(struct d_print_info): Add recursion field.
    	(d_print_init): Initialize recursion.
    	(d_print_comp): Check and update d_print_info recursion depth.
    
    	* cp-demangle.c (d_substitution): Return NULL if d_add_substitution
    	fails.
    
    	* cp-demangle.h (struct d_info): Remove did_subs field.
    	* cp-demangle.c (struct d_info_checkpoint): Likewise.
    	(d_template_param): Don't update did_subs.
    	(d_substitution): Likewise.
    	(d_checkpoint): Don't assign did_subs.
    	(d_backtrack): Likewise.
    	(cplus_demangle_init_info): Don't initialize did_subs.

commit 5cc4ca837deac7dc962d8a3741aa120c50ab41da
Author: Sergei Trofimovich <slyfox@gentoo.org>
Date:   Sat Jun 24 18:40:41 2017 +0100

    fix out-of-bounds access in elf.c:find_link
    
    The out-of-bounds access is reproducible on 'ia64-strip' command
    (see sample from https://bugs.gentoo.org/show_bug.cgi?id=622500)
    
    The output file contains less section than original one.
    This tricks 'hint' access to go out-of-bounds:
    
    	* elf.c (find_link): Bounds check "hint".

commit b21351faa29dfa6deab3afcb5a2ee78548239274
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jun 25 00:00:40 2017 +0000

    Automatic date update in version.in

commit 0cda1e190dffc804d1f1ffc4bd849ffdca694914
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Sat Jun 24 10:56:32 2017 +0100

    [ARM] Add support for ARM Cortex-R52 processor
    
    === Context ===
    
    This patch is part of a patch series to add support for ARMv8-R
    architecture. Its purpose is to add support for ARM Cortex-R52
    processor.
    
    === Patch description ===
    
    This patch adds support for Cortex-R52 as an ARMv8-R processor with CRC
    extensions.
    
    2017-06-26  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gas/
    	* NEWS: Mention support of ARM Cortex-R52 processor.
    	* config/tc-arm.c (arm_cpus): Add entry for ARM Cortex-R52 processor.
    	* doc/c-arm.texi: Mention support for -mcpu=cortex-r52.

commit bff0500d7abc215bbc6d4e9332047c023f4ce2cb
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Sat Jun 24 10:48:08 2017 +0100

    [ARM] Add linker support for ARMv8-R
    
    === Context ===
    
    This patch is part of a patch series to add support for ARMv8-R
    architecture. Its purpose is to add support for ARMv8-R in the linker.
    
    === Patch description ===
    
    This patch is composed of 3 changes:
    
    1) The main change is the addition of the logic for merging a file whose
    Tag_CPU_arch build attribute is 15 (ARMv8-R). Namely, all pre-ARMv8 are
    merged into ARMv8-R as well as ARMv8-R itself. ARMv8-A (14) merges into
    ARMv8-A. ARMv8-M Baseline (16) and Mainline (17) are not allowed to
    merge merge with ARMv8-R. Note that merging only occurs if the two
    profiles are identical or one is S (Application or Realtime) and the
    other is R.
    
    2) using_thumb_only, using_thumb2_bl, using_thumb2 and arch_has_arm_nop
    are updated according to capabilities of ARMv8-R and their BFD_ASSERT
    updated to reflect that the logic is valid for ARMv8-R.
    
    3) 2 build attribute merging tests are added to test the first change.
    
    2017-06-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    bfd/
    	* elf32-arm.c (using_thumb_only): Update list of architectures in
    	BFD_ASSERT for which the logic is valid.
    	(using_thumb2_bl): Likewise.
    	(using_thumb2): Likewise and return true for ARMv8-R.
    	(arch_has_arm_nop): Likewise.
    	(tag_cpu_arch_combine): New v8r table for ARMv8-R Tag_CPU_arch
    	merging logic.  Update commentis for value 15 of v8m_baseline,
    	v8m_mainline and v4t_plus_v6_m arrays.  Use v8r array to decide
    	merging of value 15 of Tag_CPU_arch.
    
    ld/
    	* testsuite/ld-arm/arm-elf.exp (EABI attribute merging 11): New test.
    	(EABI attribute merging 12): Likewise.
    	* testsuite/ld-arm/attr-merge-11a.s: New file.
    	* testsuite/ld-arm/attr-merge-11b.s: New file.
    	* testsuite/ld-arm/attr-merge-11.attr: New file.
    	* testsuite/ld-arm/attr-merge-12a.s: New file.
    	* testsuite/ld-arm/attr-merge-12b.s: New file.
    	* testsuite/ld-arm/attr-merge-12.attr: New file.

commit ced40572e478927f43a849d5c39f794868da8d38
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Sat Jun 24 10:37:47 2017 +0100

    [ARM] Add support for ARMv8-R in assembler and readelf
    
    === Context ===
    
    This patch is part of a patch series to add support for ARMv8-R
    architecture. Its purpose is to add support for ARMv8-R in GAS:
    instructions, build attributes and readelf.
    
    === Patch description ===
    
    Although some differences exist for system registers, from GAS point of
    view ARMv8-R supports the same instructions as ARMv8-A Aarch32 state
    and a subset of its extensions. This patch therefore introduce a new
    feature bit to distinguish the availability of the pan, ras and rdma
    extensions between ARMv8-A and ARMv8-R and allow crypto, fp and simd
    extensions to be used by ARMv8-R.
    
    Most of the changes are then in the testsuite to (i) rename source files
    and error output to be shared between ARMv8-A and ARMv8-R, (ii) rename
    files with expected output for ARMv8-A build attributes and (iii) add
    new files with expected output for ARMv8-R build attributes.
    
    2017-06-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    binutils/
    	* readelf.c (arm_attr_tag_CPU_arch): Fill value for ARMv8-R.
    
    gas/
    	* NEWS: Mention support for ARMv8-R architecture.
    	* config/tc-arm.c (arm_archs): Add entry for ARMv8-R.
    	(arm_extensions): Restrict pan, ras and rdma extension to
    	ARMv8-A and make crypto, fp and simd extensions available to
    	ARMv8-R.
    	(cpu_arch_ver): Add entry for ARMv8-R.
    	(aeabi_set_public_attributes): Update gas_assert for Tag_DIV_use
    	logic.
    	* testsuite/gas/arm/armv8-a+fp.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar+fp.s: This.  Remove .arch directive.
    	* testsuite/gas/arm/armv8-a+fp.d: Specify source to assemble and
    	architecture to assemble for.
    	* testsuite/gas/arm/armv8-r+fp.d: New.
    	* testsuite/gas/arm/armv8-a+simd.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar+simd.s: This.  Remove .arch directive.
    	* testsuite/gas/arm/armv8-a+simd.d: Specify source to assemble and
    	architecture to assemble for.
    	* testsuite/gas/arm/armv8-r+simd.d: New.
    	* testsuite/gas/arm/armv8-a-bad.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar-bad.s: This.  Remove .arch directive.
    	* testsuite/gas/arm/armv8-a-bad.l: Rename into ...
    	* testsuite/gas/arm/armv8-ar-bad.l: This.  Decrement line number by 1.
    	* testsuite/gas/arm/armv8-a-bad.d: Specify source to assemble,
    	architecture to assemble for and adjust error output file.
    	* testsuite/gas/arm/armv8-r-bad.d: New.
    	* testsuite/gas/arm/armv8-a-barrier.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar-barrier.s: This.
    	* testsuite/gas/arm/armv8-a-barrier-arm.d: Adjust source.
    	* testsuite/gas/arm/armv8-a-barrier-thumb.d: Likewise.
    	* testsuite/gas/arm/armv8-r-barrier-arm.d: New.
    	* testsuite/gas/arm/armv8-r-barrier-thumb.d: New.
    	* testsuite/gas/arm/armv8-a-it-bad.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar-it-bad.s: This.  Remove .arch directive.
    	* testsuite/gas/arm/armv8-a-it-bad.l: Rename into ...
    	* testsuite/gas/arm/armv8-ar-it-bad.l: This.  Decrement line number
    	by 1.
    	* testsuite/gas/arm/armv8-a-it-bad.d: Specify source to assemble,
    	architecture to assemble for and adjust error output file.
    	* testsuite/gas/arm/armv8-r-it-bad.d: New.
    	* testsuite/gas/arm/armv8-a.s: Rename into ...
    	* testsuite/gas/arm/armv8-ar.s: This.  Remove .arch directive.
    	* testsuite/gas/arm/armv8-a.d: Specify source to assemble and
    	architecture to assemble for.
    	* testsuite/gas/arm/armv8-r.d: New.
    	* testsuite/gas/arm/attr-march-armv8-r+crypto.d: New.
    	* testsuite/gas/arm/attr-march-armv8-r+fp.d: New.
    	* testsuite/gas/arm/attr-march-armv8-r+simd.d: New.
    	* testsuite/gas/arm/attr-march-armv8-r.d: New.
    	* testsuite/gas/arm/crc32.s: Rename into ...
    	* testsuite/gas/arm/crc32-armv8-ar.s: This.
    	* testsuite/gas/arm/crc32.d: Rename into ...
    	* testsuite/gas/arm/crc32-armv8-a.d: This.  Specify source to assemble.
    	* testsuite/gas/arm/crc32-armv8-r.d: New.
    	* testsuite/gas/arm/crc32-bad.s: Rename into ...
    	* testsuite/gas/arm/crc32-armv8-ar-bad.s: This.
    	* testsuite/gas/arm/crc32-bad.d: Rename into ...
    	* testsuite/gas/arm/crc32-armv8-a-bad.d: This.  Specify source to
    	assemble.
    	* testsuite/gas/arm/crc32-armv8-r-bad.d: New.
    	* testsuite/gas/arm/mask_1.s: Rename into ...
    	* testsuite/gas/arm/mask_1-armv8-ar.s: This.
    	* testsuite/gas/arm/mask_1.d: Rename into ...
    	* testsuite/gas/arm/mask_1-armv8-a.d: This.  Specify source to
    	assemble.
    	* testsuite/gas/arm/mask_1-armv8-r.d: new.
    
    include/
    	* elf/arm.h (TAG_CPU_ARCH_V8R): New macro.
    	* opcode/arm.h (ARM_EXT2_V8A): New macro.
    	(ARM_AEXT2_V8A): Rename into ...
    	(ARM_AEXT2_V8AR): This.
    	(ARM_AEXT2_V8A): New macro.
    	(ARM_AEXT_V8R): New macro.
    	(ARM_AEXT2_V8R): New macro.
    	(ARM_ARCH_V8R): New macro.

commit 173205ca3356cab0590c2debaac97107fb9a7fcd
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Sat Jun 24 10:26:41 2017 +0100

    [ARM] Remove ARMv6S-M special casing
    
    === Context ===
    
    This patch is part of a patch series to add support for ARMv8-R
    architecture. Its purpose is to remove special casing for ARMv6S-M
    autodetection.
    
    === Motivation ===
    
    Currently, SWI and SVC mnemonics are enabled for ARMv4T and successor
    architectures with extra checks in the handler function (do_t_swi) to
    give an error message when ARMv6-M is targeted and some more special
    casing in aeabi_set_public_attributes. This was made to exclude these
    mnemonics for ARMv6-M unless the OS extension is in use.
    
    However this logic is superfluous: there is already code to check
    whether an instruction is available based on the feature bit it is part
    of and whether the targeted architecture has that feature bit. This
    patch aims at removing that unneeded complexity.
    
    === Patch description ===
    
    The OS extension is already limited to the ARMv6-M architecture so all
    this patch does is redefined availability of the ARM_EXT_OS feature bit
    to not be present for ARM_ARCH_V6M. ARM_ARCH_V6SM does not need any
    change either because it already includes ARM_EXT_OS.
    
    The patch also make sure that the error message that was given by
    do_t_swi when SWI/SVC is unavailable is still the same by detecting the
    situation in md_assemble.
    
    2017-06-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gas/
    	* config/tc-arm.c (arm_ext_v6m): Delete.
    	(arm_ext_v7m): Delete.
    	(arm_ext_m): Remove ARM_EXT_OS from the set of feature defined M
    	profile.
    	(arm_arch_v6m_only): Delete.
    	(do_t_swi): Remove special case for ARMv6S-M.
    	(md_assemble): Display error message previously in do_t_swi when
    	SVC is not available.
    	(insns): Guard swi and svc by arm_ext_os for Thumb mode.
    	(aeabi_set_public_attributes): Remove special case for ARMv6S-M.
    
    include/
    	* opcode/arm.h (ARM_AEXT_V4TxM): Add ARM_EXT_OS bit to the set.
    	(ARM_AEXT_V4T): Likewise.
    	(ARM_AEXT_V5TxM): Likewise.
    	(ARM_AEXT_V5T): Likewise.
    	(ARM_AEXT_V6M): Mask off ARM_EXT_OS bit.

commit 926770baf44bb47c41e85486957f4ae70b694837
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jun 24 00:00:42 2017 +0000

    Automatic date update in version.in

commit 9bdfdbf929d581cf845ffc815ae94a39d9f7b032
Author: Andrew Waterman <andrew@sifive.com>
Date:   Mon May 15 08:50:57 2017 -0700

    RISC-V: Fix SLTI disassembly
    
    2017-06-23  Andrew Waterman  <andrew@sifive.com>
    
    	* riscv-opc.c (riscv_opcodes): Mark I-type SLT instruction as an
    	alias; do not mark SLTI instruction as an alias.

commit 94f78a777c396fa1ce2f40d34afed1b6b5012196
Author: Andrew Waterman <andrew@sifive.com>
Date:   Wed May 10 23:59:50 2017 -0700

    RISC-V: Error, don't warn, for shfit amounts/CSRs
    
    gas/ChangeLog
    
    2017-05-11  Andrew Waterman  <andrew@sifive.com>
    
           * config/tc-riscv.c (riscv_ip): Changes as_warn to as_bad for improper
           shift amounts.

commit 4aa57d6a2bfc4e48fa6a685bfa164db5ae2e1c1c
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Thu Jun 22 12:04:42 2017 +0100

    [AArch64] Fix typo in comments on relocation name
    
    BFD_RELOC_AARCH64_ADR_GOTPAGE should be BFD_RELOC_AARCH64_ADR_GOT_PAGE.
    
    bfd/
      * reloc.c (BFD_RELOC_AARCH64_ADR_GOTPAGE): Rename to
      BFD_RELOC_AARCH64_ADR_GOT_PAGE
      * bfd-in2.h: Regenerated.

commit 7ee7ff7015840f2d0156bf386a050bd728d22fc4
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jun 23 20:39:43 2017 +0930

    [GOLD] PowerPC64 localentry:0 plt call optimization
    
    elfcpp/
    	* elfcpp.h (DT_PPC64_OPT): Define.
    	* powerpc.h (PPC64_OPT_TLS, PPC64_OPT_MULTI_TOC,
    	PPC64_OPT_LOCALENTRY): Define.
    gold/
    	* options.h (General_options): Add plt_localentry.
    	* powerpc.cc (Target_powerpc::st_other): New function.
    	(Target_powerpc::plt_localentry0_, plt_localentry0_init_,
    	has_localentry0_): New vars.
    	(Target_powerpc::plt_localentry0, set_has_localentry0,
    	is_elfv2_localentry0): New functions.
    	(Target_powerpc::Branch_info::mark_pltcall): Don't set tocsave or
    	return true for localentry:0 calls.
    	(Stub_table::Plt_stub_ent::localentry0_): New var.
    	(Stub_table::add_plt_call_entry): Set localentry0_ and has_localentry0_.
    	Don't set r2save_ for localentry:0 calls.
    	(Output_data_glink::do_write): Save r2 in __glink_PLTresolve for elfv2.
    	(Target_powerpc::scan_relocs): Default plt_localentry0_.
    	(Target_powerpc::do_finalize_sections): Set DT_PPC64_OPT.
    	(Target_powerpc::Relocate::relocate): Don't require nop following
    	calls for localentry:0 plt calls, and don't change nop.

commit 7e57d19e48f94ff9a19a9413cf25d1887e3a7f52
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jun 23 20:37:34 2017 +0930

    [GOLD] PowerPC64 tocsave
    
    This adds support to gold for the tocsave relocs already supported by
    ld.bfd.  R_PPC64_TOCSAVE relocs are part of a scheme to move r2 saves
    to the prologue of a function rather than in each plt call stub.  We
    don't want a compiler to always emit the r2 save, as this would be
    wasted if the calls turned out to be local.  See the tocsave*.s in
    ld/testsuite/ld-powerpc/.
    
    	* powerpc.cc (Target_powerpc::tocsave_loc_): New var.
    	(Target_powerpc::mark_pltcall, add_tocsave, tocsave_loc): New functions.
    	(Target_powerpc::Branch_info::tocsave_): New var.
    	(Target_powerpc::Branch_info::mark_pltcall): New function.
    	(Target_powerpc::Branch_info::make_stub): Pass tocsave_ to
    	add_plt_call_entry.
    	(Stub_table::Plt_stub_ent): Make public.  Add r2save_.
    	(Stub_table::add_plt_call_entry): Add bool tocsave_ param.  Set
    	r2save_.
    	(Stub_table::find_plt_call_entry): Return Plt_stub_ent*.  Adjust
    	use throughout.
    	(Stub_table::do_write): Conditionally output r2 save in plt stubs.
    	(Target_powerpc::Scan::local): Handle R_PPC64_TOCSAVE.
    	(Target_powerpc::Scan::global): Likewise.
    	(Target_powerpc::Relocate::relocate): Skip r2 save in plt call stub
    	with tocsave reloc.  Replace header tocsave nop with r2 save.
    	* symtab.h (struct Symbol_location_hash): Make public.

commit 0e158763b0c5671cd40cdd2faee48d6659489ddd
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Jun 23 10:22:36 2017 +0100

    Make the strings utility reject directories.
    
    	PR binutils/21659
    	* strings.c (strings_file): Warn about attempts to run strings on
    	a directory.

commit 0dd5cbc56307afaf6a366a8e78ef25cf9cefe514
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Jun 23 10:21:39 2017 +0100

    Add XTENSA_MAX_REGISTER_SIZE
    
    gdb/
    	* xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
    	(xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
    	(xtensa_register_read_masked): Likewise.

commit b4cbbe8f7294070cc93a71ace78f134965ddad82
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Thu Jun 8 17:24:50 2017 +0200

    S/390: Add support for pgste marker
    
    This patch adds a new S/390 specific segment type: PT_S390_PGSTE.  For
    binaries marked with that segment the kernel will allocate 4k page
    tables.  The only user so far will be qemu.
    
    ld/ChangeLog:
    
    2017-06-23  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* Makefile.in: Add s390.em as build dependency.
    	* emulparams/elf64_s390.sh (EXTRA_EM_FILE): Add s390.em.
    	* emultempl/s390.em: New file.
    	* gen-doc.texi: Add documentation for --s390-pgste option.
    	* ld.texinfo: Likewise.
    
    include/ChangeLog:
    
    2017-06-23  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf/s390.h (PT_S390_PGSTE): Define macro.
    
    binutils/ChangeLog:
    
    2017-06-23  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* readelf.c (get_s390_segment_type): Add support for the new
    	segment type PT_S390_PGSTE.
    	(get_segment_type): Call get_s390_segment_type.
    
    elfcpp/ChangeLog:
    
    2017-06-23  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elfcpp.h (enum PT): Add PT_S390_PGSTE to enum.
    
    bfd/ChangeLog:
    
    2017-06-23  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf-s390.h: New file.
    	* elf64-s390.c (struct elf_s390_link_hash_table): Add params
    	field.
    	(elf_s390_additional_program_headers): New function.
    	(elf_s390_modify_segment_map): New function.
    	(bfd_elf_s390_set_options): New function.
    	(elf_backend_additional_program_headers)
    	(elf_backend_modify_segment_map): Add macro definitions.

commit 790ba5c89893f31dabb6d8e85c8d4be61c52ad99
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jun 23 00:00:39 2017 +0000

    Automatic date update in version.in

commit 0056441823b1b1b2488dcf069b4feb55b00137ba
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jun 22 15:13:15 2017 -0700

    i386: Add hidden weak undefined tests
    
    	* testsuite/ld-i386/i386.exp: Run weakundef1 tests.
    	* testsuite/ld-i386/weakundef1.c: New file.

commit 5d8763a38211dd79459485ba0be4f76849ef8200
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jun 22 14:26:09 2017 -0700

    x86-64: Move the error_alignment label forward
    
    Move the error_alignment label forward to avoid clang warning on
    
    if (!bfd_set_section_alignment (ebfd, sec, 2))
      goto error_alignment;
    
    htab = elf_x86_64_hash_table (info);
    
    error_alignment:
      info->callbacks->einfo (_("%F%A: failed to align section\n"), sec);
                                 "%F" causes a fatal linker error and
    			     immediate exit.
    
    sec = htab->elf.sgotplt;
    
    Also fix alignment on program property note section.
    
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Move
    	the error_alignment label forward.  Properly align program
    	property note section.

commit 922109c7182858b005f55f6ac69bb6af145fc710
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jun 22 12:53:39 2017 -0700

    Pass $NOPIE_CFLAGS to ELF visibility tests
    
    	PR ld/21090
    	* testsuite/ld-elfvsb/elfvsb.exp (visibility_run): Pass
    	$NOPIE_CFLAGS if non-PIE is required.

commit 84da4cf89efed1df483914d06210daae79ce3eb8
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jun 22 12:53:39 2017 -0700

    x86: Resolve local undefined weak symbol to 0
    
    Local undefined weak symbol should always be resolved to 0.
    
    	* elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Resolve
    	local undefined weak symbol to 0.
    	* elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Likewise.

commit d4c6ce5b011b03c7e4a84b530cba1f9b56441131
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Thu Jun 22 14:50:24 2017 -0400

    Update comment on gdb_environ::unset
    
    gdb_environ::unset iterates using '.end () - 1' now, instead of '.cend
    () - 1'.  This obvious patch updates the comment.
    
    gdb/ChangeLog:
    2017-06-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* common/environ.c (gdb_environ::unset): Update comment.

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

Summary of changes:
 bfd/ChangeLog                                      |  172 ++++++
 bfd/archures.c                                     |    1 +
 bfd/bfd-in2.h                                      |   10 +-
 bfd/bfdio.c                                        |    8 +-
 bfd/compress.c                                     |    2 +-
 bfd/cpu-mips.c                                     |    5 +-
 bfd/elf-s390.h                                     |   29 +
 bfd/elf.c                                          |    6 +-
 bfd/elf32-arm.c                                    |   47 ++-
 bfd/elf32-avr.c                                    |    5 +-
 bfd/elf32-i386.c                                   |   12 +-
 bfd/elf32-v850.c                                   |    4 +-
 bfd/elf64-s390.c                                   |   81 +++
 bfd/elf64-x86-64.c                                 |   27 +-
 bfd/elflink.c                                      |   40 ++-
 bfd/elfnn-riscv.c                                  |    2 +
 bfd/elfxx-mips.c                                   |   28 +-
 bfd/elfxx-riscv.c                                  |   16 +
 bfd/libbfd.c                                       |   13 +-
 bfd/libbfd.h                                       |    1 +
 bfd/opncls.c                                       |   18 +-
 bfd/reloc.c                                        |    6 +-
 bfd/tekhex.c                                       |    4 +
 bfd/version.h                                      |    2 +-
 binutils/ChangeLog                                 |   45 ++
 binutils/NEWS                                      |    4 +
 binutils/bucomm.c                                  |    2 +
 binutils/objcopy.c                                 |   68 ++-
 binutils/objdump.c                                 |    6 +-
 binutils/readelf.c                                 |   42 ++-
 binutils/strings.c                                 |    5 +
 elfcpp/ChangeLog                                   |   10 +
 elfcpp/elfcpp.h                                    |    7 +-
 elfcpp/powerpc.h                                   |    8 +
 gas/ChangeLog                                      |  302 +++++++++++
 gas/NEWS                                           |    3 +
 gas/config/obj-elf.c                               |   15 +
 gas/config/tc-aarch64.c                            |   10 +-
 gas/config/tc-arc.c                                |   19 +-
 gas/config/tc-arm.c                                |  148 ++++--
 gas/config/tc-mips.c                               |   75 +++-
 gas/config/tc-riscv.c                              |   36 +-
 gas/doc/c-aarch64.texi                             |    2 +
 gas/doc/c-arm.texi                                 |    3 +
 gas/doc/c-mips.texi                                |    1 +
 gas/testsuite/gas/aarch64/dotproduct.d             |  548 ++++++++++++++++++++
 gas/testsuite/gas/aarch64/dotproduct.s             |  540 +++++++++++++++++++
 gas/testsuite/gas/arc/asm-errors-3.d               |    2 +
 gas/testsuite/gas/arc/asm-errors-3.err             |    7 +
 gas/testsuite/gas/arc/asm-errors-3.s               |   14 +
 gas/testsuite/gas/arm/armv8-a+fp.d                 |    2 +
 gas/testsuite/gas/arm/armv8-a+simd.d               |    2 +
 gas/testsuite/gas/arm/armv8-a-bad.d                |    4 +-
 gas/testsuite/gas/arm/armv8-a-bad.l                |   96 ----
 gas/testsuite/gas/arm/armv8-a-barrier-arm.d        |    2 +-
 gas/testsuite/gas/arm/armv8-a-barrier-thumb.d      |    2 +-
 gas/testsuite/gas/arm/armv8-a-it-bad.d             |    5 +-
 gas/testsuite/gas/arm/armv8-a-it-bad.l             |   18 -
 gas/testsuite/gas/arm/armv8-a.d                    |    2 +
 .../gas/arm/{armv8-a+fp.s => armv8-ar+fp.s}        |    1 -
 .../gas/arm/{armv8-a+simd.s => armv8-ar+simd.s}    |    1 -
 gas/testsuite/gas/arm/armv8-ar-bad.l               |   96 ++++
 .../gas/arm/{armv8-a-bad.s => armv8-ar-bad.s}      |    1 -
 .../arm/{armv8-a-barrier.s => armv8-ar-barrier.s}  |    0
 gas/testsuite/gas/arm/armv8-ar-it-bad.l            |   18 +
 .../arm/{armv8-a-it-bad.s => armv8-ar-it-bad.s}    |    1 -
 gas/testsuite/gas/arm/{armv8-a.s => armv8-ar.s}    |    0
 .../gas/arm/{armv8-a+fp.d => armv8-r+fp.d}         |    4 +-
 .../gas/arm/{armv8-a+simd.d => armv8-r+simd.d}     |    4 +-
 gas/testsuite/gas/arm/armv8-r-bad.d                |    4 +
 ...armv8-a-barrier-arm.d => armv8-r-barrier-arm.d} |    6 +-
 ...8-a-barrier-thumb.d => armv8-r-barrier-thumb.d} |    6 +-
 gas/testsuite/gas/arm/armv8-r-it-bad.d             |    4 +
 gas/testsuite/gas/arm/{armv8-a.d => armv8-r.d}     |    4 +-
 gas/testsuite/gas/arm/attr-march-armv8-r+crypto.d  |   18 +
 gas/testsuite/gas/arm/attr-march-armv8-r+fp.d      |   17 +
 gas/testsuite/gas/arm/attr-march-armv8-r+simd.d    |   18 +
 gas/testsuite/gas/arm/attr-march-armv8-r.d         |   16 +
 .../gas/arm/{crc32-bad.d => crc32-armv8-a-bad.d}   |    3 +-
 gas/testsuite/gas/arm/{crc32.d => crc32-armv8-a.d} |    3 +-
 .../gas/arm/{crc32-bad.s => crc32-armv8-ar-bad.s}  |    0
 .../gas/arm/{crc32.s => crc32-armv8-ar.s}          |    0
 .../gas/arm/{crc32-bad.d => crc32-armv8-r-bad.d}   |    5 +-
 gas/testsuite/gas/arm/{crc32.d => crc32-armv8-r.d} |    5 +-
 gas/testsuite/gas/arm/dotprod-illegal.d            |    2 +
 gas/testsuite/gas/arm/dotprod-illegal.l            |   10 +
 gas/testsuite/gas/arm/dotprod-illegal.s            |   16 +
 gas/testsuite/gas/arm/dotprod-legacy-arch.d        |    3 +
 gas/testsuite/gas/arm/dotprod-legacy-arch.l        |    3 +
 gas/testsuite/gas/arm/dotprod-thumb2.d             |  297 +++++++++++
 gas/testsuite/gas/arm/dotprod.d                    |  297 +++++++++++
 gas/testsuite/gas/arm/dotprod.s                    |   44 ++
 .../gas/arm/{mask_1.d => mask_1-armv8-a.d}         |    3 +-
 .../gas/arm/{mask_1.s => mask_1-armv8-ar.s}        |    0
 .../gas/arm/{mask_1.d => mask_1-armv8-r.d}         |    5 +-
 gas/testsuite/gas/elf/elf.exp                      |    1 +
 gas/testsuite/gas/elf/pr21661.d                    |    2 +
 gas/testsuite/gas/elf/pr21661.l                    |    3 +
 gas/testsuite/gas/elf/pr21661.s                    |    4 +
 gas/testsuite/gas/mips/attr-gnu-4-5.d              |    2 +-
 gas/testsuite/gas/mips/attr-gnu-4-6.d              |    2 +-
 gas/testsuite/gas/mips/attr-gnu-4-7.d              |    2 +-
 .../gas/mips/attr-none-o32-fp64-nooddspreg.d       |    2 +-
 gas/testsuite/gas/mips/attr-none-o32-fp64.d        |    2 +-
 gas/testsuite/gas/mips/attr-none-o32-fpxx.d        |    2 +-
 gas/testsuite/gas/mips/elf_mach_interaptiv-mr2.d   |   24 +
 .../gas/mips/interaptiv-mr2@isa-override-1.d       |    6 +
 .../gas/mips/interaptiv-mr2@isa-override-1.l       |    5 +
 .../gas/mips/interaptiv-mr2@isa-override-2.d       |    4 +
 .../gas/mips/interaptiv-mr2@isa-override-2.l       |    8 +
 gas/testsuite/gas/mips/interaptiv-mr2@mcu.d        |  110 ++++
 gas/testsuite/gas/mips/interaptiv-mr2@save-sub.d   |   44 ++
 gas/testsuite/gas/mips/interaptiv-mr2@save.d       |   44 ++
 gas/testsuite/gas/mips/mips.exp                    |   23 +-
 gas/testsuite/gas/mips/mips16@save-sub.d           |   65 +++
 gas/testsuite/gas/mips/mips16e2-copy-err.d         |    3 +
 gas/testsuite/gas/mips/mips16e2-copy-err.l         |   29 +
 gas/testsuite/gas/mips/mips16e2-copy-err.s         |   36 ++
 gas/testsuite/gas/mips/mips16e2-copy.d             |   32 ++
 gas/testsuite/gas/mips/mips16e2-copy.s             |   32 ++
 .../mips/mips16e2-interaptiv-mr2@mips16-asmacro.d  |   15 +
 .../mips/mips16e2-interaptiv-mr2@mips16-insn-e.d   |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16-insn-e.l   |  131 +++++
 .../mips/mips16e2-interaptiv-mr2@mips16-insn-t.d   |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16-insn-t.l   |   43 ++
 .../mips/mips16e2-interaptiv-mr2@mips16-macro-e.d  |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16-macro-e.l  |   56 ++
 .../mips/mips16e2-interaptiv-mr2@mips16-macro-t.d  |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16-macro-t.l  |   56 ++
 .../mips/mips16e2-interaptiv-mr2@mips16-macro.d    |    5 +
 .../mips/mips16e2-interaptiv-mr2@mips16-macro.l    |   12 +
 .../gas/mips/mips16e2-interaptiv-mr2@mips16-sub.d  |    6 +
 .../gas/mips/mips16e2-interaptiv-mr2@mips16-sub.l  |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16e-64-sub.d  |    6 +
 .../mips/mips16e2-interaptiv-mr2@mips16e-64-sub.l  |    4 +
 .../gas/mips/mips16e2-interaptiv-mr2@mips16e-64.d  |    4 +
 .../gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.d |    6 +
 .../gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.l |    4 +
 .../mips/mips16e2-interaptiv-mr2@mips16e2-mt-sub.d |   22 +
 .../mips/{mips16e-save.d => mips16e@save-sub.d}    |    9 +-
 gas/testsuite/gas/mips/mips1@save-sub.d            |   44 ++
 gas/testsuite/gas/mips/mips2@save-sub.d            |    5 +
 gas/testsuite/gas/mips/mips32@save-sub.d           |    5 +
 gas/testsuite/gas/mips/mips3@save-sub.d            |    5 +
 gas/testsuite/gas/mips/mips4@save-sub.d            |    5 +
 gas/testsuite/gas/mips/mips5@save-sub.d            |    5 +
 gas/testsuite/gas/mips/mips64@save-sub.d           |    5 +
 gas/testsuite/gas/mips/octeon2@save-sub.d          |   44 ++
 gas/testsuite/gas/mips/octeon3@save-sub.d          |    5 +
 gas/testsuite/gas/mips/r3000@save-sub.d            |    5 +
 gas/testsuite/gas/mips/r3900@save-sub.d            |    5 +
 gas/testsuite/gas/mips/r4000@save-sub.d            |    5 +
 gas/testsuite/gas/mips/r5900@save-sub.d            |    5 +
 gas/testsuite/gas/mips/save-err.d                  |    3 +
 .../gas/mips/{mips16e-save-err.l => save-err.l}    |    0
 .../gas/mips/{mips16e-save-err.s => save-err.s}    |    2 +-
 gas/testsuite/gas/mips/save-sub.d                  |   43 ++
 gas/testsuite/gas/mips/save-sub.s                  |    2 +
 gas/testsuite/gas/mips/{mips16e-save.d => save.d}  |    8 +-
 gas/testsuite/gas/mips/{mips16e-save.s => save.s}  |    8 +-
 gas/testsuite/gas/mips/sb1@save-sub.d              |    5 +
 gas/testsuite/gas/mips/vr5400@save-sub.d           |    5 +
 gas/testsuite/gas/mips/xlr@save-sub.d              |    5 +
 gdb/ChangeLog                                      |  123 +++++
 gdb/ada-lex.l                                      |   10 +
 gdb/c-exp.y                                        |   10 +-
 gdb/c-lang.c                                       |    7 +-
 gdb/command.h                                      |    1 +
 gdb/common/diagnostics.h                           |   20 +-
 gdb/common/environ.c                               |    2 +-
 gdb/common/vec.h                                   |   25 +
 gdb/d-exp.y                                        |   11 +-
 gdb/darwin-nat.c                                   |   78 ++--
 gdb/dtrace-probe.c                                 |    3 +-
 gdb/dwarf2loc.c                                    |    7 +-
 gdb/dwarf2read.c                                   |   33 +-
 gdb/gdb_obstack.h                                  |   15 +
 gdb/go-exp.y                                       |    9 +-
 gdb/linux-tdep.c                                   |    7 +-
 gdb/main.c                                         |    2 +-
 gdb/mi/mi-cmd-break.c                              |    4 +-
 gdb/nat/x86-dregs.c                                |   16 +-
 gdb/objfiles.c                                     |   15 +-
 gdb/objfiles.h                                     |   32 +-
 gdb/printcmd.c                                     |   12 +-
 gdb/record-full.c                                  |   10 -
 gdb/remote-sim.c                                   |   38 +-
 gdb/rust-exp.y                                     |   15 +-
 gdb/symfile.c                                      |   25 +-
 gdb/symtab.c                                       |   40 +-
 gdb/testsuite/ChangeLog                            |    6 +
 gdb/testsuite/gdb.base/reread-readsym.c            |   22 +
 gdb/testsuite/gdb.base/reread-readsym.exp          |   61 +++
 gdb/utils.c                                        |   24 +-
 gdb/utils.h                                        |    3 -
 gdb/valprint.c                                     |   17 +-
 gdb/xtensa-tdep.c                                  |    7 +-
 gold/ChangeLog                                     |   39 ++
 gold/options.h                                     |    4 +
 gold/powerpc.cc                                    |  387 ++++++++++++---
 gold/symtab.h                                      |   20 +-
 include/ChangeLog                                  |   52 ++
 include/elf/arm.h                                  |    1 +
 include/elf/mips.h                                 |    2 +
 include/elf/riscv.h                                |    1 +
 include/elf/s390.h                                 |    3 +
 include/opcode/aarch64.h                           |    2 +
 include/opcode/arm.h                               |   24 +-
 include/opcode/mips.h                              |   21 +-
 ld/ChangeLog                                       |   76 +++
 ld/Makefile.in                                     |    1 +
 ld/emulparams/elf64_s390.sh                        |    1 +
 ld/emultempl/elf32.em                              |   10 +-
 ld/emultempl/s390.em                               |   64 +++
 ld/gen-doc.texi                                    |    1 +
 ld/ld.texinfo                                      |   31 ++
 ld/testsuite/ld-arm/arm-elf.exp                    |    6 +
 ld/testsuite/ld-arm/attr-merge-11.attr             |    9 +
 ld/testsuite/ld-arm/attr-merge-11a.s               |    5 +
 ld/testsuite/ld-arm/attr-merge-11b.s               |    5 +
 ld/testsuite/ld-arm/attr-merge-12.attr             |    9 +
 ld/testsuite/ld-arm/attr-merge-12a.s               |    5 +
 ld/testsuite/ld-arm/attr-merge-12b.s               |    5 +
 ld/testsuite/ld-avr/pr13402.d                      |   16 +
 ld/testsuite/ld-avr/pr13402.s                      |    9 +
 ld/testsuite/ld-elf/sizeofa.d                      |    4 +-
 ld/testsuite/ld-elf/sizeofc.d                      |    4 +-
 ld/testsuite/ld-elf/startofa.d                     |    4 +-
 ld/testsuite/ld-elf/startofc.d                     |    4 +-
 ld/testsuite/ld-elfvsb/elfvsb.exp                  |    5 +-
 ld/testsuite/ld-i386/i386.exp                      |   26 +
 ld/testsuite/ld-i386/weakundef1.c                  |   16 +
 ld/testsuite/ld-mips-elf/lsi-4010-isa.d            |   23 +
 ld/testsuite/ld-mips-elf/mips-elf-flags.exp        |  107 ++++-
 ld/testsuite/ld-mips-elf/mips-elf.exp              |    3 +
 libiberty/ChangeLog                                |  102 ++++
 libiberty/cp-demangle.c                            |   28 +-
 libiberty/cp-demangle.h                            |    4 -
 libiberty/cplus-dem.c                              |   16 +-
 libiberty/d-demangle.c                             |  518 ++++++++++---------
 libiberty/testsuite/d-demangle-expected            |  252 +++++++++-
 libiberty/testsuite/demangle-expected              |   15 +
 opcodes/ChangeLog                                  |   39 ++
 opcodes/aarch64-asm.c                              |   14 +
 opcodes/aarch64-dis-2.c                            |  382 ++++++++-------
 opcodes/aarch64-dis.c                              |   15 +
 opcodes/aarch64-tbl.h                              |   24 +
 opcodes/arm-dis.c                                  |    6 +
 opcodes/mips-dis.c                                 |  180 ++++---
 opcodes/mips-formats.h                             |    7 +-
 opcodes/mips-opc.c                                 |   11 +
 opcodes/mips16-opc.c                               |    6 +
 opcodes/riscv-opc.c                                |    4 +-
 253 files changed, 6752 insertions(+), 1205 deletions(-)
 create mode 100644 bfd/elf-s390.h
 create mode 100644 gas/testsuite/gas/aarch64/dotproduct.d
 create mode 100644 gas/testsuite/gas/aarch64/dotproduct.s
 create mode 100644 gas/testsuite/gas/arc/asm-errors-3.d
 create mode 100644 gas/testsuite/gas/arc/asm-errors-3.err
 create mode 100644 gas/testsuite/gas/arc/asm-errors-3.s
 delete mode 100644 gas/testsuite/gas/arm/armv8-a-bad.l
 delete mode 100644 gas/testsuite/gas/arm/armv8-a-it-bad.l
 rename gas/testsuite/gas/arm/{armv8-a+fp.s => armv8-ar+fp.s} (99%)
 rename gas/testsuite/gas/arm/{armv8-a+simd.s => armv8-ar+simd.s} (99%)
 create mode 100644 gas/testsuite/gas/arm/armv8-ar-bad.l
 rename gas/testsuite/gas/arm/{armv8-a-bad.s => armv8-ar-bad.s} (99%)
 rename gas/testsuite/gas/arm/{armv8-a-barrier.s => armv8-ar-barrier.s} (100%)
 create mode 100644 gas/testsuite/gas/arm/armv8-ar-it-bad.l
 rename gas/testsuite/gas/arm/{armv8-a-it-bad.s => armv8-ar-it-bad.s} (98%)
 rename gas/testsuite/gas/arm/{armv8-a.s => armv8-ar.s} (100%)
 copy gas/testsuite/gas/arm/{armv8-a+fp.d => armv8-r+fp.d} (98%)
 copy gas/testsuite/gas/arm/{armv8-a+simd.d => armv8-r+simd.d} (98%)
 create mode 100644 gas/testsuite/gas/arm/armv8-r-bad.d
 copy gas/testsuite/gas/arm/{armv8-a-barrier-arm.d => armv8-r-barrier-arm.d} (89%)
 copy gas/testsuite/gas/arm/{armv8-a-barrier-thumb.d => armv8-r-barrier-thumb.d} (89%)
 create mode 100644 gas/testsuite/gas/arm/armv8-r-it-bad.d
 copy gas/testsuite/gas/arm/{armv8-a.d => armv8-r.d} (98%)
 create mode 100644 gas/testsuite/gas/arm/attr-march-armv8-r+crypto.d
 create mode 100644 gas/testsuite/gas/arm/attr-march-armv8-r+fp.d
 create mode 100644 gas/testsuite/gas/arm/attr-march-armv8-r+simd.d
 create mode 100644 gas/testsuite/gas/arm/attr-march-armv8-r.d
 copy gas/testsuite/gas/arm/{crc32-bad.d => crc32-armv8-a-bad.d} (92%)
 copy gas/testsuite/gas/arm/{crc32.d => crc32-armv8-a.d} (92%)
 rename gas/testsuite/gas/arm/{crc32-bad.s => crc32-armv8-ar-bad.s} (100%)
 rename gas/testsuite/gas/arm/{crc32.s => crc32-armv8-ar.s} (100%)
 rename gas/testsuite/gas/arm/{crc32-bad.d => crc32-armv8-r-bad.d} (89%)
 rename gas/testsuite/gas/arm/{crc32.d => crc32-armv8-r.d} (89%)
 create mode 100644 gas/testsuite/gas/arm/dotprod-illegal.d
 create mode 100644 gas/testsuite/gas/arm/dotprod-illegal.l
 create mode 100644 gas/testsuite/gas/arm/dotprod-illegal.s
 create mode 100644 gas/testsuite/gas/arm/dotprod-legacy-arch.d
 create mode 100644 gas/testsuite/gas/arm/dotprod-legacy-arch.l
 create mode 100644 gas/testsuite/gas/arm/dotprod-thumb2.d
 create mode 100644 gas/testsuite/gas/arm/dotprod.d
 create mode 100644 gas/testsuite/gas/arm/dotprod.s
 copy gas/testsuite/gas/arm/{mask_1.d => mask_1-armv8-a.d} (93%)
 rename gas/testsuite/gas/arm/{mask_1.s => mask_1-armv8-ar.s} (100%)
 rename gas/testsuite/gas/arm/{mask_1.d => mask_1-armv8-r.d} (92%)
 create mode 100644 gas/testsuite/gas/elf/pr21661.d
 create mode 100644 gas/testsuite/gas/elf/pr21661.l
 create mode 100644 gas/testsuite/gas/elf/pr21661.s
 create mode 100644 gas/testsuite/gas/mips/elf_mach_interaptiv-mr2.d
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@isa-override-1.d
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@isa-override-1.l
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@isa-override-2.d
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@isa-override-2.l
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@mcu.d
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/interaptiv-mr2@save.d
 create mode 100644 gas/testsuite/gas/mips/mips16@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-copy-err.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-copy-err.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-copy-err.s
 create mode 100644 gas/testsuite/gas/mips/mips16e2-copy.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-copy.s
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-asmacro.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-e.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-e.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-t.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-insn-t.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-e.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-e.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-t.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro-t.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-macro.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16-sub.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64-sub.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-64.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e-sub.l
 create mode 100644 gas/testsuite/gas/mips/mips16e2-interaptiv-mr2@mips16e2-mt-sub.d
 copy gas/testsuite/gas/mips/{mips16e-save.d => mips16e@save-sub.d} (92%)
 create mode 100644 gas/testsuite/gas/mips/mips1@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips2@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips32@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips3@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips4@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips5@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/mips64@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/octeon2@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/octeon3@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/r3000@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/r3900@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/r4000@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/r5900@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/save-err.d
 rename gas/testsuite/gas/mips/{mips16e-save-err.l => save-err.l} (100%)
 rename gas/testsuite/gas/mips/{mips16e-save-err.s => save-err.s} (96%)
 create mode 100644 gas/testsuite/gas/mips/save-sub.d
 create mode 100644 gas/testsuite/gas/mips/save-sub.s
 rename gas/testsuite/gas/mips/{mips16e-save.d => save.d} (92%)
 rename gas/testsuite/gas/mips/{mips16e-save.s => save.s} (90%)
 create mode 100644 gas/testsuite/gas/mips/sb1@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/vr5400@save-sub.d
 create mode 100644 gas/testsuite/gas/mips/xlr@save-sub.d
 create mode 100644 gdb/testsuite/gdb.base/reread-readsym.c
 create mode 100644 gdb/testsuite/gdb.base/reread-readsym.exp
 create mode 100644 ld/emultempl/s390.em
 create mode 100644 ld/testsuite/ld-arm/attr-merge-11.attr
 create mode 100644 ld/testsuite/ld-arm/attr-merge-11a.s
 create mode 100644 ld/testsuite/ld-arm/attr-merge-11b.s
 create mode 100644 ld/testsuite/ld-arm/attr-merge-12.attr
 create mode 100644 ld/testsuite/ld-arm/attr-merge-12a.s
 create mode 100644 ld/testsuite/ld-arm/attr-merge-12b.s
 create mode 100644 ld/testsuite/ld-avr/pr13402.d
 create mode 100644 ld/testsuite/ld-avr/pr13402.s
 create mode 100644 ld/testsuite/ld-i386/weakundef1.c
 create mode 100644 ld/testsuite/ld-mips-elf/lsi-4010-isa.d

First 500 lines of diff:
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index cdd6c35..ad9eecb 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,158 @@
+2017-06-28  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* libbfd.c (_bfd_generic_get_section_contents): Don't call
+	bfd_get_file_size.  Check archive element size.
+	(_bfd_generic_get_section_contents_in_window): Likewise.
+
+2017-06-28  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* bfd-in2.h: Regenerated.
+	* bfdio.c (bfd_get_size): Change return type to ufile_ptr.
+	(bfd_get_file_size): Likewise.
+
+2017-06-28  Maciej W. Rozycki  <macro@imgtec.com>
+	    Matthew Fortune  <matthew.fortune@imgtec.com>
+
+	* archures.c (bfd_mach_mips_interaptiv_mr2): New macro.
+	* cpu-mips.c (I_interaptiv_mr2): New enum value.
+	(arch_info_struct): Add "mips:interaptiv-mr2" entry.
+	* elfxx-mips.c (_bfd_elf_mips_mach) <E_MIPS_MACH_IAMR2>: New
+	case.
+	(mips_set_isa_flags) <bfd_mach_mips_interaptiv_mr2>: Likewise.
+	(bfd_mips_isa_ext) <bfd_mach_mips_interaptiv_mr2>: Likewise.
+	(print_mips_isa_ext) <AFL_EXT_INTERAPTIV_MR2>: Likewise.
+	(mips_mach_extensions): Add `bfd_mach_mipsisa32r3' and
+	`bfd_mach_mips_interaptiv_mr2' entries.
+	* bfd-in2.h: Regenerate.
+
+2017-06-27  Nick Clifton  <nickc@redhat.com>
+
+	* tekhex.c (pass_over): Revert accidental conversion of a local
+	array to a static array.
+
+2017-06-27  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
+
+	PR ld/13402
+	* elf32-avr.c (elf32_avr_adjust_diff_reloc_value): Adjust
+	reloc addend if necessary. Adjust diff only if
+	shrinked_insn_address < end_address.
+
+2017-06-27  Alan Modra  <amodra@gmail.com>
+
+	PR binutils/21665
+	* libbfd.c (_bfd_generic_get_section_contents): Warning fix.
+	(_bfd_generic_get_section_contents_in_window): Likewise.
+
+2017-06-26  Kuan-Lin Chen  <rufus@andestech.com>
+
+	* elfnn-riscv.c (perform_relocation): Support the new
+	R_RISCV_32_PCREL relocation.
+	(riscv_elf_relocate_section): Likewise.
+	* elfxx-riscv.c (howto_table): Likewise.
+	(riscv_reloc_map): Likewise.
+	* bfd-in2.h (BFD_RELOC_RISCV_32_PCREL): New relocation.
+	* libbfd.h: Regenerate.
+
+2017-06-27  Alan Modra  <amodra@gmail.com>
+
+	PR binutils/21665
+	* libbfd.c (_bfd_generic_get_section_contents): Delete abort.
+	Use unsigned file pointer type, and remove cast.
+	* libbfd.c (_bfd_generic_get_section_contents_in_window): Likewise.
+	Add "count", not "sz".
+
+2017-06-26  Pedro Alves  <palves@redhat.com>
+
+	PR binutils/21665
+	* libbfd.c (_bfd_generic_get_section_contents): Add "count", not
+	"sz".
+
+2017-06-26  H.J. Lu  <hongjiu.lu@intel.com>
+
+	PR binutils/21665
+	* libbfd.c (_bfd_generic_get_section_contents_in_window): Add
+	a missing line.
+
+2017-06-26  Maciej W. Rozycki  <macro@imgtec.com>
+
+	* cpu-mips.c (arch_info_struct): Mark the 4010 32-bit.
+	* elfxx-mips.c (mips_set_isa_flags) <bfd_mach_mips4010>: Set
+	E_MIPS_ARCH_2 rather than E_MIPS_ARCH_3 in `e_flags'.
+	(mips_mach_extensions): Mark `bfd_mach_mips4010' as extending
+	`bfd_mach_mips6000' rather than `bfd_mach_mips4000'.
+
+2017-06-26  H.J. Lu  <hongjiu.lu@intel.com>
+
+	PR binutils/21665
+	* compress.c (bfd_get_full_section_contents): Don't check the
+	file size here.
+	* libbfd.c (_bfd_generic_get_section_contents): Check for and
+	reject a section whose size + offset is greater than the size
+	of the entire file.
+	(_bfd_generic_get_section_contents_in_window): Likewise.
+
+2017-06-26  Nick Clifton  <nickc@redhat.com>
+
+	PR binutils/21670
+	* tekhex.c (getvalue): Check for the source pointer exceeding the
+	end pointer before the first byte is read.
+
+2017-06-26  Nick Clifton  <nickc@redhat.com>
+
+	PR binutils/21665
+	* opncls.c (get_build_id): Check that the section is big enough
+	to contain the whole note.
+	* compress.c (bfd_get_full_section_contents): Check for and reject
+	a section whose size is greater than the size of the entire file.
+	* elf32-v850.c (v850_elf_copy_notes): Allow for the ouput to not
+	contain a notes section.
+
+2017-06-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
+
+	* elf64-s390.c (elf_s390_additional_program_headers): Add NULL
+	pointer checks.
+	(elf_s390_modify_segment_map): Likewise.
+	(bfd_elf_s390_set_options): Lisewise.
+
+2017-06-26  Alan Modra  <amodra@gmail.com>
+
+	* elflink.c (_bfd_elf_link_create_dynstrtab): Don't make dynobj
+	a --just-syms bfd.
+	(_bfd_elf_size_group_sections): Skip --just-syms bfds.
+	(bfd_elf_size_dynamic_sections): Ignore .note.GNU-stack and
+	.preinit_array on --just-syms bfds.
+	(_bfd_elf_gc_mark_extra_sections): Skip --just-syms bfds.
+	(elf_gc_sweep, bfd_elf_parse_eh_frame_entries): Likewise.
+	(bfd_elf_gc_sections, bfd_elf_discard_info): Likewise.
+
+2017-06-25  Sergei Trofimovich  <slyfox@gentoo.org>
+
+	* elf.c (find_link): Bounds check "hint".
+
+2017-06-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
+
+	* elf32-arm.c (using_thumb_only): Update list of architectures in
+	BFD_ASSERT for which the logic is valid.
+	(using_thumb2_bl): Likewise.
+	(using_thumb2): Likewise and return true for ARMv8-R.
+	(arch_has_arm_nop): Likewise.
+	(tag_cpu_arch_combine): New v8r table for ARMv8-R Tag_CPU_arch
+	merging logic.  Update commentis for value 15 of v8m_baseline,
+	v8m_mainline and v4t_plus_v6_m arrays.  Use v8r array to decide
+	merging of value 15 of Tag_CPU_arch.
+
+2017-06-23  Jiong Wang  <jiong.wang@arm.com>
+
+	* reloc.c (BFD_RELOC_AARCH64_ADR_GOTPAGE): Rename to
+	BFD_RELOC_AARCH64_ADR_GOT_PAGE
+	* bfd-in2.h: Regenerate.
+
+2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
+
+	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Move
+	the error_alignment label forward.  Properly align program
+	property note section.
+
 2017-06-22  Eric Christopher  <echristo@gmail.com>
 
 	* elf32-arm.c (elf32_arm_final_link_relocate): Use labs rather than
@@ -5,6 +160,12 @@
 
 2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* elf32-i386.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Resolve
+	local undefined weak symbol to 0.
+	* elf64-x86-64.c (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Likewise.
+
+2017-06-22  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* elf32-i386.c (elf_i386_merge_gnu_properties): If info->shstk
 	is set, turn on GNU_PROPERTY_X86_FEATURE_1_SHSTK.
 	(elf_i386_link_setup_gnu_properties): If info->shstk is set,
@@ -138,6 +299,17 @@
 	allocation so that loops can be caught.  Check for NULL pointers
 	when processing a group list.
 
+2017-06-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
+
+	* elf-s390.h: New file.
+	* elf64-s390.c (struct elf_s390_link_hash_table): Add params
+	field.
+	(elf_s390_additional_program_headers): New function.
+	(elf_s390_modify_segment_map): New function.
+	(bfd_elf_s390_set_options): New function.
+	(elf_backend_additional_program_headers)
+	(elf_backend_modify_segment_map): Add macro definitions.
+
 2017-06-19  H.J. Lu  <hongjiu.lu@intel.com>
 
 	PR ld/21626
diff --git a/bfd/archures.c b/bfd/archures.c
index 2fefec5..433b95f 100644
--- a/bfd/archures.c
+++ b/bfd/archures.c
@@ -200,6 +200,7 @@ DESCRIPTION
 .#define bfd_mach_mips_octeon2		6502
 .#define bfd_mach_mips_octeon3          6503
 .#define bfd_mach_mips_xlr              887682   {* decimal 'XLR'  *}
+.#define bfd_mach_mips_interaptiv_mr2   736550   {* decimal 'IA2'  *}
 .#define bfd_mach_mipsisa32             32
 .#define bfd_mach_mipsisa32r2           33
 .#define bfd_mach_mipsisa32r3           34
diff --git a/bfd/bfd-in2.h b/bfd/bfd-in2.h
index 4348793..1343780 100644
--- a/bfd/bfd-in2.h
+++ b/bfd/bfd-in2.h
@@ -1240,9 +1240,9 @@ char *bfd_follow_build_id_debuglink (bfd *abfd, const char *dir);
 /* Extracted from bfdio.c.  */
 long bfd_get_mtime (bfd *abfd);
 
-file_ptr bfd_get_size (bfd *abfd);
+ufile_ptr bfd_get_size (bfd *abfd);
 
-file_ptr bfd_get_file_size (bfd *abfd);
+ufile_ptr bfd_get_file_size (bfd *abfd);
 
 void *bfd_mmap (bfd *abfd, void *addr, bfd_size_type len,
     int prot, int flags, file_ptr offset,
@@ -2059,6 +2059,7 @@ enum bfd_architecture
 #define bfd_mach_mips_octeon2          6502
 #define bfd_mach_mips_octeon3          6503
 #define bfd_mach_mips_xlr              887682   /* decimal 'XLR'  */
+#define bfd_mach_mips_interaptiv_mr2   736550   /* decimal 'IA2'  */
 #define bfd_mach_mipsisa32             32
 #define bfd_mach_mipsisa32r2           33
 #define bfd_mach_mipsisa32r3           34
@@ -4771,6 +4772,7 @@ number for the SBIC, SBIS, SBI and CBI instructions  */
   BFD_RELOC_RISCV_SET8,
   BFD_RELOC_RISCV_SET16,
   BFD_RELOC_RISCV_SET32,
+  BFD_RELOC_RISCV_32_PCREL,
 
 /* Renesas RL78 Relocations.  */
   BFD_RELOC_RL78_NEG8,
@@ -6014,12 +6016,12 @@ conjunction with BFD_RELOC_AARCH64_LD64_GOT_LO12_NC.  */
 
 /* Unsigned 12 bit byte offset for 64 bit load/store from the page of
 the GOT entry for this symbol.  Used in conjunction with
-BFD_RELOC_AARCH64_ADR_GOTPAGE.  Valid in LP64 ABI only.  */
+BFD_RELOC_AARCH64_ADR_GOT_PAGE.  Valid in LP64 ABI only.  */
   BFD_RELOC_AARCH64_LD64_GOT_LO12_NC,
 
 /* Unsigned 12 bit byte offset for 32 bit load/store from the page of
 the GOT entry for this symbol.  Used in conjunction with
-BFD_RELOC_AARCH64_ADR_GOTPAGE.  Valid in ILP32 ABI only.  */
+BFD_RELOC_AARCH64_ADR_GOT_PAGE.  Valid in ILP32 ABI only.  */
   BFD_RELOC_AARCH64_LD32_GOT_LO12_NC,
 
 /* Unsigned 16 bit byte offset for 64 bit load/store from the GOT entry
diff --git a/bfd/bfdio.c b/bfd/bfdio.c
index e301570..fa7fb21 100644
--- a/bfd/bfdio.c
+++ b/bfd/bfdio.c
@@ -392,7 +392,7 @@ FUNCTION
 	bfd_get_size
 
 SYNOPSIS
-	file_ptr bfd_get_size (bfd *abfd);
+	ufile_ptr bfd_get_size (bfd *abfd);
 
 DESCRIPTION
 	Return the file size (as read from file system) for the file
@@ -420,7 +420,7 @@ DESCRIPTION
 	size reasonable?".
 */
 
-file_ptr
+ufile_ptr
 bfd_get_size (bfd *abfd)
 {
   struct stat buf;
@@ -439,7 +439,7 @@ FUNCTION
 	bfd_get_file_size
 
 SYNOPSIS
-	file_ptr bfd_get_file_size (bfd *abfd);
+	ufile_ptr bfd_get_file_size (bfd *abfd);
 
 DESCRIPTION
 	Return the file size (as read from file system) for the file
@@ -448,7 +448,7 @@ DESCRIPTION
 
 */
 
-file_ptr
+ufile_ptr
 bfd_get_file_size (bfd *abfd)
 {
   if (abfd->my_archive != NULL
diff --git a/bfd/compress.c b/bfd/compress.c
index c854a20..ef549f9 100644
--- a/bfd/compress.c
+++ b/bfd/compress.c
@@ -254,7 +254,7 @@ bfd_get_full_section_contents (bfd *abfd, sec_ptr sec, bfd_byte **ptr)
 		  /* xgettext:c-format */
 		  (_("error: %B(%A) is too large (%#lx bytes)"),
 		  abfd, sec, (long) sz);
-	    return FALSE;
+	      return FALSE;
 	    }
 	}
 
diff --git a/bfd/cpu-mips.c b/bfd/cpu-mips.c
index b9ecdd6..2493094 100644
--- a/bfd/cpu-mips.c
+++ b/bfd/cpu-mips.c
@@ -104,6 +104,7 @@ enum
   I_mipsocteon2,
   I_mipsocteon3,
   I_xlr,
+  I_interaptiv_mr2,
   I_micromips
 };
 
@@ -114,7 +115,7 @@ static const bfd_arch_info_type arch_info_struct[] =
   N (32, 32, bfd_mach_mips3000, "mips:3000",      FALSE, NN(I_mips3000)),
   N (32, 32, bfd_mach_mips3900, "mips:3900",      FALSE, NN(I_mips3900)),
   N (64, 64, bfd_mach_mips4000, "mips:4000",      FALSE, NN(I_mips4000)),
-  N (64, 64, bfd_mach_mips4010, "mips:4010",      FALSE, NN(I_mips4010)),
+  N (32, 32, bfd_mach_mips4010, "mips:4010",      FALSE, NN(I_mips4010)),
   N (64, 64, bfd_mach_mips4100, "mips:4100",      FALSE, NN(I_mips4100)),
   N (64, 64, bfd_mach_mips4111, "mips:4111",      FALSE, NN(I_mips4111)),
   N (64, 64, bfd_mach_mips4120, "mips:4120",      FALSE, NN(I_mips4120)),
@@ -155,6 +156,8 @@ static const bfd_arch_info_type arch_info_struct[] =
   N (64, 64, bfd_mach_mips_octeon2,"mips:octeon2",  FALSE, NN(I_mipsocteon2)),
   N (64, 64, bfd_mach_mips_octeon3, "mips:octeon3",  FALSE, NN(I_mipsocteon3)),
   N (64, 64, bfd_mach_mips_xlr, "mips:xlr",       FALSE, NN(I_xlr)),
+  N (32, 32, bfd_mach_mips_interaptiv_mr2, "mips:interaptiv-mr2", FALSE,
+     NN(I_interaptiv_mr2)),
   N (64, 64, bfd_mach_mips_micromips,"mips:micromips",FALSE,0)
 };
 
diff --git a/bfd/elf-s390.h b/bfd/elf-s390.h
new file mode 100644
index 0000000..b37ec18
--- /dev/null
+++ b/bfd/elf-s390.h
@@ -0,0 +1,29 @@
+/* S/390-specific support for ELF.
+   Copyright (C) 2017 Free Software Foundation, Inc.
+
+   This file is part of BFD, the Binary File Descriptor library.
+
+   This program is free software; you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation; either version 3 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program; if not, write to the Free Software
+   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
+   MA 02110-1301, USA.  */
+
+/* Used to pass info between ld and bfd.  */
+struct s390_elf_params
+{
+  /* Tell the kernel to allocate 4k page tables.  */
+  int pgste;
+};
+
+bfd_boolean bfd_elf_s390_set_options (struct bfd_link_info *info,
+				      struct s390_elf_params *params);
diff --git a/bfd/elf.c b/bfd/elf.c
index 5f37e7f..76c6a5c 100644
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -1283,7 +1283,8 @@ section_match (const Elf_Internal_Shdr * a,
    to be the correct section.  */
 
 static unsigned int
-find_link (const bfd * obfd, const Elf_Internal_Shdr * iheader, const unsigned int hint)
+find_link (const bfd *obfd, const Elf_Internal_Shdr *iheader,
+	   const unsigned int hint)
 {
   Elf_Internal_Shdr ** oheaders = elf_elfsections (obfd);
   unsigned int i;
@@ -1291,7 +1292,8 @@ find_link (const bfd * obfd, const Elf_Internal_Shdr * iheader, const unsigned i
   BFD_ASSERT (iheader != NULL);
 
   /* See PR 20922 for a reproducer of the NULL test.  */
-  if (oheaders[hint] != NULL
+  if (hint < elf_numsections (obfd)
+      && oheaders[hint] != NULL
       && section_match (oheaders[hint], iheader))
     return hint;
 
diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
index e499b0e..b9f5d04 100644
--- a/bfd/elf32-arm.c
+++ b/bfd/elf32-arm.c
@@ -3567,9 +3567,7 @@ using_thumb_only (struct elf32_arm_link_hash_table *globals)
   arch = bfd_elf_get_obj_attr_int (globals->obfd, OBJ_ATTR_PROC, Tag_CPU_arch);
 
   /* Force return logic to be reviewed for each new architecture.  */
-  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8
-	      || arch == TAG_CPU_ARCH_V8M_BASE
-	      || arch == TAG_CPU_ARCH_V8M_MAIN);
+  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8M_MAIN);
 
   if (arch == TAG_CPU_ARCH_V6_M
       || arch == TAG_CPU_ARCH_V6S_M
@@ -3596,14 +3594,13 @@ using_thumb2 (struct elf32_arm_link_hash_table *globals)
   arch = bfd_elf_get_obj_attr_int (globals->obfd, OBJ_ATTR_PROC, Tag_CPU_arch);
 
   /* Force return logic to be reviewed for each new architecture.  */
-  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8
-	      || arch == TAG_CPU_ARCH_V8M_BASE
-	      || arch == TAG_CPU_ARCH_V8M_MAIN);
+  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8M_MAIN);
 
   return (arch == TAG_CPU_ARCH_V6T2
 	  || arch == TAG_CPU_ARCH_V7
 	  || arch == TAG_CPU_ARCH_V7E_M
 	  || arch == TAG_CPU_ARCH_V8
+	  || arch == TAG_CPU_ARCH_V8R
 	  || arch == TAG_CPU_ARCH_V8M_MAIN);
 }
 
@@ -3616,9 +3613,7 @@ using_thumb2_bl (struct elf32_arm_link_hash_table *globals)
     bfd_elf_get_obj_attr_int (globals->obfd, OBJ_ATTR_PROC, Tag_CPU_arch);
 
   /* Force return logic to be reviewed for each new architecture.  */
-  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8
-	      || arch == TAG_CPU_ARCH_V8M_BASE
-	      || arch == TAG_CPU_ARCH_V8M_MAIN);
+  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8M_MAIN);
 
   /* Architecture was introduced after ARMv6T2 (eg. ARMv6-M).  */
   return (arch == TAG_CPU_ARCH_V6T2
@@ -3824,14 +3819,13 @@ arch_has_arm_nop (struct elf32_arm_link_hash_table *globals)
 					     Tag_CPU_arch);
 
   /* Force return logic to be reviewed for each new architecture.  */
-  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8
-	      || arch == TAG_CPU_ARCH_V8M_BASE
-	      || arch == TAG_CPU_ARCH_V8M_MAIN);
+  BFD_ASSERT (arch <= TAG_CPU_ARCH_V8M_MAIN);
 
   return (arch == TAG_CPU_ARCH_V6T2
 	  || arch == TAG_CPU_ARCH_V6K
 	  || arch == TAG_CPU_ARCH_V7
-	  || arch == TAG_CPU_ARCH_V8);
+	  || arch == TAG_CPU_ARCH_V8
+	  || arch == TAG_CPU_ARCH_V8R);
 }
 
 static bfd_boolean
@@ -13329,6 +13323,25 @@ tag_cpu_arch_combine (bfd *ibfd, int oldtag, int *secondary_compat_out,
       T(V8),		/* V7E_M.  */
       T(V8)		/* V8.  */
     };
+  const int v8r[] =
+    {
+      T(V8R),		/* PRE_V4.  */
+      T(V8R),		/* V4.  */
+      T(V8R),		/* V4T.  */
+      T(V8R),		/* V5T.  */
+      T(V8R),		/* V5TE.  */
+      T(V8R),		/* V5TEJ.  */
+      T(V8R),		/* V6.  */
+      T(V8R),		/* V6KZ.  */
+      T(V8R),		/* V6T2.  */
+      T(V8R),		/* V6K.  */
+      T(V8R),		/* V7.  */
+      T(V8R),		/* V6_M.  */
+      T(V8R),		/* V6S_M.  */
+      T(V8R),		/* V7E_M.  */
+      T(V8),		/* V8.  */
+      T(V8R),		/* V8R.  */
+    };
   const int v8m_baseline[] =
     {
       -1,		/* PRE_V4.  */
@@ -13346,7 +13359,7 @@ tag_cpu_arch_combine (bfd *ibfd, int oldtag, int *secondary_compat_out,
       T(V8M_BASE),	/* V6S_M.  */
       -1,		/* V7E_M.  */
       -1,		/* V8.  */
-      -1,
+      -1,		/* V8R.  */
       T(V8M_BASE)	/* V8-M BASELINE.  */
     };
   const int v8m_mainline[] =
@@ -13366,7 +13379,7 @@ tag_cpu_arch_combine (bfd *ibfd, int oldtag, int *secondary_compat_out,
       T(V8M_MAIN),	/* V6S_M.  */
       T(V8M_MAIN),	/* V7E_M.  */
       -1,		/* V8.  */
-      -1,
+      -1,		/* V8R.  */
       T(V8M_MAIN),	/* V8-M BASELINE.  */
       T(V8M_MAIN)	/* V8-M MAINLINE.  */
     };


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


             reply	other threads:[~2017-06-28 21:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-28 21:21 jkratoch [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-06-22 20:03 jkratoch
2017-06-22 18:34 jkratoch
2017-06-18 19:30 jkratoch
2017-06-09  5:59 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=20170628212154.70625.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).