This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Created tag users/hjl/linux/release/2.29.51.0.1


The unsigned tag 'users/hjl/linux/release/2.29.51.0.1' was created pointing to:

 4ba8500... Merge remote-tracking branch 'origin/users/hjl/linux/master

Tagger: H.J. Lu <hjl.tools@gmail.com>
Date: Fri Jan 19 03:25:34 2018 -0800

    Linux binutils 2.29.51.0.1

Diff:

Summary of changes (added commits):
-----------------------------------

  4ba8500... Merge remote-tracking branch 'origin/users/hjl/linux/master
  c935ff0... Revert "Add "-z textonly" option to ELF linker" (*)
  d653114... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  564e11c... Optimize the performance of the group_setup function. (*)
  b5b6200... Fix compile time warning building aout targeted architectur (*)
  5ae5d3f... pr22374 function pointer initialization (*)
  a78eea1... Fix override of common symbols for a.out (*)
  87e79a6... Fixes for "Ignore dynamic references on forced local symbol (*)
  58807c4... _bfd_mips_elf_final_link: Notify user about wrong .reginfo  (*)
  97a232d... Add -z undefs option to the ELF linker. (*)
  33eff4c... ld: Replace "-z textonly" with "-z separate-code" (*)
  cf9e7f1... x86-64: Add tests for -z separate-code -z max-page-size=0x1 (*)
  d346bb2... ld: Add tests for -z separate-code and -z noseparate-code (*)
  2888249... ld: Create a new LOAD segment for separate code segment (*)
  47acac1... ld: Add "-z separate-code" option to ELF linker (*)
  6181e9c... gdb_compile_shlib: Only consider shlib= options when buildi (*)
  89a7f79... Automatic date update in version.in (*)
  d664fd4... Ignore dynamic references on forced local symbols (*)
  71d378a... gdb.base/breakpoint-in-ro-region.exp regression on sss targ (*)
  8b6f4cd... ld: Keep PREINIT_ARRAY/INIT_ARRAY/FINI_ARRAY sections for - (*)
  65f1486... ld: Remove unused expression state (*)
  eab62f2... ld: Fix issue where PROVIDE overrides defined symbol (*)
  8be965c... ld: Find and run some tests using a wildcard pattern (*)
  b3b9f8d... ld: In map file use '=' in PROVIDE statements (*)
  6bd0a31... Fix the order of SHLIB_RODATA_ADDR in elf.sc (*)
  754452f... Fix gdb.texinfo for old makeinfo (*)
  3cada74... Fix backwards compatibility with old GDBservers (PR remote/ (*)
  888a89d... Remove VL variants for 4FMAPS and 4VNNIW insns. (*)
  710d7ea... Automatic date update in version.in (*)
  b90d5ba... gas tc-arm.c warning fix (*)
  618daa9... language_get_symbol_name_matcher -> get_symbol_name_matcher (*)
  c63d3e8... Ada: make verbatim matcher override other language matchers (*)
  d4c2a40... Fix gdb.ada/complete.exp's "complete break ada" test (PR gd (*)
  8825213... Fix gdb.ada/bp_c_mixed_case.exp (PR gdb/22670) (*)
  7ec0cd5... oops - updates to ChangeLog omitted by accident from previo (*)
  bf41f30... Update top level configure files by synchronizing them with (*)
  2a8ae71... Update the libiberty sources with the latest patches found  (*)
  cbda583... x86: fix Disp8 handling for scalar AVX512_4FMAPS insns (*)
  c9e9227... x86: fix Disp8 handling for AVX512VL VPCMP*{B,W} variants (*)
  35fd2b2... RISC-V: Disassemble x0 based addresses as 0. (*)
  d9ccd46... Automatic date update in version.in (*)
  2d97a5d... Document support for 'info proc' on FreeBSD. (*)
  92fce24... Support 'info proc' for native FreeBSD processes. (*)
  262f62f... Use gdb::unique_xmalloc_ptr<> instead of a deleter that inv (*)
  b999e20... Don't return stale data from fbsd_pid_to_exec_file for kern (*)
  d217622... Support 'info proc' for FreeBSD process core dumps. (*)
  74ccf6d... Add explicit shared check to eh-frame-hdr test. (*)
  91d8b67... [Arm] Add CSDB instruction (*)
  be2e7d9... Add support for the AArch64's CSDB instruction. (*)
  b1dc180... Fix breakpoint add on inlined function using function name. (*)
  6cef73f... PR22662, nds32: Fix a typographical error. (*)
  7615ca1... RISC-V: Fix accidental embedded -shared regressions. (*)
  933ea65... Automatic date update in version.in (*)
  9eed002... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  9c4ac40... hurd: Add enough auxv support for AT_ENTRY for PIE binaries (*)
  704a705... x86: Properly encode vmovd with 64-bit memeory (*)
  605fd3c... Fix GDBserver build failure when $development is false (*)
  1e5ded6... Fix GDB build failure when $development is false (*)
  9f86398... Fix second-to-last gdb/testsuite/ChangeLog entry. (*)
  30066b0... Relax expected output in gdb.ada/access_tagged_param.exp te (*)
  102e936... Add a description of the X86_64 assembler's .largcomm pseud (*)
  04bafb1... (Ada) Fix print of array using non-contiguous enumeration i (*)
  e09efd5... Automatic date update in version.in (*)
  518817b... Remove dwarf2_cu::dwarf2_per_objfile (*)
  ed2dc61... Remove dwarf2_per_objfile global (*)
  e3b9454... Replace objfile field in dwarf2_cu and dwarf2_per_cu_data w (*)
  2cc0503... Make parse_debug_format_options return an std::string (*)
  b01ba14... Replace VEC(converted_character_d) with std::vector (*)
  4d0fdd9... Replace VEC(gdb_xml_value_s) with std::vector (*)
  f979c73... Remove xmethod_worker::clone (*)
  ba18742... C++ify xmethod_worker, get rid of VEC(xmethod_worker_ptr) (*)
  d672364... Automatic date update in version.in (*)
  35eeb78... RISC-V: Print symbol address for jalr w/ zero offset. (*)
  77a502c... Automatic date update in version.in (*)
  be1dce2... RISC-V: Disable shared library support for embedded elf. (*)
  e379cee... Fix regression: cannot start with LD_PRELOAD=libSegFault.so (*)
  a655456... Fix gdb/spu-tdep.c build breakage (*)
  de63c46... Fix regresssion(internal-error) printing subprogram argumen (*)
  f98fc17... Fix gdb.ada/info_addr_mixed_case.exp (PR gdb/22670) (*)
  342f824... (Ada) problem printing renaming which references a subprogr (*)
  7150d33... (Ada) Fix Length attribute on array access (*)
  cc0e770... memory error printing component of record from convenience  (*)
  f79da88... fix date of latest gdb/ChangeLog entry (*)
  672a41a... Fix email address in latest gdb/testsuite/ChangeLog entry (*)
  e3861a0... (Ada) Remove printing of array's first index when unneeded (*)
  cd385f9... Update NEWS post GDB 8.1 branch creation. (*)
  09aca94... Bump version to 8.1.50.DATE-git. (*)
  5219ac6... Automatic date update in version.in (*)
  645a2c5... RISC-V: Add 2 missing privileged registers. (*)
  7365ec2... gdb.ada/maint_with_ada.exp: New testcase (*)
  289483b... Add new gdb.ada/bp_c_mixed_case testcase for PR gdb/22670 (*)
  344420d... Add "complete break ada" test to gdb.ada/complete.exp (*)
  66fc87a... Add gdb.ada/info_addr_mixed_case new testcase (*)
  c40d7e4... Automatic date update in version.in (*)
  ddb2bbc... Create pseudo sections for FreeBSD NT_PROCSTAT_(PROC|FILES| (*)
  f13974b... Fix compile time warning introduced by previous delta. (*)
  6f156d7... Add support for v3 binary annotation notes. (*)
  9f757bf... (Ada) New command to stop at start of exception handler. (*)
  219d1af... Update year range in copyright notice of binutils files (*)
  1e56386... ChangeLog rotation (*)
  bd570f8... Unbreak spurious fails in gdb.base/step-line.exp (*)
  39f2fa1... Automatic date update in version.in (*)
  43724d1... Fix compile time warning (in the ARM simulator) about a pri (*)
  806ab1c... Fix typo in do_mrs function in ARM assembler. (*)
  1508bbf... x86: partial revert of 10c17abdd0 (*)
  9fe561a... [gdb/Ada] slices of arrays with dynamic strides (*)
  a405673... Add support for dynamic DW_AT_byte_stride. (*)
  74a2f8f... treat Ada DW_TAG_unspecified_type DIEs as stub types (*)
  e2882c8... Update copyright year range in all GDB files (*)
  1690bb2... gdb/copyright.py: Remove testsuite/gdb.base/step-line.{c,in (*)
  0f0c98a... gdb/copyright.py: Do not forget to remind about MULTIPLE_CO (*)
  82e1e79... Update copyright year in version message of GDB, GDBserver  (*)
  053f54e... Yearly rotation of the gdb/ChangeLog file (*)
  87e4655... Automatic date update in version.in (*)
  c76ff69... Automatic date update in version.in (*)
  47fea87... Avoid indexing std::vector past the end (*)
  cfa27c3... Only ignore -Wenum-compare-switch if it exists (*)
  132448f... dwarf2read: Silence -Wenum-compare-switch warning (*)
  e9d9f57... C++-ify parser_state (*)
  a594729... Automatic date update in version.in (*)
  fc898b4... Make mapped_debug_names and mapped_index final (*)
  0436426... Ignore warning about using different types of enums in swit (*)
  502a625... Remove unnecessary call to get_thread_db_info (*)
  4b2dfff... Automatic date update in version.in (*)
  ffd727c... Automatic date update in version.in (*)
  d9be0c1... RISC-V: Add missing privileged spec registers. (*)
  4ee2b64... Remove unused HP-UX TARGET_OBJECT_ enums (*)
  0f83318... Automatic date update in version.in (*)
  cef0f86... tdesc: handle arbitrary strings in tdesc_register_in_reggro (*)
  f7efd54... reggroups: Add reggroup_gdbarch_new, reggroup_find for dyna (*)
  c1166ca... reggroups: Convert reggroups from post_init to pre_init (*)
  b67d92b... reggroups: Add test and docs for `info reg $reggroup` featu (*)
  76bce0d... Automatic date update in version.in (*)
  a811763... Automatic date update in version.in (*)
  dc6af97... Automatic date update in version.in (*)
  a6c42a6... Automatic date update in version.in (*)
  6e8c24f... Add ATTRIBUTE_PRINTF to printf_field_type_assignment (*)
  5c8833d... Automatic date update in version.in (*)
  845756a... Automatic date update in version.in (*)
  a8d2e58... Do not emit "field_type" var if not needed on "maint print  (*)
  27e9ff8... Remove write-only assignment in rs6000-tdep.c (*)
  6eab0ea... Automatic date update in version.in (*)
  21a186f... RISC-V: Add compressed instruction hints, and a few misc cl (*)
  396d398... [Cell/B.E.] Fix regression due to gdbarch_significant_addr_ (*)
  175654b... Fix ChangeLog formatting (*)
  0a16b29... Automatic date update in version.in (*)
  7bbac84... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  00c2093... Correct disassembly of dot product instructions. (*)
  a3b3345... Add support for V_4B so we can properly reject it. (*)
  bef7475... Stop readelf from complaining about relocation sections wit (*)
  be62dca... Automatic date update in version.in (*)
  63f452a... PR22626, invalid dynindx used for dynamic relocs against se (*)
  f795c49... Test binutils_assemble return value (*)
  c54207d... Decode expression lists used with DW_AT_byte_size and other (*)
  4f58889... Resolve PR 22493 - the encoding to be used when pushing the (*)
  10c17ab... x86: fold certain AVX and AVX2 templates (*)
  1b54b8d... x86: fold RegXMM/RegYMM/RegZMM into RegSIMD (*)
  ca0d63f... x86: drop FloatReg and FloatAcc (*)
  dc821c5... x86: replace Reg8, Reg16, Reg32, and Reg64 (*)
  eccab96... improved error message when getting an exception printing a (*)
  0e2da9f... (Ada) crash assigning to record component which is an array (*)
  cb923fc... Ada: fix bad handling in ada_convert_actual (*)
  7d47b06... Automatic date update in version.in (*)
  390c91c... x86: Check pseudo prefix without instruction (*)
  fd7055f... Automatic date update in version.in (*)
  38af182... gdb: Fix function parameter alignments in or1k-tdep.c. (*)
  b282f0f... gdb: Add news entries for new or1k target. (*)
  46afe19... Fix ARI warning on gdb/typeprint.c:whatis_exp (*)
  09da3ec... Automatic date update in version.in (*)
  7c16183... Implement pahole-like 'ptype /o' option (*)
  a27ed7d... Reorganize code to handle TYPE_CODE_{STRUCT,UNION} on 'c_ty (*)
  fc076a4... Update documentation regarding the bfd returned by bfd_open (*)
  68f81d6... Fix PR19061, gdb hangs/spins-on-cpu when debugging any prog (*)
  1af17fd... Skip 'maintenance check xml-descriptions' if XML is disable (*)
  97d4fac... Skip parse_memory_map_tests if XML is disabled (*)
  fbc2255... Fix disassembly for PowerPC (*)
  141975a... x86: correct operand type checks (*)
  93b71a2... x86: drop stray CheckRegSize uses (*)
  c5d0745... x86: correct abort check (*)
  2778747... [GOLD] PR22602, handle __tls_get_addr forwarders properly (*)
  828d584... (Ada) Handle same component names when searching in tagged  (*)
  1e5dd7c... Automatic date update in version.in (*)
  8e557e5... py-breakpoint: Don't use the 'p' PyArg_ParseTupleAndKeyword (*)
  193e207... Update binutils-lto-mixed.patch against master (*)
  6b8bc4f... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  863f7a5... Update the address of the FSF in the copyright notice of fi (*)
  4baeffa... binutils nm testsuite tidy (*)
  8af5c48... DWARF-5 .debug_names DW_IDX_type_unit fix (*)
  79e8fca... Ada: unable to compare strings (Attempt to compare array wi (*)
  e05fa6f... (Ada) Add support for task switching when debugging core fi (*)
  b3e7dd3... Automatic date update in version.in (*)
  25982ee... Add missing RISC-V fsrmi and fsflagsi instructions. (*)
  b89641b... python: Add qualified parameter to gdb.Breakpoint (*)
  6892d2e... Tighten regexp of lib/completion-support.exp:test_gdb_compl (*)
  a22ecf7... Fix regression: expression completer and scope operator (PR (*)
  60a20c1... Factor out final completion match string building (*)
  0b982d6... python doc: Rework Breakpoint.__init__ doc (*)
  79e7419... [BFD][AARCH64]Disallow R_AARCH64_ABS32(LP64) & R_AARCH64_AB (*)
  9664701... gdb: Fix ARI warnings in or1k-tdep.c (*)
  3bbd9f1... Fix typo in gdb_ari.sh (*)
  024d185... This patch enables disassembler_needs_relocs for PRU. It is (*)
  10e7c04... S/390: Fix (some) PIE+undef weak failures (*)
  9937536... fix "server" command prefix handling (unexpected confirmati (*)
  2c66e16... Automatic date update in version.in (*)
  702d582... sim: testsuite: add testsuite for or1k sim (*)
  0cd7970... sim: or1k: add autoconf generated files (*)
  6e51bfa... sim: or1k: add cgen generated files (*)
  fa8b7c2... sim: or1k: add or1k target to sim (*)
  58884b0... sim: cgen: add MUL2OFSI and MUL1OFSI functions (needed for  (*)
  07b9586... sim: cgen: add remainder functions (needed for OR1K lf.rem. (*)
  638d913... Add gdb for or1k build (*)
  fe49c6f... gdb: testsuite: Add or1k tdesc-regs.exp test support (*)
  c3d1862... gdb: testsuite: Add or1k l.nop instruction (*)
  a994fec... gdb: Add OpenRISC or1k and or1knd target support (*)
  db9077b... PR22576, ppc64_skip_trampoline_code uses wrong r2 for EXEC_ (*)
  a933405... remote: Return NULL extra_info/name if they are empty (*)
  4b1c0f7... Don't mask X_add_number containing a register number (*)
  dce4fb8... Automatic date update in version.in (*)
  c4e6484... Add plugin API for processing plugin-added input files (*)
  4c5ae11... [Binutils][Objdump]Check symbol section information while s (*)
  3c0aa29... Unbreak build for non-ELF ports (*)
  f2f9e7e... [MPFR] Fix regression on 32-bit host systems (*)
  c5f9cfc... Adapt gdb.ada/variant_record_packed_array.exp to accept reo (*)
  08f4901... (Ada) change tagged types base_address computation (*)
  a9c135f... Adapt gdb.ada/pkd_arr_elem.exp to accept reordered componen (*)
  75323ba... Automatic date update in version.in (*)
  57a2957... Typo fix (*)
  8bcf9b0... Automatic date update in version.in (*)
  c5ba177... Automatic date update in version.in (*)
  a3c5faf... dwarf2read.c: Rewrite/simplify mock_mapped_index (*)
  44ed8f3... Support wildmatching in .debug_names too. (*)
  f00a2de... dwarf2read.c:mapped_index, use gdb::array_view, simplify sy (*)
  927aa2e... DWARF-5: .debug_names index consumer (*)
  e5fa658... Add gdb::hash_enum (*)
  4b514bc... Refactor: Move some generic code out of .gdb_index code (*)
  abccd1e... Change dwarf2_initialize_objfile's return value (*)
  437afbb... DWARF-5: .debug_names index producer (*)
  6432ec6... cc-with-tweaks.sh: Use gdb-add-index.sh (*)
  a9d44aa... Work around sparc glibc bug (*)
  9246928... Fix thinko on dtrace-probe.c:dtrace_process_dof_probe (*)
  f17d947... Clear non-significant bits of address in watchpoint (*)
  a0de8c2... Adjust breakpoint address by clearing non-significant bits (*)
  a738ea1... Clear non-significant bits of address on memory access (*)
  8e481c3... C++-ify parse_format_string (*)
  10af2a6... gas: xtensa: fix comparison of trampoline chain symbols (*)
  1cd9a73... Adjust gdb.arch/i386-sse-stack-align.exp print statement (*)
  6b05c8b... Fix PR 22567: set SAL .section in minsym_found (*)
  336ef6d... S390: Add symfile-mem (*)
  2d054e6... Fix stripping relocs in a file with mergeable notes. (*)
  c8bed57... Add aix 64-bit check to bfd_get_sign_extend_vma (*)
  63a22ae... Automatic date update in version.in (*)
  fa6eb69... Validate explicit locations with early termination (*)
  883fd55... Record nested types (*)
  ec72db3... Fix wrong prefix in py-breakpoint.exp (*)
  99598d7... Fix regression in "commands" (*)
  23a8d18... Fix build with g++ 6.3.1 (*)
  a880623... Initialize target description early in IPA (*)
  30970df... Add virtual destructor to selftest (*)
  824cc83... Implement explicit locations for Python breakpoints. (*)
  9c226a8... gdb/MAINTAINERS: restore m68hc11, score and xstormy16 entri (*)
  7d6de42... Objcopy interleave test (*)
  931c97c... mcore-elf lacks shared lib support (*)
  05a5fea... Rewrite check_shared_lib_support (*)
  34ac47f... Automatic date update in version.in (*)
  649a140... target_set_syscall_catchpoint, use gdb::array_view and bool (*)
  9a93831... Fix syscall group completion (*)
  1c9c7ce... Objcopy interleave fails if section address not multiple of (*)
  7cc244d... remote: Make qXfer packets respect corresponding "set remot (*)
  846fefb... Tell the linker testsuite that lm32-rtems toolchains do not (*)
  9c1ce10... PR22552, readelf heap buffer overflow in load_debug_section (*)
  07d6d2b... BFD whitespace fixes (*)
  6528139... Fix Common symbol override test fails (*)
  a3cc9aa... Enable shared lib tests for frv, lm32, m32r, microblaze, nd (*)
  3bf083e... dyn_relocs tidy (*)
  dce2246... Comment tidy (*)
  8fbc617... Automatic date update in version.in (*)
  0527614... Really fix riscv shared library __global_pointer$ problem. (*)
  858c9d1... Address review comments for the previous series (*)
  d4a0e8b... Split tdesc_type into multiple classes (*)
  f0cddbe... Make tdesc_arch_data::arch_regs an std::vector (*)
  d05200d... Make tdesc_type::u::u::fields an std::vector (*)
  082b914... Make tdesc_type::name an std::string (*)
  53c934e... Make tdesc_feature::types an std::vector (*)
  a8142ee... Make tdesc_reg string fields std::string (*)
  c9c895b... Make tdesc_feature::registers an std::vector (*)
  f65ff9f... Make tdesc_feature::name an std::string (*)
  3eea796... Make target_desc::features an std::vector (*)
  40e2a98... Make target_desc::compatible an std::vector (*)
  129c10b... Make target_desc::properties an std::vector (*)
  ed9376b... Redefine gdb_static_assert as static_assert (*)
  798a742... Remove some unused variables (*)
  da02107... Riscv shared libraries should not export __global_pointer$. (*)
  4d7efb8... Automatic date update in version.in (*)
  3e1a70a... Extend gdb.core/coredump-filter.exp to test dump-excluded-m (*)
  c179feb... Document the new "-a" command line option for gcore (*)
  cd93789... Implement "-a" command line option for gcore (*)
  1e52e84... Document new {set,show} dump-excluded-mappings commands. (*)
  afa840d... Implement 'set dump-excluded-mappings' command (*)
  7403715... Update manual for Rust change (*)
  50a1fdd... Fix displaced-stepping RIP-relative VEX-encoded instruction (*)
  826c3f1... x86 map file textrel (*)
  acf1c7c... Remove binutils-pr21841.patch (*)
  9df1861... Remove binutils-pr22309.patch (*)
  768f75b... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  e21126b... Documentation fix (*)
  c88f7cb... Automatic date update in version.in (*)
  48f7f30... Run powerpc vle gas tests for all powerpc ELF targets (*)
  97d4213... Modify ppceabi ld tests to run on all powerpc ELF targets (*)
  fed44c6... Fix for texinfo 4.8. (*)
  1e97a22... Remove mem_region_vector typedef (*)
  10f6417... Make make-target-delegates grok namespace scope op and temp (*)
  f0fb248... Fix gdb.threads/process-dies-while-detaching.exp (*)
  f143cb5... Fix "FAIL: VLE relocations 3" (*)
  c0e15c9... Remove for_each_inferior_with_data (*)
  f004534... Remove for_each_inferior (*)
  9521758... Remove find_inferior (*)
  8f86d7a... Update comments (*)
  e2b4407... Remove usages of find_inferior that call proceed_one_lwp (*)
  c80825f... Remove usage of find_inferior in linux_resume (*)
  df3e4db... Remove usages of find_inferior in stop_all_lwps (*)
  5a6b0a4... Remove usage of find_inferior in linux_stabilize_threads (*)
  39a64da... Remove usages of find_inferior in select_event_lwp (*)
  a1385b7... Remove usages of find_inferior calling not_stopped_callback (*)
  454296a... Remove usage of find_inferior in find_lwp_pid (*)
  6b2a85d... Remove usage of find_inferior in linux_mourn (*)
  798a38e... Remove usage of find_inferior in linux_detach (*)
  e4eb0de... Remove usage of find_inferior in last_thread_of_process_p (*)
  83e1b6c... Remove find_inferior_in_random (*)
  8dc7b44... Remove find_inferior_id (*)
  da25033... Remove usages of find_inferior in linux-mips-low.c (*)
  c91bb56... Remove usage of find_inferior in lynx_mourn (*)
  634a325... Remove usage of find_inferior in regcache_invalidate_pid (*)
  6d83e81... Fix typo in poison.h (*)
  035d856... Automatic date update in version.in (*)
  222b39c... Handle case where posix_fallocate is not supported for a fi (*)
  158600e... Disallow --incremental with -pie and force -no-pie for incr (*)
  0af4ccf... Workaround GCC 7 bug with debug line numbers causing debug_ (*)
  059256c... Fix incremental linking failure with GCC 7+. (*)
  97cbe99... Add support for the readnever concept (*)
  754fa89... Automatic date update in version.in (*)
  b57e49f... Update and clean up RISC-V gas documentation. (*)
  40fc416... Make '{add-,}symbol-file' not care about the position of co (*)
  7f0f8ac... Revert "Add support for the readnever concept" (*)
  7ef67ba... Fix localized help string output for -fuse-ld. (*)
  ec6a20c... (Ada) GDB crash printing expression with type casting (*)
  bd2e351... Fix internal error from command line with unbalanced --star (*)
  71739b6... Fix problem where undef can fail to trigger archive rescan. (*)
  e2e3217... Add support for the readnever concept (*)
  0f873fd... Use consistent types for holding instructions, instruction  (*)
  d0df06a... Fix dependency tracking for objects in subdirectories (*)
  2ee0c9b... Update GDB's list of maintainers to reflect today's reality (*)
  92f402a... x86: Print dynreloc in readonly section for map file output (*)
  1cc75e9... Replace mail address with the URL in copyright header (*)
  7b2d209... Check return value of bfd_new_link_order (*)
  0fbdde9... Add --strip-unneeded to objcopy synopsis (*)
  40363a9... weak alias test (*)
  63c1f59... readonly_dynrelocs (*)
  254cefe... Automatic date update in version.in (*)
  875fb7a... New gdb.ada/repeat_dyn testcase. (*)
  fd6798f... Fix internal error in fix_errata on aarch64. (*)
  e0feb13... Fix problem where erratum stubs are not always applied. (*)
  036aae7... Fix segfault in relocate_erratum_stub on aarch64. (*)
  4a7e523... PR22533, dynamic relocs generated for weak aliases (*)
  6f14765... [spu] Some additional test fixes (*)
  65cb033... Remove binutils-pr22471.patch (*)
  ae89804... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  f1af7b9... Use boards/local-board.exp more (*)
  e3919f3... Fix gdb.linespec/cpls-ops.exp on 32-bit (*)
  4412216... Remove ioctl-based procfs support on Solaris (*)
  7ac2002... x86: derive DispN from BaseIndex (*)
  b5014f7... x86: drop Vec_Disp8 (*)
  fd4e034... x86/Intel: issue diagnostics for redundant segment override (*)
  e21440b... Revert "x86: Update segment register check in Intel syntax" (*)
  f425ec6... Prevent an illegal memory access in readelf when attempting (*)
  e8020e5... Fix sol-thread.c compilation on Solaris (*)
  6682476... Fix testcase for PR ld/22471 (*)
  7505954... Define MPFR_USE_INTMAX_T so that mpfr.h assumes intmax_t is (*)
  8029e59... Automatic date update in version.in (*)
  f5a9147... preserve type length in ada-lang.c::to_fixed_range_type (*)
  bd69330... Breakpoints in symbols with ABI tags (PR c++/19436) (*)
  a20714f... Make "break foo" find "A::foo", A::B::foo", etc. [C++ and w (*)
  a207cff... Handle custom completion match prefix / LCD (*)
  4024cf2... Fix setting-breakpoints regression on PPC64 (function descr (*)
  5dcf52c... Fix gdb snapshots (*)
  6cf8299... Give Palmer co-credit for last patch. (*)
  36877bf... Fix riscv malloc error on small alignment after norvc. (*)
  f923328... In x86 -n docs, mention that you need an explicit nop fill  (*)
  f10e937... [GAS][AARCH64]Fix a typo for IP1 register alias. (*)
  4581a1c... Check for a NULL symbol pointer when reading relocs from a  (*)
  f6f1d33... Fix Python rbreak tests setting too many breakpoints when g (*)
  8ca2f0b... Update usage text for add-symbol-file, symbol-file, and loa (*)
  02ca603... Fix add-symbol-file usage and errors (*)
  ed6c0bf... [gdb/testsuite] Fix return type of psymtab-parameter (*)
  d785b7d... Stop objdump from attempting to allocate a huge chunk of me (*)
  08f650e... ld: Add a testcase for PR ld/22471 (*)
  f106e10... [gdb/testsuite] Fix wrong return type in tests (*)
  ca39c2f... Support --localedir, --datarootdir and --datadir (*)
  ed9c7ee... Use the record_alignment function when creating a .note sec (*)
  5dc824e... Allow multiply-defined absolute symbols when they have the  (*)
  8de0e07... Allow multiple .eh_frame sections per object file. (*)
  144653e... Automatic date update in version.in (*)
  b0029dc... Prevent a memory exhaustion problem when trying to read in  (*)
  7387a9d... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  ff174d3... gold: Add a newline at end of pr22266_a.c (*)
  26e7a7b... Update binutils-secondary.patch against master (*)
  0e6e17f... Remove binutils-pr22490.patch (*)
  82ed968... Properly handle note sections and segments (*)
  c551128... Update binutils-pr22490.patch against master (*)
  0d434e5... Update binutils-pr22471.patch against master (*)
  979df8d... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  b23dc97... Fix a memory access violation when attempting to parse a co (*)
  6c6bc89... ELF: Don't set non_ir_ref_regular in check_relocs (*)
  165f707... PR22471, undefined reference to linker-defined symbols (*)
  cd5b2ba... Copying symbol type in ld script assignments (*)
  a83ef4d... ld: Set non_ir_ref_regular on symbols referenced in regular (*)
  f0531ed... Compress loads/stores with implicit 0 offset. (*)
  033bfb7... Fix symbol values and relocation addends for relocatable li (*)
  57c1b68... Automatic date update in version.in (*)
  18ca734... Remove REMOTE_OBS (*)
  66599a7... Move target object files to target subdirectory (*)
  4f04fba... Add missing files to COMMON_SFILES (*)
  b5adff3... Simplify COMMON_OBS by using list of sources (*)
  afa0a41... Define YYOBJ in terms of YYFILES (*)
  8fd8d00... Move python object files to python subdirectory (*)
  bd810ff... Move guile object files to guile subdirectory (*)
  75787ac... Move unittests object files to unittests subdirectory (*)
  5c8a943... Move tui object files to tui subdirectory (*)
  a26aa30... Move compile object files to compile subdirectory (*)
  6f3cdf9... Move mi objects to mi subdirectory (*)
  f06afa5... Move cli object files to cli subdirectory (*)
  b22c88c... A simpler way to make the "arch" build directory (*)
  407e114... gas: xtensa: speed up find_trampoline_seg (*)
  148d638... gas: xtensa: implement trampoline coalescing (*)
  76a493a... gas: xtensa: reuse trampoline placement code (*)
  fe6c2f1... gas: xtensa: rewrite xg_relax_trampoline (*)
  46888d7... gas: xtensa: merge trampoline_frag into xtensa_frag_type (*)
  1c2649f... gas: xtensa: reuse find_trampoline_seg (*)
  fec68fb... gas: xtensa: extract jump assembling for trampolines (*)
  120bc8b... gas: extract xg_relax_trampoline from xtensa_relax_frag (*)
  10329bb... fix two issues in gdb.ada/mi_catch_ex.exp (re: "exception-m (*)
  6dda787... [PR ld/22263] aarch64: Avoid dynamic TLS relocs in PIE (*)
  a377ae2... [PR ld/22269] aarch64: Handle local undefined weak symbols (*)
  64973b0... Update the simplified Chinese translation of the messages i (*)
  4dff97b... Fix a seg-fault when displaying notes from a prorgam segmen (*)
  e3d4058... When creating a .note section to contain a version note, se (*)
  ee9a09e... Update find command help and search memory docs (*)
  e8e7d10... python: Fix memleak in do_start_initialization (*)
  7db85ad... Automatic date update in version.in (*)
  6a99702... Add include guards to common/format.h (*)
  ef8cccf... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  2b63c33... Rename argument name from link to xlink (*)
  33a6ddb... Apply "Properly handle note sections and segments" (*)
  f3cadc4... Apply "Don't check DT_NEEDED for symbols defined by linker  (*)
  feaee4e... Apply "Gold: Update testsuite/debug_msg.sh for GCC 7" (*)
  7f7dd7b... Apply "Retry incremental_test_2 with --incremental-full" (*)
  d8e0113... Update binutils-secondary.patch against master (*)
  441fcb2... Update binutils-pr12639.patch against master (*)
  4127210... Change maybe_disable_address_space_randomization to a class (*)
  44287fd... Removes a cleanup from gcore.c (*)
  338938e... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  8e2495f... gas: Update x86 sse-noavx tests (*)
  58f7f0b... Fix broken ChangeLog entry for last commit. (*)
  617cd4b... [spu] Fix various test cases (*)
  5ffd2cb... [spu] Fix single-stepping regression (*)
  e5a8dd4... Automatic date update in version.in (*)
  0e5457d... Adding ChangeLog entry for the last commit. (*)
  685de8c... Fix PR gdb/22491: Regression when setting SystemTap probe s (*)
  deeeba5... Use TOLOWER in SYMBOL_HASH_NEXT (*)
  a81aaca... Fix completing an empty string (*)
  6a3c6ee... Add comprehensive C++ operator linespec/location/completion (*)
  13450e7... Automatic date update in version.in (*)
  8955eb2... Comprehensive C++ linespec/completer tests (*)
  0662b6a... Make strcmp_iw NOT ignore whitespace in the middle of token (*)
  276da9b... Re-apply "elf: Properly compute offsets of note descriptor  (*)
  e547c11... (Ada) provide the exception message when hitting an excepti (*)
  5f1ca24... Fix issues with gdb-memory-map.dtd (*)
  f5291a6... [spu] Fix spu-linux gdbserver build (*)
  d7fcdff... [spu] Fix spu-linux native build (*)
  4e25ac0... Revert "elf: Properly compute offsets of note descriptor an (*)
  0fbc356... Add reference to implicit use in _bfd_elf_is_local_label_na (*)
  8b77421... Update PR ld/21562 tests for underscore targets (*)
  30649c1... Workaround build bug with GCC 6.2.1 (*)
  7696f5c... Fix aarch64-none-elf build error (*)
  8172f16... Poison XNEW and friends for types that should use new/delet (*)
  7aabaf9... Create private_thread_info hierarchy (*)
  21fe1c7... remote: C++ify thread_item and threads_listing_context (*)
  089354b... Create private_inferior class hierarchy (*)
  d044bac... Document linespec/explicit locations & completion improveme (*)
  e8d58cb... Remove dead code in regcache::dump (*)
  650444e... elf: Properly compute offsets of note descriptor and next n (*)
  a63f2d2... cooked_read test for readonly regcache (*)
  1b30aaa... regcache::cooked_read unit test (*)
  6654d75... Add xml selftests for aarch64 target description. (*)
  49bdb7e... Use flexible target descriptors for aarch64 (*)
  d6d7ce5... gdbserver: add aarch64_create_target_description (*)
  da434cc... Add aarch64_create_target_description (*)
  98ead37... Change value_contents_eq return bool (*)
  62ad7ce... Change register_changed_p returns bool (*)
  506fe5f... Change tic6x target descriptions (*)
  6d2cd6b... x86: reject further invalid AVX-512 masking constructs (*)
  ac46552... x86: don't omit disambiguating suffixes from "fi*" (*)
  00ea2e2... Fix memory leak in list_available_thread_groups (*)
  7e8006d... Automatic date update in version.in (*)
  c139731... Fix vax/ns32k/mmix gas testsuite regression. (*)
  5f71e59... Fix build error with --enable-targets=all. (*)
  f45e2a7... Fix clang warnings about copy elision (*)
  bd046f6... Revert unexpected rename in previous patch (*)
  4c37490... Change int -> bool where applicable throughout varobj (*)
  eb02c04... Avoid bogus compile time warning from clang by initialising (*)
  7c3c1aa... [testsuite] Pass -g3 to clang in gdb.base/macscp.exp (*)
  be7d153... Add Disp8MemShift for AVX512 VAES instructions. (*)
  287c7ea... Don't move weak alias dyn_relocs to weakdef (*)
  ab2477e... Delete powerpc64 symbol weakref field (*)
  60d67dc... Rename u.weakdef and make it a circular list (*)
  9d9c67b... Add libmsvcrt, libmsvcrt-os and libucrtbase to the list of  (*)
  65f3ed0... x86: fix AVX-512 16-bit addressing (*)
  43083a5... x86-64: always use unsigned 32-bit reloc for 32-bit address (*)
  9bb129e... x86: drop redundant VSIB handling code (*)
  66f1eba... x86: correct UDn (*)
  38bf511... x86/Intel: don't report multiple errors for a single insn o (*)
  9c23b42... Convert DTrace probe interface to C++ (and perform some cle (*)
  0e9ae10... Convert SystemTap probe interface to C++ (and perform some  (*)
  935676c... Convert generic probe interface to C++ (and perform some cl (*)
  88108bf... Automatic date update in version.in (*)
  8f6cb6c... (Ada) ravenscar-thread.c: remove unwanted trailing \n in ca (*)
  479f8de... C++ify osdata (*)
  41bd68f... Show optimized out local variables in "info locals" (*)
  7e2fd2f... Remove DEF_VEC_P (varobj_p) (*)
  0604393... Replace VEC (varobj_update_result) with std::vector (*)
  ddf0ea0... Make varobj::children an std::vector (*)
  9e5b9d2... Basic c++ification of varobj (*)
  2469b3c... Riscv ld-elf/stab failure and fake label cleanup. (*)
  2ca23e6... Update docs on filling text with nops. (*)
  fc35dab... Remove obsolete core-regset.c (*)
  1daad29... [testsuite] Pass pthreads in prepare_for_testing (*)
  88465e8... [testsuite] Don't skip gdb.dwarf2/pr10770.exp for non-gcc c (*)
  94b9837... Remove Vec_Disp8 field for vgf2p8mulb for AVX flavor. (*)
  dc196b2... [testsuite] Pass -pie in ldflags (*)
  6f19e86... Update ChangeLog (*)
  c7478d0... Remove Vec_Disp8 from vpcompressb and vpexpandb. (*)
  5aa7542... [GAS/ARM] Clarify relation between reg_expected_msgs and ar (*)
  2400729... Target FP: Make use of MPFR if available (*)
  7a26362... Target FP: Refactor use of host floating-point arithmetic (*)
  a9f26f6... Fix build with GCC 8: strncpy ->strcpy (*)
  29f9a56... Fix build with GCC 8: strncpy -> memcpy (*)
  dc95848... [ARC] Fix handling of ARCv2 H-register class. (*)
  0ad7172... x86: Add tests for -n option of x86 assembler (*)
  c757658... Automatic date update in version.in (*)
  3b1b69b... ravenscar: update inferior ptid with event ptid (*)
  54aa6c6... (Ada) crash connecting to TSIM simulator (*)
  cf3fbed... problem debugging ravenscar programs if runtime is stripped (*)
  9edcc12... Add multiple-CPU support in ravenscar-thread.c (*)
  65d4043... Provide the "Base CPU" in output of "info task" (if set by  (*)
  e02544b... watchpoint regression debugging with remote protocol (bare  (*)
  d625154... Add a test for PR binutils/22451 (*)
  ed0f427... [PowerPC] Detect different long double floating-point forma (*)
  a25d69c... gdb.ada/minsyms.exp: Don't hardcode the variable's address (*)
  2824e1b... Stop the v850 linker from converting to other output format (*)
  bd560f5... [ARC] [COMMITTED] Update test pattern patching. (*)
  50d2740... [ARC] Improve printing of pc-relative instructions. (*)
  d85bf2b... Add ability to follow dwo links to readelf/objdump. (*)
  0fc7642... Fix build failure in darwin-nat.c (*)
  0ee5a0e... Add NULL bfd test to elf_symbol_from (*)
  bf3d139... xtensa error message (*)
  e6b2f5e... Fix mapped_index::find_name_components_bounds upper bound c (*)
  5c58de7... Unit test name-component bounds searching directly (*)
  e1ef7d7... 0xff chars in name components table; cp-name-parser lex UTF (*)
  9752982... Automatic date update in version.in (*)
  73fcf64... Fix gdb.base/whatis-ptype-typedefs.exp on 32-bit archs (*)
  b77db94... Fix handling of GNU Property notes that are not in a GNU NO (*)
  b7486a7... mingw gas testsuite fix (*)
  28e07a0... PR22451, strip no longer works on older object files (*)
  578290e... Remove usage of find_inferior when calling kill_one_lwp_cal (*)
  eca55ae... Remove usages of find_thread when calling need_step_over_p (*)
  25c28b4... Remove usage of find_thread when calling resume_status_pend (*)
  5fdda39... Remove usage of find_inferior when calling linux_set_resume (*)
  fcb056a... Remove usage of find_inferior in linux_stabilize_threads (*)
  139720c... Remove usage of find_inferior in unsuspend_all_lwps (*)
  6d1e567... Remove usage of find_inferior in iterate_over_lwps (*)
  bbf550d... Remove usage of find_inferior in reset_lwp_ptrace_options_c (*)
  00192f7... Remove usages of find_inferior in linux-arm-low.c (*)
  2bee2b6... Remove usage of find_inferior in win32-low.c (*)
  0b360f1... Remove usage of find_inferior in win32-i386-low.c (*)
  9c512d8... Fix typo in ChangeLog entry. (*)
  20dd9c2... Fix DWARF reader to use correct size for DW_FORM_ref_addr. (*)
  bde954a... Automatic date update in version.in (*)
  671275c... Fix error message typo. (*)
  e4ec198... Automatic date update in version.in (*)
  160b1a6... PR22443, Global buffer overflow in _bfd_elf_get_symbol_vers (*)
  c977a5f... Automatic date update in version.in (*)
  0333664... Finish fixing riscv gas lns-common-1 failure, and lns-dupli (*)
  cf724bc... Use an enum to represent subclasses of symbol (*)
  68e745e... Make template_symbol derive from symbol (*)
  71a3c36... Handle dereferencing Rust trait objects (*)
  7468702... Remove DEF_VEC_I (int) (*)
  f27866b... Make process_info::syscalls_to_catch an std::vector (*)
  37269bc... Make open_fds an std::vector (*)
  5c63242... Make output_thread_groups take an std::vector<int> (*)
  ced9779... (Ada) fix handling of minimal symbols (UNOP_CAST and UNOP_A (*)
  3cfd3dd... Fix a memory leak when processing archives. (*)
  2c244f9... x86: Pass "%F%P:" to linker callback in case of error (*)
  6a6196f... Fix a snafu in a previous update to readelf that stopped it (*)
  b7e2285... ada-lang.c::ada_value_cast: remove unused parameter noside (*)
  fdfffb6... Automatic date update in version.in (*)
  a0922d8... Test breakpoint commands w/ "continue" + Ctrl-C (*)
  9ccabcc... Python unwinder sniffer: PyExc_KeyboardInterrupt -> Quit (*)
  d930703... Don't ever Quit out of resume (*)
  38dc285... Fix stdin ending up not registered after a Quit (*)
  688fca4... Fix swallowed "Quit" when inserting breakpoints (*)
  e2c33ac... gdb/inflow.c: Move SIGTTOU temporary ignoring to a RAII cla (*)
  ea04e54... Fix testing gdb.rust/modules.exp against gdbserver (*)
  d723696... Refactor endian handling in DFP routines (*)
  d0f7791... Add new AArch64 FP16 FM{A|S} instructions. (*)
  fadfa6b... Correct AArch64 crypto dependencies. (*)
  68ffd93... Update documentation for Arvm8.4-A changes to AArch64. (*)
  e9dbdd8... Add assembler and disassembler support for the new Armv8.4- (*)
  e849ea8... GDBserver: Fix ignored Ctrl-C after reconnection (*)
  80a0437... Prevent illegal memory accesses when parsing incorrecctly f (*)
  d8ae99a... Add Python rbreak command. (*)
  38b28f7... Prevent a possible seg-fault in the section merging code, b (*)
  5f84764... x86: ignore high register select bit(s) in 32- and 16-bit m (*)
  968a13f... Fix gdb.base/starti.exp racy test (*)
  c2b9da1... ix86/Intel: don't require memory operand size specifier for (*)
  8c8cad3... i386: Replace .code64/.code32 with .byte (*)
  c632b64... Remove non-linux tic6x target descriptions (*)
  1d0aa65... Allow osabi to be optional in target descriptions (*)
  3491a34... Fix tic6x-uclinux GDBserver build failure (*)
  be7f761... Automatic date update in version.in (*)
  a014b87... Include <array> to declare std::array<>. (*)
  9476501... Constify the 'arg' passed to commands in bsd-kvm.c. (*)
  625ad44... tui-win: Replace VEC with std::vector (*)
  71774bc... Fix gdb.tui/completion.exp test (*)
  01f4802... Separate the new FP16 instructions backported from Armv8.4- (*)
  c0c11fa... Remove no-longer applicable maintainer entries (*)
  34a7eba... Move self to Past Maintainers. (*)
  5334ef3... Remove features/nios2-linux.c (*)
  be74fad... objcopy memory leak (*)
  a506516... Handle ' and I format flags (*)
  dda8d76... Add support to readelf and objdump for following links to s (*)
  a602f92... Better make rule for arch/ files built for IPA (*)
  a714b0d... Fix M68HC11_NUM_REGS (*)
  390a678... x86: use correct register names (*)
  3a2430e... x86: drop VEXI4_Fixup() (*)
  0645f0a... x86-64: don't allow use of %axl as accumulator (*)
  99847db... ld einfo positional arg support (*)
  583712f... First part of fix for riscv gas lns-common-1 failure. (*)
  4fbd551... Add modified file I missed in last commit. (*)
  754842f... Fix riscv ld testsuite failure for compressed1d. (*)
  47f19c1... Automatic date update in version.in (*)
  92ffd47... Fix 'xfered>0' assertion in target.c for remote connection (*)
  0743190... Fix mem region parsing regression and add test (*)
  e87d096... Add "-z textonly" option to ELF linker (*)
  9bd543a... Revert "Apply "x86: Remove func_pointer_refcount"" (*)
  5102047... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  06bcf54... PR22431, powerpc64 ld segfault when .plt discarded (*)
  640d0ed... ld-ifunc non-PIC tests (*)
  be92cb1... x86: add disassembler support for XOP VPCOM* pseudo-ops (*)
  2645e1d... x86: add support for AVX-512 VPCMP*{B,W} pseudo-ops (*)
  df145ef... x86: string insns don't allow displacements (*)
  2d0d44d... Inconsistent .eh_frame_hdr on powerpc64 (*)
  ddbb44c... gdb.opt/inline-locals.exp: Remove trailing parentheses in t (*)
  8f8a20a... Automatic date update in version.in (*)
  58e6cc7... ld: Replace exp_dataseg_none with exp_seg_none (*)
  5616b6c... Enable hardware single step for m68k in GDBServer (*)
  5b2b928... gas/arm64: don't emit stack pointer symbol table entries (*)
  6465780... gas/ia64: fix testsuite failures (*)
  5be87c8... PE: don't corrupt section flags when linking from ELF objec (*)
  b76bc5d... x86: don't default variable shift count insns to 8-bit oper (*)
  897e603... x86: {f,}xsave64 / {f,}xrstor64 / xsaveopt64 should not all (*)
  1187cf2... x86/Intel: don't mistake riz/eiz as base register (*)
  2abc2be... x86-64/Intel: issue diagnostic for out of range displacemen (*)
  ed1794e... ld: Add ldlang_check_relro_region/update lang_find_relro_se (*)
  f4d18a5... cl (*)
  cba6246... ld: Add lang_size_relro_segment (*)
  d7475e0... ld: Add fold_segment_align/fold_segment_relro_end/fold_segm (*)
  0f99513... ld: Update phase_enum/relro_enum and add seg_align_type (*)
  f882209... ld: Remove PF_X from PT_PHDR segment (*)
  53892e6... Automatic date update in version.in (*)
  ce3ad33... ld: Add OTHER_PLT_SECTIONS (*)
  e3e53ee... weakdef list handling (*)
  529fe20... non_got_ref after adjust_dynamic_relocs (*)
  d956390... Automatic date update in version.in (*)
  f617a0f... Fix riscv binutils xfail for debug_ranges test. (*)
  9080294... Automatic date update in version.in (*)
  09a5b18... Automatic date update in version.in (*)
  584a564... Fix racy output matching in gdb.tui/tui-completion.exp (*)
  5ed7a92... Fix racy output matching in gdb.base/multi-attach.exp, gdb. (*)
  a60e073... Fix racy output matching in gdb.base/cpcompletion.exp (*)
  2c88253... Fix racy output matching in gdb.base/memattr.exp (*)
  c7a3851... Fix racy output matching in gdb.base/completion.exp (*)
  f29f4b6... Fix racy output matching in gdb.asm/asm-source.exp (*)
  fb24d53... ld: Reformat emultempl/elf32.em (*)
  31432a6... fix typos in ada-lang.c comment (*)
  52c6b71... Fix riscv dwarf2-10 gas testsuite failure. (*)
  981b557... Enable the Dot Product extension by default for Armv8.4-a. (*)
  793a194... Add assembler and disassembler support for the new Armv8.4- (*)
  1a7ed57... Add the operand encoding types for the new Armv8.2-a back-p (*)
  f42f1a1... Adds the new Fields and Operand types for the new instructi (*)
  e793c05... Simplify the psymbol hash function (*)
  7e8835c... Speed up dict_hash (*)
  b6b9ca0... Split the ARM Crypto ISA extensions for AES and SHA1+2 into (*)
  21b81e6... Change the type of the aarch64_feature_set typedef to unsig (*)
  286acbb... local variable watchpoint not deleted after leaving scope (*)
  b44ec61... Make encode_actions_rsp use std::vector (*)
  dc8d2d9... gold: Ignore def/ref from a dynamic object for special symb (*)
  cb1a122... Automatic date update in version.in (*)
  62d7ae9... Avoid expensive complaint calls when complaints are disable (*)
  333d005... Fix problems with -r. (*)
  08228b1... Apply: (*)
  280ca31... Add test for fetching TLS from core file (*)
  c9ec0e8... BFD: Extract PID from MIPS core dump file (*)
  9031cb4... BFD: Write Linux core PRSTATUS note into MIPS core file (*)
  2f4732b... Remove symbolp vector (*)
  f9d67a2... Make the linespec/location completer ignore data symbols (*)
  56d87ef... Use search_domain::FUNCTIONS_DOMAIN when setting breakpoint (*)
  1b02611... Simplify completion_list_add_name | remove sym_text / sym_t (*)
  c62446b... lookup_name_info::make_ignore_params (*)
  6192012... Reorder/reindent dw2_expand_symtabs_matching & friends (*)
  3f563c8... Optimize .gdb_index symbol name searching (*)
  b5ec771... Introduce lookup_name_info and generalize Ada's FULL/WILD n (*)
  5ffa079... Per-language symbol name hashing algorithm (*)
  2a1dde5... Fix "make test-cp-name-parser" (*)
  2841837... Fix typo in changelog (*)
  c0e7cef... Split the AArch64 Crypto instructions for AES and SHA1+2 in (*)
  dec4138... Adds command line support for Armv8.4-A, via the new comman (*)
  6e98b34... xtensa message pluralization (*)
  b346cb9... Automatic date update in version.in (*)
  95a6b0a... Constify execute_command (*)
  eb4c3f4... Constify add_setshow_* (*)
  5fed81f... Remove cmd_cfunc_ftype (*)
  1d12d88... Constify add_info (*)
  0b39b52... Constify add_com (*)
  85c4be7... Add set_repeat_arguments function (*)
  022643b... Remove cleanup from backtrace_command (*)
  5614fb7... Constify add_path and friends (*)
  6be9a19... Make strip_bg_char return a unique_xmalloc_ptr (*)
  c2252c0... Make set_cmd_cfunc private (*)
  1ee870c... Constify add_com_suppress_notification (*)
  ee7ddd7... Constify add_abbrev_prefix_cmd (*)
  52eab76... opcodes/arc: Fix incorrect insn_class for some nps insns (*)
  016f5a3... Fix typo in my email address. (*)
  180093c... RISC-V: Add Jim Wilson as a maintainer, and clean up our en (*)
  f77bb6c... RISC-V: Fix riscv g++ testsuite EH failures. (*)
  1270b04... RISC-V: Add satp as an alias for sptbr (*)
  a02b41a... Add some more breakpoint/location range tests (*)
  95e95a6... Make breakpoint/location number parsing error output consis (*)
  cee62db... Add base 'enable/disable invalid location range' tests (*)
  cc638e8... Breakpoint location parsing: always error instead of warnin (*)
  d0fe470... Allow enabling/disabling breakpoint location ranges (*)
  0198d5e... This patch similarly to the AArch64 one enables Dot Product (*)
  db84fff... PowerPC64 statistics message (*)
  e54e9ac... bundle_lock message tidy (*)
  d3a49aa... readelf ngettext fixes (*)
  992a06e... gas and ld pluralization fixes (*)
  f3ce9b3... Require ngettext in test of system gettext implementation (*)
  6003e27... ngettext support (*)
  84d5321... Automatic date update in version.in (*)
  635dc5b... Update my e-mail address. (*)
  556e5da... Simplify child_terminal_inferior (*)
  46f67f8... Test attaching to a process that isn't a process group lead (*)
  d192816... Don't check termio.h and sgtty.h in common/common.m4 either (*)
  6aa899c... Eliminate STOP_SIGNAL, use SIGTSTP directly (*)
  a94799a... Don't set terminal flags twice in a row (*)
  726e135... Assume termios is available, remove support for termio and  (*)
  1cfb73d... Target FP: Merge doublest.c and dfp.c into target-float.c (*)
  b07e9c4... Target FP: Remove unused floating-point routines (*)
  3b2ca82... Target FP: Remove convert_typed_floating from tdep files (*)
  14ad931... Target FP: Handle interfaces to scripting languages (*)
  50eff16... Target FP: Perform Ada fixed-point scaling in target format (*)
  66c02b9... Target FP: Add binop and compare routines to target-float.{ (*)
  50637b2... Target FP: Add conversion routines to target-float.{c,h} (*)
  f69fdf9... Target FP: Add string routines to target-float.{c,h} (*)
  7010001... Target FP: Introduce target-float.{c,h} (*)
  74be0bd... Automatic date update in version.in (*)
  26a9301... Proper bound check in _bfd_doprnt_scan (*)
  7167fe4... PR22397, BFD internal error when message locale isn't C (*)
  0724bd4... Automatic date update in version.in (*)
  f15d0b5... powerpc TLS in PIEs (*)
  98bbb1b... PowerPC readonly_dynrelocs (*)
  2e684e7... hppa-linux TLS relocs (*)
  127e8e9... PR22394, hppa-linux-ld fails to emit dynamic relocations (*)
  ab4b1c4... Use std::vector in h8300-tdep.c (*)
  454dafb... Introduce gdb_breakpoint_up (*)
  331b71e... Use unique_xmalloc_ptr in c_type_print_base (*)
  9f584b3... Remove cleanups from linux-tdep.c (*)
  779bc38... Use gdb::byte_vector in ppc-linux-tdep.c (*)
  ed2b312... Remove make_cleanup_free_objfile (*)
  7f6743f... Use gdb::def_vector in sparc64-tdep.c (*)
  c80049d... Replace start_rbreak_breakpoints and end_rbreak_breakpoints (*)
  167b0be... Remove directive-searched cleanups (*)
  5eae7ae... Use unique_xmalloc_ptr in find_separate_debug_file_by_debug (*)
  c6bcad5... Use std::vector in compile-loc2c.c (*)
  20dcd8c... Remove cleanups from link_callbacks_einfo (*)
  33c7c59... Replace really_free_pendings with a scoped_ class (*)
  ebe6dbc... Automatic date update in version.in (*)
  79b0c98... x86: Remove func_pointer_refcount (*)
  10a3785... Apply "x86: Remove func_pointer_refcount" (*)
  67fa57c... Fix regression on ARM after Target FP patches (*)
  fdddd29... [ARC] Force the disassam to use the hexadecimal number for  (*)
  7605d94... Add option for Qualcomm Saphira part (*)
  bf59c5d... Fix integer overflow problems when reading an ELF binary wi (*)
  3334eba... [ARC] Sync opcode data base. (*)
  50ab6ac... Skip gdb.mi/list-thread-groups-available.exp if no xml supp (*)
  6cee897... Fix excessive memory allocation attempts and possible integ (*)
  8e68731... Skip gdb.python/py-thrhandle.exp if python is not enabled. (*)
  3d47a7f... Automatic date update in version.in (*)
  c05e0c5... aarch64: Remove AARCH64_FEATURE_F16 from AARCH64_ARCH_V8_2 (*)
  6ab2c4e... Work around integer overflows when readelf is checking for  (*)
  f26ae15... Construct readonly regcache without address space (*)
  6c6e941... const-fy regcache::m_readonly_p (*)
  8b86c95... const-fy regcache::m_aspace (*)
  a01bda5... s/get_regcache_aspace (regcache)/regcache->aspace ()/g (*)
  d999647... Remove regcache_descr::nr_raw_registers (*)
  4e888c2... New method regcache::assert_regnum (*)
  2e1b49b... Remove code wrapped by "#if 0" (*)
  6c5218d... Remove regcache_descr fields sizeof_raw_register_status and (*)
  8527358... [ARM] Help wince objdump on coproc tests (*)
  dcc31d2... FT32: support for FT32B processor - part 2/2 (*)
  89f3c4b... Automatic date update in version.in (*)
  29b69b1... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  81b42bc... FT32B is a new FT32 family member. It has a code compressio (*)
  a67d66e... Prevent illegal memory accesses when attempting to read exc (*)
  e0115a8... Update check for invalid values in pe_bfd_read_buildid func (*)
  ee35748... Fix an invalid free called when attempting to link a COFF o (*)
  4070243... [ARM] Fix Coprocessor instructions availability (*)
  3988aed... PR22374, PowerPC unnecessary PLT entries (*)
  e48f0c8... PR22374 testcase, function pointer references in .data (*)
  46b06a9... Tidy elf.exp (*)
  3a87ae6... Use console uiout when executing breakpoint commands (*)
  4d01dee... Automatic date update in version.in (*)
  09b847f... tracepoint: Remove unnecessary const_cast (*)
  0bb6961... Fix illegal memory access triggered when parsing a PE binar (*)
  45ac8f4... Remind users to use the --use-dynamic command line option t (*)
  f871c48... gdb/Makefile.in: fix 'make tags' failure (*)
  916296c... Automatic date update in version.in (*)
  b020ff8... Introduce in_inclusive_range, fix -Wtautological-compare wa (*)
  1b81856... remote.c, QCatchSyscalls: Build std::string instead of uniq (*)
  31b833b... Introduce string_appendf/string_vappendf (*)
  4a25033... Merge/shared string_printf and string_vprintf unit tests (*)
  16c5c17... darwin-nat: Remove gdb.h include (*)
  7f9cb5d... frv-elf --gc-sections failures (*)
  81742b8... relocs_compatible test for gc-sections (*)
  d336fa6... Fix hppa-linux pr22269-1 fail (*)
  2b2d167... Automatic date update in version.in (*)
  7ca5157... xtensa-xtregs: Fix formatting issues (*)
  c134285... xtensa-xtregs: Constify field (*)
  692af22... Automatic date update in version.in (*)
  484d8d3... Make gdb.selected_thread().inferior return a new reference (*)
  d91f0b2... PR22361 readelf buffer overflow on fuzzed archive header (*)
  c0e331c... PR22300, Abort in elf32_hppa_relocate_section building poly (*)
  bac608e... Remove find_inferior usage for thread_search (*)
  eaddb42... Remove usage of find_inferior in resume (*)
  99078d3... Remove usages of find_inferior in handle_status (*)
  b5540b5... common-utils-selftests.c: Add ATTRIBUTE_PRINTF (*)
  5a9dcda... C++ify xml-syscall.c (*)
  45461e0... Get rid of VEC(probe_p) (*)
  43dce43... Allocate breakpoint_objfile_data with new (*)
  6a1b951... Get rid of VEC(loaded_script_ptr) (*)
  593e320... Get rid of VEC(filename_language) (*)
  32fa66e... Add tests for filename_language (*)
  af5f32f... Automatic date update in version.in (*)
  4a27f11... Use SaL symbol name when reporting breakpoint locations (*)
  bb11dd5... [AArch64] Mark LR clobbered by BL in inline asm (*)
  32ef300... dwarf: Read register number as unsigned in DW_CFA_def_cfa* (*)
  7453e6b... Add PR mention to previous commit (*)
  a43f389... Fix broken recursion detection when printing static members (*)
  95904ac... Automatic date update in version.in (*)
  23cc4e1... Garbage collect remote.c:remote_async_terminal_ours_p (*)
  514f602... x86: Check invalid XMM register in AVX512 gathers (*)
  506981a... [PR21703]Adjust pr21703 tests on various targets. (*)
  4062f50... As Alan predicted at https://sourceware.org/ml/binutils/201 (*)
  6abc18b... Remove regular_breakpoint_inserted_here_p declaration (*)
  bd52251... const-fy breakpoint_ops->breakpoint_hit parameter aspace (*)
  accd0bc... const-fy function parameter struct address_space *aspace (*)
  ca3e4ea... Automatic date update in version.in (*)
  238c141... testsuite/gas/all/fill-1.s: Use L2 rather than .L2. (*)
  8df93cb... ld: Correct -z ibt documentation (*)
  ac7936d... s/get_regcache_arch (regcache)/regcache->arch ()/g (*)
  edd079d... Target FP: Use target format throughout expression parsing (*)
  e5d70d6... PR22348, conflicting global vars in crx and cr16 (*)
  cc628f3... Add common AARCH64 REGNUM defines (*)
  e601d38... Allow for __gnu_lto_slim prefixed with extra "_" (*)
  9409212... Yet another fill-1 test fix (*)
  711f5e5... Automatic date update in version.in (*)
  db283f4... Fix format typos in previous previous ld/ChangeLog entry (*)
  2e30886... testsuite/ld-riscv-elf/ld-riscv-elf.exp: Fix typo for istar (*)
  792ccf0... Fix racy test in gdb.base/new-ui.exp (*)
  63a25ea... RISC-V: Fix disassembly of c.addi4spn, c.addi16sp, c.lui wh (*)
  09a7c6a... Use const reference for decimal_from_string argument (*)
  8ba0dd5... Target FP printing: Use floatformat_to_string in tdep code (*)
  16e812b... Target FP printing: Simplify and fix ui_printf (*)
  fdf0cbc... Target FP printing: Simplify and fix print_floating (*)
  3342be5... RISC-V: Only relax to C.LUI when imm != 0 and rd != 0/2 (*)
  3779bbe... Fix my previous gas/ChangeLog entry (*)
  da5f19a... i386: Support .code64 directive only with 64-bit bfd (*)
  5033013... Fix gdb.opt/inline-cmds.exp regressions (*)
  93f4de3... [BFD][PR21703]Override the new defined symbol with the old  (*)
  eb2bfba... Reindent gdb.threads/attach-into-signal.exp (*)
  1f75a65... Drop /proc/PID/status polling from gdb.threads/attach-into- (*)
  779990d... Fix unstable test names in gdb.threads/attach-into-signal.e (*)
  ad9b8f5... Fix unstable test names in gdb.python/py-objfile.exp (*)
  fee6da6... Fix unstable test names in gdb.gdb/unittest.exp (*)
  10389c2... Fix unstable test names in gdb.base/startup-with-shell.exp (*)
  a80e65a... Fix unstable test names in gdb.arch/arc-tdesc-cpu.exp (*)
  2c3f27e... RISC-V: Don't emit 2-byte NOPs if the C extension is disabl (*)
  fee0ea1... Automatic date update in version.in (*)
  4a8f9fc... i386: Don't add elf32_x86_64 to supported emulations (*)
  2739ef6... Add missing ChangeLog entries (*)
  d55cf23... Revert "Apply "ELF: Call check_relocs after opening all inp (*)
  7a6d7aa... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  66cae56... Make sure that undefined symbols added to the linker comman (*)
  fe4e2a3... Fix the master due to bad regenerated files (*)
  defc8e2... MIPS: Preset EF_MIPS_ABI2 with n32 ELF objects (*)
  ee6872b... Enable Intel AVX512_BITALG instructions. (*)
  8cfcb76... Enable Intel AVX512_VNNI instructions. (*)
  ff1982d... Enable Intel VPCLMULQDQ instruction. (*)
  8dcf1fa... Enable Intel VAES instructions. (*)
  4852100... Enable Intel GFNI instructions. (*)
  53467f5... Enable Intel AVX512_VBMI2 instructions. (*)
  f6af9f3... Automatic date update in version.in (*)
  67c0437... Fix spurious left-over quotes from last edit. (*)
  56fbd04... Fix gas/22304 by forcing a 64-bit bfd for cris*-*. (*)
  a73ca55... Automatic date update in version.in (*)
  4e15b78... PR ld/21233 (*)
  4d3bb80... Add overloads of for_each_thread/find_thread that filter on (*)
  a664f67... Get rid of VEC (mem_region) (*)
  6e17c56... Use std::string in memory_map_parsing_data (*)
  cfba987... Create a displaced_step_closure class hierarchy (*)
  b392b30... Remove leftover declarations in interps.h (*)
  881b337... Automatic date update in version.in (*)
  d636135... Fix ChangeLog entry. (*)
  3b4190c... New gold linker option -z,text-unlikely-segment. (*)
  f301201... Add a compile-time test for PR ld/22269 (*)
  d5833c6... Use std::vector in gdb_bfd_data (*)
  06d5bbc... Use "new" to allocate gdb_bfd_data (*)
  2712ce2... Introduce new_bfd_ref (*)
  15763a0... Fix 'gdb.base/quit.exp hangs forever' if the test fails (*)
  fcc8fb2... Fix gdb.gdb/ selftest tests when testing optimized GDB buil (*)
  808811a... Improve handling of REPT pseudo op with a negative count. (*)
  36862fc... Implement BE8 support for ARM. (*)
  4c2287b... Get rid of VEC(interp_factory_p) (*)
  b5f6e74... Automatic date update in version.in (*)
  3d415c2... Remove cleanups from break-catch-syscall.c (*)
  395423c... Remove cleanup from call_function_by_hand_dummy (*)
  54f70bc... Remove cleanups from prepare_execute_command (*)
  49a4ce2... gdb: Remove hard-coded line number from test (*)
  63929e8... Fix build breakage in gdb/xml-support.c (*)
  9d06997... RISC-V: Relax RISCV_PCREL_* to RISCV_GPREL_* (*)
  ff6f4d9... RISC-V: Add R_RISCV_DELETE, which marks bytes for deletion (*)
  95e42ad... Fix the AVR assembler so that it will correctly issue warni (*)
  a75868f... Fix inferior deadlock with "target remote | CMD" (*)
  2edf834... xml_fetch_content_from_file: Read in whole file in one go (*)
  2809589... tilegx: Check bfd_link_executable for TLS check (*)
  1ba1f39... tilepro: Check bfd_link_executable for TLS check (*)
  0fb7012... sparc: Check bfd_link_executable for TLS check (*)
  fa57faa... Fix fill-1 testcase (*)
  d7dd155... Automatic date update in version.in (*)
  8e35405... tile: Mark __tls_get_addr in gc_mark_hook (*)
  8dfa5d5... RISC-V: Mark unsupported gas testcases (*)
  c8ba13a... Canonicalize conversion operators (*)
  3753468... Issue complaint instead of assert for invalid/unhandled DW_ (*)
  2a6969e... [Visium] Disassemble the operands of the stop instruction. (*)
  8ef027f... Update Cris assembler tests for checks that now pass where  (*)
  94ea37b... Update the Swedish translation in the GAS subdirectory. (*)
  8071ec0... Add a warning to the how-to-make-a-release notes to check t (*)
  482366c... Move Svein Seldal to Past Maintainers section. (*)
  28c7c15... Remove features/tic6x-c62x-linux.c (*)
  5396a86... PR22303, print_core_note out of bounds read (*)
  b721366... microblaze: Check for indirect and warning symbols (*)
  da15dcb... Automatic date update in version.in (*)
  412294d... [GOLD] Fix powerpc64 optimization of TOC accesses (*)
  b27de57... Really make the native-stdio-gdbserver board non-remote (*)
  be45943... Add myself as dwarf-mode.el maintainer (*)
  8484c95... Add several "quit with live inferior" tests (*)
  30f0b10... Remove cleanups from disasm.c (*)
  57e12da... Remove obsolete assertion from regcache.c (*)
  cf54ebf... PR22307, Heap out of bounds read in _bfd_elf_parse_gnu_prop (*)
  7b70099... Fix double-free corruption (*)
  d3037ba... Simplify regcache::xfer_part (*)
  7a7cdfa... [GDBserver] Move aarch64-insn.o to arch/ and remove one Mak (*)
  e675d17... [GDBserver] Move arm-linux.o and arm-get-next-pcs.o to arch (*)
  7eb4e0f... [GDBserver] Move arm.o to arch/arm.o (*)
  60d6cfc... [GDBserver] Replicate src dir in build dir (*)
  0301ce1... PR22306, Invalid free() in slurp_symtab() (*)
  e6e2dfb... Correct -z text and other -z documentation (*)
  83d5a34... Add missing ChangeLog entries. (*)
  487958d... Fix segfault processing nios2 pseudo-instructions with too  (*)
  c191a68... Record and output access specifiers for nested typedefs (*)
  087ce8f... Automatic date update in version.in (*)
  87028b8... Return unique_xmalloc_ptr from target_fileio_read_stralloc (*)
  b7b030a... Return unique_xmalloc_ptr from target_read_stralloc (*)
  b80406a... Simple cleanup removals in remote.c (*)
  a90ecff... Remove cleanup from ppc-linux-nat.c (*)
  2dc0e21... Remove some cleanups from probe.c (*)
  b05628f... Use std::vector in end_symtab_get_static_block (*)
  739b3f1... Make native gdbserver boards no longer be "remote" (in Deja (*)
  fe68b95... Use proc_with_prefix in py-breakpoint.exp (*)
  a79b1bc... Get rid of VEC(mem_range_s) (*)
  63f0e93... Work around GCC 6.3.1 bug (*)
  5c3261b... ELF: Call check_relocs after opening all inputs (*)
  5bfda25... Regenerate gdbserver/configure (*)
  c40c7bf... Remove features/tic6x-*.c files (*)
  df27ae6... Remove regformats/tic6x-{c62x,c64x,c64xp}.dat (*)
  8676616... Fix GDB build without expat (*)
  86e17b6... Automatic date update in version.in (*)
  631859b... Automatic date update in version.in (*)
  0c52bdd... Apply "ELF: Call check_relocs after opening all inputs" (*)
  c3d427c... Update binutils-x86-gpoff.patch against master (*)
  44b0db8... Revert "Apply 2 elfxx-x86 patches" (*)
  5eb013a... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  851b6fa... x86: Add elf_x86_backend_data (*)
  9577f60... x86: Add _bfd_x86_elf_finish_dynamic_sections (*)
  5d84490... cris: Don't hide symbol which was forced to be dynamic (*)
  e01c16a... cris: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  6ee6e05... sh: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  b27bb18... s390: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  31a53da... nios2: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  112fef4... microblaze: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  5056ba1... m68k: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  60c1b90... hppa: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  db41f6e... ia64: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  ad95120... mips: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  95b03e4... arm: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  a3cd202... tile: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  ddb7fd0... aarch64: Check UNDEFWEAK_NO_DYNAMIC_RELOC (*)
  62cd30f... Move UNDEFWEAK_NO_DYNAMIC_RELOC to elf-bfd.h (*)
  824dfcc... Fix build failure in linux-osdata.c (*)
  9c80ecd... gdbserver: use std::list for all_threads (*)
  9179355... gdbserver: Use std::list for all_processes (*)
  c9cb890... gdbserver: Use std::list for all_dlls (*)
  2098b39... Make to_traceframe_info return a unique_ptr (*)
  4cdd21a... Use std::vector for traceframe_info::memory (*)
  d0d292a... Use std::vector for traceframe_info::tvars (*)
  8d3c73e... Rename traceframe_info variable to current_traceframe_info (*)
  b129dca... Use std::vector in linux_xfer_osdata_processgroups (*)
  af5bf4a... Replace psymbol_allocation_list with std::vector (*)
  3ec5942... ada: Use std::string in print_dynamic_range_bound (*)
  867d918... Automatic date update in version.in (*)
  300b668... Skip a few tests on targets that can't use the "run" commma (*)
  50500ca... Fix gdb.base/testenv.exp against --target_board=native-exte (*)
  dad0c6d... Don't run gdb.gdb/ selftests if use_gdb_stub is true (*)
  8b0553c... Make gdb.base/find-unmapped.exp pass on remote targets (*)
  2399fe6... Simplify tic6x and s390x expedite registers (*)
  4bf3f4a... Regenerate features/s390-gs-linux64.c and features/s390x-gs (*)
  354bac4... PR22263 testcase (*)
  9e86da0... Change objfile to use new/delete (*)
  7594f62... Fix gdb.base/term.exp on non-"target native" boards (*)
  ebe3b40... Remove is_remote kfail from gdb.python/py-evthreads.exp (*)
  42f1b16... Fix gdb.python/py-evthreads.exp with --target_board=native- (*)
  8d6ef72... kfail gdb.python/py-evsignal.exp on RSP targets properly (*)
  d7bcd5b... Skip gdb.threads/thread_events.exp on RSP targets properly (*)
  df479dc... Tweak gdb.base/corefile.exp is_remote check (*)
  23fb630... Fix is_remote check in gdb.base/remote.exp (*)
  cc77b1d... gdb.base/remote.exp: Fix typo and add missing return (*)
  27c9e81... Make gdb.base/solib-nodir.exp work with --target_board=nati (*)
  5e830d9... Eliminate is_remote check in gdb.base/shlib-call.exp (*)
  c2508e9... Remove simple_displaced_step_copy_insn (*)
  3b4b0a6... FT32: support for FT32B processor - part 1 (*)
  d268bba... Add myself as ft32 maintainer for sim. (*)
  f5ca003... Eliminate is_remote check in gdb.base/scope.exp (*)
  52a58c2... Automatic date update in version.in (*)
  8aed1c0... Remove references to gdb64 in the testsuite (*)
  cfa34c8... Remove is_remote check in labels.exp (*)
  9192b7d... Make gdb.base/auvx.exp work with --target_board=native-exte (*)
  74ffa56... Add a compile-time test for PR ld/22263 (*)
  a900ff7... Use bool in pv_area (*)
  f7b7ed9... C++-ify prologue-value's pv_area (*)
  04ec789... linux low: Make the arch code free arch_process_info (*)
  466eece... lwp_info: Make the arch code free arch_lwp_info (*)
  6bf0052... Run gdb.base/catch-fork-static.exp on remote target boards (*)
  e48ef82... checkpoint.exp: Check for non-"target native" instead of is (*)
  8d7aea5... Remove is_remote target check from gdb.base/dprintf-non-sto (*)
  3044067... Tighten remote check in gdb.base/argv0-symlink.exp (*)
  4e04f04... Enable gdb.base/inferior-died.exp on is_remote target board (*)
  871a186... Enable gdb.threads/non-ldr-exc-*.exp on is_remote target bo (*)
  6c19b93... ld whitespace fixes (*)
  1d75a8e... Force the AArch64 linker backend to refuse to link when it  (*)
  9f85753... x86: Add _bfd_x86_elf_hide_symbol (*)
  359987e... ld: Update tests for warning of "-z dynamic-undefined-weak  (*)
  22b1ee1... Set dynamic_undefined_weak to zero for static PIEs (*)
  559192d... _bfd_elf_link_hash_hide_symbol calls in generic ELF code (*)
  f5233a1... Fix remaining targets using wrong .interp conditions (*)
  ff07698... Automatic date update in version.in (*)
  f71c882... Remove cleanups from TUI (*)
  981a3fb... Constify add_prefix_cmd (*)
  fdf4487... Remove prepare_re_set_context (*)
  81b1e71... Remove some cleanups from breakpoint.c (*)
  4b97e38... Add 2 testcases for PR ld/22269 (*)
  853ee16... x86: Run PR ld/19636 tests with -z dynamic-undefined-weak (*)
  4f9d990... Add native target for FreeBSD/arm. (*)
  7176dfd... Add FreeBSD/arm architecture. (*)
  39865a7... Disable the inclusion of logical input files in the assembl (*)
  fe22022... GDB: Remove Linux core PRPSINFO note writer override (*)
  3c9a7b0... ELF/BFD: Handle both variants of the 64-bit Linux core PRPS (*)
  a2f63b2... ELF/BFD,GDB: Handle both variants of the 32-bit Linux core  (*)
  72bc1bb... ELF/BFD: Fix padding in `elf_external_linux_prpsinfo64' (*)
  458ca1d... Garbage collect reattach_breakpoints (*)
  905014d... Use std::vector for symtab_fns (*)
  56d704d... arc: Pass proper CPU value to the disassembler (*)
  8f314ad... Rename _doprnt -> _bfd_doprnt to fix DJGPP bfd build (and l (*)
  04914e3... Display more information when decoding DW_AT_endianity, DW_ (*)
  7fa29be... Remove unnecessary parentheses in declarations (*)
  d9b477e... Flash memory size not aligned to address (*)
  d003af5... ld internationalization fixes (*)
  e8b8ffd... Automatic date update in version.in (*)
  0f09b4d... x86: Set GOT refcount to 1 (*)
  2f20e31... get_integer_valueof: Don't output value in test name (*)
  eb8c0d3... Bump dwarf-mode version number (*)
  c85fa91... Asynchronous insertion for dwarf-mode.el (*)
  e4905c7... Set lexical-binding in dwarf-mode (*)
  22b6379... Bind keys in dwarf-mode-map definition (*)
  6563036... Eliminate catch_exceptions/catch_exceptions_with_msg (*)
  bf46927... Eliminate catch_errors (*)
  6c69971... [ARM] PR ld/21402, only override the symbol dynamic decisio (*)
  ae7e782... Improve the speed of the --dwarf-start option by skipping p (*)
  fc3c534... riscv: Cache the max alignment of output sections (*)
  b9399fc... Prepare powerpc64 for late check_relocs (*)
  cbd3b1c... Correct ld/Makefile earmelfb_fuchsia dependencies (*)
  f8f762b... Automatic date update in version.in (*)
  1a56bfa... Remove free_splay_tree cleanup (*)
  0c478e2... Remove "do_nothing" (*)
  478c006... mn10300: Don't free cached internal symbol table (*)
  9d45a7d... bfin: Don't create .interp section for info->nointerp (*)
  777a42f... gdb.multi/multi-arch-exec.exp: Also test -m32 => -m64 (*)
  cbd2b4e... Multi-arch exec, more register reading avoidance (*)
  a181c0b... Use gdbarch_long_bit to determine layout of FreeBSD siginfo (*)
  6e66f75... Don't try building gdb against guile-2.2 (*)
  8e46450... S/390: Sync with latest POP - 3 new instructions (*)
  ee6767d... S/390: Sync with IBM z14 POP - SI_RD format (*)
  890e979... Fix automatic dependency tracking (*)
  109483d... Make cp_remove_params return a gdb::unique_xmalloc_ptr (*)
  c474ea1... Fix link time warning message when running the srec linker  (*)
  6753e38... Fix compile time warning message when running the PR19874 l (*)
  e61933a... Add missing changelog entries (*)
  5c9e442... Fix gdb.base/print-file-var-main.c value check logic (*)
  76f361e... ld: Don't allow '~' as the first char in symbol name (*)
  5d3b558... Replace nop in fill-1.s testcase. (*)
  4f2358b... Enable .fill forward labels (*)
  791afaa... Remove some cleanups from dwarf2read.c (*)
  30a9c02... Remove cleanup from frame_prepare_for_sniffer (*)
  757325a... Remove make_cleanup_value_free (*)
  b9c04fb... Change search_symbols to return std::vector (*)
  b55ec8b... PR22212, memory leak in nm (*)
  a72f95f... sh: Dump dynamic relocation info to the map file (*)
  f9799aa... sparc: Remove a strayed comment (*)
  effaa0a... Automatic date update in version.in (*)
  4c7236d... tilegx: Set this_hdr.sh_entsize only if section size > 0 (*)
  70090aa... Reformat elf_x86_allocate_dynrelocs (*)
  f0f07ad... sparc: Dump dynamic relocation info to the map file (*)
  b05c287... Automatic date update in version.in (*)
  2458d83... ld-elf/merge.d: Don't expect to fail for sparc (*)
  0ee6e55... Automatic date update in version.in (*)
  99180bc... x86: Update UNDEFINED_WEAK_RESOLVED_TO_ZERO comments (*)
  98b273d... x86: Use zero_undefweak in elf_x86_link_hash_entry (*)
  b3b7c42... Skip gdb.mi/mi-threads-interrupt.exp if nointerrupts. (*)
  544c67c... Account for padding in FreeBSD/mipsn32 NT_PRSTATUS notes. (*)
  0d28b0a... Move aarch64-insn.o to arch/aarch64-insn.o and Remove a rul (*)
  7191780... Move arm.o arm-get-next-pcs.o arm-linux.o to arch/ (*)
  2081b2b... Move i386.o to arch/i386.o (*)
  e0d8f43... Add "do/while(0);" to COPY_INPUT_RELOC_P/VERIFY_COPY_RELOC (*)
  a1b85d2... Fix more GDB build breakage on mingw32 (*)
  b79f780... Fix GDB build under msys+mingw gcc 32bit (*)
  d97987e... Share code updating gdb_target_obs (*)
  f38307f... [RFC] Replicate src dir in build dir (*)
  2f924de... gdb: Fix decoding of ARM neon memory hint insns. (*)
  ff38b4c... x86: Add VERIFY_COPY_RELOC (*)
  f3180fa... x86: Add VERIFY_PLT_ENTRY (*)
  e74399c... x86: Add COPY_INPUT_RELOC_P (*)
  aebcc8f... x86: Add GENERATE_DYNAMIC_RELOCATION_P (*)
  cf1070f... x86: Add POINTER_LOCAL_IFUNC_P/PLT_LOCAL_IFUNC_P (*)
  f70656b... x86: Add GENERATE_RELATIVE_RELOC_P (*)
  1f92404... x86: Add RESOLVED_LOCALLY_P (*)
  2eba97c... Add RESOLVED_LOCALLY_P (*)
  daf1c41... x86: Add NEED_DYNAMIC_RELOCATION_P (*)
  5153739... x86: Add TLS_TRANSITION_IE_TO_LE_P (*)
  e98fdf1... DWARF header checks (*)
  0caf6c8... powerpc: Dump dynamic relocation info to the map file (*)
  46e31de... Automatic date update in version.in (*)
  2fd9d7c... Fix fork-related regressions on GNU/Linux (*)
  d13b849... Remove unused "union agent_val" from ax.h (*)
  3b4b2f1... Clean up some DFP interfaces (*)
  1841ee5... Clean up includes of doublest.h and floatformat.h (*)
  a80a647... Add a signal frame unwinder for FreeBSD/mipsn32. (*)
  6d5be5d... Handle the NT_ARM_VFP core dump note on FreeBSD. (*)
  12c4bd7... Handle FreeBSD-specific AT_EHDRFLAGS and AT_HWCAP auxiliary (*)
  2bfa0cd... Fix the MSP430 assembler so that it detects and reports ext (*)
  97953ba... Avoid spurious readelf error status from decode_arm_unwind. (*)
  64f7152... Update the Hungarian translation in the gprof directory. (*)
  94750c0... Updated Turkish translation for the ld sub-directory. (*)
  007873f... tile: Dump dynamic relocation info to the map file (*)
  ea8fae9... Fix strip so that is accepts -M as an abbreviation for --me (*)
  5c14473... Change readelf so that when --wide is active a relocation's (*)
  ef336cb... Update README-how-to-make-a-release with the correct sequen (*)
  9c0f3d3... PR22239 - invalid memory read in display_debug_frames (*)
  c91933e... Update my email address. (*)
  2ca7de3... bfd_set_input_error (*)
  7d36e27... Add an assembler test for PR gas/21167 (*)
  8c6716e... bfd_error_on_input is for archives (*)
  e6fef60... Automatic date update in version.in (*)
  db4677b... PR21167, relocation sections not included in groups (*)
  5cd63fd... Fix "Remote 'g' packet reply is too long" problems with mul (*)
  ed4227b... Reimplement support for "maint print registers" with no run (*)
  55b11dd... Redesign mock environment for gdbarch selftests (*)
  4c71c10... Fix -list-thread-groups --available logic and add test (*)
  73dcd72... Move code out of 'between TRY and CATCH' (*)
  4470452... Add missing-END_CATCH detection/protection (to gdb's TRY/CA (*)
  a87c142... Add missing-END_CATCH detection/protection (to gdb's TRY/CA (*)
  bc3b087... Extend "set cwd" to work on gdbserver (*)
  d092c5a... Implement "set cwd" command on GDB (*)
  7da0a88... Introduce gdb_tilde_expand (*)
  a525959... PowerPC64 ELFv2 symbols not needed in get_synthetic_symtab (*)
  9ba5f27... PR22245, Fix potential UB in bfd_set_error (*)
  ca2a727... Automatic date update in version.in (*)
  db8dd16... gdbarch: Remove duplicate `struct objfile' declaration (*)
  c0107b0... Update my email address. (*)
  f8bfbf2... Fix incorrect string_printf use in utils.c (*)
  5178ed4... Use std::string in info_symbol_command (*)
  8cff873... Use std::string in gdb_safe_append_history (*)
  895b8f3... Remove make_delete_ui_cleanup (*)
  0efef64... Use gdb::byte_vector in load_progress (*)
  245ad7d... Remove unused declarations (*)
  e05550d... Use std::string in utils.c (*)
  b95de2b... Remove set_batch_flag_and_make_cleanup_restore_page_info (*)
  0703651... Change record_full_gdb_operation_disable_set not to return  (*)
  9194f82... PR21294, Binary size regression on PPC embedded (*)
  40c0777... Automatic date update in version.in (*)
  def5c83... ld -z relro documentation (*)
  45320ff... Fix &str printing in Rust (*)
  b3e3859... Fix ptype of Rust slices (*)
  01af5e0... Allow indexing of &str in Rust (*)
  888e3dd... Add missing "extern" in rust-lang.h (*)
  cc536b2... Fix GDB build with G++ 4.8 (*)
  289a684... nto & lynx x86: call init_target_desc (*)
  dcd2b8a... Fix powerpc comment typo (*)
  7a0c60f... Automatic date update in version.in (*)
  bfec0f1... PR22232, NULL pointer dereference in load_specific_debug_se (*)
  8cb1232... PR21970, assertion failed when more than one overlay has su (*)
  2023094... PR21957, addr2line incorrectly handles non-increasing seque (*)
  d2e6c9a... Add new mnemonics for VLE multiple load instructions (*)
  4b04bba... PR22047, Heap out of bounds read in parse_comp_unit (*)
  4f1881b... PR22230, buffer overflow in display_debug_macro (*)
  3678b25... Automatic date update in version.in (*)
  2715765... Add a test for PR binutils/21978 (*)
  386c861... Remove free_memory_read_result_vector (*)
  789c4b5... Change captured_mi_execute_command to use scoped_restore (*)
  ab816a2... Use a std::vector for ada_exceptions_list (*)
  52f9abe... Use std::set in mi-main.c (*)
  dcd5ddc... Use std::string in mi-main.c (*)
  45d288c... Use gdb::byte_vector in mi_cmd_data_write_memory_bytes (*)
  6afe2f4... Remove unused declaration (*)
  9813429... Don't copy a string in mi_cmd_disassemble (*)
  2d6960b... Remove cleanups from mi-cmd-var.c (*)
  784c453... Remove cleanups from mi_cmd_break_insert_1 (*)
  a9bc57b... Remove make_cleanup_defer_target_commit_resume (*)
  9754d8c... Remove some unused declarations (*)
  99ef965... Remove a cleanup from symtab.c (*)
  42518ba... Remove cleanup from mt-tdep.c (*)
  726b216... Remove cleanup from xstormy16-tdep.c (*)
  55b0643... Remove cleanup from complaints.c (*)
  8abcee9... Remove some cleanups from tracepoint.c (*)
  6ad94bc... Remove cleanups from cp-support.c (*)
  2003f3d... Remove some cleanups from stack.c (*)
  8f8accb... Remove cleanup from tilegx-tdep.c (*)
  200aa7b... Remove cleanups from utils.c (*)
  606aae8... Remove cleanup from display_gdb_prompt (*)
  bd41379... Introduce string_vprintf (*)
  8b5b252... PR21978, objdump does not display line numbers in certain c (*)
  1755697... Automatic date update in version.in (*)
  256642e... Constify unpack_varlen_hex & fix fallout (*)
  b6bb346... gdb/remote.c: Eliminate target_buf/target_buf_size hack (*)
  5b9ca4d... gdbserver/libthread_db: Don't ignore memory reading failure (*)
  94c207e... Fix gdbserver regression exposed by gdb.threads/multi-creat (*)
  f6ac8c5... Fail when string merge can't alloc memory (*)
  1b8f6c7... Automatic date update in version.in (*)
  b2f8eb7... Move utils-selftests.c -> gdb/unittests/ (*)
  08302ed... (open_and_init_dwp_file): Protect against some segvs (*)
  231ca75... Skip the PR 14918 linker test for ARM targets. (*)
  1a3b5c3... PR22220, BFD linker wrongly marks symbols as PREVAILING_DEF (*)
  5030076... Automatic date update in version.in (*)
  96a5a1d... Complete tdep move to convert_typed_floating (*)
  0db7851... Simplify floatformat_from_type (*)
  77b7c78... Make init_type/arch_type take a size in bits (*)
  8e43602... Add support for the new names of the RISC-V fmv.x.s and fmv (*)
  f21b4d5... Constify find_command (*)
  643c2ff... Constify some commands in ada-tasks.c (*)
  510e5e5... Constify some commands in symtab.c (*)
  e503b19... Constify some commands in inferior.c (*)
  4e00131... Constify some commands in regcache.c (*)
  7776370... Constify some commands in printcmd.c (*)
  4495129... Constify some commands in breakpoint.c (*)
  3088cf4... Constify some commands in macrocmd.c (*)
  69f476a... Constify some commands in infcmd.c (*)
  c4a3e68... Constify some commands in i386-tdep.c (*)
  c9d31bd... Constify add_symbol_file_from_memory_command (*)
  1f3f85e... Constify demangle_command (*)
  9c504b5... Constify maintenance_info_program_spaces_command (*)
  6663cf9... Constify some commands in compile.c (*)
  34e5fa2... Constify maintenance_print_reggroups (*)
  8384c35... Constify save_gdb_index_command (*)
  884beb0... Constify info_probes_stap_command (*)
  e0b2930... Constify unset_exec_wrapper_command (*)
  f938677... Constify some commands in btrace.c (*)
  8949cb8... Constify delete_bookmark_command (*)
  ac88e2d... Constify some commands in remote.c (*)
  bd4c9df... Constify some commands in mips-tdep.c (*)
  5e93d4c... Constify cd_command (*)
  fc41a75... Constify some commands in thread.c (*)
  6781007... Constify some commands in probes.c (*)
  1d8b34a... Constify some commands in exec.c, plus symbol_file_command (*)
  442019e... Constify some commands in remote-fileio.c (*)
  2983f7c... Constify some commands in tracepoint.c (*)
  4fd41b2... Constify some commands in ax-gdb.c (*)
  f2fc301... Constify some linespec functions (*)
  8c2f95f... Constify some commands in record.c (*)
  a0d6576... Constify some commands in source.c (*)
  5897114... Constify commands maint.c, plus maintenance_print_type (*)
  c482f52... Constify unwind_command (*)
  e100df1... Constify some commands in target-descriptions.c (*)
  31d56ad... Constify maintenance_print_dummy_frames (*)
  b961da0... Constify some commands in tui.c (*)
  e2d8ae1... Constify tui_reg_command (*)
  863779b... Constify some commands in skip.c (*)
  cdb34d4... Constify some commands in record-btrace.c (*)
  e99c83e... Constify some commands in symmisc.c (*)
  32faf97... Constify new_ui_command (*)
  2cf311e... Constify some commands in symfile.c (*)
  e673869... Constify some commands in spu-tdep.c (*)
  aa360cd... Constify some commands in cli-logging.c (*)
  898241a... Constify user_defined_command (*)
  2d0ac10... Constify commands in cli-dump.c (*)
  dede02c... Constify some commands in  cli-cmds.c (*)
  d3cb6b9... Constify maintenance_print_target_stack (*)
  1970a12... Constify interpreter_exec_cmd (*)
  4124365... Constify cmd_record_full_restore (*)
  4465d9d... Constify some functions in memattr.c (*)
  ad25e42... Constify show_convenience (*)
  d64097b... Constify core_file_command (*)
  4d4589e... Constify maintenance_print_user_registers (*)
  32a7bf1... Constify maintenance_cplus_namespace (*)
  4a47555... Constify first_component_command (*)
  990b9f9... Constify some functions in psymtab.c (*)
  c281872... Constify display_tib (*)
  5b64bf7... Constify two functions in linux-fork.c (*)
  4ada038... Constify two functions in cp-abi.c (*)
  57f5a81... Constify dump_arc_instruction_command (*)
  b0a8e6c... Constify two functions in valprint.c (*)
  8d97dc1... Constify info_probes_dtrace_command (*)
  eb7c454... Constify not_just_help_class_command (*)
  e4e3333... Constify add_cmd gdb_bfd.c (*)
  0450cc4... Add add_cmd function overloads (*)
  a9bbfbd... Add support for __VA_OPT__ (*)
  1948519... Prevent an infinite loop in the DWARF parsing code when enc (*)
  6bd6a03... PR22216, infinite loop in readelf process_symbol_table (*)
  cd28e7a... nds32: Fix a tautological comparison. (*)
  25c7861... Automatic date update in version.in (*)
  ac69a0d... x86-64: Don't pass output_bfd to info->callbacks->minfo (*)
  5230b05... dwarf2read: Restrict ICC workaround to ICC<14 (*)
  b32b108... Move GDB producer parsing routines to a separate file (*)
  75352e2... Use "switch_to_thread" more thoroughly on gdbserver (*)
  5007d76... Allow linking GDB with ncursesw (*)
  262c0a8... Fix an assertion failure when parsing a fuzzed x86_64 ELF b (*)
  00956d3... Fix incorrect register mask. (*)
  33e0a9a... Tidy reading data in read_formatted_entries (*)
  30d0157... Avoid needless resource usage when processing a corrupt DWA (*)
  281c444... Remove support for Solaris < 10 (PR gdb/22185) (*)
  39b06c2... Fix gdb 8.1 Solaris/SPARC compilation (PR build/22206) (*)
  1b86808... PR22209, invalid memory read in find_abstract_instance_name (*)
  5c1c468... Fix address violations when parsing a corrupt DWARF linenum (*)
  28d810f... LD/testsuite: Fix undefined symbol tests for MIPS and S+cor (*)
  58a0b82... Allow the macw and macl instructions to be used on CPUs tha (*)
  78b2179... Add README file for creating binutils releases (*)
  df8899e... Fix FAILs in compare-sections.exp (*)
  66cfc0f... PR21732, String-concatenated message can not be translated (*)
  6c3e20f... Remove the last cleanup from regcache.c (*)
  b292235... Remove make_cleanup_regcache_invalidate (*)
  9ac86b5... Remove make_cleanup_regcache_xfree (*)
  c0e383c... Remove regcache_xfree (*)
  791199c... Remove regcache_xmalloc (*)
  a54018b... PR22205, .debug_line file table NULL filename (*)
  e338894... PR22204, Lack of DW_LNE_end_sequence causes "infinite" loop (*)
  898f57a... Automatic date update in version.in (*)
  8dba52b... Free memory returned from bfd_get_synthetic_symtab (*)
  289e23a... S390: Document guarded-storage register support (*)
  ad33963... S390: Add guarded-storage register support to gdbserver (*)
  1b63490... S390: Add guarded-storage register support to GDB (*)
  96235dc... S390: Add guarded-storage register definitions and tdescs (*)
  1da5c9a... PR22202, buffer overflow in parse_die (*)
  11855d8... PR22201, DW_AT_name with out of bounds reference (*)
  c361faa... PR22200, DWARF5 .debug_line sanity check (*)
  57a024f... Initialize 'imm' on opcodes/aarch64-opc.c:expand_fp_imm (an (*)
  5b3fd0a... Automatic date update in version.in (*)
  52b36c5... PR22197, buffer overflow in bfd_get_debug_link_info_1 (*)
  a26a013... PR22191, memory leak in dwarf2.c (*)
  52a93b9... PR22187, infinite loop in find_abstract_instance_name (*)
  d8010d3... PR22186, divide-by-zero in decode_line_info (*)
  515f23e... PR22169, heap-based buffer overflow in read_1_byte (*)
  0d76029... PR22167, NULL pointer dereference in scan_unit_for_symbols (*)
  bd61e13... PR22166, SHT_GNU_verneed memory allocation (*)
  8d296e2... Automatic date update in version.in (*)
  b4a7c69... Removed unused declaration (*)
  4102159... Automatic date update in version.in (*)
  c2f9753... Change type of scoped_input_handler::m_quit_handler (*)
  61e3bf5... x86: Guard against corrupted PLT (*)
  59ca4c1... Update ChangeLog entry for PR 22163 (*)
  9f27220... LVU: dump loclists with locviews (*)
  4357301... Get rid of "gdb_dirbuf" and use "getcwd (NULL, 0)" (*)
  6ec2e0f... Import "glob" and "getcwd" modules from gnulib (*)
  0cf44ec... [GOLD] Set non-exec stack for aarch64 (*)
  cc4d742... gdbserver x86 on win32: call init_target_desc (*)
  b69e926... x86: Return -1 if bfd_canonicalize_dynamic_reloc returns 0 (*)
  be2b629... Add a test for PR ld/22150 (*)
  b877d21... bfd/version.h: Add rationale for BFD_VERSION_DATE (*)
  432ae71... Fix sometimes-uninitialized warning in gdbscm_value_address (*)
  4fa7574... Fix gdb 8.1 Solaris compilation (*)
  7790bd6... [GOLD] clone assert breakage (*)
  ec76901... [GOLD] Set non-exec stack for ppc64 (*)
  11bb0c7... readelf tests (*)
  df52f33... Automatic date update in version.in (*)
  ef272ca... readelf: Handle E_MIPS_MACH_5900 (*)
  42c0794... PR gas/21762: MIPS: Fix .stabs directive marking labels as  (*)
  757bf54... Test case for Inferior.thread_from_thread_handle (*)
  f2ff95c... Documentation for qXfer:threads:read handle attribute (*)
  f6327dc... Add thread_handle_to_thread_info support for remote targets (*)
  8629910... Add thread_db_notice_clone to gdbserver (*)
  da2c323... Documentation for Inferior.thread_from_thread_handle (*)
  fbbe533... Add `thread_from_thread_handle' method to (Python) gdb.Infe (*)
  e04ee09... Add target method for converting thread handle to thread_in (*)
  f557a88... gdbserver: Remove traces of ancient Hc handling (*)
  8fe09d7... S/390: Fix Elf note swap s390_gs_bc vs. s390_gs_cb (*)
  ba52cbb... Reduce excessive .eh_frame alignment for powerpc (*)
  1e5b66e... linux-waitpid: Get rid of format string warning (*)
  ebe48ba... microblaze-tdep: Add ATTRIBUTE_PRINTF to microblaze_debug (*)
  0a0bf5d... Fix aarch64-freebsd build failure (*)
  ea5cf0f... oops - changelog entry omitted from previous delta (*)
  88240b1... [SIM, ARM] Fix build failure (*)
  d1b0a7b... Change counted_command_line to a shared_ptr (*)
  48649e1... Use function_view in a couple of places in breakpoint.c (*)
  04afa70... Allocate bpstats with new (*)
  f5b358c... Automatic date update in version.in (*)
  c83833f... eval.c:evaluate_subexp_standard: Use RAII to avoid leaks (*)
  ca464aa... Check for export dynamic symbol options when doing symbol r (*)
  223ffa7... Remove make_cleanup_restore_target_terminal (*)
  013af3f... Overload catch_command_errors (*)
  06871ae... Make "list ambiguous" show symbol names too (*)
  e5f25bc... Fix "list ambiguous_variable" (*)
  1b7fa39... [OBV] amd64-features-makefile: add missing backslash. (*)
  37dd082... add ChangeLog from previous commit (*)
  6470a84... gdb - avx512: tests were failing due to missing memory alig (*)
  64b5d6d... [GOLD] PowerPC function address in non-PIC (*)
  dba74cb... Automatic date update in version.in (*)
  4e5a4f5... Add a 'starti' command. (*)
  b7f5405... MIPS/LD: Add OpenBSD/mips64 support (*)
  aa70c9f... Remove one explicit rule for monitor.o (*)
  d654162... Use DISABLE_COPY_AND_ASSIGN (*)
  25516cc... PowerPC64 stubs don't match calculated size (*)
  3d13f3e... PR22150, ld keeps a version reference for gc'd symbols (*)
  ab502e6... [GOLD, PowerPC] Add --no-stub-group-multi (*)
  ced154d... Automatic date update in version.in (*)
  94670f6... Check error return from bfd_canonicalize_dynamic_reloc (*)
  0615127... dwarf2expr: Remove unused abort_expression label in execute (*)
  e4114cb... [PATCH] Sync libiberty/ & include/ with GCC - addendum: upd (*)
  35d3b1d... Automatic date update in version.in (*)
  d9d0d1b... Automatic date update in version.in (*)
  04fd3ba... Refactor handle_qxfer_libraries and friends to use std::str (*)
  5e18755... Make xml_escape_text return an std::string (*)
  c3d7b54... Add unit test for xml_escape_text (*)
  1526853... Add selftests run filtering (*)
  5846367... mi_load_progress: Restore current_uiout using a scoped_rest (*)
  bd77e8f... mi_load_progress: Use unique_ptr to manage ui_out lifetime (*)
  c4dfafa... Use std::vector on tdesc->reg_defs (gdbserver/tdesc.h) (*)
  ebee328... Automatic date update in version.in (*)
  26a6791... Sync libiberty/ & include/ with GCC (*)
  124aceb... gdbserver: Remove thread_to_gdb_id (*)
  96cde54... gdbserver: Remove gdb_id_to_thread_id (*)
  e8ca139... gdbserver: Move detach code to its own function (*)
  f8a4e11... Deduplicate require_running macros and move them up (*)
  ef87240... Add -l option to src-release script. (*)
  0eb0a40... linux-low: Remove unused variables (*)
  3f8a780... dwarf2read: Replace copy_string usages with savestring (*)
  785922a... gdbserver: Remove duplicate functions to find any thread of (*)
  8d20070... Fix x86 build failures (*)
  8fd138c... PR22118, Incorrectly-capitalized regexp (*)
  817b771... Enable/disable various dirs in src-release.sh (*)
  21d0a60... Error when 32-bit ar tries to handle 4G or larger files (*)
  cc3e190... Automatic date update in version.in (*)
  d185219... Make dwarf_expr_context::stack an std::vector (*)
  5f93de4... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  79254a5... globalaudit.rd: Allow additional bits in DT_FLAGS_1 (*)
  5e5e02a... x86: Cache section contents and relocations (*)
  26e53f3... gdb.base/nodebug.exp: Rename called functions (*)
  8057eaf... Apply 2 elfxx-x86 patches (*)
  365ccbe... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  eccd80d... Make dwarf_expr_context::stack_empty_p return a bool (*)
  6900988... Make dwarf_stack_value::in_stack_memory a bool (*)
  1e46716... Make dwarf_expr_piece::pieces an std::vector (*)
  4d465c6... Fix address violation when parsing a corrupt PE binary. (*)
  255300f... Add enable-gold and enable-ld to src-release (*)
  2578f2f... PR22127, as segfaults assembling invalid .reloc (*)
  0952b71... Automatic date update in version.in (*)
  f47432d... elfxx-x86.h: Fix a typo in comments (*)
  9f2815a... Automatic date update in version.in (*)
  0782db8... probe: Replace VEC(probe_ops_cp) with std::vector (*)
  1eac6be... Make collect_probes return an std::vector (*)
  aaa63a3... Make probe_ops::get_probes fill an std::vector (*)
  331f81b... Automatic date update in version.in (*)
  cb85b21... Remove make_show_memory_breakpoints_cleanup (*)
  8fbc99e... Use std::string in d-namespace.c (*)
  50feb4b... Use std::string in ctf_start (*)
  c6dc63a... Remove cleanups from find_frame_funname (*)
  d6b9b80... Remove cleanups from findcmd.c (*)
  a992162... Replace clear_hook_in_cleanup with scoped_restore_hook_in (*)
  be0d7ab... Replace interp_set_temp with scoped_restore_interp (*)
  00f675f... Change setup_breakpoint_reporting to return a scoped_restor (*)
  cb791d5... Make extract_arg return a std::string (*)
  2039bd9... Constify language_enum (*)
  f1735a5... Rename _const functions to use overloading instead (*)
  7d221d7... Make it simpler to add events to Python (*)
  35c61a1... Small event ownership clean up in Python layer (*)
  7c96f8c... Add new_inferior, inferior_deleted, and new_thread events (*)
  4ec521f... nds32: Rename __BIT() to N32_BIT(). (*)
  555cb16... Automatic date update in version.in (*)
  a059f00... Fix build breakage on GNU/Linux AArch64, take 2 (*)
  cc397f3... Fix build breakage on GNU/Linux AArch64 (*)
  72542b8... gdb: Remove check for gdb_stderr == NULL (*)
  502b834... Automatic date update in version.in (*)
  0d64823... Remove unnecessary calls to is_mi_like_p in print_thread_in (*)
  eb1e02f... Use std::vector in add_using_directive (*)
  0fc21fd... Use gdb::def_vector in create_sals_line_offset (*)
  49663d0... Use gdb::byte_vector in pascal_object_print_value (*)
  0b868b6... Use gdb::def_vector in func_command (*)
  c0470d4... Use ui_out_emit_list and ui_out_emit_tuple with gdb::option (*)
  ca5909c... Remove make_cleanup_ui_out_redirect_pop (*)
  e6a2252... Use ui_out_emit_list in more places (*)
  393702c... Use ui_out_emit_tuple in disasm.c (*)
  76f9c9c... Use ui_out_emit_tuple in more places (*)
  dc9fe18... Remove make_cleanup_ui_out_table_begin_end (*)
  f8cc3da... Use ui_out_emit_table and ui_out_emit_list in print_thread_ (*)
  481695e... Remove unnecessary function prototypes. (*)
  2420fff... PowerPC64 --plt-align (*)
  372b26b... Remove binutils-pr22115.patch (*)
  246a850... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  c5bce5c... x86: Update UNDEFINED_WEAK_RESOLVED_TO_ZERO (*)
  8fbf0ba... x86: Don't check has_non_got_reloc (*)
  4e9ac44... x86: Remove restriction on NOTRACK prefix position (*)
  0a27fed... x86: Properly handle __ehdr_start (*)
  90d4990... Automatic date update in version.in (*)
  a611b5c... Remove unused field field_info.fnfields (*)
  3484638... Apply binutils-pr22115.patch (*)
  9924d30... Remove binutils-x86-convert-load.patch (*)
  f1a1c6c... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  c7df954... x86: Update comments in elfxx-x86.h (*)
  469412d... Remove C/C++ relevant code in Fortran specific file. (*)
  e0f8643... fortran: Testsuite, fix typos in vla-value. (*)
  9e9af4b... Fortran: Testsuite, fix differences in type naming. (*)
  a5ad232... Fix indentation for printing Fortran types with pointers (*)
  1de031c... x86: Replace elf_x86_plt_layout_table with elf_x86_init_tab (*)
  7a382c1... x86; Don't add elf64-x86-64.lo nor elf64.lo together with e (*)
  bd757a5... Automatic date update in version.in (*)
  ed0816b... RISC-V: Avoid emitting invalid instructions in mixed RVC/no (*)
  9eb7b0a... RISC-V: Print an error when unable to align a section (*)
  b1308d2... RISC-V: Support PCREL_* relocations agaist weak undefined s (*)
  e501422... Document the GDB 8.0.1 release in gdb/ChangeLog (*)
  63c9914... remove QStartupWithShell entry from NEWS::Changes in GDB 7. (*)
  6999821... x86: Remove _bfd_{i386,x86_64}_elf_convert_load (*)
  512a8d4... Update binutils-x86-convert-load.patch (*)
  4c291a8... Update binutils-x86-convert-load.patch (*)
  d354a13... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  639257e... Automatic date update in version.in (*)
  69c1e05... Change funcall_chain to be a std::vector (*)
  fef704b... Remove last cleanups from go-exp.y (*)
  5613c58... Remove last cleanups from d-exp.y (*)
  eae4921... Remove make_cleanup_clear_parser_state (*)
  73b9be8... Introduce dw2_linkage_name and dw2_linkage_name_attr. (*)
  5c887dd... Honor an existing CC_FOR_BUILD in the environment for sim. (*)
  5aec60e... Cast char constant to int in sizeof.exp (*)
  a102602... Correct shell compatibility issue detected with pkgsrc. (*)
  8f8f815... Fix calls in gdb.arch/thumb2-it.exp (*)
  28ad437... Define HAVE_NATIVE_GCORE_HOST on NetBSD (*)
  351787d... Add native target for FreeBSD/aarch64. (*)
  c0f8495... Add FreeBSD/aarch64 architecture. (*)
  7610297... Add myself as a write-after-approval GDB maintainer. (*)
  2dfb2ca... Apply x86: Remove _bfd_{i386,x86_64}_elf_convert_load (*)
  3a53d12... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  7898495... x86-64: Add R_X86_64_converted_reloc_bit (*)
  419414e... x86: Don't change r_type when performing TLS transitions (*)
  fbd1b77... Fix accessing TLS variables with no debug info (*)
  39250b0... Automatic date update in version.in (*)
  dc08907... x86-64: Properly set converted_reloc (*)
  5ca79ea... Fix leak of auto_obstack objfile_per_bfd_storage->storage_o (*)
  8b43e45... x86-64: Improve GOTPCREL relocation conversion (*)
  5eb5f85... Don't use -fdiagnostics-color=never for rustc (*)
  ae780a2... Test different follow-exec-mode settings in gdb.multi/multi (*)
  bf93d7b... Add thread after updating gdbarch when exec'ing (*)
  1bb7c05... Read stop_pc after updating the gdbarch when exec'ing (*)
  fc80982... Improve "'g' reply is is to long" error message (*)
  d2fcdd8... Add i386.o to gdb_target_obs for x86_64-* targets (*)
  e69570e... eval.c:evaluate_subexp_standard: Factor out function call h (*)
  f17e9d8... Fix a buffer overrun when parsing a corrupt MIPS ELF binary (*)
  22916b0... Convert the rest x86 target descriptions (*)
  0854b7b... Remove features/i386/amd64-*linux.c and features/i386/x32-* (*)
  38602d5... [GDBserver] Shorten srv_amd64_linux_xmlfiles (*)
  44b886f... [GDBserver] Use pre-generated amd64-linux tdesc as test (*)
  b4570e4... Convert amd64-linux target descriptions (*)
  6c73f67... Lazily and dynamically create amd64-linux target descriptio (*)
  9d3d478... Centralize amd64-linux target descriptions (*)
  b9f1d50... Update comments in amd64_linux_core_read_description (*)
  d1f28ea... [GDBserver] Shorten srv_i386_linux_xmlfiles (*)
  25a9358... [GDBserver] Use pre-generated tdesc as test (*)
  188c9e6... Remove features/i386/i386-*linux.c (*)
  5f035c0... Share i386-linux target description between GDB and GDBserv (*)
  0abe8a8... Dynamically composite xml in reply to GDB (*)
  0a18838... [GDBserver] unit test to i386_tdesc (*)
  f49ff00... [GDBserver] Centralize tdesc for i386-linux (*)
  2b68ef2... Return X86_TDESC_MMX in x86_get_ipa_tdesc_idx (*)
  f700054... Use VEC for target_desc.reg_defs (*)
  c9a5e2a... Adjust code generated by regformats/regdat.sh (*)
  d6b687a... expprint: Fix format string warning (*)
  625ce09... Define an error function in the PPC simulator library. (*)
  a379bfd... Enable support for x86 debug registers on NetBSD. (*)
  f7efc96... Make <sys/user.h> include in bsd-kvm.c conditional on HAVE_ (*)
  c49fbc6... Define _KMEMUSER before including BSD kernel headers. (*)
  26562e7... Include "x86-xstate.h" for X86_XSTATE_* constants. (*)
  0097251... Automatic date update in version.in (*)
  83eef88... Missing relocation R_PPC_VLE_ADDR20 and add VLE flag to det (*)
  31cf148... Explicitly include <array> for std::array<>. (*)
  5b9f8a7... Catch up to recent changes to call_function_by_hand(). (*)
  d69cf9b... Document "no debug info debugging" improvements (*)
  3693fdb... Make "p S::method() const::static_var" work too (*)
  e68cb8e... Handle "p 'S::method()::static_var'" (quoted) in symbol loo (*)
  858be34... Handle "p S::method()::static_var" in the C++ parser (*)
  dd5901a... Eliminate UNOP_MEMVAL_TLS (*)
  46a4882... Stop assuming no-debug-info variables have type int (*)
  fe13dfe... evaluate_subexp_standard: Factor out OP_VAR_VALUE handling. (*)
  d008ee2... evaluate_subexp_standard: Remove useless assignments (*)
  827d0c5... evaluate_subexp_standard: Eliminate one goto (*)
  2c5a2be... Make ptype/whatis print function name of functions with no  (*)
  74ea4be... Introduce OP_VAR_MSYM_VALUE (*)
  7022349... Stop assuming no-debug-info functions return int (*)
  5499059... Fix calling prototyped functions via function pointers (*)
  34d16ea... gdb.base/commands.exp: Test loop_break and loop_continue in (*)
  9a24775... Introduce gdb_disassembly_flags (*)
  9521ecd... Add tests for loop_break and loop_continue commands (*)
  80a65e9... Error out immediatly when using if command without args in  (*)
  6b66338... Move command lines types/declarations to cli-script.h (*)
  50a421a... gdbserver Makefile: don't delete intermediary files (*)
  51abb42... Kill init_sal (*)
  6c5b2eb... struct symtabs_and_lines -> std::vector<symtab_and_line> (*)
  7c44b49... Introduce gdb::array_view (*)
  e439fa1... Clarify "list" output when specified lines are ambiguous (*)
  7525b64... Fix build breakage when libipt is available (*)
  6c86977... Fix simulator (*)
  badc002... Let i386_target_description return tdesc_i386_mmx (*)
  d78bdb5... Return X86_XSTATE_SSE_MASK instead of 0 in i386fbsd_core_re (*)
  ca1fa5e... Use i386_target_description to get tdesc_i386 (*)
  2434b01... Use amd64_target_description to get tdesc_amd64 (*)
  0860c43... btrace: Store btrace_insn in an std::vector (*)
  a826403... Automatic date update in version.in (*)
  0638b7f... Use std::string in reopen_exec_file (*)
  8f84fb0... Use std::string and unique_xmalloc_ptr in compile/ code (*)
  18e9961... Return std::string from perror_string (*)
  4534378... Use std::string and unique_xmalloc_ptr in demangle_command (*)
  b57af50... Use std::string in do_set_command (*)
  6eecf35... Use unique_xmalloc_ptr in cd_command (*)
  56496dd... Use std::string in mi_cmd_interpreter_exec (*)
  e91a1fa... Use unique_xmalloc_ptr in env_execute_cli_command (*)
  7ffd83d... Use std::string thread.c (*)
  1ccbe99... Return std::string from memory_error_message (*)
  de64ecc... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  f4300d1... Update binutils-x86-gpoff.patch against master (*)
  0e30d99... x86-64: Set tlsdesc_plt if GOT_TLS_GDESC_P is true (*)
  1cf5843... PR22067, x86 check_relocs invalid read (*)
  d633abb... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  23fdd69... Make target_waitstatus_to_string return an std::string (*)
  f04bdfa... Initialize tls_get_addr for x86-64 in one place (*)
  d47a802... Add missing ChangeLog entries (*)
  2ac3a7f... Add elf64-x86-64.lo together with elfxx-x86.lo for 64-bit B (*)
  aed0241... Automatic date update in version.in (*)
  5e2ac45... x86: Add _bfd_x86_elf_size_dynamic_sections (*)
  2926eb2... x86: Rearrange fields and update comments (*)
  92c10f5... i386: Update sgotplt_jump_table_size setting (*)
  aa59524... x86: Define PLT_CIE_LENGTH and PLT_FDE_* in elfxx-x86.h (*)
  b9ce864... x86: Add _bfd_x86_elf_allocate_dynrelocs (*)
  fe53b4a... x86: Add is_x86_elf (*)
  9ff114c... x86: Add elf_x86_compute_jump_table_size (*)
  503294e... x86: Add sizeof_reloc to elf_x86_link_hash_table (*)
  9a742a9... i386: Check VxWorks with htab->is_vxworks (*)
  6b9553e... x86: Move GOT_TLS_* in elf32-i386.c to elfxx-x86.h (*)
  1fa4ec6... LTO rescan archives (*)
  ad71ce8... x86-64: Check ELF_COMMON_DEF_P for common symbols (*)
  96d01d9... -Og warning fixes (*)
  96fbe52... Automatic date update in version.in (*)
  4f501a2... x86: Add _bfd_x86_elf_gc_mark_hook (*)
  eeb2f20... x86: Add _bfd_x86_elf_adjust_dynamic_symbol (*)
  18da07c... Correct ChangeLog entry (*)
  c6295c2... elfxx-x86.h: Fix a typo in comments (*)
  39946cc... x86: Add _bfd_x86_elf_mkobject (*)
  ed53c01... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  a6798ba... x86: Add _bfd_x86_elf_link_setup_gnu_properties (*)
  376dc01... Import latest fixes to libiberty from GCC (*)
  e10c9c6... x86: Correct unwind information for the second PLT (*)
  1c5c938... Enable support for the AArch64 dot-prod instruction in the  (*)
  7e8b600... Prevent an address violation parsing corrupt DWARF informat (*)
  f8ad251... Import latest fixes to libiberty from GCC. (*)
  2a143b9... Fix buffer overrun when parsing an ELF attribute string tha (*)
  5c811d3... PR gdb/22046: Fix T-stopped detach regression on old Linux  (*)
  1f0c135... Automatic date update in version.in (*)
  0a2dde4... Implement the ability to set/unset environment variables to (*)
  e4f2723... Fix buffer read overrun by ensuring that DWARF sections con (*)
  b55f338... Add updated French translations for opcodes and gprof (*)
  d7de640... Add a test for PR ld/22048 (*)
  686335c... Regen SRC-POTFILES.in (*)
  9866ffe... Remove .eh_frame zero terminators (*)
  654670a... Unbreak gdb build on 32-bit host with ADI support (*)
  af471f8... PR22048, Incorrect .eh_frame section in libc.so (*)
  3321e42... Add elf64.lo together with elfxx-x86.lo for 64-bit BFD (*)
  59e8523... FT32: improve disassembly readability (*)
  ef32532... FT32: Permit R_FT32_18 overflow (*)
  e234de6... bfd_close_all_done calling _close_and_cleanup (*)
  e69f326... Automatic date update in version.in (*)
  5dda320... LD/testsuite: Also discard `.MIPS.options' in orphan tests (*)
  82a4977... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  f493882... x86: Add _bfd_x86_elf_get_synthetic_symtab (*)
  5b86dbf... x86: Check target_id instead of elf_machine_code (*)
  ba54661... Update binutils-x86-gpoff.patch against master (*)
  dfa235b... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  765e526... x86: Add _bfd_x86_elf_link_hash_table_create (*)
  70e65ca... MIPS/BFD: Correct microMIPS cross-mode BAL to JALX relaxati (*)
  37b2d32... MIPS/GAS: Also respect `-mignore-branch-isa' with MIPS16 co (*)
  7c0ed39... Call _close_and_cleanup in bfd_close_all_done (*)
  0f2425c... Remove elf_x86_64_next_tls_desc_index/elf_x86_64_srelplt2 (*)
  443701f... Add missing ChangeLog entries (*)
  e491e58... MIPS/GAS/testsuite: Deduplicate error lists of branch local (*)
  9a23f96... PowerPC TPREL16_HA/LO reloc optimization (*)
  b9f04fe... PowerPC64 __tls_get_addr sequence optimization (*)
  c7dffc3... testsuite/ld-cris various files: Run ld with --hash-style=s (*)
  22e5c80... Automatic date update in version.in (*)
  d92b954... Update binutils-x86-gpoff.patch against master (*)
  7755ddb... Look for FIR in the last FreeBSD/mips floating-point regist (*)
  91f2727... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  5f0f084... x86: Re-indent elf32-i386.c/elf64-x86-64.c (*)
  ae40e89... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  0afcef5... Add elfxx-x86.h and elfxx-x86.c (*)
  823cb06... x86: Simplify bad return in get_synthetic_symtab (*)
  37c0b6e... x86: Check valid PLT sections before checking dynamic reloc (*)
  7ef3add... Improve MSP430 section placement. (*)
  3819af1... Fix simulation of MSP430's open system call. (*)
  34e0882... [GOLD] PowerPC tls_get_addr_optimize (*)
  34ca2bd... [GOLD] Reduce size of class Symbol (*)
  f2d394f... Automatic date update in version.in (*)
  972d8a1... 2017-08-28  James Clarke <jrtc27@jrtc27.com> (*)
  0fb0a76... Remove unused _bfd_elf_ifunc_get_synthetic_symtab (*)
  5e89eb3... gdb.base/commands.exp: Remove unused global references (*)
  3804a34... Add missing PR number in ChangeLog (*)
  fd437cb... define_command: Don't convert command name to lower case (*)
  90efb64... x86: Check for valid PLT section size (*)
  cefdd1c... Fix bad offset calculation for R_AARCH64_TLSDESC_* relocs. (*)
  565ed01... [GOLD] Symbol flag for PowerPC64 localentry:0 tracking (*)
  41e5237... Automatic date update in version.in (*)
  32e5eaf... Don't apply "Disallow copy relocation against protected dat (*)
  4f41728... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  596dc58... x86: Initialize def_protected (*)
  a5b4ee9... Disallow copy relocation against protected data symbol (*)
  aecbb01... Automatic date update in version.in (*)
  ff995cc... Update binutils-x86-gpoff.patch for PR ld/21997 fix (*)
  4d94f73... Revert "Update binutils-secondary.patch for PR ld/21997 fix (*)
  f54b68c... Move def_protected to x86 link_hash_entry (*)
  8609ae2... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  7c8bbca... PowerPC TPREL reloc handling (*)
  988f6b3... remove param "dispp" from ada-lang.c::ada_lookup_struct_elt (*)
  5fdda9d... x86: Remove redundant "symbol" in comments (*)
  7d5b8b8... Automatic date update in version.in (*)
  6afd337... gdbserver: Rename some functions, thread -> inferior (*)
  1445030... PR21994, readelf looping on verdefs (*)
  176047c... ld: Add "--" after regexp (*)
  a2d64ef... Automatic date update in version.in (*)
  a160cc4... Remove unused function set_inferior_target_data (*)
  e4cab84... Don't include <asm/prctl.h> in Linux/i386 tests (*)
  1800161... Update binutils-secondary.patch for PR ld/21997 fix (*)
  3ae5934... Apply Disallow copy relocation against protected data symbo (*)
  81e9b8c... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  649556f... Don't apply binutils-pr21964.patch (*)
  074f606... ld: Replace regexp with string match (*)
  28e6a46... x86-64: Run pr22001-1b on x32 (*)
  663c44a... DWARF-5 Fix DW_FORM_implicit_const (*)
  7073b5b... x86-64: Check relocations with -z nocopyreloc (*)
  5b5f4e6... ld: Early detection of orphans we know will be discarded (*)
  34bb257... Revert commit aab921adcb656e4eefcc7d0f14241f3d7504400e (*)
  f190252... DWARF-5: Fix -fdebug-types-section (*)
  7408194... [PowerPC VLE] Add SPE2 and EFS2 instructions support (*)
  647d4de... Test undefined symbols in shared libraries (*)
  f8d3156... Automatic date update in version.in (*)
  49263c5... Update PR ld/21903 tests for dejagnu 1.4.4 (*)
  87215ad... Fix PR remote/21852: Remote run without specifying a local  (*)
  aab921a... x86-64: Properly report output type when PIC is needed (*)
  b1bb697... x86: Increment PLT count only for function symbols (*)
  842bba4... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  73784fa... x86: Clear extern_protected_data for GNU_PROPERTY_NO_COPY_O (*)
  6e41dde... compile: Add 'set compile-gcc' (*)
  e68c32d... compile: set debug compile: Display GCC driver filename (*)
  1c12d34... Update binutils-pr21964.patch against master branch (*)
  f6a36b0... gas: enable PC-relative diff relocations on sparc64 (*)
  b80c727... ppc-opc.c formatting (*)
  452bf67... PR21990, Integer overflow in process_version_sections (*)
  58afddc... gdb: SPARC ADI support (*)
  9897378... Automatic date update in version.in (*)
  9d3420f... Remove pr19161 test hppa xfail (*)
  4643463... Make undefined symbols in allocate_dynrelocs dynamic (*)
  bb4b64b... Assemble powerpc vle lsp tests with -a32 (*)
  11db943... Rename some command functions (*)
  0e4b036... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  8dfb7cb... Update PR ld/21964 tests (*)
  67d888f... RISC-V: Mark "c.nop" as an alias (*)
  5277199... Add test for "List actual code around more than one locatio (*)
  b270e6f... Change install_breakpoint to take a std::unique_ptr (*)
  36bd8ea... Fix erroneous cleanup use in add_solib_catchpoint (*)
  56f3764... Change psymtab_search_name to return a unique_xmalloc_ptr (*)
  0b581c6... Change rewrite_source_path to return a unique_xmalloc_ptr (*)
  14278e1... Change gdb_realpath to return a unique_xmalloc_ptr (*)
  4971c9a... Change gdb_realpath_keepfile to return a unique_xmalloc_ptr (*)
  e3e41d5... Change gdb_abspath to return a unique_xmalloc_ptr (*)
  0d999a6... List actual code around more than one location (*)
  329d5e7... Use an array type (lwpid_t[]) for the array of lwp IDs. (*)
  af3881e... Correct earlier ChangeLog entry for fbsd_add_threads. (*)
  487b644... Make __start/__stop symbols protected visibility (*)
  e3c2f92... [PowerPC VLE] Add LSP (Lightweight Signal Processing) instr (*)
  bf223d3... Handle function aliases better (PR gdb/19487, errno printin (*)
  c973d0a... Fix type casts losing typedefs and reimplement "whatis" typ (*)
  284d826... PR ld/20125, MMIX weak symbols (*)
  454c9bb... Automatic date update in version.in (*)
  7f3d21d... Update testsuite/ld-x86-64/plt-main-bnd.dd (*)
  45aee2d... Automatic date update in version.in (*)
  d7dec58... Automatic date update in version.in (*)
  2989a36... Remove save_inferior_ptid (*)
  e60eb28... [ARM] Mark USER_SPECIFIED_MACHINE_TYPE in disassemble_info. (*)
  6d580b6... GDBserver self tests (*)
  86dcbf5... Remove some GDB specific stuff from selftest.c (*)
  7649770... Put selftests api into selftests namespace (*)
  de25939... Fix buffer overrun parsing a corrupt tekhex binary. (*)
  dd66b39... Automatic date update in version.in (*)
  b0cba12... Plug source_command leak (*)
  4c8aa72... Plug line_header leaks (*)
  714da62... Add test of V2 GNU build attribute notes. (*)
  545bc2b... [AArch64] Skip IFUNC relocations in debug sections (*)
  1260196... Add new Brazilian Portuguese translation for the ld subdire (*)
  ba71391... Synthetic symbol leak in elf_read_minimal_symbols (*)
  44d0fb3... Mention new TUI Single-Key mode shortcuts for nexti and ste (*)
  8c1d4b8... Automatic date update in version.in (*)
  a5afdb1... Add shortcuts for "nexti" and "stepi" commands in Single-Ke (*)
  1a45775... Automatic date update in version.in (*)
  66c3b5f... Add new NT_PPC_* available since Linux 4.8 (*)
  47613ae... Add myself as a write-after-approval GDB maintainer. (*)
  9c3cc99... xtensa: Properly strdup string when building reggroup (*)
  206726f... Fix PR gdb/21954: make 'unset environment' work again (*)
  0335ac6... Fix compile on big-endian platforms in siginfo_t converter. (*)
  8975f86... [Patch AArch64] Turn lr, fp, ip0 and ip1 into proper aliase (*)
  030e221... Update binutils-x86-gpoff.patch against master (*)
  36ffeca... Apply Bind __start/__stop symbols as symbolic in shared obj (*)
  18f844e... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  bf0ec4c... GDB testsuite: Suppress GCC's colored output (*)
  d3abe1c... Remove BITS_IN_BYTES define (*)
  d6382ff... Fix two regressions in scalar printing (*)
  f978cb0... Fix memory leak in add_symbol_file_command (*)
  2f5404b... Use std::move in a few places (*)
  0c54f69... Fix null pointer dereference when parsing a corrupt ELF bin (*)
  d7f00f4... Automatic date update in version.in (*)
  79a94a2... PR21441, Unnecessary padding of .eh_frame section (*)
  34c4758... ld: Restore linker scripts in PR ld/21884 tests (*)
  6d545e3... Fix i686-nacl and x86_64-nacl pr21884 failures (*)
  9ba349b... Automatic date update in version.in (*)
  ca14571... Fix typo on documentation ("show set startup-with-shell") (*)
  c2c2dd9... testsuite: Exclude end-of-line characters from get_valueof  (*)
  483767a... Collision between NT_GNU_BUILD_ATTRIBUTE_OPEN and NT_PPC_VM (*)
  1a682d0... Automatic date update in version.in (*)
  7e7dffe... Update binutils-x86-gpoff.patch against master (*)
  f9b6ce7... Revert "Apply Also disallow global alias of common symbol" (*)
  1d37126... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  98c5dfc... x86: Allocate space for symbol names with symbol table (*)
  93ab9c0... Add -z globalaudit linker command line option to set the DF (*)
  9593aad... Add 2 more tests for PR ld/21884 (*)
  76db0a2... Also disallow global alias of common symbol (*)
  de7985c... More gdb/skip.c C++ification (*)
  be7d3cd... Reset *THIS_CACHE in frame_unwind_try_unwinder in case of e (*)
  1c90d9f... Class-fy dwarf2_frame_state_reg_info (*)
  afe37d6... Class-fy dwarf2_frame_state (*)
  b348037... Move dwarf2_frame_state_reg.exp_len to union .loc (*)
  5af3691... Automatic date update in version.in (*)
  7fa7dd9... Update binutils-secondary.patch for PR gas/21667 fix (*)
  fa7bc1e... Apply Also disallow global alias of common symbol (*)
  4a90249... Update binutils-x86-gpoff.patch against master (*)
  9e2ce07... Update binutils-secondary.patch against master (*)
  b3011b6... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  e7c9de2... Allow gdb::unique_xmalloc_ptr<T[]> (*)
  ca6f2be... Add support for PE startup files that want to define their  (*)
  4c2da80... Fix memory corruption when assembling an i386 darwin source (*)
  957e1fc... Fix out of bounds memory access when trying to allocate spa (*)
  3ecaa9f... Automatic date update in version.in (*)
  7ed1dab... LD_CLASS: Check .libs/ld-new for linker first (*)
  e8c6b62... Replace home-grown linked-lists in FreeBSD's native target  (*)
  e4a2666... Replace remaining cleanups in fbsd-nat.c. (*)
  142311d... Fix compile in the !HAVE_KINFO_GETVMMAP case. (*)
  978c054... Run PR ld/17618 test only with 64-bit ELF linker (*)
  0968fba... doc: Fix copy-pasto in Z0 packet documentation (*)
  42fa2e0... C++-ify skip.c (*)
  cc4a945... [ARM] Don't warn on REG_SP when used in CRC32 instructions (*)
  cd3af38... [AArch64] Implement gdbarch_core_read_description (*)
  0f76ffa... Revert "[AArch64] Implement gdbarch_core_read_description" (*)
  b1a6c1c... [AArch64] Implement gdbarch_core_read_description (*)
  29592bd... Make cp_comp_to_string return a gdb::unique_xmalloc_ptr<cha (*)
  b334043... gdb: Fix build failure with GCC 7 (*)
  e88e865... Fix memory leak in cp-support.c (*)
  f5a29eb... Clean up x86 non-linux GDBserver target descriptions (*)
  57757c2... Remove x32 non-linux target descriptions (*)
  25d28c9... ld: Require GCC 5 or above for 3 x86 tests (*)
  9165f45... ld: Add a ',' after -Wl,--rpath (*)
  a26c49b... Automatic date update in version.in (*)
  fe22cbc... ld: Replace --rpath with -Wl,--rpath (*)
  24d3e51... Fix address violation problems when parsing corrupt ELF bin (*)
  1fea592... Updated Serbian translation for gprof (*)
  cea7a28... Fix address violation bugs when writing beyond the end of a (*)
  206c9c7... PR21017, microblaze missing _GLOBAL_OFFSET_TABLE_ symbol (*)
  5d1ceb0... Automatic date update in version.in (*)
  2760f24... Add configure flag to enable gnu hash style by default. (*)
  8f5e83f... More support for ld --hash-style in the ld testsuite (*)
  e8c140f... Apply x86: Add R_X86_64_GPOFF/R_386_GPOFF relocation (*)
  236f701... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  7b00572... Add missing PR mention in ChangeLog (*)
  ba7b109... PR breakpoints/21886: mem-break: Fix breakpoint insertion l (*)
  b28b8b5... Mark big and mach with ATTRIBUTE_UNUSED (*)
  2980cca... Move common symbol check after bed->common_definition (*)
  e347efc... GDB/opcodes: Remove arch/mach/endian disassembler assertion (*)
  0dba2a6... gdbarch: Use an anonymous union for target data in `gdbarch (*)
  16eb6b2... Fix dwarf2_string_attr for -gsplit-dwarf (*)
  bab55c0... Support different ld --hash-style in the ld testsuite (*)
  b3293ef... PR21910, segfault in common symbol override test when hash- (*)
  74cbb09... remote-sim.c: Fix arg variables conflicts (*)
  b7a1893... Do not choose a non-ELF format input file to hold the linke (*)
  2010d1a... Automatic date update in version.in (*)
  1d4af30... x86: Lookup __tls_get_addr or ___tls_get_addr once (*)
  a4819f5... Treat common symbol as undefined for --no-define-common (*)
  e2a084f... Automatic date update in version.in (*)
  ee0c329... Use gdb::unique_xmalloc_ptr when calling tilde_expand (*)
  fdffd6f... Fix Rust test suite for 1.20 beta (*)
  3232fab... Remove cleanups from Rust parser (*)
  55ef658... Don't fail in elf32_hppa_set_gp (*)
  a66930b... Automatic date update in version.in (*)
  b4dfc24... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  f02fd77... Unbreak GDBserver build for x32 (*)
  91975af... Add namespace std to nullptr_t (*)
  9f06dab... Add a testcase for "ld -d" (*)
  223b97b... Add --no-relax option. (*)
  a30d3a7... Automatic date update in version.in (*)
  2331fa3... Add myself as a write-after-approval GDB maintainer. (*)
  f86c4d2... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  744e4fe... Remove make_cleanup_freeargv and gdb_buildargv (*)
  1c034b6... Use gdb_argv in Python (*)
  773a1ed... Introduce gdb_argv, a class wrapper for buildargv (*)
  0d50bde... Remove a cleanup in Python (*)
  7f968c8... Avoid some manual memory management in Python (*)
  3c9ebdd... Replace do_restore_instream_cleanup with scoped_restore (*)
  b51b225... Use a scoped_restore for command_nest_depth (*)
  ac99163... Remove user_call_depth (*)
  898e0c8... Remove in_user_command (*)
  26fcd5d... Use containers to avoid cleanups (*)
  7c218e6... Use unique_xmalloc_ptr in jit.c (*)
  31b68d4... Replace tui_restore_gdbout with scoped_restore (*)
  2ec845e... More uses of scoped_restore (*)
  b3bc845... Remove make_cleanup_free_so (*)
  e3ad284... Remove make_cleanup_restore_current_language (*)
  b80cf83... Remove an unlink cleanup (*)
  fad0444... Remove make_cleanup_fclose (*)
  6e7bc05... Change open_terminal_stream to return a gdb_file_up (*)
  4a45905... Use gdb_file_up in source.c (*)
  7cd06d6... Use gdb_file_up in fbsd-nat.c (*)
  ed16694... Change return type of find_and_open_script (*)
  d419f42... Introduce and use gdb_file_up (*)
  4a2b031... Introduce and use ui_out_emit_table (*)
  fd9770d... Add more targets to the list of architectures not supportin (*)
  2e9246e... ELF checks for orphan placement (*)
  5f66bad... Automatic date update in version.in (*)
  a4f320f... MIPS: Factor out FPU type naming in `gdbarch' debug (*)
  db99ecc... Check ELF section header only for ELF output (*)
  b8f4abd... Revert the last change to emultempl/elf32.em (*)
  70b0cf9... Add support for creating archives of slim-LTO modules using (*)
  73d5923... Fix assertion failure for xtensa linker. (*)
  ddff3d8... Fix seg-fault when trying to place non-ELF orphan sections. (*)
  d84ed52... Fix potential illegal memory access in Xtensa port. (*)
  75800d2... Fix gas and binutils testsuite failures for am33_2.0-linux  (*)
  262cdac... Teach readelf about IA64 MSB relocs. (*)
  a5be90a... Automatic date update in version.in (*)
  a2f1f30... MIPS: Consistently use MIPS_FPU_TYPE for `gdbarch' member (*)
  1ef692e... S/390: Fix claimfile failures (*)
  4d36230... x86: Update segment register check in Intel syntax (*)
  60c4393... Updated Swedish translation for the binutils sub-directory. (*)
  be897fb... [GOLD] PowerPC recreate eh_frame for stubs on each relax pa (*)
  51b69c7... Automatic date update in version.in (*)
  2141b11... Update myself in MAINTAINERS (*)
  2e957b1... Fix bb instructions with double-word condition on hppa. (*)
  5759343... Improve handling of ADD and SUB relocations on the RISCV ta (*)
  c48a4d9... Fix compile time error when using ansidecl.h with an old ve (*)
  7e5ed83... Update ChangeLog (missed that in my previous commit) (*)
  aacb3b6... [GOLD] PowerPC --no-tls-optimize (*)
  54387c7... Fix compiling zlib using x86_64-musl. (*)
  791fb3d... Fix documentation about rot agent expression bytecode (*)
  4bbd4ef... darwin: handle recent version of dyld (*)
  d44c746... PR 21847, PowerPC64 --plt-localentry again (*)
  93e0a1e... Automatic date update in version.in (*)
  10683b8... Automatic date update in version.in (*)
  8b5f1ed... PR 21847, Don't default PowerPC64 to --plt-localentry (*)
  ef080e7... Automatic date update in version.in (*)
  49ba15a... gold: Add put_ch_reserved to 64-bit Chdr_write (*)
  894dde0... Add missing changelog (*)
  79c12fa... S/390: Fix segfault when linking -shared -nostartfiles (*)
  2b94abd... Make some improvements to how SORT_* specifiers and EXCLUDE (*)
  a808670... Fix problems parsing RISCV architecture extenstions in the  (*)
  242f30e... Automatic date update in version.in (*)
  4c9dc81... Add myself as a write-after-approval GDB maintainer. (*)
  f726cc1... Move AVR .promemx.* sections into higher memory. (*)
  be09588... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  8bdf0be... Fix address violation issues encountered when parsing corru (*)
  63d4980... Automatic date update in version.in (*)
  104f051... Gold: Fix mips.cc for GCC 4.2 (*)
  27d41ea... Add "maint check xml-descriptions" to test builtin xml targ (*)
  ea03d0d... Lazily and dynamically create i386-linux target description (*)
  25aa13e... Generate c for feature instead of tdesc (*)
  6eb1e6a... Use visitor pattern for "maint print c-tdesc" (*)
  35b4818... Centralize i386 linux target descriptions (*)
  8e2141c... Add optional argument to command "maint prints c-tdesc" (*)
  b468ff4... Class-fy target_desc (*)
  229d26f... Add enum for result of fast_tracepoint_collecting (*)
  11f1093... Automatic date update in version.in (*)
  b9c0e1b... Fix two NetBSD-specific typos in the configure.nat conversi (*)
  a04b533... Make amd64_x32_init_abi and amd64_init_abi argument constan (*)
  133193b... Fix thinko in previous change to elf32-msp430.c (*)
  7cbc739... Fix typos in error and option messages in OPCODES library. (*)
  46a6226... Catch exceptions thrown from gdbarch_skip_prologue (*)
  02ad7fc... [ARM] Access FPSCR on vfpv2 (*)
  c26bb06... Updated French translation for the BFD library. (*)
  cfe7b9b... Add a linker branch optimization for the MSP430. (*)
  ec06425... oops - add changelog entry accidentally omitted from previo (*)
  c6b78c9... Stop readelf from returning an error status if asked to dum (*)
  d4aaa2a... __tls_get_addr_opt stub eh_frame info (*)
  aafd383... Automatic date update in version.in (*)
  031ed05... s390-vregs.exp: Fix Tcl error after non-zero-pad patch (*)
  7684e58... [AArch64] Fix the bit pattern order in the comments in auto (*)
  8a2df5e... Fix another memory access error triggered by attempting to  (*)
  ca4cf9b... Fix address violation errors parsing corrupt binary files. (*)
  e8d84ca... Stop the generation of mapping symbols in the debug section (*)
  47aeb64... Improve "unrecognized relocation" error messages to add the (*)
  645b280... [ARC] Fix big-endian ld tests errors. (*)
  8ca02f6... Automatic date update in version.in (*)
  723dfee... * dwarf2dbg.c (dwarf2dbg_final_check): Rename local variabl (*)
  15a3a14... Correct eh_frame info for __glink_PLTresolve (*)
  5c2c002... Automatic date update in version.in (*)
  b6f48cb... Use std::vector in struct catch_syscall_inferior_data (*)
  e12c9b7... Use std::vector in syscall_catchpoint (*)
  4fa8aea... C++-ify break-catch-throw (*)
  f746a15... C++-ify break-catch-sig (*)
  dbdda97... Automatic date update in version.in (*)
  dcd27dd... gdb.python/py-unwind: Disable stack protection (*)
  82c7806... Updated French translation for the binutils subdirectory. (*)
  13bace4... Fix typo in warning message. (*)
  b57e815... Remove unused variables in dwarf parser. (*)
  ba8826a... This patch introduces support for specifing views in .loc d (*)
  47826cd... S/390: Support z14 as CPU name. (*)
  33d69f8... Automatic date update in version.in (*)
  47e7764... Make language_def O(1) (*)
  edb0c9c... get_int_var_value (*)
  a778f16... Use SYMBOL_MATCHES_SEARCH_NAME some more (*)
  42edd90... Eliminate block_iter_name_* (*)
  cf32529... Fix cp_find_first_component_aux bug (*)
  62d2a18... Make gdb.base/dmsym.exp independent of "set language ada" (*)
  2d2dbad... Update the German translation for the opcodes library. (*)
  8e8f892... Automatic date update in version.in (*)
  2018ef8... PR ld/16656: Add missing annotation to the relevant ChangeL (*)
  f2e6a84... [AArch64] Fix PR18841 ifunc relocation ordering (*)
  6c4e7b6... Extend previous fix to coff-rs6000.c to coff64-rs6000.c (*)
  909e4e7... Fix use-after-free error when parsing a corrupt nested arch (*)
  62a5222... LD/testsuite: Add 2**4 section alignment FILL script statem (*)
  29866fa... Fix address violation when attempting to read a corrupt fie (*)
  70b448b... [ARC] Add SecureShield AUX registers (*)
  7179e0e... [ARC] Add SJLI instruction. (*)
  684d5a1... [ARC] Add JLI support. (*)
  e4943f2... Remove datasize measurements based on sbrk() (*)
  804a409... Fix gas crash on missing seh_endproc. (*)
  801f648... Automatic date update in version.in (*)
  927960f... LD/testsuite: Conditionalize the placement of `.got' in GNU (*)
  9a0f1d5... LD/testsuite: Conditionalize the placement of `.dynamic' in (*)
  de194d8... Fix spelling typos. (*)
  c5ed057... Fix Fission (broken by my previous patch) (*)
  e4e21d9... Fix runtime failure triggered by a corrupt ecoff input file (*)
  e29599e... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  27841e7... Remove one line comment (*)
  cfb7e58... Simplify regcache_cpy and remove regcache::cpy_no_passthrou (*)
  c646b4e... Improve doc about "maint print c-tdesc" (*)
  b6a5771... Import updated Ukranian and Swedish translations. (*)
  386535d... Fix GDB builds that include the simulator (*)
  0a79bef... * dwarf.c (display_debug_names): Initialize hash_prev. (*)
  25bda06... Automatic date update in version.in (*)
  89d249d... i386: Add tests for PIE with undefined weak symbol (*)
  8e85f84... Add missing ChangeLog entries for PR ld/21782 fix (*)
  c45ec17... A smarter linespec completer (*)
  be966d4... Linespec lexing and C++ operators (*)
  a245927... Explicit locations -label completer (*)
  c6756f6... Rewrite/enhance explicit locations completer, parse left->r (*)
  c5bb891... x86-64: Limit PIC check to shared library build (*)
  1d550c8... Introduce strncmp_iw (*)
  dd57c19... Re-indent elf_x86_64_relocate_section (*)
  8090b42... Introduce CP_OPERATOR_STR/CP_OPERATOR_LEN and use throughou (*)
  6a2c1b8... "complete" command and completion word break characters (*)
  eb3ff9a... Introduce class completion_tracker & rewrite completion<->r (*)
  6e1dbf8... Clean up "completer_handle_brkchars" callback handling (*)
  78b1310... Rename make_symbol_completion_list_fn -> symbol_completer (*)
  bbf2f4d... Fix TAB-completion + .gdb_index slowness (generalize filena (*)
  330cdd9... C++ify dwarf2_per_objfile (*)
  2a92581... Correct previous fix for an absence of input files on the a (*)
  f27dadc... Update assembler documentation on some AVR cores. (*)
  caa7496... Automatic date update in version.in (*)
  676ee2b... __tls_get_addr_opt GOT entries (*)
  046c08c... Automatic date update in version.in (*)
  5bd6848... gdb: Make some test names unique (*)
  71d01ca... Automatic date update in version.in (*)
  8880f2a... Handle sizeof(type) in Rust (*)
  6554723... Make gdb.lookup_typename work for Rust types (*)
  8f14146... Fix gdb.base/completion.exp with --target_board=dwarf4-gdb- (*)
  0f6329b... binutils/objdump: Fix disassemble for huge elf sections (*)
  86038de... ppc32 tlsopt tests (*)
  211b0be... PR ld/21529: Use a linker script to limit output with the t (*)
  2347965... ax-gdb: Remove more unused arguments (*)
  40f4af2... ax-gdb: Remove unnecessary gdbarch parameters (*)
  053f805... ax-gdb: Remove two unused agent_expr *ax parameters (*)
  6661ad4... ax-gdb: Use ax->gdbarch instead of exp->gdbarch, remove unu (*)
  ee77ed0... Automatic date update in version.in (*)
  e58ff05... Add RDMA support for falkot/qdf24xx. (*)
  b4365d0... gdb: Fix more parameter passing to mi_create_breakpoint (*)
  c55a47e... Fix x86-64 GNU/Linux crashes (*)
  5d2cbaa... gdb: Fix parameter passing to mi_create_breakpoint (*)
  55efcea... S390: Add record/replay support for arch12 instructions (*)
  a502b0b... Always delete $testarchive first (*)
  400e542... Update lto and none-lto input support for ld -r (*)
  bbe7ef6... Automatic date update in version.in (*)
  b7d7d45... Add missing gold/ChangeLog entry. (*)
  429d795... Update PO files (*)
  0bae9e9... Fix compile time warnings building the binutils with gcc 7. (*)
  2fe40b6... rs6000 testsuite update (*)
  d42c267... bfd_error_handler bfd_vma and bfd_size_type args (*)
  bd6a8c1... Automatic date update in version.in (*)
  df2f63a... Fixing for PR gold/21491 - Errata workaround can produce br (*)
  0aa37b6... Support the fs_base and gs_base registers on FreeBSD/amd64  (*)
  48aeef9... Include the fs_base and gs_base registers in amd64 target d (*)
  b384299... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  61a0857... Support single digit GCC version (*)
  04ac15a... Add missing newlines in readelf -n output (*)
  e3fbc3d... ppc32 use of %x in einfo format, typo fix (*)
  54e2cdd... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  a948ad9... Revert "Apply x86-64: Treat ___tls_get_addr like __tls_get_ (*)
  70391b2... [AArch64] Use "#pass" instead of "#..." to filter multiple  (*)
  2c4d9cb... ppc32 use of %x in einfo format (*)
  4162bb6... Mark generated cgen files read-only (*)
  11cb571... Sync dlang demangling tests from upstream libiberty testsui (*)
  36cebdd... Automatic date update in version.in (*)
  6dc8d75... Add missing ChangeLog etries (*)
  adce5b3... Fix compile time warning about duplicate case values for po (*)
  77c501b... Re-generate i386/amd64-avx-avx512-linux.c and i386/amd64-av (*)
  2e1e43e... Re-indent the code (*)
  3d99e81... Import setenv and unsetenv from gnulib (*)
  a074796... Automatic date update in version.in (*)
  14357de... DWARF-5: Fix error message typo. (*)
  266934d... compile-loc2c: Fix uninitialized variable error (*)
  0327869... Fix size check in dwarf2_evaluate_loc_desc_full (*)
  f4db828... Automatic date update in version.in (*)
  12c1f20... Automatic date update in version.in (*)
  4b65446... Read signal information from FreeBSD core dumps. (*)
  e6f3b9c... Create pseudo sections for FreeBSD NT_PTLWPINFO core notes. (*)
  0b9305e... Recognize the recently-added FreeBSD core dump note for LWP (*)
  2af9fc4... Use the thread_section_name helper class in fbsd_core_threa (*)
  382b69b... Add a new gdbarch method to fetch signal information from c (*)
  6e5eab3... Move the thread_section_name class to gdbcore.h. (*)
  929edea... Fetch signal information for native FreeBSD processes. (*)
  762c974... Implement the "get_siginfo_type" gdbarch method for FreeBSD (*)
  e54cb31... MIPS/LD: Fix a segfault from ELF `e_flags' access with non- (*)
  c620a2b... Make ppc476 testcases more robust (*)
  7639175... Move print_insn_XXX to an opcodes internal header, again (*)
  532cc31... Add some missing xcoff support (*)
  aff6079... Apply ld/Makefile.in patch to the correct file (*)
  1cf9552... Another _doprnt fix for %L handling (*)
  9691e72... Automatic date update in version.in (*)
  33c5cd7... Fission support for multiple CUs per DWO file (*)
  a0b7b10... Convert 'L' to 'l' when setting wide_width to 1 (*)
  4b617f5... Automatic date update in version.in (*)
  8455d26... Fix Python unwinder frames regression (*)
  0487c3b... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  1d827a7... Fix build with GCC 4.2 (*)
  2c60360... Apply x86-64: Treat ___tls_get_addr like __tls_get_addr (*)
  02e72ea... Merge remote-tracking branch 'origin/master' into users/hjl (*)
  15a7695... [ARM] Add support for Cortex-A55 and Cortex-A75. (*)
  e4bdd67... X86: Disassemble primary opcode map's group 2 ModRM.reg ==  (*)
  60c96db... Fixup changelog entries for previous commit (*)
  033ea11... Automatic date update in version.in (*)
  4da3eb3... Garbage collect TYPE_STATIC and several TYPE_FN_FIELD_x (*)
  40c7d50... [Patch ARM] Support MVFR2 VFP Coprocessor register for ARMv (*)
  0d702cf... Regenerate configure. (*)
  55a09eb... Add markers. (*)
  564e46b... [AArch64] Remove useless and incorrect assertion (*)
  0041f7d... [binutils patch] DWARF-5: Extend bfd/dwarf2.c parse_comp_un (*)
  568fc4f... Automatic date update in version.in (*)
  d8cd8c1... bfd: partial revert commit EC1ACAB (prevent all but undef w (*)
  15e6ed8... Regenerate pot files. (*)
  19871f4... strings: remove section/file size check (*)
  76cfced... Support %Lx, %Lu, %Ld in _bfd_error_handler format (*)
  ce9116f... BFD long long cleanup (*)
  cd9af60... Miscellaneous format string fixes (*)
  33c734b... Missing config for bfd.c:_doprnt (*)
  8d219ac... Disable symver test on hppa64-hpux (*)
  c8cf1fe... [GOLD] undef after using DW_IDX and friends (*)
  7e70564... Repair include/dwarf2.def breakage (*)
  5bfd255... buffer.h: Fix spelling mistakes (*)
  2040444... Automatic date update in version.in (*)
  6136435... DWARF-5: readelf: .debug_names (*)
  de837d7... Import include/+libiberty/ r249883 from upstream GCC. (*)
  c6eb149... Automatic date update in version.in (*)
  bae7501... Use bfd_malloc_and_get_section (*)
  25c5412... Setup .dir-locals.el to use C-style comments by default (*)
  3c465ea... Automatic date update in version.in (*)
  834a65a... MIPS/GAS: Use a switch on relaxation type in microMIPS fixu (*)
  bbd27b7... MIPS/GAS: Use frag symbol/offset directly in fixup creation (*)
  9f00292... MIPS/GAS: Use non-zero frag offset directly in PIC branch r (*)

(*) This commit exists in a branch whose name matches
    the hooks.noemail config option. No separate email
    sent.

commit 4ba8500d63991518aefef86474576de565e00237
Merge: b8cc0ce c935ff0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Jan 19 03:23:56 2018 -0800

    Merge remote-tracking branch 'origin/users/hjl/linux/master' into users/hjl/linux/applied

commit c935ff02abfbf5bb80aa043340f7d101aac262f2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Jan 12 08:30:10 2018 -0800

    Revert "Add "-z textonly" option to ELF linker"
    
    This reverts commit e87d0965bb97fa186749c8386822cdeb9752df38.
    
    "-z separate-code" has been checked into master branch.

commit d65311466ac5cf72b61af5c82423ba2c4a3d9e13
Merge: 9eed002 564e11c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Jan 12 08:26:19 2018 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 564e11c9a9d9570b233b38cd995f1b4eb7c757e8
Author: Jens Widell <jl@opera.com>
Date:   Fri Jan 12 13:16:17 2018 +0000

    Optimize the performance of the group_setup function.
    
    When processing a section that is a member of a group, the group
    that contains it is looked up using a linear search. The resulting
    O(n^2) complexity causes significant performance issues when
    dealing with object files with very many groups.
    
    By remembering the index of the last found group and restarting
    the next search from that index, the search instead becomes O(n)
    in common cases.
    
    	* elf.c (setup_group): Optimize search for group by remembering
    	last found group and restarting search at that index.
    	* elf-bfd.h (struct elf_obj_tdata): Add group_search_offset field.

commit b5b62006522c6d8d42028754bb1be165f00fe210
Author: Gunther Nikl <gnikl@users.sourceforge.net>
Date:   Fri Jan 12 13:12:17 2018 +0000

    Fix compile time warning building aout targeted architectures.
    
    Occasionally I build an out-of-tree a.out target (m68k-amigaos). After
    a system upgrade which included a newer compiler (clang 4) the build
    produces warnings like this:
    
      warning: macro expansion producing 'defined' has undefined behavior
      [-Wexpansion-to-defined]
    
    This is caused by the macro gas/config/aout_gnu.h:USE_EXTENDED_RELOC.
    Since it is in a header file, the warning triggers for several files.
    I am unsure what solution is preferable, thus I am suggesting two
    patches:
    
      a) keep the offending macro but define it explicitly to 0 and 1
      b) replace the macro usage with its value where it is used.
    
    Either patch removes the warning for clang. I did not check with a
    recent GCC.
    
    	* gas/config/aout_gnu.h (USE_EXTENDED_RELOC): Explicitly
    	define to 0 and 1. Remove a dangling reference to "AMD 29000"
    	in a comment.

commit 5ae5d3fd10c4bb520d767b25c59bf86db764adef
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jan 12 21:10:48 2018 +1030

    pr22374 function pointer initialization
    
    When I added this test I said I'd look at fixing more targets.
    That hasn't happened yet, so xfail to tidy results.
    
    	* testsuite/ld-elf/elf.exp: xfail "pr22374 function pointer
    	initialization" for currently failing targets.

commit a78eea1623aa6d05a395a73414bf01f6c8ae81c6
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jan 12 10:37:28 2018 +1030

    Fix override of common symbols for a.out
    
    The default should be bfd_link_common_skip_none, as in the original
    patch at https://sourceware.org/ml/binutils/2002-07/msg00717.html
    
    	* aoutx.h (aout_link_check_ar_symbols): Remove default and handle
    	bfd_link_common_skip_none in switch.

commit 87e79a6515951fece72ee08871dd6e112b1042ba
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jan 12 16:58:04 2018 +1030

    Fixes for "Ignore dynamic references on forced local symbols"
    
    PowerPC64 has its own mark_dynamic_ref, which needs the same change as
    made by d664fd41e1 to the generic ELF version.  Some other targets
    discard more than just .data, so allow for that too in expected ld
    messages.
    
    bfd/
    	PR ld/22649
    	* elf64-ppc.c (ppc64_elf_gc_mark_dynamic_ref): Ignore dynamic
    	references on forced local symbols.
    ld/
    	PR ld/22649
    	* testsuite/ld-elf/pr22649.msg: Allow other messages.
    	* testsuite/ld-elf/shared.exp: Check that --gc-sections is
    	supported before running ld/22649 tests.

commit 58807c48a5a317ad3e2d39a8755168a3d4d5fdf8
Author: Vlad Ivanov <vlad@ivanov.email>
Date:   Fri Jan 12 09:25:11 2018 +0000

    _bfd_mips_elf_final_link: Notify user about wrong .reginfo size
    
    One of assertions in _bfd_mips_elf_final_link could be triggered by
    a combination of input files and a linker script.  This happens when
    either the input doesn't contain .reginfo section or when this section
    is oversized.  This patch replaces the assertion with a more useful
    error message.
    
    	* elfxx-mips.c (_bfd_mips_elf_final_link): Notify user when
    	.reginfo section has wrong size.

commit 97a232d7335f3bd0231fd9cd39455bde1d563922
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Jan 12 08:15:55 2018 +0000

    Add -z undefs option to the ELF linker.
    
      Currently we have no obvious way to revert the action of the "-z defs"
      command line option.  The "--unresolved-symbols=ignore-in-object-files"
      does pretty much what is needed, but it is non-obvious and it also
      touches the setting for reporting unresolved symbol references from
      shared libraries.  So I am proposing adding a "-z undefs" option to be
      the inverse of "-z defs".  (I thought that "-z nodefs" might be
      confusing since it implies banning all definitions, rather than
      allowing them).
    
      In addition the description of the "-z defs" option in the linker
      documentation is misleading in one place, where it says:
    
        'defs'
           Disallows undefined symbols in object files.  Undefined
           symbols in shared libraries are still allowed.
    
      whereas later on it gets it right:
    
        '-z defs'
           Report unresolved symbol references from regular object files.
           This is done even if the linker is creating a non-symbolic shared
           library.  The switch '--[no-]allow-shlib-undefined' controls the
           behaviour for reporting unresolved references found in shared
           libraries being linked in.
    
    	* emultempl/elf32.em (_handle_option): Add support for "-z undefs"
    	as the opposite of "-z defs".
    	* ld.texinfo: Document the new option.  Update the description of
    	the -z defs option to make it clear that it does generate an error
    	if an undefined symbol reference is found in an object file whilst
    	creating a shared library.
    	* NEWS: Document this new feature.

commit 33eff4ce18fbee82ef39838b7c8623aed17dea60
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 20:46:01 2018 -0800

    ld: Replace "-z textonly" with "-z separate-code"
    
    Although they aren't passed to linker, we should get it right.
    
    	* testsuite/ld-elf/pr22393-2a.rd: Replace "-z textonly" with
    	"-z separate-code".
    	* testsuite/ld-elf/pr22393-2b.rd: Likewise.
    	* testsuite/ld-x86-64/pr22393-3a.rd: Likewise.
    	* testsuite/ld-x86-64/pr22393-3b.rd: Likewise.

commit cf9e7f1f07efa2ce6846d8a29015dd8fb70197b0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 19:19:22 2018 -0800

    x86-64: Add tests for -z separate-code -z max-page-size=0x1000
    
    	PR ld/22393
    	* testsuite/ld-x86-64/pr22393-3a.c: New file.
    	* testsuite/ld-x86-64/pr22393-3a.rd: Likewise.
    	* testsuite/ld-x86-64/pr22393-3b.c: Likewise.
    	* testsuite/ld-x86-64/pr22393-3b.rd: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run tests for -z separate-code
    	-z max-page-size=0x1000.

commit d346bb277c7f194ece73a7200d1ed6417b1194e5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 19:17:46 2018 -0800

    ld: Add tests for -z separate-code and -z noseparate-code
    
    Verify that -z separate-code works and -z noseparate-code doesn't disable
    -z relro.
    
    	PR ld/22393
    	* testsuite/ld-elf/pr16322.d: Add -z noseparate-code.
    	* testsuite/ld-elf/pr22393-1.s: New file.
    	* testsuite/ld-elf/pr22393-1a.d: Likewise.
    	* testsuite/ld-elf/pr22393-1b.d: Likewise.
    	* testsuite/ld-elf/pr22393-1c.d: Likewise.
    	* testsuite/ld-elf/pr22393-1d.d: Likewise.
    	* testsuite/ld-elf/pr22393-1e.d: Likewise.
    	* testsuite/ld-elf/pr22393-1f.d: Likewise.
    	* testsuite/ld-elf/pr22393-2a.c: Likewise.
    	* testsuite/ld-elf/pr22393-2a.rd: Likewise.
    	* testsuite/ld-elf/pr22393-2b.c: Likewise.
    	* testsuite/ld-elf/pr22393-2b.rd: Likewise.
    	* testsuite/ld-elf/shared.exp: Run tests for -z separate-code.

commit 2888249fc9eb38b6d6e4bd969ce63c26e3753d5e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 19:04:55 2018 -0800

    ld: Create a new LOAD segment for separate code segment
    
    When generating separate code LOAD segment, create a new LOAD segment
    if the previous section contains text and the current section doesn't
    or vice versa:
    
    Elf file type is DYN (Shared object file)
    Entry point 0x200020
    There are 7 program headers, starting at offset 52
    
    Program Headers:
      Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
      LOAD           0x000000 0x00000000 0x00000000 0x00200 0x00200 R   0x200000
      LOAD           0x200000 0x00200000 0x00200000 0x00036 0x00036 R E 0x200000
      LOAD           0x400000 0x00400000 0x00400000 0x00064 0x00064 R   0x200000
      LOAD           0x400f80 0x00600f80 0x00600f80 0x000a0 0x000a0 RW  0x200000
      DYNAMIC        0x400f80 0x00600f80 0x00600f80 0x00080 0x00080 RW  0x4
      GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RW  0x10
      GNU_RELRO      0x400f80 0x00600f80 0x00600f80 0x00080 0x00080 R   0x1
    
     Section to Segment mapping:
      Segment Sections...
       00     .hash .gnu.hash .dynsym .dynstr .rela.plt
       01     .plt .text
       02     .rodata .eh_frame
       03     .dynamic .got.plt
       04     .dynamic
       05
       06     .dynamic
    
    to prevent fetching or executing data in code pages as instructions.
    
    Also don't put a writable section in a read-only segment if there is a
    RELRO segment.
    
    Since code segment is aligned and padded to the maximum page size on
    disk, the minimum file size is bigger than the maximum page size which
    is 2MB (0x200000):
    
    -rwxr-xr-x 1 hjl hjl 4201932 Jan 10 10:41 libfoo.so
    
    "-z max-page-size=0x1000" can be used to reduce the maximum page size to
    4KB (0x1000):
    
    -rwxr-xr-x 1 hjl hjl   15820 Jan 10 10:44 libfoo.so
    
    	PR ld/22393
    	* elf.c (_bfd_elf_map_sections_to_segments): When generating
    	separate code and read-only data LOAD segments, create a new
    	LOAD segment if the previous section contains text and the
    	current section doesn't or vice versa.  Don't put a writable
    	section in a read-only segment if there is a RELRO segment.

commit 47acac12c83f173481debc64618626b50ecf7498
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 19:01:39 2018 -0800

    ld: Add "-z separate-code" option to ELF linker
    
    The new "-z separate-code" option will generate separate code LOAD
    segment which must be in wholly disjoint pages from any other data.
    
    include/
    
    	PR ld/22393
    	* bfdlink.h (bfd_link_info): Add separate_code.
    
    ld/
    
    	PR ld/22393
    	* NEWS: Mention "-z separate-code".
    	* emultempl/elf32.em (gld${EMULATION_NAME}_get_script): Get
    	builtin linker scripts and return linker scripts from disk for
    	"-z separate-code".
    	(gld${EMULATION_NAME}_handle_option): Handle "-z separate-code"
    	and "-z noseparate-code".
    	* genscripts.sh: Generate linker scripts for "-z separate-code".
    	(LD_FLAG): Set to *textonly for "-z separate-code".
    	* ld.texinfo: Document "-z separate-code".
    	* lexsup.c (elf_shlib_list_options): Add linker help messsages
    	for "-z separate-code" and "-z noseparate-code".
    	* scripttempl/elf.sc (SEPARATE_TEXT): New
    	(TEXT_SEGMENT_ALIGN): Likewise.
    	Use ${TEXT_SEGMENT_ALIGN} to align and pad text segment to
    	${MAXPAGESIZE}.

commit 6181e9c2c5ba252ac016f51903dc35d7bfbbca71
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Jan 11 21:08:23 2018 -0500

    gdb_compile_shlib: Only consider shlib= options when building executables
    
    Trying to use gdb_compile_shlib with the shlib= option to build a shared
    library that depends on another shared library does not work as of
    today.  See:
    
      https://sourceware.org/ml/gdb-patches/2017-10/msg00733.html
    
    The problem is that building the lib is done in two steps, compilation
    (.c -> .o) and linking (.o -> .so) and the shlib= options are passed to
    both steps.  When compiling the object file (.o), it results in gcc
    complaining:
    
      gcc: warning: .../solib-vanish-lib2.so: linker input file unused because linking not done
    
    The first solution I came up with was to filter the options inside
    gdb_compile_shlib to remove the shlib= options from the options we pass
    when compiling the .o file.
    
    I then thought it would be simpler to ignore the shlib= options in
    gdb_compile when not building an executable (the executable category
    includes the shared libraries).  For other compilation types (object
    file, preprocess and generate assembly), it doesn't make sense to add
    shared libraries to the source file list.
    
    Regtested on the buildbot.
    
    gdb/testsuite/ChangeLog:
    
    	* lib/gdb.exp (gdb_compile): Ignore shlib= and shlib_load
    	options when not creating an executable.

commit 89a7f793f1963b14bd649afc4154903d22591ae0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jan 12 00:00:23 2018 +0000

    Automatic date update in version.in

commit d664fd41e15f058aab41b70c567ad09f2fab1115
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 15:36:40 2018 -0800

    Ignore dynamic references on forced local symbols
    
    We should ignore dynamic references on forced local symbols during
    garbage collection since they can never be referenced dynamically.
    
    bfd/
    
    	PR ld/22649
    	* elflink.c (bfd_elf_gc_mark_dynamic_ref_symbol): Ignore dynamic
    	references on forced local symbols.
    
    ld/
    
    	PR ld/22649
    	* testsuite/ld-elf/pr22649-1.s: New file.
    	* testsuite/ld-elf/pr22649-2a.s: Likewise.
    	* testsuite/ld-elf/pr22649-2b.s: Likewise.
    	* testsuite/ld-elf/pr22649.msg: Likewise.
    	* testsuite/ld-elf/shared.exp: Run ld/22649 tests.

commit 71d378ae60a4f072ce392046878d471255f6c8a1
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jan 11 17:50:31 2018 +0000

    gdb.base/breakpoint-in-ro-region.exp regression on sss targets (PR gdb/22583)
    
    As Maciej reported at
    <https://sourceware.org/ml/gdb-patches/2017-12/msg00212.html>, this
    commit:
    
     commit d930703d68ae160ddfe8ebe5fdcf416fb6090e1e
     Date: Thu Nov 16 18:44:43 2017 +0000
     Subject: Don't ever Quit out of resume
    
    caused regressions on software single-set targets, specifically:
    
     FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw off: single-step breakpoint is not left behind
     FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw on: single-step breakpoint is not left behind
     FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted on: auto-hw off: step in ro region (cannot insert hw break)
     FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted on: auto-hw off: single-step breakpoint is not left behind
     FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted on: auto-hw on: single-step breakpoint is not left behind
    
    and indeed detailed logs indicate a breakpoint is left lingering, e.g.:
    
     (gdb) PASS: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw off: step in ro region (cannot insert sw break)
     maint info breakpoints 0
     Num     Type           Disp Enb Address    What
     0       sw single-step keep y   0x00400774 in main at [...]/gdb/testsuite/gdb.base/breakpoint-in-ro-region.c:24 inf 1 thread 1
    	 stop only in thread 1
     (gdb) FAIL: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw off: single-step breakpoint is not left behind
    
    vs:
    
     (gdb) PASS: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw off: step in ro region (cannot insert sw break)
     maint info breakpoints 0
     No breakpoint or watchpoint matching '0'.
     (gdb) PASS: gdb.base/breakpoint-in-ro-region.exp: always-inserted off: auto-hw off: single-step breakpoint is not left behind
    
    as at commit d930703d68ae^.
    
    Before commit d930703d68ae, we had a cleanup installed in 'resume'
    that would delete single-step breakpoints on error:
    
      /* Resuming.  */
    
      /* Things to clean up if we QUIT out of resume ().  */
      static void
      resume_cleanups (void *ignore)
      {
        if (!ptid_equal (inferior_ptid, null_ptid))
         delete_single_step_breakpoints (inferior_thread ());
    
        normal_stop ();
      }
    
    That whole function was removed by d930703d68ae mainly to eliminate
    the normal_stop call:
    
    ~~~~
        Note that the exception called from within resume ends up calling
        normal_stop via resume_cleanups.  That's very borked though, because
        normal_stop is going to re-handle whatever was the last reported
        event, possibly even re-running a hook stop...
    ~~~~
    
    But as the regression shows, removing resume_cleanups completely went
    a bit too far, as the delete_single_step_breakpoints call is still
    necessary.
    
    So fix the regression by reinstating the
    delete_single_step_breakpoints call on error.  However, since we're
    trying to eliminate cleanups, restore it in a different form (using
    TRY/CATCH).
    
    Tested on x86-64 GNU/Linux both top of master and on top of a series
    that implements software single-step on x86.
    
    gdb/ChangeLog:
    2018-01-11  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22583
    	* infrun.c (resume): Rename to ...
    	(resume_1): ... this.
    	(resume): Reimplement as wrapper around resume_1.

commit 8b6f4cd34fdde524ea035c65f7d48aaa3fb449b5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 09:42:12 2018 -0800

    ld: Keep PREINIT_ARRAY/INIT_ARRAY/FINI_ARRAY sections for -r --gc-sections
    
    We must keep all PREINIT_ARRAY, INIT_ARRAY as well as FINI_ARRAY sections
    for ld -r --gc-sections.
    
    bfd/
    
    	PR ld/22677
    	* elflink.c (bfd_elf_gc_sections): Keep all PREINIT_ARRAY,
    	INIT_ARRAY as well as FINI_ARRAY sections for ld -r --gc-sections.
    
    ld/
    
    	PR ld/22677
    	* scripttempl/elf.sc (PREINIT_ARRAY): New.
    	Don't add .preinit_array for ld -r.
    	* testsuite/ld-elf/pr22677.d: New file.
    	* testsuite/ld-elf/pr22677.s: Likewise.

commit 65f14869fd3fbee8ed4c4ca49de8aaa86dbc66cb
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Fri Jan 5 14:59:05 2018 +0000

    ld: Remove unused expression state
    
    Previous commit removed all uses of the defsym field within the linker
    expression union.  This commit cleans up the now redundant state.
    
    ld/ChangeLog:
    
    	* ldexp.h (union etree_union): Remove defsym field.
    	* ldexp.c (exp_assop): Remove defsym parameter, and use of defsym
    	parameter.
    	(exp_assign): Remove passing of defsym parameter.
    	(exp_defsym): Likewise.
    	(exp_provide): Likewise.

commit eab62f2f018417121e2520acb0623985b1708b02
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Thu Apr 27 18:05:08 2017 +0100

    ld: Fix issue where PROVIDE overrides defined symbol
    
    In a linker script, a sequence like this:
    
      foo = ADDR (.some_section);
      bar = foo;
      PROVIDE (foo = 0);
    
    will result in 'bar = ADDR (.some_section)' and 'foo = 0', which seems
    like incorrect behaviour, foo is clearly defined elsewhere, and so the
    PROVIDE should not trigger.
    
    The problem is that an expression like this:
    
        foo = ADDR (.some_section);
    
    can't be evaluated until a late phase of the linker, due to the need
    for the section '.some_section' to have been placed, then the PROVIDE
    was being marked as being used during an earlier phase.  At the end of
    the link, both lines:
    
        foo = ADDR (.some_section);
        PROVIDE (foo = 0);
    
    are active, and this causes the final value of 'foo' to be 0.
    
    The solution proposed in this commit is that, during earlier phases of
    the linker, when we see the expression 'foo = ADDR (.some_section);',
    instead of ignoring the expression, we create a "fake" definition of
    'foo'.  The existence of this "fake" definition prevents the PROVIDE
    from being marked used, and during the final phase the real definition
    of 'foo' will replace the "fake" definition.
    
    The new test provide-6 covers the exact case described above.  The
    provide-7 test is similar to the above, but using constant
    expressions, this was never broken, but is added here to increase
    coverage.
    
    The provide-8 case also didn't fail before this commit, but I did
    manage to break this case during development of this patch.  This case
    was only covered by a mmix test before, so I've added this here to
    increase coverage.
    
    ld/ChangeLog:
    
    	* ldexp.c (exp_fold_tree_1): Rework condition underwhich provide
    	nodes are ignored in the tree walk, and move the location at which
    	we change provide nodes into provided nodes.
    	(exp_init_os): Add etree_provided.
    	* testsuite/ld-scripts/provide-6.d: New file.
    	* testsuite/ld-scripts/provide-6.t: New file.
    	* testsuite/ld-scripts/provide-7.d: New file.
    	* testsuite/ld-scripts/provide-7.t: New file.
    	* testsuite/ld-scripts/provide-8.d: New file.
    	* testsuite/ld-scripts/provide-8.t: New file.

commit 8be965c5f058f79554ec3376afac994e6e3ad1b7
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Thu Apr 27 17:53:28 2017 +0100

    ld: Find and run some tests using a wildcard pattern
    
    Find the ld-script/provide-*.d tests using a wildcard, then run them in
    a loop.  This will make it easier to add more tests in the future.  Some
    associated clean up is required.
    
    ld/ChangeLog:
    
    	* testsuite/ld-scripts/provide-3.d: Add xfail directive.
    	* testsuite/ld-scripts/provide-4.d: Use new map file name.
    	* testsuite/ld-scripts/provide-5.d: Use new map file name.
    	* testsuite/ld-scripts/provide-4-map.d: Renamed to...
    	* testsuite/ld-scripts/provide-4.map: ...this.
    	* testsuite/ld-scripts/provide-5-map.d: Renamed to...
    	* testsuite/ld-scripts/provide-5.map: ...this.
    	* testsuite/ld-scripts/provide.exp: Move xfail into provide-3.d
    	file, and run tests in a loop.

commit b3b9f8d3e99cf46c2f85445cc5189db4c4f47407
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Fri Jan 5 22:41:55 2018 +0000

    ld: In map file use '=' in PROVIDE statements
    
    Currently when recording a PROVIDE statement in a linker map file we
    display something like:
    
        PROVIDE (SYMBOL, VALUE)
    
    However, in a linker script we write these statements like this:
    
        PROVIDE (SYMBOL = VALUE);
    
    This commit changes the output in the map file to be closer to linker
    script format, the map file now contains:
    
        PROVIDE (SYMBOL = VALUE)
    
    The ';' is still missing from the end, but map files are not intended
    to be valid linker script input, so adding the ';' just seems like
    clutter.
    
    ld/ChangeLog:
    
    	* ldexp.c (exp_print_tree): Use '=' instead of ',' when printing
    	PROVIDE statements.
    	* testsuite/ld-scripts/provide-4.map: Update expected output.
    	* testsuite/ld-scripts/provide-5.map: Likewise.

commit 6bd0a312a4cb6803b9d6aa2f5646b610d213a1fe
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jan 11 05:05:25 2018 -0800

    Fix the order of SHLIB_RODATA_ADDR in elf.sc
    
    elf.sc has
    
      if test -n "${RODATA_ADDR}"; then
        RODATA_ADDR="\
    SEGMENT_START(\"rodata-segment\", ${RODATA_ADDR}) + SIZEOF_HEADERS"
      else
        RODATA_ADDR="ALIGN(${SEGMENT_SIZE}) + (. & (${MAXPAGESIZE} - 1))"
        ^^^^^^^^^^ Set RODATA_ADDR
        RODATA_ADDR="SEGMENT_START(\"rodata-segment\", ${RODATA_ADDR})"
        ^^^^^^^^^^ Set RODATA_ADDR with ${RODATA_ADDR}
      fi
      if test -n "${SHLIB_RODATA_ADDR}"; then
        SHLIB_RODATA_ADDR="\
    SEGMENT_START(\"rodata-segment\", ${SHLIB_RODATA_ADDR}) + SIZEOF_HEADERS"
      else
        SHLIB_RODATA_ADDR="SEGMENT_START(\"rodata-segment\", ${SHLIB_RODATA_ADDR})"
        ^^^^^^^^^^ Set SHLIB_RODATA_ADDR
        SHLIB_RODATA_ADDR="ALIGN(${SEGMENT_SIZE}) + (. & (${MAXPAGESIZE} - 1))"
        ^^^^^^^^^^ Override SHLIB_RODATA_ADDR
      fi
    
    The order should be:
    
      if test -n "${SHLIB_RODATA_ADDR}"; then
        SHLIB_RODATA_ADDR="\
    SEGMENT_START(\"rodata-segment\", ${SHLIB_RODATA_ADDR}) + SIZEOF_HEADERS"
      else
        SHLIB_RODATA_ADDR="ALIGN(${SEGMENT_SIZE}) + (. & (${MAXPAGESIZE} - 1))"
        SHLIB_RODATA_ADDR="SEGMENT_START(\"rodata-segment\", ${SHLIB_RODATA_ADDR})"
      fi
    
    	PR ld/22696
    	* scripttempl/elf.sc: Fix the order of SHLIB_RODATA_ADDR.

commit 754452f07e701448e5d9bd004cb108ddc48a8d67
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Thu Jan 11 12:13:39 2018 +0000

    Fix gdb.texinfo for old makeinfo
    
    With old makeinfo (version 4.13) the changes introduced in
    
    commit 2d97a5d9d33aea87c3bd02fd1fa417f5d4e1fa05
    Author:     John Baldwin <jhb@FreeBSD.org>
    
        Document support for 'info proc' on FreeBSD.
    
    fail to build.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (pwd): Fix whitespace.

commit 3cada74087687907311b52781354ff551e10a0ed
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jan 11 00:23:04 2018 +0000

    Fix backwards compatibility with old GDBservers (PR remote/22597)
    
    At <https://sourceware.org/ml/gdb-patches/2017-12/msg00285.html>,
    Maciej reported that commit:
    
      commit 5cd63fda035d4ba949e6478406162c4673b3c9ef
      Date: Wed Oct 4 18:21:10 2017 +0100
      Subject: Fix "Remote 'g' packet reply is too long" problems with multiple inferiors
    
    made GDB stop working with older stubs.  Any attempt to continue
    execution after the initial connection fails with:
    
      [...]
      Process .../gdb/testsuite/outputs/gdb.base/advance/advance created; pid = 2670
      Listening on port 2346
      target remote [...]:2346
      Remote debugging using [...]:2346
      Reading symbols from .../lib64/ld.so.1...done.
      [Switching to Thread <main>]
      (gdb) continue
      Cannot execute this command without a live selected thread.
      (gdb)
    
    The problem is:
    
      (gdb) c
      Cannot execute this command without a live selected thread.
      (gdb) info threads
        Id   Target Id         Frame
        1    Thread 14917      0x00007f341cd98ed0 in _start () from /lib64/ld-linux-x86-64.so.2
    
      The current thread <Thread ID 2> has terminated.  See `help thread'.
    		      ^^^^^^^^^^^
      (gdb)
    
    Note, thread _2_.  There's really only one thread in the inferior
    (it's still at the entry point), but still GDB added a bogus second
    thread.
    
    The reason GDB started adding a second thread after 5cd63fda035d is
    this hunk:
    
    +                 if (event->ptid == null_ptid)
    +                   {
    +                     const char *thr = strstr (p1 + 1, ";thread:");
    +                     if (thr != NULL)
    +                       event->ptid = read_ptid (thr + strlen (";thread:"),
    +                                                NULL);
    +                     else
    +                       event->ptid = magic_null_ptid;
    +                   }
    
    Note the else branch that falls back to magic_null_ptid.  We reach
    that when we process the initial stop reply sent back in response to
    the the "?" (status) packet early in the connection setup:
    
     Sending packet: $?#3f...Ack
     Packet received: T0506:0000000000000000;07:40a510f4fd7f0000;10:d0fe1201577f0000;
    
    And note that that response does not include a ";thread:XXX" part.
    
    This stop reply is processed after listing threads with qfThreadInfo /
    qsThreadInfo :
    
     Sending packet: $qfThreadInfo#bb...Ack
     Packet received: m3915
     Sending packet: $qsThreadInfo#c8...Ack
     Packet received: l
    
    meaning, when we process that stop reply, we treat the event as coming
    from a thread with ptid == magic_null_ptid, which is not yet in the
    thread list, so we add it then:
    
      (top-gdb) p ptid
      $1 = {m_pid = 42000, m_lwp = -1, m_tid = 1}
      (top-gdb) bt
      #0  0x0000000000840a8c in add_thread_silent(ptid_t) (ptid=...) at src/gdb/thread.c:269
      #1  0x00000000007ad61d in remote_add_thread(ptid_t, int, int) (ptid=..., running=0, executing=0)
          at src/gdb/remote.c:1838
      #2  0x00000000007ad8de in remote_notice_new_inferior(ptid_t, int) (currthread=..., executing=0)
          at src/gdb/remote.c:1921
      #3  0x00000000007b758b in process_stop_reply(stop_reply*, target_waitstatus*) (stop_reply=0x1158860, status=0x7fffffffcc00)
          at src/gdb/remote.c:7217
      #4  0x00000000007b7a38 in remote_wait_as(ptid_t, target_waitstatus*, int) (ptid=..., status=0x7fffffffcc00, options=0)
          at src/gdb/remote.c:7380
      #5  0x00000000007b7cd1 in remote_wait(target_ops*, ptid_t, target_waitstatus*, int) (ops=0x102fac0 <remote_ops>, ptid=..., status=0x7fffffffcc00, options=0) at src/gdb/remote.c:7446
      #6  0x000000000081587b in delegate_wait(target_ops*, ptid_t, target_waitstatus*, int) (self=0x102fac0 <remote_ops>, arg1=..., arg2=0x7fffffffcc00, arg3=0) at src/gdb/target-delegates.c:138
      #7  0x0000000000827d77 in target_wait(ptid_t, target_waitstatus*, int) (ptid=..., status=0x7fffffffcc00, options=0)
          at src/gdb/target.c:2179
      #8  0x0000000000715fda in do_target_wait(ptid_t, target_waitstatus*, int) (ptid=..., status=0x7fffffffcc00, options=0)
          at src/gdb/infrun.c:3589
      #9  0x0000000000716351 in wait_for_inferior() () at src/gdb/infrun.c:3707
      #10 0x0000000000715435 in start_remote(int) (from_tty=1) at src/gdb/infrun.c:3212
    
    things go downhill from this.
    
    We don't see the problem with current master gdbserver, because that
    version always sends the ";thread:" part in the initial stop reply:
    
     Sending packet: $?#3f...Packet received: T0506:0000000000000000;07:a0d4ffffff7f0000;10:d05eddf7ff7f0000;thread:p3cea.3cea;core:3;
    
    Years ago I had added a "--disable-packet=" command line option to
    gdbserver which comes in handy for testing this, since the existing
    "--disable-packet=Tthread" precisely makes gdbserver not send that
    ";thread:" part in stop replies.  The testcase added by this commit
    emulates old gdbserver making use of that.
    
    I've compared a testrun at 5cd63fda035d^ (before regression) with
    'current master+patch', against old gdbserver at f8b73d13b7ca^.  I
    hacked out --once, and "monitor exit" to be able to test.  The results
    are a bit too unstable to tell accurately, but it looked like there
    were no regressions.  Maciej confirmed this worked for him as well.
    
    No regressions on master (against master gdbserver).
    
    gdb/ChangeLog:
    2018-01-11  Pedro Alves  <palves@redhat.com>
    
    	PR remote/22597
    	* remote.c (remote_parse_stop_reply): Default to the last-set
    	general thread instead of to 'magic_null_ptid'.
    
    gdb/testsuite/ChangeLog:
    2018-01-11  Pedro Alves  <palves@redhat.com>
    
    	PR remote/22597
    	* gdb.server/stop-reply-no-thread.c: New file.
    	* gdb.server/stop-reply-no-thread.exp: New file.

commit 888a89da7fa5d219695234c3a8dc7b8a57dfe8ee
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Thu Jan 11 02:56:45 2018 +0300

    Remove VL variants for 4FMAPS and 4VNNIW insns.
    
    AVX512_4FMAPS and AVX512_4VNNIW insns are marked as having AVX512VL
    variants.  That is wrong as SDM doesn't define such instructions. The
    patch removes these VL variants.
    
    gas/
    	* testsuite/gas/i386/avx512_4fmaps-warn.l: Change xmm to zmm.
    	* testsuite/gas/i386/avx512_4fmaps-warn.s: Likewise.
    	* testsuite/gas/i386/avx512_4fmaps_vl-intel.d: Delete.
    	* testsuite/gas/i386/avx512_4fmaps_vl-warn.l: Likewise.
    	* testsuite/gas/i386/avx512_4fmaps_vl-warn.s: Likewise.
    	* testsuite/gas/i386/avx512_4fmaps_vl.d: Likewise.
    	* testsuite/gas/i386/avx512_4fmaps_vl.s: Likewise.
    	* testsuite/gas/i386/avx512_4vnniw_vl-intel.d: Likewise.
    	* testsuite/gas/i386/avx512_4vnniw_vl.d: Likewise.
    	* testsuite/gas/i386/avx512_4vnniw_vl.s: Likewise.
    	* testsuite/gas/i386/i386.exp: Delete _vl tests for 4fmaps an
    	4vnniw tests.
    	* testsuite/gas/i386/x86-64-avx512_4fmaps_vl-intel.d: Delete.
    	* testsuite/gas/i386/x86-64-avx512_4fmaps_vl-warn.l: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4fmaps_vl-warn.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4fmaps_vl.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4fmaps_vl.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4vnniw_vl-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4vnniw_vl.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512_4vnniw_vl.s: Likewise.
    
    opcodes/
    	* i386-opc.tbl: Remove VL variants for 4FMAPS and 4VNNIW
    	insns.
    	* i386-tbl.h: Regenerate.

commit 710d7eae846428d25dcfc6f51e8722fc65bd26ee
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jan 11 00:00:23 2018 +0000

    Automatic date update in version.in

commit b90d5ba0b6e068db21650ad42ec9dea22426df00
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Jan 11 09:34:58 2018 +1030

    gas tc-arm.c warning fix
    
    	* config/tc-arm.c (aeabi_set_public_attributes): Avoid false
    	positive "â??profileâ?? may be used uninitialized".

commit 618daa933cdce21424d3759ea95a4e2f5c69a1c2
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Jan 10 20:38:08 2018 +0000

    language_get_symbol_name_matcher -> get_symbol_name_matcher
    
    Rename language_get_symbol_name_matcher -> get_symbol_name_matcher,
    since the function is no longer a straight "language method".
    
    gdb/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
    	* language.h (language_get_symbol_name_matcher): Rename ...
    	(get_symbol_name_matcher): ... this.
    	* language.c (language_get_symbol_name_matcher): Ditto.
    	* dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
    	callers adjusted.

commit c63d3e8d12f0b08cda95f89aa13274defed215f0
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Jan 10 20:38:07 2018 +0000

    Ada: make verbatim matcher override other language matchers (PR gdb/22670)
    
    A previous patch fixed verbatim matching in the lookup at the minimal
    symbol level, but we should also be finding that same symbol through
    the partial/full symtab search.
    
    For example, this is what happens if we use "print" instead of
    "break":
    
        (gdb) p <MixedCaseFunc>
        $1 = {<text variable, no debug info>} 0x4024dc <MixedCaseFunc>
    
    Before the C++ wildmatching series, GDB knows that MixedCaseFunc is a
    function without parameters, and the expression above means calling
    it.  If you try it before having started the inferior, you'd get the
    following (expected) error:
    
        (gdb) print  <MixedCaseFunc>
        You can't do that without a process to debug.
    
    The main idea behind making the name matcher be determined by the
    symbol's language is so that C++ (etc.) wildmatching in linespecs
    works even if the current language is not C++, as e.g., when you step
    through C or assembly code.
    
    Ada's verbatim matching syntax however ("<...>") isn't quite the same.
    It is more a property of the current language than of a particular
    symbol's language.  We want to support this syntax when debugging an
    Ada program, but it's reason of existence is to find non-Ada symbols.
    This suggests going back to enabling it depending on current language
    instead of language of the symbol being matched.
    
    I'm not entirely happy with the "current_language" reference (though I
    think that it's harmless).  I think we could try storing the current
    language in the lookup_name_info object, and then convert a bunch of
    functions more to pass around lookup_name_info objects instead of
    "const char *" names.  I.e., build the lookup_name_info higher up.
    I'm not sure about that, I'll have to think more about it.  Maybe
    something different will be better.  Meanwhile, this gets us going.
    
    I've extended the testcase to also exercise a no-debug-info function,
    for extra coverage of the minsyms-only paths.
    
    gdb/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* dwarf2read.c
    	(gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
    	Adjust to use language_get_symbol_name_matcher instead of
    	language_defn::la_get_symbol_name_matcher.
    	* language.c (language_get_symbol_name_matcher): If in Ada mode
    	and the lookup name is a verbatim match, return Ada's matcher.
    	* language.h (language_get_symbol_name_matcher): Adjust comment.
    	(ada_lookup_name_info::verbatim_p):: New method.
    
    gdb/testsuite/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* gdb.ada/bp_c_mixed_case.exp: Add intro comment.  Test printing C
    	functions too.  Test setting breakpoints and printing C functions
    	with no debug info too.
    	* gdb.ada/bp_c_mixed_case/qux.c: New file.

commit d4c2a405cb7535d25b88e9b8dad0e557242950ca
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Jan 10 20:38:07 2018 +0000

    Fix gdb.ada/complete.exp's "complete break ada" test (PR gdb/22670)
    
    This patch fixes the regression covered by the test added by:
    
        commit 344420da6beac1e0b2f7964e7101f8dcdb509b0d
        Date: Thu Jan 4 03:30:37 2018 -0500
        Subject: Add "complete break ada" test to gdb.ada/complete.exp
    
    The regression had been introduced by:
    
        commit b5ec771e60c1a0863e51eb491c85c674097e9e13
        Date:   Wed Nov 8 14:22:32 2017 +0000
        Subject: Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    The gist of it is that linespec completion in Ada mode is generating
    additional matches that should not appear in the match list
    (internally generated symbols, or symbols that should be enclosed
    between "<...>").  These extraneous entries have uppercase characters, such as:
    
        break ada__stringsS
        break ada__strings__R11s
        [etc]
    
    These matches come from minimal symbols.  The problem is that Ada
    minsyms end up with no language set (language_auto), and thus we end
    up using the generic symbol name matcher for those instead of Ada's.
    We already had a special case for in compare_symbol_name to handle
    this, but it was limited to expressions, while the case at hand is
    completing a linespec.  Fix this by applying the special case to
    linespec completion as well.  I.e., remove the EXPRESSION check from
    compare_symbol_name.  That alone turns out to not be sufficient still
    -- GDB would still show a couple entries that shouldn't be there:
    
    ~~
        break ada__exceptions__exception_data__append_info_exception_name__2Xn
        break ada__exceptions__exception_data__exception_name_length__2Xn
    ~~
    
    The reason is that these minimal symbols end up with their language
    set to language_cplus / C++, because those encoded names manage to
    demangle successfully as C++ symbols (using an old C++ mangling
    scheme):
    
      $ echo ada__exceptions__exception_data__append_info_exception_name__2Xn | c++filt
      Xn::ada__exceptions__exception_data__append_info_exception_name(void)
    
    It's unfortunate that Ada's encoding scheme doesn't start with some
    unique prefix like "_Z" in the C++ Itanium ABI mangling scheme.  For
    now, paper over that by treating C++ minsyms as Ada minsyms.
    
    gdb/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
            PR gdb/22670
    	* ada-lang.c (ada_collect_symbol_completion_matches): If the
    	minsym's language is language_auto or language_cplus, pass down
    	language_ada instead.
    	* symtab.c (compare_symbol_name): Don't frob symbol language here.
    
    gdb/testsuite/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
            PR gdb/22670
    	* gdb.ada/complete.exp ("complete break ada"): Replace kfail with
    	a fail.

commit 8825213e97f0476068dc3b52b1b61df96b40708a
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Jan 10 20:38:06 2018 +0000

    Fix gdb.ada/bp_c_mixed_case.exp (PR gdb/22670)
    
    The problem here is that we are using the user-provided lookup name
    literally for name comparisons.  I.e., "<MixedCase>" with the "<>"s
    included.
    
    This commit fixes the minsym lookup case.  psymbol/symbol lookup will
    be fixed in a follow up.
    
    In the minsym case, we're using using the user-provided lookup name
    literally for linkage name comparisons.  That obviously can't work
    since the "<>" are not really part of the linkage name.
    
    The original idea was that we'd use the symbol's language to select
    the right symbol name matching algorithm, but that doesn't work for
    Ada because it's not really possible to unambiguously tell from the
    linkage name alone whether we're dealing with Ada symbols, so Ada
    minsyms end up with no language set, or sometimes C++ set.
    
    So fix this by treating Ada mode specially when determining the
    linkage name to match against.
    
    gdb/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* minsyms.c (linkage_name_str): New function.
    	(iterate_over_minimal_symbols): Use it.
    
    gdb/testsuite/ChangeLog:
    2018-01-10  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* gdb.ada/bp_c_mixed_case.exp: Remove setup_kfail calls.

commit 7ec0cd50bf2c93854ef02b9c1f3b4edc4b70cd46
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jan 10 15:35:34 2018 +0000

    oops - updates to ChangeLog omitted by accident from previous delta.

commit bf41f30dde0f2ad09c2b7a9894fd7992e4b36a16
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jan 10 15:29:21 2018 +0000

    Update top level configure files by synchronizing them with gcc.
    
    .	* config-ml.in: Sync with gcc sources.
    	* config.guess: Likewise.
    	* config.sub: Likewise.
    	* configure.ac: Likewise.
    	* configure: Regenerate.
    
    config	* Sync with GCC sources:
    
    	2017-11-14 Boris Kolpackov  <boris@codesynthesis.com>
    
    	* gcc-plugin.m4: Add support for MinGW.
    
    	2017-11-17  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
    
    	* cet.m4: New file.
    
    	2017-11-15  Alexandre Oliva <aoliva@redhat.com>
    
    	* bootstrap-debug-lean.mk (do-compare): Use the
    	contrib/compare-debug script.
    
    	2017-10-24  H.J. Lu  <hongjiu.lu@intel.com>
    
    	* bootstrap-cet.mk: New file.
    
    	2017-06-19  Martin Liska  <mliska@suse.cz>
    
    	* bootstrap-lto-noplugin.mk: Enable -flto in all PGO stages.
    	* bootstrap-lto.mk: Likewise.
    
    	2017-06-03  Eric Botcazou  <ebotcazou@adacore.com>
    
    	* mt-android: New file.
    
    	2017-02-13  Richard Biener  <rguenther@suse.de>
    
    	* isl.m4: Remove support for ISL 0.14.
    
    	2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
    
    	PR target/78478
    	* ax_check_define.m4: New file.
    
    	2017-01-17  Jakub Jelinek  <jakub@redhat.com>
    
    	PR other/79046
    	* acx.m4 (GCC_BASE_VER): New m4 function.
    	(ACX_TOOL_DIRS): Require GCC_BASE_VER, for
    	--with-gcc-major-version-only use just major number from BASE-VER.
    
    	2017-01-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
    
    	PR go/78978
    	* hwcaps.m4 (GCC_CHECK_ASSEMBLER_HWCAP): New macro.

commit 2a8ae7146cacb006105e2e9c6f4635aca543e7ec
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jan 10 13:57:48 2018 +0000

    Update the libiberty sources with the latest patches found in the master sources.
    
    2017-01-02  Richard Biener  <rguenther@suse.de>
    
    	PR lto/83452
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_section):
    	Do not use UNDEF locals for removed symbols but instead just
    	define them in the first prevailing section and with no name.
    	Use the same gnu_lto_v1 name for all removed globals we promote to
    	WEAK UNDEFs so hpux can use a stub to provide this symbol.  Clear
    	sh_info and sh_link in removed sections.
    
    2017-10-30  Richard Biener  <rguenther@suse.de>
    
    	PR lto/82757
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
    	Strip two leading _s from the __gnu_lto_* symbols.
    
    2017-10-24  Alan Modra  <amodra@gmail.com>
    
    	PR lto/82687
    	PR lto/82575
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
    	Only make __gnu_lto symbols hidden.
    
    2017-10-20  Alan Modra  <amodra@gmail.com>
    
    	PR lto/82575
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
    	Make discarded non-local symbols weak and hidden.
    
    2017-10-18  Jakub Jelinek  <jakub@redhat.com>
    
    	PR lto/82598
    	* simple-object.c (handle_lto_debug_sections): Copy over also
    	.note.GNU-stack section with unchanged name.
    	* simple-object-elf.c (SHF_EXECINSTR): Define.
    	(simple_object_elf_copy_lto_debug_section): Drop SHF_EXECINSTR bit
    	on .note.GNU-stack section.
    
    2017-09-25  Nathan Sidwell  <nathan@acm.org>
    
    	PR demangler/82195
    	* cp-demangle.c (d_encoding): Strip return type when name is a
    	LOCAL_NAME.
    	(d_local_name): Strip return type of enclosing TYPED_NAME.
    	* testsuite/demangle-expected: Add and adjust tests.
    
    2017-09-21  Nathan Sidwell  <nathan@acm.org>
    
    	PR demangler/82195
    	* cp-demangle.c (d_name): Revert addition of 'toplevel' parm.
    	(has_return_type): Recurse for DEMANGLE_COMPONENT_LOCAL_NAME.
    	(d_encoding): Revert d_name change.  Use is_fnqual_component_type
    	to strip modifiers that do not belong.
    	(d_special_name, d_class_enum_type): Revert d_name call change.
    	(d_expresion_1): Commonize DEMANGLE_COMPONENT_UNARY building.
    	(d_local_name): Revert parsing of a function type.
    	(d_print_comp_inner): An inner LOCAL_NAME might contain a
    	TEMPLATE.
    	* testsuite/demangle-expected: Add & adjust tests

commit cbda583ada32e16bf8b6c6aff730cc9eab63b364
Author: Jan Beulich <jbeulich@novell.com>
Date:   Wed Jan 10 14:53:43 2018 +0100

    x86: fix Disp8 handling for scalar AVX512_4FMAPS insns
    
    Just like their packed counterparts the memory operand is always 16
    bytes wide, and the Disp8 scaling is the same for all of them. (As a
    side note: I'm also surprised by there being AVX512VL variants of
    these as well as the AVX512_4VNNIW ones - the SDM doesn't define any
    such.)
    
    Adjust the test cases also for the packed forms to actually live up to
    their promise of testing correct Disp8 encoding.

commit c9e9227878d172d93bcbef51dfc76d96f027751d
Author: Jan Beulich <jbeulich@novell.com>
Date:   Wed Jan 10 14:53:05 2018 +0100

    x86: fix Disp8 handling for AVX512VL VPCMP*{B,W} variants
    
    In commit 2645e1d079 ("x86: add support for AVX-512 VPCMP*{B,W}
    pseudo-ops") I screwed up the Disp8MemShift values of the AVX512VL
    variants.

commit 35fd2b2bcf370837a03f077acf1222f0a7e9c4d1
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Jan 9 16:40:06 2018 -0800

    RISC-V: Disassemble x0 based addresses as 0.
    
    	gas/
    	* testsuite/gas/riscv/auipc-x0.d: New.
    	* testsuite/gas/riscv/auipc-x0.s: New.
    
    	opcodes/
    	* riscv-dis.c (maybe_print_address): If base_reg is zero,
    	then the hi_addr value is zero.

commit d9ccd460fdbe0e0f3dd9263175aa4b23b207a51e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jan 10 00:00:34 2018 +0000

    Automatic date update in version.in

commit 2d97a5d9d33aea87c3bd02fd1fa417f5d4e1fa05
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Jan 9 13:35:17 2018 -0800

    Document support for 'info proc' on FreeBSD.
    
    Since the 'info proc' support on FreeBSD does not use /proc, reword
    the documentation for 'info proc' to not assume /proc.  This includes
    renaming the node to 'Process Information' and suggesting that
    additional process information can be queried via different
    OS-specific interfaces.  This is also cleans up the description of
    'info proc' support for core files a bit as /proc is not used for core
    file support on any current platform.
    
    gdb/ChangeLog:
    
    	* NEWS: Document that 'info proc' now works on FreeBSD.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (pwd): Update cross-reference for Process Information
    	node and remove explicit /proc reference.
    	(Native): Rename subsection from SVR4 Process Information to
    	Process Information.
    	(Process Information): Reword introduction to be less /proc
    	centric.  Document support for "info proc" on FreeBSD.

commit 92fce24de299a8b9a9a1c0c6b98e0e9c1656f99c
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Jan 9 13:35:17 2018 -0800

    Support 'info proc' for native FreeBSD processes.
    
    - Command line arguments are fetched via the kern.proc.args.<pid>
      sysctl.
    - The 'cwd' and 'exe' values are obtained from the per-process
      file descriptor table returned by kinfo_getfile() from libutil.
    - 'mappings' is implemented by walking the array of VM map entries
      returned by kinfo_getvmmap() from libutil.
    - 'status' output is generated by outputting fields from the structure
      returned by the kern.proc.pid.<pid> sysctl.
    - 'stat' is aliased to 'status'.
    
    gdb/ChangeLog:
    
    	* configure.ac: Check for kinfo_getfile in libutil.
    	* configure: Regenerate.
    	* config.in: Regenerate.
    	* fbsd-nat.c: Include "fbsd-tdep.h".
    	(fbsd_fetch_cmdline): New.
    	(fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
    	rather than calling error.
    	(fbsd_info_proc): New.
    	(fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
    	(fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
    	(fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".

commit 262f62f57d987269152412a55c458a03adc6ddd6
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Jan 9 13:35:17 2018 -0800

    Use gdb::unique_xmalloc_ptr<> instead of a deleter that invokes free().
    
    Since xfree() always wraps free(), it is safe to use the xfree deleter
    for buffers allocated by library routines such as kinfo_getvmmap() that
    must be released via free().
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (struct free_deleter): Remove.
    	(fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.

commit b999e2038dbc54e2c8b1c390f8b8fe50d0f1d10a
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Jan 9 13:35:17 2018 -0800

    Don't return stale data from fbsd_pid_to_exec_file for kernel processes.
    
    For processes without an associated executable (such as kernel processes),
    the kern.proc.pathname.<pid> system control node returns a length of zero
    without modifying the user's buffer.  Detect this case and return NULL
    rather than the previous contents of the static buffer 'buf'.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
    	NULL for an empty pathname.

commit d2176225dc982c22640215a0e611e997e8eeb030
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Jan 9 13:35:17 2018 -0800

    Support 'info proc' for FreeBSD process core dumps.
    
    - Command line arguments are obtained from the pr_psargs[] array
      saved in the NT_PRPSINFO note.
    - The 'cwd' and 'exe' values are obtained from the per-process file
      descriptor table stored in the NT_PROCSTAT_FILES core note.
    - 'mappings' is implemented by walking the array of VM map entries
      stored in the NT_PROCSTAT_VMMAP core note.
    - 'status' output is generated by outputting fields from
      the first structure stored in the NT_PROCSTAT_PROC core note.
    - 'stat' is aliased to 'status'.
    
    gdb/ChangeLog:
    
    	* fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
    	(KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
    	(KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
    	(KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
    	(KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
    	(KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
    	(KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
    	(KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
    	(kinfo_proc_layout_32, kinfo_proc_layout_i386)
    	(kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
    	(fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
    	(fbsd_core_fetch_timeval, fbsd_print_sigset)
    	(fbsd_core_info_proc_status, fbsd_core_info_proc): New.
    	(fbsd_init_abi):  Install gdbarch "core_info_proc" method.
    	* fbsd-tdep.h (fbsd_vm_map_entry_flags): New.

commit 74ccf6db1188b7b05c716f8382d28b276ec578ec
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Jan 9 10:08:47 2018 -0800

    Add explicit shared check to eh-frame-hdr test.
    
    	ld/
    	* testsuite/ld-elf/eh-frame-hdr.d (#xfail): Delete
    	(#alltargets): Renamed from #target.  Add shared.
    	* testsuite/lib/ld-lib.exp (run_dump_test): Document shared target.
    	Document alltargets option.  Add support for alltargets option.
    	(istarget): Add support for shared target.

commit 91d8b670661883fc0472fd05cf0e54d0e357c187
Author: James Greenhalgh <james.greenhalgh@arm.com>
Date:   Tue Jan 9 14:15:00 2018 +0000

    [Arm] Add CSDB instruction
    
    CSDB is a new instruction which Arm has defined. As it shares the
    encoding space with NOP instructions, it is available from Armv3 in
    Arm mode, and Armv6T2 in Thumb mode.
    
    OK? If so, please commit on my behalf as I don't have commit rights
    over here.
    
    Thanks, James
    
    ---
    opcodes/
    
    2018-01-09  James Greenhalgh  <james.greenhalgh@arm.com>
    
    	* arm-dis.c (arm_opcodes): Add csdb.
    	(thumb32_opcodes): Add csdb.
    
    gas/
    
    2018-01-09  James Greenhalgh  <james.greenhalgh@arm.com>
    
    	* config/tc-arm.c (insns): Add csdb, enable for Armv3 and above
    	in Arm execution state, and Armv6T2 and above in Thumb execution
    	state.
    	* testsuite/gas/arm/csdb.s: New.
    	* testsuite/gas/arm/csdb.d: New.
    	* testsuite/gas/arm/thumb2_it_bad.l: Add csdb.
    	* testsuite/gas/arm/thumb2_it_bad.s: Add csdb.

commit be2e7d95414eb78f29312f30e62d4cabd55f9fda
Author: James Greenhalgh <james.greenhalgh@arm.com>
Date:   Tue Jan 9 11:28:04 2018 +0000

    Add support for the AArch64's CSDB instruction.
    
    CSDB is a new instruction which Arm has defined. It has the same encoding as
    HINT #0x14 and is available at all architecture levels.
    
    opcodes	* aarch64-tbl.h (aarch64_opcode_table): Add "csdb".
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis-2.c: Regenerate.
    	* aarch64-opc-2.c: Regenerate.
    
    gas	* testsuite/gas/aarch64/system.d: Update expected results to expect
    	CSDB.

commit b1dc1806fad00fc5b2589164e964646c02a700fa
Author: Xavier Roirand <roirand@adacore.com>
Date:   Mon Dec 11 10:03:45 2017 +0100

    Fix breakpoint add on inlined function using function name.
    
    Using this Ada example:
    
      package B is
        procedure Read_Small with Inline_Always;
      end B;
    
      package body B is
        Total : Natural := 0;
        procedure Read_Small is
        begin
          Total := Total + 1;
        end Read_Small;
      end B;
    
    and
    
      with B;
    
      procedure M is
      begin
        B.Read_Small;
      end M;
    
    % gnatmake -g -O0 -m m.adb -cargs -gnatn
    % gdb m
    
    Inserting a breakpoint on Read_Small inlined function does not work:
    
    (gdb) b read_small
    Breakpoint 1 at 0x40250e: file b.adb, line 5.
    (gdb) info b
    Num     Type           Disp Enb Address            What
    1       breakpoint     keep y   0x000000000040250e in b.doit at b.adb:5
    (gdb)
    
    In this exemple we should have two breakpoints set, one in package B and
    the other one in the inlined instance inside procedure M), like below:
    
    (gdb) b read_small
    Breakpoint 1 at 0x40250e: b.adb:5. (2 locations)
    (gdb) info b
    Num     Type           Disp Enb Address            What
    1       breakpoint     keep y   <MULTIPLE>
    1.1                         y     0x000000000040250e in b.doit at b.adb:5
    1.2                         y     0x0000000000402540 in m at b.adb:5
    (gdb)
    
    Looking at the DWARF info for inlined instance of Read_Small:
    
    <1><1526>: Abbrev Number: 2 (DW_TAG_subprogram)
        <1527>   DW_AT_name        : ([...], offset: 0x1e82): b__read_small
        <152b>   DW_AT_decl_file   : 2
        <152c>   DW_AT_decl_line   : 3
        <152d>   DW_AT_inline      : 3      (declared as inline and inlined)
    [...]
     <2><1547>: Abbrev Number: 4 (DW_TAG_inlined_subroutine)
        <1548>   DW_AT_abstract_origin: <0x1526>
        <154c>   DW_AT_low_pc      : 0x402552
        <1554>   DW_AT_high_pc     : 0x2b
        <155c>   DW_AT_call_file   : 1
        <155d>   DW_AT_call_line   : 5
     <2><155e>: Abbrev Number: 0
    
    During the parsing of DWARF info in order to produce partial DIE linked
    list, the DW_TAG_inlined_subroutine were skipped thus not present in the
    final partial dies.
    Taking DW_TAG_inlined_subroutine in account during the parsing process
    fixes the problem.
    
    gdb/ChangeLog:
    
            * dwarf2read.c (scan_partial_symbols, add_partial_symbol)
            (add_partial_subprogram, load_partial_dies): Add
            DW_TAG_inlined_subroutine handling.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/bp_inlined_func: New testcase.

commit 6cef73f96f58ca3f0e0b2f594b324602c7590611
Author: Kuan-Lin Chen <kuanlinchentw@gmail.com>
Date:   Tue Jan 9 16:04:58 2018 +0800

    PR22662, nds32: Fix a typographical error.

commit 7615ca1dc941bb9f225a1c50df7fdd8d31afc9e8
Author: Jim Wilson <jimw@sifive.com>
Date:   Mon Jan 8 17:55:29 2018 -0800

    RISC-V: Fix accidental embedded -shared regressions.
    
    	ld/
    	* testsuite/ld-riscv-elf/c-lui.d: Don't use -shared.  Check for _start
    	instead of .text.
    	* testsuite/ld-riscv-elf/c-lui.s: Add _start label.
    	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Before __global_pointer$
    	tests, add call to check_shared_lib_support.

commit 933ea656af9d40604e4823b07b83e74714f2516e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jan 9 00:00:33 2018 +0000

    Automatic date update in version.in

commit 9eed002340be2dd76dc7897eebe33cd7ede674a5
Merge: 7bbac84 9c4ac40
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jan 8 08:25:32 2018 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 9c4ac400f0f7d8daa8483dbe73b5699782ae3e22
Author: Samuel Thibault <samuel.thibault@ens-lyon.org>
Date:   Mon Jan 8 10:30:16 2018 -0500

    hurd: Add enough auxv support for AT_ENTRY for PIE binaries
    
    Add PIE support for hurd, by faking an AT_ENTRY auxv entry.  That value
    is expected to be read by svr4_exec_displacement, which will propagate
    the executable displacement.
    
    gdb/ChangeLog:
    
    	* gdb/gnu-nat.c: Include <elf.h> and <link.h>.
    	(gnu_xfer_auxv): New function.
    	(gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
    	TARGET_OBJECT_AUXV.

commit 704a705d7aaab8041df76e2981e2a1efc014aad0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jan 8 04:36:59 2018 -0800

    x86: Properly encode vmovd with 64-bit memeory
    
    For historical reason, we allow movd/vmovd with 64-bit register and
    memeory operands.  But for vmovd, we failed to handle 64-bit memeory
    operand.  This has been gone unnoticed since AT&T syntax always treats
    memory operand as 32-bit memory.  This patch properly encodes vmovd
    with 64-bit memeory operands.  It also removes AVX512 vmovd with 64-bit
    operands since GCC has
    
        case TYPE_SSEMOV:
          switch (get_attr_mode (insn))
            {
            case MODE_DI:
              /* Handle broken assemblers that require movd instead of movq.  */
              if (!HAVE_AS_IX86_INTERUNIT_MOVQ
                  && (GENERAL_REG_P (operands[0]) || GENERAL_REG_P (operands[1])))
                return "%vmovd\t{%1, %0|%0, %1}";
              return "%vmovq\t{%1, %0|%0, %1}";
    
    and all AVX512 GNU assemblers set HAVE_AS_IX86_INTERUNIT_MOVQ, GCC won't
    generate AVX512 vmovd with 64-bit operand.
    
    gas/
    
    	PR gas/22681
    	* testsuite/gas/i386/i386.exp: Run x86-64-movd and
    	x86-64-movd-intel.
    	* testsuite/gas/i386/x86-64-movd-intel.d: New file.
    	* testsuite/gas/i386/x86-64-movd.d: Likewise.
    	* testsuite/gas/i386/x86-64-movd.s: Likewise.
    
    opcodes/
    
    	PR gas/22681
    	* i386-opc.tbl: Properly encode vmovd with Qword memeory operand.
    	Remove AVX512 vmovd with 64-bit operands.
    	* i386-tbl.h: Regenerated.

commit 605fd3c6590fbed834107a2e1d1df0ba58834576
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Jan 8 10:09:33 2018 +0000

    Fix GDBserver build failure when $development is false
    
    When we set bfd/development.sh:$development to false, GDBserver failed to
    build,
    
    selftest.o: In function `selftests::run_tests(char const*)':
    binutils-gdb/gdb/gdbserver/../common/selftest.c:97:undefined reference to `selftests::reset()'
    collect2: error: ld returned 1 exit status
    
    selftest.o shouldn't be compiled and linked when $development is false.
    With this patch, in release mode, GDBserver doesn't nothing with option
    --selftest,
    
    $ ./gdbserver --selftest=foo
    Selftests are not available in a non-development build.
    $ ./gdbserver --selftest
    Selftests are not available in a non-development build.
    
    gdb/gdbserver:
    
    2018-01-08  Yao Qi  <yao.qi@linaro.org>
    	    Simon Marchi  <simon.marchi@ericsson.com>
    
    	* Makefile.in (OBS): Remove selftest.o.
    	* configure.ac: Set srv_selftest_objs if $development is true.
    	(GDBSERVER_DEPFILES): Append $srv_selftest_objs.
    	* configure: Re-generated.
    	* server.c (captured_main): Wrap variable selftest_filter with
    	GDB_SELF_TEST.
    
    gdb/testsuite:
    
    2018-01-08  Simon Marchi  <simon.marchi@ericsson.com>
    
    	* gdb.server/unittest.exp: Match the output in non-development
    	mode.

commit 1e5ded6ce688ddee065fa852053dda07fcce959e
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Jan 8 10:09:32 2018 +0000

    Fix GDB build failure when $development is false
    
    We don't build GDB selftests bits when $development is false.  However, if
    we turn bfd/development.sh:$development to false, common/selftest.c is
    compiled which is not expected.  It causes the build failure,
    
    selftest.o: In function `selftests::run_tests(char const*)':
    binutils-gdb/gdb/common/selftest.c:97: undefined reference to `selftests::reset()'
    collect2: error: ld returned 1 exit status
    
    I fix this issue by putting selftest.o selftest-arch.o into CONFIG_OBS
    only when $development is true.  After this is fixed, there are other
    build failures in maint.c, this patch fixes them as well.
    
    In the release mode, the output of these commands are:
    
    (gdb) maintenance selftest
    Selftests are not available in a non-development build.
    (gdb) maintenance selftest foo
    Selftests are not available in a non-development build.
    (gdb) maintenance info selftests
    Selftests are not available in a non-development build.
    
    gdb:
    
    2018-01-08  Yao Qi  <yao.qi@linaro.org>
    	    Simon Marchi  <simon.marchi@ericsson.com>
    
    	* Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
    	common/selftest.c.
    	(COMMON_OBS): Remove selftest.o.
    	* configure.ac: Append selftest-arch.c and common/selftest.c to
    	CONFIG_SRCS.  Append selftest-arch.o and selftest.o to COMMON_OBS.
    	* configure: Re-generated.
    	* maint.c (maintenance_selftest): Wrap selftests::run_tests with
    	GDB_SELF_TEST.
    	(maintenance_info_selftests): Likewise.
    
    gdb/testsuite:
    
    2018-01-08  Simon Marchi  <simon.marchi@ericsson.com>
    
    	* gdb.gdb/unittest.exp: Match output in non-development mode.

commit 9f86398b29d53a5a0aaea390ce813628715b3125
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 8 04:39:23 2018 -0500

    Fix second-to-last gdb/testsuite/ChangeLog entry.

commit 30066b0b00a2c09baed08e49437c2ae3c44bc4e0
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 8 04:26:52 2018 -0500

    Relax expected output in gdb.ada/access_tagged_param.exp test
    
    One of the tests in gdb.ada/access_tagged_param.exp verifies
    the value of the parameters being printed by GDB when stopping
    at a breakpoint inside procedure Pck.Inspect.
    
    In particular, one of these parameters is actually generated
    internally by the compiler, and does only indirectly depend
    on the user-level code. A recent change in AdaCore's compiler
    caused the code expansion to change a little bit, and as a result,
    the value of that parameter has changed from 2 to 3. This can be
    evindenced by looking at the code post expansion, using the -gnatDG
    command-line switch to generate the .dg files:
    
        $ gnatmake -g -gnatDG foo.adb
        $ vi foo.adb.dg
    
    We can see that the call to pck.inspect used to be:
    
        pck__inspect (P8b, objL => 2);
    
    With a recent version of GNAT Pro, it is now:
    
        pck__inspect (P9b, objL => 3);
    
    This change causes a spurious FAIL when running this testcase.
    The objL parameter being, at heart, a simple counter of the nesting
    level, this commit relaxes the expected output to accept any single-
    digit number. We could accept any decimal, but given the example
    program, I dout that number will reach double-digit level. If it
    does, we'll double-check that this is normal, and relax the expected
    output further.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/access_tagged_param.exp: Relax expected output
            for value of "ObjL" in "continue" to pck.inspect breakpoint
            test.
    
    Tested on x86_64-linux.

commit 102e9361c88882756ad7ffceb0713a794c991e69
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jan 8 09:29:17 2018 +0000

    Add a description of the X86_64 assembler's .largcomm pseudo-op.
    
    	PR 22553
    	* doc/c-i386.texi (i386-Directives): Document the .largecomm
    	directive.

commit 04bafb1ed002df1f25ca5a5773d87723a4baf46b
Author: Xavier Roirand <roirand@adacore.com>
Date:   Sun Jan 7 23:56:36 2018 -0500

    (Ada) Fix print of array using non-contiguous enumeration indexes
    
    Consider the following code:
    
      type Index is (Index1, Index2);
      Size : constant Integer := 10;
      for Index use (Index1 => 1, Index2 => Size);
      type Array_Index_Enum is array (Index) of Integer;
      my_table : Array_Index_Enum :=(others => 42);
    
    When compiling the code above with a compiler where the GNAT encodings
    are turned off (which can be temporarily emulated by using the compiler
    switch -fgnat-encodings=minimal), printing this table in gdb leads to:
    
      (gdb) p my_table
      $1 = (42, 42, 4203344, 10, -8320, 32767, 4203465, 0, 0, 0)
    
    The displayed content is wrong since the handling part believes
    that the length of the array is max index value (10) minus the
    first index value (1) i+ 1 = 10 which is wrong since index are not
    contiguous in this case.
    
    The right behavior is to detect that the array is using enumeration
    index hence parse the enumeration values in order to get the number
    of indexes in this array (2 indexes here).
    
    This patch fixes this issue and changes the output as follow:
    
      (gdb) p my_table
      $1 = (42, 42)
    
    gdb/ChangeLog:
    
            * ada-valprint.c (val_print_packed_array_elements): Use
            proper number of elements when printing an array indexed
            by an enumeration type.
    
    gdb/testsuite/ChangeLog (Joel Brobecker  <brobecker@adacore.com>):
    
            * gdb.ada/arr_enum_idx_w_gap.exp
            * gdb.ada/arr_enum_idx_w_gap/foo_q418_043.adb
    
    Tested on x86_64-linux.

commit e09efd5931daf7eede1f4da46313a1aaadd4dbfa
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jan 8 00:00:33 2018 +0000

    Automatic date update in version.in

commit 518817b361167ac91e7cdad8528b4d90cdc3fb26
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 7 11:22:46 2018 -0500

    Remove dwarf2_cu::dwarf2_per_objfile
    
    This patch removes the dwarf2_per_objfile field of dwarf2_cu.  It is
    redundant, since we can access dwarf2_per_objfile through
    dwarf2_per_objfile, which is guaranteed to be set.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
    	(dw2_get_file_names_reader): Adjust.
    	(lookup_dwo_signatured_type): Adjust.
    	(lookup_dwp_signatured_type): Adjust.
    	(lookup_signatured_type): Adjust.
    	(create_type_unit_group): Adjust.
    	(get_type_unit_group): Adjust.
    	(process_psymtab_comp_unit_reader): Adjust.
    	(build_type_psymtabs_reader): Adjust.
    	(scan_partial_symbols): Adjust.
    	(add_partial_symbol): Adjust.
    	(add_partial_subprogram): Adjust.
    	(peek_die_abbrev): Adjust.
    	(fixup_go_packaging): Adjust.
    	(process_imported_unit_die): Adjust.
    	(dwarf2_compute_name): Adjust.
    	(dwarf2_physname): Adjust.
    	(read_import_statement): Adjust.
    	(handle_DW_AT_stmt_list): Adjust.
    	(read_file_scope): Adjust.
    	(read_func_scope): Adjust.
    	(read_lexical_block_scope): Adjust.
    	(read_call_site_scope): Adjust.
    	(read_variable): Adjust.
    	(dwarf2_rnglists_process): Adjust.
    	(dwarf2_ranges_process): Adjust.
    	(dwarf2_ranges_read): Adjust.
    	(dwarf2_get_pc_bounds): Adjust.
    	(dwarf2_record_block_ranges): Adjust.
    	(dwarf2_add_field): Adjust.
    	(dwarf2_add_member_fn): Adjust.
    	(read_structure_type): Adjust.
    	(process_structure_scope): Adjust.
    	(read_enumeration_type): Adjust.
    	(read_array_type): Adjust.
    	(mark_common_block_symbol_computed): Adjust.
    	(read_common_block): Adjust.
    	(read_namespace_type): Adjust.
    	(read_namespace): Adjust.
    	(read_module_type): Adjust.
    	(read_tag_pointer_type): Adjust.
    	(read_tag_ptr_to_member_type): Adjust.
    	(read_tag_string_type): Adjust.
    	(read_subroutine_type): Adjust.
    	(read_typedef): Adjust.
    	(read_base_type): Adjust.
    	(attr_to_dynamic_prop): Adjust.
    	(read_subrange_type): Adjust.
    	(read_unspecified_type): Adjust.
    	(dwarf2_read_abbrevs): Adjust.
    	(load_partial_dies): Adjust.
    	(read_partial_die): Adjust.
    	(find_partial_die): Adjust.
    	(guess_partial_die_structure_name): Adjust.
    	(fixup_partial_die): Adjust.
    	(read_attribute_value): Adjust.
    	(read_addr_index): Adjust.
    	(read_addr_index_from_leb128): Adjust.
    	(read_str_index): Adjust.
    	(dwarf2_string_attr): Adjust.
    	(get_debug_line_section): Adjust.
    	(dwarf_decode_line_header): Adjust.
    	(lnp_state_machine::check_line_address): Adjust.
    	(dwarf_decode_lines_1): Adjust.
    	(dwarf_decode_lines): Adjust.
    	(dwarf2_start_symtab): Adjust.
    	(var_decode_location): Adjust.
    	(new_symbol_full): Adjust.
    	(dwarf2_const_value_data): Adjust.
    	(dwarf2_const_value_attr): Adjust.
    	(dwarf2_const_value): Adjust.
    	(die_type): Adjust.
    	(die_containing_type): Adjust.
    	(build_error_marker_type): Adjust.
    	(lookup_die_type): Adjust.
    	(guess_full_die_structure_name): Adjust.
    	(anonymous_struct_prefix): Adjust.
    	(determine_prefix): Adjust.
    	(dwarf2_name): Adjust.
    	(follow_die_ref_or_sig): Adjust.
    	(follow_die_offset): Adjust.
    	(follow_die_ref): Adjust.
    	(follow_die_sig_1): Adjust.
    	(follow_die_sig): Adjust.
    	(get_signatured_type): Adjust.
    	(get_DW_AT_signature_type): Adjust.
    	(decode_locdesc): Adjust.
    	(dwarf_decode_macros): Adjust.
    	(cu_debug_loc_section): Adjust.
    	(fill_in_loclist_baton): Adjust.
    	(dwarf2_symbol_mark_computed): Adjust.
    	(init_one_comp_unit): Don't assign
    	dwarf2_cu::dwarf2_per_objfile.
    	(set_die_type): Adjust.

commit ed2dc618b3d2b0be01ffdf74c4c75504b707bcf1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jan 7 11:22:46 2018 -0500

    Remove dwarf2_per_objfile global
    
    This patch removes the global variable dwarf2_per_objfile.  This global
    variable is set at the various entry points of dwarf2read.c (using
    dw2_setup), and is referred to throughout the file.  Instead of passing
    data between functions in global variables like this one, it would be
    better if the functions that depend on it either received it as argument
    or got it from the existing arguments they receive.  For example, a
    function receiving a reference to a dwarf2_per_cu_data can access it
    from dwarf2_per_cu_data::dwarf2_per_objfile.
    
    This patch has been tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (struct mapped_debug_names): Add constructor.
    	<dwarf2_per_objfile>: New field.
    	(dwarf2_per_objfile): Remove global.
    	(get_dwarf2_per_objfile): New function.
    	(set_dwarf2_per_objfile): New function.
    	(dwarf2_build_psymtabs_hard): Change objfile parameter to
    	dwarf2_per_objfile.
    	(abbrev_table_read_table): Add dwarf2_per_objfile parameter.
    	(read_abbrev_offset): Likewise.
    	(read_indirect_string): Likewise.
    	(read_indirect_line_string): Likewise.
    	(read_indirect_string_at_offset): Likewise.
    	(read_indirect_string_from_dwz): Likewise.
    	(dwarf2_find_containing_comp_unit): Change objfile parameter to
    	dwarf2_per_objfile.
    	(age_cached_comp_units): Add dwarf2_per_objfile parameter.
    	(create_all_comp_units): Change objfile parameter to
    	dwarf2_per_objfile.
    	(create_all_type_units): Likewise.
    	(process_queue): Add dwarf2_per_objfile parameter.
    	(read_and_check_comp_unit_head): Likewise.
    	(lookup_dwo_unit_in_dwp): Likewise.
    	(get_dwp_file): Likewise.
    	(process_cu_includes): Likewise.
    	(struct free_dwo_file_cleanup_data): New struct.
    	(dwarf2_has_info): Use get_dwarf2_per_objfile and
    	set_dwarf2_per_objfile.
    	(dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
    	(dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
    	context, adjust calls.
    	(dw2_instantiate_symtab): Likewise.
    	(dw2_get_cutu): Add dwarf2_per_objfile parameter.
    	(dw2_get_cu): Likewise.
    	(create_cu_from_index_list): Change objfile parameter to
    	dwarf2_per_objfile.
    	(create_cus_from_index_list): Get dwarf2_per_objfile from
    	context, adjust calls.
    	(create_cus_from_index): Likewise.
    	(create_signatured_type_table_from_index): Change objfile
    	parameter to dwarf2_per_objfile.
    	(create_signatured_type_table_from_debug_names): Change objfile
    	parameter to dwarf2_per_objfile.
    	(create_addrmap_from_index): Likewise.
    	(create_addrmap_from_aranges): Likewise.
    	(dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
    	(dw2_setup): Remove.
    	(dw2_get_file_names_reader): Get dwarf2_per_objfile from
    	context.
    	(dw2_find_last_source_symtab): Get dwarf2_per_objfile using
    	get_dwarf2_per_objfile.
    	(dw2_forget_cached_source_info): Likewise.
    	(dw2_map_symtabs_matching_filename): Likewise.
    	(struct dw2_symtab_iterator) <index>: Remove.
    	<dwarf2_per_objfile>: New field.
    	(dw2_symtab_iter_init): Replace index parameter with
    	dwarf2_per_objfile.
    	(dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
    	(dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
    	(dw2_print_stats): Likewise.
    	(dw2_dump): Likewise.
    	(dw2_expand_symtabs_for_function): Likewise.
    	(dw2_expand_all_symtabs): Likewise.
    	(dw2_expand_symtabs_with_fullname): Likewise.
    	(dw2_expand_marked_cus): Replace index and objfile parameters
    	with dwarf2_per_objfile.
    	(dw_expand_symtabs_matching_file_matcher): Add
    	dwarf2_per_objfile parameter and adjust calls.
    	(dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
    	adjust calls.
    	(dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
    	(dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
    	adjust calls.
    	(create_cus_from_debug_names_list): Replace objfile parameter
    	with dwarf2_per_objfile and adjust calls.
    	(create_cus_from_debug_names): Likewise.
    	(dwarf2_read_debug_names): Likewise.
    	(mapped_debug_names::namei_to_name): Adjust call.
    	(dw2_debug_names_iterator::next): Likewise.
    	(dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
    	(dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
    	(dw2_debug_names_dump): Likewise.
    	(dw2_debug_names_expand_symtabs_for_function): Likewise.
    	(dw2_debug_names_expand_symtabs_matching): Likewise.
    	(dwarf2_initialize_objfile): Likewise.
    	(dwarf2_build_psymtabs): Likewise.
    	(get_abbrev_section_for_cu): Get dwarf2_per_objfile from
    	this_cu.
    	(error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
    	(read_and_check_comp_unit_head): Likewise.
    	(read_abbrev_offset): Likewise.
    	(create_debug_type_hash_table): Likewise.
    	(create_debug_types_hash_table): Likewise.
    	(create_all_type_units): Replace objfile parameter with
    	dwarf2_per_objfile.
    	(add_type_unit): Add dwarf2_per_objfile parameter.
    	(fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
    	with dwarf2_per_objfile.
    	(lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
    	(lookup_dwp_signatured_type): Likewise.
    	(lookup_signatured_type): Likewise.
    	(read_cutu_die_from_dwo): Likewise.
    	(init_tu_and_read_dwo_dies): Likewise.
    	(init_cutu_and_read_dies): Likewise.
    	(init_cutu_and_read_dies_no_follow): Likewise.
    	(allocate_type_unit_groups_table): Add objfile parameter.
    	(create_type_unit_group): Use dwarf2_per_objfile from cu.
    	(get_type_unit_group): Likewise.
    	(process_psymtab_comp_unit): Update call.
    	(build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
    	(build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
    	(print_tu_stats): Likewise.
    	(build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
    	in void* parameter.
    	(build_type_psymtabs): Change objfile parameter to
    	dwarf2_per_objfile.
    	(process_skeletonless_type_unit): Use dwarf2_per_objfile
    	passed in void* parameter.
    	(process_skeletonless_type_units): Change objfile parameter to
    	dwarf2_per_objfile.
    	(set_partial_user): Likewise.
    	(dwarf2_build_psymtabs_hard): Likewise.
    	(read_comp_units_from_section): Likewise.
    	(create_all_comp_units): Likewise.
    	(scan_partial_symbols): Update calls.
    	(add_partial_symbol): Likewise.
    	(dwarf2_read_symtab): Use get_dwarf2_per_objfile.
    	(maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
    	(process_queue): Add dwarf2_per_objfile parameter.
    	(get_compunit_symtab): Use dwarf2_per_objfile from cu.
    	(compute_compunit_symtab_includes): Likewise.
    	(process_cu_includes): Add dwarf2_per_objfile parameter.
    	(process_full_comp_unit): Use dwarf2_per_objfile from cu.
    	(process_full_type_unit): Likewise.
    	(process_imported_unit_die): Update call.
    	(handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
    	(read_file_scope): Likewise.
    	(allocate_dwo_file_hash_table): Add objfile parameter.
    	(lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
    	(create_cus_hash_table): Likewise.
    	(create_dwp_hash_table): Likewise.
    	(create_dwo_unit_in_dwp_v1): Likewise.
    	(create_dwp_v2_section): Likewise.
    	(create_dwo_unit_in_dwp_v2): Likewise.
    	(lookup_dwo_unit_in_dwp): Likewise.
    	(try_open_dwop_file): Likewise.
    	(open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
    	(open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
    	cleanup to include a reference to dwarf2_per_objfile.
    	(open_dwp_file): Add dwarf2_per_objfile parameter.
    	(open_and_init_dwp_file): Likewise.
    	(get_dwp_file): Likewise.
    	(lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
    	(queue_and_load_all_dwo_tus): Update call.
    	(free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
    	data.
    	(dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
    	(dwarf2_ranges_process): Likewise.
    	(dwarf2_get_pc_bounds): Likewise.
    	(mark_common_block_symbol_computed): Likewise.
    	(abbrev_table_read_table): Add dwarf2_per_objfile parameter.
    	(dwarf2_read_abbrevs): Update call.
    	(read_partial_die): Use dwarf2_per_objfile from cu.
    	(find_partial_die): Likewise.
    	(fixup_partial_die): Likewise.
    	(read_attribute_value): Likewise.
    	(read_indirect_string_at_offset_from): Add objfile parameter.
    	(read_indirect_string_at_offset): Add dwarf2_per_objfile
    	parameter.
    	(read_indirect_string_from_dwz): Add objfile parameter.
    	(read_indirect_string): Add objfile parameter.
    	(read_addr_index_1): Add dwarf2_per_objfile parameter.
    	(read_addr_index): Use dwarf2_per_objfile from cu.
    	(dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
    	call dw2_setup.
    	(read_str_index): Use dwarf2_per_objfile from cu.
    	(get_debug_line_section): Likewise.
    	(read_formatted_entries): Add dwarf2_per_objfile parameter.
    	(dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
    	(new_symbol_full): Use dwarf2_per_objfile from cu.
    	(build_error_marker_type): Likewise.
    	(lookup_die_type): Likewise.
    	(determine_prefix): Likewise.
    	(follow_die_offset): Likewise.
    	(dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
    	(dwarf2_fetch_constant_bytes): Don't call dw2_setup.
    	(dwarf2_fetch_die_type_sect_off): Likewise.
    	(dwarf2_get_die_type): Likewise.
    	(follow_die_sig_1): Use dwarf2_per_objfile from cu.
    	(get_signatured_type): Likewise.
    	(get_DW_AT_signature_type): Likewise.
    	(dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
    	(dwarf_decode_macros): Use dwarf2_per_objfile from cu.
    	(cu_debug_loc_section): Likewise.
    	(fill_in_loclist_baton): Likewise.
    	(dwarf2_symbol_mark_computed): Likewise.
    	(dwarf2_find_containing_comp_unit): Change objfile parameter to
    	dwarf2_per_objfile.
    	(free_cached_comp_units): Use dwarf2_per_objfile passed in void*
    	parameter.
    	(age_cached_comp_units): Add dwarf2_per_objfile parameter.
    	(free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
    	(dwarf2_free_objfile): Use get_dwarf2_per_objfile.
    	(set_die_type): Use dwarf2_free_objfile from cu.
    	(get_die_type_at_offset): Likewise.
    	(dwarf2_per_objfile_free): Don't assign global variable.
    	(debug_names) <constructor>: Add dwarf2_per_objfile
    	parameter, update m_debugstrlookup construction.
    	(debug_names::debug_str_lookup): Add dwarf2_per_objfile
    	parameter.
    	<m_dwarf2_per_objfile>: New field.
    	<lookup>: Use m_dwarf2_per_objfile.
    	(check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
    	(psyms_seen_size): Likewise.
    	(write_gdbindex): Replace objfile parameter with
    	dwarf2_per_objfile.
    	(write_debug_names): Likewise.
    	(write_psymtabs_to_index): Likewise.
    	(save_gdb_index_command): Use get_dwarf2_per_objfile, update
    	calls.

commit e3b94546125849c6c513114cf20f78d2a7aa9db2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jan 7 11:22:45 2018 -0500

    Replace objfile field in dwarf2_cu and dwarf2_per_cu_data with dwarf2_per_objfile
    
    The next patch aims to remove the dwarf2_per_objfile global.  In many
    functions, we need to find a way to get a reference to the current
    dwarf2_per_objfile through the objects passed in parameters.  Often, we have
    access to a dwarf2_cu or a dwarf2_per_cu_data.  These objects have a reference
    to the objfile, through which we can get the dwarf2_per_objfile:
    
      dwarf2_per_objfile = ((struct dwarf2_per_objfile *)
    		        objfile_data (objfile, dwarf2_objfile_data_key));
    
    However, this is a bit cumbersome to do all over the place.  It would be
    more logical if the dwarf2_cu and dwarf2_per_cu_data had a reference to
    their dwarf2_per_objfile, which would then have a reference to the
    objfile.  It would be more in line with the object hierarchy, where
    dwarf2_per_objfile owns the dwarf2_per_cu_data instances.  We could
    even remove the reference dwarf2_cu has to dwarf2_per_objfile, since we
    can access dwarf2_per_objfile through dwarf2_cu::per_cu.
    
    In a graphical way, references would look like this after the current
    patch:
    
      objfile <--- dwarf2_per_objfile <--- dwarf2_per_cu_data
                                        |      ^
    				    |      |
                                        `- dwarf2_cu
    
    This patch has been tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
    	<dwarf2_per_objfile>: New field.
    	(struct dwarf2_per_cu_data) <objfile>: Remove.
    	<dwarf2_per_objfile>: New field.
    	(create_cu_from_index_list): Assign dwarf2_per_objfile instead
    	of objfile.
    	(create_signatured_type_table_from_index): Likewise.
    	(create_debug_type_hash_table): Likewise.
    	(fill_in_sig_entry_from_dwo_entry): Likewise.
    	(lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
    	(create_type_unit_group): Assign dwarf2_per_objfile instead of
    	objfile.
    	(create_partial_symtab): Access objfile through
    	dwarf2_per_objfile.
    	(process_psymtab_comp_unit_reader): Likewise.
    	(read_comp_units_from_section): Likewise.
    	(scan_partial_symbols): Likewise.
    	(add_partial_symbol): Likewise.
    	(add_partial_subprogram): Likewise.
    	(peek_die_abbrev): Likewise.
    	(fixup_go_packaging): Likewise.
    	(process_full_comp_unit): Likewise.
    	(process_full_type_unit): Likewise.
    	(process_imported_unit_die): Likewise.
    	(dwarf2_compute_name): Likewise.
    	(dwarf2_physname): Likewise.
    	(read_import_statement): Likewise.
    	(create_cus_hash_table): Assign dwarf2_physname instead of
    	objfile.
    	(read_func_scope): Access objfile through dwarf2_per_objfile.
    	(read_lexical_block_scope): Likewise.
    	(read_call_site_scope): Likewise.
    	(read_variable): Likewise.
    	(dwarf2_rnglists_process): Likewise.
    	(dwarf2_ranges_process): Likewise.
    	(dwarf2_ranges_read): Likewise.
    	(dwarf2_record_block_ranges): Likewise.
    	(dwarf2_add_field): Likewise.
    	(dwarf2_add_member_fn): Likewise.
    	(read_structure_type): Likewise.
    	(process_structure_scope): Likewise.
    	(read_enumeration_type): Likewise.
    	(read_array_type): Likewise.
    	(read_common_block): Likewise.
    	(read_namespace_type): Likewise.
    	(read_namespace): Likewise.
    	(read_module_type): Likewise.
    	(read_tag_pointer_type): Likewise.
    	(read_tag_ptr_to_member_type): Likewise.
    	(read_tag_string_type): Likewise.
    	(read_subroutine_type): Likewise.
    	(read_typedef): Likewise.
    	(read_base_type): Likewise.
    	(attr_to_dynamic_prop): Likewise.
    	(read_subrange_type): Likewise.
    	(read_unspecified_type): Likewise.
    	(load_partial_dies): Likewise.
    	(read_partial_die): Likewise.
    	(find_partial_die): Likewise.
    	(guess_partial_die_structure_name): Likewise.
    	(fixup_partial_die): Likewise.
    	(read_attribute_value): Likewise.
    	(read_addr_index_from_leb128): Likewise.
    	(dwarf2_read_addr_index): Likewise.
    	(dwarf2_string_attr): Likewise.
    	(lnp_state_machine::check_line_address): Likewise.
    	(dwarf_decode_lines_1): Likewise.
    	(dwarf_decode_lines): Likewise.
    	(dwarf2_start_symtab): Likewise.
    	(var_decode_location): Likewise.
    	(new_symbol_full): Likewise.
    	(dwarf2_const_value_data): Likewise.
    	(dwarf2_const_value_attr): Likewise.
    	(dwarf2_const_value): Likewise.
    	(die_type): Likewise.
    	(die_containing_type): Likewise.
    	(lookup_die_type): Likewise.
    	(guess_full_die_structure_name): Likewise.
    	(anonymous_struct_prefix): Likewise.
    	(dwarf2_name): Likewise.
    	(follow_die_ref_or_sig): Likewise.
    	(follow_die_offset): Likewise.
    	(follow_die_ref): Likewise.
    	(dwarf2_fetch_die_loc_sect_off): Likewise.
    	(dwarf2_fetch_constant_bytes): Likewise.
    	(dwarf2_fetch_die_type_sect_off): Likewise.
    	(dwarf2_get_die_type): Likewise.
    	(follow_die_sig): Likewise.
    	(decode_locdesc): Likewise.
    	(dwarf2_per_cu_objfile): Likewise.
    	(dwarf2_per_cu_text_offset): Likewise.
    	(init_one_comp_unit): Assign dwarf2_per_objfile instead of
    	objfile.
    	(set_die_type): Access objfile through
    	dwarf2_per_objfile.

commit 2cc050302cd365fd28fac65d49b6c817eed74faf
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 7 10:50:48 2018 -0500

    Make parse_debug_format_options return an std::string
    
    This avoid having to manually free the return value.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (parse_debug_format_options): Return std::string.
    	(handle_monitor_command, captured_main): Adjust.

commit b01ba14d4d5391e59fd0e1a3608fd47287edc008
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jan 7 10:48:21 2018 -0500

    Replace VEC(converted_character_d) with std::vector
    
    This patch changes the usage of VEC(converted_character_d) to use an
    std::vector instead.  This allows getting rid of a cleanup.
    
    gdb/ChangeLog:
    
    	* valprint.c (converted_character_d): Remove typedef.
    	(DEF_VEC_O (converted_character_d)): Remove.
    	(count_next_character): Use std::vector.
    	(print_converted_chars_to_obstack): Likewise.
    	(generic_printstr): Likewise.

commit 4d0fdd9b357aff1fea3ef3def55d12464a41bf5b
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 7 09:29:52 2018 -0500

    Replace VEC(gdb_xml_value_s) with std::vector
    
    This patch replaces VEC(gdb_xml_value_s), which is passed to XML
    visitors, with an std::vector.  In order to be able to remove the
    cleanup in gdb_xml_parser::start_element, the gdb_xml_parser structure
    is made to own the value with a gdb::unique_xmalloc_ptr.
    
    This patch has been tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* xml-support.h (struct gdb_xml_value): Add constructor.
    	<value>: Change type to unique_xmalloc_ptr.
    	(gdb_xml_value_s): Remove typedef.
    	(DEF_VEC_O (gdb_xml_value_s)): Remove.
    	(gdb_xml_element_start_handler): Change parameter type to
    	std::vector.
    	(xml_find_attribute): Likewise.
    	* xml-support.c (xml_find_attribute): Change parameter type to
    	std::vector and adjust.
    	(gdb_xml_values_cleanup): Remove.
    	(gdb_xml_parser::start_element): Adjust to std::vector.
    	(xinclude_start_include): Change paraeter type to std::vector
    	and adjust.
    	* btrace.c (check_xml_btrace_version): Likewise.
    	(parse_xml_btrace_block): Likewise.
    	(parse_xml_btrace_pt_config_cpu): Likewise.
    	(parse_xml_btrace_pt): Likewise.
    	(parse_xml_btrace_conf_bts): Likewise.
    	(parse_xml_btrace_conf_pt): Likewise.
    	* memory-map.c (memory_map_start_memory): Likewise.
    	(memory_map_start_property): Likewise.
    	* osdata.c (osdata_start_osdata): Likewise.
    	(osdata_start_item): Likewise.
    	(osdata_start_column): Likewise.
    	* remote.c (start_thread): Likewise.
    	* solib-aix.c (library_list_start_library): Likewise.
    	(library_list_start_list): Likewise.
    	* solib-svr4.c (library_list_start_library): Likewise.
    	(svr4_library_list_start_list): Likewise.
    	* solib-target.c (library_list_start_segment): Likewise.
    	(library_list_start_section): Likewise.
    	(library_list_start_library): Likewise.
    	(library_list_start_list): Likewise.
    	* tracepoint.c (traceframe_info_start_memory): Likewise.
    	(traceframe_info_start_tvar): Likewise.
    	* xml-syscall.c (syscall_start_syscall): Likewise.
    	* xml-tdesc.c (tdesc_start_target): Likewise.
    	(tdesc_start_feature): Likewise.
    	(tdesc_start_reg): Likewise.
    	(tdesc_start_union): Likewise.
    	(tdesc_start_struct): Likewise.
    	(tdesc_start_flags): Likewise.
    	(tdesc_start_enum): Likewise.
    	(tdesc_start_field): Likewise.
    	(tdesc_start_enum_value): Likewise.
    	(tdesc_start_vector): Likewise.

commit f979c73fd0be9a8a683f79af40c7b939c2a65d9f
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 7 09:25:33 2018 -0500

    Remove xmethod_worker::clone
    
    I think that the clone method of xmethod_worker can be removed.  It is
    only used in find_overload_match, to clone an xmethod we want to
    keep.  Instead, we can just std::move it out of the vector and into
    value_from_xmethod.  value_from_xmethod creates a value that will own
    the xmethod_worker from that point.  Other xmethod_workers left in the
    vector will get destroyed when the vector gets destroyed, but the chosen
    one will keep living inside the value struct.
    
    gdb/ChangeLog:
    
    	* extension.h (struct xmethod_worker) <clone>: Remove.
    	* python/py-xmethods.c (struct python_xmethod_worker) <clone>:
    	Remove.
    	(python_xmethod_worker::clone): Remove.
    	* valops.c (find_overload_match): Use std::move instead of
    	clone.

commit ba18742c3a1b62ff218db99bee47bb932af6dab9
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 7 09:25:32 2018 -0500

    C++ify xmethod_worker, get rid of VEC(xmethod_worker_ptr)
    
    The initial goal of this patch was to remove the usage of
    VEC(xmethod_worker_ptr) and corresponding cleanups.  I ended up having
    to  C++ify the xmethod_worker code, to be able to have xmethod_workers
    free their data in destructors, and therefore be able to use vectors of
    xmethod_worker unique_ptr.
    
    The operations in extension_language_ops that act on one instance of
    xmethod_worker (get result type, get args type, invoke) are transformed
    to methods of xmethod_worker.  xmethod_worker becomes an abstract base
    class with virtual pure methods which python_xmethod_worker implements.
    The only xmethod-related operation left in extension_language_ops is
    get_matching_xmethod_workers, which returns a list of xmethod_workers.
    
    The changes are relatively straightforward, but here are some notes on
    things that may raise eyebrows:
    
      - I was not really comfortable with the value_of_xmethod function.  At
      first it looks like a simple getter, so I considered making it a
      method of xmethod_worker.  But actually it creates a value and
      transfers the ownership of the xmethod_worker to it.  It would be a
      bit weird and error-prone if calling a method on an object silently
      removed the ownership of the object from the caller.  To reflect the
      behavior more accurately, I renamed it to value_from_xmethod and made
      it accept an rvalue-reference (so the caller knows it gives away the
      ownership).  I noticed the backlink from xmethod_worker to its owning
      value was not used, so I removed it.
    
      - Some code, like get_matching_xmethod_workers, made each callee fill
      a new vector, which was then merged in the result vector.  I think
      it's safe if we always pass the same vector around, and each
      implementation just appends to it.
    
      - The clone operation does not seem particularly useful, it is removed
      in the following patch.
    
    gdb/ChangeLog:
    
    	* extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
    	(struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
    	<free_xmethod_worker_data>: Remove.
    	<get_matching_xmethod_workers>: Chance VEC to std::vector.
    	<get_xmethod_arg_types>: Remove.
    	<get_xmethod_result_type>: Remove.
    	<invoke_xmethod>: Remove.
    	* extension.c (new_xmethod_worker): Remove.
    	(clone_xmethod_worker): Remove.
    	(get_matching_xmethod_workers): Return void, pass std::vector by
    	pointer.
    	(get_xmethod_arg_types): Rename to...
    	(xmethod_worker::get_arg_types): ... this, and adjust.
    	(get_xmethod_result_type): Rename to...
    	(xmethod_worker::get_result_type): ... this, and adjust.
    	(invoke_xmethod): Remove.
    	(free_xmethod_worker): Remove.
    	(free_xmethod_worker_vec): Remove.
    	* extension.h (enum ext_lang_rc): Move here from
    	extension-priv.h.
    	(struct xmethod_worker): Add constructor and destructor.
    	<data>: Remove.
    	<value>: Remove.
    	<invoke, clone, do_get_result_type, do_get_arg_types>: New
    	virtual pure methods.
    	<get_arg_types, get_result_type>: New methods.
    	(xmethod_worker_ptr): Remove typedef.
    	(DEF_VEC_P (xmethod_worker_ptr)): Remove.
    	(xmethod_worker_vec): Remove typedef.
    	(xmethod_worker_up): New typedef.
    	(invoke_xmethod): Remove.
    	(clone_xmethod_worker): Remove.
    	(free_xmethod_worker): Remove.
    	(free_xmethod_worker_vec): Remove.
    	(get_xmethod_arg_types): Remove.
    	(get_xmethod_result_type): Remove.
    	* valops.c (find_method_list): Use std::vector, don't use
    	intermediate vector.
    	(value_find_oload_method_list): Use std::vector.
    	(find_overload_match): Use std::vector.
    	(find_oload_champ): Use std::vector.
    	* value.c (value_free): Use operator delete.
    	(value_of_xmethod): Rename to...
    	(value_from_xmethod): ... this.  Don't assign
    	xmethod_worker::value, take rvalue-reference.
    	(result_type_of_xmethod): Adjust.
    	(call_xmethod): Adjust.
    	* value.h: Include extension.h.
    	(struct xmethod_worker): Don't forward-declare.
    	(value_of_xmethod): Rename to...
    	(value_from_xmethod): ... this, take rvalue-reference.
    	* python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
    	(struct python_xmethod_worker): ... this, add constructor and
    	destructor.
    	<invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
    	(gdbpy_free_xmethod_worker_data): Rename to...
    	(python_xmethod_worker::~python_xmethod_worker): ... this and
    	adjust.
    	(gdbpy_clone_xmethod_worker_data): Rename to...
    	(python_xmethod_worker::clone): ... this and adjust.
    	(gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
    	temporary vector.
    	(gdbpy_get_xmethod_arg_types): Rename to...
    	(python_xmethod_worker::do_get_arg_types): ... this and adjust.
    	(gdbpy_get_xmethod_result_type): Rename to...
    	(python_xmethod_worker::do_get_result_type): ... this and
    	adjust.
    	(gdbpy_invoke_xmethod): Rename to...
    	(python_xmethod_worker::invoke): ... this and adjust.
    	(new_python_xmethod_worker): Rename to...
    	(python_xmethod_worker::python_xmethod_worker): ... this and
    	adjust.
    	* python/python-internal.h (gdbpy_clone_xmethod_worker_data):
    	Remove.
    	(gdbpy_free_xmethod_worker_data): Remove.
    	(gdbpy_get_matching_xmethod_workers): Use std::vector.
    	(gdbpy_get_xmethod_arg_types): Remove.
    	(gdbpy_get_xmethod_result_type): Remove.
    	(gdbpy_invoke_xmethod): Remove.
    	* python/python.c (python_extension_ops): Remove obsolete
    	callbacks.

commit d672364615e87e8c366b536940f269fdc3141330
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jan 7 00:00:33 2018 +0000

    Automatic date update in version.in

commit 35eeb78fa9535df6a273c053d8f102e046261b89
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Jan 5 17:51:23 2018 -0800

    RISC-V: Print symbol address for jalr w/ zero offset.
    
    	ld/
    	* testsuite/ld-riscv-elf/disas-jalr.d: New.
    	* testsuite/ld-riscv-elf/disas-jalr.s: New.
    	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Run new testcase.
    
    	opcodes/
    	* riscv-dis.c (print_insn_args) <'s'>: Call maybe_print_address for a
    	jalr.

commit 77a502c03a347f0eb31e53e94cab528190c5bd1f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jan 6 00:00:28 2018 +0000

    Automatic date update in version.in

commit be1dce26256aa9f6c7742e81c8c3db9eacff079d
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Jan 5 14:29:49 2018 -0800

    RISC-V: Disable shared library support for embedded elf.
    
    	ld/
    	* emulparams/elf32lriscv-defs.sh (GENERATE_SHLIB_SCRIPT): Move inside
    	case on $target, and don't set for riscv*-elf targets.
    	(GENERATE_PIE_SCRIPT): Likewise.

commit e379cee61f3890e535e995828e8846b020ef2a32
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Jan 5 18:26:18 2018 +0000

    Fix regression: cannot start with LD_PRELOAD=libSegFault.so (PR gdb/18653#c7)
    
    At https://sourceware.org/bugzilla/show_bug.cgi?id=18653#c7, Andrew
    reports that the fix for PR gdb/18653 made GDB useless if you preload
    libSegFault.so, because GDB internal-errors on startup:
    
     $ LD_PRELOAD=libSegFault.so gdb
     src/gdb/common/signals-state-save-restore.c:64: internal-error: unexpected signal handler
     A problem internal to GDB has been detected,
     further debugging may prove unreliable.
     Aborted (core dumped)
     $
    
    The internal error comes from the code saving the signal dispositions
    inherited from gdb's parent:
    
     (top-gdb) bt
     #0  0x000000000056b001 in internal_error(char const*, int, char const*, ...) (file=0xaf5f38 "src/gdb/common/signals-state-save-restore.c", line=64, fmt=0xaf5f18 "unexpected signal handler") at src/gdb/common/errors.c:54
     #1  0x00000000005752c9 in save_original_signals_state() () at src/gdb/common/signals-state-save-restore.c:64
     #2  0x00000000007425de in captured_main_1(captured_main_args*) (context=0x7fffffffd860)
         at src/gdb/main.c:509
     #3  0x0000000000743622 in captured_main(void*) (data=0x7fffffffd860) at src/gdb/main.c:1145
     During symbol reading, cannot get low and high bounds for subprogram DIE at 24065.
     #4  0x00000000007436f9 in gdb_main(captured_main_args*) (args=0x7fffffffd860) at src/gdb/main.c:1171
     #5  0x0000000000413acd in main(int, char**) (argc=1, argv=0x7fffffffd968) at src/gdb/gdb.c:32
    
    This commit downgrades the internal error to a warning.  You'll get
    instead:
    
    ~~~
     $ LD_PRELOAD=libSegFault.so gdb
     warning: Found custom handler for signal 11 (Segmentation fault) preinstalled.
     Some signal dispositions inherited from the environment (SIG_DFL/SIG_IGN)
     won't be propagated to spawned programs.
     GNU gdb (GDB) 8.0.50.20171213-git
     Copyright (C) 2017 Free Software Foundation, Inc.
     License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
     This is free software: you are free to change and redistribute it.
     There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
     and "show warranty" for details.
     This GDB was configured as "x86_64-pc-linux-gnu".
     Type "show configuration" for configuration details.
     For bug reporting instructions, please see:
     <http://www.gnu.org/software/gdb/bugs/>.
     Find the GDB manual and other documentation resources online at:
     <http://www.gnu.org/software/gdb/documentation/>.
     For help, type "help".
     Type "apropos word" to search for commands related to "word"...
     (gdb)
    ~~~
    
    This also moves the location where save_original_signals_state is
    called a bit further below (to after option processing), so that "-q"
    disables the warning:
    
    ~~~
     $ LD_PRELOAD=libSegFault.so gdb -q
     (gdb)
    ~~~
    
    New testcase included.
    
    gdb/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/18653
    	* common/signals-state-save-restore.c
    	(save_original_signals_state): New parameter 'quiet'.  Warn if we
    	find a custom handler preinstalled, instead of internal erroring.
    	But only warn if !quiet.
    	* common/signals-state-save-restore.h
    	(save_original_signals_state): New parameter 'quiet'.
    	* main.c (captured_main_1): Move save_original_signals_state call
    	after option handling, and pass QUIET.
    
    gdb/gdbserver/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/18653
    	* server.c (captured_main): Pass quiet=false to
    	save_original_signals_state.
    
    gdb/testsuite/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/18653
    	* gdb.base/libsegfault.exp: New.

commit a655456c134e5e02bab33941e1c738ca33905d23
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Jan 5 17:56:33 2018 +0000

    Fix gdb/spu-tdep.c build breakage
    
    Commit de63c46b549d ("Fix regresssion(internal-error) printing
    subprogram argument (PR gdb/22670)") missed updating spu-tdep.c for
    the block_lookup_symbol interface change, resulting in:
    
      ../../binutils-gdb/gdb/spu-tdep.c: In function void spu_catch_start(objfile*):
      ../../binutils-gdb/gdb/spu-tdep.c:1969:59: error: cannot convert domain_enum_tag to symbol_name_match_type for argument 3 to symbol* block_lookup_symbol(const block*, const char*, symbol_name_match_type, domain_enum)
    	 sym = block_lookup_symbol (block, "main", VAR_DOMAIN);
    							     ^
    
    gdb/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	* spu-tdep.c (spu_catch_start): Pass
    	symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.

commit de63c46b549d1cf4f7851e47872cb759a12983f4
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Jan 5 14:04:09 2018 +0000

    Fix regresssion(internal-error) printing subprogram argument (PR gdb/22670)
    
    At <https://sourceware.org/ml/gdb-patches/2017-12/msg00298.html>, Joel
    wrote:
    
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Consider the following code which first declares a tagged type (the
    equivalent of a class in Ada), and then a procedure which takes a
    pointer (access) to this type's 'Class.
    
        package Pck is
           type Top_T is tagged record
              N : Integer := 1;
           end record;
           procedure Inspect (Obj: access Top_T'Class);
        end Pck;
    
    Putting a breakpoint in that procedure and then running to it triggers
    an internal error:
    
        (gdb) break inspect
        (gdb) continue
        Breakpoint 1, pck.inspect (obj=0x63e010
        /[...]/gdb/stack.c:621: internal-error: void print_frame_args(symbol*, frame_info*, int, ui_file*): Assertion `nsym != NULL' failed.
    
    What's special about this subprogram is that it takes an access to
    what we call a 'Class type, and for implementation reasons, the
    compiler adds an extra argument named "objL". If you are curious why,
    it allows the compiler for perform dynamic accessibility checks that
    are mandated by the language.
    
    If we look at the location where we get the internal error (in
    stack.c), we find that we are looping over the symbol of each
    parameter, and for each parameter, we do:
    
        /* We have to look up the symbol because arguments can have
           two entries (one a parameter, one a local) and the one we
           want is the local, which lookup_symbol will find for us.
        [...]
            nsym = lookup_symbol (SYMBOL_LINKAGE_NAME (sym),
                                  b, VAR_DOMAIN, NULL).symbol;
            gdb_assert (nsym != NULL);
    
    The lookup_symbol goes through the lookup structure, which means the
    symbol's linkage name ("objL") gets transformed into a
    lookup_name_info object (in block_lookup_symbol), before it gets fed
    to the block symbol dictionary iterators.  This, in turn, triggers the
    symbol matching by comparing the "lookup" name which, for Ada, means
    among other things, lowercasing the given name to "objl".  It is this
    transformation that causes the lookup find no matches, and therefore
    trip this assertion.
    
    Going back to the "offending" call to lookup_symbol in stack.c, what
    we are trying to do, here, is do a lookup by linkage name.  So, I
    think what we mean to be doing is a completely literal symbol lookup,
    so maybe not even strcmp_iw, but actually just plain strcmp???
    
    In the past, in practice, you could get that effect by doing a lookup
    using the C language. But that doesn't work, because we still end up
    somehow using Ada's lookup_name routine which transforms "objL".
    
    So, ideally, as I hinted before, I think what we need is a way to
    perform a literal lookup so that searches by linkage names like the
    above can be performed.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    This commit fixes the problem by implementing something similar to
    Joel's literal idea, but with some important differences.
    
    I considered adding a symbol_name_match_type::LINKAGE and supporting
    searching by linkage name for any language, but the problem with that
    is that the dictionaries only work with SYMBOL_SEARCH_NAME, because
    that's what is used for hashing.  We'd need separate dictionaries for
    hashed linkage names.
    
    So with the current symbol tables infrastructure, it's not literal
    linkage names that we want to pass down, but instead literal _search_
    names (SYMBOL_SEARCH_NAME, etc.).
    
    However, psymbols have no overload/function parameter info in C++, so
    a straight strcmp doesn't work properly for C++ name matching.
    
    So what we do is be a little less aggressive then and add a new
    symbol_name_match_type::SEARCH_SYMBOL instead that takes as input a
    non-user-input search symbol, and then we skip any decoding/demangling
    steps and make:
    
     - Ada treat that as a verbatim match,
     - other languages treat it as symbol_name_match_type::FULL.
    
    This also fixes the new '"maint check-psymtabs" for Ada' testcase for
    me (gdb.ada/maint_with_ada.exp).  I've not removed the kfail yet
    because Joel still sees that testcase failing with this patch.
    That'll be fixed in follow up patches.
    
    gdb/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* ada-lang.c (literal_symbol_name_matcher): New function.
    	(ada_get_symbol_name_matcher): Use it for
    	symbol_name_match_type::SEARCH_NAME.
    	* block.c (block_lookup_symbol): New parameter 'match_type'.  Pass
    	it down instead of assuming symbol_name_match_type::FULL.
    	* block.h (block_lookup_symbol): New parameter 'match_type'.
    	* c-valprint.c (print_unpacked_pointer): Use
    	lookup_symbol_search_name instead of lookup_symbol.
    	* compile/compile-object-load.c (get_out_value_type): Pass down
    	symbol_name_match_type::SEARCH_NAME.
    	* cp-namespace.c (cp_basic_lookup_symbol): Pass down
    	symbol_name_match_type::FULL.
    	* cp-support.c (cp_get_symbol_name_matcher): Handle
    	symbol_name_match_type::SEARCH_NAME.
    	* infrun.c (insert_exception_resume_breakpoint): Use
    	lookup_symbol_search_name.
    	* p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
    	* psymtab.c (maintenance_check_psymtabs): Use
    	symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
    	* stack.c (print_frame_args): Use lookup_symbol_search_name and
    	SYMBOL_SEARCH_NAME.
    	* symtab.c (lookup_local_symbol): Don't demangle the lookup name
    	if symbol_name_match_type::SEARCH_NAME.
    	(lookup_symbol_in_language): Pass down
    	symbol_name_match_type::FULL.
    	(lookup_symbol_search_name): New.
    	(lookup_language_this): Pass down
    	symbol_name_match_type::SEARCH_NAME.
    	(lookup_symbol_aux, lookup_local_symbol): New parameter
    	'match_type'.  Pass it down.
    	* symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
    	(lookup_symbol_search_name): New declaration.
    	(lookup_symbol_in_block): New 'match_type' parameter.
    
    gdb/testsuite/ChangeLog:
    2018-01-05  Joel Brobecker  <brobecker@adacore.com>
    
    	PR gdb/22670
    	* gdb.ada/access_tagged_param.exp: New file.
    	* gdb.ada/access_tagged_param/foo.adb: New file.

commit f98fc17b3ac4750842ec0fe28a18b51691ddfbda
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Jan 5 16:01:57 2018 +0000

    Fix gdb.ada/info_addr_mixed_case.exp (PR gdb/22670)
    
    The comments about mixed case in the testcase are actually a red
    herring.  The problem here is that we'd get to
    ada_lookup_encoded_symbol with "my_table", which wraps the looked up
    name in "<>"s to force a verbatim match, and that in turn disables
    wild matching.
    
    Fix this by swapping around the internals of ada_lookup_encoded_symbol
    and ada_lookup_symbol, thus avoiding the encoding and
    verbatim-wrapping in the ada_lookup_symbol case, the case that starts
    with a user-provided lookup name.
    
    Ada encoding is still done of course, in the ada_lookup_name_info
    ctor.  This could be also seen as avoiding the double-encoding problem
    in a different way.
    
    gdb/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
    	ada_lookup_symbol.
    	(ada_lookup_symbol): Reimplement in terms of
    	ada_lookup_symbol_list, bits factored out from
    	ada_lookup_encoded_symbol.
    
    gdb/testsuite/ChangeLog:
    2018-01-05  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22670
    	* gdb.ada/info_addr_mixed_case.exp: Remove kfail.  Extend test to
    	exercise lower case too, and to exercise both full matching and
    	wild matching.

commit 342f82403949c74517a6353baec73b94d18549ad
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Jan 5 04:29:54 2018 -0500

    (Ada) problem printing renaming which references a subprogram parameter
    
    Consider the following code, which creates a local variable B
    which is a renaming whose expression references a subprogram
    parameter:
    
       procedure Flip (Bits : in out Bits_Type; I : Natural) is
       begin
          declare
             B : Boolean renames Bits (I);
          begin
             B := not B; -- BREAK
          end;
       end Flip;
    
    Trying to print the value of B when at the "BREAK" line currently
    does not work:
    
        (gdb) p b
        Could not find i
    
    What happens is the following: For the renaming, GNAT generates
    a variable whose name is encoded as follow:
    
        b___XR_bits___XEXSi
    
    GDB properly detects that variable, determines that, to compute
    the variable's value, we start from the symbol "Bits", which
    we then have to subscript (XS) using 'i' as the index. The error
    occurs while trying to find 'i'.
    
    This is because we forgot to pass the block in the call to
    ada_lookup_encoded_symbol, which this patch fixes.
    
    gdb/ChangeLog:
    
            * ada-exp.y (write_object_renaming): When subscripting an array
            using a symbol as the index, pass the block in call to
            ada_lookup_encoded_symbol when looking that symbol up.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/rename_subscript_param: New testcase.
    
    Tested on x86_64-linux.
    
    Note: This requires the following GCC patch:
    
      | 2017-04-25  Pierre-Marie de Rodat  <derodat@adacore.com>
      |
      | * exp_dbug.adb: In Debug_Renaming_Declaration,
      | when dealing with indexed component, accept to produce a renaming
      | symbol when the index is an IN parameter or when it is a name
      | defined in an outer scope.

commit 7150d33cda60fd543e9d9d68eb58d4e6155fb878
Author: Jerome Guitton <guitton@adacore.com>
Date:   Fri Jan 5 03:03:59 2018 -0500

    (Ada) Fix Length attribute on array access
    
    Consider the following variable "Indexed_By_Enum", declared as
    an access to an array whose index type is an enumerated type
    whose underlying values have "gaps":
    
       type Enum_With_Gaps is (LIT0, LIT1, LIT2, LIT3, LIT4);
       for Enum_With_Gaps use (LIT0 => 3,
                               LIT1 => 5,
                               LIT2 => 8,
                               LIT3 => 13,
                               LIT4 => 21);
       for Enum_With_Gaps'size use 16;
    
       type MyWord is range 0 .. 16#FFFF# ;
       for MyWord'Size use 16;
    
       type AR is array (Enum_With_Gaps range <>) of MyWord;
       type AR_Access is access AR;
    
       Indexed_By_Enum : AR_Access :=
         new AR'(LIT1 => 1,  LIT2 => 43, LIT3 => 42, LIT4 => 41);
    
    Trying to print the length (number of elements) of this array using
    the 'Length attribute does not work:
    
        (gdb) print indexed_by_enum'length
        'POS only defined on discrete types
    
    The problem occurs while trying to get the array's index type.
    It was using TYPE_INDEX_TYPE for that. It does not work for Ada arrays
    in general; use ada_index_type instead.
    
    gdb/ChangeLog:
    
    	* ada-lang.c (ada_array_length): Use ada_index_type instead of
    	TYPE_INDEX_TYPE.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/arr_acc_idx_w_gap: New testcase.
    
    Tested on x86_64-linux.

commit cc0e770c0d00acececc43826f4673896d09b3dff
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Jan 5 02:37:38 2018 -0500

    memory error printing component of record from convenience variable
    
    Consider the following situation Ada code:
    
       type Kind_T is (One, Two, Three);
       type Time_Set_T is array (Kind_T) of Integer;
    
       type T  is record
          Started    : Time_Set_T;
       end record;
    
       Null_T : constant T := (Started => (others => 0));
    
       My_Item : Pck.T := Pck.Null_T;
    
    Trying to print the value of My_Item.Started is no problem:
    
        (gdb) p item.started
        $1 = (0, 0, 0)
    
    However, if you save My_Item into a convenience variable first,
    and then try to print a component of that record, you get
    an unexpected memory error, instead of getting the same result.
    For instance:
    
        (gdb) set variable $item := item
        (gdb) p $item.started
        Cannot access memory at address 0x0
    
    The issue occurs when, after we extracted the component from
    the convenience variable, we next try to "fix" it (which is
    ada-lang speak for resolving the type into a static type).
    This is done in ada_to_fixed_value, which delegates to
    ada_to_fixed_value_create via:
    
        val = ada_to_fixed_value_create (value_type (val),
                                         value_address (val), val);
    
    And looking at ada_to_fixed_value_create, we see that:
    
      struct type *type = ada_to_fixed_type (type0, 0, address, NULL, 1);
    
      if (type == type0 && val0 != NULL)
        return val0;
      else
        return value_from_contents_and_address (type, 0, address);
    
    The part that interests us, in this case, is the "else" branch,
    where we obviously make the implicit assumption that our object
    has an address, which is not true, in this case, because we are
    actually dealing with a convenience variable.
    
    This patch plugs that hole by adding special handing for situations
    where val does not live in memory. In that case, we just create
    a not_lval value using val's contents.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_to_fixed_value_create): Add handling of
            the case where VALUE_LVAL (val0) is not lval_memory.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/convvar_comp: New testcase.
    
    Tested on x86_64-linux.

commit f79da888eb68d5add4eaa7f336923cad95367335
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Jan 5 02:39:10 2018 -0500

    fix date of latest gdb/ChangeLog entry

commit 672a41aa12fb24fe24dbf52d2e78a3a846dc0225
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Jan 4 23:51:55 2018 -0500

    Fix email address in latest gdb/testsuite/ChangeLog entry

commit e3861a03138e24e7f2f0e8c4982bdad2a6e1dbaf
Author: Xavier Roirand <roirand@adacore.com>
Date:   Thu Jan 4 23:47:05 2018 -0500

    (Ada) Remove printing of array's first index when unneeded
    
    Consider the following code:
    
      type Table is array (Character) of Natural;
      My_Table : Table := (others => 4874);
    
    Printing this table in gdb leads to:
    
      (gdb) p my_table
      $1 = ('["00"]' => 4874 <repeats 256 times>)
    
    In this case, the index of the first element in this array is also
    the first element of the index type (character type). Similar to what
    we do we enumeration types, we do not need to print the index of the
    first element when printing the array.
    
    This patch fixes this issue and changes the output as follow:
    
      (gdb) p my_table
      $1 = (4874 <repeats 256 times>)
    
    gdb/ChangeLog:
    
            * ada-valprint.c (print_optional_low_bound): Handle
            character-indexed array printing like boolean-indexed array
            printing.
    
    gdb/testuite/ChangeLog:
    
            * testsuite/gdb.ada/array_char_idx/pck.ads (Table): New type.
            (My_Table): New global variable.
            * testsuite/gdb.ada/array_char_idx.exp: Add test.
    
    Tested on x86_64-linux.

commit cd385f94a7888b619c84e9ab007bac5093c5e894
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Jan 5 08:18:05 2018 +0400

    Update NEWS post GDB 8.1 branch creation.
    
    gdb/ChangeLog:
    
    	* NEWS: Create a new section for the next release branch.
    	Rename the section of the current branch, now that it has
    	been cut.

commit 09aca9495c4794e586680f359e612ece173148ec
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Jan 5 08:08:09 2018 +0400

    Bump version to 8.1.50.DATE-git.
    
    Now that the GDB 8.1 branch has been created, we can
    bump the version number.
    
    gdb/ChangeLog:
    
    	GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
    	* version.in: Bump version to 8.1.50.DATE-git.

commit 5219ac6237c272b938c28517bf371429260c71e7
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jan 5 00:00:35 2018 +0000

    Automatic date update in version.in

commit 645a2c5b46e18013ac9cb16b66ba7b6b97cd01c5
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Jan 4 14:17:53 2018 -0800

    RISC-V: Add 2 missing privileged registers.
    
    	gas/
    	* testsuite/gas/riscv/priv-reg.s: Add missing stval and mtval.
    	* testsuite/gas/riscv/priv-reg.d: Likewise.
    
    	include/
    	* opcode/riscv-opc.h (CSR_SBADADDR): Rename to CSR_STVAL.  Rename
    	DECLARE_CSR entry.  Add alias to map sbadaddr to CSR_STVAL.
    	(CSR_MBADADDR): Rename to CSR_MTVAL.  Rename DECLARE_CSR entry.
    	Add alias to map mbadaddr to CSR_MTVAL.

commit 7365ec2ff4a7028503f39655bd2628d54418106c
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Jan 4 04:40:17 2018 -0500

    gdb.ada/maint_with_ada.exp: New testcase
    
    This commit adds a new testcase testing the "check-psymtabs" and
    "check-symtabs" maintenance commands.
    
    The "maintenance check-psymtabs" commands is currently known to
    produce some errors. While the situation was admetedly made worse
    by the following patch...
    
        commit b5ec771e60c1a0863e51eb491c85c674097e9e13
        Date:   Wed Nov 8 14:22:32 2017 +0000
        Subject: Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    ... hence the reference to PR gdb/22670, the command was already
    spotting one inconsistency prior to it:
    
        (gdb) maintenance check-psymtabs
        Global symbol `interfaces__cS' only found in /[...]/b~var_arr_typedef.adb psymtab
    
    For now, the "check-psymtab" test is KFAIL-ed.
    
    gdb/testsuite/ChangeLog:
    
            PR gdb/22670
            * gdb.ada/maint_with_ada: New testcase.
    
    Tested on x86_64-linux.

commit 289483b6a06c7a24ee9ae9021d2728ca4700b7a6
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Jan 4 03:10:34 2018 -0500

    Add new gdb.ada/bp_c_mixed_case testcase for PR gdb/22670
    
    This patch adds a new testcase to demonstrate a regression introduced by:
    
        commit b5ec771e60c1a0863e51eb491c85c674097e9e13
        Date:   Wed Nov 8 14:22:32 2017 +0000
        Subject: Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    The purpose of the testcase is to verify that a user can insert
    a breakpoint on a C function while debugging Ada, even if the name
    of the function includes uppercase letters, requiring us to use
    Ada's "<...>" notation to tell the GDB that the symbol name should
    be looked up verbatim.
    
    As of the commit above, GDB is no longer finding the function:
    
        (gdb) break <MixedCaseFunc>
        Function "<MixedCaseFunc>" not defined.
        Make breakpoint pending on future shared library load? (y or [n])
    
    Before the patch, the breakpoint was inserted without problem.
    
    gdb/testsuite/ChangeLog:
    
            PR gdb/22670
            * gdb.ada/bp_c_mixed_case: New testcase.
    
    Tested on x86_64-linux; generates a KPASS before the regression
    was introduced, and now generates a KFAIL.

commit 344420da6beac1e0b2f7964e7101f8dcdb509b0d
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Jan 4 02:39:58 2018 -0500

    Add "complete break ada" test to gdb.ada/complete.exp
    
    This patch adds a new test to demonstrate a regression introduced by:
    
        commit b5ec771e60c1a0863e51eb491c85c674097e9e13
        Date:   Wed Nov 8 14:22:32 2017 +0000
        Subject: Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    The original purpose of the new test is to exercise the "complete"
    command with an expression for which a large number of matches are
    returned and to verify that each match returned is a plausible match.
    In this particular case, the commit above causes GDB to generate
    additional matches which should in fact not appear in the list
    (internally generated symbols, or symbols that should be enclosed
    between "<...>"). These extraneous entries are easy to spot, because
    they have uppercase characters, such as:
    
        break ada__stringsS
        break ada__strings__R11s
        [etc]
    
    For now, the new test is KFAIL'ed, to avoid generating a new FAIL
    while we work on fixing that regression.
    
    gdb/testsuite/ChangeLog:
    
            PR gdb/22670
            * gdb.ada/complete.exp: Add "complete break ada" test.
    
    Tested on x86_64-linux with GDB built before and after the patch
    that caused the regression (b5ec771e60c1a0863e51eb491c85c674097e9e13).
    The test passes before the regression, and generates a KFAIL after.

commit 66fc87a0d50d2b91322cc24d17461c07925fa867
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Jan 3 23:28:14 2018 -0500

    Add gdb.ada/info_addr_mixed_case new testcase
    
    This patch adds a new testcase to demonstrate a regression introduced by:
    
        commit b5ec771e60c1a0863e51eb491c85c674097e9e13
        Date:   Wed Nov 8 14:22:32 2017 +0000
        Subject: Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    The purpose of the testcase is to verify that a user can use any
    casing for an Ada symbol name passed to the "info address" command.
    After the patch above was applied, GDB was no longer able to find
    the symbol:
    
        (gdb) info address My_Table
        No symbol "My_Table" in current context.
    
    gdb/testsuite/ChangeLog:
    
    	PR gdb/22670
    	* gdb.ada/info_addr_mixed_case: New testcase.
    
    Tested on x86_64-linux, both before and after the patch.

commit c40d7e49cf0a6842a5cf072772a48d1f6e6eeb11
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jan 4 00:00:20 2018 +0000

    Automatic date update in version.in

commit ddb2bbcf0624ef5f75c0a007c6b192c09b6fa70b
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jan 3 12:06:26 2018 -0800

    Create pseudo sections for FreeBSD NT_PROCSTAT_(PROC|FILES|VMMAP) notes.
    
    bfd/ChangeLog:
    
    	* elf.c (elfcore_grok_freebsd_note): Handle
    	NT_FREEBSD_PROCSTAT_PROC, NT_FREEBSD_PROCSTAT_FILES, and
    	NT_FREEBSD_PROCSTAT_VMMAP.

commit f13974bda3d53e47b7fe5a358e963073184ba17e
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jan 3 17:32:59 2018 +0000

    Fix compile time warning introduced by previous delta.
    
    	* objcopy.c (merge_gnu_build_notes): Add cast to maximum address
    	constants.

commit 6f156d7a4ad1c245b357dc50f63f3564d397839e
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jan 3 10:28:33 2018 +0000

    Add support for v3 binary annotation notes.
    
      I am checking in the attached patch which updates the binutils
      support for version 3 binary annotation notes.  (Version 3 adds
      an end address to the ranges covered by the notes, so that it
      is possible to detect gaps in the coverage).
    
      This patch also stops the note merging feature of objcopy from
      executing if the notes have relocations against them.  This makes the
      code simpler, and prevents the problems with architectures which have
      unusual relocation management issues.
    
    	* objcopy.c (objcopy_internal_note): New structure.
    	(gap_exists): New function.
    	(is_open_note): New function.
    	(is_func_note): New function.
    	(is_64bit): New function.
    	(merge_gnu_build_notes): Handle v3 notes.  Do not merge
    	if there are relocations against the notes.
    	* readelf.c (get_note_type): Use short names for build attribute
    	notes.
    	(print_symbol_for_build_attribute): Rename to
    	get_symbol_for_build_attribute.  Returns the found symbol rather
    	than printing it.
    	(print_gnu_build_attribute_description): Maintain address ranges
    	for function notes as well as global notes.  Handle v3 notes.
    	(print_gnu_build_attribute_name): Use more space for printing the
    	name in wide mode.
    	* testsuite/binutils-all/note-2-32.s: Use .dc.l instead of .word.
    	Eliminate symbol references in order to remove the need for
    	relocations.
    	* testsuite/binutils-all/note-2-64.s: Likewise.
    	* testsuite/binutils-all/note-3-32.s: Add a size to the note_1
    	symbol.
    	* testsuite/binutils-all/note-3-64.s: Likewise.
    	* testsuite/binutils-all/mips/mips-note-2r-n32.d: Update expected
    	output.
    	* testsuite/binutils-all/mips/mips-note-2r-n64.d: Likewise.
    	* testsuite/binutils-all/mips/mips-note-2r.d: Likewise.
    	* testsuite/binutils-all/note-2-32.d: Likewise.
    	* testsuite/binutils-all/note-2-64.d: Likewise.
    	* testsuite/binutils-all/note-3-32.d: Likewise.
    	* testsuite/binutils-all/note-3-64.d: Likewise.
    	* testsuite/binutils-all/note-4-64.s: New test.  Checks v3 notes.
    	* testsuite/binutils-all/note-4-32.s: New test.
    	* testsuite/binutils-all/note-4-64.d: New test result file.
    	* testsuite/binutils-all/note-4-32.d: New test result file.

commit 9f757bf7fcb8834ead780e0c4a76d6029b1402c2
Author: Xavier Roirand <roirand@adacore.com>
Date:   Wed Nov 22 10:40:39 2017 +0100

    (Ada) New command to stop at start of exception handler.
    
    When using gdb for debugging Ada source code, there are several catchpoint
    types you can define in order to stop upon certain conditions.  Let's
    use this small example:
    
    procedure Foo is
    begin
       begin
          raise Constraint_Error;
       exception
          when Program_Error =>
             null;
          when Constraint_Error =>
             null;
          when others =>
             null;
       end;
    end Foo;
    
    One can stop when the exception is being raised by using the exception
    catchpoint like below:
    
    (gdb) catch exception
    Catchpoint 1: all Ada exceptions
    (gdb)
    
    In that case, when running Foo, gdb will stop at the line where the exception
    was raised:
    
       begin
    >>>   raise Constraint_Error;
       exception
    
    This patch introduces new type of catchpoint, when the user wants to stop
    at the location of the exception handling.
    Imagine we want to stop on any exception handled by the program, we can do:
    
    (gdb) catch handlers
    Catchpoint 1: all Ada exceptions handlers
    (gdb) r
    Starting program: /tmp/foo
    
    By doing so, when running Foo, gdb will stop here:
    
    Catchpoint 1, exception at 0x000000000040255a in foo () at foo.adb:25
    25          when Constraint_Error =>
    (gdb)
    
    It is also possible to stop when the Constraint_Error exception is being
    handled in this program.  With this patch, we can use:
    
    (gdb) catch handlers Constraint_Error
    Catchpoint 1: `Constraint_Error' Ada exception handlers
    (gdb)
    
    Like for other catchpoint, you can set a condition when adding a catchpoint
    on exception handlers.
    Here the handlers catchpoint checks Global_Var:
    
    (gdb) catch handlers Constraint_Error if Global_Var /= 0
    
    gdb/ChangeLog:
    
            * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
            Add field.
            * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
            Add field.
            (default_exception_support_info) <catch_handlers_sym>: Add field.
            (exception_support_info_fallback) <catch_handlers_sym>: Add field.
            (ada_exception_name_addr_1): Add "catch handlers" handling.
            (ada_exception_catchpoint_cond_string) <ex>: New parameter.
            Update all callers.
            (create_excep_cond_exprs) <ex>: Add parameter.
            (re_set_exception): Update create_excep_cond_exprs call.
            (print_it_exception, print_one_exception, print_mention_exception)
            (print_recreate_exception): Add "catch handler" handling.
            (allocate_location_catch_handlers, re_set_catch_handlers)
            (check_status_catch_handlers, print_it_catch_handlers)
            (print_one_catch_handlers, print_mention_catch_handlers)
            (print_recreate_catch_handlers): New function.
            (catch_handlers_breakpoint_ops): New variable.
            (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
            Add parameter.  Add "catch handler" handling.
            (ada_exception_sym_name, ada_exception_breakpoint_ops):
            Add "catch handler" handling.
            (ada_exception_catchpoint_cond_string): Add "catch handler"
            handling.
            (create_ada_exception_catchpoint): Update create_excep_cond_exprs
            call.
            (catch_ada_handlers_command): New function.
            (initialize_ada_catchpoint_ops): Initialize "catch handlers"
            operations structure.
            (_initialize_ada_language): Add "catch handlers" command entry.
            * NEWS: Document "catch handlers" feature.
    
    gdb/doc/ChangeLog:
    
            * gdb.texinfo (Set Catchpoints): Add documentation for new
            "catch handlers" action.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/excep_handle.exp: New testcase.
            * gdb.ada/excep_handle/foo.adb: New file.
            * gdb.ada/excep_handle/pck.ads: New file.
    
    Tested on x86_64-linux.

commit 219d1afa89d0d53ca93a684cac341f16470f3ca0
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Jan 3 15:47:27 2018 +1030

    Update year range in copyright notice of binutils files

commit 1e563868718a69231c80a1d86698cee0cf847e72
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Jan 3 15:45:17 2018 +1030

    ChangeLog rotation

commit bd570f80f6e47c93f4b1cc1e94688cdde33ca931
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Jan 3 07:50:38 2018 +0400

    Unbreak spurious fails in gdb.base/step-line.exp
    
    My copyright year update in the copyright headers of the step-line
    testcase caused it to start failing, due to shift in line numbers.
    
        FAIL: gdb.base/step-line.exp: continue to f1
        FAIL: gdb.base/step-line.exp: next to dummy 2
        FAIL: gdb.base/step-line.exp: next over dummy 2
        FAIL: gdb.base/step-line.exp: step into f2
        FAIL: gdb.base/step-line.exp: next over dummy 4
        FAIL: gdb.base/step-line.exp: next to dummy 5
        FAIL: gdb.base/step-line.exp: next to dummy 6
        FAIL: gdb.base/step-line.exp: next over dummy 6
        FAIL: gdb.base/step-line.exp: next to dummy 7
        FAIL: gdb.base/step-line.exp: next to dummy 8
        FAIL: gdb.base/step-line.exp: next over dummy 8
        FAIL: gdb.base/step-line.exp: next to dummy 9
        FAIL: gdb.base/step-line.exp: next to dummy 10
        FAIL: gdb.base/step-line.exp: next over dummy 10
    
    This was caused by the copyright.py script after I changed it to
    also update this testcase, which made the following transformation:
    
        -   Copyright (C) 2001-2017
        -   Free Software Foundation, Inc.
        +   Copyright (C) 2001-2018 Free Software Foundation, Inc.
    
    We can easily unbreak the testcase without having to go back to
    manual edits each year by adding an extra line in the header.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/step-line.c: Add extra empty line in copyright header.
            * gdb.base/step-line.inp: Likewise.
    
    Tested on x86_64-linux.

commit 39f2fa1b0fdfd1b15f3d381c4fc4359c9733e657
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jan 3 00:00:31 2018 +0000

    Automatic date update in version.in

commit 43724d16bebb38fe6794f6a3741352a7698038de
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jan 2 17:15:16 2018 +0000

    Fix compile time warning (in the ARM simulator) about a print statement with insufficient arguments.
    
    	PR 22663
    	* maverick.c (DSPCDP4): Add missing parameter to debug print
    	statement.

commit 806ab1c045c4cbb5c906f79bcb2e0c3058f4c6fd
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jan 2 12:13:17 2018 +0000

    Fix typo in do_mrs function in ARM assembler.
    
    	PR 18119
    	* config/tc-arm.c (do_mrs): Fix test of bits 16-19 in non-banked
    	version of ARM MRS instruction.

commit 1508bbf535b03e3b9105d01a9e19f29f131b3d1a
Author: Jan Beulich <jbeulich@novell.com>
Date:   Tue Jan 2 11:44:04 2018 +0100

    x86: partial revert of 10c17abdd0
    
    Other than the variables in tc-i386.c using them, OPERAND_TYPE_REGYMM
    and OPERAND_TYPE_REGZMM they aren't entirely unused. No need to update
    i386-init.h though, as it mistakenly wasn't updated by the original
    commit.

commit 9fe561ab7fc5ee3a06061dae6909cd61b49435df
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 22:53:55 2018 -0500

    [gdb/Ada] slices of arrays with dynamic strides
    
        Consider the following Ada code:
    
           procedure Nested (L, U : Integer) is
              subtype Small_Type is Integer range L .. U;
              type Record_Type (I : Small_Type := L) is record
                 S : String (1 .. I);
              end record;
              type Array_Type is array (Integer range <>) of Record_Type;
    
              A1 : Array_Type :=
                (1 => (I => 0, S => <>),
                 2 => (I => 1, S => "A"),
                 3 => (I => 2, S => "AB"));
    
              procedure Discard (R : Record_Type) is
              begin
                 null;
              end Discard;
    
           begin
              Discard (A1 (1));  -- STOP
           end;
    
    Trying to print a slice of that array currently yields:
    
        (gdb) p a1(1..3)
        $1 = ((i => 0, s => ""), (i => 0, s => ""), (i => 0, s => ""))
    
    We expected instead:
    
        (gdb) p a1(1..3)
        $1 = ((i => 0, s => ""), (i => 1, s => "A"), (i => 2, s => "AB"))
    
    This is because the functions we use in ada-lang.c to create the type
    of the array slice (ada_value_slice and ada_value_slice_from_ptr) was
    not taking into account the stride of the array. This patch fixes this.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
            account when creating the array type of the slice.
            (ada_value_slice): Likewise.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/dyn_stride.exp: Add slice test.
    
    Note that, with the current use of ada_value_slice, the enhancement
    to handle dynamic array strides seems unnecessary, because I do not
    see how an array with a dynamic stride can be referenced by either
    by reference or pointer. Since references are coerced to array pointers,
    in both cases, the slice is performed by ada_value_slice_from_ptr.
    But ada_value_slice is enhanced nonetheless, in the spirit of making
    the code more robust, in case we missed something, and also as similar
    as possible with its from_ptr counterpart.
    
    tested on x86_64-linux.

commit a405673cc5b56c260de4e1202cead709d1a4f24c
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 22:47:18 2018 -0500

    Add support for dynamic DW_AT_byte_stride.
    
    This patch adds support for DW_AT_byte_stride, using Ada as one
    example of where this would be useful. However, the implementation
    is language-agnostic.
    
    Consider the following Ada code:
    
       procedure Nested (L, U : Integer) is
          subtype Small_Type is Integer range L .. U;
          type Record_Type (I : Small_Type := L) is record
             S : String (1 .. I);
          end record;
          type Array_Type is array (Integer range <>) of Record_Type;
    
          A1 : Array_Type :=
            (1 => (I => 0, S => <>),
             2 => (I => 1, S => "A"),
             3 => (I => 2, S => "AB"));
    
          procedure Discard (R : Record_Type) is
          begin
             null;
          end Discard;
    
       begin
          Discard (A1 (1));  -- STOP
       end;
    
    It defines an array A1 of Record_Type, which is a variant record
    type whose maximum size actually depends on the value of the
    parameters passed when calling Nested. As a result, the stride
    of the array A1 cannot be known statically, which leads the compiler
    to generate a dynamic DW_AT_byte_stride attribute for our type.
    Here is what the debugging info looks like with GNAT:
    
            .uleb128 0x10   # (DIE (0x14e) DW_TAG_array_type)
            .long   .LASF17 # DW_AT_name: "foo__nested__T18b"
            .long   0x141   # DW_AT_byte_stride
            .long   0xdc    # DW_AT_type
            .uleb128 0x11   # (DIE (0x15f) DW_TAG_subrange_type)
            .long   0x166   # DW_AT_type
            .byte   0x3     # DW_AT_upper_bound
            .byte   0       # end of children of DIE 0x14e
    
    There DW_AT_byte_stride is a reference to a local (internal)
    variable:
    
            .uleb128 0x9    # (DIE (0x141) DW_TAG_variable)
            .long   .LASF6  # DW_AT_name: "foo__nested__T18b___PAD___XVZ"
    
    This patch enhances GDB to handle this dynamic byte stride attribute
    by first adding a new dynamic_prop_node_kind (DYN_PROP_BYTE_STRIDE)
    to store the array dynamic stride info (when dynamic). It then enhances
    the dynamic type resolver to handle this dynamic property.
    
    Before applying this patch, trying to print the value of some of
    A1's elements after having stopped at the "STOP" comment does not
    work. For instance:
    
        (gdb) p a1(2)
        Cannot access memory at address 0x80000268dec0
    
    With this patch applied, GDB now prints the value of all 3 elements
    correctly:
    
        (gdb) print A1(1)
        $1 = (i => 0, s => "")
        (gdb) print A1(2)
        $2 = (i => 1, s => "A")
        (gdb) print A1(3)
        $3 = (i => 2, s => "AB")
    
    gdb/ChangeLog:
    
            * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
            New enum value.
            (create_array_type_with_stride): Add byte_stride_prop parameter.
            * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
            New parameter.  Update all callers in this file.
            (array_type_has_dynamic_stride): New function.
            (is_dynamic_type_internal, resolve_dynamic_array): Add handling
            of arrays with dynamic byte strides.
            * dwarf2read.c (read_array_type): Add support for dynamic
            DW_AT_byte_stride attributes.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/dyn_stride: New testcase.
    
    Tested on x86_64-linux.

commit 74a2f8ffb83172de1af0da6751a65c08a722986f
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 22:41:36 2018 -0500

    treat Ada DW_TAG_unspecified_type DIEs as stub types
    
    Consider the gdb.ada/taft_type.exp testcase, which exercises
    the situation where a variable is defined using a type which
    is a pointer to an incomplete type, with the actual type
    definition being provided by another unit. Up to now, the
    strategy used by GNAT when generating the DWARF debugging info
    was to produce a incomplete DW_TAG_enumeration_type DIE with
    a DW_AT_declaration flag attached to it:
    
            .uleb128 0x4    # (DIE (0x3e) DW_TAG_enumeration_type)
            .long   .LASF4  # DW_AT_name: "pck__empty"
                            # DW_AT_declaration
    
    However, a more standard way for the compiler to describe
    this kind of type is to use the DW_TAG_unspecified_type tag.
    When the compiler is enhanced to do so, we'll need to treat
    such types as stubs -- we only do so with types from Ada units,
    however, as the meaning of this TAG is intentionally left
    permissive and language-specific by the DWARF standard.
    
    Without this patch, running the testcase above with an enhanced
    compiler now yields:
    
        (gdb) print w.e.all
        Attempt to dereference a generic pointer.
        FAIL: gdb.ada/taft_type.exp: print w.e.all
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (read_unspecified_type): Treat
            DW_TAG_enumeration_type DIEs from Ada units as stubs.
    
    Tested on x86_64-linux, fixes the FAIL in gdb.ada/taft_type.exp above.

commit e2882c85786571175a0b0bfc3bcd2f14620b1ea3
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 08:43:02 2018 +0400

    Update copyright year range in all GDB files
    
    gdb/ChangeLog:
    
            Update copyright year range in all GDB files

commit 1690bb24d855c387211f7bc5a77334c11cc75f4b
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 08:18:16 2018 +0400

    gdb/copyright.py: Remove testsuite/gdb.base/step-line.{c,inp} special handling
    
    In the past, these files needed to be handled by hand, because
    the testcase was sensitive to the length of the header, which was
    potentially changing when new copyright years were added to
    the copyright header. Now that we simply maintain and update
    a range, the length of the copyright header should not change
    as a consequence of the update performed by this script, so
    special handling of those files is no longer necessary.
    
    gdb/ChangeLog:
    
            * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
            and gdb/testsuite/gdb.base/step-line.c.

commit 0f0c98a8a1ca2fa2e73170849b1db4876c3ea954
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 08:30:28 2018 +0400

    gdb/copyright.py: Do not forget to remind about MULTIPLE_COPYRIGHT_HEADERS
    
    There is a small logical error in the part of the script that
    dumps the list of files in BY_HAND + MULTIPLE_COPYRIGHT_HEADERS
    but only checkis the contents of BY_HAND. The issue becomes
    apparent as soon as BY_HAND is empty. Prevent this from happening
    by treating the two lists separately, as this allows us to provide
    a more informative message in the case of MULTIPLE_COPYRIGHT_HEADERS.
    
    gdb/ChangeLog:
    
            * copyright.py (main): Dump the contents of
            MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
            even if BY_HAND is empty.

commit 82e1e79a420734bcb1fa255a1e7b3250e6acee65
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 08:12:21 2018 +0400

    Update copyright year in version message of GDB, GDBserver and GDBreplay
    
    gdb/ChangeLog:
    
    	* top.c (print_gdb_version): Update Copyright year in version
    	message.
    
    gdb/gdbserver/ChangeLog:
    
    	* gdbreplay.c (gdbreplay_version): Update copyright year in
    	version message.
    	* server.c (gdbserver_version): Likewise.

commit 053f54e57f64ca88596999f37bf3bd329b497d20
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Jan 1 08:07:25 2018 +0400

    Yearly rotation of the gdb/ChangeLog file
    
    gdb/ChangeLog
    
            * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.

commit 87e4655d674c00ccefaf3682b5943505e1c90b92
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jan 2 00:00:32 2018 +0000

    Automatic date update in version.in

commit c76ff6936bd0c7f8a331e57939b1b12d84466b9b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jan 1 00:00:38 2018 +0000

    Automatic date update in version.in

commit 47fea877452b84b94ac6ffb26f194f12845526fa
Author: Ruslan Kabatsayev <b7.10110111@gmail.com>
Date:   Sat Dec 30 22:14:41 2017 +0300

    Avoid indexing std::vector past the end
    
    The code here wants to find address of an element, and often this
    element is one past the end of std::vector. Dereferencing that element
    leads to undefined behavior, so it's better to simply use pointer
    arithmetic instead of taking address of invalid dereference.
    
    gdb/ChangeLog:
    
    	* psymtab.c (recursively_search_psymtabs): Use pointer arithmetic
    	instead of dereferencing std::vector past the end.

commit cfa27c399ec9236a100ef794505d35f60da41a6d
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Dec 30 23:33:26 2017 -0500

    Only ignore -Wenum-compare-switch if it exists
    
    My patch
    
      dwarf2read: Silence -Wenum-compare-switch warning
      132448f8359a268f34f074b0908b5255b568da06
    
    made some parts of dwarf2read.c ignore warnings about switch using enums
    of different kinds.  What I did not realize was that older Clang
    versions (prior to 6) did not have that warning, and therefore give this
    error:
    
    /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:24187:7: error: unknown warning group '-Wenum-compare-switch', ignored [-Werror,-Wunknown-pragmas]
          DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES
          ^
    /home/emaisin/src/binutils-gdb/gdb/common/diagnostics.h:42:3: note: expanded from macro 'DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES'
      DIAGNOSTIC_IGNORE ("-Wenum-compare-switch")
      ^
    /home/emaisin/src/binutils-gdb/gdb/common/diagnostics.h:27:3: note: expanded from macro 'DIAGNOSTIC_IGNORE'
      _Pragma (STRINGIFY (GCC diagnostic ignored option))
      ^
    <scratch space>:10:25: note: expanded from here
     GCC diagnostic ignored "-Wenum-compare-switch"
                            ^
    
    Clang has a way to test if it knows about a particular warning.  This
    patch uses that feature to only define
    DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES to something if the
    warning is recognized by the Clang version being used.  I tested
    building dwarf2read.c with clang 4, 5, 6, as well as gcc.
    
    gdb/ChangeLog:
    
    	* common/diagnostics.h
    	(DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES): Only
    	define if the compiler knows about -Wenum-compare-switch.

commit 132448f8359a268f34f074b0908b5255b568da06
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Dec 30 21:24:29 2017 -0500

    dwarf2read: Silence -Wenum-compare-switch warning
    
    Compiling with Clang 6 gives:
    
    /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:24385:14: error: comparison of two values with different enumeration types in switch statement ('enum dwarf_macro_record_type' and 'dwarf_macinfo_record_type') [-Werror,-Wenum-compare-switch]
            case DW_MACINFO_vendor_ext:
                 ^~~~~~~~~~~~~~~~~~~~~
    /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:24561:7: error: comparison of two values with different enumeration types in switch statement ('enum dwarf_macro_record_type' and 'dwarf_macinfo_record_type') [-Werror,-Wenum-compare-switch]
            case DW_MACINFO_vendor_ext:
                 ^~~~~~~~~~~~~~~~~~~~~
    
    This code uses the two enum types on purpose, because it handles both
    .debug_macro and .debug_macinfo sections.  Add some pragmas to disable
    the warning in these specific cases.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (dwarf_decode_macro_bytes): Ignore
    	-Wenum-compare-switch warning.
    	(dwarf_decode_macros): Likewise.

commit e9d9f57e11db6427db347bc5b9b100071355e63f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 22 21:45:53 2017 -0700

    C++-ify parser_state
    
    This mildly C++-ifies parser_state and stap_parse_info -- just enough
    to remove some cleanups.
    
    This version includes the changes implemented by Simon.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-12-30  Tom Tromey  <tom@tromey.com>
    	    Simon Marchi  <simon.marchi@ericsson.com>
    
    	* stap-probe.h (struct stap_parse_info): Add constructor,
    	destructor.
    	* stap-probe.c (stap_parse_argument): Update.
    	* rust-exp.y (rust_lex_tests): Update.
    	* parser-defs.h (struct parser_state): Add constructor,
    	destructor, release method.
    	<expout>: Change type to expression_up.
    	(null_post_parser): Change type.
    	(initialize_expout, reallocate_expout): Remove.
    	* parse.c (parser_state::parser_state): Rename from
    	initialize_expout.
    	(parser_state::release): Rename from reallocate_expout.
    	(write_exp_elt, parse_exp_in_context_1, increase_expout_size):
    	Update.
    	(null_post_parser): Change type of "exp".
    	* dtrace-probe.c (dtrace_probe::build_arg_exprs): Update.
    	* ada-lang.c (resolve, resolve_subexp)
    	(replace_operator_with_call): Change type of "expp".
    	* language.h (struct language_defn) <la_post_parser>: Change type
    	of "expp".

commit a594729cfb10457e0046359d2dde0c28b4185449
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Dec 31 00:00:27 2017 +0000

    Automatic date update in version.in

commit fc898b42e355fef58e6a029799fdd71b9dda5dc6
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Dec 30 00:10:05 2017 -0500

    Make mapped_debug_names and mapped_index final
    
    When compiling with Clang 6, I see these warnings:
    
    /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:25421:5: error: destructor called on non-final 'mapped_index' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor]
        data->index_table->~mapped_index ();
        ^
    In file included from /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:31:
    In file included from /home/emaisin/src/binutils-gdb/gdb/defs.h:28:
    In file included from /home/emaisin/src/binutils-gdb/gdb/common/common-defs.h:92:
    In file included from /home/emaisin/src/binutils-gdb/gdb/common/gdb_unique_ptr.h:23:
    In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/memory:81:
    /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/bits/unique_ptr.h:76:2: error: delete called on non-final 'mapped_debug_names' that has virtual functions but non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor]
            delete __ptr;
            ^
    /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/bits/unique_ptr.h:236:4: note: in instantiation of member function 'std::default_delete<mapped_debug_names>::operator()' requested here
              get_deleter()(__ptr);
              ^
    /home/emaisin/src/binutils-gdb/gdb/dwarf2read.c:2374:21: note: in instantiation of member function 'std::unique_ptr<mapped_debug_names, std::default_delete<mapped_debug_names> >::~unique_ptr' requested here
    dwarf2_per_objfile::dwarf2_per_objfile (struct objfile *objfile_,
                        ^
    
    This patch silences these warnings by making the classes final.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (struct mapped_debug_names): Make final.
    	(struct mapped_index): Make final.

commit 0436426c7f7798b8eb4b48be9867495da8ef28f0
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Dec 29 23:32:13 2017 -0500

    Ignore warning about using different types of enums in switch
    
    When compiling with clang 6, I see a bunch of warnings like this:
    
    /home/emaisin/src/binutils-gdb/gdb/amd64-linux-tdep.c:1427:8: error: comparison of two values with different enumeration types in switch statement ('enum amd64_syscall' and 'amd
    64_x32_syscall') [-Werror,-Wenum-compare-switch]
      case amd64_x32_sys_move_pages:
           ^~~~~~~~~~~~~~~~~~~~~~~~
    
    In this switch, we indeed use enumerators of both types
    amd64_x32_syscall and amd64_syscall.  This is done on purpose, and the
    enum values are chosen so that they are complementary.
    
    I think it's still a useful warning, so I chose to ignore just that
    particular case.
    
    gdb/ChangeLog:
    
    	* common/diagnostics.h
    	(DIAGNOSTIC_IGNORE_SWITCH_DIFFERENT_ENUM_TYPES): New macro.
    	* amd64-linux-tdep.c (amd64_canonicalize_syscall): Use it.

commit 502a625ab01da27e851333b598c893d6f2c20bd0
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Dec 29 21:56:58 2017 -0500

    Remove unnecessary call to get_thread_db_info
    
    In thread_db_detach, we call get_thread_db_info to first check if there
    exists a thread_db_info entry for the pid to detach.  If there is, then
    we call delete_thread_db_info.  It's unnecessary to call
    get_thread_db_info in the first place, since delete_thread_db_info
    handles the case where no thread_db_info entry exist for the given pid.
    
    gdb/ChangeLog:
    
    	* linux-thread-db.c (thread_db_detach): Remove call to
    	delete_thread_db_info.

commit 4b2dfff9e78c6b615a92c727758f08f595aadba2
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Dec 30 00:00:30 2017 +0000

    Automatic date update in version.in

commit ffd727ca6e52d448137c8cddfbd361c67532e4e1
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Dec 29 00:00:34 2017 +0000

    Automatic date update in version.in

commit d9be0c189a9a9b77a6bf4501f8891544b8ce9593
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Dec 28 13:21:46 2017 -0800

    RISC-V: Add missing privileged spec registers.
    
    	gas/
    	* testsuite/gas/riscv/priv-reg.d, testsuite/gas/riscv/priv-reg.s: New.
    
    	include/
    	* opcode/riscv-opc.h (DECLARE_CSR): Add missing privileged registers.
    	Sort to match privileged spec documentation order.
    	(DECLARE_CSR_ALIAS): Add ubadaddr, and comments.

commit 4ee2b642ddc70393d5b3ab04956fadad02954d4a
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Dec 28 12:29:33 2017 -0500

    Remove unused HP-UX TARGET_OBJECT_ enums
    
    These two enumerators are unused, remove them.
    
    gdb/ChangeLog:
    
    	* target.h (enum target_object) <TARGET_OBJECT_HPUX_UREGS,
    	TARGET_OBJECT_HPUX_SOLIB_GOT>: Remove.

commit 0f833180d3e7a4551ffcd00ee9b6d2483ea23a8a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Dec 28 00:00:21 2017 +0000

    Automatic date update in version.in

commit cef0f8684e818f8b6c71c44dc9cc28a6d0ac3754
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Dec 27 23:36:31 2017 +0900

    tdesc: handle arbitrary strings in tdesc_register_in_reggroup_p
    
    tdesc_register_in_reggroup_p in now able to handle arbitrary
    groups. This is useful when groups are created while the
    target descriptor file is received from the remote.
    
    This can be the case of a soft core target processor where
    registers/groups can change.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Franck Jullien  <franck.jullien@gmail.com>
    	    Stafford Horne  <shorne@gmail.com>
    
    	* target-descriptions.c (tdesc_register_in_reggroup_p): Support
    	arbitrary strings.
    	(tdesc_use_registers): Add logic to register new reggroups.
    	(tdesc_reg::group): Update comment to indicate we allow
    	arbitrary strings.
    	* NEWS (Changes since GDB 8.0): Announce that GDB supports
    	arbitrary reggroups.
    
    gdb/testsuite/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.xml/extra-regs.xml: Add example foo reggroup.
    	* gdb.xml/tdesc-regs.exp: Add test to check for foo reggroup.
    
    gdb/doc/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.texinfo (Target Description Format): Explain that arbitrary
    	strings are now allowed for register groups.

commit f7efd549485db1fd84dbd2f2ee36d80c2739f224
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Dec 27 23:36:31 2017 +0900

    reggroups: Add reggroup_gdbarch_new, reggroup_find for dynamic reggroups
    
    Traditionally reggroups have been created via reggroup_new() during
    initialization code and never freed.  Now, if we want to initialize
    reggroups dynamically (i.e. in target description) we should be able to
    free them.  Create this function reggroup_gdbarch_new() which will
    allocate the reggroup memory onto the passed gdbarch obstack.
    
    Also creating reggroup_find() as a utility to find a gdbarch registered
    reggroup object by name.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* reggroups.c (reggroup_gdbarch_new): New function.
    	(reggroup_find): New function.
    	* reggroups.h (reggroup_gdbarch_new): New function.
    	(reggroup_find): New function.

commit c1166ca9f3543b28e8b0057ecaf2cd3251cd51c5
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Dec 27 23:36:30 2017 +0900

    reggroups: Convert reggroups from post_init to pre_init
    
    Currently the reggroups gdbarch_data cannot be manipulated until after
    the gdbarch is completely initialized.  This is usually done when the
    object init depends on architecture specific fields.  In the case of
    reggroups it only depends on the obstack being available.
    
    Coverting this to pre_init allows using reggroups during gdbarch
    initialization.  This is needed to allow registering arbitrary reggroups
    during gdbarch initializations.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* reggroups.c (reggroups_init): Change to depend only on
    	obstack rather than gdbarch.
    	(reggroup_add): Remove logic for forcing premature init.
    	(_initialize_reggroup): Set `reggroups_data` with
    	gdbarch_data_register_pre_init() rather than
    	gdbarch_data_register_post_init().

commit b67d92b06e6155a392a0c2d413f87d050880dbf4
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Dec 27 23:36:30 2017 +0900

    reggroups: Add test and docs for `info reg $reggroup` feature
    
    Until now this feature has existed but was not documented.  Adding docs
    and tests.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* infcmd.c (_initialize_infcmd): Add help for info reg $reggroup
    	and info all-registers $reggroup feature.
    
    gdb/doc/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.texinfo (Registers): Document info reg $reggroup feature.
    
    gdb/testsuite/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.base/reggroups.c: New file.
    	* gdb.base/reggroups.exp: New file.

commit 76bce0d1d5c4e434736ce4331bc987c7a1ee702c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Dec 27 00:00:21 2017 +0000

    Automatic date update in version.in

commit a811763d7467c8c0c819d7f0a93c4406b7c049dd
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Dec 26 00:00:28 2017 +0000

    Automatic date update in version.in

commit dc6af97a85961f06b3b4e14707dad2bcac39921a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Dec 25 00:00:30 2017 +0000

    Automatic date update in version.in

commit a6c42a6e7404cc469db89a382d2eebd31d794d5b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Dec 24 00:00:39 2017 +0000

    Automatic date update in version.in

commit 6e8c24fe27098f407000812e61fa8210095a7970
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 23 16:25:06 2017 -0500

    Add ATTRIBUTE_PRINTF to printf_field_type_assignment
    
    Get rid of:
    
    /home/simark/src/binutils-gdb/gdb/target-descriptions.c:2026:25: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
        vprintf_unfiltered (fmt, args);
    
    when building with clang.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (print_c_tdesc)
    	<printf_field_type_assignment>: Add ATTRIBUTE_PRINTF.

commit 5c8833d2fa4bcb6a0ef4249dd095bcf29a240465
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Dec 23 00:00:31 2017 +0000

    Automatic date update in version.in

commit 845756abe87ee8a272171edf032242ce4ad13865
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Dec 22 00:00:31 2017 +0000

    Automatic date update in version.in

commit a8d2e5856f87a658d69018fe1ccd56482eebdd59
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Dec 21 18:19:17 2017 -0500

    Do not emit "field_type" var if not needed on "maint print c-tdesc"
    
    While fiddling a bit with -Wunused-variable, Sergio noticed that "maint
    print c-tdesc" was always generating code for the "tdesc_type
    *field_type" variable, even when it wasn't used.  This is caught by GCC
    when using -Wunused-variable, of course.
    
    This patch changes the print_c_tdesc class to only output the field
    declaration when we actually need it.
    
    It shouldn't be necessary to do the same with the other variable
    declarations (type_with_fields and element_type), because they are
    always if they are declared.
    
    The C files in features/ are regenerated, some declarations of
    field_type are removed, as expected, while some others move to where
    they are used for the first time.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (print_c_tdesc) <visit>: Don't output
    	field_type declaration, use printf_field_type_assignment
    	instead.
    	<printf_field_type_assignment>: New method.
    	* features/aarch64-core.c, features/aarch64-fpu.c
    	features/arc-arcompact.c, features/arc-v2.c,
    	features/arm/arm-with-iwmmxt.c, features/i386/32bit-core.c,
    	features/i386/32bit-mpx.c, features/i386/32bit-sse.c,
    	features/i386/64bit-avx512.c, features/i386/64bit-core.c,
    	features/i386/64bit-mpx.c, features/i386/64bit-sse.c,
    	features/i386/x32-core.c, features/or1k.c,
    	features/rs6000/powerpc-7400.c,
    	features/rs6000/powerpc-altivec32.c,
    	features/rs6000/powerpc-altivec32l.c,
    	features/rs6000/powerpc-altivec64.c,
    	features/rs6000/powerpc-altivec64l.c,
    	features/rs6000/powerpc-cell32l.c,
    	features/rs6000/powerpc-cell64l.c,
    	features/rs6000/powerpc-isa205-altivec32l.c,
    	features/rs6000/powerpc-isa205-altivec64l.c,
    	features/rs6000/powerpc-isa205-vsx32l.c,
    	features/rs6000/powerpc-isa205-vsx64l.c,
    	features/rs6000/powerpc-vsx32.c,
    	features/rs6000/powerpc-vsx32l.c,
    	features/rs6000/powerpc-vsx64.c,
    	features/rs6000/powerpc-vsx64l.c, features/s390-gs-linux64.c,
    	features/s390-tevx-linux64.c, features/s390-vx-linux64.c,
    	features/s390x-gs-linux64.c, features/s390x-tevx-linux64.c,
    	features/s390x-vx-linux64.c: Re-generate.

commit 27e9ff87a627614fda7ddd89ddef745de5e988bb
Author: Uros Bizjak <ubizjak@gmail.com>
Date:   Wed Dec 20 20:42:05 2017 -0500

    Remove write-only assignment in rs6000-tdep.c
    
    The result of this memory read is never used, so it can be removed.
    
    gdb/ChangeLog:
    
    	* rs6000-tdep.c (ppc_deal_with_atomic_sequence): Remove
    	write-only assignment to "insn" variable.

commit 6eab0eaa1b71025cc1747396fdba127d25c209c0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Dec 21 00:00:39 2017 +0000

    Automatic date update in version.in

commit 21a186f28061ea51e422ae47d062793ceac2180f
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Dec 20 13:37:44 2017 -0800

    RISC-V: Add compressed instruction hints, and a few misc cleanups.
    
    	gas/
    	* config/tc-riscv.c (risc_ip) <o>: Add comment.
    	* testsuite/gas/riscv/c-nonzero-imm.d,
    	* testsuite/gas/riscv/c-nonzero-imm.l,
    	* testsuite/gas/riscv/c-nonzero-imm.s,
    	* testsuite/gas/riscv/c-nonzero-reg.d,
    	* testsuite/gas/riscv/c-nonzero-reg.l,
    	* testsuite/gas/riscv/c-nonzero-reg.s,
    	* testsuite/gas/riscv/c-zero-imm-64.d,
    	* testsuite/gas/riscv/c-zero-imm-64.s,
    	* testsuite/gas/riscv/c-zero-imm.d, testsuite/gas/riscv/c-zero-imm.s,
    	* testsuite/gas/riscv/c-zero-reg.d,
    	* testsuite/gas/riscv/c-zero-reg.s: New.
    
    	opcodes/
    	* riscv-opc.c (match_c_add_with_hint, match_c_lui_with_hint): New.
    	(riscv_opcodes) <li>: Delete "d,0" line.  Change Cj to Co.
    	<andi, and, add, addiw, addw, c.addi>: Change Cj to Co.
    	<add>: Add explanatory comment for 4-operand add instruction.
    	<c.nop>: Add support for immediate operand.
    	<c.mv, c.add>: Use match_c_add_with_hint instead of match_c_add.
    	<c.lui>: Use match_c_lui_with_hint instead of match_c_lui.
    	<c.li, c.slli>: Use match_opcode instead of match_rd_nonzero.

commit 396d3980f518cfc9a936e3fb8138b0492399525a
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Dec 20 13:59:14 2017 +0100

    [Cell/B.E.] Fix regression due to gdbarch_significant_addr_bit
    
    On Cell/B.E. multi-architecture debugging we use a "merged" address space
    that encodes both the main PowerPC address space and the local store address
    spaces of all active SPUs.  This will always occupy 64 bits.
    
    However, gdbarch_addr_bit is set to 32 on SPU, and may be set to 32 as well
    on PowerPC.  Since the new gdbarch_significant_addr_bit defaults to the
    value of gdbarch_addr_bit, this means addresses may be improperly truncated.
    
    Work around this problem by explicitly setting gdbarch_significant_addr_bit
    to 64 both for the SPU target and also for PowerPC target that support
    Cell/B.E. execution.
    
    gdb/ChangeLog:
    2017-12-20  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* spu-tdep.c (spu_gdbarch_init): Set set_gdbarch_significant_addr_bit
    	to 64 bits.
    	(ppc_linux_init_abi): Likewise, if Cell/B.E. is supported.

commit 175654b9cdd3113a01174b019ac286092398246b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 19 22:09:40 2017 -0500

    Fix ChangeLog formatting
    
    Doing some unrelated grepping found that there were some missing
    spaces, fix it.

commit 0a16b291e0c181223a97b68a5252f99fa38193ca
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Dec 20 00:00:21 2017 +0000

    Automatic date update in version.in

commit 7bbac84fbc1b282ca9dd15ac70a0720ca934d11f
Merge: 193e207 00c2093
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Dec 19 06:28:39 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 00c2093f698e8f40c04340cb1832d09e11ece237
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Tue Dec 19 12:05:20 2017 +0000

    Correct disassembly of dot product instructions.
    
    Dot products deviate from the normal disassembly rules for lane indexed
    instruction. Their canonical representation is in the form of:
    
    v0.2s, v0.8b, v0.4b[0] instead of v0.2s, v0.8b, v0.b[0] to try to denote
    that these instructions select 4x 1 byte elements instead of a single 1 byte
    element.
    
    Previously we were disassembling them following the normal rules, this patch
    corrects the disassembly.
    
    gas/
    
    	PR gas/22559
    	* config/tc-aarch64.c (vectype_to_qualifier): Support AARCH64_OPND_QLF_S_4B.
    	* gas/testsuite/gas/aarch64/dotproduct.d: Update disassembly.
    
    include/
    
    	PR gas/22559
    	* aarch64.h (aarch64_opnd_qualifier): Add AARCH64_OPND_QLF_S_4B.
    
    opcodes/
    
    	PR gas/22559
    	* aarch64-asm.c (aarch64_ins_reglane): Change AARCH64_OPND_QLF_S_B to
    	AARCH64_OPND_QLF_S_4B
    	* aarch64-dis.c (aarch64_ext_reglane): Change AARCH64_OPND_QLF_S_B to
    	AARCH64_OPND_QLF_S_4B
    	* aarch64-opc.c (aarch64_opnd_qualifiers): Add 4b variant.
    	* aarch64-tbl.h (QL_V2DOT): Change S_B to S_4B.

commit a3b3345ae62503982698171bcfce0afe23bd8a31
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Tue Dec 19 12:04:13 2017 +0000

    Add support for V_4B so we can properly reject it.
    
    Previously parse_vector_type_for_operand was changed to allow the use of 4b
    register size for indexed lane instructions. However this had the unintended
    side effect of also allowing 4b for normal vector registers.
    
    Because this support was only partial the rest of the tool silently treated
    4b as 8b and continued. This patch adds full support for 4b so it can be
    properly distinguished from 8b and the correct errors are generated.
    
    With this patch you still can't encode any instruction which actually requires
    v<num>.4b but such instructions don't exist so to prevent needing a workaround
    in get_vreg_qualifier_from_value this was just omitted.
    
    gas/
    
    	PR gas/22529
    	* config/tc-aarch64.c (vectype_to_qualifier): Support AARCH64_OPND_QLF_V_4B.
    	* gas/testsuite/gas/aarch64/pr22529.s: New.
    	* gas/testsuite/gas/aarch64/pr22529.d: New.
    	* gas/testsuite/gas/aarch64/pr22529.l: New.
    
    include/
    
    	PR gas/22529
    	* opcode/aarch64.h (aarch64_opnd_qualifier): Add AARCH64_OPND_QLF_V_4B.
    
    opcodes/
    
    	PR gas/22529
    	* aarch64-opc.c (aarch64_opnd_qualifiers): Add 4b variant.

commit bef7475fbda88374ca488b0acbbfe1d3d4ab3e5f
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Dec 19 09:48:40 2017 +0000

    Stop readelf from complaining about relocation sections with an sh_info field of 0 in dynamic executables.
    
    	PR 22587
    	* readelf.c (process_section_headers): Do not complain about an
    	sh_info field of 0 in relocation sections of ET_EXEC or ET_DYN
    	type executables.

commit be62dcaa1771b5f2a47f0cfd78f89828f087efff
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Dec 19 00:00:18 2017 +0000

    Automatic date update in version.in

commit 63f452a8bfd9c89b56dcc087cea84151e7a9ec24
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Dec 18 22:27:08 2017 +1030

    PR22626, invalid dynindx used for dynamic relocs against section syms
    
    _bfd_elf_link_renumber_dynsyms is called twice by the linker.  The
    first call in bfd_elf_size_dynamic_sections is just to answer the
    question as to whether there are there any dynamic symbols.  The
    second call in bfd_elf_size_dynsym_hash_dynstr sets the st_shndx value
    that dynamic symbols will have.  strip_excluded_output_sections is
    called between these two calls.  So sections seen on the first
    _bfd_elf_link_renumber_dynsyms pass might differ from those seen on
    the second pass.  Unfortunately, that can result in a stripped
    section's dynamic symbol being assigned a dynindx on the first pass
    but not corrected to the final value (of zero, ie. not dynamic) on the
    second pass.  PowerPC, x86, mips, and most other targets that emit
    dynamic section symbols, just test that section symbol dynindx is
    non-zero before using a given section symbol in dynamic relocations.
    
    This patch prevents _bfd_elf_link_renumber_dynsyms from setting any
    section symbol dynindx on the first pass.
    
    	PR 22626
    	* elflink.c (_bfd_elf_link_renumber_dynsyms): Don't set section
    	dynindx when section_sym_count is NULL.
    	(bfd_elf_size_dynamic_sections): Pass NULL section_sym_count to
    	preliminary _bfd_elf_link_renumber_dynsyms call.

commit f795c49463234dc347ddd9a1b07ee5b506295b96
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Dec 15 17:08:56 2017 +1030

    Test binutils_assemble return value
    
    This is a followup to "binutils nm testsuite tidy".  Since the perror
    in binutils_assemble has been removed, we need to take more care in
    failure paths.
    
    The patch also fixed a number of .exp files that have multiple tests,
    where an assembly failure returns from the .exp file.  In most cases
    it is nicer to attempt all tests.
    
    	* testsuite/binutils-all/ar.exp (unique_symbol): Don't run AR
    	if assembly fails.
    	* testsuite/binutils-all/arc/objdump.exp (check_assembly): If
    	objfile is empty, fail test.
    	* testsuite/binutils-all/arm/objdump.exp: Don't return if assembly
    	fails for a test, continue on to other tests.
    	* testsuite/binutils-all/bfin/objdump.exp: Likewise.
    	* testsuite/binutils-all/hppa/objdump.exp: Likewise.
    	* testsuite/binutils-all/m68k/objdump.exp: Likewise.
    	* testsuite/binutils-all/vax/objdump.exp: Likewise.
    	* testsuite/binutils-all/size.exp: Likewise.
    	* testsuite/binutils-all/nm.exp: Likewise.  Move PR12753 test.
    	* testsuite/binutils-all/objcopy.exp: Don't perror on assembly fail.
    	* testsuite/binutils-all/objdump.exp: Report assembly fails.

commit c54207d32681bb205c28facba73b6173ef15eabf
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Dec 18 17:57:18 2017 +0000

    Decode expression lists used with DW_AT_byte_size and other DWARF attributes.
    
    	PR 22532
    	* dwarf.c (read_and_display_attr_value): Add attributes that might
    	use the DW_FORM_exprloc form, and if so, display the decoded
    	location expression list.

commit 4f588891ac7d4653e1bd861ca38c2a4e6d5e907c
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Dec 18 09:37:57 2017 +0000

    Resolve PR 22493 - the encoding to be used when pushing the stack pointer onto the stack.
    
    	PR 22493
    	* config/tc-arm.c (encode_ldmstm): Do not use A2 encoding of the
    	PUSH insn when pushing the stack pointer.

commit 10c17abdd052c5f8f9c2bcdf8b01dffe5d06baf0
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Dec 18 09:37:15 2017 +0100

    x86: fold certain AVX and AVX2 templates
    
    Just like for instructions in GPRs, there's no need to have separate
    templates for otherwise identical insns acting on XMM or YMM registers
    (or memory of the same size).

commit 1b54b8d7e4fc8055f9220a5287e8a94d8a65a88d
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Dec 18 09:36:14 2017 +0100

    x86: fold RegXMM/RegYMM/RegZMM into RegSIMD
    
    ... qualified by their respective sizes, allowing to drop FirstXmm0 at
    the same time.

commit ca0d63fe0703ed36af1a7bda6097958805895b3a
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Dec 18 09:35:01 2017 +0100

    x86: drop FloatReg and FloatAcc
    
    Express them as Reg|Tbyte and Acc|Tbyte respectively.

commit dc821c5f9ae5208ad1ec438718f75e224f856deb
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Dec 18 09:34:00 2017 +0100

    x86: replace Reg8, Reg16, Reg32, and Reg64
    
    Use a combination of a single new Reg bit and Byte, Word, Dword, or
    Qword instead.
    
    Besides shrinking the number of operand type bits this has the benefit
    of making register handling more similar to accumulator handling (a
    generic flag is being accompanied by a "size qualifier"). It requires,
    however, to split a few insn templates, as it is no longer correct to
    have combinations like Reg32|Reg64|Byte. This slight growth in size will
    hopefully be outweighed by this change paving the road for folding a
    presumably much larger number of templates later on.

commit eccab96d54a9455557d3c4d5bff431f6e526d0b7
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Sun Dec 17 22:39:33 2017 -0500

    improved error message when getting an exception printing a variable
    
    Consider the following Ada code defining a global variable whose
    type is an array of static bounds (1 .. 2), but where its elements
    are a variant record whose size is not statically known:
    
        type Ints is array (Natural range <>) of Integer;
        type Bounded_Ints (Max_Size : Natural) is record
           Length : Natural := 0;
           Objs   : Ints (1 .. Max_Size);
        end record;
    
        type Ints_Doubled is array (1 .. 2) of Bounded_Ints (Idem (0));
    
        Global : Ints_Doubled;
    
    When compiling this program at -O2 using a GCC-6.4-based compiler
    on x86_64-linux, trying to print the value of that global variable
    yields:
    
        (gdb) p global
        $1 =
    
    Let's look at the debugging info, which starts with the global
    variable itself...
    
            .uleb128 0x19   # (DIE (0x25e) DW_TAG_variable)
            .long   .LASF32 # DW_AT_name: "fd__global"
            .long   0x273   # DW_AT_type
    
    ... its type is a reference to a typedef ...
    
            .uleb128 0x14   # (DIE (0x273) DW_TAG_reference_type)
            .byte   0x8     # DW_AT_byte_size
            .long   0x202   # DW_AT_type
            [...]
            .uleb128 0x15   # (DIE (0x202) DW_TAG_typedef)
            .long   .LASF19 # DW_AT_name: "fd__ints_doubled"
            .long   0x20d   # DW_AT_type
    
    ... of an array (1..2) ...
    
            .uleb128 0x2    # (DIE (0x20d) DW_TAG_array_type)
            .long   .LASF19 # DW_AT_name: "fd__ints_doubled"
            .long   0x15b   # DW_AT_type
            .long   0x221   # DW_AT_sibling
            .uleb128 0x16   # (DIE (0x21a) DW_TAG_subrange_type)
            .long   0x40    # DW_AT_type
            .sleb128 2      # DW_AT_upper_bound
            .byte   0       # end of children of DIE 0x20d
    
    ... of a struct whose name is fd__Tints_doubledC:
    
            .uleb128 0x10   # (DIE (0x15b) DW_TAG_structure_type)
            .long   .LASF11 # DW_AT_name: "fd__Tints_doubledC"
            .long   0x1e4   # DW_AT_GNAT_descriptive_type
                            # DW_AT_artificial
            .long   0x1e4   # DW_AT_sibling
            .uleb128 0x7    # (DIE (0x16a) DW_TAG_member)
            .long   .LASF4  # DW_AT_name: "max_size"
            [snip]
    
    The error occurs while Ada evaluator is trying to "fix"
    the element type inside the array, so as to determine its actual
    size. For that, it searches for a parallel "XVZ" variable,
    which, when found, contains the object's actual size.
    
    Unfortunately in our case, the variable exists but has been
    optimized out, as seen by the presence of a variable DIE in
    the debugging info, but with no address attribute:
    
            .uleb128 0x18   # (DIE (0x24e) DW_TAG_variable)
            .long   .LASF31 # DW_AT_name: "fd__Tints_doubledC___XVZ"
            .long   0x257   # DW_AT_type
                            # DW_AT_artificial
    
    Discussing this with some members of AdaCore's compiler team,
    it is expected that the optimizer can get rid of this variable,
    and we don't want to pessimize the code just to improve debuggability,
    since -O2 is about performance. So, the idea of this patch is
    not to make it work, but provide a bit more information to help
    users understand what kind of error is preventing GDB from being
    able to print the variable's value.
    
    The first hurdle we had to clear was the fact that ada_val_print
    traps all exceptions (including QUIT ones!), and does so completly
    silently. So, the fix was to add a trace of the exception being
    generated. While doing so, we fix an old XXX/FIXME by only catching
    errors, letting QUIT exceptions go through.
    
    Once this is done, we now get an error message, which gives a first
    clue as to what was happening:
    
        (gdb) p fd.global
        $1 = <error reading variable: value has been optimized out>
    
    However, it would be more useful to know which value it was
    that was optimized out. For that purpose, we enhanced
    ada-lang.c::ada_to_fixed_type_1 so as to re-throw the error
    with a message which indicates which variable we failed to read.
    
    With those changes, the new output is now:
    
        (gdb) p fd.global
        $1 = <error reading variable: unable to read value of fd__Tints_doubledC___XVZ (value has been optimized out)>
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_to_fixed_type_1): Rethrow errors with
            a more detailed exception message when getting an exception
            while trying to read the value of an XVZ variable.
            * ada-valprint.c (ada_val_print): Only catch RETURN_MASK_ERROR
            exceptions.  Print an error message when an exception is caught.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.dwarf2/ada-valprint-error.c: New file.
            * gdb.dwarf2/ada-valprint-error.exp: New file.
    
    Tested on x86_64-linux

commit 0e2da9f01334a01d1a6e224ecd592d6fbbb22515
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Sun Dec 17 22:09:27 2017 -0500

    (Ada) crash assigning to record component which is an array
    
    Consider the following code, which declares a variabled called "input"
    of type "parameter", which is a record with one component called "u2",
    where the type of that component is a simple 3-element array of
    floating point values:
    
       type Float_Array_3 is array (1 .. 3) of Float;
       type parameters is record
          u2 : Float_Array_3;
       end record;
       input : parameters;
    
    Trying to assign a value to input.u2 causes GDB to crash:
    
        (gdb) p input.u2 := (0.25,0.5,0.75)
        [1]    20228 segmentation fault (core dumped) [...]/gdb
    
    The crash occurs because input.u2 is described in the debugging
    info as a typedef of an array. Indeed, input's type is:
    
     <1><ae9>: Abbrev Number: 7 (DW_TAG_structure_type)
        <aea>   DW_AT_name        : (indirect string, offset: 0x1045): target_wrapper__parameters
        [...]
     <2><af5>: Abbrev Number: 8 (DW_TAG_member)
        <af6>   DW_AT_name        : u2
        [...]
        <afb>   DW_AT_type        : <0xaca>
    
    and, looking at DIE 0xaca to get input.u2's type, we see:
    
     <1><aca>: Abbrev Number: 4 (DW_TAG_typedef)
        <acb>   DW_AT_name        : (indirect string, offset: 0x1060): target_wrapper__float_array_3
        [...]
        <ad1>   DW_AT_type        : <0xad5>
    
    We can also confirm, following the DW_AT_type attribute (0xad5), that
    it's a typedef of our array:
    
     <1><ad5>: Abbrev Number: 5 (DW_TAG_array_type)
        <ad6>   DW_AT_name        : (indirect string, offset: 0x1060): target_wrapper__float_array_3
        [...]
    
    In fact, this scenario uncovered 2 areas where typedef handling
    is missing, thus causing a crash. The first happens inside
    assign_aggregate:
    
       if (ada_is_direct_array_type (lhs_type))
         {
           lhs = ada_coerce_to_simple_array (lhs);
           lhs_type = value_type (lhs);
           low_index = TYPE_ARRAY_LOWER_BOUND_VALUE (lhs_type);
           high_index = TYPE_ARRAY_UPPER_BOUND_VALUE (lhs_type);
         }
    
    Here, lhs_type is a TYPE_CODE_TYPEDEF. ada_is_direct_array_type
    knows how to handle it, but TYPE_ARRAY_LOWER_BOUND_VALUE assumes
    that the given type is a TYPE_CODE_ARRAY. As such, it ends up
    accessing some fields in lhs_type which it shouldn't, and kaboom.
    
    We fixed this issue by making sure that the TYPE_CODE_TYPEDEF
    layer gets stripped.
    
    Once this is done, we hit a different kind of error, also leading to
    a SEGV, this time in assign_component. The code looks like this:
    
      if (TYPE_CODE (value_type (lhs)) == TYPE_CODE_ARRAY)
        [...]
      else
        [...]
    
    Because once again lhs is a TYPE_CODE_TYPEDEF, the check fail,
    and we end up assuming that lhs is a struct, executing the "else"
    block, which is:
    
      else
        {
          elt = ada_index_struct_field (index, lhs, 0, value_type (lhs));
          elt = ada_to_fixed_value (elt);
        }
    
    Since lhs is not a struct, ada_index_struct_field returns NULL,
    which ada_to_fixed_value does not handle well, hence another crash.
    
    This patch fixes this other issue the same way, by stripping
    TYPE_CODE_TYPEDEF layers.
    
    gdb/ChangeLog:
    
            * ada-lang.c (assign_component): Strip any TYPE_CODE_TYPEDEF
            layer from lhs' type.
            (assign_aggregate): Likewise.
    
    gdb/testsuite:
    
            * gdb.ada/assign_arr: New testcase.
    
    Tested on x86_64-linux.

commit cb923fcc23e07fe3dfb3837f47249aba79cdee6f
Author: Xavier Roirand <roirand@adacore.com>
Date:   Sun Dec 17 21:59:07 2017 -0500

    Ada: fix bad handling in ada_convert_actual
    
    Using this small example:
    
    procedure Foo is
    
       type Integer_Access is access all Integer;
    
       procedure P (A : Integer_Access) is
       begin
          null;
       end P;
    
    begin
       P (null);
    end Foo;
    
    and doing this debug session:
    
    (gdb) b p
    Breakpoint 1 at 0x402d67: file foo.adb, line 7.
    (gdb) print p(null)
    
    Breakpoint 1, foo.p (a=0x641010) at foo.adb:10
    ...                  ^^^^^^^^^^
    
    shows that something goes wrong between the initial null value and the
    received parameter value in the 'f' function.
    The value for the parameter 'a' we get is the address of the value we
    would expect instead of the value itself. This can be checked by doing:
    
    (gdb) p *a
    $1 = 0
    
    Before this fix, in ada_convert_value, this function was looking to the
    actual value (the null value here) to determine if the formal (parameter
    'a' in the procedure 'P' in this exemple) requires a pointer or not which
    is a wrong assumption and leads to push the address of the value to the
    inferior instead of the value itself.
    
    This is fixed by this patch.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_convert_actual): Change the way actual value
            are passed to the inferior when the inferior expects a pointer type.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/funcall_ptr: New testcase.
    
    Tested on x86_64-linux.

commit 7d47b066d0e5ea1df82aa24fde2dd4e38814627c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Dec 18 00:00:20 2017 +0000

    Automatic date update in version.in

commit 390c91cfcffe1a0d75b6100d1542cda2544993b3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Dec 17 09:40:54 2017 -0800

    x86: Check pseudo prefix without instruction
    
    Pseudo prefixes must be used on an instruction.  Issue an error when
    pseudo prefix is used without instruction.
    
    	PR gas/22623
    	* gas/config/tc-i386.c (output_insn): Check pseudo prefix
    	without instruction.
    	* testsuite/gas/i386/i386.exp: Run inval-pseudo.
    	* testsuite/gas/i386/inval-pseudo.l: New file.
    	* testsuite/gas/i386/inval-pseudo.s: Likewise.

commit fd7055f4a7f8eef9dc926fae698ad297279726bb
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Dec 17 00:00:31 2017 +0000

    Automatic date update in version.in

commit 38af1824019684e819ffb880bdf7fb03a2c2000a
Author: Stafford Horne <shorne@gmail.com>
Date:   Sun Dec 17 07:20:51 2017 +0900

    gdb: Fix function parameter alignments in or1k-tdep.c.
    
    As suggested by Joel Brobecker <brobecker@adacore.com> and as per fsf
    coding standards.  Also fix a few more issues with directly printing
    pointers.
    
    gdb/ChangeLog:
    
    	* gdb/or1k-tdep.c (show_or1k_debug): Fix function parameter alignment.
    	(or1k_analyse_inst): Likewise.
    	(or1k_single_step_through_delay): Likewise.
    	(or1k_frame_cache): Fix parameter alignment and use paddress()
    	instead of %x.

commit b282f0f2b56903c7b58f1eb94b88e468851928e8
Author: Stafford Horne <shorne@gmail.com>
Date:   Sun Dec 17 07:20:50 2017 +0900

    gdb: Add news entries for new or1k target.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* NEWS (Changes since GDB 8.0): Mention new or1k target and new
    	commands to set/show or1k debug.

commit 46afe196ec282505dcd2727725bfb5ef87ea4b21
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Dec 15 22:33:07 2017 -0500

    Fix ARI warning on gdb/typeprint.c:whatis_exp
    
    I forgot to indent the "if" clause properly and put the "&&" at the
    beginning of the line, so ARI complained.  This commit fixed it.
    
    gdb/ChangeLog:
    2017-12-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* typeprint.c (whatis_exp): Fix ARI warning and reindent "if"
    	condition.

commit 09da3ecf04d75084ea7d9c43e3cc0b18b2443ea3
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Dec 16 00:00:33 2017 +0000

    Automatic date update in version.in

commit 7c1618381fdaa0697a211721ac31844f884797ac
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Nov 20 16:34:59 2017 -0500

    Implement pahole-like 'ptype /o' option
    
    This commit implements the pahole-like '/o' option for 'ptype', which
    prints the offsets and sizes of struct fields, reporting whenever
    there is a hole found.
    
    The output is heavily based on pahole(1), with a few modifications
    here and there to adjust it to our reality.  Here's an example:
    
      /* offset    |  size */  type = struct wer : public tuv {
    			   public:
      /*   32      |    24 */    struct tyu {
      /*   32:31   |     4 */        int a1 : 1;
      /*   32:28   |     4 */        int a2 : 3;
      /*   32: 5   |     4 */        int a3 : 23;
      /*   35: 3   |     1 */        char a4 : 2;
      /* XXX  3-bit hole   */
      /* XXX  4-byte hole  */
      /*   40      |     8 */        int64_t a5;
      /*   48:27   |     4 */        int a6 : 5;
      /*   48:56   |     8 */        int64_t a7 : 3;
    
    				 /* total size (bytes):   24 */
    			     } a1;
    
    			     /* total size (bytes):   56 */
    			   }
    
    A big part of this patch handles the formatting logic of 'ptype',
    which is a bit messy.  The code to handle bitfield offsets, however,
    took some time to craft.  My thanks to Pedro Alves for figuring things
    out and pointing me to the right direction, as well as coming up with
    a way to inspect the layout of structs with bitfields (see testcase
    for comments).
    
    After many discussions both on IRC and at the mailing list, I tried to
    implement printing vtables and inherited classes.  Unfortunately the
    code grew too complex and there were still a few corner cases failing
    so I had to drop the attempt.  This should be implemented in a future
    patch.
    
    This patch is the start of a long-term work I'll do to flush the local
    patches we carry for Fedora GDB.  In this specific case, I'm aiming at
    upstreaming the feature implemented by the 'pahole.py' script that is
    shipped with Fedora GDB:
    
      <https://src.fedoraproject.org/rpms/gdb/blob/master/f/gdb-archer.patch#_311>
    
    This has been regression-tested on the BuildBot.  There's a new
    testcase for it, along with an update to the documentation.  I also
    thought it was worth mentioning this feature in the NEWS file.
    
    gdb/ChangeLog:
    2017-12-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	PR cli/16224
    	* NEWS (Changes since GDB 8.0): Mention new '/o' flag.
    	* c-typeprint.c (OFFSET_SPC_LEN): New define.
    	(c_type_print_varspec_prefix): New argument 'struct
    	print_offset_data *'.
    	(c_type_print_base_1): New function and prototype.
    	(c_print_type_1): New function, with code from 'c_print_type'.
    	(c_print_type): Use 'c_print_type_1'.
    	(c_type_print_varspec_prefix): New argument 'struct
    	print_offset_data *'.  Use it.  Call 'c_type_print_base_1'
    	instead of 'c_print_type_base'.
    	(print_spaces_filtered_with_print_options): New function.
    	(output_access_specifier): Take new argument FLAGS.  Modify
    	function to call 'print_spaces_filtered_with_print_options'.
    	(c_print_type_vtable_offset_marker): New function.
    	(c_print_type_union_field_offset): New function.
    	(c_print_type_struct_field_offset): New function.
    	(c_print_type_no_offsets): New function.
    	(c_type_print_base_struct_union): New argument 'struct
    	print_offset_data *'.  Print offsets and sizes for
    	struct/union/class fields.
    	* typeprint.c (const struct type_print_options
    	type_print_raw_options): Initialize 'print_offsets'.
    	(static struct type_print_options default_ptype_flags):
    	Likewise.
    	(struct print_offset_data print_offset_default_data): New
    	variable.
    	(whatis_exp): Handle '/o' option.
    	(_initialize_typeprint): Add '/o' flag to ptype's help.
    	* typeprint.h (struct print_offset_data): New struct.
    	(struct type_print_options) <print_offsets>: New field.
    
    gdb/testsuite/ChangeLog:
    2017-12-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR cli/16224
    	* gdb.base/ptype-offsets.cc: New file.
    	* gdb.base/ptype-offsets.exp: New file.
    
    gdb/doc/ChangeLog:
    2017-12-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR cli/16224
    	* gdb.texinfo (ptype): Add documentation for new flag '/o'.

commit a27ed7d613ec91c3a79965d6bdab1fa96d559c85
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Dec 11 11:57:19 2017 -0500

    Reorganize code to handle TYPE_CODE_{STRUCT,UNION} on 'c_type_print_base'
    
    While doing the 'ptype /o' work, I noticed that 'c_type_print_base'
    was very long, with a big amount of code just to handle the case of
    TYPE_CODE_{STRUCT,UNION}.  This made working with the function a bit
    difficult, specially because of the level of indentation.
    
    This commit moves this part of the code to their own functions.  Now
    we have a 'c_type_print_base_struct_union' with most of the code, and
    also 'need_access_label_p', which is a subset of the code that was
    also a good candidate for having its own function.
    
    gdb/ChangeLog:
    2017-12-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* c-typeprint.c (need_access_label_p): New function.
    	(c_type_print_base_struct_union): New function.
    	(c_type_print_base): Move code to handle
    	TYPE_CODE_{STRUCT,UNION} to the functions mentioned above.

commit fc076a47fd716ca75447d432251abc67a19ef908
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Dec 15 18:55:39 2017 +0000

    Update documentation regarding the bfd returned by bfd_openr_next_archived_file
    
    	PR 22571
    	* archive.c (bfd_openr_next_archived_file): Extend the
    	documentation to note that it is necessary to call
    	bfd_check_format on the rrturned bfd before using it.

commit 68f81d60196eb201b209873cf53258f13b0046b9
Author: Richard Henderson <rth@redhat.com>
Date:   Fri Dec 15 18:19:42 2017 +0000

    Fix PR19061, gdb hangs/spins-on-cpu when debugging any program on Alpha
    
    This fixes PR19061, where gdb hangs/spins-on-cpu when debugging any
    program on Alpha.
    
    (This patch is Uros' forward port of the patch from comment #5
    of the PR [1].)
    
    Patch was tested on alphaev68-linux-gnu, also tested with gcc's
    testsuite, where it fixed all hangs in guality.exp and
    simulate-thread.exp testcases.
    
    [1] https://sourceware.org/bugzilla/show_bug.cgi?id=19061#c5
    
    gdb/ChangeLog:
    2017-12-15  Richard Henderson  <rth@redhat.com>
    	    Uros Bizjak  <ubizjak@gmail.com>
    
    	PR gdb/19061
    	* alpha-tdep.c (alpha_software_single_step): Call
    	alpha_deal_with_atomic_sequence here.
    	(set_gdbarch_software_single_step): Set to
    	alpha_software_single_step.
    	* nat/linux-ptrace.h [__alpha__]: Define GDB_ARCH_IS_TRAP_BRKPT
    	and GDB_ARCH_IS_TRAP_HWBKPT.

commit 1af17fd9cc3a453e55ce5b8f556c51859bf40363
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 15 10:45:27 2017 +0000

    Skip 'maintenance check xml-descriptions' if XML is disabled
    
    I see the following test failure when gdb is configured without XML
    support,
    
    maintenance check xml-descriptions binutils-gdb/gdb/testsuite/../features
    warning: Can not parse XML target description; XML support was disabled at compile time^M
    Tested 29 XML files, 29 failed
    (gdb) FAIL: gdb.gdb/unittest.exp: maintenance check xml-descriptions ${srcdir}/../features
    
    gdb/testsuite:
    
    2017-12-15  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.gdb/unittest.exp: Skip 'maintenance check xml-descriptions'
    	if XML is disabled.

commit 97d4fac10fb9dac465d1d7e7a26c6b9cfb0b1326
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 15 10:45:27 2017 +0000

    Skip parse_memory_map_tests if XML is disabled
    
    I find a fail in gdb unit test when gdb is configured without XML
    support.
    
    warning: Can not parse XML memory map; XML support was disabled at compile time^M
    Self test failed: self-test failed at ../../binutils-gdb/gdb/unittests/memory-map-selftests.c:65
    ...
    Ran 31 unit tests, 1 failed^M
    (gdb) FAIL: gdb.gdb/unittest.exp: maintenance selftest
    
    gdb:
    
    2017-12-15  Yao Qi  <yao.qi@linaro.org>
    
    	* unittests/memory-map-selftests.c: Wrap test with HAVE_LIBEXPAT.

commit fbc2255575afc0d332b28fd4991235e020cda667
Author: Dimitar Dimitrov <dimitar@dinux.eu>
Date:   Fri Dec 15 06:45:47 2017 +0200

    Fix disassembly for PowerPC
    
    	* disassemble.c (disassemble_init_for_target): Don't put PRU
    	between powerpc and rs6000 cases.

commit 141975a1e53798a48917271295962fb1a7e967d0
Author: Jan Beulich <jbeulich@novell.com>
Date:   Fri Dec 15 09:14:52 2017 +0100

    x86: correct operand type checks
    
    Again these look to be typos: No template currently allows for any two
    (or all three) of RegXMM, RegYMM, and RegZMM in a single operand. Quite
    clearly ! are missing, after the addition of which the checks for the
    first and (if present) second operands also fully match up.

commit 93b71a266695669cb9aa8ddf2717a1ccd53c925d
Author: Jan Beulich <jbeulich@novell.com>
Date:   Fri Dec 15 09:13:54 2017 +0100

    x86: drop stray CheckRegSize uses
    
    They are relevant only when multiple operands permit registers:
    operand_type_register_match() returns true if either operand is not a
    register one. IOW
    
    grep -i CheckRegSize i386-opc.tbl | grep -Ev "(Reg[8136]|Acc).*,.*(Reg|Acc)"
    
    should produce no output.

commit c5d0745b0d3edfea9e82a4b304ea1847790d72e4
Author: Jan Beulich <jbeulich@novell.com>
Date:   Fri Dec 15 09:12:37 2017 +0100

    x86: correct abort check
    
    I'm rather certain the missing ! was just a typo, the more with the
    similar check in mind that's in the same function a few hundred lines
    down (in the body of "if (vex_reg != (unsigned int) ~0)"). Of course
    this can't be demonstrated by a test case - internal data structure
    consistency is being checked here, and neither form of the check
    triggers with any current template.
    
    It is also not really clear to me why operand_type_equal() is being used
    in the {X,Y,Z}MM register check here, rather than just testing the
    respective bits: Just like Reg32|Reg64 is legal in an operand template,
    I don't see why e.g. RegXMM|RegYMM wouldn't be. For example it ought to
    be possible to combine
    
    vaddpd, 3, 0x6658, None, 1, CpuAVX, Modrm|Vex|VexOpcode=0|VexVVVV=1|VexW=1|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { Xmmword|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S|RegXMM, RegXMM, RegXMM }
    vaddpd, 3, 0x6658, None, 1, CpuAVX, Modrm|Vex=2|VexOpcode=0|VexVVVV=1|VexW=1|IgnoreSize|No_bSuf|No_wSuf|No_lSuf|No_sSuf|No_qSuf|No_ldSuf, { Ymmword|Unspecified|BaseIndex|Disp8|Disp16|Disp32|Disp32S|RegYMM, RegYMM, RegYMM }
    
    into a single template (with setting of VEX.L suitably handled elsewhere
    if that's not already happening anyway).
    
    Additionally I don't understand why this uses abort() instead of
    gas_assert().
    
    Both of these latter considerations then also apply to the
    aforementioned other check in the same function.

commit 2778747c56d0837ec7defb80e756a7e6ca81b8ce
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Dec 15 14:59:58 2017 +1030

    [GOLD] PR22602, handle __tls_get_addr forwarders properly
    
    We never need to resolve_forwards() a symbol found by hash table lookup
    such as target->tls_get_addr_opt() but we do potentially need to do so
    for random symbols seen on relocs.  So these calls were in the wrong
    order, resulting in missing stubs and an assertion failure.
    
    	PR 22602
    	* powerpc.cc (Target_powerpc::Branch_info::mark_pltcall): Resolve
    	forwards before replacing __tls_get_addr.
    	(Target_powerpc::Branch_info::make_stub): Likewise.

commit 828d584679845b6a1d01151f7df3592d15fe8405
Author: Xavier Roirand <roirand@adacore.com>
Date:   Thu Dec 14 22:38:17 2017 -0500

    (Ada) Handle same component names when searching in tagged types
    
    Consider the following code:
    
       type Top_T is tagged record
          N : Integer := 1;
          U : Integer := 974;
          A : Integer := 48;
       end record;
    
       type Middle_T is new Top.Top_T with record
          N : Character := 'a';
          C : Integer := 3;
       end record;
    
      type Bottom_T is new Middle.Middle_T with record
         N : Float := 4.0;
         C : Character := '5';
         X : Integer := 6;
         A : Character := 'J';
      end record;
    
    Tagged records in Ada provide object-oriented features, and what
    is interesting in the code above is that a child tagged record
    introduce additional components (fields) which sometimes have
    the same name as one of the components in the parent. For instance,
    Bottom_T introduces a component named "C", while at the same time
    inheriting from Middle_T which also has a component named "C";
    so, in essence, type Bottom_T has two components with the same name!
    
    And before people start wondering why the language can possibly
    be allowing that, this can only happen if the parent type has
    a private definition. In our case, this was brought to our attention
    when the parent was a generic paramenter.
    
    With that in mind...  Let's say we now have a variable declared
    and initialized as follow:
    
      TC : Top_A := new Bottom_T;
    
    And then we use this variable to call this function
    
      procedure Assign (Obj: in out Top_T; TV : Integer);
    
      as follow:
    
      Assign (Top_T (B), 12);
    
    Now, we're in the debugger, and we're inside that procedure
    (Top.Assign in our gdb testcase), and we want to print
    the value of obj.c:
    
    Usually, the tagged record or one of the parent type owns the
    component to print and there's no issue but in this particular
    case, what does it mean to ask for Obj.C ? Since the actual
    type for object is type Bottom_T, it could mean two things: type
    component C from the Middle_T view, but also component C from
    Bottom_T. So in that "undefined" case, when the component is
    not found in the non-resolved type (which includes all the
    components of the parent type), then resolve it and see if we
    get better luck once expanded.
    
    In the case of homonyms in the derived tagged type, we don't
    guaranty anything, and pick the one that's easiest for us
    to program.
    
    This patch fixes the behavior like described above.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_value_primitive_field): Handle field search
            in case of homonyms.
            (find_struct_field): Ditto.
            (ada_search_struct_field): Ditto.
            (ada_value_struct_elt): Ditto.
            (ada_lookup_struct_elt_type): Ditto.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/same_component_name: New testcase.
    
    Tested on x86_64-linux.

commit 1e5dd7c95a56fd61e6f2deb145ad99153d5336e5
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Dec 15 00:00:27 2017 +0000

    Automatic date update in version.in

commit 8e557e52b3fd45a56fb42dbbaad3d6ece3694eb4
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Dec 14 15:46:47 2017 -0500

    py-breakpoint: Don't use the 'p' PyArg_ParseTupleAndKeywords format specifier
    
    In Python 3, the 'p' format specifier can be passed to
    PyArg_ParseTupleAndKeywords to test the argument for truth and convert
    it to a boolean value (the p stands for predicate).  However, it is not
    available in Python 2, causing this error:
    
      Traceback (most recent call last):
        File "test.py", line 1, in <module>
          b1 = gdb.Breakpoint("foo", qualified=False)
      TypeError: argument 10 (impossible<bad format char>)
    
    This patch changes it to the 'O' specifier, which returns the Python
    object passed in without transformation, and uses PyObject_IsTrue on it.
    This is what is done for the other boolean parameters of this function
    (internal and temporary).
    
    This fixes the test gdb.python/py-breakpoint.exp for Python 2.
    
    gdb/ChangeLog:
    
    	* python/py-breakpoint.c (bppy_init): Use 'O' format specifier
    	for "qualified" and use PyObject_IsTrue.

commit 193e207ca19924f4487e64f3337eb5c8e20fd007
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Dec 14 06:49:37 2017 -0800

    Update binutils-lto-mixed.patch against master

commit 6b8bc4f682c7d7a1af92de113fe5e47362ed1738
Merge: acf1c7c 863f7a5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Dec 14 06:34:44 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 863f7a5f4811c24d9a5863ffb541ff3da1511450
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Dec 14 12:48:55 2017 +0000

    Update the address of the FSF in the copyright notice of files which were using the old address.
    
    top	* COPYING.LIBGLOSS: Update address of FSF in copyright notice.
    
    bfd	* cpu-mt.c: Update address of FSF in copyright notice.
    	* elf32-m32c.c: Likewise.
    	* elf32-mt.c: Likewise.
    	* elf32-rl78.c: Likewise.
    	* elf32-rx.c: Likewise.
    	* elf32-rx.h: Likewise.
    	* elf32-spu.h: Likewise.
    	* hosts/x86-64linux.h: Likewise.
    
    etc	* add-log.el: Update address of FSF in copyright notice.
    
    gas	* config/tc-m32c.c: Update address of FSF in copyright notice.
    	* config/tc-m32c.h: Likewise.
    	* config/tc-mt.c: Likewise.
    	* config/tc-mt.h: Likewise.
    	* config/tc-visium.c: Likewise.
    	* config/tc-visium.h: Likewise.
    	* testsuite/gas/rx/explode: Likewise.
    
    ld	* testsuite/ld-mn10300/mn10300.exp: Update address of FSF in
    	copyright notice.

commit 4baeffab22b564735be14a90f658c1aee1ceec58
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Dec 14 18:57:02 2017 +1030

    binutils nm testsuite tidy
    
    We can run the gnu_unique_object symbol test  on all ELF targets.
    Those that don't support the symbol type and fail to assemble can just
    be resolved as "unsupported".  This means binutils_assemble can't
    report an error on assembly failure, but it probably should never have
    done that anyway.
    
    	* testsuite/lib/utils-lib.exp (default_binutils_assemble_flags):
    	Don't perror on assembler diagnostic output.
    	* testsuite/binutils-all/nm.exp: Run unique symbol test on all
    	ELF targets.  Resolve as "unsupported" on assembly failure.

commit 8af5c486ea6153bb84b9257def4e5faa4bc72421
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Dec 14 10:00:17 2017 +0100

    DWARF-5 .debug_names DW_IDX_type_unit fix
    
    The .debug_names completely misses its support as it did not even produce
    DW_IDX_type_unit.
    
    gdb/ChangeLog
    2017-12-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf2read.c (dw2_debug_names_iterator::next): Support
    	DW_IDX_type_unit.
    	(debug_names::dwarf5_offset_size, unit_kind): New.
    	(debug_names::insert): Add parameter kind.
    	(debug_names::build): Support DW_IDX_type_unit.
    	(debug_names::recursively_write_psymbols): Update
    	(debug_names::write_psymbols caller.
    	(debug_names::write_one_signatured_type_data)
    	(debug_names::write_one_signatured_type): New.
    	(debug_names::index_key, debug_names::symbol_value)
    	(debug_names::write_psymbols): Add kind.
    	(debug_names::write_one_signatured_type): New.
    	(write_debug_names): Move dwarf5_offset_size to debug_names.
    	Use debug_names::write_one_signatured_type for type units.

commit 79e8fcaafa92e7b4a74e510c5487e87c60ff1945
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Dec 14 00:05:24 2017 -0500

    Ada: unable to compare strings (Attempt to compare array with non-array)
    
    Consider the following Ada Code:
    
       type Str is new String (1 .. 4);
       My_str : Str := "ABCD";
    
    This simply declares a 4-character string type. Trying to perform
    equality tests using it currently yield an error:
    
        (gdb) p my_str = my_str
        Attempt to compare array with non-array
        (gdb) p my_str = "ABCD"
        Attempt to compare array with non-array
    
    The error occurs because my_str is defined as an object whose
    type is a typdef to a TYPE_CODE_ARRAY, which ada_value_equal
    is not expecting at all (yet). This patch fixes this oversight.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_value_equal): Add handling of typedef types
            when comparing array objects.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/str_binop_equal: New testcase.
    
    Tested on x86_64-linux.

commit e05fa6f9df82886043e1f1df30e0b9be3fee2d55
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Dec 13 22:36:42 2017 -0500

    (Ada) Add support for task switching when debugging core files
    
    The reasons for not supporting task switching when debugging core files
    appear to now mostly be OBE. In particular, on GNU/Linux, the thread
    layer is now able to retrieve the same thread info as in the live
    process. So, this patch is mostly about just removing the guard
    that limited the use of task switching to live processes.
    
    gdb/ChangeLog:
    
            * ada-tasks.c (read_atcb): Properly set task_info->ptid
            when !target_has_execution as well.
            (task_command): Remove error when !target_has_execution.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/task_switch_in_core: New testcase.

commit b3e7dd3c9d05064d845afafe52a7539948823788
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Dec 14 00:00:20 2017 +0000

    Automatic date update in version.in

commit 25982ee0222196381863a17dc135fc1d2763b385
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Dec 13 14:59:42 2017 -0800

    Add missing RISC-V fsrmi and fsflagsi instructions.
    
    	PR 22599
    	gas/
    	* testsuite/gas/riscv/fsxxi.d, testsuite/gas/riscv/fsxxi.s: New.
    	opcodes/
    	* riscv-opc.c (riscv_opcodes) <fsrmi, fsflagsi>: New.

commit b89641bab55496e52094282fabe146289c57b6d1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Dec 13 11:37:09 2017 -0500

    python: Add qualified parameter to gdb.Breakpoint
    
    This patch adds the possibility to pass a qualified=True|False parameter
    when creating a breakpoint in Python.  It is equivalent to using
    -qualified in a linespec.  The parameter actually accepts any Python
    value, and converts it to boolean using Python's standard rules for
    that (https://docs.python.org/3/library/stdtypes.html#truth).
    
    Unlike the -source/-line/-function/-label parameters, it is possible to
    use -qualified with a "normal" (non-explicit) linespec.  Therefore, it
    is possible (unlike these other parameters) to use this new parameter
    along with the spec parameter.
    
    I updated the py-breakpoint.exp test.  To be able to test multiple
    locations using a namespace, I had to switch the test case to compile as
    C++.  If we really wanted to, we could run it as both C and C++, but
    omit the C++-specific parts when running it as C.
    
    gdb/ChangeLog:
    
    	* location.h (string_to_event_location): Add match_type
    	parameter.
    	* location.c (string_to_event_location): Likewise.
    	* python/py-breakpoint.c (bppy_init): Handle qualified
    	parameter.
    
    gdb/doc/ChangeLog:
    
    	* python.texi (Manipulating breakpoints using Python): Document
    	qualified parameter to gdb.Breakpoint.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-breakpoint.c (foo_ns::multiply): New function.
    	* gdb.python/py-breakpoint.exp: Compile the test case as c++,
    	call test_bkpt_qualified.
    	(test_bkpt_qualified): New proc.

commit 6892d2e4df57160f7103fef0340ae3f55ac8b2b3
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Dec 13 16:38:50 2017 +0000

    Tighten regexp of lib/completion-support.exp:test_gdb_complete_tab_multiple
    
    While writing the tests included in the previous commit, I noticed
    that test_gdb_complete_tab_multiple would not FAIL if GDB happens to
    show more completions than expected before the expected list.
    
    E.g., with something like this, expecting "p foo" to complete to
    "foo2" and "foo3":
    
     test_gdb_complete_tab_multiple "p foo" "" {
    	"foo2"
    	"foo3"
     }
    
    and then if foo actually completes to:
    
     (gdb) p foo[TAB]
     foo1   foo2  foo3
     ^^^^
    
    we'd still PASS.  (Note the spurious "foo1" above.)
    
    This tightens the regexp with a beginning anchor thus making the
    completions above cause a FAIL.  Other similar functions in
    completion-support.exp already do something like this; I had just
    missed this one originally.  Thankfully, this did not expose any
    problems in the gdb.linespec/ tests.  Phew.
    
    gdb/testsuite/ChangeLog:
    2017-12-13  Pedro Alves  <palves@redhat.com>
    
    	* lib/completion-support.exp (test_gdb_complete_tab_multiple):
    	Tighten regexp by matching with an anchor.

commit a22ecf70263eff75ca2c5878fe7e8d0311d6737f
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Dec 13 16:38:50 2017 +0000

    Fix regression: expression completer and scope operator (PR gdb/22584)
    
    I noticed this regression in the expression completer:
    
     "(gdb) p std::[TAB]" => "(gdb) p std::std::"
    
    obviously we should have not completed to "std::std::".
    
    The problem is that in the earlier big completer rework, I missed
    taking into account the fact that with expressions, the completion
    word point is not always at the start of the symbol name (it is with
    linespecs).
    
    The fix is to run the common prefix / LCD string (what readline uses
    to expand the input line) through make_completion_match_str too.
    
    New testcase included, exercising both TAB completion and the complete
    command.
    
    gdb/ChangeLog:
    2017-12-13  Pedro Alves  <palves@redhat.com>
    
    	* completer.c (completion_tracker::maybe_add_completion): New
    	'text' and 'word' parameters.  Use make_completion_match_str.
    	(completion_tracker::add_completion): New 'text' and 'word'
    	parameters.  Pass down.
    	(completion_tracker::recompute_lowest_common_denominator): Change
    	parameter type to gdb::unique_xmalloc_ptr rval ref.  Adjust.
    	* completer.h (completion_tracker::add_completion): New 'text' and
    	'word' parameters.
    	(completion_tracker::recompute_lowest_common_denominator): Change
    	parameter type to gdb::unique_xmalloc_ptr rval ref.
    	(completion_tracker::recompute_lowest_common_denominator): Change
    	parameter type to gdb::unique_xmalloc_ptr rval ref.
    	* symtab.c (completion_list_add_name): Pass down 'text' and 'word'
    	as well.
    
    gdb/testsuite/ChangeLog:
    2017-12-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.cp/cpcompletion.exp: Load completion-support.exp.
    	("expression with namespace"): New set of tests.
    	* gdb.cp/pr9594.cc (Test_NS::foo, Test_NS::bar)
    	(Nested::Test_NS::qux): New.
    	* lib/completion-support.exp (test_gdb_complete_cmd_multiple): Add
    	defaults to 'start_quote_char' and 'end_quote_char' parameters.

commit 60a20c190789fd75d1955576160cbbfe94c792fb
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Dec 13 16:38:49 2017 +0000

    Factor out final completion match string building
    
    We have several places doing essentially the same thing; factor them
    out to a central place.  Some of the places overallocate for no good
    reason, or use strcat unnecessarily.  The centralized version is more
    precise and to the point.
    
    (I considered making the gdb::unique_xmalloc_ptr overload version of
    make_completer_match_str try to realloc (not xrealloc) probably
    avoiding an allocation in most cases, but that'd be probably overdoing
    it, and also, now that I'm writing this I thought I'd try to see how
    could we ever get to filename_completer with "text != word", but I
    couldn't figure it out.  Running the testsuite with 'gdb_assert (text
    == word);' never tripped on the assertion either.  So post gdb 8.1,
    I'll probably propose a patch to simplify filename_completer a bit,
    and the gdb::unique_xmalloc_str overload can be removed then.)
    
    gdb/ChangeLog:
    2017-12-13  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-decode.c (complete_on_cmdlist, complete_on_enum): Use
    	make_completion_match_str.
    	* completer.c: Use gdb::unique_xmalloc_ptr and
    	make_completion_match_str.
    	(make_completion_match_str_1): New.
    	(make_completion_match_str(const char *, const char *,
    	const char *)): New.
    	(make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
    	const char *, const char *)): New.
    	* completer.h (make_completion_match_str(const char *,
    	const char *, const char *)): New.
    	(make_completion_match_str(gdb::unique_xmalloc_ptr<char> &&,
    	const char *, const char *)): New.
    	* interps.c (interpreter_completer): Use make_completion_match_str.
    	* symtab.c (completion_list_add_name, add_filename_to_list): Use
    	make_completion_match_str.

commit 0b982d685e840948eed4619843a0cc5ce8991d6c
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Dec 13 11:26:51 2017 -0500

    python doc: Rework Breakpoint.__init__ doc
    
    I find the documentation of the gdb.Breakpoint constructor hard to read
    and not very informative, especially since we have added the new
    linespec parameters.  There are multiple problems (some are subjective):
    
    - It's not clear that you should use either the spec string or the
      explicit arguments, not both.
    - It's not clear what combination of parameters you can use.
    - The big block of text describing the arguments is hard to read.
    - Currently, it seems like the "spec" argument is mandatory, even though
      it is not (if you use explicit linespec).
    - The square bracket nesting
    
        [arg1 [, arg2[, arg3]]]
    
      makes it seems like if you specify arg3, you must specify arg1 and
      arg2 (it's not the case here).
    
    This patch tries to address these problems.
    
    gdb/doc/ChangeLog:
    
    	* python.texi (Manipulating breakpoints using Python): Split doc
    	of Breakpoint.__init__ in two, split text in multiple
    	paragraphs, don't nest parameter square brackets.

commit 79e741920446582bd0e09f3e2b9f899c258efa56
Author: Renlin Li <renlin.li@arm.com>
Date:   Wed Dec 13 12:11:25 2017 +0000

    [BFD][AARCH64]Disallow R_AARCH64_ABS32(LP64) & R_AARCH64_ABS16 in const section of shared object.
    
    R_AARCH64_ABS64, R_AARCH64_ABS32 and R_AARCH64_ABS16 are data relocations
    supported in AArch64 elf ABI.
    
    R_AARCH64_ABS64 under LP64 is allowed in shared object and a dynamic relocation entry
    will be generated. This allows the dynamic linker to do further symbol resolution.
    R_AARCH64_ABS32 likewise is allowed in shared object, however under ILP32 abi.
    
    The original behavior for R_AARCH64_ABS32 under LP64 is that, it's allowed
    in shared object and silently resolved at static linking time.
    No dynamic relocation entry is generate for it.
    
    R_AARCH64_ABS16 is allowed in shared object under both L64 and ILP32.
    It's resolved at static linking time as well.
    
    Under LP64, the address should be 64-bit. R_AARCH64_ABS32 relocation indicates
    an address that is only sized 32 bits which is meaningless in LP64 shared object.
    It's useful to error out.
    
    I have checked glibc dynamic linker code, R_AARCH64_ABS16 is not supported at all. So
    R_AARCH64_ABS16 should be reject in shared object completely.
    
    In this patch, R_AARCH64_ABS32 is rejected under LP64 in constant section of shared object.
    R_AARCH64_ABS16 is rejected in constant section of shared object in both ABI.
    
    This will sometimes provide useful information for buggy code.

commit 9664701462aec634d304923df8dc9c52c5a92caf
Author: Stafford Horne <shorne@gmail.com>
Date:   Thu Dec 14 00:00:51 2017 +0900

    gdb: Fix ARI warnings in or1k-tdep.c
    
    Fix a few issues not using the gettext _() wrapper and issues where
    we are using %p directly instead of the dedicated host/target functions.
    
    gdb/ChangeLog:
    
    yyyy-mm-dd  Stafford Horne  <shorne@gmail.com>
    
    	* or1k-tdep.c (or1k_analyse_inst): Use _() wrapper for message
    	strings.
    	(or1k_unwind_pc): Use paddress() instead of %p.
    	(or1k_unwind_sp): Likewise.
    	(or1k_frame_cache): Use host_address_to_string()/paddress()
    	instead of %p and use _() wrapper for message strings.

commit 3bbd9f1877bfc5f37ebff1fef2af9eb783f49ace
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Dec 13 09:33:54 2017 -0500

    Fix typo in gdb_ari.sh
    
    gdb/ChangeLog:
    
    	* contrib/ari/gdb_ari.sh: Fix typo in help.

commit 024d185c10a48339ae06634d0738dd796a159cd8
Author: Dimitar Dimitrov <dimitar@dinux.eu>
Date:   Wed Dec 13 13:08:50 2017 +0000

    This patch enables disassembler_needs_relocs for PRU. It is needed to print correct symbols when disassembling arguments of "call" instructions with a relocation.
    
    opcodes	* disassemble.c: Enable disassembler_needs_relocs for PRU.
    
    gas	* testsuite/gas/pru/extern.s: New test for print of U16_PMEMM
    	relocation.
    	* testsuite/gas/pru/extern.d: New test driver.

commit 10e7c0457cb7531f8b205e29e88b3e191cfa6037
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Fri Dec 8 17:23:56 2017 +0100

    S/390: Fix (some) PIE+undef weak failures
    
    This fixes these failures on 64 bit which currently occur when running
    the Binutils testsuite with a default PIE compiler.
    
    < FAIL: Build rdynamic-1
    < FAIL: Build dynamic-1
    < FAIL: Build pr22269-1
    
    bfd/ChangeLog:
    
    2017-12-13  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf64-s390.c (elf_s390_adjust_dynamic_symbol): Use
    	UNDEFWEAK_NO_DYNAMIC_RELOC.
    	(allocate_dynrelocs): Likewise.
    	(elf_s390_relocate_section): Check resolved_to_zero.
    	(elf_s390_finish_dynamic_symbol): Don't generate runtime reloc if
    	UNDEFWEAK_NO_DYNAMIC_RELOC.

commit 9937536c23ae005422cec23d38a6b7f6fa8e1f48
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Dec 11 23:51:29 2017 -0500

    fix "server" command prefix handling (unexpected confirmation queries)
    
    The "server" command prefix no longer turns confirmation queries off.
    We can reproduce this with any program by tring to delete all breakpoints,
    for instance:
    
        (gdb) break main
        Breakpoint 1 at 0x40049b: file /[...]/break-fun-addr1.c, line 21.
        (gdb) server delete breakpoints
        Delete all breakpoints? (y or n)
    
    GDB should not be asking "Delete all breakpoints? (y or n)", but
    instead just delete all breakpoints without asking for confirmation.
    
    Looking at utils.c::defaulted_query gives a glimpse of how this feature
    is expected to work:
    
      /* Automatically answer the default value if the user did not want
         prompts or the command was issued with the server prefix.  */
      if (!confirm || server_command)
        return def_value;
    
    So, it relies on the server_command global to be set when the "server "
    command prefix is used, which is no longer the case since the following
    commit:
    
        commit b69d38afdea34e4fecab5ea47ffe1e594e0b6233
        Date:   Wed Mar 9 18:25:00 2016 +0000
        Subject: Command line input handling TLC
    
    The patch was simplifying the handling for the command line, and
    I believe there was just a small oversight of removing the setting
    of the server_command global.
    
    This patch restores that, and adds a testcase to make sure we test
    that feature.
    
    gdb/ChangeLog:
    
            * event-top.c (handle_line_of_input): Set server_command.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.base/server-del-break.c: New file.
            * gdb.base/server-del-break.exp: New file.
    
    Tested on x86_64-linux, no regression.

commit 2c66e1634c92040a8fcb9590cd80fe881def0b20
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Dec 13 00:00:21 2017 +0000

    Automatic date update in version.in

commit 702d582e2c5ab9fbd6e9a68f26d49575bfe7e062
Author: Peter Gavin <pgavin@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: testsuite: add testsuite for or1k sim
    
    This is the testsuite for the or1k sim, it tests running many of the
    basic architecture instructions on the openrisc sim.
    
    sim/testsuite/sim/or1k/ChangeLog:
    
    2017-12-12  Peter Gavin  <pgavin@gmail.com>
    	    Stafford Horne <shorne@gmail.com>
    
    	* add.S: New file.
    	* alltests.exp: New file.
    	* and.S: New file.
    	* basic.S: New file.
    	* div.S: New file.
    	* ext.S: New file.
    	* find.S: New file.
    	* flag.S: New file.
    	* fpu.S: New file.
    	* jump.S: New file.
    	* load.S: New file.
    	* mac.S: New file.
    	* mfspr.S: New file.
    	* mul.S: New file.
    	* or.S: New file.
    	* or1k-asm-test-env.h: New file.
    	* or1k-asm-test-helpers.h: New file.
    	* or1k-asm-test.h: New file.
    	* or1k-asm.h: New file.
    	* or1k-test.ld: New file.
    	* ror.S: New file.
    	* shift.S: New file.
    	* spr-defs.h: New file.
    	* sub.S: New file.
    	* xor.S: New file.
    
    sim/testsuite/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Peter Gavin  <pgavin@gmail.com>
    
    	* configure: Regenerated.

commit 0cd79707332aef140efa2275363c40aaaeba1c22
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: or1k: add autoconf generated files
    
    These are separted out to make the patch easier to read and smaller.
    
    sim/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Peter Gavin  <pgavin@gmail.com>
    
    	* configure: Regenerated.
    	* or1k/aclocal.m4: Generated.
    	* or1k/config.in: Generated.
    	* or1k/configure: Generated.

commit 6e51bfa75535439cc66039bcf4e8ebf16e8fe124
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: or1k: add cgen generated files
    
    These are the simulator files generated by cgen.  These are split out
    from the main sim patch to make the patch easier to review and smaller.
    
    sim/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Peter Gavin  <pgavin@gmail.com>
    
    	* or1k/arch.c: Generated.
    	* or1k/arch.h: Generated.
    	* or1k/cpu.c: Generated.
    	* or1k/cpu.h: Generated.
    	* or1k/cpuall.h: Generated.
    	* or1k/decode.c: Generated.
    	* or1k/decode.h: Generated.
    	* or1k/model.c: Generated.
    	* or1k/sem-switch.c: Generated.
    	* or1k/sem.c: Generated.

commit fa8b7c2128cd03135b7d31ae2ecbc2d3273e990d
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: or1k: add or1k target to sim
    
    This adds the OpenRISC 32-bit sim target.  The OpenRISC sim is a CGEN
    based sim so the bulk of the code is generated from the .cpu files by
    CGEN.  The engine decode and execute logic in mloop uses scache with
    pseudo-basic-block extraction and supports both full and fast (switch)
    modes.
    
    The sim does not implement an mmu at the moment.  The sim does implement
    fpu instructions via the common sim-fpu implementation.
    
    sim/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Peter Gavin  <pgavin@gmail.com>
    
    	* configure.tgt: Add or1k sim.
    	* or1k/README: New file.
    	* or1k/Makefile.in: New file.
    	* or1k/configure.ac: New file.
    	* or1k/mloop.in: New file.
    	* or1k/or1k-sim.h: New file.
    	* or1k/or1k.c: New file.
    	* or1k/sim-if.c: New file.
    	* or1k/sim-main.h: New file.
    	* or1k/traps.c: New file.

commit 58884b0e451043ed2fb4d2fba18134f0fb451ce5
Author: Peter Gavin <pgavin@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: cgen: add MUL2OFSI and MUL1OFSI functions (needed for OR1K l.mul[u])
    
    sim/common/ChangeLog:
    
    2017-12-12  Peter Gavin  <pgavin@gmail.com>
    	    Stafford Horne  <shorne@gmail.com>
    
    	* cgen-ops.h (MUL2OFSI): New function, 2's complement overflow
    	flag.
    	(MUL1OFSI): New function, 1's complement overflow flag.

commit 07b95864f35f19636e2a95eaf3083a8b18ac7cda
Author: Peter Gavin <pgavin@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    sim: cgen: add remainder functions (needed for OR1K lf.rem.[sd])
    
    * sim/common/ChangeLog:
    
    2017-12-12  Peter Gavin  <pgavin@gmail.com>
    	    Stafford Horne <shorne@gmail.com>
    
    	* cgen-accfp.c (remsf, remdf): New function.
    	(cgen_init_accurate_fpu): Add remsf and remdf.
    	* cgen-fpu.h (cgen_fp_ops): Add remsf, remdf, remxf and remtf.
    	* sim-fpu.c (sim_fpu_rem): New function.
    	* sim-fpu.h (sim_fpu_status_invalid_irx): New enum.
    	(sim_fpu_rem): New function.
    	(sim_fpu_print_status): Add case for sim_fpu_status_invalid_irx.

commit 638d913757609367eea219d00296a0a3d45010c2
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    Add gdb for or1k build
    
    * ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    
    	* configure.ac: Remove logic adding gdb to noconfigsdirs for or1k.
    	* configure: Regenerate.
    
    Cc: gcc-patches@gcc.gnu.org

commit fe49c6f559b67fee381f0c2a6f67c10ca306ca8a
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    gdb: testsuite: Add or1k tdesc-regs.exp test support
    
    gdb/testsuite/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.xml/tdesc-regs.exp: Add or1k support.

commit c3d186206bf04a40244e727fa381f78a1600f196
Author: Stafford Horne <shorne@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    gdb: testsuite: Add or1k l.nop instruction
    
    The test case requires adding a nop instruction.  For or1k the
    instruction is `l.nop`. This change uses the correct operation.
    
    gdb/testsuite/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    
    	* gdb.base/bp-permanent.c: Define nop of or1k.

commit a994fec4f8f7a886be61cfb3023c354cd2483b9d
Author: Franck Jullien <franck.jullien@gmail.com>
Date:   Sat Dec 9 05:57:25 2017 +0900

    gdb: Add OpenRISC or1k and or1knd target support
    
    This patch prepares the current GDB port of the OpenRISC processor from
    https://github.com/openrisc/binutils-gdb for upstream merging.
    
    Testing has been done with a cgen sim provided in a separate patch. This
    has been tested with 2 toolchains. GCC [1] 5.4.0 from the OpenRISC
    project with Newlib [2] and GCC 5.4.0 with Musl [3] 1.1.4.
    
    It supports or1knd (no delay slot target).
    The default target is or1k (with delay slot).
    
    You can change the target arch with:
    
    (gdb) set architecture or1knd
    The target architecture is assumed to be or1knd
    
    [1] https://github.com/openrisc/or1k-gcc
    [2] https://github.com/openrisc/newlib
    [3] https://github.com/openrisc/musl-cross
    
    gdb/doc/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Stefan Wallentowitz  <stefan@wallentowitz.de>
    	    Franck Jullien  <franck.jullien@gmail.com>
    	    Jeremy Bennett  <jeremy.bennett@embecosm.com>
    
    	* gdb.texinfo: Add OpenRISC documentation.
    
    gdb/ChangeLog:
    
    2017-12-12  Stafford Horne  <shorne@gmail.com>
    	    Stefan Wallentowitz  <stefan@wallentowitz.de>
    	    Stefan Kristiansson  <stefan.kristiansson@saunalahti.fi>
    	    Franck Jullien  <franck.jullien@gmail.com>
    	    Jeremy Bennett  <jeremy.bennett@embecosm.com>
    
    	* configure.tgt: Add targets for or1k and or1knd.
    	* or1k-tdep.c: New file.
    	* or1k-tdep.h: New file.
    	* features/Makefile: Add or1k.xml to build.
    	* features/or1k.xml: New file.
    	* features/or1k-core.xml: New file.
    	* features/or1k.c: Generated.

commit db9077b7275e86637218a7a7d165cb85a4de116f
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Dec 11 17:31:11 2017 +1030

    PR22576, ppc64_skip_trampoline_code uses wrong r2 for EXEC_REVERSE
    
    The TOC pointer register, r2, on powerpc64 is generally not mentioned
    in debug info.  It is saved and restored by call linkage code, and
    set to the callee value either by call stub code (ELFv1) or in the
    callee global entry point code (ELFv2).  A call stub uses the caller
    TOC pointer to access the PLT.  So for gdb to read the correct PLT
    entry in order to determine the destination of the trampoline, gdb
    needs to know the caller r2.  When skipping over trampolines in the
    normal forward direction, the caller r2 is simply the current value of
    r2 (at the start of the trampoline).  However, when reversing over
    trampolines the current value of r2 is that for the callee.  Using
    that value results in wild reads of memory rather than the correct PLT
    entry.
    
    This patch corrects the value of r2 by using the value saved on the
    stack for reverse execution.  Note that in reverse execution mode it
    isn't really necessary for skip_trampoline_code to return the actual
    destination, so we're doing a little more work than needed here.  Any
    non-zero return value would do (and it would be nicer if the interface
    was changed to return the start of the stub).
    
    	PR tdep/22576
    	* ppc64-tdep.c (ppc64_plt_entry_point): Rewrite to take TOC-relative
    	PLT offset, and retrieve r2 from stack when executing in reverse.
    	(ppc64_standard_linkage1_target): Drop pc param.  Calculate offset
    	rather than PLT address.
    	(ppc64_standard_linkage2_target): Likewise.
    	(ppc64_standard_linkage3_target): Likewise.
    	(ppc64_standard_linkage4_target): Likewise.
    	(ppc64_skip_trampoline_code_1): Adjust to suit.

commit a933405894161c8b15f675c48d077b7f7d6aabf2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Dec 11 21:05:30 2017 -0500

    remote: Return NULL extra_info/name if they are empty
    
    Commit
    
      remote: C++ify thread_item and threads_listing_context
      21fe1c752e254167d953fa8c846280f63a3a5290
    
    broke the test gdb.threads/names.exp.  The problem is that since we now
    use an std::string to hold the extra_info, an empty string is returned
    by target_extra_thread_info to print_thread_info_1 when the remote stub
    didn't send any extra info, instead of NULL before.  Because of that,
    print_thread_info_1 prints the extra info between parentheses, which
    results in some spurious empty parentheses.
    
      Expected: * 1    Thread 22752.22752 "main" all_threads_ready () at ...
      Actual  : * 1    Thread 22752.22752 "main" () all_threads_ready () a ...
    
    Since the bug was introduced by a behavior change in the remote target,
    I chose to fix it on the remote target side by making it return NULL
    when the extra string is empty.  This will avoid possibly changing the
    behavior of the common code and affecting other targets.
    
    The name field has the same problem.  If a remote stub returns no thread
    names, remote_thread_name will return an empty string instead of NULL,
    so print_thread_info_1 will show empty quotes ("") instead of nothing.
    
    gdb/ChangeLog:
    
    	PR gdb/22556
    	* remote.c (remote_thread_name): Return NULL if name is empty.
    	(remote_threads_extra_info): Return NULL if extra info is empty.

commit 4b1c0f7e85f2aec3df3498d04b5beaf45813dea8
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Dec 12 10:56:23 2017 +1030

    Don't mask X_add_number containing a register number
    
    It's obviously wrong to mask SPRs to 8 bits.
    
    	PR 21118
    	* config/tc-ppc.c (md_assemble): Don't mask register number.

commit dce4fb839ca81ba4aefa9f5dfde8c8041826b3bb
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Dec 12 00:00:33 2017 +0000

    Automatic date update in version.in

commit c4e648430f3c5c135310f87280d45dba581aaa7b
Author: Stephen Crane <sjc@immunant.com>
Date:   Mon Dec 11 14:58:38 2017 -0800

    Add plugin API for processing plugin-added input files
    
    Gold plugins may wish to further process an input file added by a plugin. For
    example, the plugin may need to assign a unique segment for sections in a
    plugin-generated input file. This patch adds a plugin callback that the linker
    will call when reading symbols from a new input file added after the
    all_symbols_read event (i.e. an input file added by a plugin).
    
    2017-12-11  Stephen Crane  <sjc@immunant.com>
    
    	* plugin-api.h: Add new plugin hook to allow processing of input
    	files added by a plugin.
    	(ld_plugin_new_input_handler): New function hook type.
    	(ld_plugin_register_new_input): New interface.
    	(LDPT_REGISTER_NEW_INPUT_HOOK): New enum val.
    	(tv_register_new_input): New member.
    
    	* plugin.cc (Plugin::load): Include hooks for register_new_input
    	in transfer vector.
    	(Plugin::new_input): New function.
    	(register_new_input): New function.
    	(Plugin_manager::claim_file): Call Plugin::new_input if in
    	replacement phase.
    	* plugin.h (Plugin::set_new_input_handler): New function.
    	* testsuite/plugin_new_section_layout.c: New plugin to test
    	new_input plugin API.
    	* testsuite/plugin_final_layout.sh: Add new input test.
    	* testsuite/Makefile.am (plugin_layout_new_file): New test case.
    	* testsuite/Makefile.in: Regenerate.

commit 4c5ae11b42433dbffc33fbde75c9e415594504d8
Author: Renlin Li <renlin.li@arm.com>
Date:   Mon Dec 11 15:33:18 2017 +0000

    [Binutils][Objdump]Check symbol section information while search a mapping symbol backward.
    
    When checking mapping symbols backwardly, the section which defines the symbol
    is not considerted. This patch fixes this by moving the section checking code
    into get_sym_code_type () function which is shared by forward and backword
    mapping symbol searching.
    
    opcodes/
    
    2017-12-11  Petr Pavlu  <petr.pavlu@arm.com>
    	    Renlin Li  <renlin.li@arm.com>
    
    	* aarch64-dis.c (print_insn_aarch64): Move symbol section check ...
    	(get_sym_code_type): Here.
    
    binutils/
    
    2017-12-11  Renlin Li  <renlin.li@arm.com>
    
    	* testsuite/binutils-all/aarch64/objdump.d: New.
    	* testsuite/binutils-all/aarch64/objdump.s: New.

commit 3c0aa29aab3949363f8b23d062c2e0cb1ccf017a
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Dec 11 13:24:32 2017 +0000

    Unbreak build for non-ELF ports
    
    As reported at
    <https://sourceware.org/ml/gdb-patches/2017-12/msg00229.html>, this
    commit:
    
    ~~~~
     commit abccd1e7b7a37385159610ca4e0bc2632a547e9a
     Author:     Jan Kratochvil <jan.kratochvil@redhat.com>
     AuthorDate: Fri Dec 8 22:44:11 2017 +0000
    
         Change dwarf2_initialize_objfile's return value
    
         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.
    ~~~~
    
    breaks non-ELF-target builds:
    
     dwarf2read.o: In function `dwarf2_initialize_objfile(objfile*)':
     /home/yao.qi/SourceCode/gnu/binutils-gdb/gdb/dwarf2read.c:6486:
     undefined reference to `elf_sym_fns_gdb_index'
     /home/yao.qi/SourceCode/gnu/binutils-gdb/gdb/dwarf2read.c:6490:
     undefined reference to `elf_sym_fns_debug_names'
     /home/yao.qi/SourceCode/gnu/binutils-gdb/gdb/dwarf2read.c:6495:
     undefined reference to `elf_sym_fns_lazy_psyms'
     collect2: error: ld returned 1 exit status
    	 Makefile:1920: recipe for target 'gdb' failed
    
    because gdb/elfread.c is not included in the gdb build unless bfd also
    includes elf support.
    
    Fix this by reverting the patch mentioned above and at the same time
    re-adding .debug_names support by adding a new output parameter to
    dwarf2_initialize_objfile to indicate the index variant in use.  We
    can reuse the new dw_index_kind enum in dwarf2read.c for that.
    
    gdb/ChangeLog:
    2017-12-11  Pedro Alves  <palves@redhat.com>
    
    	* defs.h (elf_sym_fns_lazy_psyms, elf_sym_fns_gdb_index)
    	(elf_sym_fns_debug_names): Move to elfread.c.
    	* dwarf2read.c (dwarf2_initialize_objfile): Return a boolean
    	instead of a sym_fns and add 'index_kind' output parameter.  Fill
    	the latter in with the index variant kind if using an index.
    	(enum dw_index_kind): Moved to symfile.h.
    	* elfread.c (elf_sym_fns_gdb_index, elf_sym_fns_debug_names)
    	(elf_sym_fns_lazy_psyms): Move from defs.h.
    	(elf_symfile_read): Adjust to new dwarf2_initialize_objfile
    	interface.
    	* symfile.h (enum class dw_index_kind): New, moved from
    	dwarf2read.c.
    	(dwarf2_initialize_objfile): Change prototype.

commit f2f9e7ecc1f02bfe5da83c38cf356ea96d428c6d
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Dec 11 15:26:26 2017 +0100

    [MPFR] Fix regression on 32-bit host systems
    
    When converting parts of the mantissa to MPFR, we need to make sure to do
    an *unsigned* conversion.  Since we convert at most 32 bits at a time,
    stored in an unsigned long, this doesn't matter on systems where "long"
    is larger than 32 bits.  But on systems where it is 32 bits, we can get
    conversion errors.
    
    gdb/ChangeLog
    2017-12-11  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c (mpfr_float_ops::from_target): Use mpfr_set_ui
    	instead of mpfr_set_si to convert mantissa bits.

commit c5f9cfc894373abd00ee56c6723ee0ba95a84f95
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Dec 11 00:55:36 2017 -0500

    Adapt gdb.ada/variant_record_packed_array.exp to accept reordered components
    
    Recent versions of GNAT are capable of reordering record components
    to make their access for efficient. This patch adapts this test to
    accept both cases (reordered or not).
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/variant_record_packed_array.exp: Adapt test to accept
            output with components being reordered.
    
    Tested on x86_64-linux.

commit 08f49010a10b1fc98f65aada96e788c87c56ad85
Author: Xavier Roirand <roirand@adacore.com>
Date:   Mon Dec 11 00:22:14 2017 -0500

    (Ada) change tagged types base_address computation
    
    There was a difference between C++ dispatch table and Ada's in the
    way the Offset_To_Top field is used to determined the base address
    of an object:
    
    * in C++ it is a negative offset, so converting abstract interface to
    deriving object requires adding this offset to â??thisâ??;
    
    * in Ada, it was a positive offset, so the same conversion required
    subtracting the offset value.
    
    So in ada, the base address for a tagged type was computed using this formula:
    
    base_address = value_address (obj) - offset_to_top;
    
    The offset_to_top value was previously set to 0 or a positive value.
    With recent version of AdaCore's GNAT compiler, the offset has been
    changed to match C++, which means it's set to zero or a negative value
    
    As a result, the new formula has to be:
    
    base_address = value_address (obj) + offset_to_top;
    
    Because we want to support old code compiled before GNAT compiler change
    done in 19.0w (20171023-64) with this version and future versions of gdb,
    then we change the sign of the offset_to_top if required. Required here
    means if offset_to_top is positive since it indicates that the code has
    been compiled with an old GNAT compiler.
    
    This patch changes the formula as described above.
    
    Also, one side-effect of offset_to_top now being negative is that
    we now have to worry about the sign when we read its value from the
    inferior. Up to now, we have been reading its value using the data
    address builtin type. But since addresses are not always signed, we
    now need to make sure we use the proper type (type Storage_Offset
    from System.Storage_Elements). Ideally, we would be looking this type
    up from the inferior, and then use that type. However, it is not
    guaranteed that this type always be described in the debugging
    information, so this patch just builds our own, adding it to Ada's
    list of primitive types.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_tag_value_at_base_address): Change the way
            tagged type base address is computed.
            (enum ada_primitive_types) <ada_primitive_type_storage_offset>:
            New enumerate.
            (ada_language_arch_info): Set the ada_primitive_type_storage_offset
            element of lai->primitive_type_vector.
    
    Tested on x86_64-linux. Fixes the following tests when using the newer
    version of the compiler.
    
        gdb.ada/iwide.exp: print My_Drawable
        gdb.ada/iwide.exp: print d_access.all
        gdb.ada/iwide.exp: print dp_access.all
        gdb.ada/mi_interface.exp: create ggg1 varobj (unexpected output)
        gdb.ada/mi_interface.exp: list ggg1's children (unexpected output)
        gdb.mi/mi-var-rtti.exp: run to mi-var-rtti.cc:63 (set breakpoint) (unexpected output)
        gdb.mi/mi-var-rtti.exp: run to mi-var-rtti.cc:63 (set breakpoint)

commit a9c135fc7d0c005246849ff6b205fd5090248137
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Dec 11 00:16:31 2017 -0500

    Adapt gdb.ada/pkd_arr_elem.exp to accept reordered components
    
    Recent versions of GNAT are capable of reordering record components
    to make their access for efficient. This patch adapts this test to
    accept both cases (reordered or not).
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/pkd_arr_elem.exp: Adapt "print test" test to accept
            output with components being reordered.

commit 75323ba0a7588fcd6c8505077719abd50cae71e3
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Dec 11 00:00:20 2017 +0000

    Automatic date update in version.in

commit 57a2957f2ead9ec2464a1b6fbdb250e90d27afab
Author: Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
Date:   Mon Dec 11 08:17:15 2017 +1030

    Typo fix
    
    Entirely the fault of that Alan Modra bloke.
    
    	* bfd.c (bfd_get_sign_extend_vma): Correct typo.

commit 8bcf9b03922298bb6870b7163be90163c422973a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Dec 10 00:00:26 2017 +0000

    Automatic date update in version.in

commit c5ba17787d077249ab7071192566a2c0205fc97f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Dec 9 00:00:14 2017 +0000

    Automatic date update in version.in

commit a3c5fafd2e0bc8c1ea98c579c0a044c5b324967b
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Dec 8 22:44:14 2017 +0000

    dwarf2read.c: Rewrite/simplify mock_mapped_index
    
    Now that dw2_expand_symtabs_matching_symbol works with the abstract
    mapped_index_base, we can make mock_mapped_index inherit
    mapped_index_base too instead of having it pretend to be a real
    .gdb_index table.
    
    gdb/ChangeLog:
    2017-12-08  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (mock_mapped_index): Reimplement as an extension of
    	mapped_index_base.
    	(check_match): Adjust to use mock_index directly.
    	(check_find_bounds_finds)
    	(test_mapped_index_find_name_component_bounds): Adjust to work
    	with a mapped_index_base.

commit 44ed8f3ed0264016a12cfde3126f9148c07eabfa
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Dec 8 22:44:13 2017 +0000

    Support wildmatching in .debug_names too.
    
    dw2_debug_names_expand_symtabs_matching currently doesn't support
    symbol_name_match_type::WILD, it always matches symbol names fully.
    
    The .gdb_index code supports via dw2_expand_symtabs_matching_symbol,
    which builds the mapped_index::name_components table on demand, and
    then binary searches that table.
    
    The .debug_names names index is pretty much the same as the .gdb_index
    names index, i.e., a list of fully-qualified names with no
    parameter/overload info.  (There's no
    what-is-the-language-of-symbol-name info in .debug_names either,
    unfortunately.)
    
    So this fixes .debug_names by factoring out the related .gdb_index
    code out of the mapped_index class to a base class that is inherited
    by both the .gdb_index (mapped_index) and .debug_names
    (mapped_debug_names) map classes.
    
    gdb/ChangeLog:
    2017-12-08  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (struct mapped_index_base): New, partially factored
    	out from ...
    	(struct mapped_index): ... this.  Inherit mapped_index_base.
    	(mapped_index::symbol_name_slot_invalid):
    	(mapped_index::symbol_name_at): Add override marker.
    	(mapped_index::symbol_name_count): New.
    	(struct mapped_debug_names): Inherit mapped_index_base.
    	(mapped_debug_names::symbol_name_at): New.
    	(mapped_debug_names::symbol_name_count): New.
    	(mapped_index::find_name_components_bounds): Rename to ...
    	(mapped_index_base::find_name_components_bounds): ... this.
    	(mapped_index::build_name_components): Rename to ...
    	(mapped_index_base::build_name_components): ... this.  Adjust to
    	use mapped_index_base::symbol_name_count and
    	mapped_index_base::symbol_name_slot_invalid.
    	(dw2_expand_symtabs_matching_symbol): Take a mapped_index_base
    	instead of a mapped_index.  Use
    	dw2_expand_symtabs_matching_symbol.

commit f00a2de2a7556c59bce93f7ced44afa8e1bbf7c3
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Dec 8 22:44:13 2017 +0000

    dwarf2read.c:mapped_index, use gdb::array_view, simplify symbol table
    
    This replaces a couple ptr+size pairs with gdb::array_view in the
    .gdb_index code, and simplifies things by using an aggregate for the
    type of the symbol table hash bucket instead of having to consider the
    distinction between size of table vs number of slots and access name
    vs vec by index.
    
    gdb/ChangeLog:
    2017-12-08  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (mapped_index::symbol_table_slot): New.
    	(mapped_index::address_table): Now a gdb::array_view of const
    	gdb_byte.
    	(mapped_index::symbol_table): Now a gdb::array_view of
    	symbol_table_slot.
    	(mapped_index::address_table_size)
    	(mapped_index::symbol_table_slots): Delete.
    	(create_addrmap_from_index): Adjust.
    	(find_slot_in_mapped_hash): Adjust.
    	(read_index_from_section): Adjust.
    	(dwarf2_read_index): Adjust.

commit 927aa2e778dce440f4de5de8fc37ead1683a804e
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Dec 8 22:44:12 2017 +0000

    DWARF-5: .debug_names index consumer
    
    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.
    
    gdb/ChangeLog:
    2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* defs.h (elf_sym_fns_debug_names): New declaration.
    	* dwarf2read.c: Include "hash_enum.h".
    	(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_per_objfile::locate_sections): Handle debug_names and
    	debug_aranges.
    	(locate_dwz_sections): Handle debug_names.
    	(create_signatured_type_table_from_debug_names)
    	(create_addrmap_from_aranges): New.
    	(dwarf2_read_index): Update function comment.
    	(dwarf5_augmentation): Moved up.
    	(read_debug_names_from_section, create_cus_from_debug_names_list)
    	(create_cus_from_debug_names, dwarf2_read_debug_names): New.
    	(dwarf5_djb_hash): Moved up.
    	(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::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.
    	(debug_names::djb_hash): Rename it to dwarf5_djb_hash.
    	(debug_names::build): Update djb_hash caller.
    	(write_debug_names): Move out and rename augmentation to
    	dwarf5_augmentation.
    	* 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-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
    	    Pedro Alves  <palves@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 e5fa6583a7b1e5e0e0f33a4964a1f271e189cf35
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Dec 8 22:44:12 2017 +0000

    Add gdb::hash_enum
    
    The DWARF-5 .debug_names consumer patch will want to use an
    std::unordered_map with an enum as key type, like:
    
    	std::unordered_map<sect_offset, dwarf2_per_cu_data*>
    
    That doesn't work in C++11 in non-recent compilers due to a language
    defect:
    
     http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2148
    
    ~~~
      In file included from /usr/include/c++/5.3.1/bits/hashtable.h:35:0,
    		   from /usr/include/c++/5.3.1/unordered_set:47,
    		   from src/gdb/dwarf2read.c:79:
      /usr/include/c++/5.3.1/bits/hashtable_policy.h: In instantiation of â??struct std::__detail::__is_noexcept_hash<sect_offset, std::hash<sect_offset> >â??:
      /usr/include/c++/5.3.1/type_traits:137:12:   required from â??struct std::__and_<std::__is_fast_hash<std::hash<sect_offset> >, std::__detail::__is_noexcept_hash<sect_offset, std::hash<sect_offset> > >â??
      /usr/include/c++/5.3.1/type_traits:148:38:   required from â??struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<sect_offset> >, std::__detail::__is_noexcept_hash<sect_offset, std::hash<sect_offset> > > >â??
      /usr/include/c++/5.3.1/bits/unordered_map.h:100:66:   required from â??class std::unordered_map<sect_offset, dwarf2_per_cu_data*>â??
      src/gdb/dwarf2read.c:3260:30:   required from here
      /usr/include/c++/5.3.1/bits/hashtable_policy.h:85:34: error: no match for call to â??(const std::hash<sect_offset>) (const sect_offset&)â??
        noexcept(declval<const _Hash&>()(declval<const _Key&>()))>
    				    ^
      In file included from /usr/include/c++/5.3.1/bits/move.h:57:0,
    		   from /usr/include/c++/5.3.1/bits/stl_pair.h:59,
    		   from /usr/include/c++/5.3.1/bits/stl_algobase.h:64,
    		   from /usr/include/c++/5.3.1/bits/char_traits.h:39,
    		   from /usr/include/c++/5.3.1/string:40,
    		   from /home/pedro/gdb/mygit/src/gdb/common/common-utils.h:23,
    		   from /home/pedro/gdb/mygit/src/gdb/common/common-defs.h:78,
    		   from /home/pedro/gdb/mygit/src/gdb/defs.h:28,
    		   from /home/pedro/gdb/mygit/src/gdb/dwarf2read.c:31:
    ~~~
    
    This commits adds a helper replacement.
    
    gdb/ChangeLog:
    2017-12-08  Pedro Alves  <palves@redhat.com>
    
    	* common/hash_enum.h: New file.

commit 4b514bc80885fa91e57b9d80f74ea267df343c46
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Dec 8 22:44:11 2017 +0000

    Refactor: Move some generic code out of .gdb_index code
    
    Preparation for the next patch.
    
    gdb/ChangeLog
    2017-12-08  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 abccd1e7b7a37385159610ca4e0bc2632a547e9a
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Dec 8 22:44:11 2017 +0000

    Change dwarf2_initialize_objfile's return value
    
    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.
    
    gdb/ChangeLog
    2017-12-08  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 437afbb81e3a04cbd933fc534a50c686eaa63b19
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Dec 8 22:44:10 2017 +0000

    DWARF-5: .debug_names index producer
    
    This adds a new "-dwarf-5" switch to "save gdb-index" that makes it
    generate index files with DWARF-5 .debug_names/.debug_str sections
    instead of GDB's own .gdb_index.
    
    We should probably add a command line option to
    contrib/gdb-add-index.sh (incl. cc-with-tweaks.sh) for the new
    -dwarf-5 GDB option, and a new target board to make it more convenient
    to exercise this.  To be done later.
    
    gdb/ChangeLog
    2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
    	    Pedro Alves  <palves@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, set, list.
    	(INDEX_SUFFIX): Rename to ...
    	(INDEX4_SUFFIX): ... here.
    	(INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
    	(file_write(FILE *, const void *, size_t)): New.
    	(file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
    	(data_buf::append_unsigned_leb128, data_buf::empty): New.
    	(data_buf::file_write): Use ::file_write.
    	(data_buf::c_str, dwarf5_djb_hash, debug_names)
    	(check_dwarf64_offsets): New.
    	(psyms_seen_size, write_gdbindex): New from
    	write_psymtabs_to_index code.
    	(dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
    	(enum dw_index_kind): New.
    	(write_psymtabs_to_index): New parameter index_kind.  Support
    	filename_str and out_file_str.  Move code to write_gdbindex,
    	possibly call write_debug_names.
    	(save_gdb_index_command): New parameter -dwarf-5.
    	(_initialize_dwarf2_read): Document the new parameter -dwarf-5.
    
    gdb/doc/ChangeLog
    2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gdb.texinfo (Index Files): Document .debug_names and -dwarf-5.
    --
    
     gdb/contrib/gdb-add-index.sh |   53 ++
     gdb/doc/gdb.texinfo          |   24 +
     gdb/dwarf2read.c             |  919 ++++++++++++++++++++++++++++++++++++++++--
     3 files changed, 935 insertions(+), 61 deletions(-)

commit 6432ec65a8822246db5bcede0c6bd3ed0e464a0b
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Dec 8 22:44:10 2017 +0000

    cc-with-tweaks.sh: Use gdb-add-index.sh
    
    With DWARF-5 .debug_names, the commands to add the index to the symbol
    file are more complicated, as now also .debug_str needs to be
    modified.
    
    Currently, contrib/cc-with-tweaks.sh calls objcopy to handle the '-i'
    option instead of using contrib/gdb-add-index.sh which basically does
    the same.  To help with .debug_names, this commit makes
    contrib/cc-with-tweaks.sh reuse contrib/gdb-add-index.sh instead.
    
    A problem this ran into is whether contrib/cc-with-tweaks.sh should
    fail or not when no index is produced.
    
    Currently, contrib/cc-with-tweaks.sh is more quiet (=successful) than
    contrib/gdb-add-index.sh and so with no further changes testsuite runs
    with an index would "regress".  This commit tries 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 gdb/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
    
    gdb/ChangeLog
    2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
    	comment.
    	(GDB_ADD_INDEX): New variable.
    	<$want_index>: Call $GDB_ADD_INDEX.

commit a9d44aad42e127adadbad35f23931d8d83aa40c1
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Dec 8 11:40:31 2017 +1030

    Work around sparc glibc bug
    
    	* elfxx-sparc.c (_bfd_sparc_elf_relocate_section): When emitting
    	dynamic R_SPARC_RELATIVE for GOT entries, ensure the section
    	contents are zeroed.

commit 92469284a650232768523564f2c715c4ebb57906
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Dec 8 15:33:55 2017 -0500

    Fix thinko on dtrace-probe.c:dtrace_process_dof_probe
    
    While investigating PR gdb/22557 ("Regression:
    gdb.base/dtrace-probe.exp"), I noticed that the code is wrongly
    declaring a new "expression_up" variable inside the TRY block in
    "dtrace_process_dof_probe".  This causes the outter "expr" variable to
    be empty, which may have an impact later when evaluating the
    expression.
    
    This commit fixes that.  Unfortunately the script used to test DTrace
    probes (gdb/testsuite/lib/pdtrace.in) is not very reliable so I cannot
    say whether this commit fixes the PR mentioned above.  Nonetheless,
    it's an obvious fix and should go in.
    
    gdb/ChangeLog:
    2017-12-08  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
    	"expression_up" inside the TRY block.

commit f17d9474776e50ae47aa71c52211ea6e21adf5d5
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 8 17:27:03 2017 +0000

    Clear non-significant bits of address in watchpoint
    
    Nowadays, GDB can't set watchpoint on tagged address on AArch64,
    
    (gdb) p p2
    $1 = (int *) 0xf000fffffffff474
    (gdb) watch *((int *) 0xf000fffffffff474)
    Hardware watchpoint 2: *((int *) 0xf000fffffffff474)
    (gdb) c
    Continuing.
    main () at
    binutils-gdb/gdb/testsuite/gdb.arch/aarch64-tagged-pointer.c:45
    45	  void (*func_ptr) (void) = foo;
    Unexpected error setting hardware debug registers
    
    This patch is about setting watchpoint on a tagged address.  Unlike
    breakpoint, watchpoint record the expression rather than the address, and
    when a watchpoint is fired, GDB checks the expression value changed
    instead of matching address, so we can mask the watchpoint address by
    getting rid of non-significant bits of address.
    
    gdb:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	* breakpoint.c (update_watchpoint): Call
    	address_significant.
    
    gdb/testsuite:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.arch/aarch64-tagged-pointer.c (main): Update.
    	* gdb.arch/aarch64-tagged-pointer.exp: Add tests for watchpoint.

commit a0de8c21baf46c40ed8e62faef5f750b1e5453ea
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 8 17:27:03 2017 +0000

    Adjust breakpoint address by clearing non-significant bits
    
    Tag in tagged address on AArch64 is treated as a non-significant bits of
    address, which can be got by gdbarch method significant_addr_bit, and gdb
    can clear these bits.
    
    With this patch, when user sets a breakpoint on tagged address on AArch64,
    GDB will drop the top byte of address, and put breakpoint at the new place,
    as shown below,
    
    (gdb) hbreak *func_ptr
    warning: Breakpoint address adjusted from 0xf000000000400690 to 0x00400690.
    Hardware assisted breakpoint 2 at 0x400690
    
    (gdb) break *func_ptr
    warning: Breakpoint address adjusted from 0xf000000000400690 to 0x00400690.
    Breakpoint 3 at 0x400690
    
    When program hits a breakpoint, the stopped pc reported by Linux kernel is
    the address *without* tag, so it is better the address recorded in
    breakpoint location is the one without tag too, so we can still match
    breakpoint location address and stopped pc reported by Linux kernel, by
    simple compare.
    
    gdb:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	* breakpoint.c (adjust_breakpoint_address): Call
    	address_significant.
    
    gdb/testsuite:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.arch/aarch64-tagged-pointer.c (main): Update.
    	* gdb.arch/aarch64-tagged-pointer.exp: Add test for breakpoint.

commit a738ea1d41daeec0cccb4ab6671f4f6d53bd9e18
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 8 17:27:03 2017 +0000

    Clear non-significant bits of address on memory access
    
    ARMv8 supports tagged address, that is, the top one byte in address
    is ignored.  It is always enabled on aarch64-linux.  See
    https://www.kernel.org/doc/Documentation/arm64/tagged-pointers.txt
    
    The tag in the tagged address is modeled as non-significant bits in
    address, so this patch adds a new gdbarch method significant_addr_bit and
    clear the non-significant bits (the top byte in ARMv8) of the virtual
    address at the point before passing address to target cache layer.  IOW,
    the address used in the target cache layer is already cleared.
    
    Before this patch,
    (gdb) x/x 0x0000000000411030
    0x411030 <global>:	0x00000000
    (gdb) x/x 0xf000000000411030
    0xf000000000411030:	Cannot access memory at address 0xf000000000411030
    
    After this patch,
    
    (gdb) x/x 0x0000000000411030
    0x411030 <global>:	0x00000000
    (gdb) x/x 0xf000000000411030
    0xf000000000411030:	0x00000000
    
    Note that I used address_significant in paddress, but it causes a
    regression gdb.base/long_long.exp, because gdb clears the non-significant
    bits in address, but test still expects them.
    
    p/a val.oct^M
    $24 = 0x2ee53977053977^M
    (gdb) FAIL: gdb.base/long_long.exp: p/a val.oct
    
    so I defer the change there.
    
    gdb:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	* aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
    	significant_addr_bit.
    	* gdbarch.sh (significant_addr_bit): New.
    	* gdbarch.c, gdbarch.h: Re-generated.
    	* target.c (memory_xfer_partial): Call address_significant.
    	* utils.c (address_significant): New function.
    	* utils.h (address_significant): Declare.
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    gdb/testsuite:
    
    	* gdb.arch/aarch64-tagged-pointer.c: New file.
    	* gdb.arch/aarch64-tagged-pointer.exp: New file.

commit 8e481c3ba86e512b39b16b41de24e87a17f7d968
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 22 20:17:28 2017 -0700

    C++-ify parse_format_string
    
    This replaces parse_format_string with a class, removing some
    constructors along the way.  While doing this, I found that one
    argument to gen_printf is unused, so I removed it.
    
    Also, I am not completely sure, but the use of `release' in
    maint_agent_printf_command and parse_cmd_to_aexpr seems like it may
    leak expressions.
    
    Regression tested by the buildbot.
    
    ChangeLog
    2017-12-08  Tom Tromey  <tom@tromey.com>
    
    	* printcmd.c (ui_printf): Update.  Use std::vector.
    	* common/format.h (struct format_piece): Add constructor.
    	<string>: Now const.
    	(class format_pieces): New class.
    	(parse_format_string, free_format_pieces)
    	(free_format_pieces_cleanup): Remove.
    	* common/format.c (format_pieces::format_pieces): Rename from
    	parse_format_string.  Update.
    	(free_format_pieces, free_format_pieces_cleanup): Remove.
    	* breakpoint.c (parse_cmd_to_aexpr): Update.  Use std::vector.
    	* ax-gdb.h (gen_printf): Remove argument.
    	* ax-gdb.c (gen_printf): Remove "frags" argument.
    	(maint_agent_printf_command): Update.  Use std::vector.
    
    gdbserver/ChangeLog
    2017-12-08  Tom Tromey  <tom@tromey.com>
    
    	* ax.c (ax_printf): Update.

commit 10af2a65c8891435d0d63411a3e694cc74c9447c
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Wed Dec 6 22:52:16 2017 -0800

    gas: xtensa: fix comparison of trampoline chain symbols
    
    Don't use address where symbol gets resolved, as during section
    relaxation symbols will slide, instead canonicalize symbols and check
    that they are are the same.
    This fixes a bug when a relaxed jump goes into the wrong trampoline.
    
    gas/
    2017-12-07  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (xg_order_trampoline_chain): Replace
    	xg_order_trampoline_chain_entry call with check for
    	canonicalized symbol equality and offset equality.

commit 1cd9a73b4280cb133b305ee31a0e87f114bd1be8
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Thu Dec 7 18:27:22 2017 -0500

    Adjust gdb.arch/i386-sse-stack-align.exp print statement
    
    Since:
    
    commit 7022349d5c86bae74b49225515f42d2e221bd368
    Author: Pedro Alves <palves@redhat.com>
    Date:   Mon Sep 4 20:21:13 2017 +0100
    
        Stop assuming no-debug-info functions return int
    
    We now have to explicitly tell GDB the type of the non-debug-info
    function we want to print (by casting).  This commit adjusts the
    "print" statement on gdb.arch/i386-sse-stack-align.exp to do the
    proper cast, fixing a failure that started to happen after the
    mentioned commit.
    
    gdb/testsuite/ChangeLog:
    2017-12-08  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.arch/i386-sse-stack-align.exp: Cast "print" function call
    	"int".

commit 6b05c8bd437152d7a3ecfc19074ab243ee6c92f2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 8 15:43:49 2017 +0000

    Fix PR 22567: set SAL .section in minsym_found
    
    PR 22567 is that breakpoint location can't correct gdbarch from SAL,
    because its fields .section and .symtab is NULL.  We use to have code
    setting .section, but was removed by 4024cf2
    
    -  if (msymbol_is_text (msymbol))
    +  CORE_ADDR func_addr;
    +  if (msymbol_is_function (objfile, msymbol, &func_addr))
         {
    -      sal = find_pc_sect_line (MSYMBOL_VALUE_ADDRESS (objfile, msymbol),
    -                              (struct obj_section *) 0, 0);
    -      sal.section = MSYMBOL_OBJ_SECTION (objfile, msymbol);
    
    this patch adds this back by moving it to the common place at the bottom
    of the function.
    
    gdb:
    
    2017-12-08  Yao Qi  <yao.qi@linaro.org>
    
    	PR breakpionts/22567
    	* linespec.c (minsym_found): Set sal.section.

commit 336ef6d22a5dba921eed85eb4fa75ed22a02a633
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Fri Dec 8 14:19:23 2017 +0100

    S390: Add symfile-mem
    
    For some reason symfile-mem.o is not included in the configuration for
    "s390*-*-linux*".  It was added to the configuration of most GNU/Linux
    targets with a patch from Andrew Cagney:
    
      "Add symfile-mem to all linux targets" --
      https://sourceware.org/ml/gdb-patches/2005-02/msg00053.html
    
    But the s390 target was overlooked at that time.  Thus the command
    "add-symbol-file-from-memory" is missing and VDSO symbols are not loaded.
    
    This is fixed.
    
    gdb/ChangeLog:
    
    	* configure.tgt (s390*-*-linux*): Add symfile-mem.o.

commit 2d054e6bfdfb0f58fb9cc501c29327df34fec697
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Dec 8 10:07:14 2017 +0000

    Fix stripping relocs in a file with mergeable notes.
    
      A recent Fedora bug (1520805) exposed a problem with objcopy's reloc
      copying code, when a binary also contains mergeable notes.  The note
      merging code would delete some relocs, but then the reloc copying code
      would try to put them back again, which did not work.
    
      So I am checking in the patch below to fix the problem.  The patch
      also tweaks one of the binutils note merging tests so that it is
      skipped for the Sparc64 target, since this has funky relocs.
    
    binutils	* objcopy.c (copy_relocations_in_section): Use the orelocations
    	field of the input section, if it has been initialised.
    	* testsuite/binutils-all/note-2-64.d: Skip test on Sparc64.
    
    bfd	* elfcode.h (elf_write_relocs): Check for an empty howto field.

commit c8bed57010e8789212a6841db4b397b175a00f9e
Author: Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
Date:   Fri Dec 8 13:47:17 2017 +1030

    Add aix 64-bit check to bfd_get_sign_extend_vma
    
    	* bfd.c (bfd_get_sign_extend_vma): Handle aix5coff64-rs6000.

commit 63a22aee30c7109adec9e9f503a086210683109e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Dec 8 00:00:21 2017 +0000

    Automatic date update in version.in

commit fa6eb693cf43b427474b1d96ce093f6ea9e5da6a
Author: Keith Seitz <keiths@redhat.com>
Date:   Thu Dec 7 12:59:07 2017 -0800

    Validate explicit locations with early termination
    
    breakpoints/22569 involves an internal error generated by the rather
    innocent looking command:
    
    (gdb) break -source test.cpp main
    .../linespec.c:3302: internal-error: void decode_line_full(...):
    Assertion `result.size () == 1 || canonical->pre_expanded' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n)
    
    The input string is tokenized into "-source", "test.cpp", and "main"
    (input parsing breaks on whitespace). create_breakpoint is then called with
    the explicit location (containing only the source file name) and "main" as
    the extra_string argument.
    
    No SaLs are created for this underspecified explicit location, and the
    "result.size () == 1" evaluates false (as does the pre_expanded condition).
    This triggers the assertion.
    
    Normally string_to_explicit_location validates the input string.  However,
    the presence of the string "main" causes the parser to exit early:
    
       802        else
       803          {
       804            /* End of the explicit location specification.
       805               Stop parsing and return whatever explicit location was
       806               parsed.  */
       807            *argp = start;
       808            return location;
       809          }
    
    This bypasses the validation that is done a few lines down in this function
    which would have emitted the expected error.  This patch fixes that.
    
    Additionally, this patch also fixes an inconsistency with error reporting
    in this use case:
    
    (gdb) b -source foo
    Source filename requires function, label, or line offset.
    (gdb) b -source foo main
    No source file named foo.
    
    These two commands should have elicited the same error message.
    
    gdb/ChangeLog:
    
    	PR breakpoints/22569
    	* location.c (string_to_explicit_location): When terminating
    	parsing early, break out of enclosing loop instead of returning.
    
    gdb/testsuite/ChangeLog:
    
    	PR breakpoints/22569
    	* gdb.linespec/ls-errs.exp: Change expected result of "break
    	-source this file has spaces.c -line 3".
    	Check that an explicit source file followed by whitespace is
    	identified as an invalid explicit location.

commit 883fd55ab1049333364479a7f5b0c7e61a310bac
Author: Keith Seitz <keiths@redhat.com>
Date:   Thu Dec 7 15:01:30 2017 -0800

    Record nested types
    
    GDB currently does not track types defined in classes.  Consider:
    
    class A
    {
      public:
    
      class B
      {
        public:
          class C { };
      };
    };
    
    (gdb) ptype A
    type = class A {
       <no data fields>
    }
    
    This patch changes this behavior so that GDB records these nested types
    and displays them to the user when he has set the (new) "print type"
    option "nested-type-limit."
    
    Example:
    
    (gdb) set print type nested-type-limit 1
    (gdb) ptype A
    type = class A {
        <no data fields>
        class A::B {
            <no data fields>
        };
    }
    (gdb) set print type nested-type-limit 2
    type = class A {
        <no data fields>
        class A::B {
            <no data fields>
            class A::B::C {
                <no data fields>
            };
        };
    }
    
    By default, the code maintains the status quo, that is, it will not print
    any nested type definitions at all.
    
    Testing is carried out via cp_ptype_class which required quite a bit of
    modification to permit recursive calling (for the nested types).  This
    was most easily facilitated by turning the ptype command output into a
    queue.  Upshot: the test suite now has stack and queue data structures that
    may be used by test writers.
    
    gdb/ChangeLog
    
    	* NEWS (New commands): Mention set/show print type nested-type-limit.
    	* c-typeprint.c (c_type_print_base): Print out nested types.
    	* dwarf2read.c (struct typedef_field_list): Rename to ...
    	(struct decl_field_list): ... this.  Change all uses.
    	(struct field_info) <nested_types_list, nested_types_list_count>:
    	New fields.
    	(add_partial_symbol): Look for nested type definitions in C++, too.
    	(dwarf2_add_typedef): Rename to ...
    	(dwarf2_add_type_defn): ... this.
    	(type_can_define_types): New function.
    	Update assertion to use type_can_define_types.
    	Permit NULL for a field's name.
    	(process_structure_scope): Handle child DIEs of types that can
    	define types.
    	Copy the list of nested types into the type struct.
    	* gdbtypes.h (struct typedef_field): Rename to ...
    	(struct decl_field): ... this.  Change all uses.
    	[is_protected, is_private]: New fields.
    	(struct cplus_struct_type) <nested_types, nested_types_count>: New
    	fields.
    	(TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
    	(TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
    	(TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
    	(TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
    	* typeprint.c (type_print_raw_options, default_ptype_flags): Add
    	default value for print_nested_type_limit.
    	(print_nested_type_limit): New static variable.
    	(set_print_type_nested_types, show_print_type_nested_types): New
    	functions.
    	(_initialize_typeprint): Register new commands for set/show
    	`print-nested-type-limit'.
    	* typeprint.h (struct type_print_options) [print_nested_type_limit]:
    	New field.
    
    gdb/testsuite/ChangeLog
    
    	* gdb.cp/nested-types.cc: New file.
    	* gdb.cp/nested-types.exp: New file.
    	* lib/cp-support.exp: Load data-structures.exp library.
    	(debug_cp_test_ptype_class): New global.
    	(cp_ptype_class_verbose, next_line): New procedures.
    	(cp_test_ptype_class): Add and document new parameter `recursive_qid'.
    	Add and document new return value.
    	Switch the list of lines to a queue.
    	Add support for new `type' key for nested type definitions.
    	Add debugging/troubleshooting messages.
    	* lib/data-structures.exp: New file.
    
    gdb/doc/ChangeLog
    
    	* gdb.texinfo (Symbols): Document "set print type nested-type-limit"
    	and "show print type nested-type-limit".

commit ec72db3ef415ebdcedaf36a1d83bd6624ec063e0
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Dec 7 17:37:02 2017 -0500

    Fix wrong prefix in py-breakpoint.exp
    
    The prefix in test_bkpt_explicit_loc is wrong.  Instead of using
    with_test_prefix directly, define test_bkpt_explicit_loc with
    proc_with_prefix.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-breakpoint.exp (test_bkpt_explicit_loc): Define
    	with proc_with_prefix, don't use with_test_prefix.

commit 99598d713f45d1b26015ec3562d160dc2b3792e4
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Nov 3 10:26:11 2017 -0600

    Fix regression in "commands"
    
    Pedro pointed out a regression in "commands", where trying to clear a
    breakpoint's command list would fail:
    
        (top-gdb) commands
        Type commands for breakpoint(s) 3, one per line.
        End with a line saying just "end".
        >end
        No breakpoints specified.
        (top-gdb)
    
    I believe the bug was introduced by my patch that changes
    counted_command_line to be a shared_ptr.  This causes the problem
    because now the counted_command_line in commands_command_1 can be NULL,
    whereas previously it never could be.
    
    After some discussion, we agreed to simply remove the error case from
    commands_command_1.
    
    2017-12-07  Tom Tromey  <tom@tromey.com>
    
    	PR breakpoints/22511:
    	* breakpoint.c (commands_command_1): Don't throw an exception when
    	no commands have been read.
    
    2017-12-07  Tom Tromey  <tom@tromey.com>
    
    	* gdb.base/break.exp: Add test for empty "commands".

commit 23a8d1862b7e5b95f0fe9d724c6be326e545e6d1
Author: Adam Stylinski <adam.stylinski@etegent.com>
Date:   Thu Dec 7 12:51:03 2017 -0500

    Fix build with g++ 6.3.1
    
    With g++ 6.3.1:
    
     target-descriptions.c: In member function â??virtual void
     print_c_tdesc::visit_pre(const target_desc*)â??:
     target-descriptions.c:1836:16: error: types may not be defined in a
     for-range-declaration [-Werror]
          for (const struct bfd_arch_info *compatible : e->compatible)
    		 ^~~~~~
    
    I think at some point the forward declaration of this struct had been
    removed and declared as a typedef.  This fixes that.
    
    gdb/ChangeLog:
    2017-12-07  Adam Stylinski  <adam.stylinski@etegent.com>
    
    	PR c++/21222
    	* target-descriptions.c (print_c_tdesc::visit_pre): Change type of
    	range-for variable.

commit a8806230241d201f808d856eaae4d44088117b0c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Dec 7 17:07:01 2017 +0000

    Initialize target description early in IPA
    
    Target descriptions are allocated lazily, that is fine in GDBserver,
    but it is not safe to call malloc in gdb_collect in IPA, because we
    can set a fast tracepoint in malloc, and when the tracepoint is hit,
    gdb_collect/malloc is called, deadlock or memory corruption may be
    triggered.
    
     #0  0xf7cfc200 in malloc ()
     #1  0xf7efdc07 in operator new(unsigned int) ()
     #2  0xf7ef7636 in allocate_target_description() ()
     #3  0xf7efcbe1 in i386_create_target_description(unsigned long long, bool) ()
     #4  0xf7efb474 in i386_linux_read_description(unsigned long long) ()
     #5  0xf7efb190 in get_ipa_tdesc(int) ()
     #6  0xf7ef9baa in gdb_collect ()
    
    The fix is to initialize all target descriptions earlier, when the
    IPA is loaded.  In order to guarantee malloc is not called in IPA
    in gdb_collect, I change the test to set a breakpoint on malloc, if
    IPA gdb_collect calls malloc, program will hit the breakpoint, and
    test fail.
    
    continue
    Continuing.
    
    Thread 1 "" hit Breakpoint 5, 0xf7cfc200 in malloc ()
    (gdb) FAIL: gdb.trace/ftrace.exp: advance through tracing
    
    gdb/gdbserver:
    
    2017-12-07  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-aarch64-ipa.c (initialize_low_tracepoint): Call
    	aarch64_linux_read_description.
    	* linux-amd64-ipa.c (idx2mask): New array.
    	(get_ipa_tdesc): Move idx2mask out.
    	(initialize_low_tracepoint): Initialize target descriptions.
    	* linux-i386-ipa.c (idx2mask): New array.
    	(get_ipa_tdesc): Move idx2mask out.
    	(initialize_low_tracepoint): Initialize target descriptions.
    
    gdb/testsuite:
    
    2017-12-07  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.trace/ftrace.exp (run_trace_experiment): Set breakpoint on
    	malloc and catch syscall.

commit 30970df7d56bd65657c97296f31fe9862bf27e1d
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Dec 7 11:48:21 2017 -0500

    Add virtual destructor to selftest
    
    Clang 6 shows this warning
    
      In file included from /home/emaisin/src/binutils-gdb/gdb/common/selftest.c:19:
      In file included from /home/emaisin/src/binutils-gdb/gdb/common/common-defs.h:92:
      In file included from /home/emaisin/src/binutils-gdb/gdb/common/gdb_unique_ptr.h:23:
      In file included from /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/memory:81:
      /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/bits/unique_ptr.h:76:2: error: delete called on 'selftests::selftest' that is abstract but has non-virtual destructor [-Werror,-Wdelete-non-virtual-dtor]
              delete __ptr;
              ^
      /usr/bin/../lib/gcc/x86_64-linux-gnu/5.4.0/../../../../include/c++/5.4.0/bits/unique_ptr.h:236:4: note: in instantiation of member function 'std::default_delete<selftests::selftest>::operator()' requested here
                get_deleter()(__ptr);
                ^
      /home/emaisin/src/binutils-gdb/gdb/common/selftest.c:57:17: note: in instantiation of member function 'std::unique_ptr<selftests::selftest, std::default_delete<selftests::selftest> >::~unique_ptr' requested here
        tests[name] = std::unique_ptr<selftest> (test);
                      ^
    
    The error is legitimate, we (the unique_ptr) are deleting selftest
    objects through the base pointer, so technically the destructor should
    be virtual, so that the destructor of the subclass is invoked.
    
    gdb/ChangeLog:
    
    	* common/selftest.h (struct selftest): Add virtual destructor.

commit 824cc835aa9a4d585d955db4ab2a5dd4c17cc22c
Author: Phil Muldoon <pmuldoon@redhat.com>
Date:   Thu Dec 7 16:47:33 2017 +0000

    Implement explicit locations for Python breakpoints.
    
    This introduces several new keywords to the bppy_init constructor.
    The spec parameter is now optional but mutually exclusive to the
    explicit keywords source, label, function and line.
    
    gdb/ChangeLog
    
    2017-12-07  Phil Muldoon  <pmuldoon@redhat.com>
    
           * python/py-breakpoint.c (bppy_init): Use string_to_event_location
           over basic location code. Implement explicit location keywords.
           (bppy_init_validate_args): New function.
           * NEWS: Document Python explicit breakpoint locations.
    
    doc/ChangeLog
    
    2017-12-07  Phil Muldoon  <pmuldoon@redhat.com>
    
           * python.texi (Breakpoints In Python): Add text relating
           to allowed explicit locations and keywords in gdb.Breakpoints.
    
    testsuite/ChangeLog
    
    2017-12-07  Phil Muldoon  <pmuldoon@redhat.com>
    
           * gdb.python/py-breakpoint.exp (test_bkpt_explicit_loc): Add new
           tests for explicit locations.

commit 9c226a8689db8bced43b94f551e118551219ce54
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Dec 7 14:10:33 2017 +0100

    gdb/MAINTAINERS: restore m68hc11, score and xstormy16 entries
    
    This patch restores some entries removed by a recent patch whose purpose
    was to update the list of active maintainers. I thought that, the target
    information was purely to document the scope of the given target, and
    thus could be removed is maintainerless. But, in fact, those entries
    are still useful, as a number of scripts (eg: gdb_buildall.sh) use
    that information to build GDB with all targets enabled.
    
    gdb/ChangeLog:
    
    	* MAINTAINERS: Restore target entries for m68hc11-elf,
    	score-elf and xstormy16-elf, incorrectly removed in a previous
    	patch meant to only update the list of active maintainers.

commit 7d6de425dad59050131ac4ffef84068e57bba7c4
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Dec 7 21:46:34 2017 +1030

    Objcopy interleave test
    
    	PR 22465
    	* testsuite/ld-elf/interleave.s: Use .data sections and provide
    	section attrs.
    	* testsuite/ld-elf/interleave.ld: Discard other sections.  Adjust
    	for changed section names.

commit 931c97c81a55dffed31e20e0cd109aced62221e0
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Dec 7 20:37:33 2017 +1030

    mcore-elf lacks shared lib support
    
    elf32-mcore.c has no backend create_dynamic_sections function so can't
    support shared libs.
    
    	* emulparams/elf32mcore.sh (GENERATE_SHLIB_SCRIPT): Don't define.

commit 05a5feafdd3869b81533993a23c344d60baa56de
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Dec 7 17:50:57 2017 +1030

    Rewrite check_shared_lib_support
    
    	* testsuite/lib/ld-lib.exp (check_shared_lib_support): Ask ld
    	under test whether -shared is supported.

commit 34ac47f671d870c62635cac209d8df4250f20192
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Dec 7 00:00:30 2017 +0000

    Automatic date update in version.in

commit 649a140ccf129ff79ea55ac0cc23ebddec0f02ef
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Dec 6 17:45:09 2017 -0500

    target_set_syscall_catchpoint, use gdb::array_view and bool
    
    I noticed that we're passing down a data/size pair to
    target_ops::to_set_syscall_catchpoint.  This commit makes use of
    gdb::array_view instead.  While at it, use bool where appropriate as
    well.
    
    gdb/ChangeLog:
    
    	* break-catch-syscall.c (insert_catch_syscall)
    	(remove_catch_syscall): Adjust to pass reference to
    	inf_data->syscalls_counts directly via gdb::array_view.
    	* fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
    	and gdb::array_view.
    	* linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
    	* remote.c (remote_set_syscall_catchpoint): Likewise.
    	* target-debug.h (target_debug_print_bool): New.
    	(define target_debug_print_gdb_array_view_const_int): New.
    	* target-delegates.c: Regenerate.
    	* target.h (target_ops) <to_set_syscall_catchpoint>: Use
    	gdb::array_view and bool.
    	(target_set_syscall_catchpoint): Likewise.

commit 9a93831ccc0ba3ba447552069f230e6d93dcbf3f
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Dec 6 16:27:33 2017 -0500

    Fix syscall group completion
    
    The test gdb.base/catch-syscall.exp has been failing since commit
    
      3d415c26bad3a15eed00d2ddf85c4268df77a4cc
      Remove cleanups from break-catch-syscall.c
    
    The reason is that we are putting into the group_ptr array a pointer to
    the buffer of the local string object.  If the string is small enough to
    fit in the internal string buffer (used for small string optimizations),
    the pointer will point to the local object directly.  So even if we
    std::move the string to the vector, the pointer in group_ptr will still
    point to the local object.  When we reuse that object (technically a new
    instance, but most likely the same memory) for the next syscall, we'll
    overwrite the previous string.  The result is that we'll get less
    results than expected, since there will be duplicates.
    
    We'll also run into problems if we push the string to the vector, and
    then record the c_str () pointer using the string object in the vector.
    The vector might get reallocated, the string may move in memory, and our
    pointer in group_ptr will point to stale memory.
    
    Instead, we have to push all the strings first, then, when we know the
    vector won't change anymore, build the group_ptr array.  This is what
    this patch does.
    
    gdb/ChangeLog:
    
    	* break-catch-syscall.c (catch_syscall_completer): Get pointers
    	to syscall group strings after building the string vector.

commit 1c9c7ce078427891a94dc7604ce9e62175ebfda5
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Dec 6 10:34:36 2017 -0800

    Objcopy interleave fails if section address not multiple of interleave.
    
    	PR 22465
    	binutils/
    	* objcopy.c (copy_section): New local extra.  If isection->lma not
    	exactly divisible by interleave, then bias from.  Also adjust
    	osection->lma if necessary.
    
    	ld/
    	* testsuite/ld-elf/interleave-0.d, testsuite/ld-elf/interleave-4.d,
    	* testsuite/ld-elf/interleave.ld, testsuite/ld-elf/interleave.s: New.

commit 7cc244debb587d0f6179d80b5ca9b0ee86e9ab72
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Dec 6 11:28:47 2017 +0000

    remote: Make qXfer packets respect corresponding "set remote foo-packet"
    
    I've noticed that "set remote target-features-packet off" before
    connecting has no effect -- GDB still fetches a target description
    anyway.
    
    The problem is that while most "set remote foo-packet" commands were
    fixed by:
    
      From 4082afcc3d1af9d8063d1c8e02deb34a8b97a489 Mon Sep 17 00:00:00 2001
      From: Pedro Alves <palves@redhat.com>
      Date: Fri, 25 Apr 2014 18:07:02 +0100
      Subject: [PATCH] Fix several "set remote foo-packet on/off" commands.
      <https://sourceware.org/ml/gdb-patches/2014-04/msg00006.html>
    
    the "qXfer" packets where missed.  This commit fixes that.
    
    I've changed remote_search_memory too for consistency (seems like
    those are the last direct references to packet->support), though the
    difference is not observable because the qSearch:memory packet is auto
    probed.  Note gdb.base/find-unmapped.exp already exercises explicit
    "set remote search-memory-packet off".
    
    gdb/ChangeLog:
    2017-12-06  Pedro Alves  <palves@redhat.com>
    
    	* remote.c (remote_query_supported): Don't send "xmlRegisters=" if
    	"qXfer:features:read"" is disabled.
    	(remote_write_qxfer, remote_read_qxfer, remote_search_memory):
    	Check packet_config_support instead of packet->support directly.
    
    gdb/testsuite/ChangeLog:
    2017-12-06  Pedro Alves  <palves@redhat.com>
    
    	* gdb.arch/i386-avx.exp: If testing with a RSP target, check
    	force-disabling XML descriptions.
    --
    
     gdb/remote.c                        |   16 +++++++++-------
     gdb/testsuite/gdb.arch/i386-avx.exp |   25 +++++++++++++++++++++++++
     2 files changed, 34 insertions(+), 7 deletions(-)

commit 846fefbdb2280374ad91afca3d24fa0c3fa26f96
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Dec 6 10:04:51 2017 +0000

    Tell the linker testsuite that lm32-rtems toolchains do not support the generation of shared libraries.
    
    	* testsuite/lib/ld-lib.exp (check_shared_lib_support): Return
    	false for lm32-rtems targets.

commit 9c1ce1085070f42718e341d89a28881edd96161f
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Dec 6 17:32:48 2017 +1030

    PR22552, readelf heap buffer overflow in load_debug_section
    
    	PR 22552
    	* readelf.c (process_file_header): Don't assume XINDEX case
    	value for e_shstrndx is within bounds.
    	(load_debug_section): Sanity test e_shstrndx before attempting
    	to read .shstrtab.  Wrap long lines.

commit 07d6d2b8345ef3dc82eab49635acac9ee67dbb18
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Dec 6 09:26:00 2017 +1030

    BFD whitespace fixes
    
    Binutils is supposed to use tabs.  In my git config I have
    whitespace = indent-with-non-tab,space-before-tab,trailing-space
    and I got annoyed enough seeing red in "git diff" output to fix
    the problems.
    
    	* doc/header.sed: Trim trailing space when splitting lines.
    	* aix386-core.c, * aout-adobe.c, * aout-arm.c, * aout-cris.c,
    	* aout-ns32k.c, * aout-target.h, * aout-tic30.c, * aoutf1.h, * aoutx.h,
    	* arc-got.h, * arc-plt.def, * arc-plt.h, * archive.c, * archive64.c,
    	* archures.c, * armnetbsd.c, * bfd-in.h, * bfd.c, * bfdio.c, * binary.c,
    	* bout.c, * cache.c, * cisco-core.c, * coff-alpha.c, * coff-apollo.c,
    	* coff-arm.c, * coff-h8300.c, * coff-i386.c, * coff-i860.c,
    	* coff-i960.c, * coff-m68k.c, * coff-m88k.c, * coff-mcore.c,
    	* coff-mips.c, * coff-ppc.c, * coff-rs6000.c, * coff-sh.c,
    	* coff-stgo32.c, * coff-tic4x.c, * coff-tic54x.c, * coff-tic80.c,
    	* coff-we32k.c, * coff-x86_64.c, * coff-z80.c, * coff-z8k.c,
    	* coff64-rs6000.c, * coffcode.h, * coffgen.c, * cofflink.c,
    	* coffswap.h, * compress.c, * corefile.c, * cpu-alpha.c, * cpu-arm.c,
    	* cpu-avr.c, * cpu-bfin.c, * cpu-cr16.c, * cpu-cr16c.c, * cpu-crx.c,
    	* cpu-d10v.c, * cpu-frv.c, * cpu-ft32.c, * cpu-i370.c, * cpu-i960.c,
    	* cpu-ia64-opc.c, * cpu-ip2k.c, * cpu-lm32.c, * cpu-m32r.c,
    	* cpu-mcore.c, * cpu-microblaze.c, * cpu-mips.c, * cpu-moxie.c,
    	* cpu-mt.c, * cpu-nios2.c, * cpu-ns32k.c, * cpu-or1k.c, * cpu-powerpc.c,
    	* cpu-pru.c, * cpu-sh.c, * cpu-spu.c, * cpu-v850.c, * cpu-v850_rh850.c,
    	* cpu-xgate.c, * cpu-z80.c, * dwarf1.c, * dwarf2.c, * ecoff.c,
    	* ecofflink.c, * ecoffswap.h, * elf-bfd.h, * elf-eh-frame.c,
    	* elf-hppa.h, * elf-m10200.c, * elf-m10300.c, * elf-s390-common.c,
    	* elf-strtab.c, * elf-vxworks.c, * elf.c, * elf32-am33lin.c,
    	* elf32-arc.c, * elf32-arm.c, * elf32-avr.c, * elf32-avr.h,
    	* elf32-bfin.c, * elf32-cr16.c, * elf32-cr16c.c, * elf32-cris.c,
    	* elf32-crx.c, * elf32-d10v.c, * elf32-d30v.c, * elf32-dlx.c,
    	* elf32-epiphany.c, * elf32-fr30.c, * elf32-frv.c, * elf32-ft32.c,
    	* elf32-h8300.c, * elf32-hppa.c, * elf32-i386.c, * elf32-i860.c,
    	* elf32-i960.c, * elf32-ip2k.c, * elf32-lm32.c, * elf32-m32c.c,
    	* elf32-m32r.c, * elf32-m68hc11.c, * elf32-m68hc12.c, * elf32-m68hc1x.c,
    	* elf32-m68hc1x.h, * elf32-m68k.c, * elf32-m88k.c, * elf32-mcore.c,
    	* elf32-mep.c, * elf32-metag.c, * elf32-microblaze.c, * elf32-mips.c,
    	* elf32-moxie.c, * elf32-msp430.c, * elf32-mt.c, * elf32-nds32.c,
    	* elf32-nds32.h, * elf32-nios2.c, * elf32-or1k.c, * elf32-pj.c,
    	* elf32-ppc.c, * elf32-ppc.h, * elf32-pru.c, * elf32-rl78.c,
    	* elf32-rx.c, * elf32-s390.c, * elf32-score.c, * elf32-score.h,
    	* elf32-score7.c, * elf32-sh-symbian.c, * elf32-sh.c, * elf32-sh64.c,
    	* elf32-sparc.c, * elf32-spu.c, * elf32-tic6x.c, * elf32-tilegx.c,
    	* elf32-tilegx.h, * elf32-tilepro.c, * elf32-tilepro.h, * elf32-v850.c,
    	* elf32-vax.c, * elf32-wasm32.c, * elf32-xc16x.c, * elf32-xgate.c,
    	* elf32-xgate.h, * elf32-xstormy16.c, * elf32-xtensa.c, * elf64-alpha.c,
    	* elf64-hppa.c, * elf64-ia64-vms.c, * elf64-mips.c, * elf64-mmix.c,
    	* elf64-ppc.c, * elf64-s390.c, * elf64-sh64.c, * elf64-sparc.c,
    	* elf64-tilegx.c, * elf64-tilegx.h, * elf64-x86-64.c, * elfcore.h,
    	* elflink.c, * elfn32-mips.c, * elfnn-aarch64.c, * elfnn-ia64.c,
    	* elfnn-riscv.c, * elfxx-aarch64.c, * elfxx-aarch64.h, * elfxx-ia64.c,
    	* elfxx-ia64.h, * elfxx-mips.c, * elfxx-riscv.c, * elfxx-sparc.c,
    	* elfxx-tilegx.c, * elfxx-x86.c, * elfxx-x86.h, * freebsd.h, * hash.c,
    	* host-aout.c, * hp300hpux.c, * hppabsd-core.c, * hpux-core.c,
    	* i386aout.c, * i386linux.c, * i386lynx.c, * i386mach3.c, * i386msdos.c,
    	* i386netbsd.c, * ieee.c, * ihex.c, * irix-core.c, * libaout.h,
    	* libbfd-in.h, * libbfd.c, * libcoff-in.h, * libnlm.h, * libpei.h,
    	* libxcoff.h, * linker.c, * lynx-core.c, * m68k4knetbsd.c,
    	* m68klinux.c, * m68knetbsd.c, * m88kmach3.c, * mach-o-aarch64.c,
    	* mach-o-arm.c, * mach-o-i386.c, * mach-o-target.c, * mach-o-x86-64.c,
    	* mach-o.c, * mach-o.h, * merge.c, * mipsbsd.c, * mmo.c, * netbsd.h,
    	* netbsd-core.c, * newsos3.c, * nlm-target.h, * nlm32-ppc.c,
    	* nlm32-sparc.c, * nlmcode.h, * ns32k.h, * ns32knetbsd.c, * oasys.c,
    	* opncls.c, * pc532-mach.c, * pdp11.c, * pe-arm.c, * pe-i386.c,
    	* pe-mcore.c, * pe-mips.c, * pe-x86_64.c, * peXXigen.c, * pef.c,
    	* pef.h, * pei-arm.c, * pei-i386.c, * pei-mcore.c, * pei-x86_64.c,
    	* peicode.h, * plugin.c, * ppcboot.c, * ptrace-core.c, * reloc.c,
    	* riscix.c, * rs6000-core.c, * section.c, * som.c, * som.h,
    	* sparclinux.c, * sparcnetbsd.c, * srec.c, * stabs.c, * sunos.c,
    	* syms.c, * targets.c, * tekhex.c, * trad-core.c, * vax1knetbsd.c,
    	* vaxnetbsd.c, * verilog.c, * versados.c, * vms-alpha.c, * vms-lib.c,
    	* vms-misc.c, * wasm-module.c, * wasm-module.h, * xcofflink.c,
    	* xsym.c, * xsym.h: Whitespace fixes.
    	* bfd-in2.h, * libbfd.h, * libcoff.h: Regenerate.

commit 65281396861dfcfa993eb5af4769d6837104890d
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Dec 6 17:31:15 2017 +1030

    Fix Common symbol override test fails
    
    Fixes fails on SH and NDS32 introduced by dyn_reloc tidy.
    
    	* elf32-lm32.c (lm32_elf_check_relocs): Skip non-ALLOC sections.
    	* elf32-m32r.c (m32r_elf_check_relocs): Likewise.
    	* elf32-nds32.c (nds32_elf_check_relocs): Likewise.
    	* elf32-or1k.c (or1k_elf_check_relocs): Likewise.
    	* elf32-sh.c (sh_elf_check_relocs): Likewise.

commit a3cc9aad2e3de033462d64c8e028e1a3587c63e9
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Dec 6 09:04:48 2017 +1030

    Enable shared lib tests for frv, lm32, m32r, microblaze, nds32 and or1k
    
    These claim to support shared libs when configuring for <target>-linux
    (in contrast to <target>-elf which doesn't support shared libs).
    
    	* testsuite/lib/ld-lib.exp (check_shared_lib_support): Return true
    	for frv, lm32, m32r, microblaze, nds32 and or1k linux targets.

commit 3bf083ed23b1337341129b810ed5da29ba8207f9
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Dec 5 10:03:03 2017 +1030

    dyn_relocs tidy
    
    Many targets define their own dyn_relocs struct when they could use
    struct elf_dyn_relocs.  This patch tidies that, and uses
    readonly_dynrelocs in a few more places.
    
    The SH adjust_dynamic_symbol had some really weird code dating back to
    2002 that looked over dynamic relocations for any in SEC_HAS_CONTENTS
    or SEC_READONLY sections, rather than just the usual SEC_READONLY
    sections.  So basically any dynamic relocation.  What's more, the SH
    relocate_section has no support for emitting dynamic relocations in
    non-PIC.  In other words, SH has no support for avoiding copy relocs
    in non-PIC.  I've made that more obvious by using "if (0 && ..)" in
    asjust_dynamic_symbol.
    
    Unfortunately, LM32, M32R, NDS32, and OR1K copied the bogus SH
    adjust_dynamic_symbol code.  So none of those targets would have
    avoided copy relocs.  LM32, M32R, NDS32 get the "if (0)" treatment
    too.  (LM32 is even more broken in that non_got_ref is never set.)
    
    OR1K relocate_section looks like it might support dynamic relocs in
    non-PIC, so I've enabled the copy reloc avoidance code for that
    target.
    
    	* elf32-hppa.c (struct elf32_hppa_dyn_reloc_entry): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(elf32_hppa_adjust_dynamic_symbol): Comment tidy.
    	* elf32-lm32.c (struct elf_lm32_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(lm32_elf_adjust_dynamic_symbol): Use readonly_dynrelocs, but disable.
    	Disable -z no-copyreloc too.
    	* elf32-m32r.c (struct elf_m32r_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(m32r_elf_adjust_dynamic_symbol): Use readonly_dynrelocs, but disable.
    	Disable -z no-copyreloc too.
    	* elf32-metag.c (struct elf_metag_dyn_reloc_entry): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(elf_metag_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elf32-microblaze.c (struct elf32_mb_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(readonly_dynrelocs): New function.
    	(microblaze_elf_adjust_dynamic_symbol): Use it.
    	* elf32-nds32.c (struct elf_nds32_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(nds32_elf_adjust_dynamic_symbol): Use readonly_dynrelocs, but disable.
    	Disable -z no-copyreloc too.
    	* elf32-nios2.c (struct elf32_nios2_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	* elf32-or1k.c (struct elf_or1k_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(or1k_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elf32-sh.c (struct elf_sh_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(sh_elf_adjust_dynamic_symbol): Use readonly_dynrelocs, but disable.
    	Disable -z no-copyreloc too.
    	* elf32-tilepro.c (struct tilepro_elf_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(tilepro_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elfnn-riscv.c (struct riscv_elf_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(riscv_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elfxx-sparc.c (struct _bfd_sparc_elf_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(_bfd_sparc_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elfxx-tilegx.c (struct tilegx_elf_dyn_relocs): Delete.  Use
    	struct elf_dyn_relocs throughout file instead.
    	(tilegx_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elf32-s390.c (elf_s390_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* elf64-s390.c (elf_s390_adjust_dynamic_symbol): Use readonly_dynrelocs.

commit dce2246a6c934bf35157e8970d0da5a11aefb282
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Dec 5 10:05:19 2017 +1030

    Comment tidy
    
    Past tense is wrong for a comment before some action.
    
    	* elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Comment tidy.
    	* elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_adjust_dynamic_symbol): Likewise.

commit 8fbc617a46b015098876a7515c3a7ad6d1682876
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Dec 6 00:00:23 2017 +0000

    Automatic date update in version.in

commit 0527614a9b805d1f640f477f51f9780403487ef8
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Dec 5 14:42:12 2017 -0800

    Really fix riscv shared library __global_pointer$ problem.
    
    	ld/
    	* emulparams/elf32lriscv-defs.sh (SDATA_START_SYMBOLS): Remove HIDDEN.
    	Don't define __global_pointer$ when CREATE_SHLIB.
    	* testsuite/ld-riscv-elf/gp-hidden-64.rd,
    	* testsuite/ld-riscv-elf/gp-hidden-lib.rd,
    	* testsuite/ld-riscv-elf/gp-hidden-lib.s,
    	* testsuite/ld-riscv-elf/gp-hidden-ver-64.rd,
    	* testsuite/ld-riscv-elf/gp-hidden-ver.rd,
    	* testsuite/ld-riscv-elf/gp-hidden-ver.s,
    	* testsuite/ld-riscv-elf/gp-hidden-ver.ver,
    	* testsuite/ld-riscv-elf/gp-hidden.rd,
    	* testsuite/ld-riscv-elf/gp-hidden.s,
    	* testsuite/ld-riscv-elf/gp-hidden.sd: Delete.
    	* testsuite/ld-riscv-elf/gp-test-lib.sd,
    	* testsuite/ld-riscv-elf/gp-test.s,
    	* testsuite/ld-riscv-elf/gp-test.sd: New.
    	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Rewrite gp tests.

commit 858c9d13240e695bc3b750368f5d4e524b12112e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 5 16:39:35 2017 -0500

    Address review comments for the previous series
    
    I failed at git and missed adding/lost changes on the wrong branch, the
    result being that I didn't incorporate fixes resulting from Yao's review
    comments.  This patch fixes that.
    
    There are two places where we should use the unique pointer typedef, and
    ChangeLog entries missing.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (struct tdesc_feature) <registers>: Use
    	tdesc_reg_up typedef.
    	(struct target_desc) <features>: Use tdesc_feature_up typedef.

commit d4a0e8b57d6f85e4ee4a31e0e6929ff5b4fd9823
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:28 2017 -0500

    Split tdesc_type into multiple classes
    
    This patch makes tdesc_type an abstract base class and creates three
    subclasses:
    
    - tdesc_type_builtin, for builtin types
    - tdesc_type_vector, for vector types
    - tdesc_type_with_fields, for struct, union, flag and enum types
    
    This allows getting rid of the union in tdesc_type and to not allow the
    std::vector separately.  I tried to go further and create separate
    classes for struct, union, flag and enum, but it proved too difficult.
    One problem is that from the point of the of the target description
    code, the types tdesc_type_* are opaque (only forward-declared).
    Therefore, it doesn't know about inheritance relationship between those
    classes.  This makes it impossible to make functions that accept a
    pointer to a base class and pass a pointer to a derived class, for
    example.  I think this patch here is a good compromise, and if somebody
    wants to improve things further, the door is open.
    
    A make_gdb_type virtual pure method is added to tdesc_type, which
    replaces the current tdesc_gdb_type function.  Calling this method on a
    tdesc_type returns the corresponding built gdb type.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (struct tdesc_type): Use default
    	destructor.
    	<u>: Remove.
    	<accept>: Remove.
    	(struct tdesc_type_builtin): New.
    	(struct tdesc_type_vector): New.
    	(struct tdesc_type_with_fields): New.
    	(tdesc_predefined_types): Change type to tdesc_type_builtin[].
    	(tdesc_gdb_type): Remove.
    	(tdesc_register_type): Adjust.
    	(tdesc_create_vector): Create tdesc_type_vector.
    	(tdesc_create_struct): Create tdesc_type_with_fields.
    	(tdesc_set_struct_size): Change parameter type.
    	(tdesc_create_union): Create tdesc_type_with_fields.
    	(tdesc_create_flags): Likewise.
    	(tdesc_create_enum): Likewise.
    	(tdesc_add_field): Change parameter type.
    	(tdesc_add_typed_bitfield): Likewise.
    	(tdesc_add_bitfield): Likewise.
    	(tdesc_add_flag): Likewise.
    	(tdesc_add_enum_value): Likewise.
    	(print_c_tdesc) <visit>: Remove overload with tdesc_type
    	parameter, add overloads for tdesc_type_builtin,
    	tdesc_type_with_fields and tdesc_type_vector.
    	<m_printed_type>: Remove.
    	<m_printed_element_type, m_printed_type_with_fields>: Add.
    	* target-descriptions.h (tdesc_create_enum): Change return type.
    	(tdesc_add_typed_bitfield): Change parameter type.
    	(tdesc_add_enum_value): Change parameter type.
    	* xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
    	type to tdesc_type_with_fields.
    	(tdesc_start_struct): Adjust.
    	(tdesc_start_flags): Adjust.
    	(tdesc_start_enum): Adjust.
    	(tdesc_start_field): Adjust.
    	* arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
    	(struct tdesc_type_vector): Forward-declare.
    	(struct tdesc_type_with_fields): Forward-declare.
    	(tdesc_create_struct): Change return type.
    	(tdesc_create_union): Likewise.
    	(tdesc_create_flags): Likewise.
    	(tdesc_add_field): Change parameter type.
    	(tdesc_set_struct_size): Likewise.
    	(tdesc_add_bitfield): Likewise.
    	(tdesc_add_flag): Likewise.
    	* features: Re-generate C files.
    
    gdb/gdbserver/ChangeLog:
    
    	* tdesc.c (struct tdesc_type): Change return type.
    	(tdesc_add_flag): Change parameter type.
    	(tdesc_add_bitfield): Likewise.
    	(tdesc_add_field): Likewise.
    	(tdesc_set_struct_size): Likewise.

commit f0cddbef410cb626ea87b3a954bd4e3d7526115e
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:27 2017 -0500

    Make tdesc_arch_data::arch_regs an std::vector
    
    Make tdesc_arch_data::arch_regs be an std::vector of tdesc_arch_reg
    objects.
    
    On particularity is that the tdesc_arch_data linked to a gdbarch is
    allocated on the gdbarch's obstack.  To be safe, I did not change it and
    called placement-new on the area returned by OBSTACK_ZALLOC.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_arch_reg): Remove typedef.
    	(struct tdesc_arch_reg): Add constructor.
    	(DEF_VEC_O (tdesc_arch_reg)): Remove.
    	(struct tdesc_arch_data): Initialize fields.
    	<arch_regs>: Change type to std::vector.
    	(target_find_description): Adjust.
    	(tdesc_find_type): Adjust.
    	(tdesc_data_init): Call tdesc_arch_data constructor.
    	(tdesc_data_alloc): Allocate tdesc_arch_data with new.
    	(tdesc_data_cleanup): Free data with delete.
    	(tdesc_numbered_register): Adjust.
    	(tdesc_find_arch_register): Adjust.
    	(tdesc_use_registers): Adjust.

commit d05200d155f065b93e2dc353a7d33408c7574e9c
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:26 2017 -0500

    Make tdesc_type::u::u::fields an std::vector
    
    This patch makes the tdesc_type::u::u::fields an std::vector of
    tdesc_type_field.   The difficulty here is that the vector is part of a
    union.  Because of this, I made fields a pointer to a vector, and
    instantiate/destroy the vector if the type is one that uses this member
    of the union
    
    The field tdesc_type_field::name is changed to an std::string at the
    same time.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_type_field): Remove typedef.
    	(DEF_VEC_O (tdesc_type_field)): Remove.
    	(struct tdesc_type_field): Add constructor.
    	<name>: Change type to std::string.
    	(struct tdesc_type) <tdesc_type>: Instantiate vector if the type
    	kind uses it.
    	<~tdesc_type>: Destroy vector if the type kind uses it.
    	<u::u::fields>: Change type to std::vector.
    	(tdesc_gdb_type): Adjust.
    	(tdesc_add_field): Adjust.
    	(tdesc_add_typed_bitfield): Adjust.
    	(tdesc_add_field): Adjust.
    	(tdesc_add_enum_value): Adjust.
    	(class print_c_tdesc) <visit>: Adjust.

commit 082b9140d953b9e6a78271384ec48ff5d0ba8fad
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:26 2017 -0500

    Make tdesc_type::name an std::string
    
    This patch makes tdesc_type::name an std::string.  This way, we don't
    need to free it manually in ~tdesc_type.  I think the comment on top of
    name is not correct, the string is always malloc'ed.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (struct tdesc_type) <name>: Change type
    	to std::string.
    	<~tdesc_type>: Don't manually free name.
    	<operator==>: Adjust.
    	(tdesc_named_type): Adjust.
    	(tdesc_find_type): Adjust.
    	(tdesc_gdb_type): Adjust.
    	(class print_c_tdesc) <visit>: Adjust.

commit 53c934e9fed9a35542661690e4e71febcbebb539
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:25 2017 -0500

    Make tdesc_feature::types an std::vector
    
    This patch makes tdesc_feature::types an std::vector of unique_ptr of
    tdesc_type.  This way, we don't need to manually free the objects and
    the vector in ~tdesc_feature.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_type_p): Remove typedef.
    	(DEF_VEC_P (tdesc_type_p)): Remove.
    	(struct tdesc_feature) <types>: Change type to std::vector.
    	<~tdesc_feature>: Replace with default implementation.
    	<accept>: Adjust.
    	(tdesc_named_type): Adjust.
    	(tdesc_create_vector): Adjust.
    	(tdesc_create_struct): Adjust.
    	(tdesc_create_union): Adjust.
    	(tdesc_create_flags): Adjust.
    	(tdesc_create_enum): Adjust.

commit a8142ee195063e8c7202429e80ee58185c34b3fc
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 5 16:30:25 2017 -0500

    Make tdesc_reg string fields std::string
    
    Make the name, group and type fields of tdesc_reg std::strings.  This
    way, we don't have to manually free them in ~tdesc_reg.
    
    Doing so results in a small change in the generated tdesc.  Instead of
    passing an empty string for the group parameter of tdesc_create_reg, the
    two modified tdesc now pass NULL.  The end result should be the same.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
    	type of name_ parameter, adjust to std::string change.
    	<name, group, type>: Change type to std::string.
    	<~tdesc_reg>: Replace with default implementation.
    	<operator==>: Adjust.
    	(tdesc_find_register_early): Adjust.
    	(tdesc_register_name): Adjust.
    	(tdesc_register_type): Adjust.
    	(tdesc_register_in_reggroup_p): Adjust.
    	(class print_c_tdesc) <visit>: Adjust.
    	(class print_c_feature) <visit>: Adjust.

commit c9c895b9666e33a2b910faf9c1b667ea665f00f1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 5 16:30:24 2017 -0500

    Make tdesc_feature::registers an std::vector
    
    This patch makes tdesc_feature::registers an std::vector of unique_ptr
    to tdesc_reg.  This way, we don't have to manually free the tdesc_reg
    objects and the vector in the tdesc_feature destructor.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_reg_p): Remove typedef.
    	(DEF_VEC_P (tdesc_reg_p)): Remove.
    	(struct tdesc_feature) <registers>: Change type to std::vector.
    	<~tdesc_feature>: Don't manually free registers.
    	<accept>: Adjust.
    	<operator==>: Adjust.
    	(tdesc_has_registers): Adjust.
    	(tdesc_find_register_early): Adjust.
    	(tdesc_use_registers): Adjust.
    	(tdesc_create_reg): Adjust.

commit f65ff9f9a4add415e5ae332a094b2134c1625517
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:24 2017 -0500

    Make tdesc_feature::name an std::string
    
    ... so we don't have to manually free it in ~tdesc_feature.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_feature) <name>: Change type to
    	std::string.
    	<~tdesc_feature>: Don't manually free name.
    	<operator==>: Adjust.
    	(tdesc_find_feature): Adjust.
    	(tdesc_feature_name): Adjust.
    	(class print_c_tdesc) <visit_pre>: Adjust.
    	(class print_c_feature) <visit_pre>: Adjust.

commit 3eea796c5daeb7b60531fc3d707470fa91a86e11
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:23 2017 -0500

    Make target_desc::features an std::vector
    
    This patch makes target_desc to be a vector of unique_ptr to
    tdesc_feature objects.  This way, we don't have to manually free the
    features and the vector in the target_desc destructor.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (tdesc_feature_p): Remove typedef.
    	(DEF_VEC_P (tdesc_feature_p)): Remove.
    	(struct target_desc) <features>: Change type to std::vector.
    	<~target_desc>: Replace with default implementation.
    	<accept>: Adjust.
    	<operator==>: Adjust.
    	(tdesc_has_registers): Adjust.
    	(tdesc_find_feature): Adjust.
    	(tdesc_use_registers): Adjust.
    	(tdesc_create_feature): Adjust.

commit 40e2a9835f6cf47b630babef3fd788e413ef2dc5
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:22 2017 -0500

    Make target_desc::compatible an std::vector
    
    This patch changes target_desc::compatible to be a vector of
    bfd_arch_info *.  This way, we don't need to manually free the vector in
    the target_desc destructor.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (arch_p): Remove typedef.
    	(DEF_VEC_P (arch_p)): Remove.
    	(struct target_desc) <compatible>: Change type to std::vector.
    	<~target_desc>: Don't manually free compatible.
    	(tdesc_compatible_p): Adjust.
    	(tdesc_add_compatible): Adjust.
    	(class print_c_tdesc) <visit_pre>: Adjust.

commit 129c10bcb9b3bc2ed9682040aa9a0d144bb5e959
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Dec 5 16:30:22 2017 -0500

    Make target_desc::properties an std::vector
    
    This patch changes target_desc::properties to be a vector of property
    objects.  This way, we don't need to manually free the property members
    as well as the property objects themselves.
    
    gdb/ChangeLog:
    
    	* target-descriptions.c (property_s): Remove typedef.
    	(DEF_VEC_O (property_s)): Remove.
    	(struct target_desc) <properties>: Make an std::vector.
    	<~target_desc>: Don't manually free properties.
    	(tdesc_property): Adjust.
    	(set_tdesc_property): Adjust.
    	(class print_c_tdesc) <visit_pre>: Adjust.

commit ed9376bd95c52ba00aa37b224b4407030a00d184
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 5 16:15:08 2017 -0500

    Redefine gdb_static_assert as static_assert
    
    Since we use C++11, we can use static_assert instead doing the trick
    that makes a negative-sized array if the expression is false.
    static_assert is built in the language and gives clearer error messages.
    
    To avoid modifying the usages of gdb_static_assert, redefine
    gdb_static_assert in terms of static_assert, passing an empty message.
    If we want to add an assert with a message, it's always possible to use
    static_assert directly.
    
    gdb/ChangeLog:
    
    	* common/gdb_assert.h (gdb_static_assert): Redefine using
    	static_assert.

commit 798a7429f980a00844c22dfdda9475c451c635d4
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Dec 5 16:05:34 2017 -0500

    Remove some unused variables
    
    This patch removes some unused variables, found with -Wunused.  I have
    not removed everything reported by -Wunused, because some expressions
    such as
    
      struct type *arg_type = check_typedef (value_type);
    
    in bfin-tdep.c could have an unexpected but important side-effect.  I
    removed others that I considered more low-risk, such as:
    
      struct gdbarch *gdbarch = get_objfile_arch (objfile);
    
    I tested building with Python 2/Python 3/no Python, with/without expat,
    with/without libipt and with/without babeltrace.
    
    gdb/ChangeLog:
    
    	* ada-lang.c (ada_collect_symbol_completion_matches): Remove
    	unused variables.
    	(ada_is_redundant_range_encoding): Likewise.
    	* ada-varobj.c (ada_varobj_get_value_of_array_variable):
    	Likewise.
    	* alpha-tdep.c (alpha_software_single_step): Likewise.
    	* arm-tdep.c (_initialize_arm_tdep): Likewise.
    	* auto-load.c (info_auto_load_cmd): Likewise.
    	* break-catch-syscall.c (insert_catch_syscall): Likewise.
    	(remove_catch_syscall): Likewise.
    	* breakpoint.c (condition_completer): Likewise.
    	(clear_command): Likewise.
    	(update_breakpoint_locations): Likewise.
    	* btrace.c (btrace_disable): Likewise.
    	(btrace_teardown): Likewise.
    	(btrace_maint_update_pt_packets): Likewise.
    	(maint_btrace_clear_cmd): Likewise.
    	* cli/cli-decode.c (lookup_cmd_1): Likewise.
    	(lookup_cmd_composition): Likewise.
    	* cli/cli-dump.c (scan_filename): Likewise.
    	(restore_command): Likewise.
    	* compile/compile-loc2c.c (compute_stack_depth): Likewise.
    	* compile/compile-object-load.c (compile_object_load): Likewise.
    	* compile/compile-object-run.c (compile_object_run): Likewise.
    	* compile/compile.c (compile_to_object): Likewise.
    	* completer.c (filename_completer): Likewise.
    	(complete_files_symbols): Likewise.
    	(complete_expression): Likewise.
    	* corelow.c (core_open): Likewise.
    	* ctf.c (ctf_start): Likewise.
    	(ctf_write_status): Likewise.
    	(ctf_write_uploaded_tsv): Likewise.
    	(ctf_write_definition_end): Likewise.
    	(ctf_open_dir): Likewise.
    	(ctf_xfer_partial): Likewise.
    	(ctf_trace_find): Likewise.
    	* disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
    	Likewise.
    	* dwarf2loc.c (allocate_piece_closure): Likewise.
    	(indirect_pieced_value): Likewise.
    	(dwarf2_evaluate_loc_desc_full): Likewise.
    	* dwarf2read.c (dw2_expand_marked_cus): Likewise.
    	(dw2_expand_symtabs_matching): Likewise.
    	(dw2_map_symbol_filenames): Likewise.
    	(read_and_check_comp_unit_head): Likewise.
    	(read_cutu_die_from_dwo): Likewise.
    	(lookup_dwo_unit): Likewise.
    	(read_comp_units_from_section): Likewise.
    	(dwarf2_compute_name): Likewise.
    	(handle_DW_AT_stmt_list): Likewise.
    	(create_cus_hash_table): Likewise.
    	(create_dwp_v2_section): Likewise.
    	(dwarf2_rnglists_process): Likewise.
    	(dwarf2_ranges_process): Likewise.
    	(dwarf2_record_block_ranges): Likewise.
    	(is_vtable_name): Likewise.
    	(read_formatted_entries): Likewise.
    	(skip_form_bytes): Likewise.
    	* elfread.c (elf_symtab_read): Likewise.
    	* exec.c (exec_file_command): Likewise.
    	* f-valprint.c (f_val_print): Likewise.
    	(info_common_command_for_block): Likewise.
    	* guile/guile.c (initialize_scheme_side): Likewise.
    	* guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
    	* guile/scm-cmd.c (cmdscm_completer): Likewise.
    	(gdbscm_register_command_x): Likewise.
    	* guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
    	* guile/scm-param.c (gdbscm_parameter_value): Likewise.
    	* guile/scm-ports.c (file_port_magic): Likewise.
    	* guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
    	(ppscm_pretty_print_one_value): Likewise.
    	(ppscm_print_children): Likewise.
    	* guile/scm-string.c (gdbscm_string_to_argv): Likewise.
    	* guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
    	* guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
    	* guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
    	* i386-tdep.c (i386_register_reggroup_p): Likewise.
    	* infcmd.c (run_command_1): Likewise.
    	(until_next_fsm_clean_up): Likewise.
    	* linespec.c (linespec_complete): Likewise.
    	(find_label_symbols): Likewise.
    	* m2-valprint.c (m2_val_print): Likewise.
    	* memattr.c (require_user_regions): Likewise.
    	(lookup_mem_region): Likewise.
    	(disable_mem_command): Likewise.
    	(mem_delete): Likewise.
    	* mep-tdep.c (mep_register_name): Likewise.
    	(mep_analyze_prologue): Likewise.
    	* mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
    	* mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
    	* mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
    	* microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
    	* minidebug.c (lzma_open): Likewise.
    	* minsyms.c (lookup_minimal_symbol): Likewise.
    	* mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
    	* mips-tdep.c (mips_stub_frame_sniffer): Likewise.
    	(mips_o64_return_value): Likewise.
    	(mips_single_step_through_delay): Likewise.
    	(_initialize_mips_tdep): Likewise.
    	* nios2-tdep.c (nios2_push_dummy_call): Likewise.
    	(nios2_software_single_step): Likewise.
    	* parse.c (find_minsym_type_and_address): Likewise.
    	* psymtab.c (psym_relocate): Likewise.
    	* python/py-breakpoint.c (bppy_get_commands): Likewise.
    	(gdbpy_breakpoint_modified): Likewise.
    	* python/py-infevents.c (create_inferior_call_event_object):
    	Likewise.
    	* python/py-record-btrace.c (btpy_list_item): Likewise.
    	* python/py-type.c (typy_str): Likewise.
    	* python/py-value.c (valpy_call): Likewise.
    	* python/python.c (do_start_initialization): Likewise.
    	* record-btrace.c (record_btrace_insn_history_range): Likewise.
    	(record_btrace_call_history_range): Likewise.
    	(record_btrace_record_method): Likewise.
    	(record_btrace_xfer_partial): Likewise.
    	(btrace_get_frame_function): Likewise.
    	* record-full.c (record_full_open): Likewise.
    	* record.c (get_context_size): Likewise.
    	* registry.h (DEFINE_REGISTRY): Likewise.
    	* remote-fileio.c (remote_fileio_request): Likewise.
    	* remote.c (remote_update_thread_list): Likewise.
    	(remote_check_symbols): Likewise.
    	(remote_commit_resume): Likewise.
    	(remote_interrupt): Likewise.
    	(remote_insert_breakpoint): Likewise.
    	(compare_sections_command): Likewise.
    	* rust-exp.y (super_name): Likewise.
    	(lex_string): Likewise.
    	(convert_ast_to_type): Likewise.
    	(convert_ast_to_expression): Likewise.
    	* rust-lang.c (rust_print_struct_def): Likewise.
    	(rust_print_type): Likewise.
    	(rust_evaluate_subexp): Likewise.
    	* rx-tdep.c (rx_register_type): Likewise.
    	* ser-event.c (serial_event_clear): Likewise.
    	* serial.c (serial_open): Likewise.
    	* spu-tdep.c (spu_overlay_new_objfile): Likewise.
    	* symfile.c (section_is_overlay): Likewise.
    	(overlay_unmapped_address): Likewise.
    	(overlay_mapped_address): Likewise.
    	(simple_overlay_update_1): Likewise.
    	(simple_overlay_update): Likewise.
    	* symtab.c (symbol_find_demangled_name): Likewise.
    	(search_symbols): Likewise.
    	* target-descriptions.c (tdesc_predefined_type): Likewise.
    	* target.c (target_commit_resume): Likewise.
    	* thread.c (print_selected_thread_frame): Likewise.
    	* top.c (new_ui_command): Likewise.
    	(gdb_readline_no_editing): Likewise.
    	* tracefile-tfile.c (tfile_open): Likewise.
    	* tracepoint.c (create_tsv_from_upload): Likewise.
    	* utils.c (quit): Likewise.
    	(defaulted_query): Likewise.
    	* valarith.c (value_concat): Likewise.
    	* xml-syscall.c (xml_list_syscalls_by_group): Likewise.
    	* xml-tdesc.c (target_fetch_description_xml): Likewise.
    	* xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
    	(xtensa_pseudo_register_write): Likewise.
    
    gdb/gdbserver/ChangeLog:
    
    	* regcache.c (registers_to_string): Remove unused variable.

commit da02107a39f3eff5e0b6d6321da4e88f9564350a
Author: Jim Wilson <jimw@sifive.com>
Date:   Mon Dec 4 17:37:55 2017 -0800

    Riscv shared libraries should not export __global_pointer$.
    
    	ld/
    	* emulparams/elf32lriscv-defs.sh (SDATA_START_SYMBOLS): Mark
    	__global_pointer$ as HIDDEN.
    	* testsuite/ld-riscv-elf/gp-hidden-64.rd: New.
    	* testsuite/ld-riscv-elf/gp-hidden-lib.rd: New.
    	* testsuite/ld-riscv-elf/gp-hidden-lib.s: New.
    	* testsuite/ld-riscv-elf/gp-hidden-ver-64.rd: New.
    	* testsuite/ld-riscv-elf/gp-hidden-ver.rd: New.
    	* testsuite/ld-riscv-elf/gp-hidden-ver.s: New.
    	* testsuite/ld-riscv-elf/gp-hidder-ver.ver: New.
    	* testsuite/ld-riscv-elf/gp-hidden.rd: New.
    	* testsuite/ld-riscv-elf/gp-hidden.s: New.
    	* testsuite/ld-riscv-elf/gp-hidden.sd: New.
    	* testsuite/ld-riscv-elf/ld-riscv-elf.exp: Change riscv to riscv*.
    	Run the new tests with run_ld_link_tests.

commit 4d7efb8ce25f6d2c74c8073fbca880211cedda34
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Dec 5 00:00:22 2017 +0000

    Automatic date update in version.in

commit 3e1a70a0189ae8d2dacfef93790e42e42e721762
Author: Sergio Lopez <slp@redhat.com>
Date:   Mon Dec 4 09:17:16 2017 +0100

    Extend gdb.core/coredump-filter.exp to test dump-excluded-mappings.
    
    gdb/testsuite/ChangeLog:
    2017-11-30  Sergio Lopez  <slp@redhat.com>
    
    	* gdb.core/coredump-filter.exp: Extend test to verify
    	the functionality of the dump-excluded-mappings command.

commit c179febe79bf2fe2f64852c827813fc46da819f5
Author: Sergio Lopez <slp@redhat.com>
Date:   Mon Dec 4 09:17:15 2017 +0100

    Document the new "-a" command line option for gcore
    
    gdb/ChangeLog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* NEWS (Changes since GDB 8.0): Announce new "-a"
    	command line option for gcore.
    
    gdb/doc/ChangeLog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* gdb.texinfo (gcore man): Document new "-a" command line option.

commit cd93789b89f55355d3eeda6c31ed7bd0ed318acd
Author: Sergio Lopez <slp@redhat.com>
Date:   Mon Dec 4 09:17:14 2017 +0100

    Implement "-a" command line option for gcore
    
    With the new "-a" command line option, the user may request gcore to
    actually dump all present memory mappings. The actual effect of this
    argument is OS dependent.
    
    On GNU/Linux, it will disable use-coredump-filter and enable
    dump-excluded-mappings.
    
    gdb/ChangeLog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* gcore.in: Add "-a" command line option for instructing gdb to
    	dump all memory mappings (OS dependent).

commit 1e52e8495a074c9d1f7ef17f13b9060b76be6f41
Author: Sergio Lopez <slp@redhat.com>
Date:   Mon Dec 4 09:17:13 2017 +0100

    Document new {set,show} dump-excluded-mappings commands.
    
    gdb/ChangeLog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* NEWS (Changes since GDB 8.0): Announce {set,show}
    	dump_excluded_mappings commands.
    
    gdb/doc/ChangeLog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* gdb.texinfo (gcore): Mention new {set,show}
    	dump-excluded-mappings commands.
    	(set dump-excluded-mappings): Document new command.

commit afa840dcc021eaeb975dcde3bedbf46ea0511717
Author: Sergio Lopez <slp@redhat.com>
Date:   Mon Dec 4 09:17:12 2017 +0100

    Implement 'set dump-excluded-mappings' command
    
    Commit df8411da087dc05481926f4c4a82deabc5bc3859 implemented support for
    checking /proc/PID/coredump_filter, and also changed gcore behavior to
    unconditionally honor the VM_DONTDUMP flag, preventing sections marked
    as such for being dumped into the core file.
    
    This patch implements the 'set dump-excluded-mappings' command for
    instructing gdb to ignore the VM_DONTDUMP flag. Combined with 'set
    use-coredump-filter', this allows the user to restore the old behavior,
    dumping all sections (except the ones marked as IO) unconditionally.
    
    gdb/Changelog:
    2017-11-29  Sergio Lopez  <slp@redhat.com>
    
    	* linux-tdep.c (dump_excluded_mappings): New variable.
    	(dump_mapping_p): Use dump_excluded_mappings variable.
    	(_initialize_linux_tdep): New command 'set dump_excluded_mappings'.

commit 7403715e305f7733d8dfa4a8e1739f12f5180cb2
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Dec 1 14:16:33 2017 -0700

    Update manual for Rust change
    
    I realized today that a recent change to the Rust support required an
    update to the manual; and so I updated NEWS as well.
    
    2017-12-04  Tom Tromey  <tom@tromey.com>
    
    	* NEWS: Mention Rust trait object inspection.
    
    2017-12-04  Tom Tromey  <tom@tromey.com>
    
    	* gdb.texinfo (Rust): Update trait object status

commit 50a1fdd59c1777672a9be0e81fe2301c2a115fce
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Dec 4 15:59:20 2017 +0000

    Fix displaced-stepping RIP-relative VEX-encoded instructions (AVX) (PR gdb/22499)
    
    PR gdb/22499 is about a latent bug exposed by the switch to "maint set
    target-non-stop on" by default on x86-64 GNU/Linux, a while ago.  With
    that on, GDB is also preferring to use displaced-stepping by default.
    
    The testcase in the bug is failing because GDB ends up incorrectly
    displaced-stepping over a RIP-relative VEX-encoded instruction, like
    this:
    
     0x00000000004007f5 <+15>:    c5 fb 10 05 8b 01 00 00 vmovsd 0x18b(%rip),%xmm0        # 0x400988
    
    While RIP-relative instructions need adjustment when relocated to the
    scratch pad, GDB ends up just copying VEX-encoded instructions to the
    scratch pad unmodified, with the end result that the inferior ends up
    executing an instruction that fetches/writes memory from the wrong
    address...
    
    This patch teaches GDB about the VEX-encoding prefixes, fixing the
    problem, and adds a testcase that fails without the GDB fix.
    
    I think we may need a similar treatment for EVEX-encoded instructions,
    but I didn't address that simply because I couldn't find any
    EVEX-encoded RIP-relative instruction in the gas testsuite.  In any
    case, this commit is forward progress as-is already.
    
    gdb/ChangeLog:
    2017-12-04  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22499
    	* amd64-tdep.c (amd64_insn::rex_offset): Rename to...
    	(amd64_insn::enc_prefix_offset): ... this, and tweak comment.
    	(vex2_prefix_p, vex3_prefix_p): New functions.
    	(amd64_get_insn_details): Adjust to rename.  Also skip VEX2 and
    	VEX3 prefixes.
    	(fixup_riprel): Set VEX3.!B.
    
    gdb/testsuite/ChangeLog:
    2017-12-04  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22499
    	* gdb.arch/amd64-disp-step-avx.S: New file.
    	* gdb.arch/amd64-disp-step-avx.exp: New file.

commit 826c3f1edc2f9da4594aed86b57a7b447a46016d
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Dec 2 14:48:50 2017 +1030

    x86 map file textrel
    
    bfd/
    	* elfxx-x86.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function.  Always prints via minfo and
    	correct "readonly" to "read-only" in warning message., replacing..
    	(_bfd_x86_elf_readonly_dynrelocs): ..this.
    	(_bfd_x86_elf_size_dynamic_sections): Correct "readonly" to
    	"read-only" in warning message.  Formatting.
    	(_bfd_x86_elf_adjust_dynamic_symbol): Use readonly_dynrelocs.
    	* linker.c (bfd_link_hash_traverse): Comment typo fix.
    ld/
    	* testsuite/ld-i386/pr17935-1.d: Adjust expected error.
    	* testsuite/ld-i386/pr17935-2.d: Likewise.
    	* testsuite/ld-x86-64/pr17935-1.d: Likewise.
    	* testsuite/ld-x86-64/pr17935-2.d: Likewise.

commit acf1c7c81adc305020eec4108aa0fb4d8e75b56c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Dec 4 04:23:37 2017 -0800

    Remove binutils-pr21841.patch
    
    PR gold/21841 has been fixed on master branch.

commit 9df1861d796e5bc82a723fd5460e428491142af4
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Dec 4 04:21:21 2017 -0800

    Remove binutils-pr22309.patch
    
    PR gold/22309 has been fixed on master branch.

commit 768f75b6d7d29cfbbd5ecd49d4262bab919ca713
Merge: 65cb033 e21126b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Dec 4 04:15:33 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit e21126b7b381a9083e6670ca9adaad6060e376d1
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Dec 4 22:25:45 2017 +1030

    Documentation fix
    
    	PR 22544
    	* doc/as.texinfo (8byte): Correct.

commit c88f7cba81551fe60246af61ac41effa2d51d36a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Dec 4 00:00:26 2017 +0000

    Automatic date update in version.in

commit 48f7f3036a792c655c98b0742574841743e38f58
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Dec 4 10:12:46 2017 +1030

    Run powerpc vle gas tests for all powerpc ELF targets
    
    	* testsuite/gas/ppc/ppc.exp: Don't exclude VLE tests when little-endian.
    	* testsuite/gas/ppc/efs.d: Add -mbig to assembler options.
    	* testsuite/gas/ppc/efs2.d: Likewise.
    	* testsuite/gas/ppc/lsp-checks.d: Likewise.
    	* testsuite/gas/ppc/lsp.d: Likewise.
    	* testsuite/gas/ppc/spe.d: Likewise.
    	* testsuite/gas/ppc/spe2-checks.d: Likewise.
    	* testsuite/gas/ppc/spe2.d: Likewise.
    	* testsuite/gas/ppc/spe_ambiguous.d: Likewise.
    	* testsuite/gas/ppc/vle-mult-ld-st-insns.d: Likewise.
    	* testsuite/gas/ppc/vle-reloc.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-1.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-2.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-3.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-4.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-5.d: Likewise.
    	* testsuite/gas/ppc/vle-simple-6.d: Likewise.
    	* testsuite/gas/ppc/vle.d: Likewise.

commit 97d4213f68ce37efe4c957f761e500a13b19f16f
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Dec 4 08:38:35 2017 +1030

    Modify ppceabi ld tests to run on all powerpc ELF targets
    
    	* testsuite/ld-powerpc/powerpc.exp (ppceabitests): Add -a32 -mbig
    	to assembler options, and -melf32ppc to linker options.  Always
    	run these tests.

commit fed44c60b3a3ded5e60982af7412d20603054910
Author: Jim Wilson <jimw@sifive.com>
Date:   Sun Dec 3 15:11:07 2017 -0800

    Fix for texinfo 4.8.
    
    	gas/
    	* doc/c-riscv.texi (RISC-V-Directives): Move @section immediately after
    	@node.

commit 1e97a22796cced8bba3359df46e8c2883653516f
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Dec 3 13:01:03 2017 -0500

    Remove mem_region_vector typedef
    
    Now that make-target-delegates understands namespaces and templates,
    this typedef is no longer useful.
    
    gdb/ChangeLog:
    
    	* target.h (mem_region_vector): Remove.
    	(struct target_ops) <to_memory_map>: Change return type to
    	std::vector<mem_region>.
    	* target-debug.h (target_debug_print_mem_region_vector): Rename
    	to ...
    	(target_debug_print_std_vector_mem_region): ... this.
    	* target-delegates.c: Re-generate.

commit 10f64178412d9c6e4f2faade0da271ab8be273c9
Author: Pedro Alves <palves@redhat.com>
Date:   Sun Dec 3 12:50:43 2017 -0500

    Make make-target-delegates grok namespace scope op and template params
    
    The next patch will want to use gdb::array_view<int> as parameter type
    of a target_ops method.  However, that runs into a
    make-target-delegates limitation: target_debug_foo calls in
    target-delegates.c for parameters/return types with namespace scope
    operators ("::") or template parameters, end up looking like:
    
     @@ -1313,9 +1313,7 @@ debug_set_syscall_catchpoint (struct target_ops *self, int arg1, int arg2, int a
        fputs_unfiltered (", ", gdb_stdlog);
        target_debug_print_int (arg3);
        fputs_unfiltered (", ", gdb_stdlog);
     -  target_debug_print_int (arg4);
     -  fputs_unfiltered (", ", gdb_stdlog);
     -  target_debug_print_int_p (arg5);
     +  target_debug_print_gdb::array_view<const_int> (arg4);
    
    which obviously isn't something that compiles.  The problem is that
    make-target-delegates wasn't ever taught that '::', '<', and '>' can
    appear in parameter/return types.  You could work around it by hidding
    the unsupported characters behind a typedef in the target method
    declaration, or by using an explicit TARGET_DEBUG_PRINTER, but it's
    better to just remove the limitation.
    
    While at it, also fix an "abuse" of reserved identifiers.
    
    gdb/ChangeLog:
    
    	* make-target-delegates (munge_type): Also munge '<', '>', and
    	':'.  Avoid double underscores in identifiers, and trailing
    	underscores.
    	* target-debug.h
    	(target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
    	...
    	(target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
    	* target-delegates.c: Regenerate.

commit f0fb2488c93c00fa1436a4813a375faa00a94de5
Author: Pedro Alves <palves@redhat.com>
Date:   Sun Dec 3 15:32:08 2017 +0000

    Fix gdb.threads/process-dies-while-detaching.exp
    
    I noticed [1] a test bug in gdb.threads/process-dies-while-detaching.exp.
    Simplified, the test code in question looks somewhat like this:
    
    ~~~
      # Detach from a process, and ensure that it exits after detaching.
      # This relies on inferior I/O.
    
      proc detach_and_expect_exit {test} {
    
          gdb_test_multiple "detach" $test ....
    
          set saw_prompt 0
          set saw_inf_exit 0
          while { !$saw_prompt && !$saw_inf_exit } {
              gdb_test_multiple "" $test {
                  -re "exited, status=0" {
                      set saw_inf_exit 1
                  }
                  -re "$gdb_prompt " {
                      set saw_prompt 1
                  }
              }
          }
    
          pass $test
      }
    ~~~
    
    The bug is in the while loop's condition.  We want to make sure we see
    both the inferior output and the prompt, so the loop's test should be:
    
       -    while { !$saw_prompt && !$saw_inf_exit } {
       +    while { !$saw_prompt || !$saw_inf_exit } {
    
    If we just fix that, the test starts failing though, because it
    exposes a couple latent problems:
    
    - When called from test_detach_killed_outside, the parent doesn't
      print "exited, status=0", because in that case the child dies with a
      signal, and so detach_and_expect_exit times out.
    
      Fix it by making the parent print "signaled, sig=9" in that case,
      and have the .exp expect it.
    
    - When testing against --target_board=native-gdbserver, sometimes we'd
      get this:
    
        ERROR: Process no longer exists
        ERROR: : spawn id exp9 not open
    	while executing
        "expect {
        -i exp8 -timeout 220
    	    -i $server_spawn_id
    	    eof {
    		pass $test
    		wait -i $server_spawn_id
    		unset server_spawn_id
    	    }
    	    timeout {
    	       ..."
    	("uplevel" body line 1)
    	invoked from within
        "uplevel $body" NONE : spawn id exp9 not open
    
      The problem is that:
    
       - inferior_spawn_id and server_spawn_id are the same when testing
         with gdbserver.
       - gdbserver exits after "detach", so we get an eof for
         $inferior_spawn_id in the loop in detach_and_expect_exit.
         That's the first "ERROR: Process no longer exists".
       - and then when we reach test_server_exit, server_spawn_id
         is already closed (because server_spawn_id==inferior_spawn_id).
    
      To handle this, make the loop in detach_and_expect_exit use an
      indirect spawn id list and remove $inferior_spawn_id from the list
      as soon as we got the inferior output we're expecting, so that the
      "eof" is left unprocessed until we reach test_server_exit.
    
    [1] I changed GDB in a way that should have made the test fail, but it
        didn't.
    
    gdb/testsuite/ChangeLog:
    2017-12-03  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/process-dies-while-detaching.c: Include <errno.h>
    	and <string.h>.
    	(parent_function): Print distinct messages when waitpid fails, or
    	the child exits with a signal, or the child exits for an unhandled
    	reason.
    	* gdb.threads/process-dies-while-detaching.exp
    	(detach_and_expect_exit): New 'inf_output_re' parameter and use
    	it.  Wait for both inferior output and GDB's prompt.  Use an
    	indirect spawn id list.
    	(do_detach): New parameter 'child_exit'.  Use it to compute
    	expected inferior output.
    	(test_detach, test_detach_watch, test_detach_killed_outside):
    	Adjust to pass down the expected child exit kind.

commit f143cb5fc655e1ed0a6e15e6ba33af0d79ba1802
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Dec 3 21:51:45 2017 +1030

    Fix "FAIL: VLE relocations 3"
    
    Correct sign extension.
    
    	* ppc-opc.c (extract_li20): Rewrite.

commit c0e15c9bfd6fb4bf36e5240838f6ebed1e1f4a7e
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:46 2017 -0500

    Remove for_each_inferior_with_data
    
    Remove for_each_inferior_with_data, replacing its sole usage with
    for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.c (for_each_inferior_with_data): Remove.
    	* inferiors.h (for_each_inferior_with_data): Remove.
    	* server.c (handle_qxfer_threads_worker): Change parameter type.
    	(handle_qxfer_threads_proper): Use for_each_thread.

commit f004534791145669d7765f8122e48f21e1deeb94
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:37:53 2017 -0500

    Remove for_each_inferior
    
    This patch removes for_each_inferior, replacing all its usages with
    for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.c (for_each_inferior): Remove.
    	(clear_inferiors): Use for_each_thread.
    	* inferiors.h (for_each_inferior): Remove.
    	* linux-low.c (linux_wait_for_event_filtered): Use
    	for_each_thread.
    	(linux_stabilize_threads): Likewise.
    	* regcache.c (regcache_release): Likewise.
    	* server.c (gdb_wants_all_threads_stopped): Likewise.
    	(clear_pending_status_callback): Remove.
    	(handle_status): Use for_each_thread.
    	(captured_main): Likewise.
    	* win32-low.c (child_init_thread_list): Likewise.
    	(win32_clear_inferiors): Likewise.
    	(fake_breakpoint_event): Likewise.

commit 9521758bf967360fc1e18b2a2195d97ae19cb80d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:45 2017 -0500

    Remove find_inferior
    
    All the usages of find_inferior were removed, so the function itself can
    be removed.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h (find_inferior): Remove.
    	* inferiors.c (find_inferior): Remove.

commit 8f86d7aa8504e9a557e807a3e37718055befcd84
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:44 2017 -0500

    Update comments
    
    These functions were modified in the previous patch series, but I forgot
    to update some comments.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (resume_status_pending_p): Update comment.
    	(need_step_over_p): Update comment.

commit e2b4407579df508f85de961dd693c9028e79d823
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:43 2017 -0500

    Remove usages of find_inferior that call proceed_one_lwp
    
    Replace with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (proceed_one_lwp): Return void, change parameter
    	type.
    	(unsuspend_and_proceed_one_lwp): Likewise.
    	(proceed_all_lwps): Use for_each_thread.
    	(unstop_all_lwps): Likewise.

commit c80825ff32ba805982ef5e66e4fa1a80e019d47d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:42 2017 -0500

    Remove usage of find_inferior in linux_resume
    
    Replace with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (linux_resume_one_thread): Return void, take
    	parameter directly.
    	(linux_resume): Use for_each_thread.

commit df3e4dbe661e522cc63d3dab15c3974713fba4dd
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:41 2017 -0500

    Remove usages of find_inferior in stop_all_lwps
    
    Replace with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (send_sigstop_callback): Return void, change
    	parameter type.  Rename to...
    	(send_sigstop): ... this.
    	(suspend_and_send_sigstop_callback): Return void, change parameter
    	type.  Rename to...
    	(suspend_and_send_sigstop): ... this.
    	(stop_all_lwps): Use for_each_thread.

commit 5a6b0a41dfc9b860f285ddb3a1e518299f614cd3
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:41 2017 -0500

    Remove usage of find_inferior in linux_stabilize_threads
    
    Replace with find_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (lwp_running): Return bool, remove unused
    	argument.
    	(linux_stabilize_threads): Use find_thread.

commit 39a64da5fc9ce6decd7e5ba0bacfeb2144d2bd63
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:40 2017 -0500

    Remove usages of find_inferior in select_event_lwp
    
    Replace with find_thread/for_each_thread.  I inlined the callbacks,
    because they are relatively simple.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (select_singlestep_lwp_callback): Remove.
    	(count_events_callback): Remove.
    	(select_event_lwp_callback): Remove.
    	(select_event_lwp): Use find_thread/for_each_thread.

commit a1385b7b881d2b129f8c26fac8ad20bc406a1a6d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:39 2017 -0500

    Remove usages of find_inferior calling not_stopped_callback
    
    Replace with find_thread.  Writing a lambda inline in directly in the if
    conditions would be a bit messy, so I chose to assign them to variables
    instead.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (not_stopped_callback): Return bool, take filter
    	argument directly.
    	(linux_wait_for_event_filtered): Use find_thread.
    	(linux_wait_1): Likewise.

commit 454296a2c1f3afe163e49730b9b396ffdd985e1f
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:38 2017 -0500

    Remove usage of find_inferior in find_lwp_pid
    
    Replace with find_thread.  We could almost use find_thread_ptid, except
    that find_lwp_pid uses the pid of the input ptid of the lwp is 0, so the
    behavior is not quite the same.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (same_lwp): Remove.
    	(find_lwp_pid): Use find_thread.

commit 6b2a85daf5a5c20c6d4832de1f19109d9e1cf17a
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:37 2017 -0500

    Remove usage of find_inferior in linux_mourn
    
    Replace with for_each_thread with pid filtering.  The callback becomes
    trivial enough that it's better to inline it.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (delete_lwp_callback): Remove.
    	(linux_mourn): Use for_each_thread.

commit 798a38e8de5f0fb5f7b17ae757b2bf4c5139c023
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:36 2017 -0500

    Remove usage of find_inferior in linux_detach
    
    Replace with for_each_thread with pid filtering.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (linux_detach_lwp_callback): Return void, remove
    	args parameter, don't check for pid.
    	(linux_detach): Use for_each_thread.

commit e4eb0dec0b9219a27ea6b9769f098fff34612779
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:36 2017 -0500

    Remove usage of find_inferior in last_thread_of_process_p
    
    Replace it with find_thread.  I also modified the code a bit to use a
    lambda and a boolean.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (struct counter): Remove.
    	(second_thread_of_pid_p): Remove.
    	(last_thread_of_process_p): Use find_thread.

commit 83e1b6c13a285b4e1e852e1647667f09bb26892b
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:35 2017 -0500

    Remove find_inferior_in_random
    
    Replace with find_thread_in_random.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.c (find_inferior_in_random): Remove.
    	* inferiors.h (find_inferior_in_random): Remove.
    	* linux-low.c (status_pending_p_callback): Return bool, accept
    	parameter ptid directly.
    	(linux_wait_for_event_filtered): Use find_thread_in_random.
    	(linux_wait_1): Likewise.

commit 8dc7b443a6295da4b3d7ba22f3a7695990bf4f39
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:34 2017 -0500

    Remove find_inferior_id
    
    Remove find_inferior_id, replacing its usages with find_thread_ptid.
    find_thread_ptid was implemented using find_inferior_id, so move the
    implementation there instead.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.c (find_inferior_id): Remove.
    	(find_thread_ptid): Move implemention from find_inferior_id to
    	here.
    	* inferiors.h (find_inferior_id): Remove.
    	* server.c (handle_status): Use find_thread_ptid.
    	(process_serial_event): Likewise.
    	* thread-db.c (find_one_thread): Likewise.
    	(thread_db_thread_handle): Likewise.
    	* win32-low.c (thread_rec): Likewise.
    	(child_delete_thread): Likewise.
    	(win32_thread_alive): Likewise.
    	(get_child_debug_event): Likewise.

commit da25033cd92a60f4462e1468abfabfee02d0b8d9
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:33 2017 -0500

    Remove usages of find_inferior in linux-mips-low.c
    
    Replace with for_each_thread with pid filtering.  This allows
    simplifying the callback a little bit.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-mips-low.c (update_watch_registers_callback): Return
    	void, remove pid_p parameter, don't check for pid.
    	(mips_insert_point, mips_remove_point): Use for_each_thread.

commit c91bb56b06b52d45de7c8871a6d44ddae61ae977
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:32 2017 -0500

    Remove usage of find_inferior in lynx_mourn
    
    Replace it with for_each_thread with pid filtering.  We can remove
    lynx_delete_thread_callback and pass remove_thread directly.
    
    I can't build/test this change, but it should be obvious enough.
    
    gdb/gdbserver/ChangeLog:
    
    	* lynx.low (lynx_delete_thread_callback): Remove.
    	(lynx_mourn): Use for_each_thread.

commit 634a3254c8fe1728c0202289afe594928094d860
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:36:32 2017 -0500

    Remove usage of find_inferior in regcache_invalidate_pid
    
    Replace with for_each_thread with pid filtering.
    regcache_invalidate_one is not longer needed, as it was only used to
    filter the pid.  We can call regcache_invalidate_thread directly.
    
    gdb/gdbserver/ChangeLog:
    
    	* regcache.c (regcache_invalidate_one): Remove.
    	(regcache_invalidate_pid): use for_each_thread.

commit 6d83e819df0c71868d04db46c60ff0ecf8cf1914
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Dec 2 20:28:22 2017 -0500

    Fix typo in poison.h
    
    gdb/ChangeLog:
    
    	* common/poison.h (XDELETE): Fix typo.

commit 035d856f2c3a30750e1260c595eca1e92e94421f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Dec 3 00:00:36 2017 +0000

    Automatic date update in version.in

commit 222b39c283e3fd7823ad95ccc58ae94e76b63237
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Sat Dec 2 09:56:40 2017 -0800

    Handle case where posix_fallocate is not supported for a filesystem.
    
    2017-12-02  Vladimir Kondratyev  <vladimir@kondratyev.su>
    	    Cary Coutant  <ccoutant@gmail.com>
    
    gold/
    	PR gold/22540
    	* output.cc (gold_fallocate): Trivial return for len == 0.
    	Add fallback options when posix_fallocate and fallocate return
    	not-supported errors.

commit 158600eb989bcbc364c6d18259f1cb32ea9dc478
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Wed Feb 15 00:25:29 2017 -0800

    Disallow --incremental with -pie and force -no-pie for incremental tests.
    
    This is a partial fix for the gold testsuite failures documented in
    PR 21090. The use of -fpie triggers some mov-to-lea optimizations that
    are not compatible with incremental linking, so those optimizations need
    to be disabled. We also diagnose the attempt to use -pie with incremental
    linking, and force -no-pie for the incremental tests in case the build has
    been configured to have GCC pass -pie all the time.
    
    We still have a problem where compiling with -fpie results in some GOT
    entries even when linking with -no-pie. This combination still causes test
    failures because we are not updating the GOT entries in an incremental update
    link.
    
    gold/
    	PR gold/21090
    	* incremental.cc (Sized_relobj_incr::do_relocate): Fix comment.
    	* options.cc (General_options::finalize): Disallow -pie with
    	incremental linking.
    	* x86_64.cc (Target_x86_64::Scan::local): Don't do mov-to-lea
    	or callq-to-direct optimizations for incremental links.
    	(Target_x86_64::Scan::global): Likewise.
    	(Target_x86_64::Relocate::relocate): Likewise.
    	* testsuite/Makefile.am (incremental_test): Force -no-pie.
    	(incremental_test_2): Likewise.
    	(incremental_test_3): Likewise.
    	(incremental_test_4): Likewise.
    	(incremental_test_5): Likewise.
    	(incremental_test_6): Likewise.
    	(incremental_copy_test): Likewise.
    	(incremental_common_test_1): Likewise.
    	(incremental_comdat_test_1):  Likewise.
    	* testsuite/Makefile.in: Regenerate.

commit 0af4ccfc5bc7ded4d87f813e3754486eb5a75349
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Fri Dec 1 22:53:08 2017 -0800

    Workaround GCC 7 bug with debug line numbers causing debug_msg.sh failure.
    
    gold/
    	PR gold/21841
    	* testsuite/debug_msg.sh: Adjust expected line numbers.
    	* testsuite/odr_violation2.cc (DummyFunction): New function.

commit 059256c7465164fc070482dbe04ebe4e2ccf1a08
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Fri Dec 1 22:03:09 2017 -0800

    Fix incremental linking failure with GCC 7+.
    
    With the new compiler, we're running out of patch space for the .eh_frame
    section. To workaround that issue, we compile the before and after versions
    both with no unwind tables.
    
    gold/
    	PR gold/22309
    	* testsuite/Makefile.am (two_file_test_1_v1_ndebug.o): Compile with
    	no EH information.
    	(two_file_test_1_ndebug.o): Likewise.
    	* testsuite/Makefile.in: Regenerate.
    	* testsuite/two_file_test_1.cc: Touch to force recompilation with new
    	flags.
    	* testsuite/two_file_test_1_v1.cc: Likewise.

commit 97cbe998d0dd5c13a0317fbb24d745da367d8caa
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Nov 24 16:56:08 2017 -0500

    Add support for the readnever concept
    
    The purpose of this concept is to turn the load of debugging
    information off, either globally (via the '--readnever' option), or
    objfile-specific.  The implementation proposed here is an extension of
    the patch distributed with Fedora GDB; looking at the Fedora patch
    itself and the history, one can see some reasons why it was never
    resubmitted:
    
      - The patch appears to have been introduced as a workaround, at
        least initially;
      - The patch is far from perfect, as it simply shunts the load of
        DWARF debugging information, without really worrying about the
        other debug format.
      - Who really does non-symbolic debugging anyways?
    
    One use of this feature is when a user simply wants to do the
    following sequence: attach, dump core, detach.  Loading the debugging
    information in this case is an unnecessary cause of delay.
    
    This patch expands the version shipped with Fedora GDB in order to
    make the feature available for all the debuginfo backends, not only
    for DWARF.  It also implements a per-objfile flag which can be
    activated by using the "-readnever" command when using the
    'add-symbol-file' or 'symbol-file' commands.
    
    It's also worth mentioning that this patch tests whether GDB correctly
    fails to initialize if both '--readnow' and '--readnever' options are
    passed.
    
    Tested on the BuildBot.
    
    gdb/ChangeLog:
    
    2017-12-01  Andrew Cagney  <cagney@redhat.com>
    	    Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* NEWS (Changes since GDB 8.0: Mention new '--readnever'
    	feature.
    	* coffread.c (coff_symfile_read): Do not map over sections with
    	'coff_locate_sections' if readnever is on.
    	* dwarf2read.c (dwarf2_has_info): Return 0 if
    	readnever is on.
    	* elfread.c (elf_symfile_read): Do not map over sections with
    	'elf_locate_sections' if readnever is on.
    	* main.c (validate_readnow_readnever): New function.
    	(captured_main_1): Add support for --readnever.
    	(print_gdb_help): Document --readnever.
    	* objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
    	flag.
    	* symfile.c (readnever_symbol_files): New global.
    	(symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
    	'READNEVER_SYMBOL_FILES' is set.
    	(validate_readnow_readnever): New function.
    	(symbol_file_command): Handle '-readnever' option.
    	Call 'validate_readnow_readnever'.
    	(add_symbol_file_command): Handle '-readnever' option.
    	Call 'validate_readnow_readnever'.
    	(_initialize_symfile): Document new '-readnever' option for
    	both 'symbol-file' and 'add-symbol-file' commands.
    	* top.h (readnever_symbol_files): New extern global.
    	* xcoffread.c (xcoff_initial_scan): Do not read debug
    	information if readnever is on.
    
    gdb/doc/ChangeLog:
    
    2017-12-01  Andrew Cagney  <cagney@redhat.com>
    	    Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.texinfo (File Options): Document --readnever.
    	(Commands to Specify Files): Likewise, for 'symbol-file' and
    	'add-symbol-file'.
    
    gdb/testsuite/ChangeLog:
    
    2017-12-01  Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/readnever.c, gdb.base/readnever.exp: New files.

commit 754fa8997d48bc9da80e8c2e0baaf36a313ba74a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Dec 2 00:00:25 2017 +0000

    Automatic date update in version.in

commit b57e49f726f854e65b2ce5e87dc7ee664daac1fb
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Dec 1 15:34:42 2017 -0800

    Update and clean up RISC-V gas documentation.
    
    	gas/
    	* doc/as.texinfo (RISC-V): Alphabetize RISC-V entries.  Change
    	RISC-V-Opts to RISC-V-Options.  Delete redundant space.  Add -fpic
    	and related options to option list.
    	* doc/c-riscv.texi: (RISC-V-Options): Renamed from RISC-V-Opts.
    	(RISC-V Options): Renamed from Options.  Add missing period.
    	(-fpic): Also mention -fPIC.
    	(RISC-V Directives): New node.

commit 40fc416f4e22913ba2a2bafcc8da05f59c677b7d
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Wed Nov 29 16:36:13 2017 -0500

    Make '{add-,}symbol-file' not care about the position of command line arguments
    
    This is a bug that's been detected while doing the readnever work.
    
    If you use 'symbol-file' or 'add-symbol-file', the position of each
    argument passed to the command matters.  This means that if you do:
    
      (gdb) symbol-file -readnow /foo/bar
    
    The symbol file specified will (correctly) have all of its symbols
    read by GDB (because of the -readnow flag).  However, if you do:
    
      (gdb) symbol-file /foo/bar -readnow
    
    GDB will silently ignore the -readnow flag, because it was specified
    after the filename.  This is not a good thing to do and may confuse
    the user.
    
    To address that, I've modified the argument parsing mechanisms of
    symbol_file_command and add_symbol_file_command to be
    "position-independent".  I have also added one error call at the end
    of add_symbol_file_command's argument parsing logic, which now clearly
    complains if no filename has been specified.  Both commands now
    support the "--" option to stop argument processing.
    
    This patch provides a testcase for both commands, in order to make
    sure that the argument order does not matter.  It has been
    regression-tested on BuildBot.
    
    gdb/ChangeLog:
    
    2017-12-01  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* symfile.c (symbol_file_command): Call
    	'symbol_file_add_main_1' only after processing all command
    	line options.
    	(add_symbol_file_command): Modify logic to make arguments
    	position-independent.
    
    gdb/testsuite/ChangeLog:
    
    2017-12-01  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.base/relocate.exp: Add tests to guarantee that arguments
    	to 'symbol-file' and 'add-symbol-file' can be
    	position-independent.

commit 7f0f8ac8b15f5f5327116614b4137e5dd533ada2
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Dec 1 16:58:47 2017 -0500

    Revert "Add support for the readnever concept"
    
    This reverts commit e2e321740ce2e36a97be2a410cd56eebaa2304aa.
    
    It was mistakenly pushed.

commit 7ef67ba53397c52a87375403aa614c52b94ccc73
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Fri Dec 1 13:44:54 2017 -0800

    Fix localized help string output for -fuse-ld.
    
    gold/
    	PR gold/22042
    	* options.h (-fuse-ld): Use NULL instead of empty string.

commit ec6a20c268c3be4c34b951bc7d02543dca956108
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Dec 1 15:45:30 2017 -0500

    (Ada) GDB crash printing expression with type casting
    
    One of our users reported that trying to print the following expression,
    caused GDB to SEGV:
    
        (gdb) print some_package.some_type (val)
    
    In this particular instance, the crash occurred inside ada_args_match
    because it is given a NULL "func", leading to the SEGV because of:
    
        struct type *func_type = SYMBOL_TYPE (func);
    
    This NULL symbol comes from a list of symbols which was given to
    ada_resolve_function (parameter called "syms") which then iterates
    over each of them to discard the ones that don't match the actuals:
    
         for (k = 0; k < nsyms; k += 1)
           {
             struct type *type = ada_check_typedef (SYMBOL_TYPE (syms[k].symbol));
    
             if (ada_args_match (syms[k].symbol, args, nargs)
                 && (fallback || return_match (type, context_type)))
             [...]
           }
    
    What's really interesting is that, when entering the block above for
    the first time, all entries in SYMS have a valid (non-NULL) symbol.
    However, once we return from the call to ada_check_typedef, the first
    entry of our SYMS table gets set to all zeros:
    
        (gdb) p syms[0]
        $2 = {symbol = 0x0, block = 0x0}
    
    Hence the call to ada_args_match with a NULL symbol, and the ensuing
    SEGV.
    
    To find out why this happen, we need to step back a little and look
    at how syms was allocated. This list of symbols comes from a symbol
    lookup, which means ada_lookup_symbol_list_worker. We have our first
    hint when we look at the function's documentation and see:
    
        This vector is transient---good only to the next call of
        ada_lookup_symbol_list.
    
    Implementation-wise, this is done by using a static global obstack,
    which we just re-initialize each time ada_lookup_symbol_list_worker
    gets called:
    
        obstack_free (&symbol_list_obstack, NULL);
        obstack_init (&symbol_list_obstack);
    
    This property was probably established in order to facilitate the use
    of the returned vector, since the users of that function would not have
    to worry about releasing that memory when no longer needed. However,
    I found during this investigation that it is all to easy to indirectly
    trigger another symbol lookup while still using the results of a previous
    lookup.
    
    In our particular case, there is the call to ada_check_typedef, which
    leads to check_typedef. As it happens, my first symbol had a type which
    was a typedef to a stub type, so check_typedef calls lookup_symbol to
    find the non-stub version. This in turn eventually leads us back to
    ada_lookup_symbol_list_worker, where the first thing it does is free
    the memory area when our list of symbols have been residing and then
    recreates a new one. in other words, SYMS then becomes a dangling
    pointer!
    
    This patch fixes the issue by having ada_lookup_symbol_list_worker
    return a copy of the list of symbols, with the responsibility of
    deallocating that list now transfered to the users of that list.
    
    More generally speaking, it is absolutely amazing that we haven't seen
    consequences of this issue before. This can happen fairly frequently.
    For instance, I found that ada-exp.y::write_var_or_type calls
    ada_lookup_symbol_list, and then, while processing that list, calls
    select_possible_type_sym, which leads to ada_prefer_type, eventually
    leading to ada_check_typedef again (via eg. ada_is_array_descriptor_type).
    
    Even more amazing is the fact that, while I was able to produce multiple
    scenarios where the corruption occurs, none of them leads to incorrect
    behavior at the user level. In other words, it requires a very precise
    set of conditions for the corruption to become user-visible, and
    despite having a megalarge program where the crash occured, using that
    as a template for creating a reproducer did not work (pb goes away).
    This is why this patch does not come with a reproducer. On the other hand,
    this should not be a problem in terms of testing coverage, as the changes
    are made in common areas which, at least for the most part, are routinely
    exercised during testing.
    
    gdb/ChangeLog:
    
            * ada-lang.c (symbol_list_obstack): Delete.
            (resolve_subexp): Make sure "candidates" gets xfree'ed.
            (ada_lookup_symbol_list_worker): Remove the limitation that
            the result is only good until the next call, now making it
            the responsibility of the caller to free the result when no
            longer needed.  Adjust the function's intro comment accordingly.
            (ada_lookup_symbol_list): Adjust the function's intro comment.
            (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
            (ada_lookup_encoded_symbol, get_var_value): Likewise.
            (_initialize_ada_language): Remove symbol_list_obstack
            initialization.
            * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
            (write_var_or_type, write_name_assoc): Likewise.
    
    Tested on x86_64-linux.

commit bd2e3511f74940beec6a39914480ed6ff88c0a71
Author: Benjamin Peterson <bp@benjamin.pe>
Date:   Fri Dec 1 12:59:36 2017 -0800

    Fix internal error from command line with unbalanced --start-lib/--end-lib.
    
    The problem is that while the command line isn't trivially empty,
    it contains no input files. As gold tries to configure the number
    of threads to use based on the number of input files, this causes
    the assertion failure above. Fix this problem by making the logic
    in gold.cc more robust and also adding a better error message
    about --start-lib to options.cc.
    
    gold/
    	PR gold/22406
    	* gold.cc (queue_initial_tasks) Check for number of real input files.
    	* options.cc (Command_line::process) Check for unterminated --start-lib
    	options.
    	* testsuite/Makefile.am: Add new test script.
    	* testsuite/Makefile.in: Regenerate.
    	* testsuite/check_empty_command_lines.sh: New test script.

commit 71739b698d47945463f183619078ff680c277f0f
Author: Stephen Crane <sjc@immunant.com>
Date:   Fri Dec 1 12:10:02 2017 -0800

    Fix problem where undef can fail to trigger archive rescan.
    
    If a shared library contains an undefined symbol and LTO adds
    a new reference to that same undefined symbol, the reference in the new
    object added by the plugin would not trigger a rescan of the archive
    containing the symbol.
    
    2017-11-17  Stephen Crane  <sjc@immunant.com>
    
    gold/
    	PR gold/22448
    	* symtab.cc (Symbol_table::add_from_object): Only rescan for
    	undefined symbols in regular, not dynamic, objects.

commit e2e321740ce2e36a97be2a410cd56eebaa2304aa
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Nov 24 16:56:08 2017 -0500

    Add support for the readnever concept
    
    The purpose of this concept is to turn the load of debugging
    information off, either globally (via the '--readnever' option), or
    objfile-specific.  The implementation proposed here is an extension of
    the patch distributed with Fedora GDB; looking at the Fedora patch
    itself and the history, one can see some reasons why it was never
    resubmitted:
    
      - The patch appears to have been introduced as a workaround, at
        least initially;
      - The patch is far from perfect, as it simply shunts the load of
        DWARF debugging information, without really worrying about the
        other debug format.
      - Who really does non-symbolic debugging anyways?
    
    One use of this feature is when a user simply wants to do the
    following sequence: attach, dump core, detach.  Loading the debugging
    information in this case is an unnecessary cause of delay.
    
    This patch expands the version shipped with Fedora GDB in order to
    make the feature available for all the debuginfo backends, not only
    for DWARF.  It also implements a per-objfile flag which can be
    activated by using the "-readnever" command when using the
    'add-symbol-file' or 'symbol-file' commands.
    
    It's also worth mentioning that this patch tests whether GDB correctly
    fails to initialize if both '--readnow' and '--readnever' options are
    passed.
    
    Tested on the BuildBot.
    
    gdb/ChangeLog:
    
    2017-12-01  Andrew Cagney  <cagney@redhat.com>
    	    Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* NEWS (Changes since GDB 8.0: Mention new '--readnever'
    	feature.
    	* coffread.c (coff_symfile_read): Do not map over sections with
    	'coff_locate_sections' if readnever is on.
    	* dwarf2read.c (dwarf2_has_info): Return 0 if
    	readnever is on.
    	* elfread.c (elf_symfile_read): Do not map over sections with
    	'elf_locate_sections' if readnever is on.
    	* main.c (validate_readnow_readnever): New function.
    	(captured_main_1): Add support for --readnever.
    	(print_gdb_help): Document --readnever.
    	* objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
    	flag.
    	* symfile.c (readnever_symbol_files): New global.
    	(symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
    	'READNEVER_SYMBOL_FILES' is set.
    	(validate_readnow_readnever): New function.
    	(symbol_file_command): Handle '-readnever' option.
    	Call 'validate_readnow_readnever'.
    	(add_symbol_file_command): Handle '-readnever' option.
    	Call 'validate_readnow_readnever'.
    	(_initialize_symfile): Document new '-readnever' option for
    	both 'symbol-file' and 'add-symbol-file' commands.
    	* top.h (readnever_symbol_files): New extern global.
    	* xcoffread.c (xcoff_initial_scan): Do not read debug
    	information if readnever is on.
    
    gdb/doc/ChangeLog:
    
    2017-12-01  Andrew Cagney  <cagney@redhat.com>
    	    Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.texinfo (File Options): Document --readnever.
    	(Commands to Specify Files): Likewise, for 'symbol-file' and
    	'add-symbol-file'.
    
    gdb/testsuite/ChangeLog:
    
    2017-12-01  Joel Brobecker  <brobecker@adacore.com>
    	    Sergio Durigan Junior  <sergiodj@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/readnever.c, gdb.base/readnever.exp: New files.

commit 0f873fd58b51a2906f31bb445ab685da04a1be23
Author: Peter Bergner <bergner@vnet.ibm.com>
Date:   Fri Dec 1 11:20:15 2017 -0600

    Use consistent types for holding instructions, instruction masks, etc.
    
    include/
    	* opcode/ppc.h (PPC_INT_FMT): Define.
    	(struct powerpc_opcode) <opcode>: Update type.
    	(struct powerpc_opcode) <mask>: Likewise.
    	(struct powerpc_opcode) <bitm>: Likewise.
    	(struct powerpc_opcode) <insert>: Likewise.
    	(struct powerpc_opcode) <extract>: Likewise.
    	(ppc_optional_operand_value): Likewise.
    
    gas/
    	* config/tc-ppc.c (last_insn): Update type.
    	(insn_validate) <omask, mask>: Likewise.
    	(ppc_setup_opcodes) <mask, right_bit>: Likewise.
    	<PRINT_OPCODE_TABLE>: Update types and printf format specifiers.
    	(ppc_insert_operand): Update return and argument types and remove
    	unneeded type casts.
    	<min, max, right, tmp>: Update type.
    	(md_assemble): Remove unneeded type casts.
    	<insn, val, tmp_insn>: Update type.
    
    opcodes/
    	* opcodes/ppc-dis.c (disassemble_init_powerpc): Fix white space.
    	(operand_value_powerpc): Update return and argument type.
    	<value, top>: Update type.
    	(skip_optional_operands): Update argument type.
    	(lookup_powerpc): Likewise.
    	(lookup_vle): Likewise.
    	<table_opcd, table_mask, insn2>: Update type.
    	(lookup_spe2): Update argument type.
    	<table_opcd, table_mask, insn2>: Update type.
    	(print_insn_powerpc) <insn, value>: Update type.
    	Use PPC_INT_FMT for printing instructions and operands.
    	* opcodes/ppc-opc.c (insert_arx, extract_arx, insert_ary, extract_ary,
    	insert_rx, extract_rx, insert_ry, extract_ry, insert_bat, extract_bat,
    	insert_bba, extract_bba, insert_bdm, extract_bdm, insert_bdp,
    	extract_bdp, valid_bo_pre_v2, valid_bo_post_v2, valid_bo, insert_bo,
    	extract_bo, insert_boe, extract_boe, insert_dcmxs, extract_dcmxs,
    	insert_dxd, extract_dxd, insert_dxdn, extract_dxdn, insert_fxm,
    	extract_fxm, insert_li20, extract_li20, insert_ls, extract_ls,
    	insert_esync, extract_esync, insert_mbe, extract_mbe, insert_mb6,
    	extract_mb6, extract_nb, insert_nbi, insert_nsi, extract_nsi,
    	insert_ral, extract_ral, insert_ram, extract_ram, insert_raq,
    	extract_raq, insert_ras, extract_ras, insert_rbs, extract_rbs,
    	insert_rbx, extract_rbx, insert_sci8, extract_sci8, insert_sci8n,
    	extract_sci8n, insert_sd4h, extract_sd4h, insert_sd4w, extract_sd4w,
    	insert_oimm, extract_oimm, insert_sh6, extract_sh6, insert_spr,
    	extract_spr, insert_sprg, extract_sprg, insert_tbr, extract_tbr,
    	insert_xt6, extract_xt6, insert_xtq6, extract_xtq6, insert_xa6,
    	extract_xa6, insert_xb6, extract_xb6, insert_xb6s, extract_xb6s,
    	insert_xc6, extract_xc6, insert_dm, extract_dm, insert_vlesi,
    	extract_vlesi, insert_vlensi, extract_vlensi, insert_vleui,
    	extract_vleui, insert_vleil, extract_vleil, insert_evuimm1_ex0,
    	extract_evuimm1_ex0, insert_evuimm2_ex0, extract_evuimm2_ex0,
    	insert_evuimm4_ex0, extract_evuimm4_ex0, insert_evuimm8_ex0,
    	extract_evuimm8_ex0, insert_evuimm_lt8, extract_evuimm_lt8,
    	insert_evuimm_lt16, extract_evuimm_lt16, insert_rD_rS_even,
    	extract_rD_rS_even, insert_off_lsp, extract_off_lsp, insert_off_spe2,
    	extract_off_spe2, insert_Ddd, extract_Ddd): Update types.
    	(OP, OPTO, OPL, OPVUP, OPVUPRT, A, AFRALFRC_MASK, B, BD8, BD8IO, BD15,
    	BD24, BBO, Y_MASK  , AT1_MASK, AT2_MASK, BBOCB, C_LK, C, CTX, UCTX,
    	DX, EVSEL, IA16, I16A, I16L, IM7, LI20, MME, MD, MDS, SC, SC_MASK,
    	SCI8, SCI8BF, SD4, SE_IM5, SE_R, SE_RR, VX, VX_LSP, VX_RA_CONST,
    	VX_RB_CONST, VX_SPE_CRFD, VX_SPE2_CLR, VX_SPE2_SPLATB, VX_SPE2_OCTET,
    	VX_SPE2_DDHH, VX_SPE2_HH, VX_SPE2_EVMAR, VX_SPE2_EVMAR_MASK, VXA,
    	VXR, VXASH, X, EX, XX2, XX3, XX3RC, XX4, Z, XWRA_MASK, XLRT_MASK,
    	XRLARB_MASK, XLRAND_MASK, XRTLRA_MASK, XRTLRARB_MASK, XRTARARB_MASK,
    	XRTBFRARB_MASK, XOPL, XOPL2, XRCL, XRT, XRTRA, XCMP_MASK, XCMPL_MASK,
    	XTO, XTLB, XSYNC, XEH_MASK, XDSS, XFL, XISEL, XL, XLO, XLYLK, XLOCB,
    	XMBAR, XO, XOPS, XS, XFXM, XSPR, XUC, XW, APU): Update types in casts.

commit d0df06af9b70c5a6a2aa496437364f219e669067
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Nov 30 11:49:27 2017 -0700

    Fix dependency tracking for objects in subdirectories
    
    On irc, Pedro pointed out that dependencies for objects in
    subdirectories didn't seem to be working.
    
    The bug was that the "-include" for .deps files was using the wrong file
    name for subdirectory objects; e.g., for cli/cli-decode.o it was trying
    to open .deps/cli/cli-decode.o, whereas the correct file is
    cli/.deps/cli-decode.o.
    
    This patch changes how the dep files are found.  Tested by touching a
    source file and rebuilding cli/cli-decode.o.
    
    2017-12-01  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (all_deps_files): New variable.
    	Include .Po files using all_deps_files.

commit 2ee0c9b3eedca5d1071870334d2721be80a77ea1
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Dec 1 08:35:56 2017 -0500

    Update GDB's list of maintainers to reflect today's reality
    
    gdb/ChangeLog:
    
           * MAINTAINERS: Update list of maintainers, moving those who
           stepped down or became inactive to the "Past Maintainers"
           section.

commit 92f402a7e03f5d747bc9a09c8da2f61cc539ac33
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Dec 1 04:01:11 2017 -0800

    x86: Print dynreloc in readonly section for map file output
    
    This fixed:
    
    FAIL: DT_TEXTREL map file warning
    
    on Linux/x86.
    
    	* elfxx-x86.c (_bfd_x86_elf_readonly_dynrelocs): Print dynamic
    	relocation in readonly section for map file output.

commit 1cc75e929ff4e99b3bef4ca0e93250d5b1b126c9
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Dec 1 11:34:14 2017 +0000

    Replace mail address with the URL in copyright header
    
    The copyright header in most of GDB files were changed from mail address
    to the URL in the conversion to GPLv3 in Aug 2007.  However, some files
    still use mail address instead of the URL.  This patch fixes them.
    
    gdb/testsuite:
    
    2017-12-01  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.arch/aarch64-atomic-inst.exp: Replace mail address with
    	the URL in copyright header.
    	* gdb.arch/aarch64-fp.exp: Likewise.
    	* gdb.arch/ppc64-atomic-inst.exp: Likewise.
    	* gdb.arch/ppc64-isa207-atomic-inst.exp: Likewise.
    	* gdb.base/expand-psymtabs.exp: Likewise.
    	* gdb.cp/expand-psymtabs-cxx.exp: Likewise.
    	* gdb.fortran/common-block.exp: Likewise.
    	* gdb.fortran/common-block.f90: Likewise.
    	* gdb.fortran/logical.exp: Likewise.
    	* gdb.fortran/vla-datatypes.f90: Likewise.
    	* gdb.fortran/vla-sub.f90: Likewise.

commit 7b2d20948528f94b405af3e951931758e92e8e4d
Author: Tobias Ulmer <tobiasu@tmux.org>
Date:   Fri Dec 1 19:25:19 2017 +1030

    Check return value of bfd_new_link_order
    
    	* ldwrite.c (build_link_order): Check return value of all
    	bfd_new_link_order calls.

commit 0fbdde942914bd9834860b65f2943577be1e46e5
Author: Oleksandr Pikozh <o.pikozh@gmail.com>
Date:   Fri Dec 1 17:40:55 2017 +1030

    Add --strip-unneeded to objcopy synopsis
    
    	* doc/binutils.texi: Add --strip-unneeded to objcopy synopsis.

commit 40363a913b8c1292af97b4f50a0b2c5e6fdd04cb
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Dec 1 13:38:01 2017 +1030

    weak alias test
    
    This adds the test I was using when testing 60d67dc8.
    
    	* testsuite/ld-elfweak/alias.c,
    	* testsuite/ld-elfweak/alias.dat,
    	* testsuite/ld-elfweak/aliasmain.c,
    	* testsuite/ld-elfweak/weakref1.c,
    	* testsuite/ld-elfweak/weakref2.c: New test.
    	* testsuite/ld-elfweak/elfweak.exp: Run it.  Don't return on fails,
    	attempt other tests.

commit 63c1f59d665542359de4737e3e48033c588f44dc
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Nov 30 19:46:17 2017 +1030

    readonly_dynrelocs
    
    In early October, HJ Lu added support for a number of targets to "Dump
    dynamic relocation in read-only section with minfo".  This extends
    that support to more targets, displays the symbol involved, and splits
    the existing function that sets TEXTREL into a "readonly_dynrelocs"
    and "maybe_set_textrel" function.  I'll need "readonly_dynrelocs" if I
    ever get around to fixing "pr22374 function pointer initialization"
    fails.
    
    am33_2.0, arc, bfin, hppa64, mn10300, and nios2 fail to mark a binary
    needing text relocations with DT_TEXTREL.  That's not good.  xtensa also
    fails to do so but complains about "dangerous relocation: dynamic
    relocation in read-only section" so I reckon that is fine and have
    marked the test as an xfail.  The other targets need maintainer
    attention.
    
    Curiously, the map file dump wasn't added for x86, so the map test
    currently fail on x86.  It also fails on alpha, am33_2.0, arc, bfin,
    hppa64, ia64, m68k, mips, mn10300, nios2, score and vax.  cris
    complains with "tmpdir/textrel.o, section .rodata: relocation
    R_CRIS_32 should not be used in a shared object; recompile with -fPIC"
    so I've marked it as an xfail.
    
    bfd/
    	* elf32-hppa.c (maybe_set_textrel): Print symbol for map file output.
    	* elf32-ppc.c (maybe_set_textrel): Likewise.
    	* elf64-ppc.c (maybe_set_textrel): Likewise.
    	* elf32-arm.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing..
    	(elf32_arm_readonly_dynrelocs): ..this.
    	* elf32-lm32.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-m32r.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-metag.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-nds32.c: Delete unnecessary forward declarations.
    	(readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-or1k.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-s390.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-sh.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf32-tic6x.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing..
    	(elf32_tic6x_readonly_dynrelocs): ..this.
    	* elf32-tilepro.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elf64-s390.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elfnn-aarch64.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing..
    	(aarch64_readonly_readonly_dynrelocs): ..this.
    	* elfnn-riscv.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elfxx-sparc.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    	* elfxx-tilegx.c (readonly_dynrelocs): New function.
    	(maybe_set_textrel): New function, replacing old version of..
    	(readonly_dynrelocs): ..this.
    ld/
    	* testsuite/ld-elf/shared.exp: Run new textrel tests.
    	* testsuite/ld-elf/textrel.map: New file.
    	* testsuite/ld-elf/textrel.rd: New file.
    	* testsuite/ld-elf/textrel.s: New file.
    	* testsuite/ld-elf/textrel.warn: New file.

commit 254cefe35f012977d567af0bbad2a8091d90e22b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Dec 1 00:00:33 2017 +0000

    Automatic date update in version.in

commit 875fb7a785e78fddef6da270636e8f4efbfd3e0d
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Nov 30 18:41:55 2017 -0500

    New gdb.ada/repeat_dyn testcase.
    
    This patch introduces a testcase that exercises a scenario
    which used to trigger an internal-error, but no longer does:
    
    Consider the following array:
    
       type Small is new Integer range Ident (1) .. Ident (10);
       type Table is array (1 .. 3) of Small;
       A1 : Table := (3, 5, 8);
    
    The particularity of this array is that the type of each element
    is a range type whose bounds are dynamic, since they depend on
    the value returned by Ident (1) and Ident (10). Trying to apply
    the repeat operator ('@') on one of its elements used to yield
    an internal error:
    
        (gdb) p a1(1)@3
        $1 =
        /[...]/gdbtypes.c:4512: internal-error:
        copy_type: Assertion `TYPE_OBJFILE_OWNED (type)' failed.
    
    Although the issue no longer appears, the testcase is still
    interesting to have.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/repeat_dyn: New testcase.
    
    Tested on x86_64-linux with clean results.

commit fd6798fa2d6f0374d45449c4212869da93623b1e
Author: Peter Smith <peter.smith@linaro.org>
Date:   Thu Nov 30 15:07:26 2017 -0800

    Fix internal error in fix_errata on aarch64.
    
    The addresses of erratum stubs can be changed by relaxation passes, and
    need to be updated.
    
    gold/
    	PR gold/20765
    	* aarch64.cc (Aarch64_relobj::update_erratum_address): New method.
    	(AArch64_relobj::scan_errata): Update addresses in stub table after
    	relaxation pass.

commit e0feb133429709603eeeb382c1ebb6edd0a886aa
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Thu Nov 30 13:44:28 2017 -0800

    Fix problem where erratum stubs are not always applied.
    
    I checked over the results of applying --fix-cortex-a53-843419 to
    a very large program (gitit) with two stub tables and thousands
    of erratum fixes. I noticed that all the erratum_stubs were being
    created but about 1/3 of them were being skipped over by
    fix_errata_and_relocate_erratum_stubs(). By skipped over I mean
    no branch relocation or adrp -> adr transformation was applied to
    the erratum address, leaving the erratum_stub unreachable, and
    with a branch with a 0 immediate.
    
    The root cause of the skipped over erratum_stubs is
    Erratum_stub::invalidate_erratum_stub() that is used to set
    relobj_ to NULL when an erratum_stub has been processed.
    Unfortunately relobj_ is used in operator<() so altering relobj
    makes the results from erratum_stubs_.lower_bound() as used in
    find_erratum_stubs_for_input_section() unreliable.
    
    2017-11-30  Peter Smith  <peter.smith@linaro.org>
    	    Cary Coutant  <ccoutant@gmail.com>
    
    gold/
    	PR gold/20765
    	* aarch64.cc (Erratum_stub::invalidate_erratum_stub): Use erratum_insn_
    	instead of relobj_ to invalidate the stub.
    	(Erratum_stub::is_invalidated_erratum_stub): Likewise.

commit 036aae79303c43c56b604bc215ce4a70fc2a6474
Author: Peter Smith <peter.smith@linaro.org>
Date:   Thu Nov 30 13:30:58 2017 -0800

    Fix segfault in relocate_erratum_stub on aarch64.
    
    The fix for PR21868 (an internal error when --fix-cortex-a53-843419
    is applied) has a small mistake in it. When the stub_owner section
    needs an erratum fix an incorrect address for the stubs for the section
    is given to relocate_erratum_stub. If we are lucky we will get a segfault;
    if we aren't, an incorrect patch or data corruption is possible.
    The error is visible in PR21868, but the side-effects aren't fatal.
    
    gold/
    	PR gold/22233
    	* aarch64.cc (AArch64_relobj::fix_errata_and_relocate_erratum_stubs):
    	Fix calculation of stub address.

commit 4a7e52349807017f9bc09ea25f07924f2ec971b3
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Dec 1 07:53:16 2017 +1030

    PR22533, dynamic relocs generated for weak aliases
    
    This cleans up yet more craziness with non_got_ref.
    
    	PR 22533
    	* elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Don't do anything
    	special with non_got_ref for weak aliases.
    	(elf32_hppa_check_relocs): Tweak setting of non_got_ref.
    	(elf32_hppa_adjust_dynamic_symbol): When initialising weak aliases,
    	don't uselessly copy non_got_ref.  Clear dyn_relocs instead if
    	strong symbol is allocated in dynbss.  Tidy comments.
    	(elf32_hppa_relocate_section): Comment fix.
    	* elf32-ppc.c (ppc_elf_copy_indirect_symbol): Don't do anything
    	special with non_got_ref for weak aliases.
    	(ppc_elf_adjust_dynamic_symbol): When initialising weak aliases,
    	don't uselessly copy non_got_ref.  Clear dyn_relocs instead if
    	strong symbol is allocated in dynbss.  Tidy comments.
    	* elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't do anything
    	special with non_got_ref for weak aliases.
    	(ppc64_elf_adjust_dynamic_symbol): When initialising weak aliases,
    	don't uselessly copy non_got_ref.  Clear dyn_relocs instead if
    	strong symbol is allocated in dynbss.  Tidy comments.

commit 6f14765f9f448bbe03750634eb42c4a9db6521b8
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Thu Nov 30 18:35:54 2017 +0100

    [spu] Some additional test fixes
    
    Now that the ppc64 breakpoint regression is fixed, running the
    gdb.cell test suite showed a few more test case problems, caused
    by tests that haven't been updated to adapt to GDB changes.
    
    gdb/testsuite/ChangeLog:
    2017-11-30  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.cell/gcore.exp: Fix typo when setting spu_bin.
    	Update for changed thread numbering.
    	* gdb.cell/bt.exp: Update for changed GDB output.

commit 65cb033f43e1f5fa177a977b0bb29cd72877294d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Nov 30 09:11:48 2017 -0800

    Remove binutils-pr22471.patch
    
    It has been checked into master branch.

commit ae89804592a1d9c23e5beca8ee0332175be148de
Merge: 7387a9d f1af7b9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Nov 30 09:10:35 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit f1af7b94c16029f2c6da9eae4076f64cd9383687
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Nov 30 11:39:31 2017 -0500

    Use boards/local-board.exp more
    
    local-board.exp was introduced recently, containing the code required to
    force the gdbserver boards to be non-remote (from the DejaGNU point of
    view).  Other board files use the same trick of forcing isremote to 0.
    Instead of doing it by hand in each file, include local-board.exp.
    
    gdb/testsuite/ChangeLog:
    
    	* boards/cc-with-tweaks.exp: Include local-board.exp instead of
    	setting isremote by hand.
    	* boards/dwarf4-gdb-index.exp: Likewise.
    	* boards/fission.exp: Likewise.
    	* boards/stabs.exp: Likewise.

commit e3919f3e898aa5ab9a98dcaf9e242a9ebacc0757
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 30 16:32:10 2017 +0000

    Fix gdb.linespec/cpls-ops.exp on 32-bit
    
    gdb.linespec/cpls-ops.exp is currently failing on x86-64 -m32 and other
    32-bit ports:
    
     b test_op_new::operator new(unsigned int) FAIL: gdb.linespec/cpls-ops.exp: operator-new: tab complete "b test_op_new::operator" (timeout)
     ^CQuit
     (gdb) complete b test_op_new::operator
     b test_op_new::operator new(unsigned int)
     (gdb) FAIL: gdb.linespec/cpls-ops.exp: operator-new: cmd complete "b test_op_new::operator"
    
    The problem is simply that the testcase incorrectly assumes that
    size_t is "unsigned long".
    
    Fix this by extracting the right type with the "ptype" command.
    
    gdb/testsuite/ChangeLog:
    2017-11-30  Pedro Alves  <palves@redhat.com>
    
    	* gdb.linespec/cpls-ops.exp
    	(check_explicit_skips_function_argument): Extract the underlying
    	type of size_t instead of hardcoding it.

commit 44122162aefcbabb2fbe5b531412d157da5e59fc
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date:   Thu Nov 30 16:05:30 2017 +0100

    Remove ioctl-based procfs support on Solaris
    
    This is the previously mentioned patch to get rid of
    unstructured/ioctl-based procfs support in procfs.c.  Given that support
    for structured procfs was introduced in Solaris 2.6 back in 1997 and
    we're just removing support for Solaris < 10, there's no point in
    carrying that baggage (and tons of support for IRIX and OSF/1 as well)
    around any longer.
    
    Most of the patch should be straightforward (removing support for
    !NEW_PROC_API, non-Solaris OSes and pre-Solaris 10 quirks).
    
    Only a few points need explanations:
    
    * <sys/syscall.h> was already included unconditionally in most places,
      so there's no need to have guards in a few remaining ones.
    
    * configure.host already obsoletes i?86-*-sysv4.2, i?86-*-sysv5, so
      NEW_PROC_API detection for those in configure.ac can go.
    
    * I'm still including <sys/procfs.h> with #define _STRUCTURED_PROC 1.
      Theoretically, it would be better to include <procfs.h> on Solaris
      (which includes that define), but that breaks the build over
      <procfs.h> vs. gdb's "procfs.h", and doesn't exist on Linux.
    
    * I've regenerated syscall_table[] in proc-events.c with a small script
      from Solaris 10, 11.3, 11.4 <sys/syscall.h>, so there should be no
      traces of older Solaris versions and other OSes left.
    
    * prsysent_t and DYNAMIC_SYSCALLS was only used for AIX 5, but AIX
      doesn't use procfs.c any longer, so all related code can go.
    
    The patch was generated with diff -w so one can easier see changes
    without being distracted by simple reindentations.
    
    So far, it has only been compiled and smoke-tested on
    amd64-pc-solaris2.1[01], sparcv9-sun-solaris2.1[01], and
    x86_64-pc-linux-gnu.  Certainly needs more testing (Solaris 11.3
    vs. 11.4, 32-bit gdb, testsuite once I've figured out what's wrong on
    Solaris 10 etc.), but it's enough to get a first impression how much
    cleanup is possible here.
    
    	* configure.ac Don't check for sys/fault.h, sys/syscall.h,
    	sys/proc.h.
    	(NEW_PROC_API): Remove.
    	(prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
    	Likewise.
    	* common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
    	* configure: Regenerate.
    	* config.in: Regenerate.
    	* gdbserver/configure: Regenerate.
    	* gdbserver/config.in: Regenerate.
    
    	* i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
    	NEW_PROC_API test.
    	* sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
    
    	* linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
    
    	* proc-api.c: Remove !NEW_PROC_API support.
    	Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
    	Remove tests for macros always defined on Solaris.
    	* proc-events.c: Remove !NEW_PROC_API support.
    	Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
    	HAVE_SYS_USER_H tests.
    	(init_syscall_table): Remove non-Solaris syscalls.
    	Remove tests for syscalls present on all Solaris versions.
    	Add missing Solaris 10+ syscalls.
    	(signal_table): Remove non-Solaris signals.
    	Remove tests for signals present on all Solaris versions.
    	(fault_table): Remove non-Solaris faults.
    	Remove tests for faults present on all Solaris versions.
    	* proc-flags.c: Remove !NEW_PROC_API support.
    	(pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
    	Remove non-Solaris flags.
    	* proc-why.c: Remove !NEW_PROC_API support.
    	(pr_why_table): Remove meaningless comments.
    	Remove tests for reasons present on all Solaris versions.
    	Remove OSF/1 cases.
    	(proc_prettyfprint_why): Likewise.
    
    	* procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
    	Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
    	Remove WA_READ test, IRIX watchpoint support.
    	(gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
    	types.  Change users.
    	(gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
    	(gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
    	Change callers.
    	Remove CTL_PROC_NAME_FMT tests.
    	(gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types.  Change
    	users.
    	(sysset_t_size): Remove.  Use sizeof (sysset_t) in callers.
    	Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
    	(proc_modify_flag): Replace GDBRESET by PCUNSET.
    	Remove PR_ASYNC, PR_KLC tests.
    	(proc_unset_inherit_on_fork): Remove PR_ASYNC test.
    	(proc_parent_pid): Remove PCWATCH etc. tests.
    	(proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
    	Remove PCAGENT test.
    	(proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
    	Remove SYS_lwpcreate || SYS_lwp_create test.
    	(proc_get_current_thread): Likewise.
    	[PIOCNTHR && PIOCTLIST]: Remove.
    	[PIOCLSTATUS]: Remove.
    	(procfs_debug_inferior): Remove non-Solaris cases, conditionals.
    	[PRFS_STOPEXEC]: Remove.
    	(syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
    	(syscall_is_exit): Likewise.
    	(syscall_is_exec): Likewise.
    	(syscall_is_lwp_create): Likewise.
    	Remove SYS_syssgi support.
    	(procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
    	[SYS_syssgi]: Remove.
    	Remove non-Solaris cases, conditionals.
    	(unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
    	Remove.
    	(procfs_init_inferior) [SYS_syssgi]: Remove.
    	(procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
    	(procfs_inferior_created) [SYS_syssgi]: Remove.
    	(procfs_set_watchpoint): Remove !AIX5 test.
    	(procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
    	case.
    	(mappingflags) [MA_PHYS]: Remove.
    	(info_mappings_callback): Remove PCAGENT test.
    	Remove PIOCOPENLWP || PCAGENT test.

commit 7ac20022477c163983de77e5b16c016d518ca7bc
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 30 11:48:13 2017 +0100

    x86: derive DispN from BaseIndex
    
    BaseIndex implies - with the exception of string instructions the
    optional presence of a displacement. This is almost completely uniform
    for all instructions (the sole exception being MPX ones, which don't
    allow 16-bit addressing and hence Disp16), so there's no point in
    explicitly stating this in the main opcode table. Drop those explict
    specifications in favor of adding logic to i386-gen, shrinking the
    table size quite a bit and hence making it more readable.
    
    The opcodes/i386-tbl.h changes are due to a few cases where pointless
    Disp* still hadn't been removed from their insns.

commit b5014f7af26ff0fbc1128b5fabdaf3bd5918dd94
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 30 11:47:38 2017 +0100

    x86: drop Vec_Disp8
    
    This is fully redundant with Disp8MemShift being non-zero, and hence can
    be folded with normal Disp8 handling.

commit fd4e0347596acf79642625f4faad9e37c8fa0f0e
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 30 11:46:26 2017 +0100

    x86/Intel: issue diagnostics for redundant segment override prefixes
    
    While we shouldn't outright reject such (as was wrongly done by commit
    4d36230d59 ("x86: Update segment register check in Intel syntax"), as
    MASM accepts them even silently, issue (by default) a warning for such
    questionable constructs.

commit e21440ba622e17a2f12a858a87a6a75ef90654ca
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 30 11:44:27 2017 +0100

    Revert "x86: Update segment register check in Intel syntax"
    
    This reverts commit 4d36230d59903b92fbe2b53b31ed64a884860f0e.
    I was committed without maintainer ack and regresses intended
    functionality. A replacement will be committed shortly.

commit f425ec6600b69e39eb605f3128806ff688137ea8
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Nov 30 10:25:01 2017 +0000

    Prevent an illegal memory access in readelf when attempting to parse a corrupt ELF file.
    
    	PR 22510
    	* readelf.c (load_debug_section): Fail if there are no section
    	headers available.

commit e8020e54f4b9ac05150c4b02fa81e228d6cf1f6a
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date:   Thu Nov 30 10:57:04 2017 +0100

    Fix sol-thread.c compilation on Solaris
    
    Building current gdb mainline with gcc 7.1 on Solaris 11.4 fails:
    
    /vol/src/gnu/gdb/gdb/dist/gdb/sol-thread.c: In function `void _initialize_sol_thread()':
    /vol/src/gnu/gdb/gdb/dist/gdb/sol-thread.c:1229:66: error: invalid conversion from `void (*)(char*, int)' to `void (*)(const char*, int)' [-fpermissive]
         _("Show info on Solaris user threads."), &maintenanceinfolist);
                                                                      ^
    In file included from /vol/src/gnu/gdb/gdb/dist/gdb/completer.h:21:0,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/symtab.h:31,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/language.h:26,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/frame.h:72,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/gdbarch.h:39,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/defs.h:557,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/sol-thread.c:51:
    /vol/src/gnu/gdb/gdb/dist/gdb/command.h:140:33: note:   initializing argument 3 of `cmd_list_element* add_cmd(const char*, command_class, void (*)(const char*, int), const char*, cmd_list_element**)'
     extern struct cmd_list_element *add_cmd (const char *, enum command_class,
                                     ^~~~~~~
    
    The following patch allows compilation to succeed on i386-pc-solaris2.11
    and sparc-sun-solaris2.11.
    
    	* sol-thread.c (info_solthreads): Constify args.
    	Cast args to void *.

commit 668247656d5dec815a57761e98720dda09f72481
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Nov 30 13:10:35 2017 +1030

    Fix testcase for PR ld/22471
    
    ASFLAGS should be restored after any modification.  Fixes
    metag-linux  +FAIL: Long branch stub
    metag-linux  +FAIL: Long branch stub (PIC, app)
    mn10300-elf  +FAIL: difference of two same-section symbols where the difference is held in another section
    mn10300-elf  +FAIL: relaxation and alignment directives
    
    	PR 22471
    	* testsuite/ld-elf/shared.exp: Save and restore ASFLAGS.

commit 7505954411a168f5c5b9adec23eac55b1532fbe6
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Nov 29 16:28:01 2017 -0800

    Define MPFR_USE_INTMAX_T so that mpfr.h assumes intmax_t is available.
    
    mpfr.h uses a non-portable test to guess if intmax_t is available and
    if API functions using intmax_t should be exposed.  Define
    MPFR_USE_INTMAX_T to override the non-portable test and always expose
    these functions.  This fixes the build on platforms where the test
    guesses incorrectly.
    
    gdb/ChangeLog:
    
    	* target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.

commit 8029e59279e861071234decddf6a493119e0cb98
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 30 00:00:20 2017 +0000

    Automatic date update in version.in

commit f5a91472120952bbc40f277561626b8ccdf7b194
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Nov 29 18:31:18 2017 -0500

    preserve type length in ada-lang.c::to_fixed_range_type
    
    This patch fixes a potential issue which was noticed by code inspection:
    ada-lang.c::to_fixed_range_type uses gdbtypes.c::create_static_range_type
    to create most of the range type, which relies on create_range_type to
    do most of the work. The latter has the following piece of code which
    sets the length of the range type to match the length of the index_type:
    
        if (TYPE_STUB (index_type))
          TYPE_TARGET_STUB (result_type) = 1;
        else
          TYPE_LENGTH (result_type) = TYPE_LENGTH (check_typedef (index_type));
    
    In Ada, it is actually possible to have a range type whose size
    is smaller than its base type. For instance, with:
    
        type Unsigned2_T is  range 0 .. 2 ** 16 - 1;
        for Unsigned2_T'SIZE use 16;
    
    The compiler generates the following DWARF:
    
            .uleb128 0x3    # (DIE (0x4e) DW_TAG_subrange_type)
            .byte   0x2     # DW_AT_byte_size
            .byte   0       # DW_AT_lower_bound
            .value  0xffff  # DW_AT_upper_bound
            .long   .LASF64 # DW_AT_name: "try__unsigned2_t___XDLU_0__65535"
            .long   0x616   # DW_AT_type
    
    ... which points to the following base type...
    
            .uleb128 0x1d   # (DIE (0x616) DW_TAG_base_type)
            .byte   0x4     # DW_AT_byte_size
            .byte   0x5     # DW_AT_encoding
            .long   .LASF57 # DW_AT_name: "try__Tunsigned2_tB"
                            # DW_AT_artificial
    
    ... which has a size of 4 bytes.
    
    With a type like this one, create_range_type returns a type whose
    size is 4 bytes, instead of 2, which is not what we we would normally
    expect.
    
    Currently, this function is only used to handle array index types,
    so the length of the type actually does not matter and there should
    not be any user-visible consequences of the current behavior. But
    it seems best to plug this latent bug now, rather than wait for it
    to surface....
    
    gdb/ChangeLog:
    
            * ada-lang.c (to_fixed_range_type): Make sure that the size
            of the range type being returned is the same as the size
            of the range type being fixed.
    
    Tested on x86_64-linux, no regression.

commit bd69330db86b2367aac8aac5915f1686451c9d5d
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 29 19:33:24 2017 +0000

    Breakpoints in symbols with ABI tags (PR c++/19436)
    
    Trying to set a breakpoint in a function with an ABI tag does not work
    currently.  E.g., debugging gdb itself, we see this with the
    "string_printf" function:
    
     (top-gdb) b string_print                               [TAB]
     (top-gdb) b string_printf[abi:cxx11](char const*, ...) [RET]
     No source file named string_printf[abi.
     Make breakpoint pending on future shared library load? (y or [n])
    
    Quoting doesn't help:
     (top-gdb) b 'string_printf[abi:cxx11]'(char const*, ...)
     malformed linespec error: unexpected string, "(char const*, ...)"
     (top-gdb) b 'string_printf[abi:cxx11](char const*, ...)'
     No source file named string_printf[abi.
     Make breakpoint pending on future shared library load? (y or [n]) n
    
    This patch fixes this, and takes it a bit further.
    
    The actual symbol name as demangled by libiberty's demangler is really
    
     string_printf[abi:cxx11](char const*, ...)
    
    however, this patch makes it possible to set the breakpoint with
    
     string_printf(char const*, ...)
    
    too.  I.e., ignoring the ABI tag.
    
    And to match, it teaches the completer to complete the symbol name
    without the ABI tag, i.e.,
    
      "string_pri<TAB>"  -> "string_printf(char const*, ...)"
    
    If however, you really want to break on a symbol with the tag, then
    you simply start writing the tag, and GDB will preserve it, like:
    
      "string_printf[a<TAB>"  -> "string_printf[abi:cxx11](char const*, ...)"
    
    Grows the gdb.linespec/ tests like this:
    
      -# of expected passes           8977
      +# of expected passes           9176
    
    gdb/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	PR c++/19436
    	* NEWS: Mention setting breakpoints on functions with C++ ABI
    	tags.
    	* completer.h (completion_match_for_lcd) <match,
    	mark_ignored_range>: New methods.
    	<finish>: Consider ignored ranges.
    	<clear>: Clear ignored ranges.
    	<m_ignored_ranges, m_finished_storage>: New fields.
    	* cp-support.c (cp_search_name_hash): Ignore ABI tags.
    	(cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
    	completion_match_for_lcd pointer to strncmp_iw_with_mode.
    	(test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
    	* language.c (default_symbol_name_matcher): Pass the
    	completion_match_for_lcd pointer to strncmp_iw_with_mode.
    	* linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
    	* utils.c (skip_abi_tag): New function.
    	(strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
    	Handle ABI tags.
    	* utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
    	parameter.
    
    gdb/testsuite/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	PR c++/19436
    	* gdb.linespec/cpls-abi-tag.cc: New file.
    	* gdb.linespec/cpls-abi-tag.exp: New file.
    
    gdb/doc/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	PR c++/19436
    	* gdb.texinfo (Debugging C Plus Plus): Document setting
    	breakpoints in functions with ABI tags.

commit a20714ff39f621961151d0c204e89062ab2107eb
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 29 19:33:23 2017 +0000

    Make "break foo" find "A::foo", A::B::foo", etc. [C++ and wild matching]
    
    This patch teaches GDB about setting breakpoints in all scopes
    (namespaces and classes) by default.
    
    Here's a contrived example:
    
      (gdb) b func<tab>
      (anonymous namespace)::A::function()            Bn::(anonymous namespace)::B::function()        function(int, int)
      (anonymous namespace)::B::function()            Bn::(anonymous namespace)::function()           gdb::(anonymous namespace)::A::function()
      (anonymous namespace)::B::function() const      Bn::(anonymous namespace)::function(int, int)   gdb::(anonymous namespace)::function()
      (anonymous namespace)::function()               Bn::B::func()                                   gdb::(anonymous namespace)::function(int, int)
      (anonymous namespace)::function(int, int)       Bn::B::function()                               gdb::A::func()
      A::func()                                       Bn::func()                                      gdb::A::function()
      A::function()                                   Bn::function()                                  gdb::func()
      B::func()                                       Bn::function(int, int)                          gdb::function()
      B::function()                                   Bn::function(long)                              gdb::function(int, int)
      B::function() const                             func()                                          gdb::function(long)
      B::function_const() const                       function()
      (gdb) b function
      Breakpoint 1 at 0x4005ce: function. (26 locations)
    
      (gdb) b B::function<tab>
      (anonymous namespace)::B::function()        B::function() const                         Bn::B::function()
      (anonymous namespace)::B::function() const  B::function_const() const
      B::function()                               Bn::(anonymous namespace)::B::function()
      (gdb) b B::function
      Breakpoint 1 at 0x40072c: B::function. (6 locations)
    
    To get back the original behavior of interpreting the function name as
    a fully-qualified name, you can use the new "-qualified" (or "-q")
    option/flag (added by this commit).  For example:
    
     (gdb) b B::function
     (anonymous namespace)::B::function()        B::function() const                         Bn::B::function()
     (anonymous namespace)::B::function() const  B::function_const() const
     B::function()                               Bn::(anonymous namespace)::B::function()
    
    vs:
    
     (gdb) b -qualified B::function
     B::function()              B::function() const        B::function_const() const
    
    I've chosen "-qualified" / "-q" because "-f" (for "full" or
    "fully-qualified") is already taken for "-function".
    
    Note: the "-qualified" option works with both linespecs and explicit
    locations.  I.e., these are equivalent:
    
     (gdb) b -q func
     (gdb) b -q -f func
    
    and so are these:
    
     (gdb) b -q filename.cc:func
     (gdb) b -q -s filename.cc -f func
     (gdb) b -s filename.cc -q -f func
     (gdb) b -s filename.cc -f func -q
    
    To better understand why I consider wild matching the better default,
    consider what happens when we get to the point when _all_ of GDB is
    wrapped under "namespace gdb {}".  I have a patch series that does
    that, and when I started debugging that GDB, I immediately became
    frustrated.  You'd have to write "b gdb::internal_error", "b
    gdb::foo", "b gdb::bar", etc. etc., which gets annoying pretty
    quickly.  OTOH, consider how this makes it very easy to set
    breakpoints in classes wrapped in anonymous namespaces.  You just
    don't think of them, GDB finds the symbols for you automatically.
    
    (At the Cauldron a couple months ago, several people told me that they
    run into a similar issue when debugging other C++ projects.  One
    example was when debugging LLVM, which puts all its code under the
    "llvm" namespace.)
    
    Implementation-wise, what the patch does is:
    
      - makes C++ symbol name hashing only consider the last component of
        a symbol name. (so that we can look up symbol names by
        last-component name only).
    
      - adds a C++ symbol name matcher for symbol_name_match_type::WILD,
        which ignores missing leading specifiers / components.
    
      - adjusts a few preexisting testsuite tests to use "-qualified" when
        they mean it.
    
      - adds new testsuite tests.
    
      - adds unit tests.
    
    Grows the gdb.linespec/ tests like this:
    
      -# of expected passes           7823
      +# of expected passes           8977
    
    gdb/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	* NEWS: Mention that breakpoints on C++ functions are now set on
    	on all namespaces/classes by default, and mention "break
    	-qualified".
    	* ax-gdb.c (agent_command_1): Adjust to pass a
    	symbol_name_match_type to new_linespec_location.
    	* breakpoint.c (parse_breakpoint_sals): Adjust to
    	get_linespec_location's return type change.
    	(strace_marker_create_sals_from_location): Adjust to pass a
    	symbol_name_match_type to new_linespec_location.
    	(strace_marker_decode_location): Adjust to get_linespec_location's
    	return type change.
    	(strace_command): Adjust to pass a symbol_name_match_type to
    	new_linespec_location.
    	(LOCATION_HELP_STRING): Add paragraph about wildmatching, and
    	mention "-qualified".
    	* c-lang.c (cplus_language_defn): Install cp_search_name_hash.
    	* completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
    	enumerator.
    	(complete_address_and_linespec_locations): New parameter
    	'match_type'.  Pass it down.
    	(explicit_options): Add "-qualified".
    	(collect_explicit_location_matches): Pass the requested match type
    	to the linespec completers.  Handle MATCH_QUALIFIED.
    	(location_completer): Handle "-qualified" combined with linespecs.
    	* cp-support.c (cp_search_name_hash): New.
    	(cp_symbol_name_matches_1): Implement wild matching for C++.
    	(cp_fq_symbol_name_matches): Reimplement.
    	(cp_get_symbol_name_matcher): Return different matchers depending
    	on the lookup name's match type.
    	(selftests::test_cp_symbol_name_matches): Add wild matching tests.
    	* cp-support.h (cp_search_name_hash): New declaration.
    	* dwarf2read.c
    	(selftests::dw2_expand_symtabs_matching::test_symbols): Add
    	symbols.
    	(test_dw2_expand_symtabs_matching_symbol): Add wild matching
    	tests.
    	* guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
    	pass a symbol_name_match_type to new_linespec_location.
    	* linespec.c (linespec_parse_basic): Lookup function symbols using
    	the parser's symbol name match type.
    	(convert_explicit_location_to_linespec): New
    	symbol_name_match_type parameter.  Pass it down to
    	find_linespec_symbols.
    	(convert_explicit_location_to_sals): Pass the location's name
    	match type to convert_explicit_location_to_linespec.
    	(parse_linespec): New match_type parameter.  Save it in the
    	parser.
    	(linespec_parser_new): Default to symbol_name_match_type::WILD.
    	(linespec_complete_function): New symbol_name_match_type
    	parameter.  Use it.
    	(complete_linespec_component): Pass down the parser's recorded
    	name match type.
    	(linespec_complete_label): New symbol_name_match_type parameter.
    	Use it.
    	(linespec_complete): New symbol_name_match_type parameter.  Save
    	it in the parser and pass it down.  Adjust to
    	get_linespec_location's prototype change.
    	(find_function_symbols, find_linespec_symbols): New
    	symbol_name_match_type parameter.  Pass it down instead of
    	assuming symbol_name_match_type::WILD.
    	* linespec.h (linespec_complete, linespec_complete_function)
    	(linespec_complete_label): New symbol_name_match_type parameter.
    	* location.c (event_location::linespec_location): Now a struct
    	linespec_location.
    	(EL_LINESPEC): Adjust.
    	(initialize_explicit_location): Default to
    	symbol_name_match_type::WILD.
    	(new_linespec_location): New symbol_name_match_type parameter.
    	Record it in the location.
    	(get_linespec_location): Now returns a struct linespec_location.
    	(new_explicit_location): Also copy func_name_match_type.
    	(explicit_to_string_internal)
    	(string_to_explicit_location): Handle "-qualified".
    	(copy_event_location): Adjust to LINESPEC_LOCATION type change.
    	Copy symbol_name_match_type fields.
    	(event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
    	type change.
    	(event_location_to_string): Adjust to LINESPEC_LOCATION type
    	change.  Handle "-qualfied".
    	(string_to_explicit_location): Handle "-qualified".
    	(string_to_event_location_basic): New symbol_name_match_type
    	parameter.  Pass it down.
    	(string_to_event_location): Handle "-qualified".
    	* location.h (struct linespec_location): New.
    	(explicit_location::func_name_match_type): New field.
    	(new_linespec_location): Now returns a const linespec_location *.
    	(string_to_event_location_basic): New symbol_name_match_type
    	parameter.
    	(explicit_completion_info::saw_explicit_location_option): New
    	field.
    	* mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
    	symbol_name_match_type to new_linespec_location.
    	* python/py-breakpoint.c (bppy_init): Likewise.
    	* python/python.c (gdbpy_decode_line): Likewise.
    
    gdb/testsuite/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/langs.exp: Use -qualified.
    	* gdb.cp/meth-typedefs.exp: Use -qualified, and add tests without
    	it.
    	* gdb.cp/namespace.exp: Use -qualified.
    	* gdb.linespec/cpcompletion.exp (overload-2, fqn, fqn-2)
    	(overload-3, template-overload, template-ret-type, const-overload)
    	(const-overload-quoted, anon-ns, ambiguous-prefix): New
    	procedures.
    	(test_driver): Call them.
    	* gdb.cp/save-bp-qualified.cc: New.
    	* gdb.cp/save-bp-qualified.exp: New.
    	* gdb.linespec/explicit.exp: Test -qualified.
    	* lib/completion-support.exp (completion::explicit_opts_list): Add
    	"-qualified".
    	* lib/gdb.exp (gdb_breakpoint): Handle "qualified".
    
    gdb/doc/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	* gdb.texinfo (Linespec Locations): Document how "function" is
    	interpreted in C++ and Ada.  Document "-qualified".
    	(Explicit Locations): Document how "-function" is interpreted in
    	C++ and Ada.  Document "-qualified".

commit a207cff2da9f154e4f581b19dcde215593bfccf9
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 29 19:33:23 2017 +0000

    Handle custom completion match prefix / LCD
    
    A following patch will add support for wild matching for C++ symbols,
    making completing on "b push_ba" on a C++ program complete to
    std::vector<...>::push_back, std::string::push_back etc., like:
    
     (gdb) b push_ba[TAB]
     std::vector<...>::push_back(....)
     std::string<...>::push_back(....)
    
    Currently, we compute the "lowest common denominator" between all
    completion candidates (what the input line is adjusted to) as the
    common prefix of all matches.  That's problematic with wild matching
    as above, as then we'd end up with TAB changing the input line to
    "b std::", losing the original input, like:
    
     (gdb) b push_ba[TAB]
     std::vector<...>::push_back(....)
     std::string<...>::push_back(....)
     (gdb) b std::
    
    while obviously we'd want it to adjust itself to "b push_back(" instead:
    
     (gdb) b push_ba[TAB]
     std::vector<...>::push_back(....)
     std::string<...>::push_back(....)
     (gdb) b push_back(
    
    This patch adds the core code necessary to support this, though
    nothing really makes use of it yet in this patch.
    
    gdb/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_lookup_name_info::matches): Change type of
    	parameter from completion_match to completion_match_result.
    	Adjust.
    	(do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
    	* completer.c (completion_tracker::maybe_add_completion): Add
    	match_for_lcd parameter and use it.
    	(completion_tracker::add_completion): Likewise.
    	* completer.h (class completion_match_for_lcd): New class.
    	(completion_match_result::match_for_lcd): New field.
    	(completion_match_result::set_match): New method.
    	(completion_tracker): Add comments.
    	(completion_tracker::add_completion): Add match_for_lcd parameter.
    	(completion_tracker::reset_completion_match_result): Reset
    	match_for_lcd too.
    	(completion_tracker::maybe_add_completion): Add match_for_lcd
    	parameter.
    	(completion_tracker::m_lowest_common_denominator_unique): Extend
    	comments.
    	* cp-support.c (cp_symbol_name_matches_1)
    	(cp_fq_symbol_name_matches): Change type of parameter from
    	completion_match to completion_match_result.  Adjust.
    	* language.c (default_symbol_name_matcher): Change type of
    	parameter from completion_match to completion_match_result.
    	Adjust.
    	* language.h (completion_match_for_lcd): Forward declare.
    	(default_symbol_name_matcher): Change type of parameter from
    	completion_match to completion_match_result.
    	* symtab.c (compare_symbol_name): Adjust.
    	(completion_list_add_name): Pass the match_for_lcd to the tracker.
    	* symtab.h (ada_lookup_name_info::matches): Change type of
    	parameter from completion_match to completion_match_result.
    	(symbol_name_matcher_ftype): Likewise, and update comments.

commit 4024cf2b8d864279ff87af1a2ade77ab6d710d50
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 29 19:25:58 2017 +0000

    Fix setting-breakpoints regression on PPC64 (function descriptors)
    
    The recent-ish commit e5f25bc5d6db ('Fix "list ambiguous_variable"')
    caused a serious regression on PPC64.  See
    <https://sourceware.org/ml/gdb-patches/2017-11/msg00666.html>.
    
    Basically, after that patch, GDB sets breakpoints in function
    descriptors instead of where the descriptors point to, which is
    incorrect.
    
    The problem is that GDB now only runs a minsym's address through
    gdbarch_convert_from_func_ptr_addr if msymbol_is_text returns true.
    However, if the symbol points to a function descriptor,
    msymbol_is_text is false since function descriptors are in fact
    outside the text section.
    
    The fix is to also run a non-text address through
    gdbarch_convert_from_func_ptr_addr, and if that detects that it was
    indeed a function descriptor, treat the resulting address as a
    function.
    
    While implementing that directly in linespec.c:minsym_found (where the
    bad msymbol_is_text check is) fixes the issue, I noticed that
    linespec.c:add_minsym has some code that also basically needs to do
    the same checks, however it's implemented differently.  Also,
    add_minsym is calling find_pc_sect_line on non-function symbols, which
    also doesn't look right.
    
    So I introduced msymbol_is_function, so that we have a simple place to
    consider minsyms and function descriptors.
    
    And then, the only other use of msymbol_is_text is in
    find_function_alias_target, which turns out to also be incorrect.
    Changing that one to use msymbol_is_function, i.e., to consider
    function descriptors too fixes (on PPC64):
    
      -FAIL: gdb.base/symbol-alias.exp: p func_alias
      -FAIL: gdb.base/symbol-alias.exp: p *func_alias()
      +PASS: gdb.base/symbol-alias.exp: p func_alias
      +PASS: gdb.base/symbol-alias.exp: p *func_alias()
    
    And then after that, msymbol_is_text is no longer used anywhere, so it
    can be removed.
    
    Tested on x86_64 GNU/Linux, no regressions.  Tested on PPC64 GNU/Linux
    and results compared to a testrun of e5f25bc5d6db^ (before the
    offending commit), also no regressions.  (there's a couple new FAILs
    and some new symbol name matching unit tests are crashing, but that
    looks unrelated).
    
    gdb/ChangeLog:
    2017-11-29  Pedro Alves  <palves@redhat.com>
    
    	* linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
    	* minsyms.c (msymbol_is_text): Delete.
    	(msymbol_is_function): New function.
    	* minsyms.h (msymbol_is_text): Delete.
    	(msymbol_is_function): New declaration.
    	* symtab.c (find_function_alias_target): Use msymbol_is_function.

commit 5dcf52c19f7045fb179f703426d345b8a81d2210
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 29 09:27:40 2017 -0700

    Fix gdb snapshots
    
    Joel pointed out that gdb snapshots were broken by my Makefile patch
    series.  The bug is that rmdir in distclean was failing, because the
    directory did not exist.  This fixes the bug by only invoking rmdir when
    the directory exists.
    
    Tested using "src-release.sh gdb".
    
    2017-11-29  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (distclean): Handle the case where rmdir fails.

commit 6cf829987c6bc9ae61c7c9e8b4c71c4eea8ba2f9
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Nov 29 10:51:36 2017 -0800

    Give Palmer co-credit for last patch.

commit 36877bfb88f99dd0e4336f98233f7caaa1d594a7
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Nov 29 10:36:46 2017 -0800

    Fix riscv malloc error on small alignment after norvc.
    
    	gas/
    	* config/tc-riscv.c (riscv_frag_align_code): New local insn_alignment.
    	Early return if bytes less than or equal to insn_alignment.
    	* testsuite/gas/riscv/align-1.l: New.
    	* testsuite/gas/riscv/align-1.s: New.
    	* testsuite/gas/riscv/riscv.exp: Use run_dump_tests.  Use run_list_test
    	for align-1.

commit f923328821e2e835c725822bce2aac6e10c52dd9
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Nov 29 10:22:26 2017 -0800

    In x86 -n docs, mention that you need an explicit nop fill byte.
    
    	gas/
    	PR gas/22464
    	* doc/c-i386.texi (-n): Clarify docs.

commit f10e937a1cdcffcca748c226ed78d09369fc4cd0
Author: Renlin Li <renlin.li@arm.com>
Date:   Wed Nov 29 16:00:47 2017 +0000

    [GAS][AARCH64]Fix a typo for IP1 register alias.
    
    This should be an obvious fix.
    It corrects the register number for IP1 to 17.
    
    gas/
    
    2017-11-29  Renlin Li  <renlin.li@arm.com>
    
    	* config/tc-aarch64.c (reg_names): Fix IP1 register alias error.
    	* testsuite/gas/aarch64/register_aliases.s: Add IP0 and IP1 tests.
    	* testsuite/gas/aarch64/register_aliases.d: Update.

commit 4581a1c7d304ce14e714b27522ebf3d0188d6543
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 29 17:12:12 2017 +0000

    Check for a NULL symbol pointer when reading relocs from a COFF based file.
    
    	PR 22509
    	* coffcode.h (coff_slurp_reloc_table): Check for a NULL symbol
    	pointer when processing relocs.

commit f6f1d339d4169a60362f1438221bd03f8f021f04
Author: Phil Muldoon <pmuldoon@redhat.com>
Date:   Wed Nov 29 16:48:32 2017 +0000

    Fix Python rbreak tests setting too many breakpoints when glibc debug info is installed.
    
    2017-11-29  Phil Muldoon  <pmuldoon@redhat.com>
    
    	* gdb.python/py-rbreak.exp: Set nosharedlibrary before tests.

commit 8ca2f0b9ac024db56ca40f2b37c0b6b2bfcd139b
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 21 20:01:40 2017 -0600

    Update usage text for add-symbol-file, symbol-file, and load
    
    This updates the usage text for the add-symbol-file, symbol-file, and
    load commands.
    
    gdb/ChangeLog
    2017-11-29  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (_initialize_symfile): Update usage text for
    	add-symbol-file, symbol-file, load.

commit 02ca603a481d55e175765ab5bff30a04b86e905a
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 6 11:07:28 2017 -0600

    Fix add-symbol-file usage and errors
    
    This patch updates add-symbol-file help and error text.
    
    It changes add-symbol-file to throw an exception if "-s" is seen but
    not all of the arguments are given.  Previously this was silently
    ignored.
    
    It changes the unrecognized argument message to more clearly state
    what went wrong.
    
    Finally, it updates the usage line in the help text to follow GNU
    style regarding "metasyntactic variables"; a change I believe should
    be made to all gdb help messages.
    
    gdb/ChangeLog
    2017-11-29  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (add_symbol_file_command): Error if some arguments to
    	-s are missing.  Change unrecognized-argument error message.
    	(_initialize_symfile): Fix usage text for add-symbol-file.
    
    gdb/testsuite/ChangeLog
    2017-11-29  Tom Tromey  <tom@tromey.com>
    
    	* gdb.base/relocate.exp: Update invalid argument test.
    	Add new tests for invalid arguments.

commit ed6c0bfb2643861636581ac8775144efa1728c7c
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Wed Nov 29 13:40:59 2017 +0000

    [gdb/testsuite] Fix return type of psymtab-parameter
    
    As pointed out by Pedro Alves, psymtab-parameter testcase rely on the
    return type being long. This patch revert the changes made in
    f106e10e5e80265e1c43532bba4cb997a7dfa022 and change psymtab-parameter.cc
    to return 0 long instead.
    
    2017-11-29  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gdb/testsuite/
    	* gdb.cp/psymtab-parameter.cc (func): Change return type back to long.
    	Return 0 as a long.
    	* gdb.cp/psymtab-parameter.exp: Change func's return type back to long.

commit d785b7d4b877ed465d04072e17ca19d0f47d840f
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 29 12:40:43 2017 +0000

    Stop objdump from attempting to allocate a huge chunk of memory when parsing relocs in a corrupt file.
    
    	PR 22508
    	* objdump.c (dump_relocs_in_section): Also check the section's
    	relocation count to make sure that it is reasonable before
    	attempting to allocate space for the relocs.

commit 08f650e6b657e59959d7db8af100720721bd10a2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Nov 29 04:20:48 2017 -0800

    ld: Add a testcase for PR ld/22471
    
    	PR ld/22471
    	* testsuite/ld-elf/pr22471.t: New file.
    	* testsuite/ld-elf/pr22471a.s: Likewise.
    	* testsuite/ld-elf/pr22471b.s: Likewise.
    	* testsuite/ld-elf/shared.exp (ASFLAGS): Define UNDERSCORE for
    	underscore targets.
    	Run PR ld/22471 tests.

commit f106e10e5e80265e1c43532bba4cb997a7dfa022
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Wed Nov 29 10:45:31 2017 +0000

    [gdb/testsuite] Fix wrong return type in tests
    
    The following tests are marked untested with latest GCC due to a warning
    being emitted for a mismatch between their return type and what the lack
    of return statement:
    
    * gdb.cp/breakpoint.exp
    * gdb.cp/psymtab-parameter.exp
    * gdb.cp/shadow.exp
    
    This patch fix the return type to match the function definitions.
    
    2017-11-29  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gdb/testsuite/
    	* gdb.cp/breakpoint.cc (bar): Set return type to void.
    	* gdb.cp/psymtab-parameter.cc (func): Likewise.
    	* gdb.cp/psymtab-parameter.exp: Update comment regarding prototype of
    	func ().
    	* gdb.cp/shadow.cc (B.func): Return 0.

commit ca39c2f4dd0fedcaaee348be7a913f0c14876796
Author: Stefan Stroe <stroestefan@gmail.com>
Date:   Wed Nov 29 18:12:14 2017 +1030

    Support --localedir, --datarootdir and --datadir
    
    bfd/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    binutils/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    gas/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    gold/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    gprof/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    ld/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.
    opcodes/
    	* po/Make-in (datadir): Define as @datadir@.
    	(localedir): Define as @localedir@.
    	(gnulocaledir, gettextsrcdir): Use @datarootdir@.

commit ed9c7ee03780b8d5acf091091ded29cd40df8254
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 29 09:32:49 2017 +0000

    Use the record_alignment function when creating a .note section, in case the user has already created the section.
    
    	PR 22492
    	* config/obj-elf.c (obj_elf_version): Use record_alignment rather
    	than bfd_set_section_alignment.

commit 5dc824ed42cd173c1525f5abc76f4091f11a4dbc
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Tue Nov 28 18:48:12 2017 -0800

    Allow multiply-defined absolute symbols when they have the same value.
    
    gold/
    	* resolve.cc (Symbol_table::resolve): Allow multiply-defined absolute
    	symbols when they have the same value.

commit 8de0e07bf381f677bb93a8da72185a54e5b014bd
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Tue Nov 28 18:09:41 2017 -0800

    Allow multiple .eh_frame sections per object file.
    
    LLVM is experimenting with placing .eh_frame sections in the COMDAT group
    with the function's text. This triggers an internal error in gold because
    we don't expect to see but one .eh_frame section in an object, and we use
    a single data member in class Sized_relobj_file to keep track of that section.
    
    This patch removes that data member, and instead checks the output section
    and the input section offset to identify an optimized .eh_frame section.
    
    gold/
    	* object.h (class Sized_relobj_file): Remove discarded_eh_frame_shndx_.
    	* object.cc (Sized_relobj_file::Sized_relobj_file): Likewise.
    	(Sized_relobj_file::layout_eh_frame_section): Likewise.
    	(Sized_relobj_file::do_count_local_symbols): Check for optimized
    	.eh_frame section by other means.
    	(Sized_relobj_file::compute_final_local_value_internal): Likewise.

commit 144653ec15141907a3276b6181c4d1114f71be13
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Nov 29 00:00:23 2017 +0000

    Automatic date update in version.in

commit b0029dce6867de1a2828293177b0e030d2f0f03c
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Nov 28 18:00:29 2017 +0000

    Prevent a memory exhaustion problem when trying to read in strings from a COFF binary with a corrupt string table size.
    
    	PR 22507
    	* coffgen.c (_bfd_coff_read_string_table): Check for an excessive
    	size of the external string table.

commit 7387a9da1ff218e66aceb3f570b372a3a8c9a3d2
Merge: 26e7a7b ff174d3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 09:03:15 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit ff174d3ffad13af17a61583db3e1cd9c0c6cf237
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 09:00:44 2017 -0800

    gold: Add a newline at end of pr22266_a.c
    
    This patch fixes the build with GCC 4.2:
    
    gold/testsuite/pr22266_a.c:13:2: error: no newline at end of file
    
    	* testsuite/pr22266_a.c: Add a newline at end of file.

commit 26e7a7b2d33d4a5c5f82b1ef55213063a1f8558f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 08:21:38 2017 -0800

    Update binutils-secondary.patch against master

commit 0e6e17f057ce8c7393cdae87396e6cf1630a3ca3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 08:20:12 2017 -0800

    Remove binutils-pr22490.patch
    
    It has been checked into master branch.

commit 82ed9683ec099d8205dc499ac84febc975235af6
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 08:18:33 2017 -0800

    Properly handle note sections and segments
    
    When dumping notes, get note alignment from either note section or note
    segment.  To support notes generated by assemblers with
    
    https://sourceware.org/bugzilla/show_bug.cgi?id=22492
    
    we treate alignment as 4 bytes if it is less than 4.  Otherwise, we skip
    notes if alignment isn't 4 nor 8 bytes.
    
    We should call load_separate_debug_file only if e_shstrndx != SHN_UNDEF.
    
    	PR binutils/22490
    	* readelf.c (process_notes_at): Add an argument for note
    	alignment.  If note alignment is less than 4, use 4 byte
    	alignment.  Otherwise, skip notes if alignment isn't 4 nor
    	8 bytes.
    	(process_corefile_note_segments): Pass segment alignment to
    	process_notes_at.
    	(process_note_sections): Pass section alignment to
    	process_notes_at.
    	(process_object): Call load_separate_debug_file only if
    	e_shstrndx != SHN_UNDEF.

commit c55112850459764ef884cf3f5a4dffd83d781753
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 08:06:00 2017 -0800

    Update binutils-pr22490.patch against master
    
    Remove the PR gas/22492 fix which has been fixed on master branch.

commit 0d434e5d590fc03c1e36f3ccdb188d2070613fe3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 08:00:58 2017 -0800

    Update binutils-pr22471.patch against master
    
    Just add the testcase.

commit 979df8d592e881c61e38a43ad7cea1d4f1c46071
Merge: ef8cccf 6c6bc89
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 07:59:55 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit b23dc97fe237a1d9e850d7cbeee066183a00630b
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Nov 28 13:20:31 2017 +0000

    Fix a memory access violation when attempting to parse a corrupt COFF binary with a relocation that points beyond the end of the section to be relocated.
    
    	PR 22506
    	* reloc.c (reloc_offset_in_range): Rename to
    	bfd_reloc_offset_in_range and export.
    	(bfd_perform_relocation): Rename function invocation.
    	(bfd_install_relocation): Likewise.
    	(bfd_final_link_relocate): Likewise.
    	* bfd-in2.h: Regenerate.
    	* coff-arm.c (coff_arm_reloc): Use bfd_reloc_offset_in_range.
    	* coff-i386.c (coff_i386_reloc): Likewise.
    	* coff-i860.c (coff_i860_reloc): Likewise.
    	* coff-m68k.c (mk68kcoff_common_addend_special_fn): Likewise.
    	* coff-m88k.c (m88k_special_reloc): Likewise.
    	* coff-mips.c (mips_reflo_reloc): Likewise.
    	* coff-x86_64.c (coff_amd64_reloc): Likewise.

commit 6c6bc899302deb7c9b14f71da79c0fffc992204e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 04:54:35 2017 -0800

    ELF: Don't set non_ir_ref_regular in check_relocs
    
    Since elf_link_add_object_symbols sets non_ir_ref_regular now, there is
    no need to set non_ir_ref_regular in check_relocs.
    
    Tested on i686 and x86-64.
    
    	* elf-m10300.c (mn10300_elf_check_relocs): Don't set
    	non_ir_ref_regular.
    	* elf32-arm.c (elf32_arm_check_relocs): Likewise.
    	* elf32-bfin.c (bfin_check_relocs): Likewise.
    	* elf32-cr16.c (cr16_elf_check_relocs): Likewise.
    	* elf32-cris.c (cris_elf_check_relocs): Likewise.
    	* elf32-d10v.c (elf32_d10v_check_relocs): Likewise.
    	* elf32-dlx.c (elf32_dlx_check_relocs): Likewise.
    	* elf32-fr30.c (fr30_elf_check_relocs): Likewise.
    	* elf32-frv.c (elf32_frv_check_relocs): Likewise.
    	* elf32-hppa.c (elf32_hppa_check_relocs): Likewise.
    	* elf32-i370.c (i370_elf_check_relocs): Likewise.
    	* elf32-i386.c (elf_i386_check_relocs): Likewise.
    	* elf32-iq2000.c (iq2000_elf_check_relocs): Likewise.
    	* elf32-lm32.c (lm32_elf_check_relocs): Likewise.
    	* elf32-m32c.c (m32c_elf_check_relocs): Likewise.
    	* elf32-m32r.c (m32r_elf_check_relocs): Likewise.
    	* elf32-m68hc1x.c (elf32_m68hc11_check_relocs): Likewise.
    	* elf32-m68k.c (elf_m68k_check_relocs): Likewise.
    	* elf32-mcore.c (mcore_elf_check_relocs): Likewise.
    	* elf32-metag.c (elf_metag_check_relocs): Likewise.
    	* elf32-microblaze.c (microblaze_elf_check_relocs): Likewise.
    	* elf32-moxie.c (moxie_elf_check_relocs): Likewise.
    	* elf32-msp430.c (elf32_msp430_check_relocs): Likewise.
    	* elf32-mt.c (mt_elf_check_relocs): Likewise.
    	* elf32-nios2.c (nios2_elf32_check_relocs): Likewise.
    	* elf32-or1k.c (or1k_elf_check_relocs): Likewise.
    	* elf32-ppc.c (ppc_elf_check_relocs): Likewise.
    	* elf32-rl78.c (rl78_elf_check_relocs): Likewise.
    	* elf32-s390.c (elf_s390_check_relocs): Likewise.
    	* elf32-score.c (s3_bfd_score_elf_check_relocs): Likewise.
    	* elf32-score7.c (s7_bfd_score_elf_check_relocs): Likewise.
    	* elf32-sh.c (sh_elf_check_relocs): Likewise.
    	* elf32-tic6x.c (elf32_tic6x_check_relocs): Likewise.
    	* elf32-tilepro.c (tilepro_elf_check_relocs): Likewise.
    	* elf32-v850.c (v850_elf_check_relocs): Likewise.
    	* elf32-vax.c (elf_vax_check_relocs): Likewise.
    	* elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise.
    	* elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
    	* elf64-aarch64.c (elf64_aarch64_check_relocs): Likewise.
    	* elf64-alpha.c (elf64_alpha_check_relocs): Likewise.
    	* elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
    	* elf64-ia64-vms.c (elf64_ia64_check_relocs): Likewise.
    	* elf64-mmix.c (mmix_elf_check_relocs): Likewise.
    	* elf64-ppc.c (ppc64_elf_check_relocs): Likewise.
    	* elf64-s390.c (elf_s390_check_relocs): Likewise.
    	* elf64-sh64.c (sh_elf64_check_relocs): Likewise.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_check_relocs): Likewise.
    	* elfnn-ia64.c (elfNN_ia64_check_relocs): Likewise.
    	* elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
    	* elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
    	* elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
    	* elfxx-tilegx.c (tilegx_elf_check_relocs): Likewise.

commit 165f707ac88916aedecc96fa518be8879704d6da
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 27 13:40:43 2017 +1030

    PR22471, undefined reference to linker-defined symbols
    
    This patch processes linker script assignment statements before ld
    opens DT_NEEDED libraries, in order to define symbols like __bss_start
    that might also be defined by a library, falsely triggering an error
    about "DSO missing from command line".
    
    The initial value won't be correct when assigning a symbol from dot,
    and I make no attempt to handle all expressions.  For example, an
    assignment like "_start_foo = ADDR (.foo)" isn't valid until sections
    are laid out, so won't define _start_foo early.  What's here should be
    enough for most common scripts, and hopefully won't perturb fragile
    scripts.
    
    bfd/
    	PR 22471
    	* elflink.c (_bfd_elf_merge_symbol): Allow weak symbols to override
    	early passes over linker script symbols.
    	* linker.c (_bfd_generic_link_add_one_symbol): Allow symbols to
    	override early passes over linker script symbols.  Clear ldscript_def
    	on symbol definitions.
    ld/
    	PR 22471
    	* ldexp.c (struct definedness_hash_entry): Delete "by_script".  Make
    	"iteration" an 8-bit field, and update mask in all uses.
    	(definedness_newfunc): Don't init "by_script".
    	(update_definedness): Test ldscript_def rather than by_script.
    	(is_sym_value): Likewise.
    	(fold_name <DEFINED>): Return a result for first phase.  Test
    	ldscript_def.
    	(fold_name <NAME>): Return a result for first phase.
    	* ldlang.c (open_input_bfds): Process all assignments, not just
    	defsym.
    	(lang_process): Increment lang_statement_iteration before
    	open_input_bfds.
    	* testsuite/ld-mips-elf/tlsdyn-o32-1.d: Adjust for larger .dynsym.
    	* testsuite/ld-mips-elf/tlsdyn-o32-1.got: Likewise.
    	* testsuite/ld-mips-elf/tlsdyn-o32-2.d: Likewise.
    	* testsuite/ld-mips-elf/tlsdyn-o32-2.got: Likewise.
    	* testsuite/ld-mips-elf/tlsdyn-o32-3.d: Likewise.
    	* testsuite/ld-mips-elf/tlsdyn-o32-3.got: Likewise.

commit cd5b2babea487b0a71a14b593af98330efd8d73e
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 27 18:43:03 2017 +1030

    Copying symbol type in ld script assignments
    
    There is a call to update_definedness between code that evaluates an
    assignment expression value and code that transfers symbol
    attributes.  When script assignment expressions contain DEFINED, that
    can mean the wrong symbol type is copied.  This patch tracks symbols
    read during expression evaluation, rather than examining the
    expression and re-evaluating conditionals.  Not only does this
    simplify the code, it also means ld can now copy symbol types in more
    complex expressions.
    
    An unfortunate side effect of copying symbol type for more complex
    expressions affects mmix, which uses
     PROVIDE (Main = DEFINED (Main) ? Main : (DEFINED (_start) ? _start : _start.));
    in a default script.  So now _start or _start. symbol type may be
    copied, losing the function type specially set up for Main.  This can
    be avoided by making bfd_copy_link_hash_symbol_type do nothing for
    mmix.
    
    bfd/
    	* elf64-mmix.c (bfd_elf64_bfd_copy_link_hash_symbol_type): Define.
    ld/
    	* ldexp.h (struct ldexp_control): Add "assign_src".
    	* ldexp.c (fold_trinary): Save and restore assign_src around
    	condition evaluation.
    	(fold_name <NAME>): Set expld.assign_src.
    	(try_copy_symbol_type): Delete.
    	(exp_fold_tree_1): Set symbol type using expld.assign_src.

commit a83ef4d139c377e0e87d105977d85c6ef9fbb162
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 28 03:48:25 2017 -0800

    ld: Set non_ir_ref_regular on symbols referenced in regular objects
    
    If linker plugin is enabled, set non_ir_ref_regular on symbols referenced
    in regular objects so that linker plugin will get the correct symbol
    resolution.
    
    bfd/
    
    	PR ld/22502
    	* elflink.c (_bfd_elf_merge_symbol): Also skip definition from
    	an IR object.
    	(elf_link_add_object_symbols): If linker plugin is enabled, set
    	non_ir_ref_regular on symbols referenced in regular objects so
    	that linker plugin will get the correct symbol resolution.
    
    ld/
    
    	PR ld/22502
    	* testsuite/ld-plugin/lto.exp: Run PR ld/22502 test.
    	* testsuite/ld-plugin/pr22502a.c: New file.
    	* testsuite/ld-plugin/pr22502b.c: Likewise.

commit f0531ed6a429b0e6e6509e6852ccd3586f3fa1bd
Author: Jim Wilson <jimw@sifive.com>
Date:   Mon Nov 27 19:20:53 2017 -0800

    Compress loads/stores with implicit 0 offset.
    
    	gas/
    	* config/tc-riscv.c (riscv_handle_implicit_zero_offset): New.
    	(riscv_ip): Cases 'k', 'l', 'm', 'n', 'M', 'N', add call to
    	riscv_handle_implicit_zero_offset.  At label load_store, replace
    	existing code with call to riscv_handle_implicit_zero_offset.
    	* testsuite/gas/riscv/c-ld.d, testsuite/gas/riscv/c-ld.s: New.
    	* testsuite/gas/riscv/c-lw.d, testsuite/gas/riscv/c-lw.s: New.
    	* testsuite/gas/riscv/riscv.exp: Run new tests.

commit 033bfb739b525703bfe23f151d09e9beee3a2afe
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Mon Nov 27 17:32:55 2017 -0800

    Fix symbol values and relocation addends for relocatable links.
    
    The fix for PR 19291 broke some other cases where -r is used with scripts,
    as reported in PR 22266. The original fix for PR 22266 ended up breaking
    many cases for REL targets, where the addends are stored in the section data,
    and are not being adjusted properly.
    
    The problem was basically that in a relocatable output file (ET_REL),
    symbol values are supposed to be relative to the start address of their
    section. Usually in a relocatable file, all sections start at 0, so the
    failure to get this right is often irrelevant, but with a linker script,
    we occasionally see an output section whose starting address is not 0,
    and gold would occasionally write a symbol with its relocated value instead
    of its section-relative value.
    
    This patch reverts the recent fix for PR 22266 as well as my original fix
    for PR 19291. The original fix moved the symbol value adjustment to
    write_local_symbols, but neglected to undo a few places where the adjustment
    was also being applied, resulting in an occasional double adjustment. The
    more recent fix removed those other adjustments, but then failed to
    re-account for the adjustment when rewriting the relocations on REL targets.
    
    With the old attempts reverted, we now apply the symbol value adjustment to
    the one case that had been missed (non-section symbols in merge sections).
    But now we also need to account for the adjustment when rewriting the addends
    for RELA relocations.
    
    gold/
    	PR gold/19291
    	PR gold/22266
    	* object.cc (Sized_relobj_file::compute_final_local_value_internal):
    	Revert changes from 2017-11-08 patch.  Adjust symbol value in
    	relocatable links for non-section symbols.
    	(Sized_relobj_file::compute_final_local_value): Revert changes from
    	2017-11-08 patch.
    	(Sized_relobj_file::do_finalize_local_symbols): Likewise.
    	(Sized_relobj_file::write_local_symbols): Revert changes from
    	2015-11-25 patch.
    	* object.h (Sized_relobj_file::compute_final_local_value_internal):
    	Revert changes from 2017-11-08 patch.
    	* powerpc.cc (Target_powerpc::relocate_relocs): Adjust addend for
    	relocatable links.
    	* target-reloc.h (relocate_relocs): Adjust addend for relocatable links.
    	* testsuite/pr22266_a.c (hello): New function.
    	* testsuite/pr22266_main.c (main): Add test for merge sections.
    	* testsuite/pr22266_script.t: Add rule for .rodata.

commit 57c1b6811a2d97a3de229351ed19201853245a5d
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Nov 28 00:00:24 2017 +0000

    Automatic date update in version.in

commit 18ca73470a0d7eb96a807c97559cbb9fddb4b461
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 22 20:57:04 2017 -0700

    Remove REMOTE_OBS
    
    This removes REMOTE_OBS from the Makefile.  It is no longer needed, as
    remote support is always built into gdb.  The relevant sources are now
    added to COMMON_SFILES, where they are treated like other ordinary
    sources.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (REMOTE_OBS): Remove.
    	(SFILES): Remove remote sources.
    	(COMMON_SFILES): Add remote sources.
    	(ALLDEPFILES): Remove dcache.c.

commit 66599a7dc0369583229c0c51e5e009cfa7cceb73
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 14:29:59 2017 -0700

    Move target object files to target subdirectory
    
    Move the object files corresponding to target/*.c to the target
    subdirectory in the build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
    	variables.
    	(SFILES): Use SUBDIR_TARGET_SRCS.
    	(COMMON_OBS): Use SUBDIR_TARGET_OBS.  Remove waitstatus.o.
    	(CONFIG_SRC_SUBDIR): Add target.
    	(%.o): Remove target rule.

commit 4f04fba813785f3d749376d9b434c0f94f835dbc
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 14:24:29 2017 -0700

    Add missing files to COMMON_SFILES
    
    While working on the previous patch, I found a few .o files whose
    corresponding .c file was not mentioned in Makefile.in.  This patch
    fixes the problem.  I pulled this out separately to make it simpler to
    review.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
    	registry.o, thread-fsm.o, debug.o.
    	(COMMON_SFILES): Add filename-seen-cache.c, registry.c,
    	thread-fsm.c, debug.c.

commit b5adff3b5e14a45501f5761877d587019c94368a
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 14:19:27 2017 -0700

    Simplify COMMON_OBS by using list of sources
    
    This introduces a new COMMON_SFILES variable, and then defines some of
    COMMON_OBS in terms of this new variable.  This simpifies adding a new
    ordinary source file.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (COMMON_SFILES): New.
    	(SFILES): Move some entries to COMMON_SFILES.
    	(COMMON_OBS): Use COMMON_SFILES.

commit afa0a4115985939f242bcd54211c98345eefe16b
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 13:44:11 2017 -0700

    Define YYOBJ in terms of YYFILES
    
    Change YYOBJ to be defined in terms of YYFILES.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (YYFILES): Update comment.
    	(YYOBJ): Redefine.

commit 8fd8d003de32661ed703ae9fd7e1a856f1b58f81
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 13:17:31 2017 -0700

    Move python object files to python subdirectory
    
    Move the object files corresponding to python/*.c to the python
    subdirectory in the build tree.
    
    Because special CFLAGS are passed just to Python compilations, this
    patch also required the addition of a pattern rule to update
    INTERNAL_CFLAGS for here.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
    	(CONFIG_SRC_SUBDIR): Add python.
    	(%.o): Remove python rule.
    	(python/%.o): New rule.
    	* configure: Rebuild.
    	* configure.ac (CONFIG_OBS): Refer to python/python.o

commit bd810fff78006d38e3c287b7bd241319f4d763be
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 13:05:26 2017 -0700

    Move guile object files to guile subdirectory
    
    Move the object files corresponding to guile/*.c to the guile
    subdirectory in the build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* configure: Rebuild.
    	* configure.ac (CONFIG_OBS): Refer to guile/guile.o.
    	* Makefile.in (SUBDIR_GUILE_OBS): Redefine.
    	(CONFIG_SRC_SUBDIR): Add guile.
    	(%.o): Remove guile rule.

commit 75787ac19cdf7e8aa9b4c28f9421837ba479cf51
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:56:55 2017 -0700

    Move unittests object files to unittests subdirectory
    
    Move the object files corresponding to unittests/*.c to the unittests
    subdirectory in the build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
    	(%.o): Remove unittests rule.
    	(CONFIG_SRC_SUBDIR): Add unittests.

commit 5c8a943144f6972dc0854f2d01d7cb365b06fceb
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:42:33 2017 -0700

    Move tui object files to tui subdirectory
    
    Move the object files corresponding to tui/*.c to the tui subdirectory
    in the build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_TUI_OBS): Redefine.
    	(CONFIG_SRC_SUBDIR): Add tui.
    	(%.o): Remove tui rule.

commit a26aa30cc535c9bde457cdd00daf0c82f25da0af
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:35:05 2017 -0700

    Move compile object files to compile subdirectory
    
    Move the object files corresponding to compile/*.c to the compile
    subdirectory in the build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
    	(%.o): Remove compile rule.
    	(CONFIG_SRC_SUBDIR): Add compile.

commit 6f3cdf9a3bfa2c0a22fa9dc40b45578e2ea7957d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:26:11 2017 -0700

    Move mi objects to mi subdirectory
    
    Move object files corresponding to mi/*.c to a subdirectory in the
    build tree.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_MI_OBS): Redefine.
    	(%.o): Remove mi rule.
    	(CONFIG_SRC_SUBDIR): Add mi.
    	(COMMON_OBS): Use mi/mi-common.o

commit f06afa533665d88c651617de528b9640eb4e8611
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:22:11 2017 -0700

    Move cli object files to cli subdirectory
    
    Following the "arch" move, this moves the object files corresponding
    to the cli/*.c source files to the "cli" build directory.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (SUBDIR_CLI_OBS): Redefine.
    	(%.o): Remove cli rule.
    	(CONFIG_SRC_SUBDIR): Add cli.

commit b22c88c2ca013cc25d7a8fcbc748122bb1a349bb
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Nov 21 12:15:33 2017 -0700

    A simpler way to make the "arch" build directory
    
    This implements a simpler way to make the "arch" build directory --
    namely, now it is done as an order-only dependency in the Makefile,
    rather than being created when config.status is run.  This simpler
    because it means that the build directories can be changed without
    re-running autoconf.
    
    ChangeLog
    2017-11-27  Tom Tromey  <tom@tromey.com>
    
    	* configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
    	* configure: Rebuild.
    	* Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
    	(CONFIG_DEP_SUBDIR): New variable.
    	(%.o): Add order-only dependency.
    	($(CONFIG_DEP_SUBDIR)): New target.

commit 407e1140841f7fc337e90a7ba4482fb5a10c1701
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Mon Nov 20 06:35:06 2017 -0800

    gas: xtensa: speed up find_trampoline_seg
    
    find_trampoline_seg takes noticeable time when assembling source with
    many sections. Cache the result of the most recent search and check it
    first. No functional changes.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (find_trampoline_seg): Add static variable
    	that caches the result of the most recent search.

commit 148d6384291720bcaaa062badf1179b6215f6da3
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Tue Nov 14 15:16:08 2017 -0800

    gas: xtensa: implement trampoline coalescing
    
    There is a recurring pattern in assembly files generated by a compiler
    where a lot of jumps in a function are going to the same place. When
    these jumps are relaxed with trampolines the assembler generates a
    separate jump thread from each source.
    Create an index of trampoline jump targets for each segment and see if a
    jump being relaxed goes to a location from that index, in which case
    replace its target with a location of existing trampoline jump that
    results in the shortest path to the original target.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (trampoline_chain_entry, trampoline_chain)
    	(trampoline_chain_index): New structures.
    	(trampoline_index): Add chain_index field.
    	(xg_order_trampoline_chain_entry, xg_sort_trampoline_chain)
    	(xg_find_chain_entry, xg_get_best_chain_entry)
    	(xg_order_trampoline_chain, xg_get_trampoline_chain)
    	(xg_find_best_eq_target, xg_add_location_to_chain)
    	(xg_create_trampoline_chain, xg_get_single_symbol_slot): New
    	functions.
    	(xg_relax_fixups): Call xg_find_best_eq_target to adjust jump
    	target to point to an existing jump. Call
    	xg_create_trampoline_chain to create new jump target. Call
    	xg_add_location_to_chain to add newly created trampoline jump
    	to the corresponding chain.
    	(add_jump_to_trampoline): Extract loop searching for a single
    	slot with a symbol into a separate function, replace that code
    	with a call to that function.
    	(relax_frag_immed): Call xg_find_best_eq_target to adjust jump
    	target to point to an existing jump.
    	* testsuite/gas/xtensa/all.exp: Add trampoline-2 test.
    	* testsuite/gas/xtensa/trampoline.d: Adjust absolute addresses
    	as many duplicate trampoline chains are now coalesced.
    	* testsuite/gas/xtensa/trampoline.s: Add _nop so that objdump
    	stays in sync with instruction stream.
    	* testsuite/gas/xtensa/trampoline-2.l: New test result file.
    	* testsuite/gas/xtensa/trampoline-2.s: New test source file.

commit 76a493ab99d9276180db6e791f95d1d6d86d2954
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Mon Nov 13 00:42:43 2017 -0800

    gas: xtensa: reuse trampoline placement code
    
    There's almost exact copy of the trampoline placement code in the
    search_trampolines function that is used for jumps generated for relaxed
    branch instructions. Get rid of the duplication and reuse
    xg_find_best_trampoline function for that.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (search_trampolines, get_best_trampoline):
    	Remove definitions.
    	(xg_find_best_trampoline_for_tinsn): New function.
    	(relax_frag_immed): Replace call to get_best_trampoline with a
    	call to xg_find_best_trampoline_for_tinsn.
    	* testsuite/gas/xtensa/trampoline.d: Adjust absolute addresses
    	as the placement of trampolines for relaxed branches has been
    	changed.

commit fe6c2f1b6409867a03dd32214679dd825f74ec48
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Sat Nov 11 04:15:55 2017 -0800

    gas: xtensa: rewrite xg_relax_trampoline
    
    Replace linked list of trampoline frags with an ordered array, so that
    instead of indexing fixups trampolines could be indexed. Keep each array
    in the trampoline_seg structure, so there's no need to rebuild it for
    every new processed segment. Don't run relaxation for each trampoline
    frag, instead run it for each fixup in the current segment that needs
    relaxation at the beginning of each relaxation pass. This way the
    complexity of this process drops from about O(n^2 * m) to about
    O(log n * m), where n is the number of trampoline frags and m is the
    number of fixups that need relaxation in the segment.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (trampoline_index): New structure.
    	(trampoline_seg): Replace trampoline list with trampoline index.
    	(xg_find_trampoline, xg_add_trampoline_to_index)
    	(xg_remove_trampoline_from_index, xg_add_trampoline_to_seg)
    	(xg_is_trampoline_frag_full, xg_get_fulcrum)
    	(xg_find_best_trampoline, xg_relax_fixup, xg_relax_fixups)
    	(xg_is_relaxable_fixup): New functions.
    	(J_MARGIN): New macro.
    	(xtensa_create_trampoline_frag): Use xg_add_trampoline_to_seg
    	instead of open-coded addition to the linked list.
    	(dump_trampolines): Iterate through the trampoline_seg::index.
    	(cached_fixupS, cached_fixup, fixup_cacheS, fixup_cache)
    	(fixup_order, xtensa_make_cached_fixup)
    	(xtensa_realloc_fixup_cache, xtensa_cache_relaxable_fixups)
    	(xtensa_find_first_cached_fixup, xtensa_delete_cached_fixup)
    	(xtensa_add_cached_fixup, check_and_update_trampolines): Remove
    	definitions.
    	(xg_relax_trampoline): Extract logic into separate functions,
    	replace body with a call to xg_relax_fixups.
    	(search_trampolines): Replace search in linked list with search
    	in index. Change data type of address-tracking variables from
    	int to offsetT. Replace abs with labs.
    	(xg_append_jump): Finish the trampoline frag if it's full.
    	(add_jump_to_trampoline): Remove trampoline frag from the index
    	if the frag is full.
    	* config/tc-xtensa.h (xtensa_frag_type): Remove next_trampoline.
    	* testsuite/gas/xtensa/trampoline.d: Adjust absolute addresses
    	as the placement of trampolines has slightly changed.
    	* testsuite/gas/xtensa/trampoline.s: Add _nop so that objdump
    	stays in sync with instruction stream.

commit 46888d710015aa8d4bb3c2dac7aa6505d6ac8227
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Fri Nov 10 14:27:42 2017 -0800

    gas: xtensa: merge trampoline_frag into xtensa_frag_type
    
    The split between fragS and trampoline_frag doesn't save much space, but
    makes trampolines management much more awkward. Merge trampoline_frag
    data into the xtensa_frag_type, which is a part of fragS. No functional
    changes.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (init_trampoline_frag): Replace pointer to
    	struct trampoline_frag parameter with pointer to fragS.
    	(xg_append_jump): Remove jump_around parameter.
    	(struct trampoline_frag): Remove.
    	(struct trampoline_seg): Change type of trampoline_list from
    	struct trampoline_frag to fragS.
    	(xtensa_create_trampoline_frag): Don't allocate struct
    	trampoline_frag. Initialize new fragS::tc_frag_data fields.
    	(dump_trampolines, xg_relax_trampoline, search_trampolines)
    	(get_best_trampoline, init_trampoline_frag)
    	(add_jump_to_trampoline, relax_frag_immed): Replace pointer to
    	struct trampoline_frag with a pointer to fragS.
    	(xg_append_jump): Remove jump_around parameter, use
    	fragS::tc_frag_data.jump_around_fix instead.
    	(xg_relax_trampoline, init_trampoline_frag)
    	(add_jump_to_trampoline): Don't pass jump_around parameter to
    	xg_append_jump.
    	* config/tc-xtensa.h (struct xtensa_frag_type): Add new fields:
    	needs_jump_around, next_trampoline and jump_around_fix.

commit 1c2649f50f4e40c07840f45c4d237efcdd02e8e2
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Fri Nov 10 13:38:23 2017 -0800

    gas: xtensa: reuse find_trampoline_seg
    
    xtensa_create_trampoline_frag has opencoded fragment equivalent to
    find_trampoline_seg. Drop the fragment and use find_trampoline_seg
    instead. No functional changes.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (find_trampoline_seg): Move above the first
    	use.
    	(xtensa_create_trampoline_frag): Replace trampoline seg search
    	code with a call to find_trampoline_seg.

commit fec68fb168d580c188358347f3834072a8960ddc
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Thu Nov 9 14:51:18 2017 -0800

    gas: xtensa: extract jump assembling for trampolines
    
    init_trampoline_frag, add_jump_to_trampoline and xg_relax_trampoline add
    a jump to the end of a trampoline frag. Extract it into a separate
    funciton and use it in all these places. No functional changes.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (xg_append_jump): New function.
    	(xg_relax_trampoline, init_trampoline_frag)
    	(add_jump_to_trampoline): Replace trampoline jump assembling
    	code with a call to xg_append_jump.

commit 120bc8b8b91cba4a8d4092ea0fb3d76bcbe98712
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Fri Oct 20 16:23:28 2017 -0700

    gas: extract xg_relax_trampoline from xtensa_relax_frag
    
    To make measurement and changes easier extract trampoline relaxation
    function. No functional changes.
    
    gas/
    2017-11-27  Max Filippov  <jcmvbkbc@gmail.com>
    
    	* config/tc-xtensa.c (xg_relax_trampoline): New function.
    	(xtensa_relax_frag): Replace trampoline relaxation code with a
    	call to xg_relax_trampoline.

commit 10329bb27fa5531bf97da184c4d0ed9c4ed85605
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Mon Nov 27 11:38:54 2017 -0800

    fix two issues in gdb.ada/mi_catch_ex.exp (re: "exception-message")
    
    The following patch introduced a new feature related to Ada exception
    catchpoints:
    
        commit e547c119d043f2ecffb70452020ab9150d083a91
        Author: Joel Brobecker <brobecker@adacore.com>
        Date:   Fri Nov 24 17:09:42 2017 -0500
        Subject: (Ada) provide the exception message when hitting an exception catchpoint
    
    Unfortunately, the patch left 2 errors in gdb.ada/mi_catch_ex.exp,
    both inside the "continue_to_exception" function:
    
      1. The exception message on the console can include the exception
         message, and thus this patch adjust the expected output in
         the corresponding gdb_expect call to allow it;
         to allow it.
    
      2. There was a TCL syntax confusion in "$exception_name(..."
         that caused TCL to evaluate "exception_name as an array,
         rather than as a variable. This patch fixes this by escaping
         the '(' (and the corresponding closing parenthesis, for
         consistency).
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/mi_catch_ex.exp (continue_to_exception): Adjust
            expected output in gdb_expect call to allow the exception
            message to be present as well.  Fix syntax confusion to avoid
            TCL thinking that exception_name is an array.
    
    Tested on x86_64-linux, with:
    
        DejaGnu version  1.6
        Expect version   5.45
        Tcl version      8.6

commit 6dda7875a8021787f11bd95a69d81a079e408a57
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Wed Nov 15 17:40:04 2017 +0000

    [PR ld/22263] aarch64: Avoid dynamic TLS relocs in PIE
    
    No dynamic relocs are needed for TLS defined in an executable, the
    TP relative offset is known at link time.
    
    Fixes
    FAIL: Build pr22263-1
    
    bfd/
    	PR ld/22263
    	* elfnn-aarch64.c (elfNN_aarch64_relocate_section): Use
    	bfd_link_executable instead of bfd_link_pic for TLS.
    	(elfNN_aarch64_allocate_dynrelocs): Likewise.
    	(aarch64_can_relax_tls): Likewise.

commit a377ae2ad683d3c16ae74dba440ee441120a7d8a
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Wed Nov 15 15:56:30 2017 +0000

    [PR ld/22269] aarch64: Handle local undefined weak symbols
    
    With static pie linking undefined weak symbols are forced to resolve locally
    to 0, so no GOT setup is needed in elfNN_aarch64_finish_dynamic_symbol,
    which previously failed for these symbols.
    
    The failure caused the unhelpful error message:
    "ld: final link failed: Nonrepresentable section on output"
    
    bfd/
    	PR ld/22269
    	* elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Use
    	UNDEFWEAK_NO_DYNAMIC_RELOC to avoid dynamic GOT relocs.
    	(elfNN_aarch64_allocate_dynrelocs): Likewise.

commit 64973b0ac4c34e80821a56561ae1af15f7d6e809
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Nov 27 11:14:38 2017 +0000

    Update the simplified Chinese translation of the messages in the opcodes library.
    
    	* po/zh_CN.po: Updated simplified Chinese translation.

commit 4dff97b2ce94bbb9c0c16e0e4129060b9a894f13
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Nov 27 11:05:39 2017 +0000

    Fix a seg-fault when displaying notes from a prorgam segment.  Check for a NULL string section before attempting compute the name of a separate debug info file.
    
    	PR 22490
    	* readelf.c (dump_section_as_bytes): Check for a NULL string
    	section pointer.
    	(process_notes_at): Compute the alignment to use if displaying
    	notes from a segment.

commit e3d40582166056dd1dfeef2a06ba8f5897b673ee
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Nov 27 11:04:17 2017 +0000

    When creating a .note section to contain a version note, set the section alignment to 4 bytes.
    
    	PR 22492
    	* config/obj-elf.c (obj_elf_version): Set the alignment of the
    	.note section.

commit ee9a09e959a5b7c152cc72028d4f6c879bc901c9
Author: Dominik Czarnota <dominik.b.czarnota@gmail.com>
Date:   Sun Nov 26 22:42:18 2017 -0500

    Update find command help and search memory docs
    
    This patch updates the `find` command help and docs description to show
    how to search for not null terminated strings when current language's
    strings includes it.
    
    gdb/ChangeLog:
    
    	PR gdb/21945
    	* findcmd.c (_initialize_mem_search): Update find command help
    	text.
    
    gdb/doc/ChangeLog:
    
    	PR gdb/21945
    	* gdb.texinfo (Search Memory): Update description and example
    	about how to search a string without NULL terminator.

commit e8e7d10c39955e7ff99ff42f6f16d6befe2fa12e
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Nov 26 19:32:47 2017 -0500

    python: Fix memleak in do_start_initialization
    
    While playing with valgrind, I noticed that with Python 3, the progname
    variable in do_start_initialization is not being freed (concat returns a
    malloc'ed string).  This patch uses unique_xmalloc_ptr to manage it.
    With Python 2, we pass progname it directly to Py_SetProgramName, so it
    should not be freed.  We therefore release it before passing it.
    
    gdb/ChangeLog:
    
    	* python/python.c (do_start_initialization): Change progname
    	type to gdb::unique_xmalloc_ptr.  Release the pointer when using
    	Python 2.

commit 7db85adb3b988560d9d4706d826e193e83ae7cd9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Nov 27 00:00:27 2017 +0000

    Automatic date update in version.in

commit 6a997029fb0fca1a9e2832db80a3afb9bccaaf59
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 22 09:37:05 2017 -0700

    Add include guards to common/format.h
    
    This adds include guards to common/format.h.
    
    ChangeLog
    2017-11-26  Tom Tromey  <tom@tromey.com>
    
    	* common/format.h: Add include guards.

commit ef8cccf3589356b0de0f8eecec1c4ebe043e2bc8
Merge: 33a6ddb 2b63c33
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 10:20:08 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 2b63c337d99fe12220e6ca12a71dac6cdd3224d3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 10:12:35 2017 -0800

    Rename argument name from link to xlink
    
    This fixed the build with GCC 4.2:
    
    cc1: warnings being treated as errors
    binutils-gdb/binutils/dwarf.c: In function â??load_separate_debug_infoâ??:
    binutils-gdb/binutils/dwarf.c:9650: warning: declaration of â??linkâ?? shadows a global declaration
    /usr/include/unistd.h:757: warning: shadowed declaration is here
    
    	* dwarf.c (load_separate_debug_info): Rename argument name from
    	link to xlink.

commit 33a6ddbb909d894dc1214760d2a82e7eed41f26a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:58:27 2017 -0800

    Apply "Properly handle note sections and segments"

commit f3cadc4552be53f64cfd0a7c4400cb3fe471113b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:53:08 2017 -0800

    Apply "Don't check DT_NEEDED for symbols defined by linker script"

commit feaee4e8c541c9da3f9de7209c070613f4ad60dd
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:50:15 2017 -0800

    Apply "Gold: Update testsuite/debug_msg.sh for GCC 7"

commit 7f7dd7b0b4d28ba59571463c95ec2036c1fa9efb
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:47:13 2017 -0800

    Apply "Retry incremental_test_2 with --incremental-full"

commit d8e011383e53929b681781d6686561416e07ffe9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:43:56 2017 -0800

    Update binutils-secondary.patch against master

commit 441fcb29c21224c594096f249612052821eb6a13
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 09:42:44 2017 -0800

    Update binutils-pr12639.patch against master

commit 41272101db08e20f044dbf0f09b6d79a0fa6c1ac
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 22 09:30:21 2017 -0700

    Change maybe_disable_address_space_randomization to a class
    
    This changes maybe_disable_address_space_randomization to be an RAII
    class, rather than having it return a cleanup.
    
    Regression tested by the buildbot.
    
    ChangeLog
    2017-11-26  Tom Tromey  <tom@tromey.com>
    
    	* nat/linux-personality.h (class
    	maybe_disable_address_space_randomization): New class.
    	(maybe_disable_address_space_randomization): Don't declare
    	function.
    	* nat/linux-personality.c (restore_personality)
    	(make_disable_asr_cleanup): Remove.
    	(maybe_disable_address_space_randomization): Now a constructor.
    	(~maybe_disable_address_space_randomization): New destructor.
    	* linux-nat.c (linux_nat_create_inferior): Update.
    
    gdbserver/ChangeLog
    2017-11-26  Tom Tromey  <tom@tromey.com>
    
    	* linux-low.c (linux_create_inferior): Update.

commit 44287fd89091a833451e74c79e46404c23fdaf9b
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Nov 9 17:15:37 2017 -0700

    Removes a cleanup from gcore.c
    
    This removes a cleanup from gcore.c, replacing it with
    unique_xmalloc_ptr.
    
    Regression tested by the buildbot.
    
    ChangeLog
    2017-11-26  Tom Tromey  <tom@tromey.com>
    
    	* gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.

commit 338938e665ed8404ab6258b9b6452e5d2f6ff9b2
Merge: e87d096 8e2495f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 08:45:50 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 8e2495f2f75120baae14f9dac9d29b043c539b2b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 26 08:28:25 2017 -0800

    gas: Update x86 sse-noavx tests
    
    This fixed:
    
    FAIL: i386 SSE without AVX equivalent
    FAIL: x86-64 SSE without AVX equivalent
    FAIL: x86-64 (ILP32) SSE without AVX equivalent
    
    on x86-64.
    
    	* testsuite/gas/i386/sse-noavx.s: Add tests for fisttps and
    	fisttpl.
    	* testsuite/gas/i386/x86-64-sse-noavx.s: Likewise.
    	* testsuite/gas/i386/ilp32/x86-64-sse-noavx.d: Updated.
    	* testsuite/gas/i386/sse-noavx.d: Likewise.
    	* testsuite/gas/i386/x86-64-sse-noavx.d: Likewise.

commit 58f7f0bf542ff9b712ef1ed6a6e1a6da563b9054
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Sun Nov 26 17:29:00 2017 +0100

    Fix broken ChangeLog entry for last commit.

commit 617cd4bc366e47f92ecee3c3f9850a0fd2e6c6a9
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Sun Nov 26 17:19:57 2017 +0100

    [spu] Fix various test cases
    
    The SPU-specific test cases were not modified to use standard_output_file
    and therefore all were no longer being executed.  Fixing this exposed a
    few other bugs in spu-info noticed by using a more recent compiler, which
    are also fixed here.
    
    gdb/testsuite/ChangeLog:
    2017-11-26  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.arch/spu-info.c: Include <unistd.h>.
    	(do_signal_test): Fix broken calls to write.
    	* gdb.arch/spu-info.exp: Use prepare_for_testing.
    	Fix checks for empty mailboxes.  Update signal tests for corrected
    	do_signal_test routine.  Allow nonzero event status.

commit 5ffd2cb722440053267d0db52df8bbd278fd6d91
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Sun Nov 26 17:15:25 2017 +0100

    [spu] Fix single-stepping regression
    
    Switching spu_software_single_step to use a regcache instead of a frame:
    https://sourceware.org/ml/gdb-patches/2016-11/msg00355.html
    cause a serious regression to SPU single-stepping.
    
    There were two separate problems:
    - SPU_LSLR_REGNUM is a pseudo register, so we must use the "cooked"
      regcache methods instead of the "raw" ones to access it.
    - When accessing a branch target register, we must only use the first
      four bytes of the 16-byte vector register.  This was done automatically
      by the frame routines, but not by the regcache routines.
    
    gdb/ChangeLog:
    2017-11-26  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
    	"cooked" register.  Access only first four bytes of branch target
    	registers.

commit e5a8dd426de76af279cb6eff0c761ec866e97dc8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Nov 26 00:00:27 2017 +0000

    Automatic date update in version.in

commit 0e5457dca14e2e0474432566dc7a603db6c990f7
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sat Nov 25 10:57:58 2017 -0500

    Adding ChangeLog entry for the last commit.

commit 685de8c2990a04fba5e2954b7ff089a2c641071f
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sat Nov 25 01:13:03 2017 -0500

    Fix PR gdb/22491: Regression when setting SystemTap probe semaphores
    
    Pedro has kindly pointed out that
    gdb.arch/amd64-stap-optional-prefix.exp was failing after my
    C++-ification patches touching the probe interface.  The failure is
    kind of cryptic:
    
     77 break -pstap bar
     78 Breakpoint 3 at 0x40048d
     79 (gdb) PASS: gdb.arch/amd64-stap-optional-prefix.exp: bar: break -pstap bar
     80 continue
     81 Continuing.
     82
     83 Program received signal SIGILL, Illegal instruction.
     84 main () at amd64-stap-optional-prefix.S:26
     85 26              STAP_PROBE1(probe, foo, (%rsp))
    
    It took me a while to figure out where this SIGILL is coming from.
    Initially I thought it was something related to writing registers to
    the inferior when dealing with probe arguments, but I discarded this
    since the arguments were not touching any registers.
    
    In the end, this was a mistake that was introduced during the review
    process of the patch.  When setting/clearing a SystemTap probe's
    semaphore, the code was using 'm_address' (which refers the probe's
    address) instead of 'm_sem_addr' (which refers to the semaphore's
    address).  This caused GDB to write a bogus value in the wrong memory
    position, which in turn caused the SIGILL.
    
    I am pushing this patch to correct the mistake.
    
    On a side note: I told Pedro that the BuildBot hadn't caught the
    failure during my try build, and for a moment there was a suspicion
    that the BuildBot might be at fault here.  However, I investigate this
    and noticed that I only did one try build, with a patch that was
    correctly using 'm_sem_addr' where applicable, and therefore no
    failure should have happened indeed.  I probably should have requested
    another try build after addressing the review's comments, but they
    were mostly basic and I didn't think it was needed.  Oh, well.
    
    2017-11-25  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR gdb/22491
    	* stap-probe.c (relocate_address): New function.
    	(stap_probe::get_relocated_address): Use 'relocate_address'.
    	(stap_probe::set_semaphore): Use 'relocate_address' and pass
    	'm_sem_addr'.
    	(stap_probe::clear_semaphore): Likewise.

commit deeeba559bd0c18e06dba19f44571ee8a218fcdb
Author: Pedro Alves <palves@redhat.com>
Date:   Sat Nov 25 00:33:05 2017 +0000

    Use TOLOWER in SYMBOL_HASH_NEXT
    
    The support for setting breakpoint in functions with ABI tags patch
    will add a use of SYMBOL_HASH_NEXT in cp-support.c, which fails to
    compile with:
    
      src/gdb/cp-support.c:38:0:
      src/gdb/cp-support.c: In function â??unsigned int cp_search_name_hash(const char*)â??:
      src/gdb/../include/safe-ctype.h:148:20: error: â??do_not_use_tolower_with_safe_ctypeâ?? was not declared in this scope
       #define tolower(c) do_not_use_tolower_with_safe_ctype
    		      ^
      src/gdb/minsyms.h:174:18: note: in expansion of macro â??tolowerâ??
         ((hash) * 67 + tolower ((unsigned char) (c)) - 113)
    		    ^
      src/gdb/cp-support.c:1677:14: note: in expansion of macro â??SYMBOL_HASH_NEXTâ??
    	 hash = SYMBOL_HASH_NEXT (hash, *string);
    		^
    
    This fixes the problem before it happens.
    
    I was somewhat worried about whether this might have an impact with
    languages that are case insensitive, but I convinced myself that it
    doesn't.  As bonus, this improves GDB's minsym interning performance a
    bit (3%-10%).  See
    <https://sourceware.org/ml/gdb/2017-11/msg00021.html>.
    
    gdb/ChangeLog:
    2017-11-25  Pedro Alves  <palves@redhat.com>
    
    	* dictionary.c: Include "safe-ctype.h".
    	* minsyms.c: Include "safe-ctype.h".
    	* minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.

commit a81aaca0578ee91ce1cee56c0a31e26c2a5ef581
Author: Pedro Alves <palves@redhat.com>
Date:   Sat Nov 25 00:20:31 2017 +0000

    Fix completing an empty string
    
    Earlier while working on the big completer rework series, I managed to
    break
    
     (gdb) [TAB]
    
    locally, and make GDB crash, but only notice a few weeks down the
    road, because we have no test for that...
    
    I also noticed that:
    
     (gdb)     [TAB]
    
    didn't work (didn't show all commands as matches), even though
    entering a command with leading whitespace works:
    
     (gdb)     help
    
    This commit fixes the latter and adds a testcase that covers both
    issues.
    
    The gdb.base/completion.exp change is necessary because the new test
    has a file name that also starts with "gdb.base/complet", making that
    particular test ambiguous.  Adding another letter disambiguates.
    
    gdb/ChangeLog:
    2017-11-25   Pedro Alves  <palves@redhat.com>
    
    	* completer.c (complete_line_internal_1): Skip spaces until the
    	start of the command.
    
    gdb/testsuite/ChangeLog:
    2017-11-25   Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/complete-empty.exp: New file.
    	* gdb.base/completion.exp: Adjust.

commit 6a3c6ee41898743234d8fd9f9cab15f2ecdaba49
Author: Pedro Alves <palves@redhat.com>
Date:   Sat Nov 25 00:09:25 2017 +0000

    Add comprehensive C++ operator linespec/location/completion tests
    
    This exercises the special handling C++ operators require in several
    places in the linespec parser, both the linespec and explicit location
    completers, symbol lookup, etc.  Particularly, makes sure all that
    works without quoting.
    
    Note that despite the apparent smallish size, this adds thousands of
    tests to the testsuite, due to combination explosion (linespecs,
    explicit locations, tab completion, complete command, completion at
    different points in each function, etc.)
    
    Grows the gdb.linespec/ tests like this:
    
     -# of expected passes           3464
     +# of expected passes           7823
    
    gdb/testsuite/ChangeLog:
    2017-11-25  Pedro Alves  <palves@redhat.com>
    
    	* gdb.linespec/cpls-ops.cc: New file.
    	* gdb.linespec/cpls-ops.exp: New file.
    	* lib/completion-support.exp (test_complete_prefix_range_re): New,
    	factored out from ...
    	(test_complete_prefix_range): ... this.

commit 13450e7c7fdbdb9b25aae68c60475d061ed427d3
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Nov 25 00:00:26 2017 +0000

    Automatic date update in version.in

commit 8955eb2da31d78690c762748fab3a16832ef1f81
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Nov 24 23:41:12 2017 +0000

    Comprehensive C++ linespec/completer tests
    
    Exercises all sorts of aspects fixed by previous patches, going back a
    few months.
    
     - Exercises label completion, linespecs and explicit locations.
    
     - Exercises both quoting vs non-quoting, source filenames, function
       names, labels, with both linespecs and explicit locations.
    
     - Tests corner cases around not-quoting function names, and
       whitespace and/and completing inside a parameter or template
       argument list, anonymous namespace awareness, etc.
    
       E.g.,
    
         "break foo<[TAB]"          -> "break foo<int>()"
         "break bar ( int[TAB]"     -> "break bar ( int)
         "break ( anon"             -> "break ( anonymous namespace)::func()"
         "b cfunc() [tab]"          -> "b cfunc() const"
         "b rettype templfunc[tab]" -> "b rettype templfunc<bar>()"
    
       ... and others.
    
     - Tests the "b source.c[TAB] -> b source.cc:" feature.  I.e., colon
       auto-appending.
    
     - Exercises corner cases around C++ "operator<" / "operator<<".
       (Much more extensive C++ operator completion/linespec handling in a
       separate patch.)
    
     - Exercises both tab completion and "complete" command completion,
       using routines that handle it automatically, to ensure no test
       forgets either mode.
    
     - Many of the completion tests test completion at at prefix of a
       given tricky name, to make sure all corner cases are covered.
       E.g., completing before, at and after ":", "(", "<".
    
     - Exercises "keyword" completion.  I.e., "b function() [TAB]"
       displaying "if task thread" as completion match list.  Likewise for
       display explicit location options matches at the appropriate
       points.
    
     - Ensures that the completer finds the same breakpoint locations that
       setting a breakpoint finds.
    
     - Tests that linespec/location completion doesn't find data symbols.
    
     - Tests that expression completion still kicks in after a
       linespec/location keyword.  I.e., this:
    
         "b function () if global1 + global[TAB]"
    
       knows that after "if", you're completing on an expression, and thus
       breaks words after "if" as an expression and matches on "global" as
       a data symbol.
    
     - Adds common routines to help with all the above, to be used by
       multiple completion and linespec/location test cases.
    
     - More...
    
    Grows the gdb.linespec/ tests like this:
    
      -# of expected passes           573
      +# of expected passes           3464
    
    gdb/testsuite/ChangeLog:
    2017-11-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.linespec/cpcompletion.exp: New file.
    	* gdb.linespec/cpls-hyphen.cc: New file.
    	* gdb.linespec/cpls.cc: New file.
    	* gdb.linespec/cpls2.cc: New file.
    	* gdb.linespec/explicit.exp: Load completion-support.exp.  Adjust
    	test to use test_gdb_complete_unique.  Add label completion,
    	keyword completion and explicit location completion tests.
    	* lib/completion-support.exp: New file.

commit 0662b6a7c1b3b04a4ca31a09af703c91c7aa9646
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Nov 24 23:30:04 2017 +0000

    Make strcmp_iw NOT ignore whitespace in the middle of tokens
    
    currently "b func tion" manages to set a breakpoint at "function" !
    
    All these years I had never noticed this, but now that the linespec
    completer actually works, this easily happens by accident, with:
    
      "b func t<tab>"
    
    expecting to get "thread", but getting instead:
    
      "b func tion"
    
    ...
    
    Also, this:
    
      "b rettypefunc<int>"
    
    manages to set a breakpoint on "rettype func<int>()".
    
    These things happen due to strcmp_iw "magic".
    
    Fix it by teaching strcmp_iw about when can it skip whitespace.  This
    required handling user-defined operators, and scope operators,
    complicating the code a bit, unfortunately.  I added unit tests for
    all the corner cases I stumbled on, as I was developing this, and then
    in the end wrote a testsuite testcase covering many of the same things
    and more (to be added later).
    
    gdb/ChangeLog:
    2017-11-24  Pedro Alves  <palves@redhat.com>
    
    	* cp-support.c (cp_symbol_name_matches_1): New, factored out from
    	cp_fq_symbol_name_matches.  Pass language_cplus to
    	strncmp_with_mode.
    	(cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
    	(selftests::test_cp_symbol_name_cmp): New.
    	(_initialize_cp_support): Register "cp_symbol_name_matches"
    	selftests.
    	* language.c (default_symbol_name_matcher): Pass language_minimal
    	to strncmp_iw_with_mode.
    	* utils.c: Include "cp-support.h" and <algorithm>.
    	(valid_identifier_name_char, cp_skip_operator_token, skip_ws)
    	(cp_is_operator): New functions.
    	(strncmp_iw_with_mode): Use them.  Add language parameter.  Don't
    	skip whitespace in the symbol name when the lookup name doesn't
    	have spaces, and vice versa.
    	(strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
    	* utils.h (strncmp_iw_with_mode): Add language parameter.

commit 276da9b31bd6e3eb8d1dd814c867266f59f29093
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 24 14:49:36 2017 -0800

    Re-apply "elf: Properly compute offsets of note descriptor and next note"
    
    CORE PT_NOTE segments may have p_align values of 0 or 1.  gABI specifies
    that PT_NOTE alignment should be aligned to 4 bytes for 32-bit objects
    and to 8 bytes for 64-bit objects.  If segment alignment is less than 4,
    we use 4 byte alignment.

commit e547c119d043f2ecffb70452020ab9150d083a91
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Nov 24 17:09:42 2017 -0500

    (Ada) provide the exception message when hitting an exception catchpoint
    
    This patch enhances the debugger to print the exception message, when
    available, as part of an exception catchpoint hit notification (both
    GDB/CLI and GDB/MI). For instance, with the following code...
    
        procedure A is
        begin
           raise Constraint_Error with "hello world";
        end A;
    
    ... instead of printing...
    
        Catchpoint 1, CONSTRAINT_ERROR at 0x000000000040245c in a () at a.adb:3
    
    ... it now prints:
    
        Catchpoint 1, CONSTRAINT_ERROR (hello world) at 0x000000000040245c in a ()
                                       ^^^^^^^^^^^^^
    
    This enhancement requires runtime support. If not present, the debugger
    just behaves as before.
    
    In GDB/MI mode, if the exception message is available, it is provided
    as an extra field named "exception-message" in the catchpoint notification:
    
        *stopped,bkptno="1",[...],exception-name="CONSTRAINT_ERROR",
           exception-message="hello world",[...]
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_exception_message_1, ada_exception_message):
            New functions.
            (print_it_exception): If available, display the exception
            message as well.
            * NEWS: Document new feature.
    
    gdb/doc/ChangeLog:
    
            * gdb.texinfo (GDB/MI Ada Exception Information): Document
            new "exception-message" field.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/catch_ex.exp, gdb.ada/mi_catch_ex.exp,
            gdb.ada/mi_ex_cond.exp: Accept optional exception message in
            when hitting an exception catchpoint.

commit 5f1ca24acd8fd4e21c4f6f3ed2bbc4e2365215fe
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Nov 24 17:10:25 2017 -0500

    Fix issues with gdb-memory-map.dtd
    
    While writing a unit test for parse_memory_map, I tried to validate my
    test input against gdb-memory-map.dtd, and found a few problems with it.
    This doesn't influence how gdb parses it (AFAIK it doesn't use the
    linked dtd), but if you edit the xml file in an editor that supports
    dtds, you'll get plenty of errors.
    
      - The <memory-map> element accepts exactly one <memory> OR <property>
        as a child.  This is a problem because you can't have multiple
        <memory> elements and you shouldn't be able to have <property> elements
        as direct children of <memory-map>.
      - The <memory> element wants exactly one <property> child.  This is
        wrong, since you could have zero or more (even though we only
        support one kind of property currently).
      - I have no idea wht the device attribute of <memory> is, GDB doesn't
        read that.  I searched back in time a bit but couldn't find a trace
        of it.
    
    I took the opportunity to tighten what is accepted as a value of the
    memory type and property name attributes.  We currently accept any
    string, but we can restrict them to the values GDB really accepts (and
    which are documented).
    
    AFAIK, this "file" only exists in the documentation, in gdb.texinfo, so
    this is what I modified.  However, it's also available at
    http://sourceware.org/gdb/gdb-memory-map.dtd.  This one should be
    updated too, but I don't know how that should be done.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (Memory Map Format): Update gdb-memory-map.dtd.

commit f5291a6f321ba6d657aab447ebb6a168ae48d40b
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Fri Nov 24 22:04:41 2017 +0100

    [spu] Fix spu-linux gdbserver build
    
    Fix a typo in a newly added argument name.
    
    gdb/ChangeLog:
    2017-11-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* spu-low.c (spu_create_inferior): Fix typo in argument name.

commit d7fcdff980f113ccf77f8dd2f8fb3de3d6addaa3
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Fri Nov 24 22:03:28 2017 +0100

    [spu] Fix spu-linux native build
    
    Add missing file to NATDEPFILES.
    
    gdb/ChangeLog:
    2017-11-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.

commit 4e25ac038efbe5293885cc75d8a3e08b23da7cc9
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Nov 24 15:41:23 2017 -0500

    Revert "elf: Properly compute offsets of note descriptor and next note"
    
    This reverts commit 650444eb540f9fd85e821567a3f943b4bc41b8be.
    
    With this patch, running the GDB test case gdb.base/auxv.exp is stuck in
    an infinite loop, consuming memory to the point that it renders the
    machine unusable. I am reverting it so we can take our time to
    investigate while not killing all the developers' machines.

commit 0fbc35681ff0825be97802efcccf953bc4573a45
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Nov 24 09:31:59 2017 -0800

    Add reference to implicit use in _bfd_elf_is_local_label_name.
    
    	gas/
    	* write.h (FAKE_LABEL_CHAR): Expand comment.

commit 8b77421a20c22c9a66048e7d1484b149da060b67
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 24 08:58:43 2017 -0800

    Update PR ld/21562 tests for underscore targets
    
    We also need to provide __start_scnfoo and __stop_scnfoo with the extra
    leading underscore for underscore targets.
    
    This patch fixed:
    
    FAIL: ld-elf/pr21562k
    FAIL: ld-elf/pr21562l
    FAIL: ld-elf/pr21562m
    FAIL: ld-elf/pr21562n
    
    for metag-linux,
    
    	* testsuite/ld-elf/pr21562c.t: Also provide ___start_scnfoo and
    	___stop_scnfoo.
    	* testsuite/ld-elf/pr21562d.t: Likewise.

commit 30649c145114fe3aac089bf06e9457238d46341b
Author: Philipp Rudo <prudo@linux.vnet.ibm.com>
Date:   Fri Nov 24 11:05:57 2017 +0100

    Workaround build bug with GCC 6.2.1
    
    Building GDB with GCC 6.2.1 gives multiple errors like
    
    gdb/dtrace-probe.c: In member function â??void dtrace_probe::build_arg_exprs(gdbarch*)â??:
    gdb/dtrace-probe.c:627:8: error: types may not be defined in a for-range-declaration [-Werror]
        for (struct dtrace_probe_arg &arg : m_args
    
    Fix it by removing the 'struct' keyword.
    
    A similar Bug was already fixed for GCC 6.3.1
    https://sourceware.org/ml/gdb-patches/2017-10/msg00442.html
    
    gdb/ChangeLog:
    
    	* dtrace-probe.c (dtrace_probe::build_arg_exprs)
    	(dtrace_probe::is_enabled, dtrace_probe::enable)
    	(dtrace_probe::disable): Remove keyword 'struct' at for-range
    	variable
    	* probe.c (gen_ui_out_table_header_info)
    	(print_ui_out_not_applicables):  Remove keyword 'struct' at
    	for-range variable

commit 7696f5c95761be03db7ac62683aa027ecea30fa7
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Nov 24 15:54:57 2017 +0000

    Fix aarch64-none-elf build error
    
    gdb/
    	* configure.tgt: Add arch/aarch64.o

commit 8172f16b5b8bf3007d0aafcb38964a408f0e844f
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 24 10:42:01 2017 -0500

    Poison XNEW and friends for types that should use new/delete
    
    This patch (finally!) makes it so that trying to use XNEW with a type
    that requires "new" will cause a compilation error.  The criterion I
    initially used to allow a type to use XNEW (which calls malloc in the
    end) was std::is_trivially_constructible, but then realized that gcc 4.8
    did not have it.  Instead, I went with:
    
      using IsMallocatable = std::is_pod<T>;
    
    which is just a bit more strict, which doesn't hurt.  A similar thing is
    done for macros that free instead of allocated, the criterion is:
    
      using IsFreeable = gdb::Or<std::is_trivially_destructible<T>, std::is_void<T>>;
    
    Trying to use XNEW on a type that requires new will result in an error
    like this:
    
        In file included from /home/simark/src/binutils-gdb/gdb/common/common-utils.h:26:0,
                         from /home/simark/src/binutils-gdb/gdb/common/common-defs.h:78,
                         from /home/simark/src/binutils-gdb/gdb/defs.h:28,
                         from /home/simark/src/binutils-gdb/gdb/lala.c:1:
        /home/simark/src/binutils-gdb/gdb/common/poison.h: In instantiation of â??T* xnew() [with T = bar]â??:
        /home/simark/src/binutils-gdb/gdb/lala.c:13:3:   required from here
        /home/simark/src/binutils-gdb/gdb/common/poison.h:103:3: error: static assertion failed: Trying to use XNEW with a non-POD data type.  Use operator new instead.
           static_assert (IsMallocatable<T>::value, "Trying to use XNEW with a non-POD\
           ^~~~~~~~~~~~~
    
    Generated-code-wise, it adds one more function call (xnew<T>) when using
    XNEW and building with -O0, but it all goes away with optimizations
    enabled.
    
    gdb/ChangeLog:
    
    	* common/common-utils.h: Include poison.h.
    	(xfree): Remove declaration, add definition with static_assert.
    	* common/common-utils.c (xfree): Remove.
    	* common/poison.h (IsMallocatable): Define.
    	(IsFreeable): Define.
    	(free): Delete for non-freeable types.
    	(xnew): New.
    	(XNEW): Undef and redefine.
    	(xcnew): New.
    	(XCNEW): Undef and redefine.
    	(xdelete): New.
    	(XDELETE): Undef and redefine.
    	(xnewvec): New.
    	(XNEWVEC): Undef and redefine.
    	(xcnewvec): New.
    	(XCNEWVEC): Undef and redefine.
    	(xresizevec): New.
    	(XRESIZEVEC): Undef and redefine.
    	(xdeletevec): New.
    	(XDELETEVEC): Undef and redefine.
    	(xnewvar): New.
    	(XNEWVAR): Undef and redefine.
    	(xcnewvar): New.
    	(XCNEWVAR): Undef and redefine.
    	(xresizevar): New.
    	(XRESIZEVAR): Undef and redefine.

commit 7aabaf9d4ad52a1df1f551908fbd8cafc5e7597a
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 24 10:40:31 2017 -0500

    Create private_thread_info hierarchy
    
    There are multiple definitions of the private_thread_info structure
    compiled in the same GDB build.  Because of the one definition rule, we
    need to change this if we want to be able to make them non-POD (e.g. use
    std::vector fields).  This patch creates a class hierarchy, with
    private_thread_info being an abstract base class, and all the specific
    implementations inheriting from it.
    
    In order to poison XNEW/xfree for non-POD types, it is also needed to
    get rid of the xfree in thread_info::~thread_info, which operates on an
    opaque type.  This is replaced by thread_info::priv now being a
    unique_ptr, which calls the destructor of the private_thread_info
    subclass when the thread is being destroyed.
    
    Including gdbthread.h from darwin-nat.h gave these errors:
    
    /Users/simark/src/binutils-gdb/gdb/gdbthread.h:609:3: error: must use 'class' tag to refer to type 'thread_info' in this scope
      thread_info *m_thread;
      ^
      class
    /usr/include/mach/thread_act.h:240:15: note: class 'thread_info' is hidden by a non-type declaration of 'thread_info' here
    kern_return_t thread_info
                  ^
    
    It turns out that there is a thread_info function in the Darwin/XNU/mach API:
    
      http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/thread_info.html
    
    Therefore, I had to add the class keyword at a couple of places in gdbthread.h,
    I don't really see a way around it.
    
    gdb/ChangeLog:
    
    	* gdbthread.h (private_thread_info): Define structure type, add
    	virtual pure destructor.
    	(thread_info) <priv>: Change type to unique_ptr.
    	<private_dtor>: Remove.
    	* thread.c (add_thread_with_info): Adjust to use of unique_ptr.
    	(private_thread_info::~private_thread_info): Provide default
    	implementation.
    	(thread_info::~thread_info): Don't call private_dtor nor
    	manually free priv.
    	* aix-thread.c (private_thread_info): Rename to ...
    	(aix_thread_info): ... this.
    	(get_aix_thread_info): New.
    	(sync_threadlists): Adjust.
    	(iter_tid): Adjust.
    	(aix_thread_resume): Adjust.
    	(aix_thread_fetch_registers): Adjust.
    	(aix_thread_store_registers): Adjust.
    	(aix_thread_extra_thread_info): Adjust.
    	* darwin-nat.h (private_thread_info): Rename to ...
    	(darwin_thread_info): ... this.
    	(get_darwin_thread_info): New.
    	* darwin-nat.c (darwin_init_thread_list): Adjust.
    	(darwin_check_new_threads): Adjust.
    	(thread_info_from_private_thread_info): Adjust.
    	* linux-thread-db.c (private_thread_info): Rename to ...
    	(thread_db_thread_info): ... this, initialize fields.
    	(get_thread_db_thread_info): New.
    	<dying>: Change type to bool.
    	(update_thread_state): Adjust to type rename.
    	(record_thread): Adjust to type rename an use of unique_ptr.
    	(thread_db_pid_to_str): Likewise.
    	(thread_db_extra_thread_info): Likewise.
    	(thread_db_thread_handle_to_thread_info): Likewise.
    	(thread_db_get_thread_local_address): Likewise.
    	* nto-tdep.h (private_thread_info): Rename to ...
    	(nto_thread_info): ... this, initialize fields.
    	(get_nto_thread_info): New.
    	<name>: Change type to std::string.
    	* nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
    	use of unique_ptr.
    	* nto-procfs.c (update_thread_private_data_name): Adjust to
    	std::string change, allocate nto_private_thread_info with new.
    	(update_thread_private_data): Adjust to unique_ptr.
    	* remote.c (private_thread_info): Rename to ...
    	(remote_thread_info): ... this, initialize data members with
    	default values.
    	<extra, name>: Change type to std::string.
    	<thread_handle>: Change type to non-pointer.
    	(free_private_thread_info): Remove.
    	(get_private_info_thread): Rename to...
    	(get_remote_thread_info): ... this, change return type, adjust to
    	use of unique_ptr, use remote_thread_info constructor.
    	(remote_add_thread): Adjust.
    	(get_private_info_ptid): Rename to...
    	(get_remote_thread_info): ...this, change return type.
    	(remote_thread_name): Use get_remote_thread_info, adjust to
    	change to std::string.
    	(struct thread_item) <~thread_item>: Remove.
    	<thread_handle>: Make non pointer.
    	(start_thread): Adjust to thread_item::thread_handle type
    	change.
    	(remote_update_thread_list): Adjust to type name change, move
    	strings from temporary to long-lived object instead of
    	duplicating.
    	(remote_threads_extra_info): Use get_remote_thread_info.
    	(process_initial_stop_replies): Likewise.
    	(resume_clear_thread_private_info): Likewise.
    	(remote_resume): Adjust to type name change.
    	(remote_commit_resume): Use get_remote_thread_info.
    	(process_stop_reply): Adjust to type name change.
    	(remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
    	(remote_stopped_by_hw_breakpoint): Likewise.
    	(remote_stopped_by_watchpoint): Likewise.
    	(remote_stopped_data_address): Likewise.
    	(remote_core_of_thread): Likewise.
    	(remote_thread_handle_to_thread_info): Use
    	get_private_info_thread, adjust to thread_handle field type
    	change.

commit 21fe1c752e254167d953fa8c846280f63a3a5290
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 24 10:40:13 2017 -0500

    remote: C++ify thread_item and threads_listing_context
    
    This patch C++ifies the thread_item and threads_listing_context
    structures in remote.c.  thread_item::{extra,name} are changed to
    std::string.  As a result, there's a bit of awkwardness in
    remote_update_thread_list, where we have to xstrdup those strings when
    filling the private_thread_info structure.  This is removed in the
    following patch, where private_thread_info is also C++ified and its
    corresponding fields made std::string too.  The xstrdup then becomes an
    std::move.
    
    Other than that there's nothing really special, it's a usual day-to-day
    VEC -> vector and char* -> std::string change.  It allows removing a
    cleanup in remote_update_thread_list.
    
    Note that an overload of hex2bin that returns a gdb::byte_vector is
    added, with corresponding selftests.
    
    gdb/ChangeLog:
    
    	* remote.c (struct thread_item): Add constructor, disable copy
    	construction and copy assignment, define default move
    	construction and move assignment.
    	<extra, name>: Change type to std::string.
    	<core>: Initialize.
    	<thread_handle>: Make non-pointer.
    	(thread_item_t): Remove typedef.
    	(DEF_VEC_O(thread_item_t)): Remove.
    	(threads_listing_context) <contains_thread>: New method.
    	<remove_thread>: New method.
    	<items>: Change type to std::vector.
    	(clear_threads_listing_context): Remove.
    	(threads_listing_context_remove): Remove.
    	(remote_newthread_step): Use thread_item constructor, adjust to
    	change to std::vector.
    	(start_thread): Use thread_item constructor, adjust to change to
    	std::vector.
    	(end_thread): Adjust to change to std::vector and std::string.
    	(remote_get_threads_with_qthreadinfo): Use thread_item
    	constructor, adjust to std::vector.
    	(remote_update_thread_list): Adjust to change to std::vector and
    	std::string, use threads_listing_context methods.
    	(remove_child_of_pending_fork): Adjust.
    	(remove_new_fork_children): Adjust.
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
    	* unittests/rsp-low-selftests.c: New file.
    	* common/rsp-low.h: Include common/byte-vector.h.
    	(hex2bin): New overload.
    	* common/rsp-low.c (hex2bin): New overload.

commit 089354bb0613ca1559813f0a79fbe73655113785
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Nov 24 10:39:30 2017 -0500

    Create private_inferior class hierarchy
    
    There are currently multiple definitions of private_inferior, defined in
    remote.c and darwin-nat.h.  The patch that poisons XNEW and friends for
    non-POD types trips on that, because private_inferior is freed in
    ~inferior(), where it is an opaque type.  Since the compiler can't tell
    whether the type is POD, it gives an error.  Also, we can't start using
    C++ features in these structures (make them non-POD) as long as there
    are multiple definitions with the same name.  For these reasons, this
    patch makes a class hierarchy, with private_inferior being the abstract
    base class, and darwin_inferior & remote_inferior inheriting from it.
    Destruction is done through the virtual destructor.
    
    I stumbled on some suspicious code in the darwin implementation though.
    darwin_check_new_threads does an XCNEW(darwin_thread_t) when it finds a
    new thread, allocating a new structure for it (darwin_thread_t is a
    typedef for private_thread_info).  It then VEC_safe_pushes it in a
    vector defined as DEF_VEC_O (a vector of objects).  This means that the
    structure content gets copied in the vector.  The thread_info object is
    created with the XCNEW'ed structure as the private thread info, while
    the rest of the code works with the instance in the vector.  We have
    therefore two distinct instances of darwin_thread_t/private_thread_info
    for each thread.  This is not really a problem in practice, because
    thread_info::priv is not used in the darwin code.  I still find it weird
    and far from ideal, so I tried to fix it by changing the vector to be a
    vector of pointers.  There should now be a single instance of the
    structure for each thread.  The deallocation of the
    darwin_thread_t/private_thread_info structure is done by the thread_info
    destructor.
    
    I am able to build on macOS, but not really test, since the port seems a
    bit broken.  I am not able to debug reliably on the machine I have
    access to, which runs macOS 10.12.6.
    
    gdb/ChangeLog:
    
    	* inferior.h (private_inferior): Define structure type, add
    	virtual pure destructor.
    	(inferior) <priv>: Change type to unique_ptr.
    	* inferior.c (private_inferior::~private_inferior): Provide
    	default implementation.
    	(inferior::~inferior): Don't free priv field.
    	(exit_inferior_1): Likewise.
    	* darwin-nat.h (struct darwin_exception_info): Initialize fields.
    	(darwin_exception_info): Remove typedef.
    	(DEF_VEC_O (darwin_thread_t)); Remove.
    	(private_inferior): Rename to ...
    	(darwin_private_inferior): ... this, extend private_inferior.
    	(get_darwin_inferior): New.
    	<threads>: Change type to std::vector of darwin_thread_t pointers.
    	* darwin-nat.c (darwin_check_new_threads): Adjust.
    	(find_inferior_task_it): Adjust.
    	(darwin_find_thread); Adjust.
    	(darwin_suspend_inferior): Adjust.
    	(darwin_resume_inferior): Adjust.
    	(darwin_find_new_inferior): Adjust.
    	(darwin_decode_notify_message): Adjust.
    	(darwin_send_reply): Adjust.
    	(darwin_resume_inferior_threads): Adjust.
    	(darwin_suspend_inferior_threads): Adjust.
    	(darwin_decode_message): Adjust.
    	(darwin_wait): Adjust.
    	(darwin_interrupt): Adjust.
    	(darwin_deallocate_threads): Adjust.
    	(darwin_mourn_inferior): Adjust, don't free private data.
    	(darwin_reply_to_all_pending_messages): Adjust.
    	(darwin_stop_inferior): Adjust.
    	(darwin_setup_exceptions): Adjust.
    	(darwin_kill_inferior): Adjust.
    	(darwin_setup_request_notification): Adjust.
    	(darwin_attach_pid): Adjust.
    	(darwin_init_thread_list): Adjust.
    	(darwin_setup_fake_stop_event): Adjust.
    	(darwin_attach): Adjust.
    	(darwin_detach): Adjust.
    	(darwin_xfer_partial): Adjust.
    	(set_enable_mach_exceptions): Adjust.
    	(darwin_pid_to_exec_file): Adjust.
    	(darwin_get_ada_task_ptid): Adjust.
    	* darwin-nat-info.c (get_task_from_args): Adjust.
    	(info_mach_ports_command): Adjust.
    	(info_mach_region_command): Adjust.
    	(info_mach_exceptions_command): Adjust.
    	* remote.c (private_inferior): Rename to ...
    	(remote_private_inferior): ... this, initialize fields.
    	(get_remote_inferior); New.
    	(remote_commit_resume): Use get_remote_inferior.
    	(check_pending_event_prevents_wildcard_vcont_callback): Likewise.

commit d044bac8ce5e6737d13e7e5180f5a5641053e690
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Nov 24 15:21:16 2017 +0000

    Document linespec/explicit locations & completion improvements (manual + NEWS)
    
    gdb/ChangeLog:
    2017-11-24  Pedro Alves  <palves@redhat.com>
    
    	* NEWS: Mention linespecs and explicit locations, and completion
    	improvements.
    
    gdb/doc/ChangeLog:
    2017-11-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.texinfo (Completion): Update need-quoting examples.  Remove
    	false claim that GDB inserts quoting automatically.
    	(Symbols): Add anchor.

commit e8d58cbaacb9ca54ad32eee1a38301202e09f878
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 14:58:45 2017 +0000

    Remove dead code in regcache::dump
    
    footnote_register_size in regcache::dump is a constant zero, so the
    condition check against footnote_register_size is dead code.  The code
    writing to footnote_register_size was removed by 01e1877.
    
    This patche removes footnote_register_size and the dead code.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (regcache::dump): Remove footnote_register_size.

commit 650444eb540f9fd85e821567a3f943b4bc41b8be
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 24 06:41:40 2017 -0800

    elf: Properly compute offsets of note descriptor and next note
    
    According to gABI, in a note entry, the note name field, not note name
    size, is padded for the note descriptor.  And the note descriptor field,
    not note descriptor size, is padded for the next note entry.  Also notes
    are aligned to 4 bytes in 32-bit objects and 8 bytes in 64-bit objects.
    Since on Linux, .note.ABI-tag and .note.gnu.build-id notes are always
    aligned to 4 bytes, we need to use alignment of note section or note
    segment, instead of assuming alignment based on ELF file class.
    
    Tested on i686 and x86-64.
    
    bfd/
    
    	PR binutils/22444
    	* elf.c (elf_read_notes): Add an argument for note aligment.
    	(elf_parse_notes): Likewise.
    	(_bfd_elf_make_section_from_shdr): Pass section aligment to
    	elf_parse_notes.
    	(bfd_section_from_phdr): Pass segment aligment to elf_read_notes.
    	(elf_parse_notes): Add an argument for note aligment.  Use
    	ELF_NOTE_DESC_OFFSET to get the offset of the note descriptor.
    	Use ELF_NOTE_NEXT_OFFSET to get the offset of the next note
    	entry.
    	(elf_read_notes): Add an argument for note aligment and pass it
    	to elf_parse_notes.
    
    binutils/
    
    	PR binutils/22444
    	* readelf.c (process_notes_at): Use ELF_NOTE_DESC_OFFSET to get
    	the offset of the note descriptor.  Use ELF_NOTE_NEXT_OFFSET to
    	get the offset of the next note entry.
    
    include/
    
    	PR binutils/22444
    	* elf/external.h (ELF_ALIGN_UP): New.
    	(ELF_NOTE_DESC_OFFSET): Likewise.
    	(ELF_NOTE_NEXT_OFFSET): Likewise.

commit a63f2d2feedcfce401ae1d7d03d119bfa5e4d8bc
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 13:04:30 2017 +0000

    cooked_read test for readonly regcache
    
    This patch adds a test to check cooked_read for readonly regcache.  For
    raw registers, cooked_read get either REG_VALID or REG_UNKNOWN, depends on
    the raw register is in save_reggroup or not.  For pseudo register,
    cooked_read get different result in different ports.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (cooked_read_test): Add more test for readonly
    	regcache.

commit 1b30aaa56607a563fa263b9d2ee9eba89d79c1b4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 13:04:30 2017 +0000

    regcache::cooked_read unit test
    
    This patch adds a unit test to regcache::cooked_read.  This unit test is a
    little different from normal unit test, it is more about conformance test
    or interaction test.  This test pass both raw register number and pseudo
    register number to regcache::cooked_read, in order to inspect 1) return
    value of cooked_read, 2) how are target_ops to_xfer_partial,
    to_{fetch,store}_registers called (because regcache is updated by means of
    these three target_ops methods).  With this test here, we have a clear
    picture about how each port of GDB get cooked registers.
    
    This patch also shares some code on mock target.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* gdbarch-selftests.c (test_target_has_registers): Move it to
    	target.c.
    	(test_target_has_stack): Likewise.
    	(test_target_has_memory): Likewise.
    	(test_target_prepare_to_store): Likewise.
    	(test_target_store_registers): Likewise.
    	(test_target_ops): Likewise.
    	* regcache.c: Include selftest-arch.h and gdbthread.h.
    	(target_ops_no_register): New class.
    	(test_target_fetch_registers): New.
    	(test_target_store_registers): New.
    	(test_target_xfer_partial): New.
    	(readwrite_regcache): New.
    	(cooked_read_test): New.
    	(_initialize_regcache): Register the test.
    	* target.c: (test_target_has_registers): Moved from
    	gdbarch-selftests.c.
    	(test_target_has_stack): Likewise.
    	(test_target_has_memory): Likewise.
    	(test_target_prepare_to_store): Likewise.
    	(test_target_store_registers): Likewise.
    	* target.h (test_target_ops): New class.

commit 6654d750c7c584dd83b93f062c5628f15c675480
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Nov 24 10:28:58 2017 +0000

    Add xml selftests for aarch64 target description.
    
    gdb/
    	* aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
    	selftest.
    
    gdbserver/
    	* configure.srv: Add linux-aarch64-tdesc-selftest.o.
    	* linux-aarch64-low.c (initialize_low_arch): Call init func.
    	* linux-aarch64-tdesc-selftest.c: New file.
    	* linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.

commit 49bdb7ee48a10581e9f7254782f2eb953c4a164b
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Nov 24 10:20:48 2017 +0000

    Use flexible target descriptors for aarch64
    
    gdb/
    	* aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
    	* arch/aarch64.c (aarch64_create_target_description): Create
    	new target description.
    	* features/Makefile: Add new files.
    	* features/aarch64.c: Remove file.
    	* features/aarch64-core.c: New autogenerated file.
    	* features/aarch64-fpu.c: New autogenerated file.
    	* target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
    
    gdbserver/
    	* linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
    	* linux-aarch64-low.c (initialize_low_arch): Remove init.
    	* linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.

commit d6d7ce56231ca8c233e64b2ebcb910fe334d6ff8
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Nov 24 10:04:53 2017 +0000

    gdbserver: add aarch64_create_target_description
    
    gdbserver/
    	* configure.srv: Add new files.
    	* linux-aarch64-ipa.c (get_ipa_tdesc): Call
    	aarch64_linux_read_description.
    	* linux-aarch64-low.c (aarch64_linux_read_description):
    	Merge with aarch64_arch_setup.
    	(aarch64_arch_setup): Call aarch64_linux_read_description.
    	* linux-aarch64-tdesc.c: New file.
    	* linux-aarch64-tdesc.h: New file.

commit da434ccbc3e0ed843700790cd16c1d4bb5882460
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Fri Nov 24 10:00:54 2017 +0000

    Add aarch64_create_target_description
    
    gdb/
    	* Makefile.in: Add new files.
    	* aarch64-linux-nat.c (aarch64_linux_read_description): Call
    	aarch64_read_description.
    	* aarch64-linux-tdep.c (aarch64_linux_core_read_description):
    	Call aarch64_read_description.
    	* aarch64-tdep.c (aarch64_read_description): New function.
    	(aarch64_gdbarch_init): Call aarch64_read_description.
    	* aarch64-tdep.h (aarch64_read_description): New function.
    	* arch/aarch64.c: New file.
    	* configure.tgt: Add new files.

commit 98ead37e9735438986934f9f1f35f020a093fe07
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 10:47:27 2017 +0000

    Change value_contents_eq return bool
    
    This patch changes value_contents_eq return type from int to bool.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* mi/mi-main.c (register_changed_p): Update.
    	* value.c (value_contents_bits_eq): Change return type.
    	(value_contents_eq): Likewise.
    	* value.h: Update comments.

commit 62ad7ce71b243df3e8d7d4f8b8560a7316233a9e
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 10:47:27 2017 +0000

    Change register_changed_p returns bool
    
    register_changed_p actually returns bool, but return type is still int.
    This patch changes the return type to bool.  The caller of
    register_changed_p also checked whether the return value can be negative,
    which is not needed now.  Such check was added in fb40c2090 in 2000,
    at that moment, register_changed_p returns -1 when
    read_relative_register_raw_bytes fails.  I can tell from its name that
    it reads register contents, but we don't have this function called inside
    register_changed_p, and the regcache is read-only.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
    	local 'changed'.  Remove error.
    	(register_changed_p): Change return type to bool.

commit 506fe5f4996738f25b7c26f126a84b231429ba95
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 24 09:29:43 2017 +0000

    Change tic6x target descriptions
    
    This patch changes tic6x target descriptions to be more flexible.  Rebuild
    tic6x-uclinux GDBserver with my x86 g++, and the unit test passes.
    
    gdb:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* arch/tic6x.c: New file.
    	* arch/tic6x.h: New file.
    	* features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
    	tic6x-core.xml and tic6x-gp.xml.
    	* features/tic6x-c6xp.c: Generated.
    	* features/tic6x-core.c: Generated.
    	* features/tic6x-gp.c: Generated.
    	* target-descriptions.c (maint_print_c_tdesc_cmd): Match
    	"tic6x-".
    
    gdb/gdbserver:
    
    2017-11-24  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv: Set $srv_regobj for tic6x-linux.
    	* linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
    	(tic6x_read_description): Move some code to tic6x_arch_setup.
    	(tic6x_tdesc_test): New function.
    	(initialize_low_arch): Call selftests::register_test.

commit 6d2cd6b2084d980a4baf5b4bdce8499c2295a672
Author: Jan Beulich <jbeulich@novell.com>
Date:   Fri Nov 24 08:42:57 2017 +0100

    x86: reject further invalid AVX-512 masking constructs
    
    For one the register type used for masking should be validated. And then
    we shouldn't accept input producing encodings which will #UD when
    executed, as is the case when EVEX.Z is set while EVEX.AAA is zero.

commit ac465521a50102d589a6a05a1e722dfa349d3181
Author: Jan Beulich <jbeulich@novell.com>
Date:   Fri Nov 24 08:42:04 2017 +0100

    x86: don't omit disambiguating suffixes from "fi*"
    
    "fi*" typically come in two (loads/stores: three) flavors, distinguished
    by the suffix. Don't omit the 's' one when disassembling.

commit 00ea2e2ad34edd202f58d9a1eea2081f0905f9f2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Nov 23 21:56:19 2017 -0500

    Fix memory leak in list_available_thread_groups
    
    Commit
    
      C++ify osdata
      479f8de1b3b7e69ca8d557bbe9d843c7d1bc89c5
    
    introduced a memory leak.  We allocate std::vectors and insert them in a
    map, but never free them.  Instead, the map value type can be
    std::vector objects directly.
    
    gdb/ChangeLog:
    
    	* mi/mi-main.c (list_available_thread_groups): Change map value
    	type to std::vector.

commit 7e8006d14c544a069619dc2bb2c9d2d2b7fd99a6
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Nov 24 00:00:23 2017 +0000

    Automatic date update in version.in

commit c139731b13f83da3c9436f92d52b915e94ff7480
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Nov 23 13:11:40 2017 -0800

    Fix vax/ns32k/mmix gas testsuite regression.
    
    	gas/
    	* testsuite/gas/all/err-fakelabel.s (dg-error): Also accept fatal error
    	string.

commit 5f71e59e1a284eec67ba2a91851d0ec8319b0b95
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Nov 23 12:30:47 2017 -0800

    Fix build error with --enable-targets=all.
    
    	gas/
    	* as.c (INITIALIZING_EMULS): Define.
    	* config/obj-multi.h (FAKE_LABEL_NAME): When INITIALIZING_EMULS set,
    	don't define it.

commit f45e2a7704c738ba8195a667f910297c4155924e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Nov 23 13:51:50 2017 -0500

    Fix clang warnings about copy elision
    
    When building with clang, I get:
    
    /home/emaisin/src/binutils-gdb/gdb/osdata.c:107:9: error: moving a temporary object prevents copy elision [-Werror,-Wpessimizing-move]
                                 std::move (std::string (body_text)));
                                 ^
    /home/emaisin/src/binutils-gdb/gdb/osdata.c:107:9: note: remove std::move call here
                                 std::move (std::string (body_text)));
                                 ^~~~~~~~~~~                       ~
    /home/emaisin/src/binutils-gdb/gdb/osdata.c:181:10: error: moving a local object in a return statement prevents copy elision [-Werror,-Wpessimizing-move]
      return std::move (osdata);
             ^
    /home/emaisin/src/binutils-gdb/gdb/osdata.c:181:10: note: remove std::move call here
      return std::move (osdata);
             ^~~~~~~~~~~      ~
    
    Indeed, those two std::move are unnecessary.
    
    gdb/ChangeLog:
    
    	* osdata.c (osdata_end_column, get_osdata): Remove std::move.

commit bd046f64a193405f2fef2d5120fab4be25feaa8b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Nov 23 11:05:22 2017 -0500

    Revert unexpected rename in previous patch
    
    While working on the previous patch, I renamed variables whose type I
    changed to let the compiler help me find their usages, but I forgot to
    rename one back to its original name.  This patch fixes it.
    
    gdb/ChangeLog:
    
    	* varobj.c (struct varobj_dynamic) <children_requested_>: Rename
    	back to...
    	<children_requested>: ... this.
    	(varobj_get_num_children, varobj_update): Adjust.

commit 4c37490d92c0168e5192ce109a791c4b3fec9f8e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Nov 23 11:00:56 2017 -0500

    Change int -> bool where applicable throughout varobj
    
    This patch changes all the "int" I could find in varobj.{c,h} that are
    really boolean values to use bool.  I followed the ramifications
    (parameters and return values of exported functions), so the changes
    spilled a bit on other, related files (ada-varobj.c and c-varobj.c).
    
    gdb/ChangeLog:
    
    	* ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
    	(ada_value_has_mutated): Likewise.
    	* c-varobj.c (varobj_is_anonymous_child): Likewise.
    	(c_is_path_expr_parent): Likewise.
    	* mi/mi-cmd-var.c (varobj_update_one): Likewise.
    	(mi_cmd_var_set_frozen): Likewise.
    	(mi_cmd_var_update_iter): Likewise.
    	(mi_cmd_var_update): Likewise.
    	* varobj.c (pretty_printing): Likewise.
    	(varobj_enable_pretty_printing): Likewise.
    	(struct varobj_root) <floating, is_valid>: Likewise.
    	(struct varobj_dynamic) <children_requested>: Likewise.
    	(delete_variable): Likewise.
    	(delete_variable_1): Likewise.
    	(install_variable): Likewise.
    	(update_type_if_necessary): Likewise.
    	(install_new_value): Likewise.
    	(value_of_root): Likewise.
    	(is_root_p): Likewise.
    	(varobj_create): Likewise.
    	(varobj_delete): Likewise.
    	(varobj_has_more): Likewise.
    	(varobj_set_frozen): Likewise.
    	(varobj_get_frozen): Likewise.
    	(install_dynamic_child): Likewise.
    	(dynamic_varobj_has_child_method): Likewise.
    	(update_dynamic_varobj_children): Likewise.
    	(varobj_get_num_children): Likewise.
    	(varobj_list_children): Likewise.
    	(is_path_expr_parent): Likewise.
    	(varobj_default_is_path_expr_parent): Likewise.
    	(varobj_is_dynamic_p): Likewise.
    	(varobj_set_value): Likewise.
    	(varobj_value_has_mutated): Likewise.
    	(varobj_update): Likewise.
    	(check_scope): Likewise.
    	(value_of_root_1): Likewise.
    	(varobj_value_get_print_value): Likewise.
    	(varobj_editable_p): Likewise.
    	(varobj_value_is_changeable_p): Likewise.
    	(varobj_floating_p): Likewise.
    	(varobj_default_value_is_changeable_p): Likewise.
    	(varobj_invalidate_iter): Likewise.
    	* varobj.h (struct varobj_update_result) <type_changed,
    	children_changed, changed, value_installed>: Likewise.
    	(struct varobj) <updated, frozen, not_fetched>: Likewise.
    	(struct lang_varobj_ops) <value_is_changeable_p,
    	value_has_mutated, is_path_expr_parent>: Likewise.
    	(varobj_delete): Likewise.
    	(varobj_set_frozen): Likewise.
    	(varobj_get_frozen): Likewise.
    	(varobj_set_value): Likewise.
    	(varobj_update): Likewise.
    	(varobj_editable_p): Likewise.
    	(varobj_floating_p): Likewise.
    	(varobj_has_more): Likewise.
    	(varobj_is_dynamic_p): Likewise.
    	(varobj_default_value_is_changeable_p): Likewise.
    	(varobj_value_is_changeable_p): Likewise.
    	(varobj_is_anonymous_child): Likewise.
    	(varobj_default_is_path_expr_parent): Likewise.

commit eb02c04dc3600e18bb06dc1ef8fc3cf9a967d550
Author: Pavel I. Kryukov <kryukov@frtk.ru>
Date:   Thu Nov 23 15:53:04 2017 +0000

    Avoid bogus compile time warning from clang by initialising local data structure using memset.
    
    	PR 22485
    	* readelf.c (process_archive): Use memset to initiaise
    	thin_filedata structure.

commit 7c3c1aa885b720e25b25af6ac05f34f9ff0e3dfa
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 23 15:30:56 2017 +0000

    [testsuite] Pass -g3 to clang in gdb.base/macscp.exp
    
    clang accepts option -g3 too.  I checked the manual of xlc and icc, looks
    they don't accept -g3 option, so I don't pass -g3 for them.
    
    gdb/testsuite:
    
    2017-11-23  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.base/macscp.exp: Append -g3 to additional_flags for clang.

commit be7d1531e1ce34efbdb9367f1483f9cdad477059
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Wed Nov 22 14:40:32 2017 +0300

    Add Disp8MemShift for AVX512 VAES instructions.
    
    opcodes/
    	* i386-opc.tbl: Add Disp8MemShift for AVX512 VAES instructions.
    	* i386-tbl.h: Regenerate.
    
    gas/
    	* testsuite/gas/i386/avx512f_vaes-intel.d: Regenerate.
    	* testsuite/gas/i386/avx512f_vaes.d: Likewise.
    	* testsuite/gas/i386/avx512f_vaes-wig1-intel.d: Likewise.
    	* testsuite/gas/i386/avx512f_vaes-wig1.d: Likewise.
    	* testsuite/gas/i386/avx512vl_vaes-intel.d: Likewise.
    	* testsuite/gas/i386/avx512vl_vaes.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_vaes.s: Add instructions with disp8*N.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-intel.d: Regenerate.
    	* testsuite/gas/i386/x86-64-avx512f_vaes.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig.s: Add instructions with disp8*N.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig1-intel.d: Regenerate.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig1.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-intel.d: Regenerate.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig.s: Add instructions with disp8*N.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig1-intel.d: Regenerate.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig1.d: Regenerate.

commit 287c7eaf0d90cc1bbb5a5463c665b163c6ee04e7
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 22 21:07:03 2017 +1030

    Don't move weak alias dyn_relocs to weakdef
    
    I did this for powerpc64 a while ago.  Not moving weak symbol
    dyn_relocs to the strong alias makes for a much simpler test for
    dynamic relocs in relocate_section.
    
    This patch implements the change for powerpc and hppa.  Other targets
    could benefit from similar changes.
    
    	* elf32-hppa.c (pc_dynrelocs): Define.
    	(elf32_hppa_copy_indirect_symbol): Don't copy dyn_relocs to weakdefs.
    	(alias_readonly_dynrelocs): New function.
    	(elf32_hppa_adjust_dynamic_symbol): Don't clear non_got_ref to
    	indicate dyn_relocs should be discarded, discard them here.
    	Use alias_readonly_dynrelocs.
    	(allocate_dynrelocs): Don't test or clear non_got_ref.
    	(elf32_hppa_relocate_section): Simplify test for dynamic relocs.
    	* elf32-ppc.c (ppc_elf_copy_indirect_symbol): Don't copy dyn_relocs
    	to weakdefs.
    	(alias_readonly_dynrelocs, pc_dynrelocs): New functions.
    	(ppc_elf_adjust_dynamic_symbol): Don't clear non_got_ref to
    	indicate dyn_relocs should be discarded, discard them here.
    	Use alias_readonly_dynrelocs.
    	(allocate_dynrelocs): Don't test or clear non_got_ref.
    	(ppc_elf_relocate_section): Simplify test for dynamic relocs.

commit ab2477e15cbe067ff119f1bb5dea05de3cadbdd5
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 22 17:32:50 2017 +1030

    Delete powerpc64 symbol weakref field
    
    Now that u.alias is circular, weakref just duplicates its function.
    Also, function symbols shouldn't be on the alias list so there is no
    need to use alias_readonly_dynrelocs with them.
    
    	* elf64-ppc.c (struct ppc_link_hash_entry): Delete weakref field.
    	(ppc64_elf_copy_indirect_symbol): Don't set weakref.
    	(alias_readonly_dynrelocs): Use u.alias rather than weakref.
    	(ppc64_elf_adjust_dynamic_symbol): Don't use
    	alias_readonly_dynrelocs for function symbols.

commit 60d67dc84bbc7d73672d297d714f8a4a0547618d
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 22 17:30:55 2017 +1030

    Rename u.weakdef and make it a circular list
    
    This makes the elf_link_hash_entry weakdef field, currently used to
    point from a weak symbol to a strong alias, a circular list so that
    all aliases can be found from any of them.  A new flag, is_weakalias,
    distinguishes the weak symbol from a strong alias, and is used in all
    places where we currently test u.weakdef != NULL.
    
    With the original u.weakdef handling it was possible to have two or
    more weak symbols pointing via u.weakdef to a strong definition.
    Obviously that situation can't map to a circular list; One or more of
    the weak symbols must point at another weak alias rather than the
    strong definition.  To handle that, I've added an accessor function to
    return the strong definition.
    
    	* elf-bfd.h (struct elf_link_hash_entry): Add is_weakalias.
    	Rename u.weakdef to u.alias and update comment.
    	(weakdef): New static inline function.
    	* elflink.c (bfd_elf_record_link_assignment) Test is_weakalias
    	rather than u.weakdef != NULL, and use weakdef function.
    	(_bfd_elf_adjust_dynamic_symbol): Likewise.
    	(_bfd_elf_fix_symbol_flags): Likewise.  Clear is_weakalias on
    	all aliases if def has been overridden in a regular object, not
    	u.weakdef.
    	(elf_link_add_object_symbols): Delete new_weakdef flag.  Test
    	is_weakalias and use weakdef.  Set is_weakalias and circular
    	u.alias.  Update comments.
    	(_bfd_elf_gc_mark_rsec): Test is_weakalias rather than
    	u.weakdef != NULL and use weakdef function.
    	* elf-m10300.c (_bfd_mn10300_elf_adjust_dynamic_symbol): Test
    	is_weakalias rather than u.weakdef != NULL and use weakdef
    	function.  Assert that def is strong defined.
    	* elf32-arc.c (elf_arc_adjust_dynamic_symbol): Likewise.
    	* elf32-arm.c (elf32_arm_adjust_dynamic_symbol): Likewise.
    	* elf32-bfin.c (elf32_bfinfdpic_adjust_dynamic_symbol): Likewise.
    	(bfin_adjust_dynamic_symbol): Likewise.
    	* elf32-cr16.c (_bfd_cr16_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-cris.c (elf_cris_adjust_dynamic_symbol): Likewise.
    	* elf32-frv.c (elf32_frvfdpic_adjust_dynamic_symbol): Likewise.
    	* elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Likewise.
    	* elf32-i370.c (i370_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-lm32.c (lm32_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-m32r.c (m32r_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
    	* elf32-metag.c (elf_metag_adjust_dynamic_symbol): Likewise.
    	* elf32-microblaze.c (microblaze_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-nds32.c (nds32_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-nios2.c (nios2_elf32_adjust_dynamic_symbol): Likewise.
    	* elf32-or1k.c (or1k_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
    	* elf32-score.c (s3_bfd_score_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-score7.c (s7_bfd_score_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-sh.c (sh_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-tic6x.c (elf32_tic6x_adjust_dynamic_symbol): Likewise.
    	* elf32-tilepro.c (tilepro_elf_gc_mark_hook): Likewise.
    	(tilepro_elf_adjust_dynamic_symbol): Likewise.
    	* elf32-vax.c (elf_vax_adjust_dynamic_symbol): Likewise.
    	* elf32-xtensa.c (elf_xtensa_adjust_dynamic_symbol): Likewise.
    	* elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Likewise.
    	* elf64-hppa.c (elf64_hppa_adjust_dynamic_symbol): Likewise.
    	* elf64-ia64-vms.c (elf64_ia64_adjust_dynamic_symbol): Likewise.
    	* elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
    	(ppc64_elf_adjust_dynamic_symbol): Likewise.
    	* elf64-s390.c (elf_s390_adjust_dynamic_symbol): Likewise.
    	* elf64-sh64.c (sh64_elf64_adjust_dynamic_symbol): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_adjust_dynamic_symbol): Likewise.
    	* elfnn-ia64.c (elfNN_ia64_adjust_dynamic_symbol): Likewise.
    	* elfnn-riscv.c (riscv_elf_adjust_dynamic_symbol): Likewise.
    	* elfxx-mips.c (_bfd_mips_elf_adjust_dynamic_symbol): Likewise.
    	* elfxx-sparc.c (_bfd_sparc_elf_gc_mark_hook): Likewise.
    	(_bfd_sparc_elf_adjust_dynamic_symbol): Likewise.
    	* elfxx-tilegx.c (tilegx_elf_gc_mark_hook): Likewise.
    	(tilegx_elf_adjust_dynamic_symbol): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_adjust_dynamic_symbol): Likewise.

commit 9d9c67b06c1bf4c4550e3de0eb575c2bfbe96df9
Author: Martin Storsjo <martin@martin.st>
Date:   Thu Nov 23 12:07:24 2017 +0000

    Add libmsvcrt, libmsvcrt-os and libucrtbase to the list of libraries for which the automatic generation of exported variables should be disabled.
    
    In the latest git version of mingw-w64, one can set the default
    libmsvcrt.a to actually be the import library of another CRT version,
    to facilitate switching to ucrtbase.dll. In these versions, the
    traditional libmsvcrt.a (for linking to msvcrt.dll) is also provided
    with the name libmsvcrt-os.a.
    
    The import libraries for the CRT also contain a number of compatibility
    wrapper functions. The ones in libmsvcrt.a have so far been excluded
    automatically since they in most cases come with a corresponding
    __imp_foo function. None of these make sense to export automatically
    from a DLL though, so add these libraries to the exclude list.
    
    libucrtbase.a contains a number of compatibility wrapper functions
    that don't have a corresponding __imp_foo symbol, which cause
    these symbols to be exported from DLLs.
    
    This can be worked around on the mingw-w64 side by adding extra
    __imp_ symbols, but since they aren't strictly necessary for linking
    to succeed, it's probably better long-term to add these libraries to
    the exclusion list.
    
    ld	* pe-dll.c (autofilter_liblist): Add libmsvcrt, libmsvcrt-os and
    	libucrtbase.

commit 65f3ed048fa0741e874c7aa372f9ddba153a2949
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 23 11:04:18 2017 +0100

    x86: fix AVX-512 16-bit addressing
    
    Despite EVEX encodings not being available in real and VM86 modes,
    16-bit addressing still needs to be handled properly for 16-bit
    protected mode as well as 16-bit addressing in 32-bit mode. Neither
    should displacements be dropped silently by the assembler, nor should
    the disassembler fail to correctly scale 8-bit displacements.

commit 43083a502b8d658b8d096111e54afcc73b0215a4
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 23 11:02:30 2017 +0100

    x86-64: always use unsigned 32-bit reloc for 32-bit addressing w/o base reg
    
    Except for %eip-relative addressing, where we don't have a suitable
    relocation type silently wrapping at the 4G boundary, consistently
    force use of R_X86_64_32 (in ELF terms) instead of its sign-extending
    counterpart. This wasn't right in case there was no base register in
    the addressing expression.

commit 9bb129e82f0506fe78d61670ea2b4140388955dd
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 23 11:00:44 2017 +0100

    x86: drop redundant VSIB handling code
    
    The vecsib && !base_reg case is already being handled (in a more correct
    manner) by earlier code.

commit 66f1eba0b7e83f293573ab42bbbe5d7d5c905d91
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 23 10:59:48 2017 +0100

    x86: correct UDn
    
    Make the assembler recognize UD0, supporting only the newer form
    expecting a ModR/M byte.
    
    Make assembler and disassembler properly emit / expect a ModR/M byte for
    UD1.
    
    For the testsuite, as arch-4 already tests all UDn, avoid producing a
    huge delta for other tests using UD2B by making them use UD2 instead.

commit 38bf51134d1a58f155c89f2b1c7bf885c2604ead
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 23 10:57:54 2017 +0100

    x86/Intel: don't report multiple errors for a single insn operand
    
    Multiple errors are more confusing than helpful, as the more generic
    one often implies a sufficiently different adjustment than would
    actually be needed to fix the code. Additionally it makes it more
    cumbersome to add missing error checks, as the testsuite then needs
    extra updating.

commit 9c23b42ffa67b866cd7562c1d8caed70db5d6840
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Nov 13 01:29:39 2017 -0500

    Convert DTrace probe interface to C++ (and perform some cleanups)
    
    This patch converts the DTrace probe
    interface (gdb/dtrace-probe.[ch]) to C++, and also performs some
    cleanups that were on my TODO list for a while.
    
    The main changes were the conversion of 'struct dtrace_probe' to 'class
    dtrace_probe', and a new 'class dtrace_static_probe_ops' to replace the
    use of 'dtrace_probe_ops'.  Both classes implement the virtual methods
    exported by their parents, 'class probe' and 'class static_probe_ops',
    respectively.  I believe it's now a bit simpler to understand the
    logic behind the dtrace-probe interface.
    
    There are several helper functions used to parse parts of a dtrace
    probe, and since they are generic and don't need to know about the
    probe they're working on, I decided to leave them as simple static
    functions (instead of e.g. converting them to class methods).
    
    I've also converted a few uses of "VEC" to "std::vector", which makes
    the code simpler and easier to maintain.  And, as usual, some cleanups
    here and there.
    
    Even though I'm sending a series of patches, they need to be tested
    and committed as a single unit, because of inter-dependencies.  But it
    should be easier to review in separate logical units.
    
    I wasn't able to test these modifications because the current test
    framework for DTrace probes is not working.  See
    <https://sourceware.org/bugzilla/show_bug.cgi?id=22420>.
    
    gdb/ChangeLog:
    2017-11-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
    	(struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
    	<type_str>: Convert to 'std::string'.
    	<expr>: Convert to 'expression_up'.
    	(dtrace_probe_arg_s): Delete type and VEC.
    	(dtrace_probe_enabler_s): Likewise.
    	(struct dtrace_probe): Replace by...
    	(class dtrace_static_probe_ops): ...this and...
    	(class dtrace_probe): ...this.
    	(dtrace_probe_is_linespec): Rename to...
    	(dtrace_static_probe_ops::is_linespec): ...this.  Adjust code
    	to reflect change.
    	(dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
    	Adjust code.  Create new instance of 'dtrace_probe'.
    	(dtrace_build_arg_exprs): Rename to...
    	(dtrace_probe::build_arg_exprs): ...this.  Adjust code to
    	reflect change.
    	(dtrace_get_probes): Rename to...
    	(dtrace_static_probe_ops::get_probes): ...this.  Adjust code
    	to reflect change.
    	(dtrace_get_arg): Rename to...
    	(dtrace_probe::get_arg_by_number): ...this.  Adjust code to
    	reflect change.
    	(dtrace_probe_is_enabled): Rename to...
    	(dtrace_probe::is_enabled): ...this.  Adjust code to reflect
    	change.
    	(dtrace_get_probe_address): Rename to...
    	(dtrace_probe::get_relocated_address): ...this.  Adjust code
    	to reflect change.
    	(dtrace_get_probe_argument_count): Rename to...
    	(dtrace_probe::get_argument_count): ...this.  Adjust code to
    	reflect change.
    	(dtrace_can_evaluate_probe_arguments): Rename to...
    	(dtrace_probe::can_evaluate_arguments): ...this.  Adjust code
    	to reflect change.
    	(dtrace_evaluate_probe_argument): Rename to...
    	(dtrace_probe::evaluate_argument): ...this.  Adjust code to
    	reflect change.
    	(dtrace_compile_to_ax): Rename to...
    	(dtrace_probe::compile_to_ax): ...this.  Adjust code to
    	reflect change.
    	(dtrace_probe_destroy): Delete.
    	(dtrace_type_name): Rename to...
    	(dtrace_static_probe_ops::type_name): ...this.  Adjust code to
    	reflect change.
    	(dtrace_probe::get_static_ops): New method.
    	(dtrace_gen_info_probes_table_header): Rename to...
    	(dtrace_static_probe_ops::gen_info_probes_table_header):
    	...this.  Adjust code to reflect change.
    	(dtrace_gen_info_probes_table_values): Rename to...
    	(dtrace_probe::gen_info_probes_table_values): ...this.  Adjust
    	code to reflect change.
    	(dtrace_enable_probe): Rename to...
    	(dtrace_probe::enable_probe): ...this.  Adjust code to reflect
    	change.
    	(dtrace_disable_probe): Rename to...
    	(dtrace_probe::disable_probe): ...this.  Adjust code to reflect
    	change.
    	(struct probe_ops dtrace_probe_ops): Delete.
    	(info_probes_dtrace_command): Call 'info_probes_for_spops'
    	instead of 'info_probes_for_ops'.
    	(_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
    	of 'all_probe_ops'.

commit 0e9ae10f5f97824067365af4813b843973297573
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Nov 13 01:05:57 2017 -0500

    Convert SystemTap probe interface to C++ (and perform some cleanups)
    
    This patch converts the SystemTap probe
    interface (gdb/stap-probe.[ch]) to C++, and also performs some
    cleanups that were on my TODO list for a while.
    
    The main changes were the conversion of 'struct stap_probe' to 'class
    stap_probe', and a new 'class stap_static_probe_ops' to replace the
    use of 'stap_probe_ops'.  Both classes implement the virtual methods
    exported by their parents, 'class probe' and 'class static_probe_ops',
    respectively.  I believe it's now a bit simpler to understand the
    logic behind the stap-probe interface.
    
    There are several helper functions used to parse parts of a stap
    probe, and since they are generic and don't need to know about the
    probe they're working on, I decided to leave them as simple static
    functions (instead of e.g. converting them to class methods).
    
    I've also converted a few uses of "VEC" to "std::vector", which makes
    the code simpler and easier to maintain.  And, as usual, some cleanups
    here and there.
    
    Even though I'm sending a series of patches, they need to be tested
    and committed as a single unit, because of inter-dependencies.  But it
    should be easier to review in separate logical units.
    
    I've regtested this patch on BuildBot, no regressions found.
    
    gdb/ChangeLog:
    2017-11-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    	    Simon Marchi  <simark@simark.ca>
    
    	* stap-probe.c (struct probe_ops stap_probe_ops): Delete
    	variable.
    	(struct stap_probe_arg) <stap_probe_arg>: New constructor.
    	<aexpr>: Change type to 'expression_up'.
    	(stap_probe_arg_s): Delete type and VEC.
    	(struct stap_probe): Delete.  Replace by...
    	(class stap_static_probe_ops): ...this and...
    	(class stap_probe): ...this.  Rename variables to add 'm_'
    	prefix.  Do not use 'union' for arguments anymore.
    	(stap_get_expected_argument_type): Receive probe name instead
    	of 'struct stap_probe'.  Adjust code.
    	(stap_parse_probe_arguments): Rename to...
    	(stap_probe::parse_arguments): ...this.  Adjust code to
    	reflect change.
    	(stap_get_probe_address): Rename to...
    	(stap_probe::get_relocated_address): ...this.  Adjust code
    	to reflect change.
    	(stap_get_probe_argument_count): Rename to...
    	(stap_probe::get_argument_count): ...this.  Adjust code
    	to reflect change.
    	(stap_get_arg): Rename to...
    	(stap_probe::get_arg_by_number'): ...this. Adjust code to
    	reflect change.
    	(can_evaluate_probe_arguments): Rename to...
    	(stap_probe::can_evaluate_arguments): ...this.  Adjust code
    	to reflect change.
    	(stap_evaluate_probe_argument): Rename to...
    	(stap_probe::evaluate_argument): ...this.  Adjust code
    	to reflect change.
    	(stap_compile_to_ax): Rename to...
    	(stap_probe::compile_to_ax): ...this.  Adjust code to
    	reflect change.
    	(stap_probe_destroy): Delete.
    	(stap_modify_semaphore): Adjust comment.
    	(stap_set_semaphore): Rename to...
    	(stap_probe::set_semaphore): ...this.  Adjust code to reflect
    	change.
    	(stap_clear_semaphore): Rename to...
    	(stap_probe::clear_semaphore): ...this.  Adjust code to
    	reflect	change.
    	(stap_probe::get_static_ops): New method.
    	(handle_stap_probe): Adjust code to create instance of
    	'stap_probe'.
    	(stap_get_probes): Rename to...
    	(stap_static_probe_ops::get_probes): ...this.  Adjust code to
    	reflect change.
    	(stap_probe_is_linespec): Rename to...
    	(stap_static_probe_ops::is_linespec): ...this.  Adjust code to
    	reflect change.
    	(stap_type_name): Rename to...
    	(stap_static_probe_ops::type_name): ...this.  Adjust code to
    	reflect change.
    	(stap_gen_info_probes_table_header): Rename to...
    	(stap_static_probe_ops::gen_info_probes_table_header):
    	...this.  Adjust code to reflect change.
    	(stap_gen_info_probes_table_values): Rename to...
    	(stap_probe::gen_info_probes_table_values): ...this.  Adjust
    	code to reflect change.
    	(struct probe_ops stap_probe_ops): Delete.
    	(info_probes_stap_command): Use 'info_probes_for_spops'
    	instead of 'info_probes_for_ops'.
    	(_initialize_stap_probe): Use 'all_static_probe_ops' instead
    	of 'all_probe_ops'.

commit 935676c92feb5f35e4634ef58c20ffdfd0979b07
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Nov 13 00:28:24 2017 -0500

    Convert generic probe interface to C++ (and perform some cleanups)
    
    This patch converts the generic probe interface (gdb/probe.[ch]) to
    C++, and also performs some cleanups that were on my TODO list for a
    while.
    
    The main changes were the conversion of 'struct probe' to 'class
    probe', and 'struct probe_ops' to 'class static_probe_ops'.  The
    former now contains all the "dynamic", generic methods that act on a
    probe + the generic data related to it; the latter encapsulates a
    bunch of "static" methods that relate to the probe type, but not to a
    specific probe itself.
    
    I've had to do a few renamings (e.g., on 'struct bound_probe' the
    field is called 'probe *prob' now, instead of 'struct probe *probe')
    because GCC was complaining about naming the field using the same name
    as the class.  Nothing major, though.  Generally speaking, the logic
    behind and the design behind the code are the same.
    
    Even though I'm sending a series of patches, they need to be tested
    and committed as a single unit, because of inter-dependencies.  But it
    should be easier to review in separate logical units.
    
    I've regtested this patch on BuildBot, no regressions found.
    
    gdb/ChangeLog:
    2017-11-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* break-catch-throw.c (fetch_probe_arguments): Use
    	'probe.prob' instead of 'probe.probe'.
    	* breakpoint.c (create_longjmp_master_breakpoint): Call
    	'can_evaluate_arguments' and 'get_relocated_address' methods
    	from probe.
    	(create_exception_master_breakpoint): Likewise.
    	(add_location_to_breakpoint): Use 'sal->prob' instead of
    	'sal->probe'.
    	(bkpt_probe_insert_location): Call 'set_semaphore' method from
    	probe.
    	(bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
    	* elfread.c (elf_get_probes): Use 'static_probe_ops' instead
    	of 'probe_ops'.
    	(probe_key_free): Call 'delete' on probe.
    	(check_exception_resume): Use 'probe.prob' instead of
    	'probe.probe'.
    	* location.c (string_to_event_location_basic): Call
    	'probe_linespec_to_static_ops'.
    	* probe.c (class any_static_probe_ops): New class.
    	(any_static_probe_ops any_static_probe_ops): New variable.
    	(parse_probes_in_pspace): Receive 'static_probe_ops' as
    	argument.  Adjust code to reflect change.
    	(parse_probes): Use 'static_probe_ops' instead of
    	'probe_ops'.  Adjust code to reflect change.
    	(find_probes_in_objfile): Call methods to get name and
    	provider from probe.
    	(find_probe_by_pc): Use 'result.prob' instead of
    	'result.probe'.  Call 'get_relocated_address' method from
    	probe.
    	(collect_probes): Adjust comment and argument list to receive
    	'static_probe_ops' instead of 'probe_ops'.  Adjust code to
    	reflect change.  Call necessary methods from probe.
    	(compare_probes): Call methods to get name and provider from
    	probes.
    	(gen_ui_out_table_header_info): Receive 'static_probe_ops'
    	instead of 'probe_ops'.  Use 'std::vector' instead of VEC,
    	adjust code accordingly.
    	(print_ui_out_not_applicables): Likewise.
    	(info_probes_for_ops): Rename to...
    	(info_probes_for_spops): ...this.  Receive 'static_probe_ops'
    	as argument instead of 'probe_ops'.  Adjust code.  Call
    	necessary methods from probe.
    	(info_probes_command): Use 'info_probes_for_spops'.
    	(enable_probes_command): Pass correct argument to
    	'collect_probes'.  Call methods from probe.
    	(disable_probes_command): Likewise.
    	(get_probe_address): Move to 'any_static_probe_ops::get_address'.
    	(get_probe_argument_count): Move to
    	'any_static_probe_ops::get_argument_count'.
    	(can_evaluate_probe_arguments): Move to
    	'any_static_probe_ops::can_evaluate_arguments'.
    	(evaluate_probe_argument): Move to
    	'any_static_probe_ops::evaluate_argument'.
    	(probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
    	'probe.probe'.
    	(probe_linespec_to_ops): Rename to...
    	(probe_linespec_to_static_ops): ...this.  Adjust code.
    	(probe_any_is_linespec): Rename to...
    	(any_static_probe_ops::is_linespec): ...this.
    	(probe_any_get_probes): Rename to...
    	(any_static_probe_ops::get_probes): ...this.
    	(any_static_probe_ops::type_name): New method.
    	(any_static_probe_ops::gen_info_probes_table_header): New
    	method.
    	(compute_probe_arg): Use 'pc_probe.prob' instead of
    	'pc_probe.probe'.  Call methods from probe.
    	(compile_probe_arg): Likewise.
    	(std::vector<const probe_ops *> all_probe_ops): Delete.
    	(std::vector<const static_probe_ops *> all_static_probe_ops):
    	New variable.
    	(_initialize_probe): Use 'all_static_probe_ops' instead of
    	'all_probe_ops'.
    	* probe.h (struct info_probe_column) <field_name>: Delete
    	extraneous newline
    	(info_probe_column_s): Delete type and VEC.
    	(struct probe_ops): Delete.  Replace with...
    	(class static_probe_ops): ...this and...
    	(clas probe): ...this.
    	(struct bound_probe) <bound_probe>: Delete extraneous
    	newline.  Adjust constructor to receive 'probe' instead of
    	'struct probe'.
    	<probe>: Rename to...
    	<prob>: ...this.  Delete extraneous newline.
    	<objfile>: Delete extraneous newline.
    	(register_probe_ops): Delete unused prototype.
    	(info_probes_for_ops): Rename to...
    	(info_probes_for_spops): ...this.  Adjust comment.
    	(get_probe_address): Move to 'probe::get_address'.
    	(get_probe_argument_count): Move to
    	'probe::get_argument_count'.
    	(can_evaluate_probe_arguments): Move to
    	'probe::can_evaluate_arguments'.
    	(evaluate_probe_argument): Move to 'probe::evaluate_argument'.
    	* solib-svr4.c (struct svr4_info): Adjust comment.
    	(struct probe_and_action) <probe>: Rename to...
    	<prob>: ...this.
    	(register_solib_event_probe): Receive 'probe' instead of
    	'struct probe' as argument.  Use 'prob' instead of 'probe'
    	when applicable.
    	(solib_event_probe_action): Call 'get_argument_count' method
    	from probe.  Adjust comment.
    	(svr4_handle_solib_event): Adjust comment.  Call
    	'evaluate_argument' method from probe.
    	(svr4_create_probe_breakpoints): Call 'get_relocated_address'
    	from probe.
    	(svr4_create_solib_event_breakpoints): Use 'probe' instead of
    	'struct probe'.  Call 'can_evaluate_arguments' from probe.
    	* symfile.h: Forward declare 'class probe' instead of 'struct
    	probe'.
    	* symtab.h: Likewise.
    	(struct symtab_and_line) <probe>: Rename to...
    	<prob>: ...this.
    	* tracepoint.c (start_tracing): Use 'prob' when applicable.
    	Call probe methods.
    	(stop_tracing): Likewise.

commit 88108bf28c4a726af84dfec2f85b8404cc2ac0bd
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 23 00:00:27 2017 +0000

    Automatic date update in version.in

commit 8f6cb6c33815f38b41e1e93e59f12869db07c070
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Nov 22 14:30:41 2017 -0800

    (Ada) ravenscar-thread.c: remove unwanted trailing \n in call to warning
    
    A recent patch introduced a call to warning, and the string used
    had a trailing newline, which is not correct; the nightly ARI run
    caught it, so this patch removes it.
    
    gdb/ChangeLog:
    
            * ravenscar-thread.c (ravenscar_inferior_created): Remove
            trailing newline at end of string in call to warning.
    
    Tested on powerpc-eabispe, no regression.

commit 479f8de1b3b7e69ca8d557bbe9d843c7d1bc89c5
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Wed Nov 22 16:12:06 2017 -0500

    C++ify osdata
    
    This patch c++ifies the osdata structure: osdata_column, osdata_item and
    osdata.  char* are replaced with std::string and VEC are replaced with
    std::vector.  This allows to get rid of a great deal of cleanup and
    free'ing code.
    
    I replaced the splay tree in list_available_thread_groups with an
    std::map.  Unless there's a good advantage to keep using a splay tree,
    I think using the standard type should make things simpler to
    understand.
    
    gdb/ChangeLog:
    
    	* osdata.h: Include vector isntead of vec.h.
    	(osdata_column_s): Remove typedef.
    	(struct osdata_column): Add constructor.
    	<name, value>: Change type to std::string.
    	(DEF_VEC_O (osdata_column_s)): Remove.
    	(osdata_item_s): Remove typedef.
    	(struct osdata_item) <columns>: Change type to std::vector.
    	(DEF_VEC_O (osdata_item_s)): Remove.
    	(struct osdata): Add constructor.
    	<type>: Change type to std::string.
    	<items>: Change type to std::vector.
    	(osdata_p): Remove typedef.
    	(DEF_VEC_P (osdata_p)): Remove.
    	(osdata_parse): Return a unique_ptr.
    	(osdata_free): Remove.
    	(make_cleanup_osdata_free): Remove.
    	(get_osdata): Return a unique_ptr.
    	(get_osdata_column): Return pointer to std::string, take a
    	reference to osdata_item as parameter.
    	* osdata.c (struct osdata_parsing_data) <osdata>: Change type to
    	unique_ptr.
    	<property_name>: Change type to std::string.
    	(osdata_start_osdata): Allocate osdata with new and adjust.
    	(osdata_start_item): Adjust.
    	(osdata_start_column): Adjust.
    	(osdata_end_column): Adjust.
    	(clear_parsing_data): Remove.
    	(osdata_parse): Return a unique_ptr and adjust, remove cleanup.
    	(osdata_item_clear): Remove.
    	(get_osdata): return a unique_ptr and adjust.
    	(get_osdata_column): Return a pointer to std::string and adjust.
    	(info_osdata): Adjust.
    	* mi/mi-main.c: Include <map>.
    	(free_vector_of_osdata_items): Remove.
    	(list_available_thread_groups): Adjust, use std::map instead of
    	splay tree.

commit 41bd68f52c05f5654bed49f312f6562c8d048897
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Nov 22 15:51:44 2017 -0500

    Show optimized out local variables in "info locals"
    
    Currently, optimized out variables are not shown when doing "info
    locals".  Some users found that confusing, thinking GDB forgot to print
    their variable.  This patch adds them to the "info locals" output.  I
    added a test in gdb.dwarf2 to test for that behavior.  I think doing a
    synthetic DWARF test is the easiest way to have an optimized out local
    variable for sure.
    
    However, this change reveals what I think is a bug in GDB, see:
    
    http://lists.dwarfstd.org/pipermail/dwarf-discuss-dwarfstd.org/2017-September/004394.html
    
    This patch marks the tests in inline-locals.exp that start failing as
    KFAIL.  I'd like to tackle this bug eventually, but I don't have the
    time right now.  I think it's still better to show an extra erroneous
    entry than to not show the optimized out variables at all.  I haven't
    created a bug in bugzilla yet, but if we agree it's indeed a bug,  I'll
    create one and update the setup_kfail lines with the actual bug number
    before pushing.
    
    gdb/ChangeLog:
    
    	* stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
    	case in switch.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.opt/inline-locals.exp: Mark tests as KFAIL.
    	* gdb.dwarf2/info-locals-optimized-out.exp: New file.
    	* gdb.dwarf2/info-locals-optimized-out.c: New file.

commit 7e2fd2f47b37185505f68e45c5cf016c7a16e1ce
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Wed Nov 22 15:08:07 2017 -0500

    Remove DEF_VEC_P (varobj_p)
    
    The last patch removed the last usage of this type, so we can remove it.
    
    gdb/ChangeLog:
    
    	* varobj.h (DEF_VEC_P (varobj_p)): Remove.

commit 0604393c22f626f26b5a4a30e57da40404f5aa5e
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Wed Nov 22 15:08:06 2017 -0500

    Replace VEC (varobj_update_result) with std::vector
    
    This patch replaces makes varobj_update return an std::vector, and
    updates the fallouts.
    
    To make that easier, the varobj_update_result is c++ified a bit.  I
    added a constructor and initialized its fields in-class.  The newobj
    vector is also made an std::vector, so that it's automatically freed
    when varobj_update_result is destroyed and handled correctly by the
    default move constructor.  I disabled copy constructor and assignment
    for that structure, because normally it never needs to be copied, only
    moved.
    
    As a result, the newobj parameter of update_dynamic_varobj_children must
    be changed to an std::vector.  The patch converts the other vector
    parameters of update_dynamic_varobj_children to std::vector.  It's not
    strictly necessary to do it in the same patch, but I think it makes
    sense to do it.
    
    gdb/ChangeLog:
    
    	* varobj.h (struct varobj_update_result): Add constructor, add
    	move constructor, disable copy and assign, initialize fields.
    	<newobj>: Change type to std::vector.
    	(varobj_update): Return std::vector.
    	* varobj.c (install_dynamic_child): Change VEC parameters to
    	std::vector and adjust.
    	(update_dynamic_varobj_children): Likewise.
    	(varobj_update): Return std::vector and adjust.
    	* mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.

commit ddf0ea085b626ddcbb14f88f495bcb677b7ab6e9
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Wed Nov 22 15:08:06 2017 -0500

    Make varobj::children an std::vector
    
    This patch makes the children field of varobj an std::vector, and
    updates the fallout.
    
    One note is that varobj::parent must be made non-const.  The reason is
    that when a child deletes itself, it modifies its writes NULL to its
    slot in its parent's children vector.  With the VEC, the const didn't
    made the parent's children vector content const, only the pointer to it,
    but with std::vector, even the content is.
    
    gdb/ChangeLog:
    
    	* varobj.h (struct varobj) <parent>: Remove const.
    	<children>: Change type to std::vector.
    	(varobj_list_children): Return std::vector const reference.
    	(varobj_restrict_range): Change parameter type to std::vector
    	const reference.
    	* varobj.c (varobj_has_more): Adjust.
    	(varobj_restrict_range): Change parameter type to std::vector
    	const reference and adjust.
    	(install_dynamic_child): Adjust.
    	(update_dynamic_varobj_children): Adjust.
    	(varobj_list_children): Return std::vector const reference and
    	adjust.
    	(varobj_add_child): Adjust.
    	(update_type_if_necessary): Adjust.
    	(varobj_update): Adjust.
    	(delete_variable_1): Adjust.
    	* ada-varobj.c (ada_value_has_mutated): Adjust.
    	* mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.

commit 9e5b9d2b295d1771647a9e4bc942e398142ccf9b
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Wed Nov 22 15:08:05 2017 -0500

    Basic c++ification of varobj
    
    This patch does a basic c++ification or the varobj data structure.
    
      - varobj: add constructor and destructor, initialize fields
      - varobj_root: initialize fields
      - varobj_dynamic: initialize fields
    
    This allows getting rid of new_variable, new_root_variable.
    free_variable essentially becomes varobj's destructor.  This also allows
    getting rid of a cleanup, make_cleanup_free_variable, which was only
    used in varobj_create in case the varobj creation fails.  It is replaced
    with a unique_ptr.
    
    gdb/ChangeLog:
    
    	* varobj.h (struct varobj): Add constructor and destructor,
    	initialize fields.
    	* varobj.c (struct varobj_root): Initialize fields.
    	(struct varobj_dynamic): Initialize fields.
    	(varobj_create): Use unique_ptr instead of cleanup.  Create
    	varobj with new instead of new_root_variable.
    	(delete_variable_1): Free variable with delete instead of
    	free_variable.
    	(create_child_with_value): Create variable with new instead of
    	new_variable.
    	(varobj::varobj): New.
    	(varobj::~varobj): New (body mostly coming from free_variable).
    	(new_variable): Remove.
    	(free_variable): Remove.
    	(do_free_variable_cleanup): Remove.
    	(make_cleanup_free_variable): Remove.

commit 2469b3c58447e98e073ffe7ab6c9627dbbd1aa81
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Nov 22 11:20:48 2017 -0800

    Riscv ld-elf/stab failure and fake label cleanup.
    
    	* as.c: Include write.h.
    	(common_emul_init): Use FAKE_LABEL_NAME.
    	* ecoff.c (add_file, ecoff_directive_end, ecoff_directive_loc):
    	Likewise.
    	(ecoff_build_symbols): Use FAKE_LABEL_CHAR.
    	* expr.c (get_symbol_name): Use FAKE_LABEL_CHAR.  Accept only if
    	input_from_string is TRUE.
    	* read.c (input_from_string): New.
    	(read_symbol_name): Use FAKE_LABEL_CHAR.  Accept only if
    	input_from_string is TRUE.
    	(temp_ilp): Set input_from_string to TRUE.
    	(restore_ilp): Set input_from_string to FALSE.
    	* read.h (input_from_string): Declare.
    	* symbols.c: Include write.h
    	(S_IS_LOCAL): Check for FAKE_LABEL_CHAR.
    	(symbol_relc_make_sym): Fix comment refering to default fake label
    	string.
    	* write.h (FAKE_LABEL_CHAR): New.
    	* config/tc-riscv.h (FAKE_LABEL_CHAR): Define.
    	* testsuite/gas/all/err-fakelabel.s: New.

commit 2ca23e65f562bd0efa7c483a99b49cc3d5118a58
Author: Jim Wilson <jimw@sifive.com>
Date:   Wed Nov 22 11:09:30 2017 -0800

    Update docs on filling text with nops.
    
    	gas/
    	* doc/as.texinfo (.align): Change some to most for text nop fill.
    	(.balign, .p2align): Likewise.

commit fc35dab1a62541858cab1c82aebc6cd166e39f5b
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Nov 22 19:57:05 2017 +0100

    Remove obsolete core-regset.c
    
    The last target that used core-regset.c (FreeBSD/alpha) has been
    removed with GDB 8.0, and since then this file is obsolete.

commit 1daad298d699383bb4f35aa919a1acfa0ab8e16c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 22 16:50:53 2017 +0000

    [testsuite] Pass pthreads in prepare_for_testing
    
    "pthreads" in the right flag to pass in prepare_for_testing to linker,
    instead of additional_flags.  Without this patch, the test case can't be
    complied by clang.
    
    gdb compile failed, clang: warning: -lpthread: 'linker' input unused
    
    gdb/testsuite:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.base/info-os.exp: Pass pthreads.
    	* gdb.multi/multi-attach.exp: Likewise.

commit 88465e872cb6649c42863e5c47011bae9e17bbdb
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 22 14:46:30 2017 +0000

    [testsuite] Don't skip gdb.dwarf2/pr10770.exp for non-gcc compiler
    
    gdb.dwarf2/pr10770.exp can be used for non-gcc compiler, at least clang.
    This patch removes the restriction to only use gcc.  If other compilers,
    like xlc or icc, can't compile the .c file, test result is not changed.
    
    gdb/testsuite:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.dwarf2/pr10770.exp: Remove code skipping non-gcc
    	compiler.

commit 94b98370de3ee157e039f26865390b5994c47c3b
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Mon Nov 20 19:23:28 2017 +0300

    Remove Vec_Disp8 field for vgf2p8mulb for AVX flavor.
    
    	* i386-opc.tbl: Remove Vec_Disp8 from vgf2p8mulb.
    	* i386-tbl.h: Regenerate.

commit dc196b230b7366683799755b4461acef5cc95be7
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 22 14:35:01 2017 +0000

    [testsuite] Pass -pie in ldflags
    
    -pie is a linker flag, it should be passed via "ldflags", instead
    of "additional_flags".  Otherwise, clang complains,
    
    clang: warning: argument unused during compilation: '-pie'
    
    gdb/testsuite:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.base/attach-pie-noexec.exp: Pass "-pie" in ldflags.
    	* gdb.base/break-interp.exp: Likewise.
    	* gdb.base/jit-attach-pie.exp: Likewise.

commit 6f19e86dac3a191945b5eb08ae767deced660a00
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Wed Nov 22 17:23:38 2017 +0300

    Update ChangeLog

commit c7478d028e8829402b05478f571eb5e1916c63d3
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Mon Nov 20 19:14:32 2017 +0300

    Remove Vec_Disp8 from vpcompressb and vpexpandb.
    
    	* i386-opc.tbl: Remove Vec_Disp8 from vpcompressb and vpexpandb.
    	* i386-tbl.h: Regenerate.

commit 5aa75429d0531ac6cfe59efd80f1ab01311865b3
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Wed Nov 22 14:02:49 2017 +0000

    [GAS/ARM] Clarify relation between reg_expected_msgs and arm_reg_type
    
    Uses of reg_expected_msgs rely on each arm_reg_type enumerator to have a
    message entry in the same order as the enumerator declaration. This is
    not clearly stated in the definition of both the arm_reg_type enum and
    the reg_expected_msgs. Worse, there is nothing to ensure both are kept
    in sync.
    
    As an attempt towards this, this patch uses C99 array designators to
    ensure that each message is associated with the right arm_reg_type. A
    comment is also added near the definition of arm_reg_type to point to
    the reg_expected_msgs array. Finally, the array is synced with
    arm_reg_type by adding the missing error message for REG_TYPE_RNB.
    
    2017-11-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gas/
    	* config/tc-arm.c (arm_reg_type): Comment on the link with
    	reg_expected_msgs.
    	(reg_expected_msgs): Initialize using array designators with
    	arm_reg_type index.

commit 2400729ecfd2c7be8b18aeaa822fef5a4b503f8a
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Nov 22 13:53:43 2017 +0100

    Target FP: Make use of MPFR if available
    
    This second patch introduces mfpr_float_ops, an new implementation
    of target_float_ops.  This implements precise emulation of target
    floating-point formats using the MPFR library.  This is then used
    to perform operations on types that do not match any host type.
    
    Note that use of MPFR is still not required.  The patch adds
    a configure option --with-mpfr similar to --with-expat.  If use of
    MPFR is disabled via the option or MPFR is not available, code will
    fall back to current behavior.  This means that operations on types
    that do not match any host type will be implemented on the host
    long double type instead.
    
    A new test case verifies that we can correctly print the largest
    __float128 value now.
    
    gdb/ChangeLog:
    2017-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* NEWS: Document use of GNU MPFR.
    	* README: Likewise.
    
    	* Makefile.in (LIBMPFR): Add define.
    	(CLIBS): Add $(LIBMPFR).
    	* configure.ac: Add --with-mpfr configure option.
    	* configure: Regenerate.
    	* config.in: Regenerate.
    
    	* target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
    	(class mpfr_float_ops): New type.
    	(mpfr_float_ops::from_target): Two new overloaded functions.
    	(mpfr_float_ops::to_target): Likewise.
    	(mpfr_float_ops::to_string): New function.
    	(mpfr_float_ops::from_string): Likewise.
    	(mpfr_float_ops::to_longest): Likewise.
    	(mpfr_float_ops::from_longest): Likewise.
    	(mpfr_float_ops::from_ulongest): Likewise.
    	(mpfr_float_ops::to_host_double): Likewise.
    	(mpfr_float_ops::from_host_double): Likewise.
    	(mpfr_float_ops::convert): Likewise.
    	(mpfr_float_ops::binop): Likewise.
    	(mpfr_float_ops::compare): Likewise.
    	(get_target_float_ops): Use mpfr_float_ops if available.
    
    gdb/doc/ChangeLog:
    2017-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.texinfo (Requirements): Document use of GNU MPFR.
    
    gdb/testsuite/ChangeLog:
    2017-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.base/float128.c (large128): New variable.
    	* gdb.base/float128.exp: Add test to print largest __float128 value.

commit 7a26362d360ee34de1e8e927bd7159860fe8354b
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Nov 22 13:51:49 2017 +0100

    Target FP: Refactor use of host floating-point arithmetic
    
    Prepare for using MPFR to implement floating-point arithmetic by
    refactoring the way host floating-point arithmetic is currently used.
    
    In particular, fix the following two problems that cause different
    (and incorrect) results due to using host arithmetic:
    
    - Current processing always uses host "long double", and then converts
      back to the actual target format.  This may introduce rounding errors.
    
    - Conversion of FP values to LONGEST simply does a host C++ type cast.
      However the result of such a cast is undefined if the source value
      is outside the representable range.  MPFR always has defined behavior
      here (returns the minimum or maximum representable value).
    
    To fix the first issue, I've now created not just one set of routines
    using host FP arithmetic (on long double), but instead three different
    sets of routines, one each for host float, double, and long double.
    Operations can then be performed in the desired type directly, avoiding
    the extra rounding step.  Using C++ templates, the three sets can all
    share the same source code without duplication.
    
    To fix the second issue, I'm simply enforcing the same conversion rule
    (which makes sense anyway) when converting out-of-range values from
    FP to LONGEST.
    
    To contain the code complexity with the variety of options now possible,
    I've created a new class "target_float_ops".  There are a total of five
    separate implementations of this:
    
      host_float_ops<float>        Implemented via host FP in given type
      host_float_ops<double>
      host_float_ops<long double>
      mpfr_float_ops               Implemented via MPFR if available
      decimal_float_ops            Implemented via libdecnumber
    
    Note instead of using the DOUBLEST define, this always just uses the
    "long double" data type.  But since we now require C++11 anyway, this
    type must in any case be avaialble unconditionally.
    
    Most target floating-point operations simply dispatch to a (virtual)
    member routine of this class.  Which implementation to choose is
    determined from the target types involved, and whether they match
    some host type or not.  E.g. any operation on a single type that
    matches a host type is performed in that type.  Operations involving
    two types that both match host types are performed in the larger one
    (according to C/C++ implicit conversion rules).  Operations that
    involve any type that does not match a host type are performed using
    MPFR.  (And of course operations involving decimal FP are performed
    using libdecnumber.)
    
    This first patch implements the refactoring of target-float.c as
    described above, introduing the host_float_ops and decimal_float_ops
    classes, and using them.  Use of MPFR is introduced in the second patch.
    A bit of special-case handling code is moved around to as to avoid
    code duplication between host_float_ops and mpfr_float_ops.
    
    Note that due to the changes mentioned above, I've had to update (fix)
    the floating-point register values tested in the gdb.arch/vsx-regs.exp
    test case.  (The new values now work both with host arithmetic and MPFR.)
    
    gdb/ChangeLog:
    2017-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c: Do not include <math.h>.
    	Include <cmath> and <limits>.
    	(DOUBLEST): Do not define.
    	(class target_float_ops): New type.
    	(class host_float_ops): New templated type.
    	(class decimal_float_ops): New type.
    
    	(floatformat_to_doublest): Rename to ...
    	(host_float_ops<T>::from_target): ... this.  Use template type T
    	instead of DOUBLEST.  Use C++ math routines.  Update recursive calls.
    	(host_float_ops<T>::from_target): New overload using a type argument.
    	(floatformat_from_doublest): Rename to ...
    	(host_float_ops<T>::to_target): ... this.  Use template type T
    	instead of DOUBLEST.  Use C++ math routines.  Update recursive calls.
    	(host_float_ops<T>::to_target): New overload using a type argument.
    	(floatformat_printf_format): New function.
    	(struct printf_length_modifier): New templated type.
    	(floatformat_to_string): Rename to ...
    	(host_float_ops<T>::to_string): ... this.  Use type instead of
    	floatformat argument.  Use floatformat_printf_format and
    	printf_length_modifier.  Remove special handling of invalid numbers,
    	infinities and NaN (moved to target_float_to_string).
    	(struct scanf_length_modifier): New templated type.
    	(floatformat_from_string): Rename to ...
    	(host_float_ops<T>::from_string): ... this.  Use type instead of
    	floatformat argument.  Use scanf_length_modifier.
    	(floatformat_to_longest): Rename to ...
    	(host_float_ops<T>::to_longest): ... this.  Use type instead of
    	floatformat argument.  Handle out-of-range values deterministically.
    	(floatformat_from_longest): Rename to ...
    	(host_float_ops<T>::from_longest): ... this.  Use type instead of
    	floatformat argument.
    	(floatformat_from_ulongest): Rename to ...
    	(host_float_ops<T>::from_ulongest): ... this.  Use type instead of
    	floatformat argument.
    	(floatformat_to_host_double): Rename to ...
    	(host_float_ops<T>::to_host_double): ... this.  Use type instead of
    	floatformat argument.
    	(floatformat_from_host_double): Rename to ...
    	(host_float_ops<T>::from_host_double): ... this.  Use type instead of
    	floatformat argument.
    	(floatformat_convert): Rename to ...
    	(host_float_ops<T>::convert): ... this.  Use type instead of
    	floatformat arguments.  Remove handling of no-op conversions.
    	(floatformat_binop): Rename to ...
    	(host_float_ops<T>::binop): ... this.  Use type instead of
    	floatformat arguments.
    	(floatformat_compare): Rename to ...
    	(host_float_ops<T>::compare): ... this.  Use type instead of
    	floatformat arguments.
    
    	(match_endianness): Use type instead of length/byte_order arguments.
    	(set_decnumber_context): Likewise.
    	(decimal_from_number): Likewise.  Update calls.
    	(decimal_to_number): Likewise.
    	(decimal_is_zero): Likewise.  Update calls.  Move to earlier in file.
    	(decimal_float_ops::to_host_double): New dummy function.
    	(decimal_float_ops::from_host_double): Likewise.
    	(decimal_to_string): Rename to ...
    	(decimal_float_ops::to_string): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_from_string): Rename to ...
    	(decimal_float_ops::from_string): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_from_longest): Rename to ...
    	(decimal_float_ops::from_longest): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_from_ulongest): Rename to ...
    	(decimal_float_ops::from_ulongest): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_to_longest): Rename to ...
    	(decimal_float_ops::to_longest): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_binop): Rename to ...
    	(decimal_float_ops::binop): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_compare): Rename to ...
    	(decimal_float_ops::compare): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    	(decimal_convert): Rename to ...
    	(decimal_float_ops::convert): ... this.  Use type instead of
    	length/byte_order arguments.  Update calls.
    
    	(target_float_same_category_p): New function.
    	(target_float_same_format_p): Likewise.
    	(target_float_format_length): Likewise.
    	(enum target_float_ops_kind): New type.
    	(get_target_float_ops_kind): New function.
    	(get_target_float_ops): Three new overloaded functions.
    
    	(target_float_is_zero): Update call.
    	(target_float_to_string): Add special handling of invalid numbers,
    	infinities and NaN (moved from floatformat_to_string).  Use
    	target_float_ops callback.
    	(target_float_from_string): Use target_float_ops callback.
    	(target_float_to_longest): Likewise.
    	(target_float_from_longest): Likewise.
    	(target_float_from_ulongest): Likewise.
    	(target_float_to_host_double): Likewise.
    	(target_float_from_host_double): Likewise.
    	(target_float_convert): Add special case for no-op conversions.
    	Use target_float_ops callback.
    	(target_float_binop): Use target_float_ops callback.
    	(target_float_compare): Likewise.
    
    gdb/testsuite/ChangeLog:
    2017-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.arch/vsx-regs.exp: Update register content checks.

commit a9f26f609e3a1b6ae3aab300b55442e0a81e2bce
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 22 12:22:11 2017 +0000

    Fix build with GCC 8: strncpy ->strcpy
    
    Recent gcc 8 trunk emits the warning below,
    
    ../../binutils-gdb/gdb/python/py-gdb-readline.c:79:15: error: â??char* strncpy(char*, const char*, size_t)â?? output truncated before terminating nul copying as many bytes from a string as its length [-Werror=stringop-truncation]
           strncpy (q, p, n);
           ~~~~~~~~^~~~~~~~~
    ../../binutils-gdb/gdb/python/py-gdb-readline.c:73:14: note: length computed here
       n = strlen (p);
           ~~~~~~~^~~
    
    gdb:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.

commit 29f9a5673764c1b2711c0ceeba380a6ee764d1b2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 22 12:22:11 2017 +0000

    Fix build with GCC 8: strncpy -> memcpy
    
    Recent gcc 8 trunk emits the warning below,
    
    ../../../binutils-gdb/gdb/gdbserver/remote-utils.c:1204:14: error: â??char* strncpy(char*, const char*, size_t)â?? output truncated before terminating nul copying 6 bytes from a string of the same length [-Werror=stringop-truncation]
          strncpy (buf, "watch:", 6);
          ~~~~~~~~^~~~~~~~~~~~~~~~~~
    
    ../../binutils-gdb/gdb/cli/cli-decode.c:1118:15: error: â??char* strncpy(char*, const char*, size_t)â?? specified bound depends on the length of the source argument [-Werror=stringop-overflow=]
           strncpy (cmdtype1 + 1, cmdtype, len - 1);
           ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../binutils-gdb/gdb/cli/cli-decode.c:1110:16: note: length computed here
       len = strlen (cmdtype);
             ~~~~~~~^~~~~~~~~
    ../../binutils-gdb/gdb/cli/cli-decode.c:1120:15: error: â??char* strncpy(char*, const char*, size_t)â?? specified bound depends on the length of the source argument [-Werror=stringop-overflow=]
           strncpy (cmdtype2, cmdtype, len - 1);
           ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../binutils-gdb/gdb/cli/cli-decode.c:1110:16: note: length computed here
       len = strlen (cmdtype);
             ~~~~~~~^~~~~~~~~
    
    ../../binutils-gdb/gdb/cp-namespace.c:1071:11: error: â??char* strncpy(char*, const char*, size_t)â?? output truncated before terminating nul copying 2 bytes from a string of the same length [-Werror=stringop-truncation]
       strncpy (full_name + scope_length, "::", 2);
       ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
    This patch fixes it by using memcpy instead of strncpy.
    
    gdb:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
    	* cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
    
    gdb/gdbserver:
    
    2017-11-22  Yao Qi  <yao.qi@linaro.org>
    
    	* remote-utils.c (prepare_resume_reply): Use memcpy.

commit dc958481429708ecf91f9b2c445063d43397f07e
Author: claziss <claziss@synopsys.com>
Date:   Wed Nov 22 10:46:45 2017 +0100

    [ARC] Fix handling of ARCv2 H-register class.
    
    For ARCv2, h-regs are only valid unitl r31.
    
    gas/
    2017-11-21  Claudiu Zissulescu <claziss@synopsys.com>
    
            * testsuite/gas/arc/hregs-err.s: New test.
    
    opcodes/
    2017-11-21  Claudiu Zissulescu <claziss@synopsys.com>
    
            * arc-opc.c (insert_rhv2): Check h-regs range.

commit 0ad71725d917c51b46ffacbad25744dd889e87da
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 21 16:44:29 2017 -0800

    x86: Add tests for -n option of x86 assembler
    
    The -n command-line of x86 assembler disables optimization of alignment
    directives, like ".balign 8, 0x90", with multi-byte nop instructions
    such as leal 0(%esi),%esi.
    
    	PR gas/22464
    	* testsuite/gas/i386/align-1.s: New file.
    	* testsuite/gas/i386/align-1a.d: Likewise.
    	* testsuite/gas/i386/align-1b.d: Likewise.
    	* testsuite/gas/i386/i386.exp: Run align-1a and align-1b.

commit c757658ed60fb1027a4335358bd55eaf6c23190f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Nov 22 00:00:23 2017 +0000

    Automatic date update in version.in

commit 3b1b69bffe522f22d269723856d2caa901041819
Author: Jerome Guitton <guitton@adacore.com>
Date:   Tue Nov 21 14:10:01 2017 -0800

    ravenscar: update inferior ptid with event ptid
    
    When debugging a program using a ravenscar runtime, the thread
    layer sometimes gets confused, and even missing some threads.
    This was traced to an assumption that ravenscar_wait was making,
    which is that calling the "to_wait" target_ops method would
    set the inferior_ptid, so that we could then use that assumption
    to update our thread_list and current ptid. However, this has not
    been the case for quite a while now. This patch fixes the problem
    by assigning inferior_ptid the ptid returned by "to_wait".
    
    gdb/ChangeLog:
    
    	* ravenscar-thread.c (ravenscar_wait): Update inferior ptid
    	with event ptid from the lower layer before doing the
    	ravenscar-specific update.

commit 54aa6c67f5a0d52dabd428cc40ce02781032acd3
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Tue Nov 21 14:04:38 2017 -0800

    (Ada) crash connecting to TSIM simulator
    
    Connecting to a TSIM simulator over the remote protocol causes GDB
    to crash with the following failed assertion:
    
        (gdb) tar remote :1234
        Remote debugging using :1234
        /[...]/gdb/ravenscar-thread.c:182: internal-error: ravenscar_update_inferior_ptid: Assertion `!is_ravenscar_task (inferior_ptid)' failed.
        A problem internal to GDB has been detected,
        further debugging may prove unreliable.
        Quit this debugging session? (y or n) y
    
    What happens is the following. Upon connection to the target, GDB
    sends a 'qfThreadInfo' query, which is the query asking the target
    for the ID of the first thread, and TSIM replies 'm0':
    
        Sending packet: $qfThreadInfo#bb...Ack
        Packet received: m0
    
    As a result of this, GDB takes the '0' as the TID, and because of it,
    constructs a ptid whose value is {42000, 0, 0}. This trips our
    !is_ravenscar_task check, because all it does to identify threads
    corresponding to ravenscar tasks is that their lwp is null, because
    that's how we construct their ptid.
    
    But this is unfortunatly not sufficient when debugging with TSIM,
    because the thread ID that TSIM returns causes the creation of
    a ptid whose lwp is zero, which matches the current identification
    scheme and yet is clearly not a ravenscar task.
    
    The fix is to also make sure that the ptid's tid field is nonzero.
    
    gdb/ChangeLog:
    
            * ravenscar-thread.c (is_ravenscar_task): Also verify that
            the ptid's TID is nonzero.

commit cf3fbed4a00e668ffcad1b878eccec87334fdcff
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Tue Nov 21 14:03:06 2017 -0800

    problem debugging ravenscar programs if runtime is stripped
    
    Trying to debug a program using a stripped version of the ravenscar
    runtime, we can get the following error:
    
        (gdb) cont
        Continuing.
        Cannot find Ada_Task_Control_Block type. Aborting
    
    This is because the ravenscar-thread layer makes the assumption that
    the runtime is built the way we expect it, meaning that the Ada tasking
    units we rely on for Ada tasking debugging, are built with debugging
    information, and that this debug information has not been stripped from
    the runtime.
    
    When this assumption is not true, resuming such a program can trigger
    the error above, which then leads GDB a little confused. For instance,
    we can see things like:
    
         (gdb) bt
         Target is executing.
    
    This patch fixes the issue by disabling the ravenscar thread layer
    if we detect that the runtime is missing some of the debugging info
    we need in order to support Ada task debugging. This is the best
    we can do, as the ravenscar-thread layer actually depends on the
    ada-tasks layer to implement thread debugging.
    
    gdb/ChangeLog:
    
            * ada-lang.h (ada_get_tcb_types_info): Add declaration.
            * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
            Make non-static.  Change return type to char *.  Adjust code
            accordingly.  Rewrite the function's documentation.
            (read_atcb): Adjust call to get_tcb_types_info accordingly.
            * ravenscar-thread.c (ravenscar_inferior_created): Check that
            we have enough debugging information in the runtime to support
            Ada task debugging before we enable the ravenscar-thread layer.

commit 9edcc12f9b714149f84bcf20dbdad91f030e62de
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Tue Nov 21 14:00:30 2017 -0800

    Add multiple-CPU support in ravenscar-thread.c
    
    This patch reworks the ravenscar-thread layer to remove the
    assumption that the target only has 1 CPU. In particular,
    when connected to a QEMU target over the remote protocol,
    QEMU reports each CPU as one thread. This patch adapts
    the ravenscar-thread layer to this, and adds a large comment
    explaining the general design of this unit.
    
    gdb/ChangeLog:
    
            * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
            * ada-tasks.c (ada_get_task_info_from_ptid): New function.
            * ravenscar-thread.c: Add into comment.
            (base_magic_null_ptid): Delete.
            (base_ptid): Change documentation.
            (ravenscar_active_task): Renames ravenscar_running_thread.
            All callers updated throughout.
            (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
            (ravenscar_task_is_currently_active): Likewise.
            (get_base_thread_from_ravenscar_task): Ditto.
            (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
            (ravenscar_runtime_initialized): Likewise.
            (get_running_thread_id): Add new parameter "cpu".  Adjust
            implementation to handle this new parameter.
            (ravenscar_fetch_registers): Small adjustment to use
            is_ravenscar_task and ravenscar_task_is_currently_active in
            order to decide whether to use the target beneath or this
            module's arch_ops.
            (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
            (ravenscar_stopped_by_sw_breakpoint): Use
            get_base_thread_from_ravenscar_task to get the underlying
            thread, rather than using base_ptid.
            (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
            (ravenscar_stopped_data_address, ravenscar_core_of_thread):
            Likewise.
            (ravenscar_inferior_created): Do not set base_magic_null_ptid.

commit 65d40437e2704e635e7144319e956edf3e7fa026
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Tue Nov 21 13:58:00 2017 -0800

    Provide the "Base CPU" in output of "info task" (if set by runtime).
    
    At the user level, this patch enhances the debugger to print the ID
    of the base CPU a task is running on:
    
            (gdb) info task 3
            Ada Task: 0x13268
            Name: raven1
            Thread: 0x13280
            LWP: 0
     !!!->  Base CPU: 1
            No parent
            Base Priority: 127
            State: Runnable
    
    This new field is only printed when the base CPU is nonzero or, in
    other words, if the base CPU info is being provided by the runtime.
    For instance, on native systems, where threads/processes can "jump"
    from CPU to CPU, the info is not available, and the output of the
    command above then remains unchanged.
    
    At the internal level, the real purpose of this change is to prepare
    the way for ravenscar-thread to start handling SMP systems. For that,
    we'll need to know which CPU each task is running on...  More info
    on that in the commit that actually adds support for it.
    
    gdb/ChangeLog:
    
            * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
            * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
            (get_tcb_types_info): Set fieldnos.base_cpu.
            (read_atcb): Set task_info->base_cpu.
            (info_task): Print "Base CPU" info if set by runtime.

commit e02544b292a3d537b43ae9cff890ea040b944d01
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Tue Nov 21 13:42:48 2017 -0800

    watchpoint regression debugging with remote protocol (bare metal)
    
    We have noticed a regression in our watchpoint support when debugging
    through the remote protocol a program running on a bare metal platform,
    when the program uses what we call the Ravenscar Runtime.
    
    This runtime is a subset of the Ada runtime defined by the Ravenscar
    Profile.  One of the nice things about this runtime is that it provides
    tasking, which is equivalent to the concept of threads in C (it is
    actually often mapped to threads, when available). For bare metal
    targets, however, there is no OS, and therefore no thread layer.
    What we did, then, was add a ravenscar-thread layer, which has insider
    knowledge of the runtime to get the list of threads, but also all
    necessary info to perform thread switching.
    
    For the record, the commit which caused the regression is:
    
        commit 799a2abe613be0645b84f5aaa050f2f91e6ae3f7
        Date:   Mon Nov 30 16:05:16 2015 +0000
        Subject: remote: stop reason and watchpoint data address per thread
    
        Running local-watch-wrong-thread.exp with "maint set target-non-stop
        on" exposes that gdb/remote.c only records whether the target stopped
        for a breakpoint/watchpoint plus the watchpoint data address *for the
        last reported remote event*.  But in non-stop mode, we need to keep
        that info per-thread, as each thread can end up with its own
        last-status pending.
    
    Our testcase is very simple. We have a package defining a global
    variable named "Watch"...
    
        package Pck is
           Watch : Integer := 1974;
        end Pck;
    
    ... and a main subprogram which changes its value
    
        procedure Foo is
        begin
           Pck.Watch := Pck.Watch + 1;
        end Foo;
    
    To reproduce, we built our program as usual, started it in QEMU,
    and then connected GDB to QEMU...
    
        (gdb) target remote :4444
        (gdb) break _ada_foo
        (gdb) cont  <--- this is to make sure the program is started
                         and the variable we want to watch is initialized
    
    ... at which point we try to use a watchpoint on our global variable:
    
        (gdb) watch watch
    
    ... but, upon resuming the execution with a "cont", we expected to
    get a watchpoint-hit notification, such as...
    
        (gdb) cont
        Hardware watchpoint 2: watch
    
        Old value = 1974
        New value = 1975
        0xfff00258 in foo () at /[...]/foo.adb:6
        6       end Foo;
    
    ... but unfortunately, we get a SIGTRAP instead:
    
        (gdb) cont
        Program received signal SIGTRAP, Trace/breakpoint trap.
        foo () at /[...]/foo.adb:6
            6   end Foo;
    
    What happens is that, on the one hand, the change in remote.c
    now stores the watchpoint-hit notification info in the thread
    that received it; and on the other hand, we have a ravenscar-thread
    layer which manages the thread list on top of the remote protocol
    layer. The two of them get disconnected, and this eventually results
    in GDB not realizing that we hit a watchpoint.  Below is how:
    
    First, once connected and just before inserting our watchpoint,
    we have the ravenscar-thread layer which built the list of threads
    by extracting some info from inferior memory, giving us the following
    two threads:
    
          (gdb) info threads
          Id   Target Id         Frame
          1    Thread 0 "0Q@" (Ravenscar task) foo () at /[...]/foo.adb:5
        * 2    Thread 0x24618 (Ravenscar task) foo () at /[...]/foo.adb:5
    
    The first thread is the only thread QEMU told GDB about. The second
    one is a thread that the ravenscar-thread added. QEMU has now way
    to know about those threads, since they are really embedded inside
    the program; that's why we have the ravenscar layer, which uses
    inside-knowledge to extract the list of threads.
    
    Next, we insert a watchpoint, which applies to all threads. No problem
    so far.
    
    Then, we continue; meaning that GDB sends a Z2 packet to QEMU to
    get the watchpoint inserted, then a vCont to resume the program's
    execution. The program hits the watchpoints, and thererfore QEMU
    reports it back:
    
            Packet received: T05thread:01;watch:000022c4;
    
    Since QEMU knows about one thread and one thread only, it stands
    to reason that it would say that the event applies to thread:01,
    which is our first thread in the "info threads" listing. That
    thread has a ptid of {42000, lwp=1, tid=0}.
    
    This is where Pedro's change kicks in: Seeing this event, and
    having determined that the event was reported for thread 01,
    and therefore ptid {42000, lwp=1, tid=0}, it saves the watchpoint-hit
    event info in the private area of that thread/ptid. Once this is
    done, remote.c's event-wait layer returns.
    
    Enter the ravenscar-thread layer of the event-wait, which does
    a little dance to delegate the wait to underlying layers with
    ptids that those layers know about, and then when the target_beneath's
    to_wait is done, tries to figure out which thread is now the active
    thread. The code looks like this:
    
      1.    inferior_ptid = base_ptid;
      2.    beneath->to_wait (beneath, base_ptid, status, 0);
      3.    [...]
      4.        ravenscar_update_inferior_ptid ();
      5.
      6.    return inferior_ptid;
    
    Line 1 is where we reset inferior_ptid to the ptid that
    the target_beneath layer knows about, allowing us to then
    call its to_wait implementation (line 2). And then, upon
    return, we call ravenscar_update_inferior_ptid, which reads
    inferior memory to determine which thread is actually active,
    setting inferior_ptid accordingly. Then we return that
    inferior_ptid (which, again, neither QEMU and therefore nor
    the remote.c layer knows about).
    
    Upon return, we eventually arrive to the part where we try
    to handle the inferior event: we discover that we got a SIGTRAP
    and, as part of its handling, we call watchpoints_triggered,
    which calls target_stopped_by_watchpoint, which eventually
    remote_stopped_by_watchpoint, where Pedro's change kicks in
    again:
    
        struct thread_info *thread = inferior_thread ();
        return (thread->priv != NULL
                && thread->priv->stop_reason == TARGET_STOPPED_BY_WATCHPOINT);
    
    Because the ravenscar-thread layer changed the inferior_ptid
    to the ptid of the active thread, inferior_thread now returns
    the private data of that thread. This is not the thread that
    QEMU reported the watchpoint-hit on, and thus, the function
    returns "no watchpoint hit, mister". Hence GDB not understanding
    the SIGTRAP, thus reporting it verbatim.
    
    The way we chose to fix the issue is by making sure that the
    ravenscar-thread layer doesn't let the remote layer be called
    with inferior_ptid being set to a thread that the remote layer
    does not know about.
    
    gdb/ChangeLog:
    
            * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
            (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
            (ravenscar_stopped_data_address, ravenscar_core_of_thread):
            New functions.
            (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
            to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
            to_stopped_data_address and to_core_of_thread fields of
            ravenscar_ops.

commit d6251545e230b243abe60e334bb3f78c5e564fa1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 21 13:41:10 2017 -0800

    Add a test for PR binutils/22451
    
    Check in the object file generated from the older assembler as a
    compressed file.
    
    	PR binutils/22451
    	* testsuite/binutils-all/x86-64/objects.exp: New file.
    	* testsuite/binutils-all/x86-64/pr22451.o.bz2: Likewise.

commit ed0f427344d0befead629d9267aecd01bfb72721
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Nov 21 18:50:59 2017 +0100

    [PowerPC] Detect different long double floating-point formats
    
    Current versions of GCC support switching the format used for "long double"
    to either IBM double double or IEEE-128.  The resulting binary is marked
    via different setting of the Tag_GNU_Power_ABI_FP GNU attribute.
    
    This patch checks this attribute to detect the format of the default
    "long double" type and sets GDB's notion of the format accordingly.
    
    The patch also adds support for the "__ibm128" type, which always uses
    IBM double double format independent of the format used for "long double".
    
    A new test case verifies that all three types, "long double", "__float128",
    and "__ibm128" are correctly detected in all three compiler settings,
    the default setting, -mabi=ieeelongdouble, and -mabi=ibmlongdouble.
    
    gdb/ChangeLog:
    2017-11-21  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* ppc-tdep.h (enum powerpc_long_double_abi): New data type.
    	(struct gdbarch_tdep): New member long_double_abi.
    	* rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
    	member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
    	* ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
    	format depending on long_double_abi tdep member.
    	(ppc_floatformat_for_type): Handle __ibm128 type.
    
    gdb/testsuite/ChangeLog:
    2017-11-21  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.arch/ppc-longdouble.exp: New file.
    	* gdb.arch/ppc-longdouble.c: Likewise.

commit a25d69c6dcbabf3f6629b847246ffb4ddbc29472
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 21 16:04:42 2017 +0000

    gdb.ada/minsyms.exp: Don't hardcode the variable's address
    
    This new testcase has a test that fails like this here:
    
      $1 = (<data variable, no debug info> *) 0x60208c <some_minsym>
      (gdb) FAIL: gdb.ada/minsyms.exp: print &some_minsym
    
    The problem is that the testcase hardcodes an expected address for the
    "some_minsym" variable, which obviously isn't stable.
    
    Fix that by expecting $hex instead.
    
    gdb/testsuite/ChangeLog:
    2017-11-21  Pedro Alves  <palves@redhat.com>
    
    	* gdb.ada/minsyms.exp: Accept any address for 'some_minsym'.

commit 2824e1bd4fc93f112875969b1ba606980aaa55ba
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Nov 21 14:15:51 2017 +0000

    Stop the v850 linker from converting to other output formats whilst linking.
    
    	PR 22419
    	* emultempl/v850elf.em (v850_create_output_section_statements):
    	New function.  Generate an error if attempting to convert the
    	format of the output file.
    	* testsuite/ld-unique/pr21529.d: Skip for the V850.
    	* testsuite/ld-elf/pr21884.d: Skip for the V850.

commit bd560f571fe7a83755a17e7b5951e70f5e4c5039
Author: claziss <claziss@synopsys.com>
Date:   Tue Nov 21 15:04:22 2017 +0100

    [ARC] [COMMITTED] Update test pattern patching.
    
    2017-11-21  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* testsuite/binutils-all/arc/objdump.exp: Update pattern matching
    	expression.

commit 50d2740d562edc68b2fbcacc0585c3acfc2c302f
Author: claziss <claziss@synopsys.com>
Date:   Tue Nov 21 14:03:03 2017 +0100

    [ARC] Improve printing of pc-relative instructions.
    
    opcodes/
    2017-11-21  Claudiu Zissulescu <claziss@synopsys.com>
    
    	* arc-dis.c (print_insn_arc): Pretty print pc-relative offsets.
    	* arc-opc.c (SIMM21_A16_5): Make it pc-relative.
    
    gas/
    2017-11-21  Claudiu Zissulescu <claziss@synopsys.com>
    
    	* testsuite/gas/arc/b.d : Update test.
    	* testsuite/gas/arc/bl.d: Likewise.
    	* testsuite/gas/arc/jli-1.d: Likewise.
    	* testsuite/gas/arc/lp.d: Likewise.
    	* testsuite/gas/arc/pcl-relocs.d: Likewise.
    	* testsuite/gas/arc/pcrel-relocs.d: Likewise.
    	* testsuite/gas/arc/pic-relocs.d: Likewise.
    	* testsuite/gas/arc/plt-relocs.d: Likewise.
    	* testsuite/gas/arc/pseudos.d: Likewise.
    	* testsuite/gas/arc/relax-avoid2.d: Likewise.
    	* testsuite/gas/arc/relax-avoid3.d: Likewise.
    	* testsuite/gas/arc/relax-b.d: Likewise.
    	* testsuite/gas/arc/tls-relocs.d: Likewise.
    	* testsuite/gas/arc/relax-add01.d: Likewise.
    	* testsuite/gas/arc/relax-add04.d: Likewise.
    	* testsuite/gas/arc/relax-ld01.d: Likewise.
    	* testsuite/gas/arc/relax-sub01.d: Likewise.
    	* testsuite/gas/arc/relax-sub02.d: Likewise.
    	* testsuite/gas/arc/relax-sub04.d: Likewise.
    	* testsuite/gas/arc/pcl-print.s: New file.
    	* testsuite/gas/arc/pcl-print.d: Likewise.
    	* testsuite/gas/arc/nps400-12.d: Likewise.
    
    ld/
    2017-11-21  Claudiu Zissulescu <claziss@synopsys.com>
    
    	* testsuite/ld-arc/jli-simple.d: Update test.

commit d85bf2ba86fea1cf918f065d179b98eb4ddbde86
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Nov 21 13:12:04 2017 +0000

    Add ability to follow dwo links to readelf/objdump.
    
    	* dwarf.c (dwo_name, dwo_dir, dwo_id, dwo_id_len): New variables.
    	(read_and_display_attr_value): Record dwo variables if requested.
    	(display_augmentation_data): Rename to display_data and make
    	generic.
    	(load_dwo_file): New function.  Loads a separate dwarf object
    	file.
    	(load_separate_debug_file): Add reporting and loading of separate
    	dwarf objet files.
    	* readelf.c (process_section_headers): Add do_debug_links to list
    	of flags requiring a debug dump.
    	(display_debug_section): Tidy up code.
    	* doc/debug.options.texi: Add note that dwo links will also be
    	followed.
    	* testsuite/binutils-all/debuglink.s: Tidy code.
    	* testsuite/binutils-all/dwo.s: New test file.
    	* testsuite/binutils-all/readelf.wk2: New file - expected output
    	from readelf.
    	* testsuite/binutils-all/readelf.exp: Run the new test.

commit 0fc7642151cc5e62f05ac8ea91fe4d5b44bee11a
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Mon Nov 20 23:29:10 2017 -0500

    Fix build failure in darwin-nat.c
    
    Fix:
    
    /Users/simark/src/binutils-gdb/gdb/darwin-nat.c:2404:3: error: no matching function for call to 'add_setshow_boolean_cmd'
      add_setshow_boolean_cmd ("mach-exceptions", class_support,
      ^~~~~~~~~~~~~~~~~~~~~~~
    
    gdb/ChangeLog:
    
    	* darwin-nat.c (set_enable_mach_exceptions): Constify parameter.

commit 0ee5a0e48314fec3522f7eabadd5fea920628077
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 21 10:04:05 2017 +1030

    Add NULL bfd test to elf_symbol_from
    
    A followup to PR22443.
    
    	* elf-bfd.h (elf_symbol_from): Check for NULL symbol bfd.
    	* elfcode.h (elf_slurp_reloc_table_from_section): Add FIXME comment.

commit bf3d139947aa7f846b463db4a7c4b6059a183e11
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 21 10:25:18 2017 +1030

    xtensa error message
    
    	* config/tc-xtensa.c (finish_vinsn): Avoid multiple ngettext calls
    	in error message.

commit e6b2f5efa97c7f3de8a3947c6782c40ec6172686
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 21 00:02:46 2017 +0000

    Fix mapped_index::find_name_components_bounds upper bound computation
    
    Here we want to find where we'd insert "after", so we want
    std::lower_bound, not std::upper_bound.
    
    gdb/ChangeLog:
    2017-11-21  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (mapped_index::find_name_components_bounds)
    	<completion mode, upper bound>: Use std::lower_bound instead of
    	std::upper_bound.
    	(test_mapped_index_find_name_component_bounds): Remove incorrect
    	"t1_fund" from expected symbols.

commit 5c58de74c9acb346513c974fcdede270be2a77c3
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 21 00:02:46 2017 +0000

    Unit test name-component bounds searching directly
    
    This commit factors out the name-components-vector building and bounds
    searching out of dw2_expand_symtabs_matching_symbol into separate
    functions, and adds unit tests that:
    
     - expose both the latent bug mentioned in the previous commit, and
       also,
    
     - for completeness exercise the 0xff character handling fixed in the
       previous commit more directly.
    
    The actual fix for the now-exposed bug is left for the following
    patch.
    
    gdb/ChangeLog:
    2017-11-21  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (mapped_index::name_components_casing): New field.
    	(mapped_index) <build_name_components,
    	find_name_components_bounds): Declare new methods.
    	(mapped_index::find_name_components_bounds)
    	(mapped_index::build_name_components): New methods, factored out
    	from dw2_expand_symtabs_matching_symbol.
    	(check_find_bounds_finds)
    	(test_mapped_index_find_name_component_bounds): New.
    	(run_test): Rename to ...
    	(test_dw2_expand_symtabs_matching_symbol): ... this.
    	(run_test): Reimplement.

commit e1ef7d7a5166f846b14bea5a77acb0dec76661a8
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 21 00:02:46 2017 +0000

    0xff chars in name components table; cp-name-parser lex UTF-8 identifiers
    
    The find-upper-bound-for-completion algorithm in the name components
    accelerator table in dwarf2read.c increments a char in a string, and
    asserts that it's not incrementing a 0xff char, but that's incorrect.
    
    First, we shouldn't be calling gdb_assert on input.
    
    Then, if "char" is signed, comparing a caracther with "0xff" will
    never yield true, which is caught by Clang with:
    
      error: comparison of constant 255 with expression of type '....' (aka 'char') is always true [-Werror,-Wtautological-constant-out-of-range-compare]
    	    gdb_assert (after.back () != 0xff);
    			~~~~~~~~~~~~~ ^  ~~~~
    
    And then, 0xff is a valid character on non-UTF-8/ASCII character sets.
    E.g., it's 'ÿ' in Latin1.  While GCC nor Clang support !ASCII &&
    !UTF-8 characters in identifiers (GCC supports UTF-8 characters only
    via UCNs, see https://gcc.gnu.org/onlinedocs/cpp/Character-sets.html),
    but other compilers might (Visual Studio?), so it doesn't hurt to
    handle it correctly.  Testing is covered by extending the
    dw2_expand_symtabs_matching unit tests with relevant cases.
    
    However, without further changes, the unit tests still fail...  The
    problem is that cp-name-parser.y assumes that identifiers are ASCII
    (via ISALPHA/ISALNUM).  This commit fixes that too, so that we can
    unit test the dwarf2read.c changes.  (The regular C/C++ lexer in
    c-lang.y needs a similar treatment, but I'm leaving that for another
    patch.)
    
    While doing this, I noticed a thinko in the computation of the upper
    bound for completion in dw2_expand_symtabs_matching_symbol.  We're
    using std::upper_bound but we should use std::lower_bound.  I extended
    the unit test with a case that I thought would expose it, this one:
    
     +  /* These are used to check that the increment-last-char in the
     +     matching algorithm for completion doesn't match "t1_fund" when
     +     completing "t1_func".  */
     +  "t1_func",
     +  "t1_func1",
     +  "t1_fund",
     +  "t1_fund1",
    
    The algorithm actually returns "t1_fund1" as lower bound, so "t1_fund"
    matches incorrectly.  But turns out the problem is masked because
    later here:
    
      for (;lower != upper; ++lower)
        {
          const char *qualified = index.symbol_name_at (lower->idx);
    
          if (!lookup_name_matcher.matches (qualified)
    
    the lookup_name_matcher.matches check above filters out "t1_fund"
    because that doesn't start with "t1_func".
    
    I'll fix the latent bug in follow up patches, after factoring things
    out a bit in a way that allows unit testing the relevant code more
    directly.
    
    gdb/ChangeLog:
    2017-11-21  Pedro Alves  <palves@redhat.com>
    
    	* cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
    	(symbol_end): Use cp_ident_is_alnum.
    	(yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
    	* dwarf2read.c (make_sort_after_prefix_name): New function.
    	(dw2_expand_symtabs_matching_symbol): Use it.
    	(test_symbols): Add more symbols.
    	(run_test): Add tests.

commit 9752982420bffb6cace1a25830a92db7fcd1dbd0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Nov 21 00:00:14 2017 +0000

    Automatic date update in version.in

commit 73fcf6418ddce47ead4ffde4fc9fea8e8bd1f4af
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 20 23:03:17 2017 +0000

    Fix gdb.base/whatis-ptype-typedefs.exp on 32-bit archs
    
    The gdb.base/whatis-ptype-typedefs.exp testcase has several tests that
    fail on 32-bit architectures.  E.g., on 'x86-64 -m32', I see:
    
     ...
     FAIL: gdb.base/whatis-ptype-typedefs.exp: lang=c: cast: whatis (float_typedef) v_uchar_array_t_struct_typedef (invalid)
     FAIL: gdb.base/whatis-ptype-typedefs.exp: lang=c: cast: ptype (float_typedef) v_uchar_array_t_struct_typedef (invalid)
     ...
    
    gdb.log:
    
     (gdb) whatis (float_typedef) v_uchar_array_t_struct_typedef
     type = float_typedef
     (gdb) FAIL: gdb.base/whatis-ptype-typedefs.exp: lang=c: cast: whatis (float_typedef) v_uchar_array_t_struct_typedef (invalid)
    
    As Simon explained [1], the issue boils down to the fact that on
    64-bit, this is an invalid cast:
    
     (gdb) p (float_typedef) v_uchar_array_t_struct_typedef
     Invalid cast.
    
    while on 32 bits it is valid:
    
     (gdb) p (float_typedef) v_uchar_array_t_struct_typedef
     $1 = 1.16251721e-41
    
    The expression basically tries to cast an array (which decays to a
    pointer) to a float.  The cast works on 32 bits because a float and a
    pointer are of the same size, and value_cast works in that case:
    
    ~~~
       More general than a C cast: accepts any two types of the same length,
       and if ARG2 is an lvalue it can be cast into anything at all.  */
    ~~~
    
    On 64 bits, they are not the same size, so it ends throwing the
    "Invalid cast" error.
    
    The testcase is expecting the invalid cast behavior, thus the FAILs.
    
    A point of these tests was to cover as many code paths in value_cast
    as possible, as a sort of documentation of the current behavior:
    
        # The main idea here is testing all the different paths in the
        # value casting code in GDB (value_cast), making sure typedefs are
        # preserved.
    ...
        # We try all combinations, even those that don't parse, or are
        # invalid, to catch the case of a regression making them
        # inadvertently valid.  For example, these convertions are
        # invalid:
    ...
    
    In that spirit, this commit makes the testcase adjust itself depending
    on size of floats and pointers, and also test floats of different
    sizes.
    
    Passes cleanly on x86-64 GNU/Linux both -m64/-m32.
    
    [1] - https://sourceware.org/ml/gdb-patches/2017-11/msg00382.html
    
    gdb/ChangeLog:
    2017-11-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/whatis-ptype-typedefs.c (double_typedef)
    	(long_double_typedef): New typedefs.
    	Use DEF on double and long double.
    	* gdb.base/whatis-ptype-typedefs.exp: Add double and long double
    	cases.
    	(run_tests): New 'float_ptr_same_size', 'double_ptr_same_size',
    	and 'long_double_ptr_same_size' locals.  Use them to decide
    	whether cast from array/function to float is valid/invalid.

commit b77db948f4175e479bb3310ba86346c9554ab9f5
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Nov 20 15:32:55 2017 +0000

    Fix handling of GNU Property notes that are not in a GNU NOTE PROPERTY section.
    
    	PR 22450
    gas	* elf-properties.c (_bfd_elf_link_setup_gnu_properties): Skip
    	objects without a GNU_PROPERTY note section when looking for a bfd
    	onto which notes can be accumulated.
    
    ld	* testsuite/ld-elf/elf.exp: Add --defsym ALIGN=2|3 to assembler
    	command line depending upon the size of the target address space.
    	* testsuite/ld-elf/pr22450.s: New test file.
    	* testsuite/ld-elf/pr22450.d: New test driver.
    	* testsuite/config/default.exp: Add note that LD_CLASS refers to
    	the size of the host linker not the size of the target linker.

commit b7486a74a62527412cfd2dd50a9a100118265c28
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 20 22:04:30 2017 +1030

    mingw gas testsuite fix
    
    Some x86_64 targets pad sections with nops.
    
    	* testsuite/gas/i386/x86-64-reg-bad.l: Accept trailing padding.

commit 28e07a0510ca896311014cddf125aedfd7a8cd52
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 20 21:35:09 2017 +1030

    PR22451, strip no longer works on older object files
    
    Setting SHF_GROUP unconditionally on rel/rela sections associated with
    SHF_GROUP sections fails badly with objcopy/strip and ld -r if the
    input file SHT_GROUP section didn't specify the rel/rela sections.
    This patch rearranges where SHF_GROUP is set for rel/rela sections.
    
    	PR 22451
    	PR 22460
    	* elf.c (_bfd_elf_init_reloc_shdr): Delete "sec_hdr" parameter
    	and leave rel_hdr->sh_flags zero.  Update calls.
    	(bfd_elf_set_group_contents): Check input rel/rela SHF_GROUP
    	flag when !gas before adding rel/rela section to group.  Set
    	output rel/rela SHF_GROUP flags.

commit 578290ecafb83e93f0ac695df586b65dac5e8c5d
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:28 2017 -0500

    Remove usage of find_inferior when calling kill_one_lwp_callback
    
    Replace with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (kill_one_lwp_callback): Return void, take
    	argument directly, don't filter on pid.
    	(linux_kill): Use for_each_thread.

commit eca55aec1d919b69e0d61c91367f8b4d25bc7c43
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:27 2017 -0500

    Remove usages of find_thread when calling need_step_over_p
    
    Replace with find_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (need_step_over_p): Return bool, remove dummy
    	argument.
    	(linux_resume, proceed_all_lwps): Use find_thread.

commit 25c28b4d153ced950cc8702aafb054d6f14f6a02
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:26 2017 -0500

    Remove usage of find_thread when calling resume_status_pending_p
    
    Replace with find_thread.  Instead of setting the flag in the callback,
    make the callback return true/false, and check the result against NULL
    in the caller.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (resume_status_pending_p): Return bool, remove
    	flag_p argument.
    	(linux_resume): Use find_thread.

commit 5fdda39248cc4a3311efbff3cf2350123d638232
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:26 2017 -0500

    Remove usage of find_inferior when calling linux_set_resume_request
    
    Replace it with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (struct thread_resume_array): Remove.
    	(linux_set_resume_request): Return void, take arguments
    	directly.
    	(linux_resume): Use for_each_thread.

commit fcb056a58dd38cfe7bcd34b7889138bf807c40b8
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:25 2017 -0500

    Remove usage of find_inferior in linux_stabilize_threads
    
    Simply replace with find_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (stuck_in_jump_pad_callback): Change prototype,
    	return bool, remove data argument.
    	(linux_stabilize_threads): Use find_thread.

commit 139720c5b32963ce52c5f691e179920ff84a2237
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:24 2017 -0500

    Remove usage of find_inferior in unsuspend_all_lwps
    
    Replace with for_each_thread.  I inlined unsuspend_one_lwp in
    unsuspend_all_lwps, since it is very simple.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (unsuspend_one_lwp): Remove.
    	(unsuspend_all_lwps): Use for_each_thread, inline code from
    	unsuspend_one_lwp.

commit 6d1e5673fec830f0f1c86632a5d9333e34582bb3
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:23 2017 -0500

    Remove usage of find_inferior in iterate_over_lwps
    
    Replace find_inferior with find_thread.  Since it may be useful in the
    future, I added another overload to find_thread which filters based on a
    ptid (using ptid_t::matches), so now iterate_over_lwps doesn't have to
    do the filtering itself.  iterate_over_lwps_filter is removed and
    inlined into iterate_over_lwps.
    
    gdb/gdbserver/ChangeLog:
    
    	* gdbthread.h (find_thread): Add overload with ptid_t filter.
    	* linux-low.c (struct iterate_over_lwps_args): Remove.
    	(iterate_over_lwps_filter): Remove.
    	(iterate_over_lwps): Use find_thread.

commit bbf550d50e4c85666877456f014421089503e83b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:22 2017 -0500

    Remove usage of find_inferior in reset_lwp_ptrace_options_callback
    
    Replace with for_each_thread, and inline code from
    reset_lwp_ptrace_options_callback.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (reset_lwp_ptrace_options_callback): Remove.
    	(linux_handle_new_gdb_connection): Use for_each_thread, inline
    	code from reset_lwp_ptrace_options_callback.

commit 00192f771796a144fe27f5f1d98d8e6f66976221
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:22 2017 -0500

    Remove usages of find_inferior in linux-arm-low.c
    
    Replace two usages with the overload of for_each_thread that filters on
    pid.  It allows to simplify the callback a little bit.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-arm-low.c (struct update_registers_data): Remove.
    	(update_registers_callback): Return void, take arguments
    	directly, don't check thread's pid.
    	(arm_insert_point, arm_remove_point): Use for_each_thread.

commit 2bee2b6ca4cb1a736f963a168dd2ded2831c540d
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:21 2017 -0500

    Remove usage of find_inferior in win32-low.c
    
    Replace with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* win32-low.c (continue_one_thread): Return void, take argument
    	directly.
    	(child_continue): Use for_each_thread.

commit 0b360f1926cb15edc39c661dac2f1a433fb288c0
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Nov 19 22:23:20 2017 -0500

    Remove usage of find_inferior in win32-i386-low.c
    
    Straightforward replacement of find_inferior with the overload of
    for_each_thread that filters on pid.  I am able to build-test this
    patch, but not run it.
    
    gdb/gdbserver/ChangeLog:
    
    	* win32-i386-low.c (update_debug_registers_callback): Rename
    	to ...
    	(update_debug_registers): ... this, return void, remove pid_p arg.
    	(x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.

commit 9c512d88c36689cffc3caf5875bc4a08b0ea05f4
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Sun Nov 19 18:02:31 2017 -0800

    Fix typo in ChangeLog entry.

commit 20dd9c210ef05fc6e87afe07670d8ceba530a1c5
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Sun Nov 19 17:56:30 2017 -0800

    Fix DWARF reader to use correct size for DW_FORM_ref_addr.
    
    2017-11-19  Ian Lance Taylor  <iant@google.com>
    	    Cary Coutant  <ccoutant@gmail.com>
    
    gold/
    	* gold/dwarf_reader.h (class Dwarf_info_reader): Add ref_addr_size
    	method.
    	* gold/dwarf_reader.cc (Dwarf_die::read_attributes): Use ref_addr_size
    	for DW_FORM_ref_addr_size.
    	(Dwarf_die::skip_attributes): Likewise.

commit bde954a064b0a983d1db37cec4777d576d7a9d56
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Nov 20 00:00:30 2017 +0000

    Automatic date update in version.in

commit 671275c35e71d3bcdde173d8817e34e89b984241
Author: Jim Wilson <jimw@sifive.com>
Date:   Sat Nov 18 17:03:08 2017 -0800

    Fix error message typo.
    
    	bfd/
    	* elfnn-riscv.c (_bfd_riscv_relax_align): Add space between alignment
    	and to in error message.

commit e4ec19878f7a6d99d87ec12cbd7b313062f64fbe
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Nov 19 00:00:28 2017 +0000

    Automatic date update in version.in

commit 160b1a618ad94988410dc81fce9189fcda5b7ff4
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Nov 18 23:18:22 2017 +1030

    PR22443, Global buffer overflow in _bfd_elf_get_symbol_version_string
    
    Symbols like *ABS* defined in bfd/section.c:global_syms are not
    elf_symbol_type.  They can appear on relocs and perhaps other places
    in an ELF bfd, so a number of places in nm.c and objdump.c are wrong
    to cast an asymbol based on the bfd being ELF.  I think we lose
    nothing by excluding all section symbols, not just the global_syms.
    
    	PR 22443
    	* nm.c (sort_symbols_by_size): Don't attempt to access
    	section symbol internal_elf_sym.
    	(print_symbol): Likewise.  Don't call bfd_get_symbol_version_string
    	for section symbols.
    	* objdump.c (compare_symbols): Don't attempt to access
    	section symbol internal_elf_sym.
    	(objdump_print_symname): Don't call bfd_get_symbol_version_string
    	for section symbols.

commit c977a5f0280f29136631cf043d6ce6cfdbc47b99
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Nov 18 00:00:10 2017 +0000

    Automatic date update in version.in

commit 033366417daedf6bf044608df1c7a8dfe01a0de2
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Nov 17 14:47:52 2017 -0800

    Finish fixing riscv gas lns-common-1 failure, and lns-duplicate.
    
    	binutils/
    	* readelf.c (elf/riscv.h): Alphabetize include.
    	(is_32bit_inplace_add_reloc, is_32bit_inplace_sub_reloc)
    	(is_64bit_inplace_add_reloc, is_64bit_inplace_sub_reloc)
    	(is_16bit_inplace_add_reloc, is_16bit_inplace_sub_reloc)
    	(is_8bit_inplace_add_reloc, is_8bit_inplace_sub_reloc): New.
    	(apply_relocations): New locals reloc_inplace and reloc_subtract.
    	Call the new functions and set the new locals.  Call byte_get if
    	reloc_inplace.  Subtract sym->st_value if reloc_subtract.

commit cf724bc93ee954a6f7aac0557afc41c1316dc80c
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Nov 17 12:05:58 2017 -0700

    Use an enum to represent subclasses of symbol
    
    This changes struct symbol to use an enum to encode the concrete
    subclass of a particular symbol.  Note that "enum class" doesn't work
    properly with bitfields, so a plain enum is used.
    
    2017-11-17  Tom Tromey  <tom@tromey.com>
    
    	* symtab.h (enum symbol_subclass_kind): New.
    	(struct symbol) <is_cplus_template_function, is_rust_vtable>:
    	Remove.
    	<subclass>: New member.
    	(SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
    	* rust-lang.c (rust_get_trait_object_pointer): Update.
    	* dwarf2read.c (read_func_scope): Update.
    	(read_variable): Update.

commit 68e745e38edebd2a12d60ef7b5774066db3f1c40
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Nov 17 11:55:38 2017 -0700

    Make template_symbol derive from symbol
    
    This changes template_symbol to derive from symbol, which seems a bit
    cleaner; and also more consistent with rust_vtable_symbol.
    
    2017-11-17  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2read.c (read_func_scope): Update.
    	* symtab.h (struct template_symbol): Derive from symbol.
    	<base>: Remove.

commit 71a3c36949407eafea744bf00334c4e0c136f927
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Jul 6 06:44:38 2017 -0600

    Handle dereferencing Rust trait objects
    
    In Rust, virtual tables work a bit differently than they do in C++.  In
    C++, as you know, they are connected to a particular class hierarchy.
    Rust, instead, can generate a virtual table for potentially any type --
    in fact, one such virtual table for each trait (a trait is similar to an
    abstract class or to a Java interface) that a type implements.
    
    Objects that are referenced via a trait can't currently be inspected by
    gdb.  This patch implements the Rust equivalent of "set print object".
    
    gdb relies heavily on the C++ ABI to decode virtual tables; primarily to
    make "set print object" work; but also "info vtbl".  However, Rust does
    not currently have a specified ABI, so this approach seems unwise to
    emulate.
    
    Instead, I've changed the Rust compiler to emit some DWARF that
    describes trait objects (previously their internal structure was
    opaque), vtables (currently just a size -- but I hope to expand this in
    the future), and the concrete type for which a vtable was emitted.
    
    The concrete type is expressed as a DW_AT_containing_type on the
    vtable's type.  This is a small extension to DWARF.
    
    This patch adds a new entry to quick_symbol_functions to return the
    symtab that holds a data address.  Previously there was no way in gdb to
    look up a full (only minimal) non-text symbol by address.  The psymbol
    implementation of this method works by lazily filling in a map that is
    added to the objfile.  This avoids slowing down psymbol reading for a
    feature that is likely to not be used too frequently.
    
    I did not update .gdb_index.  My thinking here is that the DWARF 5
    indices will obsolete .gdb_index soon-ish, meaning that adding a new
    feature to them is probably wasted work.  If necessary I can update the
    DWARF 5 index code when it lands in gdb.
    
    Regression tested on x86-64 Fedora 25.
    
    2017-11-17  Tom Tromey  <tom@tromey.com>
    
    	* symtab.h (struct symbol) <is_rust_vtable>: New member.
    	(struct rust_vtable_symbol): New.
    	(find_symbol_at_address): Declare.
    	* symtab.c (find_symbol_at_address): New function.
    	* symfile.h (struct quick_symbol_functions)
    	<find_compunit_symtab_by_address>: New member.
    	* symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
    	function.
    	(debug_sym_quick_functions): Link to
    	debug_qf_find_compunit_symtab_by_address.
    	* rust-lang.c (rust_get_trait_object_pointer): New function.
    	(rust_evaluate_subexp) <case UNOP_IND>: New case.  Call
    	rust_get_trait_object_pointer.
    	* psymtab.c (psym_relocate): Clear psymbol_map.
    	(psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
    	functions.
    	(psym_functions): Link to psym_find_compunit_symtab_by_address.
    	* objfiles.h (struct objfile) <psymbol_map>: New member.
    	* dwarf2read.c (dwarf2_gdb_index_functions): Update.
    	(process_die) <DW_TAG_variable>: New case.  Call read_variable.
    	(rust_containing_type, read_variable): New functions.
    
    2017-11-17  Tom Tromey  <tom@tromey.com>
    
    	* gdb.rust/traits.rs: New file.
    	* gdb.rust/traits.exp: New file.

commit 7468702dcb37013edbbbc62e247e23c4b2632379
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 17 13:02:25 2017 -0500

    Remove DEF_VEC_I (int)
    
    Now that all its usages are removed, we can get rid of DEF_VEC_I (int).
    
    gdb/ChangeLog:
    
    	* common/gdb_vecs.h (DEF_VEC_I (int)): Remove.

commit f27866ba9c348a72a899f5a84dadf1f943c89720
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 17 13:02:25 2017 -0500

    Make process_info::syscalls_to_catch an std::vector
    
    This patch makes the syscalls_to_catch field of process_info an
    std::vector<int>.  The process_info structure must now be
    newed/deleted.
    
    In handle_extended_wait, the code that handles exec events destroys the
    existing process_info and creates a new one.  It moves the content of
    syscalls_to_catch from the old to the new vector.  I used std::move for
    that (through an intermediary variable), which should have the same
    behavior as the old code.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h (struct process_info): Add constructor, initialize
    	fields..
    	<syscalls_to_catch>: Change type to std::vector<int>.
    	* inferiors.c (add_process): Allocate process_info with new.
    	(remove_process): Free process_info with delete.
    	* linux-low.c (handle_extended_wait): Adjust.
    	(gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
    	* server.c (handle_general_set): Adjust.

commit 37269bc92ca6a79f9e56fe83718f3c86a1db845d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 17 13:02:24 2017 -0500

    Make open_fds an std::vector
    
    Simple replacement of VEC with std::vector.
    
    gdb/ChangeLog:
    
    	* common/filestuff.c: Include <algorithm>.
    	(open_fds): Change type to std::vector<int>.
    	(do_mark_open_fd): Adjust.
    	(unmark_fd_no_cloexec): Adjust.
    	(do_close): Adjust.

commit 5c632425957f0150a0d5d1e747f0425f74622132
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Nov 17 13:02:23 2017 -0500

    Make output_thread_groups take an std::vector<int>
    
    A simple replacement of VEC with std::vector.
    
    gdb/ChangeLog:
    
    	* breakpoint.c (output_thread_groups): Take an std::vector.
    	(print_one_breakpoint_location): Adjust.

commit ced9779b4c45b9bc9c16dd98fa30d7a620e93a55
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Wed Nov 15 19:02:33 2017 -0500

    (Ada) fix handling of minimal symbols (UNOP_CAST and UNOP_ADDR)
    
    Consider a program which provides a symbol without debugging
    information. For instance, compiling the following code without -g:
    
        Some_Minimal_Symbol : Integer := 1234;
        pragma Export (C, Some_Minimal_Symbol, "some_minsym");
    
    Trying to print this variable with GDB now causes an error, which
    is now expected:
    
        (gdb) p some_minsym
        'some_minsym' has unknown type; cast it to its declared type
    
    However, trying to cast this symbol, or to take its address
    does not work:
    
        (gdb) p integer(some_minsym)
        'some_minsym' has unknown type; cast it to its declared type
        (gdb) p &some_minsym
        'some_minsym' has unknown type; cast it to its declared type
    
    Another manisfestation of this issue can be seen when trying to
    insert an Ada exception catchpoint for a specific standard exception
    (this only occurs if the Ada runtime is built without debugging
    information, which is the default).  For instance:
    
        $ (gdb) catch exception constraint_error
        warning: failed to reevaluate internal exception condition for catchpoint 0: 'constraint_error' has unknown type; cast it to its declared type
    
    This is because, internally, the cachtpoint uses a condition referencing
    a minimal symbol, more precisely:
    
       long_integer (e) = long_integer (&constraint_error)
    
    This patch fixes all issues listed above:
    
      1. resolve_subexp: Special-case the handling of OP_VAR_MSYM_VALUE
         expression elements, where there are no ambiguities to be resolved
         in that situation;
    
      2. ada_evaluate_subexp: Enhance the handling of the UNOP_CAST
         handling so as to process the case where the target of
         the cast is a minimal symbol (as well as a symbol with debugging
         information). This mimics what's done in C.
    
    gdb/ChangeLog:
    
            * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
            (ada_evaluate_subexp_for_cast): New function.
            (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
            ada_evaluate_subexp_for_cast.
            (ada_evaluate_subexp) <nosideret>: Replace code by call to
            eval_skip_value.
            * eval.c (evaluate_var_value): Make non-static.
            (evaluate_var_msym_value, eval_skip_value): Likewise.
            * value.h (evaluate_var_value, evaluate_var_msym_value)
            (eval_skip_value): Declare.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/minsyms: New testcase.
    
    Tested on x86_64-linux. No regression. Fixes the following failures:
    
        catch_ex.exp: continuing to Program_Error exception
        catch_ex.exp: continuing to failed assertion
        catch_ex.exp: continuing to unhandled exception
        catch_ex.exp: continuing to program completion
        complete.exp: p <Exported_Capitalized>
        complete.exp: p Exported_Capitalized
        complete.exp: p exported_capitalized
        mi_catch_ex.exp: catch Program_Error (unexpected output)
        mi_catch_ex.exp: continue to exception catchpoint hit (unknown output after running)
        mi_catch_ex.exp: continue to assert failure catchpoint hit (unknown output after running)
        mi_catch_ex.exp: continue to unhandled exception catchpoint hit (unknown output after running)
        mi_ex_cond.exp: catch C_E if i = 2 (unexpected output)

commit 3cfd3dd0956fe854a07795de12c1302ecabbd819
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Nov 17 12:44:16 2017 +0000

    Fix a memory leak when processing archives.
    
    	PR 22449
    	* ar.c (write_archive): Free the temporary file name.

commit 2c244f9b0935e577d7c20bb5706e27438e48227f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 17 04:09:12 2017 -0800

    x86: Pass "%F%P:" to linker callback in case of error
    
    We should pass "%F%P:" to  linker callback in case of error.  Otherwise,
    linker will report:
    
    : failed to create GNU property section
    
    	* elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties): Pass
    	"%F%P:", instead of "%F:", to linker callback in case of error.

commit 6a6196fc71467e39e9009d6306ef13de008c6fe3
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Nov 17 12:05:34 2017 +0000

    Fix a snafu in a previous update to readelf that stopped it from printing archive member names along with the archive file name.
    
    --
    This patch causes problems for glibc linknamespace tests because of how it
    changes the output format of readelf on .a files.
    
    Previously, "readelf -W -s libc.a" would produce output starting e.g.:
    
    File: /scratch/jmyers/glibc/many8/build/glibcs/x86_64-linux-gnu/glibc/libc.a(init-first.o)
    
    Symbol table '.symtab' contains 30 entries:
    
    and continuing with symbol information for each object in that .a file.
    After this commit, instead it starts:
    
    File: /scratch/jmyers/glibc/many8/build/glibcs/x86_64-linux-gnu/glibc/libc.a
    
    Symbol table '.symtab' contains 30 entries:
    
    and every object's symbol information starts with the same File: line,
    missing any information about which object's symbols (within libc.a) are
    being listed.
    
    I think the previous File: lines that said libc.a(init-first.o) etc.,
    identifying the particular object within libc.a, were clearly preferable,
    and the glibc linknamespace tests rely on having that information about
    the individual object within libc.a.
    --
    
    binutils * readelf.c (process_archive): Include member name in the
    	file_name of the filedata structure.

commit b7e228508255359e473611fdf7c067b0b79cadbe
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Nov 16 16:15:13 2017 -0800

    ada-lang.c::ada_value_cast: remove unused parameter noside
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_value_cast): Remove parameter "noside".
            Update all callers.

commit fdfffb6ea04ab0e857e8bdc17841a7372b187bd0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Nov 17 00:00:18 2017 +0000

    Automatic date update in version.in

commit a0922d80dff15d4fbd5d469f56bcd1696846b90a
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:44 2017 +0000

    Test breakpoint commands w/ "continue" + Ctrl-C
    
    This adds the testcase that exposed the multiple problems with Ctrl-C
    handling fixed by the previous patches, when run against both native
    and gdbserver GNU/Linux.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/bp-cmds-continue-ctrl-c.c: New file.
    	* gdb.base/bp-cmds-continue-ctrl-c.exp: New file.

commit 9ccabccd15603dbf9fe988c86708fe644d1398a7
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:44 2017 +0000

    Python unwinder sniffer: PyExc_KeyboardInterrupt -> Quit
    
    If you happen to press Ctrl-C while GDB is running the Python unwinder
    machinery, the Ctrl-C is swallowed by the Python unwinder machinery.
    
    For example, with:
    
     break foo
     commands
     > c
     > end
    
    and
    
      while (1)
        foo ();
    
    and then let the inferior hit "foo" repeatedly, sometimes Ctrl-C
    results in:
    
    ~~~
      23        usleep (100);
    
      Breakpoint 2, foo () at gdb.base/bp-cmds-continue-ctrl-c.c:23
      23        usleep (100);
      ^C
      Breakpoint 2, Python Exception <class 'KeyboardInterrupt'> <class 'KeyboardInterrupt'>:
      foo () at gdb.base/bp-cmds-continue-ctrl-c.c:23
      23        usleep (100);
    
      Breakpoint 2, foo () at gdb.base/bp-cmds-continue-ctrl-c.c:23
      23        usleep (100);
    
      Breakpoint 2, foo () at gdb.base/bp-cmds-continue-ctrl-c.c:23
      23        usleep (100);
    ~~~
    
    Notice the Python exception above.  The interesting thing here is that
    GDB continues as if nothing happened, doesn't really stop and give
    back control to the user.  Instead, the Ctrl-C aborted the Python
    unwinder sniffer and GDB moved on to just use another unwinder.
    
    Fix this by translating a PyExc_KeyboardInterrupt back into a Quit
    exception once back in GDB.
    
    This was exposed by the new gdb.base/bp-cmds-continue-ctrl-c.exp
    testcase added later in the series.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* python/py-unwind.c (pyuw_sniffer): Translate
    	PyExc_KeyboardInterrupt to a GDB Quit exception.

commit d930703d68ae160ddfe8ebe5fdcf416fb6090e1e
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:43 2017 +0000

    Don't ever Quit out of resume
    
    If you have a breakpoint command that re-resumes the target, like:
    
      break foo
      commands
      > c
      > end
    
    and then let the inferior run, hitting the breakpoint, and then press
    Ctrl-C at just the right time, between GDB processing the stop at
    "foo", and re-resuming the target, you'll hit the QUIT call in
    infrun.c:resume.
    
    With this hack, we can reproduce the bad case consistently:
    
      --- a/gdb/inf-loop.c
      +++ b/gdb/inf-loop.c
      @@ -31,6 +31,8 @@
       #include "top.h"
       #include "observer.h"
    
      +bool continue_hack;
      +
       /* General function to handle events in the inferior.  */
    
       void
      @@ -64,6 +66,8 @@ inferior_event_handler (enum inferior_event_type event_type,
    	  {
    	    check_frame_language_change ();
    
      +         continue_hack = true;
      +
    	    /* Don't propagate breakpoint commands errors.  Either we're
    	       stopping or some command resumes the inferior.  The user will
    	       be informed.  */
      diff --git a/gdb/infrun.c b/gdb/infrun.c
      index d425664..c74b14c 100644
      --- a/gdb/infrun.c
      +++ b/gdb/infrun.c
      @@ -2403,6 +2403,10 @@ resume (enum gdb_signal sig)
         gdb_assert (!tp->stop_requested);
         gdb_assert (!thread_is_in_step_over_chain (tp));
    
      +  extern bool continue_hack;
      +
      +  if (continue_hack)
      +    set_quit_flag ();
         QUIT;
    
    The GDB backtrace looks like this:
    
      (top-gdb) bt
      ...
      #3  0x0000000000612e8b in throw_quit(char const*, ...) (fmt=0xaf84a1 "Quit") at src/gdb/common/common-exceptions.c:408
      #4  0x00000000007fc104 in quit() () at src/gdb/utils.c:748
      #5  0x00000000006a79d2 in default_quit_handler() () at src/gdb/event-top.c:954
      #6  0x00000000007fc134 in maybe_quit() () at src/gdb/utils.c:762
      #7  0x00000000006f66a3 in resume(gdb_signal) (sig=GDB_SIGNAL_0) at src/gdb/infrun.c:2406
      #8  0x0000000000700c3d in keep_going_pass_signal(execution_control_state*) (ecs=0x7ffcf3744e60) at src/gdb/infrun.c:7793
      #9  0x00000000006f5fcd in start_step_over() () at src/gdb/infrun.c:2145
      #10 0x00000000006f7b1f in proceed(unsigned long, gdb_signal) (addr=18446744073709551615, siggnal=GDB_SIGNAL_DEFAULT)
          at src/gdb/infrun.c:3135
      #11 0x00000000006ebdd4 in continue_1(int) (all_threads=0) at src/gdb/infcmd.c:842
      #12 0x00000000006ec097 in continue_command(char*, int) (args=0x0, from_tty=0) at src/gdb/infcmd.c:938
      #13 0x00000000004b5140 in do_cfunc(cmd_list_element*, char*, int) (c=0x2d18570, args=0x0, from_tty=0)
          at src/gdb/cli/cli-decode.c:106
      #14 0x00000000004b8219 in cmd_func(cmd_list_element*, char*, int) (cmd=0x2d18570, args=0x0, from_tty=0)
          at src/gdb/cli/cli-decode.c:1952
      #15 0x00000000007f1532 in execute_command(char*, int) (p=0x7ffcf37452b1 "", from_tty=0) at src/gdb/top.c:608
      #16 0x00000000004bd127 in execute_control_command(command_line*) (cmd=0x3a88ef0) at src/gdb/cli/cli-script.c:485
      #17 0x00000000005cae0c in bpstat_do_actions_1(bpstat*) (bsp=0x37edcf0) at src/gdb/breakpoint.c:4513
      #18 0x00000000005caf67 in bpstat_do_actions() () at src/gdb/breakpoint.c:4563
      #19 0x00000000006e8798 in inferior_event_handler(inferior_event_type, void*) (event_type=INF_EXEC_COMPLETE, client_data=0x0)
          at src/gdb/inf-loop.c:72
      #20 0x00000000006f9447 in fetch_inferior_event(void*) (client_data=0x0) at src/gdb/infrun.c:3970
      #21 0x00000000006e870e in inferior_event_handler(inferior_event_type, void*) (event_type=INF_REG_EVENT, client_data=0x0)
          at src/gdb/inf-loop.c:43
      #22 0x0000000000494d58 in remote_async_serial_handler(serial*, void*) (scb=0x3585ca0, context=0x2cd1b80)
          at src/gdb/remote.c:13820
      #23 0x000000000044d682 in run_async_handler_and_reschedule(serial*) (scb=0x3585ca0) at src/gdb/ser-base.c:137
      #24 0x000000000044d767 in fd_event(int, void*) (error=0, context=0x3585ca0) at src/gdb/ser-base.c:188
      #25 0x00000000006a5686 in handle_file_event(file_handler*, int) (file_ptr=0x45997d0, ready_mask=1)
          at src/gdb/event-loop.c:733
      #26 0x00000000006a5c29 in gdb_wait_for_event(int) (block=1) at src/gdb/event-loop.c:859
      #27 0x00000000006a4aa6 in gdb_do_one_event() () at src/gdb/event-loop.c:347
      #28 0x00000000006a4ade in start_event_loop() () at src/gdb/event-loop.c:371
    
    and when that happens, you end up with GDB's run control in quite a
    messed up state.  Something like this:
    
      thread_function1 (arg=0x1) at threads.c:107
      107             usleep (SLEEP);  /* Loop increment.  */
      Quit
      (gdb) c
      Continuing.
      ** nothing happens, time passes..., press ctrl-c again **
      ^CQuit
      (gdb) info threads
        Id   Target Id         Frame
        1    Thread 1462.1462 "threads" (running)
      * 2    Thread 1462.1466 "threads" (running)
        3    Thread 1462.1465 "function0" (running)
      (gdb) c
      Cannot execute this command while the selected thread is running.
      (gdb)
    
    The first "Quit" above is thrown from within "resume", and cancels run
    control while GDB is in the middle of stepping over a breakpoint.
    with step_over_info_valid_p() true.  The next "c" didn't actually
    resume anything, because GDB throught that the step-over was still in
    progress.  It wasn't, because the thread that was supposed to be
    stepping over the breakpoint wasn't actually resumed.
    
    So at this point, we press Ctrl-C again, and this time, the default
    quit handler is called directly from the event loop
    (event-top.c:default_quit_handler -> quit()), because gdb was left
    owning the terminal (because the previous resume was cancelled before
    we reach target_resume -> target_terminal::inferior()).
    
    Note that the exception called from within resume ends up calling
    normal_stop via resume_cleanups.  That's very borked though, because
    normal_stop is going to re-handle whatever was the last reported
    event, possibly even re-running a hook stop...  I think that the only
    sane way to safely cancel the run control state machinery is to push
    an event via handle_inferior_event like all other events.
    
    The fix here does two things, and either alone would fix the problem
    at hand:
    
    #1 - passes the terminal to the inferior earlier, so that any QUIT
         call from the point we declare the target as running goes to the
         inferior directly, protecting run control from unsafe QUIT calls.
    
    #2 - gets rid of this QUIT call in resume and of its related unsafe
         resume_cleanups.
    
    Aboout #2, the comment describing resume says:
    
      /* Resume the inferior, but allow a QUIT.  This is useful if the user
         wants to interrupt some lengthy single-stepping operation
         (for child processes, the SIGINT goes to the inferior, and so
         we get a SIGINT random_signal, but for remote debugging and perhaps
         other targets, that's not true).
    
    but that's a really old comment that predates a lot of fixes to Ctrl-C
    handling throughout both GDB core and the remote target, that made
    sure that a Ctrl-C isn't ever lost.  In any case, if some target
    depended on this, a much better fix would be to make the target return
    a SIGINT stop out of target_wait the next time that is called.
    
    This was exposed by the new gdb.base/bp-cmds-continue-ctrl-c.exp
    testcase added later in the series.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* infrun.c (resume_cleanups): Delete.
    	(resume): No longer install a resume_cleanups cleanup nor call
    	QUIT.
    	(proceed): Pass the terminal to the inferior.
    	(keep_going_pass_signal): No longer install a resume_cleanups
    	cleanup.

commit 38dc2859c464733314c591d30a5359db20167f7f
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:43 2017 +0000

    Fix stdin ending up not registered after a Quit
    
    If you press Ctrl-C while GDB is processing breakpoint commands the
    TRY/CATCH in inferior_event_handler catches the Quit exception and
    prints it, and then if the interpreter was running a foreground
    execution command, nothing re-adds stdin back in the event loop,
    meaning the debug session ends up busted, because the user can't type
    anything...
    
    This was exposed by the new gdb.base/bp-cmds-continue-ctrl-c.exp
    testcase added later in the series.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* inf-loop.c (inferior_event_handler): Don't swallow the exception
    	if the prompt is blocked.

commit 688fca4fe6c83a6802731faa8455d177998d614d
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:42 2017 +0000

    Fix swallowed "Quit" when inserting breakpoints
    
    If GDB is inserting a breakpoint and you type Ctrl-C at the exact
    "right" time, you'll hit a QUIT call in target_read, and the
    breakpoint insertion is cancelled.  However, the related TRY/CATCH
    code in insert_bp_location does:
    
     		  CATCH (e, RETURN_MASK_ALL)
     		    {
    		      bp_err = e.error;
    		      bp_err_message = e.message;
    		    }
    
    The problem with that is that a RETURN_QUIT exception has e.error ==
    0, which means that further below, in the places that check for error
    with:
    
          if (bp_err != GDB_NO_ERROR)
    
    because GDB_NO_ERROR == 0, GDB continues as if the breakpoint was
    inserted succesfully, and resumes the inferior.  Since the breakpoint
    wasn't inserted the inferior runs free, out of our control...
    
    Fix this by having insert_bp_location store a copy of the whole
    exception instead of just a error/message parts, and then checking
    "gdb_exception::reason" instead.
    
    This was exposed by the new gdb.base/bp-cmds-continue-ctrl-c.exp
    testcase added later in the series.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* breakpoint.c (insert_bp_location): Replace bp_err and
    	bp_err_message locals by a gdb_exception local.

commit e2c33ac745108550dcc2dc61d23378fb2fa9e911
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:44:42 2017 +0000

    gdb/inflow.c: Move SIGTTOU temporary ignoring to a RAII class
    
    I expect to use this in more places (in inflow.c) in follow up
    patches, but I think this is still good on its own.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* inflow.c (scoped_ignore_sigttou): New class.
    	(child_terminal_ours_1, new_tty): Use it.

commit ea04e54ca8b935b01155c3d40381d879dd6ba683
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 18:07:41 2017 +0000

    Fix testing gdb.rust/modules.exp against gdbserver
    
    Currently several tests in gdb.rust/modules.exp fail with
     --target_board=native-gdbserver:
    
     Running src/gdb/testsuite/gdb.rust/modules.exp ...
     FAIL: gdb.rust/modules.exp: call f3()
     FAIL: gdb.rust/modules.exp: call self::f2()
     FAIL: gdb.rust/modules.exp: call self::super::f2()
     FAIL: gdb.rust/modules.exp: call super::f2()
     FAIL: gdb.rust/modules.exp: call self::super::super::f2()
     FAIL: gdb.rust/modules.exp: call super::super::f2()
     FAIL: gdb.rust/modules.exp: call ::f2()
     FAIL: gdb.rust/modules.exp: call extern modules::mod1::f2()
    
    This is because these tests rely on matching inferior output.
    However, when testing with gdbserver, inferior output goes to a
    separate terminal instead of to gdb's terminal, and so gdb_test won't
    cut it, as that is only reading from gdb's pty/gdb_spawn_id:
    
     (gdb) call f3()
     (gdb) FAIL: gdb.rust/modules.exp: call f3()
     call self::f2()
     (gdb) FAIL: gdb.rust/modules.exp: call self::f2()
    
    Fix this by using gdb_test_stdio instead, which handles output coming
    out of gdbserver's pty.
    
    Also, skip the tests if the target/board doesn't support inferior I/O
    at all.
    
    gdb/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* gdb.rust/modules.exp: Skip tests that rely on inferior I/O if
    	gdb,noinferiorio is set, and use gdb_test_stdio otherwise.

commit d723696126beb185dc1f8f3196be7cb29948148d
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Thu Nov 16 18:49:11 2017 +0100

    Refactor endian handling in DFP routines
    
    This patch moves endian conversion into the decimal_from_number and
    decimal_to_number routines, and removes it from all their callers,
    making the code simpler overall.  No functional change.
    
    gdb/ChangeLog:
    2017-11-16  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c (decimal_from_number): Add byte_order argument and
    	call match_endianness.  Error if unknown floating-point type.
    	(decimal_to_number): Add byte_order argument and call match_endianness.
    	(decimal_from_longest): Update call.  Do not call match_endianness.
    	(decimal_from_ulongest): Likewise.
    	(decimal_binop): Likewise.
    	(decimal_is_zero): Likewise.
    	(decimal_compare): Likewise.
    	(decimal_convert): Likewise.

commit d0f7791c6659081f3a62e220289417c010997baa
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 16 16:19:37 2017 +0000

    Add new AArch64 FP16 FM{A|S} instructions.
    
    This patch separates the new FP16 instructions backported from Armv8.4-a to Armv8.2-a
    into a new flag order to distinguish them from the rest of the already existing optional
    FP16 instructions in Armv8.2-a.
    
    The new flag "+fp16fml" is available from Armv8.2-a and implies +fp16 and is mandatory on
    Armv8.4-a.
    
    gas/
    
    	* config/tc-aarch64.c (fp16fml): New.
    	* doc/c-aarch64.texi (fp16fml): New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16.d (fp16): Make fp16fml.
    	* testsuite/gas/aarch64/armv8_3-a-crypto-fp16.d (fp16): Make fp16fml.
    
    include/
    
    	* opcode/aarch64.h: (AARCH64_FEATURE_F16_FML): New.
    	(AARCH64_ARCH_V8_4): Enable AARCH64_FEATURE_F16_FML by default.
    
    opcodes/
    
    	* aarch64-tbl.h (aarch64_feature_fp_16_v8_2): Require AARCH64_FEATURE_F16_FML
    	and AARCH64_FEATURE_F16.

commit fadfa6b0020b934500356e7aea8934a4565657d3
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 16 16:15:51 2017 +0000

    Correct AArch64 crypto dependencies.
    
    The crypto options depend on SIMD and FP, the documentation states so but the dependency is not there the code.
    
    We have mostly gotten away with this due to the default flags
    for the architectures (e.g. Armv8.2-a  implies +simd) but this
    discrepancy needs to be addressed.
    
    gas/
    
    2017-11-16  Tamar Christina  <tamar.christina@arm.com>
    
    	* opcodes/aarch64-tbl.h
    	(aarch64_feature_crypto): Add ARCH64_FEATURE_SIMD and AARCH64_FEATURE_FP.
    	(aarch64_feature_crypto_v8_2, aarch64_feature_sm4): Likewise.
    	(aarch64_feature_sha3): Likewise.

commit 68ffd9368a020fb685520da51f8c672c720869e4
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 16 16:13:01 2017 +0000

    Update documentation for Arvm8.4-A changes to AArch64.
    
    gas/
    
    2017-11-16  Tamar Christina  <tamar.christina@arm.com>
    
    	* doc/c-aarch64.texi (armv8.4-a, sha2, sha3, sm4): New.
    	(dotprod): Update default note.

commit e9dbdd80cb02ac66cf7d4cd1207ec11928db2c95
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 16 16:07:07 2017 +0000

    Add assembler and disassembler support for the new Armv8.4-a instructions for AArch64.
    
    Some of these instructions have been back-ported as optional extensions to
    Armv8.2-a and higher, but others are only available for Armv8.4-a.
    
    opcodes/
    
    	* aarch64-tbl.h (sha512h, sha512h2, sha512su0, sha512su1, eor3): New.
    	(rax1, xar, bcax, sm3ss1, sm3tt1a, sm3tt1b, sm3tt2a, sm3tt2b): New.
    	(sm3partw1, sm3partw2, sm4e, sm4ekey, fmlal, fmlsl): New.
    	(fmlal2, fmlsl2, cfinv, rmif, setf8, setf16, stlurb): New.
    	(ldapurb, ldapursb, stlurh, ldapurh, ldapursh, stlur): New.
    	(ldapur, ldapursw, stlur): New.
    	* aarch64-dis-2.c: Regenerate.
    
    gas/
    
    	* testsuite/gas/aarch64/armv8_4-a-illegal.d: New.
    	* testsuite/gas/aarch64/armv8_4-a-illegal.l: New.
    	* testsuite/gas/aarch64/armv8_4-a-illegal.s: New.
    	* testsuite/gas/aarch64/armv8_4-a.d: New.
    	* testsuite/gas/aarch64/armv8_4-a.s: New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16.s: New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16.d: New.
    	* testsuite/gas/aarch64/armv8_3-a-crypto-fp16.d: New.
    	* testsuite/gas/aarch64/armv8_4-a-crypto-fp16.d: New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16-illegal.s: New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16-illegal.l: New.
    	* testsuite/gas/aarch64/armv8_2-a-crypto-fp16-illegal.d: New.

commit e849ea896bcdc3da8caff02eb6dc91dc85dd8a7e
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 14:58:51 2017 +0000

    GDBserver: Fix ignored Ctrl-C after reconnection
    
    This fixes the issue reported by Dmitry Antipov <dantipov@nvidia.com>
    here:
      https://sourceware.org/ml/gdb/2017-10/msg00048.html
    
    The problem is that GDBserver stops listening to Ctrl-C/interrupt
    requests if you disconnect and reconnect back.
    
    Dmitry wrote:
    
    ~~~
    Currently gdbserver installs SIGIO handler just once, in
    initialize_async_io() called from captured_main(), and this handler is
    removed when remote_desc is closed in remote_close().  Next, when a
    new instance of remote_desc is fetched from accept() and has '\003'
    arrived, input_interrupt() is never called because it is not
    registered as SIGIO handler.
    ~~~
    
    The fix here is not remove the SIGIO handler in the first place, thus
    going back to the original before-first-connection state.
    
    (I haven't gone back to try it, but I think this was a regression
    caused by commit 8b2073398477 ("[GDBserver] Block and unblock SIGIO"),
    which was what made remote_close remove the signal handler.)
    
    New test included.
    
    gdb/gdbserver/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* remote-utils.c (remote_close): Block SIGIO signals instead of
    	uninstalling the SIGIO handler.
    
    gdb/testsuite/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* gdb.server/reconnect-ctrl-c.c: New file.
    	* gdb.server/reconnect-ctrl-c.exp: New file.

commit 80a0437873045cc08753fcac4af154e2931a99fd
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Nov 16 14:53:32 2017 +0000

    Prevent illegal memory accesses when parsing incorrecctly formated core notes.
    
    	PR 22421
    	* elf.c (elfcore_grok_netbsd_procinfo): Check that the note is big enough.
    	(elfcore_grok_openbsd_procinfo): Likewise.
    	(elfcore_grok_nto_status): Likewise.

commit d8ae99a7b08e29e31446aee1e47e59943d7d9926
Author: Phil Muldoon <pmuldoon@redhat.com>
Date:   Thu Nov 16 14:14:03 2017 +0000

    Add Python rbreak command.
    
    gdb/Changelog
    
    2017-11-16  Phil Muldoon  <pmuldoon@redhat.com>
    
    	* python/python.c (gdbpy_rbreak): New function.
            * NEWS: Document Python rbreak feature.
    
    testsuite/Changelog
    
    2017-11-16  Phil Muldoon  <pmuldoon@redhat.com>
    
    	* gdb.python/py-rbreak.exp: New file.
    	* gdb.python/py-rbreak.c: New file.
    	* gdb.python/py-rbreak-func2.c: New file.
    
    doc/Changelog
    
    2017-11-16  Phil Muldoon  <pmuldoon@redhat.com>
    
    	* python.texi (Basic Python): Add rbreak documentation.

commit 38b28f7088057d70497de7312cd983ec8e408a76
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Nov 16 13:06:22 2017 +0000

    Prevent a possible seg-fault in the section merging code, by always creating a padding buffer.
    
    	* merge.c (sec_merge_emit): Always create padding buffer.  Add
    	asserts to make sure that the buffer is long enough.

commit 5f847646eeb0107cb8c5e44c8bca3a4c88c91673
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 16 13:56:45 2017 +0100

    x86: ignore high register select bit(s) in 32- and 16-bit modes
    
    While commits 9889cbb14e ("Check invalid mask registers") and
    abfcb414b9 ("X86: Ignore REX_B bit for 32-bit XOP instructions") went a
    bit into the right direction, this wasn't quite enough:
    - VEX.vvvv has its high bit ignored
    - EVEX.vvvv has its high bit ignored together with EVEX.v'
    - the high bits of {,E}VEX.vvvv should not be prematurely zapped, to
      allow proper checking of them when the fields has to hold al ones
    - when the high bits of an immediate specify a register, bit 7 is
      ignored

commit 968a13f8362072b5f7eae8584d490b53d7f97ca5
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 16 11:57:01 2017 +0000

    Fix gdb.base/starti.exp racy test
    
    This commit fixes a couple problems with gdb.base/starti.exp, causing
    spurious FAILs.
    
    The first is a double-prompt problem:
    
    ~~~
     (gdb) PASS: gdb.base/starti.exp: hook-stop
     starti
     [....]
     gdb_expect_list pattern: /\$1 = 0/
     $1 = 0
    
     gdb_expect_list pattern: //
     0x00007ffff7ddcc80 in _start () from /lib64/ld-linux-x86-64.so.2
    
     (gdb)                                         # EXPECTED PROMPT
     (gdb) PASS: gdb.base/starti.exp: starti       # ANOTHER PROMPT!
     break main
    ~~~
    
    This happens because the test uses gdb_test_sequence with no command,
    like this:
    
     gdb_test_sequence "" "starti" {
         "Program stopped."
         "\\$1 = 0"
     }
    
    but gdb_test_sequence doesn't have a check for empty command like
    gdb_test_multiple does, and so sends "\n" to GDB:
    
     proc gdb_test_sequence { command test_name expected_output_list } {
         global gdb_prompt
         if { $test_name == "" } {
    	 set test_name $command
         }
         lappend expected_output_list ""; # implicit ".*" before gdb prompt
         send_gdb "$command\n"
         return [gdb_expect_list $test_name "$gdb_prompt $" $expected_output_list]
     }
    
    "starti" is a no-repeat command, so pressing <ret> just makes another
    prompt appear, confusing the following gdb_test/gdb_test_multiple/etc.
    
    Even with that fixed, the testcase is still racy though.
    
    The second problem is that sometimes the "continue" test times out
    here:
    
    ~~~
     continue
     Continuing.
     $2 = 1
    
    
     gdb_expect_list pattern: /.*Breakpoint .*main \(\) at .*starti.c.*/
     Breakpoint 1, main () at /home/pedro/src/gdb/testsuite/gdb.base/starti.c:29
     29	  return 0;
     (gdb) gdb_expect_list pattern: //
     * hung here *
    ~~~
    
    The problem is that the too-greedy ".*" trailing match in
    gdb_expect_list's pattern ends up consuming GDB's prompt too soon.
    Fix that by removing the unnecessary trailing ".*".  While at it,
    remove all ".*"s to be stricter.
    
    Tested on x86_64 GNU/Linux.
    
    gdb/testsuite/ChangeLog:
    2017-11-16  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/starti.exp ("continue" test): Remove ".*"s from
    	pattern.
    	* lib/gdb.exp (gdb_test_sequence): Don't send empty command to
    	GDB.

commit c2b9da16088f8c500ab93e9a4e3001ab7393cb38
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Nov 16 12:28:06 2017 +0100

    ix86/Intel: don't require memory operand size specifier for PTWRITE
    
    Other than in 64-bit mode, in 32- and 16-bit modes operand size isn't
    ambiguous.

commit 8c8cad3aa839747e368cc5db58331756a2b70e8e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Nov 16 02:50:33 2017 -0800

    i386: Replace .code64/.code32 with .byte
    
    Since .code64 directive isn't available for 32-bit BFD and ELF directive
    isn't available for non-ELF directive, we should avoid them.
    
    	* testsuite/gas/i386/noextreg.s: Replace .code64/.code32 and
    	64-bit instructions with .byte.  Remove ELF directive.

commit c632b6456b1f220475fbf61f19ada28230449ff6
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 16 10:17:25 2017 +0000

    Remove non-linux tic6x target descriptions
    
    They are not used by GDB nor by GDBserver.  This patch removes them.
    
    gdb:
    
    2017-11-16  Yao Qi  <yao.qi@linaro.org>
    
    	* features/tic6x-c62x.xml: Remove.
    	* features/tic6x-c64x.xml: Remove.
    	* features/tic6x-c64xp.xml: Remove.

commit 1d0aa65c24f7c6406718cb506bed912aeec1d5c9
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Thu Nov 16 10:05:21 2017 +0000

    Allow osabi to be optional in target descriptions
    
    gdbserver/
    	* tdesc.c (tdesc_get_features_xml): Allow null osabi.

commit 3491a34c4f7de10dbd19c719052642d8471c45a6
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 16 10:05:27 2017 +0000

    Fix tic6x-uclinux GDBserver build failure
    
    I can't find a c6x-uclinux c++ compiler, so I use my host g++ to build
    tic6x-uclinux GDBserver, and find the following build failures.  They are
    not target specific, so I believe they are real errors.  This patch fixes
    them.
    
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c:313:34: error: invalid
    conversion from 'void*' to 'tic6x_register*' [-fpermissive]
       union tic6x_register *regset = buf;
                                      ^
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c: In function 'void tic6x_store_gregset(regcache*, const void*)':
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c:324:40: error: invalid
    conversion from 'const void*' to 'const tic6x_register*' [-fpermissive]
       const union tic6x_register *regset = buf;
                                            ^
    
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c: At global scope:
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c:359:28: error: redefinition of 'usrregs_info tic6x_usrregs_info'
     static struct usrregs_info tic6x_usrregs_info =
                                ^
    ../binutils-gdb/gdb/gdbserver/linux-tic6x-low.c:186:28: note: 'usrregs_info tic6x_usrregs_info' previously declared here
     static struct usrregs_info tic6x_usrregs_info;
                                ^
    
    gdb/gdbserver:
    
    2017-11-16  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
    	(tic6x_store_gregset): Likewise.
    	(tic6x_usrregs_info): Move it up.

commit be7f7611881bae0fb9e26c892ecd61387d32542d
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 16 00:00:23 2017 +0000

    Automatic date update in version.in

commit a014b87a9ac665d2b92cfc66384d1af3ddd345dd
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Nov 15 11:36:42 2017 -0800

    Include <array> to declare std::array<>.
    
    gdb/ChangeLog:
    
    	* symtab.h: Include <array>.

commit 9476501135dbbe1eb2e104ff219c7988920d23fc
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Nov 15 11:35:15 2017 -0800

    Constify the 'arg' passed to commands in bsd-kvm.c.
    
    gdb/ChangeLog:
    
    	* bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
    	(bsd_kvm_proc_cmd): Likewise.

commit 625ad4406d301f670b823a7767528f3ba7e292c6
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Nov 15 09:22:48 2017 -0500

    tui-win: Replace VEC with std::vector
    
    This patch replaces an instance of VEC (const_char_ptr) with
    std::vector<const char *>.  Tested by running gdb.tui/completion.exp,
    which exercises this function.
    
    gdb/ChangeLog:
    
    	* tui/tui-win.c (window_name_completer): Replace VEC with
    	std::vector.

commit 71774bc994e3f2a09c3b1988dbf2e99b86f53e2e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Nov 15 11:07:02 2017 -0500

    Fix gdb.tui/completion.exp test
    
    When I run it locally, the test gdb.tui/completion.exp test fails
    because of a timeout:
    
    Running /home/emaisin/src/binutils-gdb/gdb/testsuite/gdb.tui/completion.exp ...
    FAIL: gdb.tui/completion.exp: completion of layout names: tab completion (timeout)
    
    The problem seems to be this regex, which confirms that after doing
    layout<TAB>, "layout" is printed again after the gdb prompt:
    
      -re "^$input_line$"
    
    The problem is that there's a trailing space in the output after
    "layout".  Since the regex has an anchored end (the $), it doesn't
    match.  Adding a space fixes the test.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.tui/completionn.exp (test_tab_completion): Add space in
    	regex.

commit 01f48020363f1ca9b31df2ee0b2afedc38db1259
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Wed Nov 15 15:56:23 2017 +0000

    Separate the new FP16 instructions backported from Armv8.4-a to Armv8.2-a into a new flag order to distinguish them from the rest of the already existing optional FP16 instructions in Armv8.2-a.
    
    The new flag "+fp16fml" is available from Armv8.2-a and implies +fp16 and is mandatory
    from Armv8.4-a.
    
    gas/
    
    	* config/tc-arm.c (arm_ext_fp16_fml, fp16fml): New.
    	(do_neon_fmac_maybe_scalar_long): Use arm_ext_fp16_fml.
    	* doc/c-arm.texi (fp16, fp16fml): New.
    	* testsuite/gas/arm/armv8_2-a-fp16.d (fp16): Make fp16fml.
    	* testsuite/gas/arm/armv8_3-a-fp16.d (fp16): Make fp16fml.
    	* testsuite/gas/arm/armv8_2-a-fp16-illegal.d (fp16): Make fp16fml.
    	* testsuite/gas/arm/armv8_2-a-fp16-thumb2.d (fp16): Make fp16fml.
    
    include/
    
    	* opcode/arm.h: (ARM_EXT2_FP16_FML): New.
    	(ARM_AEXT2_V8_4A): Add ARM_EXT2_FP16_FML.

commit c0c11fa91dbbf91b9c9d04384fe9f3ef5a6e7145
Author: Andrew Cagney <cagney@gnu.org>
Date:   Wed Nov 15 10:26:59 2017 -0500

    Remove no-longer applicable maintainer entries
    
    2017-11-15  Andrew Cagney  <cagney@gnu.org>
    
           * MAINTAINERS: Remove no-longer applicable entries.

commit 34a7ebaff9e522913afba4e9cac9d8d5064e5480
Author: Andrew Cagney <cagney@gnu.org>
Date:   Wed Nov 15 10:12:12 2017 -0500

    Move self to Past Maintainers.
    
    2017-11-15  Andrew Cagney  <cagney@gnu.org>
    
          * MAINTAINERS: Move self to Past Maintainers.

commit 5334ef3907e2fbb98aef6839df23e41dccfaf701
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 15 12:03:03 2017 +0000

    Remove features/nios2-linux.c
    
    tdesc_nios2_linux is not used at all.  Remove features/nios2-linux.c,
    and don't generate it anymore.
    
    gdb:
    
    2017-11-15  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (XMLTOC): Remove nios2-linux.xml.
    	* features/nios2-linux.c: Remove.
    	* nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
    	initialize_tdesc_nios2_linux.

commit be74fad95edc8827516e144cf38d135b503249cd
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 15 22:23:22 2017 +1030

    objcopy memory leak
    
    	PR 22426
    	* objcopy.c (copy_main): Free tmpname.

commit a5065160868895e91cac8515263d9783f8120818
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 15 22:16:08 2017 +1030

    Handle ' and I format flags
    
    Also a little tidying and error checking.
    
    	* bfd.c (union _bfd_doprnt_args): Add "Bad".
    	(_bfd_doprnt): Handle more flags.
    	(_bfd_doprnt_scan): Likewise.  Tidy setting of args array.
    	(error_handler_internal): Init args type to Bad.

commit dda8d76d0dd2b07df769f6cae20aff483468b342
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 15 11:34:03 2017 +0000

    Add support to readelf and objdump for following links to separate debug information files.
    
    Hi Guys,
    
      I am applying the rather large patch attached to this email to enhance
      the readelf and objdump programs so that they now have the ability to
      follow links to separate debug info files.  (As requested by PR
      15152).  So for example whereas before we had this output:
    
        $ readelf -wi main.exe
    
        Contents of the .debug_info section:
        [...]
        <15>   DW_AT_comp_dir    : (alt indirect string, offset: 0x30c)
        [...]
    
      With the new option enabled we get:
    
        $ readelf -wiK main.exe
    
        main.exe: Found separate debug info file: dwz.debug
        Contents of the .debug_info section (loaded from main.exe):
        [...]
        <15>   DW_AT_comp_dir    : (alt indirect string, offset: 0x30c) /home/nickc/Downloads/dwzm
        [...]
    
      The link following feature also means that we can get two lots of
      output if the same section exists in both the main file and the
      separate debug info file:
    
        $ readelf -wiK main.exe
        main.exe: Found separate debug info file: dwz.debug
        Contents of the .debug_info section (loaded from main.exe):
        [...]
        Contents of the .debug_info section (loaded from dwz.debug):
        [...]
    
      The patch also adds the ability to display the contents of debuglink
      sections:
    
        $ readelf -wk main.exe
        Contents of the .gnu_debugaltlink section:
    
          Separate debug info file: dwz.debug
          Build-ID (0x14 bytes):
         c4 a8 89 8d 64 cf 70 8a 35 68 21 f2 ed 24 45 3e 18 7a 7a 93
    
      Naturally there are long versions of these options (=follow-links and
      =links).  The documentation has been updated as well, and since both
      readelf and objdump use the same set of debug display options, I have
      moved the text into a separate file.  There are also a couple of new
      binutils tests to exercise the new behaviour.
    
      There are a couple of missing features in the current patch however,
      although I do intend to address them in follow up submissions:
    
      Firstly the code does not check the build-id inside separate debug
      info files when it is searching for a file specified by a
      .gnu_debugaltlink section.  It just assumes that if the file is there,
      then it contains the information being sought.
    
      Secondly I have not checked the DWARF-5 version of these link
      features, so there will probably be code to add there.
    
      Thirdly I have only implemented link following for the
      DW_FORM_GNU_strp_alt format.  Other alternate formats (eg
      DW_FORM_GNU_ref_alt) have yet to be implemented.
    
      Lastly, whilst implementing this feature I found it necessary to move
      some of the global variables used by readelf (eg section_headers) into
      a structure that can be passed around.  I have moved all of the global
      variables that were necessary to get the patch working, but I need to
      complete the operation and move the remaining, file-specific variables
      (eg dynamic_strings).
    
    Cheers
      Nick
    
    binutils	PR 15152
    	* dwarf.h (enum dwarf_section_display_enum): Add gnu_debuglink,
    	gnu_debugaltlink and separate_debug_str.
    	(struct dwarf_section): Add filename field.
    	Add prototypes for load_separate_debug_file, close_debug_file and
    	open_debug_file.
    	* dwarf.c (do_debug_links): New.
    	(do_follow_links): New.
    	(separate_debug_file, separate_debug_filename): New.
    	(fetch_alt_indirect_string): New function.  Retrieves a string
    	from the debug string table in the separate debug info file.
    	(read_and_display_attr_value): Use it with DW_FORM_GNU_strp_alt.
    	(load_debug_section_with_follow): New function.  Like
    	load_debug_section, but if the first attempt fails, then tries
    	again in the separate debug info file.
    	(introduce): New function.
    	(process_debug_info): Use load_debug_section_with_follow and
    	introduce.
    	(load_debug_info): Likewise.
    	(display_debug_lines_raw): Likewise.
    	(display_debug_lines_decoded): Likewise.
    	(display_debug_macinfo): Likewise.
    	(display_debug_macro): Likewise.
    	(display_debug_abbrev): Likewise.
    	(display_debug_loc): Likewise.
    	(display_debug_str): Likewise.
    	(display_debug_aranges): Likewise.
    	(display_debug_addr); Likewise.
    	(display_debug_frames): Likewise.
    	(display_gdb_index): Likewise.
    	(process_cu_tu_index): Likewise.
    	(load_cu_tu_indexes): Likewise.
    	(display_debug_links): New function.  Displays the contents of a
    	.gnu_debuglink or .gnu_debugaltlink section.
    	(calc_gnu_debuglink_ctc32):New function.  Calculates a CRC32
    	value.
    	(check_gnu_debuglink): New function.  Checks the CRC of a
    	potential separate debug info file.
    	(parse_gnu_debuglink): New function.  Reads a CRC value out of a
    	.gnu_debuglink section.
    	(check_gnu_debugaltlink): New function.
    	(parse_gnu_debugaltlink): New function.  Reads the build-id value
    	out of a .gnu_debugaltlink section.
    	(load_separate_debug_info): New function.  Finds and loads a
    	separate debug info file.
    	(load_separate_debug_file): New function. Attempts to find and
    	follow a link to a separate debug info file.
    	(free_debug_memory): Free the separate debug info file
    	information.
    	(opts_table): Add "follow-links" and "links".
    	(dwarf_select_sections_by_letters): Add "k" and "K".
    	(debug_displays): Reformat.  Add .gnu-debuglink and
    	.gnu_debugaltlink.
    	Add an extra entry for .debug_str in a separate debug info file.
    	* doc/binutils.texi: Move description of debug dump features
    	common to both readelf and objdump into...
    	* objdump.c (usage): Add -Wk and -WK.
    	(load_specific_debug_section): Initialise the filename field in
    	the dwarf_section structure.
    	(close_debug_file): New function.
    	(open_debug_file): New function.
    	(dump_dwarf): Load and dump the separate debug info sections.
    	* readelf.c (struct filedata): New structure.  Contains various
    	variables that used to be global:
    	(current_file_size, string_table, string_table_length, elf_header)
    	(section_headers, program_headers, dump_sects, num_dump_sects):
    	Move into filedata structure.
    	(cmdline): New global variable.  Contains list of sections to dump
    	by number, as specified on the command line.
    	Add filedata parameter to most functions.
    	(load_debug_section): Load the string table if it has not already
    	been retrieved.
    	(close_file): New function.
    	(close_debug_file): New function.
    	(open_file): New function.
    	(open_debug_file): New function.
    	(process_object): Process sections in any separate debug info files.
    	* doc/debug.options.texi: New file.  Add description of =links and
    	=follow-links options.
    	* NEWS: Mention the new feature.
    	* elfcomm.c: Have the byte gte functions take a const pointer.
    	* elfcomm.h: Update prototypes.
    	* testsuite/binutils-all/dw5.W: Update expected output.
    	* testsuite/binutils-all/objdump.WL: Update expected output.
    	* testsuite/binutils-all/objdump.exp: Add test of -WK and -Wk.
    	* testsuite/binutils-all/readelf.exp: Add test of -wK and -wk.
    	* testsuite/binutils-all/readelf.k: New file.
    	* testsuite/binutils-all/objdump.Wk: New file.
    	* testsuite/binutils-all/objdump.WK2: New file.
    	* testsuite/binutils-all/linkdebug.s: New file.
    	* testsuite/binutils-all/debuglink.s: New file.
    
    gas	* testsuite/gas/avr/large-debug-line-table.d: Update expected
    	output.
    	* testsuite/gas/elf/dwarf2-11.d: Likewise.
    	* testsuite/gas/elf/dwarf2-12.d: Likewise.
    	* testsuite/gas/elf/dwarf2-13.d: Likewise.
    	* testsuite/gas/elf/dwarf2-14.d: Likewise.
    	* testsuite/gas/elf/dwarf2-15.d: Likewise.
    	* testsuite/gas/elf/dwarf2-16.d: Likewise.
    	* testsuite/gas/elf/dwarf2-17.d: Likewise.
    	* testsuite/gas/elf/dwarf2-18.d: Likewise.
    	* testsuite/gas/elf/dwarf2-5.d: Likewise.
    	* testsuite/gas/elf/dwarf2-6.d: Likewise.
    	* testsuite/gas/elf/dwarf2-7.d: Likewise.
    
    ld	* testsuite/ld-avr/gc-section-debugline.d: Update expected
    	output.

commit a602f924c8e281d40868844b0f0747fadff3f29a
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Wed Nov 15 09:59:12 2017 +0000

    Better make rule for arch/ files built for IPA
    
    gdbserver/
    	* Makefile.in: Update arch rules.
    	* configure.srv: Explicitly mark arch/ files.

commit a714b0d6928ba195623ec2825b00c446939f6e59
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Nov 15 09:36:51 2017 +0000

    Fix M68HC11_NUM_REGS
    
    M68HC11_LAST_HARD_REG is 8, but m68hc11 register number is started from 0,
    so there are 9 raw registers, but M68HC11_NUM_REGS is 8 by mistake.
    
    My following unit test can find this issue (GDB is built with asan)
    
    =================================================================
    ==15555==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x602000113150 at pc 0x51393f bp 0x7fffcec36f60 sp 0x7fffcec36f58
    WRITE of size 2 at 0x602000113150 thread T0
        #0 0x51393e in m68hc11_pseudo_register_read gdb/m68hc11-tdep.c:320
        #1 0xc4b620 in gdbarch_pseudo_register_read(gdbarch*, regcache*, int, unsigned char*) gdb/gdbarch.c:1974
        #2 0xddad88 in regcache::cooked_read(int, unsigned char*) gdb/regcache.c:710
        #3 0xddff2b in cooked_read_test gdb/regcache.c:1850
        #4 0xdf8cfb in selftests::gdbarch_selftest::operator()() const gdb/selftest-arch.c:73
    
    gdb:
    
    2017-11-15  Yao Qi  <yao.qi@linaro.org>
    
    	* m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
    	M68HC11_LAST_HARD_REG + 1.

commit 390a67891e4f1ed334e266cf084ba8948da5fcdf
Author: Jan Beulich <jbeulich@novell.com>
Date:   Wed Nov 15 08:52:05 2017 +0100

    x86: use correct register names
    
    VEX.W may be legitimately set (and is then ignored by the CPU) for
    non-64-bit code. Don't print 64-bit register names in such a case, by
    utilizing that REX_W would never be set for non-64-bit code, and that
    it is being set from VEX.W by generic decoding.
    
    A test for this is going to be introduced in the next patch of this
    series.

commit 3a2430e05b1503653ae09cb21feb2a0d4ea51ec7
Author: Jan Beulich <jbeulich@novell.com>
Date:   Wed Nov 15 08:51:03 2017 +0100

    x86: drop VEXI4_Fixup()
    
    The low four bits of an immediate being set when the high bits specify a
    fourth register operand is not a problem: CPUs ignore these bits rather
    than raising #UD. Take care of incrementing codep in OP_EX_VexW()
    instead.

commit 0645f0a2a75ad77d9786595978591d3f302f9647
Author: Jan Beulich <jbeulich@novell.com>
Date:   Wed Nov 15 08:48:51 2017 +0100

    x86-64: don't allow use of %axl as accumulator
    
    Just like %cxl can't be used as shift count register. Otherwise for
    consistency %cxl would need to gain "ShiftCount" and use of both ought
    to properly cause REX prefixes to be emitted.

commit 99847db8ea741f895d79b9312114c13ccb660d83
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Nov 15 11:35:21 2017 +1030

    ld einfo positional arg support
    
    To allow translators to reorder values in translated strings.  This
    should mean that all binutils messages now have support for
    reordering.
    
    Note to translators:  Not all % letters take arguments, so for example
    the following only has two arguments, the two %s strings.
    "%P%F: output format %s cannot represent section called %s: %E\n"
    
    You could reorder this if you liked to:
    "%P%F: %E: section %2$s cannot be represented in output format %1$s\n"
    
    einfo lacks support for flags, field width, precision and length
    modifier (apart from %ld and %lu) so don't try to use them in
    translations.  Both ld and bfd lack support to use a positional arg
    twice.  These features could be added if needed..
    
    	* ldmisc.c (vfinfo): Support up to 9 positional args.

commit 583712f5ab935948b6c28f1b8b686308f0652ddf
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Nov 14 17:23:14 2017 -0800

    First part of fix for riscv gas lns-common-1 failure.
    
    	gas/
    	* testsuite/gas/lns/lns.exp (lns-common-1): Add riscv*-*-* to alt list.

commit 4fbd5513b100b94b6b9fdb51975f79c38b6b1040
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Nov 14 17:07:32 2017 -0800

    Add modified file I missed in last commit.

commit 754842fba3981b8d9d4d516d6cfc65d3992fa4b2
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Nov 14 17:02:43 2017 -0800

    Fix riscv ld testsuite failure for compressed1d.
    
    	ld/
    	* testsuite/ld-elf/compress1-alt.s: New.
    	* testsuite/ld-elf/compressed1d-alt.d: New.
    	* testsuite/ld-elf/compressed1d.d: Add riscv*-*-* to notarget list.

commit 47f19c17d6eaa45dc756a057c299a5194ad0b75c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Nov 15 00:00:25 2017 +0000

    Automatic date update in version.in

commit 92ffd475192030a46a6046177c732372b4dadad5
Author: Paul Carroll <pcarroll@codesourcery.com>
Date:   Tue Nov 14 17:37:37 2017 -0500

    Fix 'xfered>0' assertion in target.c for remote connection
    
    We have a customer who is using a Corelis gdb server to connect to gdb.
    Occasionally, the gdb server will send a 0-byte block of memory for a
    read.  When this happens, gdb gives an assertion from target.c:
    
    internal-error: target_xfer_partial: Assertion `*xfered_len > 0' failed.
    
    This problem is almost identical to that fixed in
    https://sourceware.org/ml/gdb-patches/2014-02/msg00636.html
    
    In this case, remote.c needs to be modified to return TARGET_XFER_EOF
    instead of TARGET_XFER_OK or TARGET_XFER_UNAVAILABLE when 0 bytes are
    transferred.
    
    gdb/ChangeLog:
    
    	PR gdb/22388
    	* remote.c (remote_write_bytes_aux, remote_read_bytes_1,
    	remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
    	Return TARGET_XFER_EOF if size of returned data is 0.

commit 074319087452e3a8b1a0e84279a82555dd798d69
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Nov 14 16:42:08 2017 -0500

    Fix mem region parsing regression and add test
    
    In my patch
    
      Get rid of VEC (mem_region)
      a664f67e50eff30198097d51cec0ec4690abb2a1
    
    I introduced a regression, where the length of the memory region is
    assigned to the "hi" field.  It should obviously be computed as "start +
    length".  To my defense, no test had caught this :).  As a penance, I
    wrote one.
    
    gdb/ChangeLog:
    
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
    	memory-map-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
    	* memory-map.c (memory_map_start_memory): Fix computation of hi
    	address.
    	* unittests/memory-map-selftests.c: New file.

commit e87d0965bb97fa186749c8386822cdeb9752df38
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 14 08:05:46 2017 -0800

    Add "-z textonly" option to ELF linker

commit 9bd543a56e2b7d1ed85f3baf77fdd9ae77297c37
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 14 07:52:46 2017 -0800

    Revert "Apply "x86: Remove func_pointer_refcount""
    
    This reverts commit 10a3785b1e4ae68bf9c6a2d39eb79aefa44a0e9d.
    
    It has been checked into master branch.

commit 510204745c4c0e2c6c2cacf455e8cb063c6c6e5c
Merge: 10a3785 06bcf54
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 14 07:51:52 2017 -0800

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 06bcf5416feae129e239476ab1408e038bba171d
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 14 18:47:34 2017 +1030

    PR22431, powerpc64 ld segfault when .plt discarded
    
    The fix for the PR is to not use input_section->output_section->owner
    to get to the output bfd, but use the output bfd directly since it is
    available nowadays in struct bfd_link_info.
    
    I thought it worth warning when non-empty dynamic sections are
    discarded too, which meant a tweak to one of the ld tests to avoid the
    warning.
    
    bfd/
    	PR 22431
    	* elf64-ppc.c (ppc64_elf_size_dynamic_sections): Warn on discarding
    	non-empty dynamic section.
    	(ppc_build_one_stub): Take elf_gp from output bfd, not output
    	section owner.
    	(ppc_size_one_stub, ppc64_elf_next_toc_section): Likewise.
    ld/
    	* testsuite/ld-elf/note-3.t: Don't discard .got.

commit 640d0ed874167d73b11dfbf5e838c65cc43e6a63
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Nov 12 17:41:50 2017 +1030

    ld-ifunc non-PIC tests
    
    	* testsuite/ld-ifunc/ifunc.exp: Ensure non-PIC tests are really
    	not PIE by default gcc options.

commit be92cb147d77d0ebc6a084a18627d800a9da9f95
Author: Jan Beulich <jbeulich@novell.com>
Date:   Tue Nov 14 08:43:26 2017 +0100

    x86: add disassembler support for XOP VPCOM* pseudo-ops
    
    Matching up with the assembler, which already supports them.

commit 2645e1d0798da9487def06d14bb744c33dba702d
Author: Jan Beulich <jbeulich@novell.com>
Date:   Tue Nov 14 08:42:26 2017 +0100

    x86: add support for AVX-512 VPCMP*{B,W} pseudo-ops
    
    ... matching up with VPCMP*{D,Q}.

commit df145ef65632dbc6bb31f8d01a088f8600b6c7f1
Author: Jan Beulich <jbeulich@novell.com>
Date:   Tue Nov 14 08:40:48 2017 +0100

    x86: string insns don't allow displacements
    
    Remove the misleading indicators from the table.

commit 2d0d44d514d9a2e2b0f7ae8129d52b02160c9897
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 14 11:02:57 2017 +1030

    Inconsistent .eh_frame_hdr on powerpc64
    
    There is code in bfd/elf-eh-frame.c and ld/emultempl/elf32.em that
    checks for the presence of eh_frame info by testing for a section
    named .eh_frame sized more than 8 bytes.   The size test is to exclude
    a zero terminator.  A similar check in elf64-ppc.c wrongly just tested
    for non-zero size before creating the linker generated .eh_frame
    describing plt call and other linkage stubs.  The intention was to not
    generate that info unless there was some user .eh_frame.  (No user
    .eh_frame implies the user doesn't care about exception handling.)
    Because the test in elf64-ppc.c was wrong, ld generated the stub
    .eh_frame just on finding a zero .eh_frame terminator in crtend.o, but
    didn't generate the corresponding .eh_frame_hdr.
    
    	* elf64-ppc.c (ppc64_elf_size_stubs): Correct test for user
    	.eh_frame info.

commit ddbb44cf366b652dc9edf2ccd4605f1ed0e2e62d
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Mon Nov 13 22:06:02 2017 -0500

    gdb.opt/inline-locals.exp: Remove trailing parentheses in test names
    
    Test names should not end with parentheses, since the buildbot strips
    those.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.opt/inline-locals.exp: Remove trailing parentheses from
    	test names.

commit 8f8a20af3ff322f868ce8adfeb86c6f698265a2a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Nov 14 00:00:24 2017 +0000

    Automatic date update in version.in

commit 58e6cc77b7605e26cbf3fccc166089c01ceee95f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Nov 13 08:19:10 2017 -0800

    ld: Replace exp_dataseg_none with exp_seg_none
    
    	* emultempl/ppc32elf.em (ppc_before_allocation): Replace
    	exp_dataseg_none with exp_seg_none.
    	* emultempl/ppc64elf.em (prelim_size_sections): Likewise.
    	* emultempl/spuelf.em (spu_before_allocation): Likewise.

commit 5616b6c32f7454987ae167ba35589e095c0172fc
Author: Andreas Schwab <schwab@suse.de>
Date:   Mon Nov 13 15:46:09 2017 +0100

    Enable hardware single step for m68k in GDBServer
    
    * linux-m68k-low.c (m68k_supports_hardware_single_step): New
    function.
    (struct linux_target_ops) <supports_hardware_single_step>: Initialize.

commit 5b2b928e83538b23eb1b3f585b14c3d6cf1bfd7e
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:27:45 2017 +0100

    gas/arm64: don't emit stack pointer symbol table entries
    
    Without this change, all of
    
    	mov	z0.b, p0/m, wsp
    	mov	z0.b, wsp
    	mov	z0.d, p0/m, sp
    	mov	z0.d, sp
    
    insert stray symbols into the symbol table.

commit 6465780617638ce65bd7458e30b34ebdc1a99f52
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:26:48 2017 +0100

    gas/ia64: fix testsuite failures
    
    Commit dd90581873 ("Place .shstrtab section after .symtab and .strtab,
    thus restoring monotonically incre... ") adjusted section numbers, but
    forgot to adjust sh_link references from relocation and group section
    table entries.
    
    Additionally some other (perhaps subsequent) change appears to have
    added .rel.* and .rela.* sections to their respective groups, which
    requires some further adjustments to group-2.d. I assume this additional
    breakage wasn't noticed because the test was already failing at that
    time.
    
    This makes the gas testsuite complete successfully again for me in a
    cross build on ix86-linux; there continue to be quite a few ld failures.

commit 5be87c8fa74c9ae6684bea571b4157ad1966d008
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:26:12 2017 +0100

    PE: don't corrupt section flags when linking from ELF objects
    
    Linking EFI executables from ELF object files can result in corrupted
    COFF section flags if the section's alignment is too high. Issue a
    diagnostic in that case, erroring out if this is not a final link, and
    make sure only in-range values get written to the output image.
    
    While doing this also make tic80 use the generic alignment macros
    instead of custom #ifdef-ary.
    
    No testsuite regressions for the range of COFF/PE targets that actually
    cross-build in the first place on x86-64-linux.

commit b76bc5d54e36f15efd954898d9aa075c2bea02dd
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:22:21 2017 +0100

    x86: don't default variable shift count insns to 8-bit operand size
    
    Just like %dx in I/O instructions isn't suitable to derive operand size
    information, %cl source operands of shift instructions aren't.

commit 897e603cb98c50968ea21d1b3baac5bc020ccc06
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:21:29 2017 +0100

    x86: {f,}xsave64 / {f,}xrstor64 / xsaveopt64 should not allow q suffix
    
    Just like is the case for xsave{s,c}64 and xrstors64 already. I wonder
    though why xsave{s,c} and xrstors don't allow for the q suffix, other
    than the other insns without the "64" suffix do.

commit 1187cf29b1f77b4d806c3bbe1fcd86fc7387eeb9
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:20:30 2017 +0100

    x86/Intel: don't mistake riz/eiz as base register
    
    Just like we make rsp/esp a base register even if it comes second, make
    riz/eiz an index register even if it comes first.

commit 2abc2bec4d8c241c1cd3972b64162407128b4daf
Author: Jan Beulich <jbeulich@novell.com>
Date:   Mon Nov 13 12:19:34 2017 +0100

    x86-64/Intel: issue diagnostic for out of range displacement
    
    ... rather than silently dropping it altogether.
    i386_finalize_displacement() expects baseindex to already be set, so
    the respective statement needs to be moved up. This then also allows a
    subsequent conditional to be simplified.
    
    For this to not regress on 32-bit addressing, break out address size
    guessing from i386_index_check(), invoking the new function earlier so
    that i386_finalize_displacement() has i.prefix[ADDR_PREFIX] available.
    i386_addressing_mode () in turn needs i.base_reg / i.index_reg set
    earlier.

commit ed1794ee7a2bd8adc22e5bb8e7343b72758d5692
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Nov 11 07:02:30 2017 -0800

    ld: Add ldlang_check_relro_region/update lang_find_relro_sections_1
    
    Extract GNU_RELRO region check into a new funtion and pass a pointer to
    seg_align_type to lang_find_relro_sections_1 so that they can also be
    used for text-only LOAD segment.
    
    	* ldlang.c (lang_size_sections_1): Extract GNU_RELRO region check
    	into ...
    	(ldlang_check_relro_region): New function.
    	(lang_find_relro_sections_1): Add an argument for pointer to
    	seg_align_type and replace expld.dataseg with the pointer.
    	(lang_find_relro_sections): Pass address of expld.dataseg to
    	lang_find_relro_sections_1.

commit f4d18a54667ded2b50894a3d0740f93825f2a3e8
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 17:23:22 2017 -0800

    cl

commit cba6246d3ad332ab353afeff0016b195ffc69e05
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 17:22:15 2017 -0800

    ld: Add lang_size_relro_segment
    
    Break lang_size_sections down into separate functions so that they can
    also be used for text-only LOAD segment.  lang_size_relro_segment will
    call lang_size_relro_segment_1 and lang_size_segment for both GNU_RELRO
    segment and text-only LOAD segment.
    
    	* ldlang.c (lang_size_segment): New function.
    	(lang_size_relro_segment_1): Likewise.
    	(lang_size_relro_segment): Likewise.
    	(lang_size_sections): Rewrite to call lang_size_relro_segment.

commit d7475e036f69ff7ac78252db74a65fe4d617c4ee
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 17:20:09 2017 -0800

    ld: Add fold_segment_align/fold_segment_relro_end/fold_segment_end
    
    Extract DATA_SEGMENT_END/DATA_SEGMENT_ALIGN/DATA_SEGMENT_RELRO_END cases
    for GNU_RELRO segment into separate functions so that they can also be
    used for text-only LOAD segment.
    
    	* ldexp.c (fold_unary): Extract the DATA_SEGMENT_END case to ...
    	(fold_segment_end): New function.
    	(fold_binary): Extract the DATA_SEGMENT_ALIGN case to ...
    	(fold_segment_align): New function.
    	(fold_binary): Extract the DATA_SEGMENT_RELRO_END case to ...
    	(fold_segment_relro_end): New function.

commit 0f99513f2a52b7d73b94a1f77b8c6de9159b50d7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 17:17:47 2017 -0800

    ld: Update phase_enum/relro_enum and add seg_align_type
    
    Update GNU_RELRO date type so that they can also be used for text-only
    LOAD segment.
    
    	* ldexp.h (phase_enum): Rename exp_dataseg_none,
    	exp_dataseg_align_seen, exp_dataseg_relro_seen,
    	exp_dataseg_end_seen, exp_dataseg_relro_adjust,
    	exp_dataseg_adjust and exp_dataseg_done to exp_seg_none,
    	exp_seg_align_seen, exp_seg_relro_seen, exp_seg_end_seen,
    	exp_seg_relro_adjust, exp_seg_adjust and exp_seg_done.
    	(relro_enum): Rename exp_dataseg_relro_none,
    	exp_dataseg_relro_start and exp_dataseg_relro_end to
    	exp_seg_relro_none, exp_seg_relro_start and exp_seg_relro_end.
    	(seg_align_type): New struct type.
    	(ldexp_control): Use seg_align_type.
    	* ldexp.c (fold_unary): Updated.
    	(fold_binary): Likewise.
    	* ldlang.c (strip_excluded_output_sections): Likewise.
    	(lang_size_sections_1): Likewise.
    	(lang_size_sections): Likewise.

commit f882209d9aa5b68d68c45c5849e129ffc228749c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 17:03:50 2017 -0800

    ld: Remove PF_X from PT_PHDR segment
    
    It was reasonable to mark PT_PHDR segment with PF_X for compatibility
    with UnixWare and Solaris linkers 20 years ago.  But it is inappropriate
    today when the primary OS of GNU ld is Linux.  This patch removes PF_X
    from PT_PHDR segment as gold does.
    
    Tested natively on Linux/x86 as well as crosss-binutils for alpha-linux,
    ia64-linux, powerpc64-linux, powerpc-linux, s390-linux, s390x-linux,
    sparc64-linux and sparc-linux.
    
    bfd/
    
    	PR ld/22423
    	* elf.c (_bfd_elf_map_sections_to_segments): Remove PF_X from
    	PT_PHDR segment.
    
    ld/
    
    	PR ld/22423
    	* testsuite/ld-alpha/tlsbin.rd: Replace "R E " with "R +" for
    	PT_PHDR segment.
    	* testsuite/ld-alpha/tlsbinr.rd: Likewise.
    	* testsuite/ld-ia64/tlsbin.rd: Likewise.
    	* testsuite/ld-powerpc/tlsexe.r: Likewise.
    	* testsuite/ld-powerpc/tlsexe32.r: Likewise.
    	* testsuite/ld-powerpc/tlsexetoc.r: Likewise.
    	* testsuite/ld-s390/tlsbin.rd: Likewise.
    	* testsuite/ld-s390/tlsbin_64.rd: Likewise.
    	* testsuite/ld-sparc/tlssunbin32.rd: Likewise.
    	* testsuite/ld-sparc/tlssunbin64.rd: Likewise.
    	* testsuite/ld-elf/pr22423.d: New test.

commit 53892e6d2395b818554b825cabf6129fed7e2aae
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Nov 13 00:00:24 2017 +0000

    Automatic date update in version.in

commit ce3ad333570333287842ed20f55220534ad4a025
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Nov 12 07:25:26 2017 -0800

    ld: Add OTHER_PLT_SECTIONS
    
    OTHER_PLT_SECTIONS contains sections which should be placed right after
    .plt section.
    
    	* emulparams/elf32_x86_64.sh (TINY_READONLY_SECTION): Renamed
    	to ...
    	(OTHER_PLT_SECTIONS): This.
    	* emulparams/elf_i386.sh: Likewise.
    	* emulparams/elf_iamcu.sh: Likewise.
    	* emulparams/elf_x86_64.sh: Likewise.
    	* scripttempl/elf.sc: Place ${OTHER_PLT_SECTIONS} just after
    	.plt.

commit e3e53eed9c2f1ab82ae4a7683f474b4f6eb162c7
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Nov 12 14:12:41 2017 +1030

    weakdef list handling
    
    The existing code allowed common and indirect symbols to pass an
    assert, but then read root.u.def which is not valid for anything
    besides defined and weakdef symbols.  The garbage root.u.def.section
    pointer read can't possibly match pointers stored at the same location
    for indirect and common symbols, so we would always have left
    u.weakdef NULL.
    
    	* elflink.c (elf_link_add_object_symbols): Ignore anything but
    	defined and defweak symbols when setting up weakdefs.

commit 529fe20eeb0030ea5d653d0ebec433f9e3145874
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Nov 12 17:44:15 2017 +1030

    non_got_ref after adjust_dynamic_relocs
    
    This patch was aimed at a FIXME in elf32-hppa.c, the ludicrous and
    confusing fact that non_got_ref after adjust_dynamic_relocs in that
    backend means precisely the inverse of what it means before
    adjust_dynamic_relocs.  Before, when non_got_ref is set it means there
    are dynamic relocs, after, if non_got_ref is clear it means "keep
    dynamic relocs" and later, "has dynamic relocs".  There is a reason
    why it was done that way..  Some symbols that may have dynamic
    relocations pre-allocated in check_relocs turn out to not be dynamic,
    and then are not seen by the backend adjust_dynamic_symbols.  We want
    those symbols to lose their dynamic relocs when non-pic, so it's handy
    that non_got_ref means the opposite after adjust_dynamic_relocs.  But
    it's really confusing.
    
    Most other targets, like ppc32, don't always set non_got_ref on
    non-GOT references that have dynamic relocations.  This is because the
    primary purpose of non_got_ref before adjust_dynamic_relocs is to flag
    symbols that might need to be copied to .dynbss, and there are
    relocation types that may require dyn_relocs but clearly cannot have
    symbols copied into .dynbss, for example, TLS relocations.
    
    Why do we need a flag after adjust_dynamic_relocs to say "keep
    dynamic relocations"?  Well, you can discard most unwanted dyn_relocs
    in the backend adjust_dynamic_relocs, and for those symbols that
    aren't seen by the backend adjust_dynamic_relocs, in
    allocate_dynrelocs based on a flag set by adjust_dynamic relocs,
    dynamic_adjusted.  That doesn't solve all our difficulties though.
    relocate_section needs to know whether a symbol has dyn_relocs, and
    many targets transfer dyn_relocs to a weakdef if the symbol has one.
    The transfer means relocate_section can't test dyn_relocs itself and
    the weakdef field has been overwritten by that time.  So non_got_ref
    is used to flag "this symbol has dynamic relocations" for
    relocate_section.
    
    Confused still?  Well, let's hope the comments I've added help clarify
    things..  The patch also fixes a case where we might wrongly emit
    dynamic relocations in an executable for common and undefined symbols.
    
    	* elf32-hppa.c (elf32_hppa_adjust_dynamic_symbol): Set non_got_ref
    	to keep dyn_relocs, clear to discard.  Comment.
    	(allocate_dynrelocs): Always clear non_got_ref when clearing
    	dyn_relocs in non-pic case.  Invert non_got_ref test.  Also test
    	dynamic_adjusted and ELF_COMMON_DEF_P.  Move code deleting
    	dyn_relocs on undefined syms to handle for non-pic too.
    	(elf32_hppa_relocate_section): Simplify test for non-pic dyn relocs.
    	* elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Set non_got_ref
    	to keep dyn_relocs, clear to discard.  Comment.
    	(allocate_dynrelocs): Always clear non_got_ref when clearing
    	dyn_relocs in non-pic case.  Invert non_got_ref test.  Also test
    	dynamic_adjusted and ELF_COMMON_DEF_P.  Move code deleting
    	dyn_relocs on undefined syms to handle for non-pic too.
    	(ppc_elf_relocate_section): Simplify test for non-pic dyn relocs.
    	* elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Discard
    	dyn_relocs here.  Don't bother setting non_got_ref.  Comment.
    	(allocate_dynrelocs): Delete special handling of non-pic ELFv2
    	ifuncs.  Move code deleting dyn_relocs on undefined symbols to
    	handle for non-pic too.  Don't test non_got_ref.  Do test
    	dynamic_adjusted and ELF_COMMON_DEF_P.

commit d95639024585ce43e8fe0557ac85e706452e1515
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Nov 12 00:00:18 2017 +0000

    Automatic date update in version.in

commit f617a0f6ceeb34dfd39d8673b0ab225c9127aab6
Author: Jim Wilson <jimw@sifive.com>
Date:   Fri Nov 10 19:24:45 2017 -0800

    Fix riscv binutils xfail for debug_ranges test.
    
    	binutils/
    	* testsuite/binutils-all/objdump.exp: Expect the debug_ranges test to
    	pass.

commit 9080294593eee9e09625e62b2201da57ee150e11
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Nov 11 00:00:20 2017 +0000

    Automatic date update in version.in

commit 09a5b18a6ae9fc5ad30f88d646b7f7313a14929e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Nov 10 00:00:28 2017 +0000

    Automatic date update in version.in

commit 584a564f366de16d1cecd1910ab0be8ca6167415
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:10 2017 +0000

    Fix racy output matching in gdb.tui/tui-completion.exp
    
    'make check-read1 TESTS="gdb.tui/tui-completion.exp"' exposes this test race:
    
      (gdb) PASS: gdb.tui/completion.exp: set max-completions unlimited
      layout ^G
      asm    next   prev   regs   split  src
      (gdb) FAIL: gdb.tui/completion.exp: completion of layout names: tab completion
      Quit
      (gdb) PASS: gdb.tui/completion.exp: completion of layout names: quit command input
      focus ^G
      cmd   next  prev  src
      (gdb) FAIL: gdb.tui/completion.exp: completion of focus command: tab completion
      Quit
    
    This is caused by expecting "$gdb_prompt layout $".
    gdb_test_multiple's internal prompt regexp can match first if expect's
    internal buffer is filled with partial output.  Fix that by splitting
    the gdb_test_multiple in question in two.  Since the same problem/code
    appears twice in the file, factor out a common procedure.
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.tui/tui-completion.exp (test_tab_completion): New procedure,
    	factored out from ...
    	(top level): ... here, and adjusted to avoid expecting beyond the
    	prompt in a single gdb_test_multiple.

commit 5ed7a928acc231ccd13af71cf6df9900250cf884
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:09 2017 +0000

    Fix racy output matching in gdb.base/multi-attach.exp, gdb.server/ext-{attach, restart, ext-run}.exp
    
    This commit fixes this same problem in several places:
    
      (gdb) PASS: gdb.multi/multi-attach.exp: backtrace 2
      kill
      Kill the program being debugged? (y or n) y
      (gdb) FAIL: gdb.multi/multi-attach.exp: kill inferior 2 (got interactive prompt)
    
    This is just another case of the gdb_test_multiple's internal "got
    interactive prompt" pattern matching because the testcase misses
    matching enough.
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.multi/multi-attach.exp ("kill" test): Match the whole query
    	output.
    	* gdb.server/ext-attach.exp ("kill" test): Likewise.
    	* gdb.server/ext-restart.exp ("kill" test): Likewise.
    	* gdb.server/ext-run.exp ("kill" test): Likewise.
    	* gdb.server/ext-wrapper.exp ("kill" test): Likewise.

commit a60e07381c812ab82aff9abae203fd192f460ef4
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:09 2017 +0000

    Fix racy output matching in gdb.base/cpcompletion.exp
    
    With:
    
     $ make check-read1 TESTS="gdb.cp/cpcompletion.exp"
    
    we get (from gdb.log):
    
     (gdb) complete break Foo::
     break Foo::Foo()
     break Foo::Foofoo()
     break Foo::get_foo()
     break Foo::set_foo(int)
     break Foo::~Foo()
     (gdb) FAIL: gdb.cp/cpcompletion.exp: complete class methods (Foo not found)
    
    The problem is that the
      "break ${class}::\[A-Za-z0-9_~\]+"
    regexp patches partial input, like:
      break Foo::F
      break Foo::Fo
      break Foo::Foo
    etc.
    
    Fix that by expecting each whole line.
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.cp/cpcompletion.exp (test_class_complete): Tighten regex to
    	match till end of line.

commit 2c88253fc469fbf40be7f0d1f7060b81055f2eb1
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:08 2017 +0000

    Fix racy output matching in gdb.base/memattr.exp
    
    Testing with:
     $ make check-read1 TESTS="gdb.base/memattr.exp"
    
    
    Exposes a testcase bug that can result in racy fails:
    
      info mem
      Using user-defined memory regions.
      Num Enb Low Addr           High Addr          Attrs
      1   y   0x0000000000601060 0x0000000000601160 wo nocache
      2   y   0x0000000000601180 0x0000000000601280 ro nocache
      4   y   0x0000000000601280 0x0000000000601380 rw nocache
      3   y   0x0000000000601380 0x0000000000601480 rw nocache
      5   y   0x0000000000601480 0x0000000000601580 rw nocache
      (gdb) FAIL: gdb.base/memattr.exp: info mem (1)
    
    The problem is that:
    
      "Attrs\[^\n\r]*.."
    
    matches:
    
      "Attrs \r"
    
    when the output buffer is filled with partial output like this:
    
      "info mem\r\nUsing user-defined memory regions.\r\nNum Enb Low Addr           High Addr          Attrs \r"
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/memattr.exp: Tighten regexes to match the end line.

commit c7a3851716f98540396b9e02be7d2fcd3bff2d29
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:08 2017 +0000

    Fix racy output matching in gdb.base/completion.exp
    
    Testing with:
     $ make check-read1 TESTS="gdb.base/completion.exp"
    
    Exposes a testcase bug that can result in racy fails:
    
      FAIL: gdb.base/completion.exp: command-name completion limiting using tab character
      ERROR: Undefined command "".
      FAIL: gdb.base/completion.exp: symbol-name completion limiting using tab character
      FAIL: gdb.base/completion.exp: symbol-name completion limiting using complete command
    
    testsuite/gdb.log shows:
    
      (gdb) PASS: gdb.base/completion.exp: set max-completions 5
      p^G
      passcount     path          print         print-object  printf
      *** List may be truncated, max-completions reached. ***
      (gdb) FAIL: gdb.base/completion.exp: command-name completion limiting using tab character
      pcomplete p
      Undefined command: "pcomplete".  Try "help".
      (gdb) ERROR: Undefined command "".
    
    The problem is that the expect buffer can get filled with partial
    output that ends in the gdb prompt, and so the default FAIL inside
    gdb_test_multiple matches.
    
    Fix that by splitting the gdb_test_multiple in two stages.  Since that
    is done in more than one place in the testcase, move the otherwise
    duplicate code to helper procedures.
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/completion.exp (ignore_and_resync, test_tab_complete):
    	New procedures, factored out from ...
    	(top level): ... here, and adjusted to avoid expecting beyond the
    	prompt in one go.

commit f29f4b6ba198674096fddf2aa38fa8d028d387b2
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Nov 9 22:44:08 2017 +0000

    Fix racy output matching in gdb.asm/asm-source.exp
    
    Testing with:
     $ make check-read1 TESTS="gdb.asm/asm-source.exp"
    
    Exposes a testcase bug that can result in racy fails:
    
     (gdb) PASS: gdb.asm/asm-source.exp: next over foo3
     return
     Make selected stack frame return now? (y or n) y
     n
     #0  main () at /home/pedro/gdb/mygit/src/gdb/testsuite/gdb.asm/asmsrc1.s:53
     53              gdbasm_exit0
     (gdb) FAIL: gdb.asm/asm-source.exp: return from foo2 (got interactive prompt)
     n
    
    The problem is that the "return now\?.*" regex can match partial
    output like this:
    
     "Make selected stack frame return no"
    
    and then we send the 'y' too early, and then the next time around we
    hit gdb_test_multiple's internal "got interactive prompt" regex.
    
    Also, note we match "return no" instead of "return now" because the
    regex is missing one quote level.
    
    gdb/testsuite/ChangeLog:
    2017-11-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.asm/asm-source.exp ("kill" test): Match the whole query
    	output.  Fix '?' match.

commit fb24d531e9ef7ad7831ca62298d21684717cbe38
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Nov 9 14:36:51 2017 -0800

    ld: Reformat emultempl/elf32.em
    
    Reformat emultempl/elf32.em to generate consistent codes.
    
    	* emultempl/elf32.em (gld${EMULATION_NAME}_get_script): Reformat
    	to generate consistent codes.

commit 31432a672fd40058a714eb2791ea1c3168ccc4f1
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Nov 9 11:58:37 2017 -0800

    fix typos in ada-lang.c comment
    
    gdb/ChangeLog:
    
            * ada-lang.c: Fix some typos in the general command documenting
            how Ada expressions are being evaluated and how their result
            is printed.

commit 52c6b71b65139cad73ada8df81293fd645eac173
Author: Jim Wilson <jimw@sifive.com>
Date:   Thu Nov 9 09:43:59 2017 -0800

    Fix riscv dwarf2-10 gas testsuite failure.
    
    	gas/
    	* testsuite/gas/elf/dwarf2-10.l: Accept optional line number in error.

commit 981b557a488f7c3179dee1e34515ca9b10cf885c
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 9 15:50:56 2017 +0000

    Enable the Dot Product extension by default for Armv8.4-a.
    
    include/
    
    	* opcode/aarch64.h (AARCH64_ARCH_V8_4): Enable DOTPROD.
    
    gas/testsuite
    
    	* gas/aarch64/dotproduct_armv8_4.s: New.
    	* gas/aarch64/dotproduct_armv8_4.d: New.

commit 793a194839bc8add71fdc7429c58b10f0667a6f6
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 9 15:48:43 2017 +0000

    Add assembler and disassembler support for the new Armv8.4-a registers for AArch64.
    
    Some of these instructions have been back-ported as optional extensions to
    Armv8.2-a and higher, but others are only available for Armv8.4-a.
    
    opcodes/
    
    	* aarch64-opc.c (aarch64_sys_regs): Add ARMv8.4-a registers;
    	dit, vstcr_el2, vsttbr_el2, cnthvs_tval_el2, cnthvs_cval_el2,
    	cnthvs_ctl_el2, cnthps_tval_el2, cnthps_cval_el2, cnthps_ctl_el2,
    	sder32_el2, vncr_el2.
    	(aarch64_sys_reg_supported_p): Likewise.
    	(aarch64_pstatefields): Add dit register.
    	(aarch64_pstatefield_supported_p): Likewise.
    	(aarch64_sys_regs_tlbi): Add vmalle1os, vae1os, aside1os, vaae1os,
    	vale1os, vaale1os, ipas2e1os, ipas2le1os, vae2os, vale2os, vmalls12e1os,
    	vae3os, vale3os, alle2os, alle1os, alle3os, rvae1, rvaae1, rvale1,
    	rvaale1, rvae1is, rvaae1is, rvale1is, rvaale1is, rvae1os, rvaae1os,
    	rvale1os, rvaale1os, ripas2e1is, ripas2le1is, ripas2e1, ripas2le1,
    	ripas2e1os, ripas2le1os, rvae2, rvale2, rvae2is, rvale2is, rvae2os,
    	rvale2os, rvae3, rvale3, rvae3is, rvale3is, rvae3os, rvale3os.
    
    gas/testsuite
    
    	* gas/aarch64/armv8_4-a-registers-illegal.d: New.
    	* gas/aarch64/armv8_4-a-registers-illegal.l: New.
    	* gas/aarch64/armv8_4-a-registers-illegal.s: New.
    	* gas/aarch64/armv8_4-a-registers.d: New.
    	* gas/aarch64/armv8_4-a-registers.s: New.

commit 1a7ed57c840dcb0401f1a67c6763a89f7d2686d2
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 9 15:45:00 2017 +0000

    Add the operand encoding types for the new Armv8.2-a back-ported instructions. These are to be used later when the new instructions are added.
    
    opcodes/
    	* aarch64-tbl.h (QL_SHA512UPT, QL_V2SAME2D, QL_V3SAME2D): New.
    	(QL_V4SAME16B, QL_V4SAME4S, QL_XAR, QL_SM3TT, QL_V3FML2S): New.
    	(QL_V3FML4S, QL_V2FML2S, QL_V2FML4S, QL_RMIF, QL_SETF): New.
    	(QL_STLW, QL_STLX): New.

commit f42f1a1d6ca0cc84e43d7f2b85044a2565ca00f2
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 9 15:22:30 2017 +0000

    Adds the new Fields and Operand types for the new instructions in Armv8.4-a.
    
    gas/
    	* config/tc-aarch64.c (process_omitted_operand):
    	Add AARCH64_OPND_Va, AARCH64_OPND_SM3_IMM2
    	and AARCH64_OPND_IMM_2.
    	(parse_operands): Add AARCH64_OPND_Va, AARCH64_OPND_SM3_IMM2,
    	AARCH64_OPND_IMM_2, AARCH64_OPND_MASK
    	and AARCH64_OPND_ADDR_OFFSET.
    
    include/
    	* opcode/aarch64.h:
    	(aarch64_opnd): Add AARCH64_OPND_Va, AARCH64_OPND_MASK,
    	AARCH64_OPND_IMM_2, AARCH64_OPND_ADDR_OFFSET
    	and AARCH64_OPND_SM3_IMM2.
    	(aarch64_insn_class): Add cryptosm3 and cryptosm4.
    	(arch64_feature_set): Make uint64_t.
    
    opcodes/
    	* aarch64-asm.h (ins_addr_offset): New.
    	* aarch64-asm.c (aarch64_ins_reglane): Add cryptosm3.
    	(aarch64_ins_addr_offset): New.
    	* aarch64-asm-2.c: Regenerate.
    	* aarch64-dis.h (ext_addr_offset): New.
    	* aarch64-dis.c (aarch64_ext_reglane): Add cryptosm3.
    	(aarch64_ext_addr_offset): New.
    	* aarch64-dis-2.c: Regenerate.
    	* aarch64-opc.h (aarch64_field_kind): Add FLD_imm6_2,
    	FLD_imm4_2 and FLD_SM3_imm2.
    	* aarch64-opc.c (fields): Add FLD_imm6_2,
    	FLD_imm4_2 and FLD_SM3_imm2.
    	(operand_general_constraint_met_p): Add AARCH64_OPND_ADDR_OFFSET.
    	(aarch64_print_operand): Add AARCH64_OPND_Va, AARCH64_OPND_SM3_IMM2,
    	AARCH64_OPND_MASK, AARCH64_OPND_IMM_2 and AARCH64_OPND_ADDR_OFFSET.
    	* aarch64-opc-2.c (Va, MASK, IMM_2, ADDR_OFFSET, SM3_IMM2): New.
    	* aarch64-tbl.h
    	(aarch64_opcode_table): Add Va, MASK, IMM_2, ADDR_OFFSET, SM3_IMM2.

commit e793c052f9d9548442a46817998a46cbca4ccb70
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Nov 2 12:48:44 2017 -0600

    Simplify the psymbol hash function
    
    This patch simplifies the psymbol_hash function, by changing it not to
    examine the contents of the symbol's name.  This change just mirrors
    what psymbol_compare already does -- it is checking for name equality,
    which is ok because symbol names are interned in symbol_set_names.
    
    This change speeds up psymbol reading.  "gdb -nx -batch gdb"
    previously took ~1.8 seconds on my machine, and with this patch it now
    takes ~1.7 seconds.
    
    gdb/ChangeLog
    2017-11-09  Tom Tromey  <tom@tromey.com>
    
    	* psymtab.c (psymbol_hash): Do not hash string contents.
    	(psymbol_compare): Add comment.

commit 7e8835c5f44931d02ecd8c8ba3d167e891981d24
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 11:15:06 2017 -0600

    Speed up dict_hash
    
    This speeds up dict_hash a bit, by moving the "TKB" check into the
    switch in the loop.
    
    For "gdb -nx -readnow -batch gdb", this improves the time from ~9.8s
    before to ~8.5s afterward.
    
    gdb/ChangeLog
    2017-11-09  Tom Tromey  <tom@tromey.com>
    
    	* dictionary.c (dict_hash): Move "TKB" check into the "switch".

commit b6b9ca0c3ec9589d0dd40b2b86ba748a361b48eb
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Thu Nov 9 11:21:31 2017 +0000

    Split the ARM Crypto ISA extensions for AES and SHA1+2 into their own options (+aes and +sha2).  The reason for the split is because with the introduction of Armv8.4-a the implementation of AES has explicitly been made independent of the implementation of the other crypto extensions.
    
    gas	* config/tc-aarch64.c (aarch64_arch_option_table): Add armv8.4-a.
    	(aarch64_features):	Added SM4 and SHA3.
    
    include	* opcode/aarch64.h:
    	(AARCH64_FEATURE_V8_4, AARCH64_FEATURE_SM4): New.
    	(AARCH64_ARCH_V8_4, AARCH64_FEATURE_SHA3): New.
    
    opcodes	* aarch64-tbl.h
    	(aarch64_feature_v8_4, aarch64_feature_crypto_v8_2): New.
    	(aarch64_feature_sm4, aarch64_feature_sha3): New.
    	(aarch64_feature_fp_16_v8_2): New.
    	(ARMV8_4, SHA3, SM4, CRYPTO_V8_2, FP_F16_V8_2): New.
    	(V8_4_INSN, CRYPTO_V8_2_INSN): New.
    	(SHA3_INSN, SM4_INSN, FP16_V8_2_INSN): New.

commit 21b81e67c73368dbbc9f6356ac5a7eb274789a32
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Nov 9 10:28:32 2017 +0000

    Change the type of the aarch64_feature_set typedef to unsigned long long so that it will work on 32-bit hosts.
    
    	* opcode/aarch64.h (aarch64_feature_set): Change type to unsigned
    	long long.

commit 286acbb5c25c5895832d3dd3be3398d3f2d64fad
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Mar 3 17:31:13 2017 +0100

    local variable watchpoint not deleted after leaving scope
    
    When debugging an Ada program, and inserting a watchpoint tracking
    a local variable, the watchpoint doesn't get automatically deleted
    upon leaving that variable's scope. This watchpoint then starts
    creating problems later on, when trying to resume the program's
    execution from a location outside of the watchpoint's scope:
    
        (gdb) c
        Continuing.
    
        Breakpoint 2, foo_p708_025 () at foo_p708_025.adb:7
        7	   Do_Nothing (Val);
        (gdb) n
        No frame is currently executing in block pck.get_val.
        Command aborted.
        (gdb) c
        Continuing.
        No frame is currently executing in block pck.get_val.
        Command aborted.
    
    The expected output is the following:
    
      - The program's execution after the first continue should stop
        as soon as we reach the end of the watchpoint's scope, and
        the debugger should be deleting it.
    
      - Then we can continue until reaching breakpoint 2 above;
    
      - After which we should be able to do next/continue as usual.
    
    The reason the watchpoint is not automatically deleted at scope exit
    is because the watchpoint is not marked as being scope-specific
    (b->exp_valid_block is equal NULL), and this is because the
    symbol lookup for our local variable failed to set the innermost_block
    global variable during the lookup.
    
    More precisely, if we look at watch_command_1, we do the following:
    
      innermost_block = NULL;
      [...]
      exp = parse_exp_1 (&arg, 0, 0, 0);
      [...]
      exp_valid_block = innermost_block;
    
    Currently, innermost_block stays NULL after the call to parse_exp_1.
    
    Digging further, this innermost_block is typically set during symbol
    lookup when the symbol is considered to have a frame-relative address.
    For instance, in c-exp.y, we see some code like the following:
    
       if (symbol_read_needs_frame (sym.symbol))
         {
           if (innermost_block == 0
               || contained_in (sym.block,
                                innermost_block))
             innermost_block = sym.block;
         }
    
    We actually have the exact same mechanism in ada-exp.y, except
    that it vhas accidently been turned off. See write_var_from_sym,
    where we start with:
    
       if (orig_left_context == NULL && symbol_read_needs_frame (sym))
         {
           if (innermost_block == 0
               || contained_in (block, innermost_block))
             innermost_block = block;
         }
    
    In this case, orig_left_context is a parameter, and looking at
    the point of call in write_var_or_type, we see:
    
              if (nsyms == 1)
                {
                  write_var_from_sym (par_state, block, syms[0].block,
                                      syms[0].symbol);
    
    In the call above, the paramater we are interested in is "block",
    which is a parameter for write_var_or_type as well, except we
    explicitly override its value at the beginning when found to be NULL:
    
      if (block == NULL)
        block = expression_context_block;
    
    So the block we pass to write_var_from_sym is not NULL, and
    we therefore don't set innermost_block, which leads to the watchpoint
    no longer being marked as scope-specific.
    
    The handling of orig_left_context in write_var_from_sym was there
    to handle the case where a user writes an expression where the symbol
    is qualified with a scope (Eg: "function::variable"). But it appears
    that handling this is specifically here is no longer necessary,
    so this patch simply removes that parameter and the associated check,
    and then updates all the points of calls.
    
    Interestingly, this also affects GDB/MI, and in particular varobjs,
    because local variables are now properly reported as having a block,
    which causes the associated varob to have a "thread-id" field.
    This patch also adjusts a couple of Ada/gdb-mi tests.
    
    gdb/ChangeLog:
    
            * ada-exp.y (write_var_from_sym): Remove parameter
            "orig_left_context".  Update all callers.
    
    gdb/testsuite/ChangeLog:
    
            * gdb.ada/scoped_watch: New testcase.
            * gdb.ada/watch_arg.exp: Adjust expected behavior to the behavior
            which is actually correct.
            * gdb.ada/mi_interface.exp: Add missing thread-id in expected varobj.
            * gdb.ada/mi_var_array.exp: Add missing thread-id in expected varobj.

commit b44ec61915f10a953ca85da5bf7a97911554f1aa
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Nov 8 19:42:08 2017 -0500

    Make encode_actions_rsp use std::vector
    
    Currently, encode_actions_rsp returns two malloc'ed arrays of malloc'ed
    strings (char *) by pointer.  Change this to use
    std::vector<std::string>.  This eliminates some cleanups in remote.c.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* tracepoint.h (class collection_list) <stringify>: Return
    	std::vector<std::string>.
    	(encode_actions_rsp): Change parameters to
    	std::vector<std::string> *.
    	* tracepoint.c (collection_list::stringify): Return
    	std::vector<std::string> and adjust accordingly.
    	(encode_actions_rsp): Changee parameters to
    	std::vector<std::string> and adjust accordingly.
    	* remote.c (free_actions_list),
    	free_actions_list_cleanup_wrapper): Remove.
    	(remote_download_tracepoint): Adjust to std::vector.

commit dc8d2d90da3f191ae0461900ab98e3b29cc2b280
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Nov 8 15:56:54 2017 -0800

    gold: Ignore def/ref from a dynamic object for special symbols
    
    Since special symbol must be defined in a regular object, definition
    from a dynamic object should be ignored.  If special symbol has the
    hidden or internal visibility, reference from a dynamic object should
    also be ignored.  Also __start and __stop symbols in a dynamic object
    shouldn't be preempted.
    
    	PR gold/22291
    	* layout.cc (Layout::define_section_symbols): Use STV_PROTECTED
    	for __start and __stop symbols.
    	* symtab.cc (Symbol_table::define_special_symbol): Add an
    	argument, visibility.  Ignore definition and reference from
    	a dynamic object, depending on visibility.
    	(Symbol_table::do_define_in_output_data): Pass visibility to
    	define_special_symbol.
    	(Symbol_table::do_define_in_output_segment): Likewise.
    	(Symbol_table::do_define_as_constant): Likewise.
    	(Symbol_table::add_undefined_symbol_from_command_line): Pass
    	STV_DEFAULT to define_special_symbol.
    	* symtab.h (Symbol_table::define_special_symbol): Add an
    	argument, visibility.

commit cb1a122cce8a7eefe1025d8d189c52f96da6138f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 9 00:00:11 2017 +0000

    Automatic date update in version.in

commit 62d7ae92341b53ef10b709464edca759d6738500
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 23:42:11 2017 +0000

    Avoid expensive complaint calls when complaints are disabled
    
    Running perf on "gdb -nx -readnow -batch gdb", I'm seeing a lot of
    time (24%.75!) spent in gettext, via complaints.  'perf report -g' shows:
    
     -   86.23%     0.00%  gdb      gdb                     [.] gdb_main
        - gdb_main
           - 85.60% catch_command_errors
                symbol_file_add_main_adapter
                symbol_file_add_main
                symbol_file_add_main_1
                symbol_file_add
              - symbol_file_add_with_addrs
                 - 84.31% dw2_expand_all_symtabs
                    - dw2_instantiate_symtab
                       - 83.79% dw2_do_instantiate_symtab
                          - 70.85% process_die
                             - 41.11% dwarf_decode_macros
                                - 41.09% dwarf_decode_macro_bytes
                                   - 39.74% dwarf_decode_macro_bytes
       >>>>>>>>>>>>>>>>>>>>>>>        + 24.75% __dcigettext              <<<<<<<
                                      + 7.37% macro_define_object_internal
                                      + 3.16% macro_define_function
                                        0.77% splay_tree_insert
                                      + 0.76% savestring
                                      + 0.58% free
                                        0.53% read_indirect_string_at_offset_from
                                     0.54% macro_define_object_internal
                                     0.51% macro_start_file
                             + 25.57% process_die
                             + 4.07% dwarf_decode_lines
                          + 4.28% compute_delayed_physnames
                          + 3.85% end_symtab_from_static_block
                          + 3.38% load_cu
                          + 1.29% end_symtab_get_static_block
                       + 0.52% do_my_cleanups
                 + 1.29% read_symbols
           + 0.54% gdb_init
    
    The problem is that we're always computing the arguments to pass to
    complaint, including passing the format strings through gettext, even
    when complaints are disabled.  As seen above, gettext can be quite
    expensive.
    
    Fix this by wrapping complaint in a macro that skips the real
    complaint call when complaints are disabled.
    
    This improves "gdb -nx -readnow -batch gdb" from
     ~11.0s => ~7.8s with -O2 -g3, and
      ~6.0s => ~5.3s with -O2 -g.
    w/ gcc 5.3.1, on x86_64, for me.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* complaints.c (stop_whining): Make extern.
    	(complaint): Rename to ...
    	(complaint_internal): ... this.
    	* complaints.h (complaint): Rename to ...
    	(complaint_internal): ... this.
    	(complaint): Reimplement as macro around complaint_internal.
    
    gdb/testsuite/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* gdb.gdb/complaints.exp (test_initial_complaints)
    	(test_serial_complaints, test_short_complaints): Call
    	complaint_internal instead of complaint.

commit 333d0055f6f162c334c36f1946b6fcdb5c92b681
Author: James Clarke <jrtc27@jrtc27.com>
Date:   Wed Nov 8 15:13:53 2017 -0800

    Fix problems with -r.
    
    The fix committed for PR gold/19291 ended up breaking other cases. The
    commit added adjustment code to write_local_symbols, but in many cases
    compute_final_local_value_internal had already subtracted the output
    section's address. To fix this, all other adjustments are now removed, so
    only the one in write_local_symbols is left.
    
    gold/
    	PR gold/22266
    	* object.cc (Sized_relobj_file::compute_final_local_value_internal):
    	Drop relocatable parameter and stop adjusting output value based on
    	it.
    	(Sized_relobj_file::compute_final_local_value): Stop passing
    	relocatable to compute_final_local_value_internal.
    	(Sized_relobj_file::do_finalize_local_symbols): Ditto.
    	* object.h (Sized_relobj_file::compute_final_local_value_internal):
    	Drop relocatable parameter.

commit 08228b11557016f6f12d537ebff5f169fdf9bc6c
Author: Eric Christopher <echristo@gmail.com>
Date:   Wed Nov 8 14:03:55 2017 -0800

    Apply:
    
    2017-11-08  Kyle Butt  <iteratee@google.com>
    
            * object.cc (do_find_special_sections): Fix a thinko with memmem return
            values and check for != NULL rather than == 0.

commit 280ca31f4d608082e1b61cd0b6d90fdc3450b9f3
Author: Djordje Todorovic <djordje.todorovic@rt-rk.com>
Date:   Wed Nov 8 21:19:05 2017 +0000

    Add test for fetching TLS from core file
    
    A correct PID is needed by `libthread_db' library supplied with
    glibc repository revisions before commit c579f48edba8 ("Remove
    cached PID/TID in clone") or versions before 2.25 release for
    GDB to fetch value of TLS variable from core file.  On MIPS
    platforms it was omitted and fetching value of TLS variable was not
    available.
    
    This adds a new test in order to be sure if GDB on native platforms
    can successfully fetch value of TLS variable.
    
    gdb/testsuite:
    
    	* gdb.threads/tls-core.c: New file.
    	* gdb.threads/tls-core.exp: Likewise.

commit c9ec0e8945d057979a361e3545d42b3f15adf04a
Author: Djordje Todorovic <djordje.todorovic@rt-rk.com>
Date:   Wed Nov 8 21:19:05 2017 +0000

    BFD: Extract PID from MIPS core dump file
    
    On MIPS o32, n32 and n64 platforms, PID information was not
    correctly propagated from core dump file to internal GDB
    structures.  This patch fixes that behavior.
    
    A correct PID is needed by `libthread_db' library supplied with
    glibc repository revisions before commit c579f48edba8 ("Remove
    cached PID/TID in clone") or released versions before 2.25 for
    GDB to fetch value of TLS variable from core file.
    
    bfd/ChangeLog:
    
    	* elf32-mips.c (elf32_mips_grok_psinfo): Extract core->pid.
    	* elf64-mips.c (elf64_mips_grok_psinfo): Likewise.
    	* elfn32-mips.c (elf32_mips_grok_psinfo): Likewise.

commit 9031cb4af0adcf1c73cb9b8c73ca2d989023af2f
Author: Djordje Todorovic <djordje.todorovic@rt-rk.com>
Date:   Wed Nov 8 21:19:05 2017 +0000

    BFD: Write Linux core PRSTATUS note into MIPS core file
    
    On MIPS o32, n32 and n64 platforms information such as PID was not
    correctly written into core file from GDB.
    
    This fixes that behavior.
    
    bfd/ChangeLog:
    
    	* elf32-mips.c (elf32_mips_write_core_note): New function.
    	(elf_backend_write_core_note): New macro.
    	* elf64-mips.c (elf64_mips_write_core_note): New function.
    	(elf_backend_write_core_note): New macro.
    	* elfn32-mips.c (elf32_mips_write_core_note): New function.
    	(elf_backend_write_core_note): New macro.

commit 2f4732b0e622d9d5d899c29e2132e4cd2966aaad
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Nov 3 14:55:39 2017 -0600

    Remove symbolp vector
    
    This removes the symbolp typedef from dwarf2read.c and converts the
    associated VEC uses to std::vector.  This fixes a latent possible
    memory leak if an exception were thrown, because there were no
    cleanups installed for these VECs.
    
    Regression tested on the buildbot.
    
    gdb/ChangeLog
    2017-11-08  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2read.c (symbolp): Remove typedef.
    	(read_func_scope): Use std::vector.
    	(process_structure_scope): Use std::vector.

commit f9d67a22392f8f52c779f68a2561eb35c2f86b81
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:34 2017 +0000

    Make the linespec/location completer ignore data symbols
    
    Currently "b foo[TAB]" offers data symbols as completion candidates.
    This doesn't make sense, since you can't set a breakpoint on data
    symbols, only on code symbols.
    
     (gdb) b globa[TAB]
     (gdb) b global [ENTER]
     Function "global" not defined.
     Make breakpoint pending on future shared library load? (y or [n]) n
     (gdb) info symbol global
     global in section .rodata
    
    So this patch makes linespec completion ignore data symbols.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_make_symbol_completion_list): Use
    	completion_skip_symbol.
    	* symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
    	(symbol_is_function_or_method(symbol*)): New.
    	(add_symtab_completions): Add complete_symbol_mode parameter.  Use
    	completion_skip_symbol.
    	(default_collect_symbol_completion_matches_break_on): Use
    	completion_skip_symbol.  Pass down mode.
    	(collect_file_symbol_completion_matches): Pass down mode.
    	* symtab.h (symbol_is_function_or_method): New declarations.
    	(completion_skip_symbol): New template function.

commit 56d87ef769e6adab27af77fa86ea294ee7c6ee72
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:34 2017 +0000

    Use search_domain::FUNCTIONS_DOMAIN when setting breakpoints
    
    While working on C++ support for wild matching, I noticed that
    attaching to my system's Firefox (which uses .gdb_index), setting a
    break at main and bailing, like:
    
      $ gdb --batch -q -p `pidof firefox` -ex "b main"
    
    would get substancially slower.  It'd take around 20s when currently
    it takes 3s.
    
    The problem is that gdb would expand more symtabs than currently,
    because Firefox has symbols named like "nsHtml5Atoms::main",
    "nsGkAtoms::main", etc., which given wild matching, match.
    
    However, these are not function symbols, [they're "(nsIAtom *)"], so
    it seems silly that they'd cause expansion in the first place.
    
    The .gdb_index code (dwarf2read.c:dw2_expand_marked_cus) filters out
    symbols matches based on search_domain:
    
      case VARIABLES_DOMAIN:
        if (symbol_kind != GDB_INDEX_SYMBOL_KIND_VARIABLE)
          continue;
        break;
      case FUNCTIONS_DOMAIN:
        if (symbol_kind != GDB_INDEX_SYMBOL_KIND_FUNCTION)
          continue;
        break;
      case TYPES_DOMAIN:
        if (symbol_kind != GDB_INDEX_SYMBOL_KIND_TYPE)
          continue;
        break;
      default:
        break;
    
    however, we're currently passing down search_domain::ALL_DOMAIN when
    we know we're looking for functions, for no good reason.  This patch
    fixes that.
    
    It seems like search_domain is underutilized throughout, but I'll
    leave using it more for another pass.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* linespec.c (iterate_over_all_matching_symtabs): Add
    	search_domain parameter.  Pass it down to expand_symtabs_matching.
    	(decode_objc): Request FUNCTIONS_DOMAIN symbols only.
    	(lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
    	search_domain.
    	(add_all_symbol_names_from_pspace): Add search_domain parameter.
    	Pass it down.
    	(find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
    	symbols.
    	(add_matching_symbols_to_info): Add search_domain parameter.  Pass
    	it down.

commit 1b0261195e3f11932c0f5657a74028f5814168eb
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:34 2017 +0000

    Simplify completion_list_add_name | remove sym_text / sym_text_len
    
    sym_text_len existed to strip parameters out of the lookup name.  Now
    that that's handled by the lookup_name_info objects, the
    sym_text/sym_text_len parameters are no longer necessary.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_make_symbol_completion_list): Remove text and
    	text_len locals and don't pass them down.
    	* symtab.c (completion_list_add_name): Remove
    	sym_text/sym_text_len parameters and adjust.
    	(completion_list_add_symbol, completion_list_add_msymbol)
    	(completion_list_objc_symbol, completion_list_add_fields)
    	(add_symtab_completions): Likewise.
    	(default_collect_symbol_completion_matches_break_on)
    	(collect_file_symbol_completion_matches): Remove sym_text_len
    	local and don't pass it down.
    	* symtab.h (completion_list_add_name): Remove
    	sym_text/sym_text_len parameters.

commit c62446b12b32ce57d2b40cdb0c1baa7fc1677d82
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:49:10 2017 +0000

    lookup_name_info::make_ignore_params
    
    A few places in the completion code look for a "(" to find a
    function's parameter list, in order to strip it, because psymtabs (and
    gdb index) don't include parameter info in the symbol names.
    
    See compare_symbol_name and
    default_collect_symbol_completion_matches_break_on.
    
    This is too naive.  Consider:
    
     ns_overload2_test::([TAB]
    
    We'd want to complete that to:
     ns_overload2_test::(anonymous namespace)::struct_overload2_test
    
    Or:
    
     b (anonymous namespace)::[TAB]
    
    That currently completes to:
    
     b (anonymous namespace)
    
    Which is obviously broken.  This patch makes that work.
    
    Also, the current compare_symbol_name hack means that while this
    works:
    
     "b function([TAB]"  ->  "b function()"
    
    This does not:
    
     "b function ([TAB]"
    
    This patch fixes that.  Whitespace "ignoring" now Just Works, i.e.,
    assuming a symbol named "function(int, long)", this:
     b function (   int , lon[TAB]
    completes to:
     b function (   int , long)
    
    To address all of this, this patch builds on top of the rest of the
    series, and pushes the responsibility of stripping parameters from a
    lookup name to the new lookup_name_info object, where we can apply
    per-language rules.  Also note that we now only make a version of the
    lookup name with parameters stripped out where it's actually required
    to do that, in the psymtab and GDB index code.
    
    For C++, the right way to strip parameters is with "cp_remove_params",
    which uses a real parser (cp-name-parser.y) to split the name into a
    component tree and then discards parameters.
    
    The trouble for completion is that in that case we have an incomplete
    name, like "foo::func(int" and thus cp_remove_params throws an error.
    
    This patch sorts that by adding a cp_remove_params_if_any variant of
    cp_remove_params that tries removing characters from the end of the
    string until cp_remove_params works.  So cp_remove_params_if_any
    behaves like this:
    
    With a complete name:
    
       "foo::func(int)"  => foo::func(int)  # cp_remove_params_1 succeeds the first time.
    
    With an incomplete name:
    
       "foo::func(int"  => NULL             # cp_remove_params fails the first time.
       "foo::func(in"   => NULL             # and again...
       "foo::func(i"    => NULL             # and again...
       "foo::func("     => NULL             # and again...
       "foo::func"      => "foo::func"      # success!
    
    Note that even if this approach removes significant rightmost
    characters, it's still OK, because this parameter stripping is only
    necessary for psymtabs and gdb index, where we're determining whether
    to expand a symbol table.  Say cp_remove_params_if_any returned
    "foo::" above for "foo::func(int".  That'd cause us to expand more
    symtabs than ideal (because we'd expand all symtabs with symbols that
    start with "foo::", not just "foo::func"), but then when we actually
    look for completion matches, we'd still use the original lookup name,
    with parameter information ["foo::func(int"], and thus we'll return no
    false positive to the user.  Whether the stripping works as intended
    and doesn't strip too much is thus covered by a unit test instead of a
    testsuite test.
    
    The "if_any" part of the name refers to the fact that while
    cp_remove_params returns NULL if the input name has no parameters in
    the first place, like:
    
       "foo::func"      => NULL         # cp_remove_params
    
    cp_remove_params_if_any still returns the function name:
    
       "foo::func"      => "foo::func"  # cp_remove_params_if_any
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
    	unittests/lookup_name_info-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
    	* cp-support.c: Include "selftest.h".
    	(cp_remove_params_1): Rename from cp_remove_params.  Add
    	'require_param' parameter, and handle it.
    	(cp_remove_params): Reimplement.
    	(cp_remove_params_if_any): New.
    	(selftests::quote): New.
    	(selftests::check_remove_params): New.
    	(selftests::test_cp_remove_params): New.
    	(_initialize_cp_support): Install
    	selftests::test_cp_remove_params.
    	* cp-support.h (cp_remove_params_if_any): Declare.
    	* dwarf2read.c :Include "selftest.h".
    	(dw2_expand_symtabs_matching_symbol): Use
    	lookup_name_info::make_ignore_params.
    	(selftests::dw2_expand_symtabs_matching::mock_mapped_index)
    	(selftests::dw2_expand_symtabs_matching::string_or_null)
    	(selftests::dw2_expand_symtabs_matching::check_match)
    	(selftests::dw2_expand_symtabs_matching::test_symbols)
    	(selftests::dw2_expand_symtabs_matching::run_test): New.
    	(_initialize_dwarf2_read): Register
    	selftests::dw2_expand_symtabs_matching::run_test.
    	* psymtab.c (psym_expand_symtabs_matching): Use
    	lookup_name_info::make_ignore_params.
    	* symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
    	If the lookup name wants to ignore parameters, strip them.
    	(compare_symbol_name): Remove sym_text/sym_text_len parameters and
    	code handling '('.
    	(completion_list_add_name): Don't pass down sym_text/sym_text_len.
    	(default_collect_symbol_completion_matches_break_on): Don't try to
    	strip parameters.
    	* symtab.h (lookup_name_info::lookup_name_info): Add
    	'ignore_parameters' parameter.
    	(lookup_name_info::ignore_parameters)
    	(lookup_name_info::make_ignore_params): New methods.
    	(lookup_name_info::m_ignore_parameters): New field.
    	* unittests/lookup_name_info-selftests.c: New file.

commit 61920122ba93d58cc2e8c78a30475c569c2506fd
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:32 2017 +0000

    Reorder/reindent dw2_expand_symtabs_matching & friends
    
    The previous patch had added dw2_expand_symtabs_matching_symbol and
    dw2_expand_marked_cus forward declarations and did not reindent
    dw2_expand_marked_cus to avoid moving the code around while changing
    it at the same time.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (dw2_expand_marked_cus)
    	(dw2_expand_symtabs_matching_symbol): Remove forward declarations.
    	(dw2_expand_symtabs_matching): Move further below.
    	(dw2_expand_marked_cus): Reindent.

commit 3f563c840a2c891ec2868b3e08bfaecb6f7aa57f
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:32 2017 +0000

    Optimize .gdb_index symbol name searching
    
    As mentioned in the previous patch, .gdb_index name lookup got
    significantly slower with the previous patch.
    
    This patch addresses that, and in the process makes .gdb_index name
    searching faster than what we had before the previous patch, even.
    Using the same test:
    
     $ cat script.cmd
     set pagination off
     set $count = 0
     while $count < 400
       complete b string_prin
       printf "count = %d\n", $count
       set $count = $count + 1
     end
    
     $ time gdb --batch -q ./gdb-with-index -ex "source script.cmd"
    
    I got, before the previous patch (-O2, x86-64):
    
     real    0m1.773s
     user    0m1.737s
     sys     0m0.040s
    
    and after this patch:
    
     real    0m1.361s
     user    0m1.315s
     sys     0m0.040s
    
    The basic idea here is simple: instead of always iterating over all
    the symbol names in the index, we build an accelerator/sorted name
    table and binary search names in it.
    
    Later in the series, we'll want to support wild matching for C++ too,
    so this mechanism already considers that.  For example, say that
    you're looking up functions/methods named "func", no matter the
    containing namespace/class.  If we sorted the table by qualified name,
    then we obviously wouldn't be able to find those symbols with a binary
    search:
    
      func
      ns1::a::b::func
      ns1::b::func
      ns2::func
    
    (function symbol names in .gdb_index have no parameter info, like psymbols)
    
    To address that out, we put an entry for each name component in the
    sorted table.  something like this:
    
      Table Entry       Actual symbol
      ---------------------------------
      func              func
    
      func              ns1::a::b::func
      b::func           ns1::a::b::func
      a::b::func        ns1::a::b::func
      ns1::a::b::func   ns1::a::b::func
    
      func              ns1::b::func
      b::func           ns1::b::func
      ns1::b::func      ns1::b::func
    
      func              ns2::func
      ns2::func         ns2::func
    
    Which sorted results in this:
    
      Table Entry       Actual symbol
      ---------------------------------
      a::b::func        ns1::a::b::func
      b::func           ns1::a::b::func
      b::func           ns1::b::func
      func              func
      func              ns1::a::b::func
      func              ns1::b::func
      func              ns2::func
      ns1::a::b::func   ns1::a::b::func
      ns1::b::func      ns1::b::func
      ns2::func         ns2::func
    
    And we can binary search this.
    
    Note that a binary search approach works for both completion and
    regular lookup, while a name hashing approach only works for normal
    symbol looking, since obviously "fun" and "func" have different
    hashes.
    
    At first I was a bit wary of these tables potentially growing GDB's
    memory significantly.  But I did an experiment that convinced it's not
    a worry at all.  I hacked gdb to count the total number of entries in
    all the tables, attached that gdb to my system/Fedora's Firefox
    (Fedora's debug packages uses .gdb_index), did "set max-completions
    unlimited", and then hit "b [TAB]" to cause everything to expand.
    
    That resulted in 1351355 name_components.  Each entry takes 8 bytes,
    so that's 10810840 bytes (ignoring std::vector overhead), or ~10.3 MB.
    That's IMO too small to worry about, given GDB was using over 7400MB
    total at that point.  I.e., we're talking about 0.1% increase.
    
    dw2_expand_symtabs_matching unit tests covering this will be added in
    a follow up patch.
    
    If the size of this table turns out to be a concern, I have an idea to
    reduce the size of the table further at the expense of a bit more code
    -- the vast majority of the name offsets are either 0 or fit in
    8-bits:
    
     total name_component = 1351355, of which,
     name_component::name_offset instances need  0 bits = 679531
     name_component::name_offset instances need  8 bits = 669526
     name_component::name_offset instances need 16 bits = 2298
     name_component::name_offset instances need 32 bits = 0
     name_component::idx instances need 0 bits  = 51
     name_component::idx instances need 8 bits  = 8361
     name_component::idx instances need 16 bits = 280329
     name_component::idx instances need 32 bits = 1062614
    
    so we could have separate tables for 0 name_offset, 8-bit name_offset
    and 32-bit name_offset.  That'd give us roughly:
    
     679531 * 0 + 669526 * 1 + 2298 * 4 + 1062614 * 4 = 4929174, or ~4.7MB
    
    with only 8-bit and 32-bit tables, that'd be:
    
     1349057 * 1 + 2298 * 4 + 4 * 1351355 = 6763669 bytes, or ~6.5MB.
    
    I don't think we need to bother though.
    
    I also timed:
    
     $ time gdb --batch -q -p `pidof firefox`
     $ time gdb --batch -q -p `pidof firefox` -ex "b main"
     $ time gdb --batch -q -p `pidof firefox` -ex "set max-completion unlimited" -ex "complete b "
    
    and compared before previous patch vs this patch, and I didn't see a
    significant difference, seemingly because time to read debug info
    dominates.  The "complete b " variant of the test takes ~2min
    currently...  (I have a follow up series that speeds that up
    somewhat.)
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
    	(struct name_component): New.
    	(mapped_index::name_components): New field.
    	(mapped_index::symbol_name_at): New method.
    	(dwarf2_read_index): Call mapped_index ctor.
    	(dw2_map_matching_symbols): Add comment about name_components
    	table.
    	(dw2_expand_symtabs_matching): Factor part to...
    	(dw2_expand_symtabs_matching_symbol): ... this new function.
    	Build name components table, and lookup symbols in it before
    	calling the name matcher.
    	(dw2_expand_marked_cus): New, factored out from
    	dw2_expand_symtabs_matching.
    	(dwarf2_per_objfile_free): Call the mapped_index's dtor.

commit b5ec771e60c1a0863e51eb491c85c674097e9e13
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 14:22:32 2017 +0000

    Introduce lookup_name_info and generalize Ada's FULL/WILD name matching
    
    Summary:
     - This is preparation for supporting wild name matching on C++ too.
     - This is also preparation for TAB-completion fixes.
     - Makes symbol name matching (think strcmp_iw) be based on a per-language method.
     - Merges completion and non-completion name comparison (think
       language_ops::la_get_symbol_name_cmp generalized).
     - Avoid re-hashing lookup name multiple times
     - Centralizes preparing a name for lookup (Ada name encoding / C++ Demangling),
       both completion and non-completion.
     - Fixes Ada latent bug with verbatim name matches in expressions
     - Makes ada-lang.c use common|symtab.c completion code a bit more.
    
    Ada's wild matching basically means that
    
     "(gdb) break foo"
    
    will find all methods named "foo" in all packages.  Translating to
    C++, it's roughly the same as saying that "break klass::method" sets
    breakpoints on all "klass::method" methods of all classes, no matter
    the namespace.  A following patch will teach GDB about fullname vs
    wild matching for C++ too.  This patch is preparatory work to get
    there.
    
    Another idea here is to do symbol name matching based on the symbol
    language's algorithm.  I.e., avoid dependency on current language set.
    
    This allows for example doing
    
      (gdb) b foo::bar< int > (<tab>
    
    and having gdb name match the C++ symbols correctly even if the
    current language is C or Assembly (or Rust, or Ada, or ...), which can
    easily happen if you step into an Assembly/C runtime library frame.
    
    By encapsulating all the information related to a lookup name in a
    class, we can also cache hash computation for a given language in the
    lookup name object, to avoid recomputing it over and over.
    
    Similarly, because we don't really know upfront which languages the
    lookup name will be matched against, for each language we store the
    lookup name transformed into a search name.  E.g., for C++, that means
    demangling the name.  But for Ada, it means encoding the name.  This
    actually forces us to centralize all the different lookup name
    encoding in a central place, resulting in clearer code, IMO.  See
    e.g., the new ada_lookup_name_info class.
    
    The lookup name -> symbol search name computation is also done only
    once per language.
    
    The old language->la_get_symbol_name_cmp / symbol_name_cmp_ftype are
    generalized to work with both completion, and normal symbol look up.
    
    At some point early on, I had separate completion vs non-completion
    language vector entry points, but a single method ends up being better
    IMO for simplifying things -- the more we merge the completion /
    non-completion name lookup code paths, the less changes for bugs
    causing completion vs normal lookup finding different symbols.
    
    The ada-lex.l change is necessary because when doing
    
      (gdb) p <UpperCase>
    
    then the name that is passed to write_ write_var_or_type ->
    ada_lookup_symbol_list misses the "<>", i.e., it's just "UpperCase",
    and we end up doing a wild match against "UpperCase" lowercased by
    ada_lookup_name_info's constructor.  I.e., "uppercase" wouldn't ever
    match "UpperCase", and the symbol lookup fails.
    
    This wouldn't cause any regression in the testsuite, but I added a new
    test that would pass before the patch and fail after, if it weren't
    for that fix.
    
    This is latent bug that happens to go unnoticed because that
    particular path was inconsistent with the rest of Ada symbol lookup by
    not lowercasing the lookup name.
    
    Ada's symbol_completion_add is deleted, replaced by using common
    code's completion_list_add_name.  To make the latter work for Ada, we
    needed to add a new output parameter, because Ada wants to return back
    a custom completion candidates that are not the symbol name.
    
    With this patch, minimal symbol demangled name hashing is made
    consistent with regular symbol hashing.  I.e., it now goes via the
    language vector's search_name_hash method too, as I had suggested in a
    previous patch.
    
    dw2_expand_symtabs_matching / .gdb_index symbol names were a
    challenge.  The problem is that we have no way to telling what is the
    language of each symbol name found in the index, until we expand the
    corresponding full symbol, which is off course what we're trying to
    avoid.  Language information is simply not considered in the index
    format...  Since the symbol name hashing and comparison routines are
    per-language, we now have a problem.  The patch sorts this out by
    matching each name against all languages.  This is inneficient, and
    indeed slows down completion several times.  E.g., with:
    
     $ cat script.cmd
     set pagination off
     set $count = 0
     while $count < 400
       complete b string_prin
       printf "count = %d\n", $count
       set $count = $count + 1
     end
    
     $ time gdb --batch -q ./gdb-with-index -ex "source script-string_printf.cmd"
    
    I get, before patch (-O2, x86-64):
    
     real    0m1.773s
     user    0m1.737s
     sys     0m0.040s
    
    While after patch (-O2, x86-64):
    
     real    0m9.843s
     user    0m9.482s
     sys     0m0.034s
    
    However, the following patch will optimize this, and will actually
    make this use case faster compared to the "before patch" above:
    
     real    0m1.321s
     user    0m1.285s
     sys     0m0.039s
    
    gdb/ChangeLog:
    2017-11-08   Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_encode): Rename to ..
    	(ada_encode_1): ... this.  Add throw_errors parameter and handle
    	it.
    	(ada_encode): Reimplement.
    	(match_name): Delete, folded into full_name.
    	(resolve_subexp): No longer pass the encoded name to
    	ada_lookup_symbol_list.
    	(should_use_wild_match): Delete.
    	(name_match_type_from_name): New.
    	(ada_lookup_simple_minsym): Use lookup_name_info and the
    	language's symbol_name_matcher_ftype.
    	(add_symbols_from_enclosing_procs, ada_add_local_symbols)
    	(ada_add_block_renamings): Adjust to use lookup_name_info.
    	(ada_lookup_name): New.
    	(add_nonlocal_symbols, ada_add_all_symbols)
    	(ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
    	(ada_iterate_over_symbols): Adjust to use lookup_name_info.
    	(ada_name_for_lookup): Delete.
    	(ada_lookup_encoded_symbol): Construct a verbatim name.
    	(wild_match): Reverse sense of return type.  Use bool.
    	(full_match): Reverse sense of return type.  Inline bits of old
    	match_name here.
    	(ada_add_block_symbols): Adjust to use lookup_name_info.
    	(symbol_completion_match): Delete, folded into...
    	(ada_lookup_name_info::matches): ... .this new method.
    	(symbol_completion_add): Delete.
    	(ada_collect_symbol_completion_matches): Add name_match_type
    	parameter.  Adjust to use lookup_name_info and
    	completion_list_add_name.
    	(get_var_value, ada_add_global_exceptions): Adjust to use
    	lookup_name_info.
    	(ada_get_symbol_name_cmp): Delete.
    	(do_wild_match, do_full_match): New functions.
    	(ada_lookup_name_info::ada_lookup_name_info): New method.
    	(ada_symbol_name_matches, ada_get_symbol_name_matcher): New
    	functions.
    	(ada_language_defn): Install ada_get_symbol_name_matcher.
    	* ada-lex.l (processId): If name starts with '<', copy it
    	verbatim.
    	* block.c (block_iter_match_step, block_iter_match_first)
    	(block_iter_match_next, block_lookup_symbol)
    	(block_lookup_symbol_primary, block_find_symbol): Adjust to use
    	lookup_name_info.
    	* block.h (block_iter_match_first, block_iter_match_next)
    	(ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
    	* c-lang.c (c_language_defn, cplus_language_defn)
    	(asm_language_defn, minimal_language_defn): Adjust comments to
    	refer to la_get_symbol_name_matcher.
    	* completer.c (complete_files_symbols)
    	(collect_explicit_location_matches, symbol_completer): Pass a
    	symbol_name_match_type down.
    	* completer.h (class completion_match, completion_match_result):
    	New classes.
    	(completion_tracker::reset_completion_match_result): New method.
    	(completion_tracker::m_completion_match_result): New field.
    	* cp-support.c (make_symbol_overload_list_block): Adjust to use
    	lookup_name_info.
    	(cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
    	functions.
    	* cp-support.h (cp_get_symbol_name_matcher): New declaration.
    	* d-lang.c: Adjust comments to refer to
    	la_get_symbol_name_matcher.
    	* dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
    	Adjust to use lookup_name_info.
    	(dict_iter_match_first, dict_iter_match_next)
    	(iter_match_first_hashed, iter_match_next_hashed)
    	(iter_match_first_linear, iter_match_next_linear): Adjust to work
    	with a lookup_name_info.
    	* dictionary.h (dict_iter_match_first, dict_iter_match_next):
    	Likewise.
    	* dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
    	(dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
    	(gdb_index_symbol_name_matcher): New class.
    	(dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
    	gdb_index_symbol_name_matcher.  Accept a NULL symbol_matcher.
    	* f-lang.c (f_collect_symbol_completion_matches): Adjust to work
    	with a symbol_name_match_type.
    	(f_language_defn): Adjust comments to refer to
    	la_get_symbol_name_matcher.
    	* go-lang.c (go_language_defn): Adjust comments to refer to
    	la_get_symbol_name_matcher.
    	* language.c (default_symbol_name_matcher)
    	(language_get_symbol_name_matcher): New functions.
    	(unknown_language_defn, auto_language_defn): Adjust comments to
    	refer to la_get_symbol_name_matcher.
    	* language.h (symbol_name_cmp_ftype): Delete.
    	(language_defn) <la_collect_symbol_completion_matches>: Add match
    	type parameter.
    	<la_get_symbol_name_cmp>: Delete field.
    	<la_get_symbol_name_matcher>: New field.
    	<la_iterate_over_symbols>: Adjust to use lookup_name_info.
    	(default_symbol_name_matcher, language_get_symbol_name_matcher):
    	Declare.
    	* linespec.c (iterate_over_all_matching_symtabs)
    	(iterate_over_file_blocks): Adjust to use lookup_name_info.
    	(find_methods): Add language parameter, and use lookup_name_info
    	and the language's symbol_name_matcher_ftype.
    	(linespec_complete_function): Adjust.
    	(lookup_prefix_sym): Use lookup_name_info.
    	(add_all_symbol_names_from_pspace): Adjust.
    	(find_superclass_methods): Add language parameter and pass it
    	down.
    	(find_method): Pass symbol language down.
    	(find_linespec_symbols): Don't demangle or Ada encode here.
    	(search_minsyms_for_name): Add lookup_name_info parameter.
    	(add_matching_symbols_to_info): Add name_match_type parameter.
    	Use lookup_name_info.
    	* m2-lang.c (m2_language_defn): Adjust comments to refer to
    	la_get_symbol_name_matcher.
    	* minsyms.c: Include <algorithm>.
    	(add_minsym_to_demangled_hash_table): Remove table parameter and
    	add objfile parameter.  Use search_name_hash, and add language to
    	demangled languages vector.
    	(struct found_minimal_symbols): New struct.
    	(lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
    	New functions.
    	(lookup_minimal_symbol): Adjust to use them.  Don't canonicalize
    	input names here.  Use lookup_name_info instead.  Lookup up
    	demangled names once for each language in the demangled names
    	vector.
    	(iterate_over_minimal_symbols): Use lookup_name_info.  Lookup up
    	demangled names once for each language in the demangled names
    	vector.
    	(build_minimal_symbol_hash_tables): Adjust.
    	* minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
    	lookup_name_info.
    	* objc-lang.c (objc_language_defn): Adjust comment to refer to
    	la_get_symbol_name_matcher.
    	* objfiles.h: Include <vector>.
    	(objfile_per_bfd_storage) <demangled_hash_languages>: New field.
    	* opencl-lang.c (opencl_language_defn): Adjust comment to refer to
    	la_get_symbol_name_matcher.
    	* p-lang.c (pascal_language_defn): Adjust comment to refer to
    	la_get_symbol_name_matcher.
    	* psymtab.c (psym_lookup_symbol): Use lookup_name_info.
    	(match_partial_symbol): Use symbol_name_match_type,
    	lookup_name_info and psymbol_name_matches.
    	(lookup_partial_symbol): Use lookup_name_info.
    	(map_block): Use symbol_name_match_type and lookup_name_info.
    	(psym_map_matching_symbols): Use symbol_name_match_type.
    	(psymbol_name_matches): New.
    	(recursively_search_psymtabs): Use lookup_name_info and
    	psymbol_name_matches.  Rename 'kind' parameter to 'domain'.
    	(psym_expand_symtabs_matching): Use lookup_name_info.  Rename
    	'kind' parameter to 'domain'.
    	* rust-lang.c (rust_language_defn): Adjust comment to refer to
    	la_get_symbol_name_matcher.
    	* symfile-debug.c (debug_qf_map_matching_symbols)
    	(debug_qf_map_matching_symbols): Use symbol_name_match_type.
    	(debug_qf_expand_symtabs_matching): Use lookup_name_info.
    	* symfile.c (expand_symtabs_matching): Use lookup_name_info.
    	* symfile.h (quick_symbol_functions) <map_matching_symbols>:
    	Adjust to use symbol_name_match_type.
    	<expand_symtabs_matching>: Adjust to use lookup_name_info.
    	(expand_symtabs_matching): Adjust to use lookup_name_info.
    	* symmisc.c (maintenance_expand_symtabs): Use
    	lookup_name_info::match_any ().
    	* symtab.c (symbol_matches_search_name): New.
    	(eq_symbol_entry): Adjust to use lookup_name_info and the
    	language's matcher.
    	(demangle_for_lookup_info::demangle_for_lookup_info): New.
    	(lookup_name_info::match_any): New.
    	(iterate_over_symbols, search_symbols): Use lookup_name_info.
    	(compare_symbol_name): Add language, lookup_name_info and
    	completion_match_result parameters, and use them.
    	(completion_list_add_name): Make extern.  Add language and
    	lookup_name_info parameters.  Use them.
    	(completion_list_add_symbol, completion_list_add_msymbol)
    	(completion_list_objc_symbol): Add lookup_name_info parameters and
    	adjust.  Pass down language.
    	(completion_list_add_fields): Add lookup_name_info parameters and
    	adjust.  Pass down language.
    	(add_symtab_completions): Add lookup_name_info parameters and
    	adjust.
    	(default_collect_symbol_completion_matches_break_on): Add
    	name_match_type parameter, and use it.  Use lookup_name_info.
    	(default_collect_symbol_completion_matches)
    	(collect_symbol_completion_matches): Add name_match_type
    	parameter, and pass it down.
    	(collect_symbol_completion_matches_type): Adjust.
    	(collect_file_symbol_completion_matches): Add name_match_type
    	parameter, and use lookup_name_info.
    	* symtab.h: Include <string> and "common/gdb_optional.h".
    	(enum class symbol_name_match_type): New.
    	(class ada_lookup_name_info): New.
    	(struct demangle_for_lookup_info): New.
    	(class lookup_name_info): New.
    	(symbol_name_matcher_ftype): New.
    	(SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
    	(symbol_matches_search_name): Declare.
    	(MSYMBOL_MATCHES_SEARCH_NAME): Delete.
    	(default_collect_symbol_completion_matches)
    	(collect_symbol_completion_matches)
    	(collect_file_symbol_completion_matches): Add name_match_type
    	parameter.
    	(iterate_over_symbols): Use lookup_name_info.
    	(completion_list_add_name): Declare.
    	* utils.c (enum class strncmp_iw_mode): Moved to utils.h.
    	(strncmp_iw_with_mode): Now extern.
    	* utils.h (enum class strncmp_iw_mode): Moved from utils.c.
    	(strncmp_iw_with_mode): Declare.
    
    gdb/testsuite/ChangeLog:
    2017-11-08   Pedro Alves  <palves@redhat.com>
    
    	* gdb.ada/complete.exp (p <Exported_Capitalized>): New test.
    	(p Exported_Capitalized): New test.
    	(p exported_capitalized): New test.

commit 5ffa0793690b42b2a0c1c21dbb5e64634e58fa00
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 15:07:56 2017 +0000

    Per-language symbol name hashing algorithm
    
    Currently, we have a mess of symbol name hashing/comparison routines.
    There's msymbol_hash for mangled names, and dict_hash and
    msymbol_hash_iw for demangled names.  Then there's strcmp_iw,
    strcmp_iw_ordered and Ada's full_match/wild_match, which all have to
    agree with the hashing routines.  That's why dict_hash is really about
    Ada names.  From the inconsistency department, minimal symbol hashing
    doesn't go via dict_hash, so Ada's wild matching can't ever work with
    minimal symbols.
    
    This patch starts fixing this, by doing two things:
    
    #1 - adds a language vector method to let each language decide how to
         compute a symbol name hash.
    
    #2 - makes dictionaries know the language of the symbols they hold,
         and then use the dictionaries language to decide which hashing
         method to use.
    
    For now, this is just scaffolding, since all languages install the
    default method.  The series will make C++ install its own hashing
    method later on, and will add per-language symbol name comparison
    routines too.
    
    This patch was originally based on a patch that Keith wrote for the
    libcc1/C++ WIP support.
    
    gdb/ChangeLog:
    2017-11-08  Keith Seitz  <keiths@redhat.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_language_defn): Install
    	default_search_name_hash.
    	* buildsym.c (struct buildsym_compunit): <language>: New field.
    	(finish_block_internal): Pass language when creating dictionaries.
    	(start_buildsym_compunit, start_symtab): New language parameters.
    	Use them.
    	(restart_symtab): Pass down compilation unit's language.
    	* buildsym.h (enum language): Forward declare.
    	(start_symtab): New 'language' parameter.
    	* c-lang.c (c_language_defn, cplus_language_defn)
    	(asm_language_defn, minimal_language_defn): Install
    	default_search_name_hash.
    	* coffread.c (coff_start_symtab): Adjust.
    	* d-lang.c (d_language_defn): Install default_search_name_hash.
    	* dbxread.c (struct symloc): Add 'pst_language' field.
    	(PST_LANGUAGE): Define.
    	(start_psymtab, read_ofile_symtab): Use it.
    	(process_one_symbol): New 'language' parameter.  Pass it down.
    	* dictionary.c (struct dictionary) <language>: New field.
    	(DICT_LANGUAGE): Define.
    	(dict_create_hashed, dict_create_hashed_expandable)
    	(dict_create_linear, dict_create_linear_expandable): New parameter
    	'language'.  Set the dictionary's language.
    	(iter_match_first_hashed): Adjust to rename.
    	(insert_symbol_hashed): Assert we don't see mismatching
    	languages.  Adjust to rename.
    	(dict_hash): Rename to ...
    	(default_search_name_hash): ... this and make extern.
    	* dictionary.h (struct language_defn): Forward declare.
    	(dict_create_hashed): New parameter 'language'.
    	* dwarf2read.c (dwarf2_start_symtab): Pass down language.
    	* f-lang.c (f_language_defn): Install default_search_name_hash.
    	* go-lang.c (go_language_defn): Install default_search_name_hash.
    	* jit.c (finalize_symtab): Pass compunit's language to dictionary
    	creation.
    	* language.c (unknown_language_defn, auto_language_defn):
    	* language.h (language_defn::la_search_name_hash): New field.
    	(default_search_name_hash): Declare.
    	* m2-lang.c (m2_language_defn): Install default_search_name_hash.
    	* mdebugread.c (new_block): New parameter 'language'.
    	* mdebugread.c (parse_symbol): Pass symbol language to block
    	allocation.
    	(psymtab_to_symtab_1): Pass down language.
    	(new_symtab): Pass compunit's language to block allocation.
    	* objc-lang.c (objc_language_defn): Install
    	default_search_name_hash.
    	* opencl-lang.c (opencl_language_defn):
    	* p-lang.c (pascal_language_defn): Install
    	default_search_name_hash.
    	* rust-lang.c (rust_language_defn): Install
    	default_search_name_hash.
    	* stabsread.h (enum language): Forward declare.
    	(process_one_symbol): Add 'language' parameter.
    	* symtab.c (search_name_hash): New function.
    	* symtab.h (search_name_hash): Declare.
    	* xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.

commit 2a1dde5da23779fd0d269c3e51c7814aba9001dd
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Nov 8 15:20:41 2017 +0000

    Fix "make test-cp-name-parser"
    
    src/gdb/cp-name-parser.y: In function â??int main(int, char**)â??:
    src/gdb/cp-name-parser.y:2132:30: error: ISO C++ forbids converting a string constant to â??char*â?? [-Werror=write-strings]
       char *str2, *extra_chars = "", c;
                                  ^
    
    Simply don't initialize the variable, it's not necessary.
    
    gdb/ChangeLog:
    2017-11-08  Pedro Alves  <palves@redhat.com>
    
    	* cp-name-parser.y (main): Don't initialize extra_chars.

commit 2841837fac18861bb62e039a20321075d1e76248
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 8 14:34:32 2017 +0000

    Fix typo in changelog

commit c0e7cef7156b2bc15ba43441ad14c6e83c09df8e
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 8 14:30:53 2017 +0000

    Split the AArch64 Crypto instructions for AES and SHA1+2 into their own options (+aes and +sha2).
    
    The new options are:
    
    	+aes: Enables the AES instructions of Armv8-a,
    	      enabled by default with +crypto.
    
    	+sha2: Enables the SHA1 and SHA2 instructions of Armv8-a,
    	       enabled by default with +crypto.
    
    These options have been turned on by default when +crypto
    is used, as such no breakage is expected.
    
    The reason for the split is because with the introduction of Armv8.4-a
    the implementation of AES has explicitly been made independent of the
    implementation of the other crypto extensions. Backporting the split does
    not break any of the previous requirements and so is safe to do.
    
    gas	* config/tc-aarch64.c
    	(aarch64_features): Include AES and SHA2 in CRYPTO.
    	Add SHA2 and AES.
    
    include	* opcode/aarch64.h:
    	(AARCH64_FEATURE_SHA2, AARCH64_FEATURE_AES): New.
    
    opcodes	* aarch64-tbl.h (aarch64_feature_crypto): Add AES and SHA2.
    	(aarch64_feature_sha2, aarch64_feature_aes): New.
    	(SHA2, AES): New.
    	(AES_INSN, SHA2_INSN): New.
    	(pmull, pmull2, aese, aesd, aesmc, aesimc): Change to AES_INS.
    	(sha1h, sha1su1, sha256su0, sha1c, sha1p,
    	 sha1m, sha1su0, sha256h, sha256h2, sha256su1):
    	Change to SHA2_INS.

commit dec41383fff7116c9f66cdeca3105e968047a4e6
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Nov 8 13:15:12 2017 +0000

    Adds command line support for Armv8.4-A, via the new command line option -march=armv8.4-a.  Add support for "+dotprod" ARM feature (required for ARMv8.4-A).  Add assembler and disassembler support for new FP16 instructions introduced in Armv8.4-A
    
    gas	* config/tc-arm.c (arm_extensions):
    	(arm_archs): New entry for "armv8.4-a".
    	Add FPU_ARCH_DOTPROD_NEON_VFP_ARMV8.
    	(arm_ext_v8_2): New variable.
    	(enum arm_reg_type): New enumeration REG_TYPE_NSD.
    	(reg_expected_msgs): New entry for REG_TYPE_NSD.
    	(parse_typed_reg_or_scalar): Handle REG_TYPE_NSD.
    	(parse_scalar): Support REG_TYPE_VFS.
    	(enum operand_parse_code): New enumerations OP_RNSD and OP_RNSD_RNSC.
    	(parse_operands): Handle OP_RNSD and OP_RNSD_RNSC.
    	(NEON_SHAPE_DEF): New entries for DHH and DHS.
    	(neon_scalar_for_fmac_fp16_long): New function to generate Rm encoding
    	for new FP16 instructions in ARMv8.2-A.
    	(do_neon_fmac_maybe_scalar_long): New function to encode new FP16
    	instructions in ARMv8.2-A.
    	(do_neon_vfmal): Wrapper function for vfmal.
    	(do_neon_vfmsl): Wrapper function for vfmsl.
    	(insns): New entries for vfmal and vfmsl.
    	* doc/c-arm.texi (-march): Document "armv8.4-a".
    	* testsuite/gas/arm/dotprod-mandatory.d: New test.
    	* testsuite/gas/arm/armv8_2-a-fp16.s: New test source.
    	* testsuite/gas/arm/armv8_2-a-fp16-illegal.s: New test source.
    	* testsuite/gas/arm/armv8_2-a-fp16.d: New test.
    	* testsuite/gas/arm/armv8_3-a-fp16.d: New test.
    	* testsuite/gas/arm/armv8_4-a-fp16.d: New test.
    	* testsuite/gas/arm/armv8_2-a-fp16-thumb2.d: New test.
    	* testsuite/gas/arm/armv8_2-a-fp16-illegal.d: New test.
    	* testsuite/gas/arm/armv8_2-a-fp16-illegal.l: New error file.
    
    opcodes	* arm-dis.c (coprocessor_opcodes): New entries for ARMv8.2-A new
    	FP16 instructions, including vfmal.f16 and vfmsl.f16.
    
    include	* opcode/arm.h (ARM_AEXT2_V8_4A): Include Dot Product feature.
    	(ARM_EXT2_V8_4A): New macro.
    	(ARM_AEXT2_V8_4A): Likewise.
    	(ARM_ARCH_V8_4A): Likewise.

commit 6e98b3428bdd0bf388c3c72eb205105926b15a64
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 7 17:03:41 2017 +1030

    xtensa message pluralization
    
    	* config/tc-xtensa.c (finish_vinsn): Properly pluralize error message.

commit b346cb961f729e2955391513a5b05eaf02b308ea
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Nov 8 00:00:20 2017 +0000

    Automatic date update in version.in

commit 95a6b0a106fac6ea35670421534d461a3663c0ba
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 15 08:36:51 2017 -0600

    Constify execute_command
    
    This constifies execute_command and fixes up the callers.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* event-top.h (command_handler): Constify.
    	* record-full.c (cmd_record_full_start): Update.
    	* thread.c (thread_apply_all_command): Update.
    	* printcmd.c (eval_command): Update.
    	* mi/mi-main.c (mi_execute_cli_command): Update.
    	(mi_execute_async_cli_command): Update.
    	* tui/tui-stack.c (tui_update_command): Update.
    	* cli/cli-interp.c (safe_execute_command): Constify.
    	* record.c (record_start): Update.
    	(record_start, record_stop, cmd_record_start): Update.
    	* record-btrace.c (cmd_record_btrace_bts_start): Update.
    	(cmd_record_btrace_pt_start): Update.
    	(cmd_record_btrace_start): Update.
    	(cmd_record_btrace_start): Update.
    	* reverse.c (exec_reverse_once): Update.
    	* python/python.c (execute_gdb_command): Don't copy the command.
    	* event-top.c (command_line_handler): Update.
    	(command_handler): Constify.
    	* defs.h (deprecated_call_command_hook): Constify.
    	* cli/cli-script.h (execute_user_command): Constify.
    	* cli/cli-script.c (execute_user_command): Constify.
    	(execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
    	(enum command_control_type): Update.
    	* main.c (catch_command_errors): Remove non-const overload.
    	(catch_command_errors_ftype): Remove.
    	* python/py-cmd.c (cmdpy_function): Constify.
    	* guile/scm-cmd.c (cmdscm_function): Constify.
    	* cli/cli-dump.c (call_dump_func): Constify.
    	* cli/cli-decode.c (do_const_cfunc): Constify.
    	(do_sfunc): Constify.
    	(cmd_func): Constify.
    	* gdbcmd.h (execute_command, execute_command_to_string): Constify.
    	* top.h (execute_command): Constify.
    	* top.c (execute_command): Constify.
    	(execute_command_to_string): Constify.
    	(deprecated_call_command_hook): Constify.
    	* command.h (cmd_func): Constify.
    	* cli/cli-decode.h (struct cmd_list_element) <func>: Constify.

commit eb4c3f4aaae2ee1b27c210e951260a7e699133b4
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Oct 14 09:07:00 2017 -0600

    Constify add_setshow_*
    
    This constifies the add_setshow_* family of functions, and then fixes
    up the fallout.  The bulk of this patch was written by script.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* ada-lang.c (catch_ada_exception_command): Constify.
    	(catch_assert_command): Constify.
    	* break-catch-throw.c (catch_catch_command, catch_throw_command)
    	(catch_rethrow_command): Constify.
    	(catch_exception_command_1): Constify.
    	* breakpoint.h (add_catch_command): Constify.
    	* break-catch-syscall.c (catch_syscall_command_1): Constify.
    	(catch_syscall_split_args): Constify.
    	* break-catch-sig.c (catch_signal_command): Constify.
    	(catch_signal_split_args): Constify.
    	* cli/cli-decode.h (struct cmd_list_element) <function>: Use
    	cmd_const_sfunc_ftype.
    	* cli/cli-decode.c (add_setshow_cmd_full): Constify.
    	(add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
    	(add_setshow_boolean_cmd, add_setshow_filename_cmd)
    	(add_setshow_string_cmd, struct cmd_list_element)
    	(add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
    	(add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
    	(add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
    	Constify.
    	(set_cmd_sfunc): Constify.
    	(empty_sfunc): Constify.
    	* command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
    	(add_setshow_boolean_cmd, add_setshow_filename_cmd)
    	(add_setshow_string_cmd, add_setshow_string_noescape_cmd)
    	(add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
    	(add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
    	(add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
    	Constify.
    	(set_cmd_sfunc): Constify.
    	(cmd_sfunc_ftype): Remove.
    	* compile/compile.c (set_compile_args): Constify.
    	* infrun.c (set_disable_randomization): Constify.
    	* infcmd.c (set_args_command, set_cwd_command): Constify.
    	* breakpoint.c (set_condition_evaluation_mode): Constify.
    	(add_catch_command): Constify.
    	(catch_fork_command_1, catch_exec_command_1)
    	(catch_load_command_1, catch_unload_command_1): Constify.
    	(catch_load_or_unload): Constify.
    	* guile/scm-param.c (pascm_set_func): Constify.
    	(add_setshow_generic): Constify.
    	* python/py-param.c (get_set_value): Constify.
    	* top.h (set_verbose): Constify.
    	* tui/tui-win.c (tui_set_var_cmd): Constify.
    	* mi/mi-main.c (set_mi_async_command): Constify.
    	* cli/cli-logging.c (set_logging_overwrite)
    	(set_logging_redirect): Constify.
    	* value.c (set_max_value_size): Constify.
    	* valprint.c (set_input_radix, set_output_radix): Constify.
    	* utils.c (set_width_command, set_height_command): Constify.
    	* typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
    	* tracepoint.c (set_disconnected_tracing)
    	(set_circular_trace_buffer, set_trace_buffer_size)
    	(set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
    	* top.c (set_history_size_command, set_verbose, set_editing)
    	(set_gdb_datadir, set_history_filename): Constify.
    	* target.c (set_targetdebug, maint_set_target_async_command)
    	(maint_set_target_non_stop_command, set_target_permissions)
    	(set_write_memory_permission): Constify.
    	(open_target): Constify.
    	* target-descriptions.c (set_tdesc_filename_cmd): Constify.
    	* target-dcache.c (set_stack_cache, set_code_cache): Constify.
    	* symtab.c (set_symbol_cache_size_handler): Constify.
    	* symfile.c (set_ext_lang_command): Constify.
    	* symfile-debug.c (set_debug_symfile): Constify.
    	* source.c (set_directories_command): Constify.
    	* solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
    	* serial.c (set_parity): Constify.
    	* rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
    	* remote.c (set_remote_exec_file, set_remotebreak)
    	(set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
    	* record.c (set_record_insn_history_size)
    	(set_record_call_history_size): Constify.
    	* record-full.c (set_record_full_insn_max_num): Constify.
    	* proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
    	* osabi.c (set_osabi): Constify.
    	* mips-tdep.c (set_mips64_transfers_32bit_regs)
    	(reinit_frame_cache_sfunc, mips_abi_update): Constify.
    	* maint.c (maintenance_set_profile_cmd): Constify.
    	* linux-thread-db.c (set_libthread_db_search_path): Constify.
    	* language.c (set_language_command, set_range_command)
    	(set_case_command): Constify.
    	* infrun.c (set_non_stop, set_observer_mode)
    	(set_stop_on_solib_events, set_schedlock_func)
    	(set_exec_direction_func): Constify.
    	* infcmd.c (set_inferior_tty_command): Constify.
    	* disasm.c (set_disassembler_options_sfunc): Constify.
    	* demangle.c (set_demangling_command): Constify.
    	* dcache.c (set_dcache_size, set_dcache_line_size): Constify.
    	* cris-tdep.c (set_cris_version, set_cris_mode)
    	(set_cris_dwarf2_cfi): Constify.
    	* corefile.c (set_gnutarget_command): Constify.
    	* charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
    	(set_target_wide_charset_sfunc): Constify.
    	* breakpoint.c (update_dprintf_commands): Constify.
    	* auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
    	* arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
    	(set_disassembly_style_sfunc): Constify.
    	* arch-utils.c (set_endian, set_architecture): Constify.
    	* alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
    	* agent.c (set_can_use_agent): Constify.

commit 5fed81ff351121887a93b5b57caebb86667cbbd2
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 13 22:58:21 2017 -0600

    Remove cmd_cfunc_ftype
    
    This removes cmd_cfunc_ftype and the non-const overload of add_cmd;
    then fixes up the fallout.
    
    For the most part this patch is straightforward.  There are a few
    files (go32-nat.c, windows-nat.c, and gnu-nat.c) that I could not
    compile; so I made a best effort there.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
    	(go32_pde, go32_pte, go32_pte_for_address): Constify.
    	* gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
    	(set_thread_default_pause_cmd, set_thread_default_run_cmd)
    	(show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
    	(parse_int_arg, show_thread_default_detach_sc_cmd)
    	(set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
    	(show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
    	(set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
    	(show_task_pause_cmd, set_task_detach_sc_cmd)
    	(show_task_detach_sc_cmd, set_task_exc_port_cmd)
    	(set_noninvasive_cmd, set_thread_pause_cmd)
    	(show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
    	(set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
    	(set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
    	* windows-nat.c (display_selectors): Constify.
    	* cli/cli-decode.h (struct cmd_list_element) <function>: Remove
    	non-const "cfunc".
    	* cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
    	(cmd_cfunc_eq): Likewise.
    	(struct cmd_list_element): Likewise.
    	(do_cfunc): Remove.
    	(cli_user_command_p): Update.
    	* command.h (add_cmd): Remove non-const overload.
    	(cmd_cfunc_ftype): Remove typedef.
    	(cmd_cfunc_eq): Remove non-const overload.
    	* value.c (show_values): Constify.
    	* thread.c (thread_apply_all_command): Constify.
    	* symfile.c (load_command): Constify.
    	* source.c (directory_command): Constify.
    	* maint.c (maintenance_internal_error)
    	(maintenance_demangler_warning, maintenance_space_display)
    	(maintenance_print_architecture, maintenance_translate_address)
    	(maintenance_info_selftests, maintenance_internal_warning):
    	Constify.
    	* breakpoint.c (disable_trace_command, enable_trace_command):
    	Constify.
    	* auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
    	Constify.
    	(add_auto_load_safe_path): Constify.
    	* guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
    	* top.h (show_commands): Constify.
    	* linux-thread-db.c (info_auto_load_libthread_db): Constify.
    	* sparc64-tdep.c (adi_examine_command): Constify.
    	(adi_assign_command): Constify.

commit 1d12d88f186fe1ae66deccf877b5509c506c4d39
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 13 22:07:26 2017 -0600

    Constify add_info
    
    This patch constifies add_info and updates all the info commands.  The
    bulk of this patch was written using a script; and then I did a manual
    pass to fix up the remaining compilation errors.
    
    I could not compile every changed file; in particular nto-procfs.c,
    gnu-nat.c, and darwin-nat-info.c; but I at least tried to check the
    correctness by inspection.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* frame.h (info_locals_command, info_args_command): Constify.
    	* auto-load.h (auto_load_info_scripts): Constify.
    	* inferior.h (registers_info): Constify.
    	* copying.c: Rebuild.
    	* copying.awk: Constify generated commands.
    	* auto-load.c (auto_load_info_scripts)
    	(info_auto_load_gdb_scripts): Constify.
    	* cli/cli-decode.c (struct cmd_list_element): Take a
    	cmd_const_cfunc_ftype.
    	* command.h (add_info): Take a cmd_const_cfunc_ftype.
    	* tui/tui-win.c (tui_all_windows_info): Constify.
    	* python/py-auto-load.c (info_auto_load_python_scripts):
    	Constify.
    	* cli/cli-cmds.c (show_command): Remove non-const overload.
    	* tracepoint.c (info_tvariables_command, info_scope_command):
    	Constify.
    	(info_static_tracepoint_markers_command): Constify.
    	* thread.c (info_threads_command): Constify.
    	(print_thread_info_1): Constify.
    	* target.c (info_target_command): Constify.
    	* symtab.c (info_sources_command, info_functions_command)
    	(info_types_command): Constify.
    	(info_variables_command): Remove non-const overload.
    	* symfile.c (info_ext_lang_command): Constify.
    	* stack.c (info_frame_command, info_locals_command)
    	(info_args_command): Constify.
    	(backtrace_command): Remove non-const overload.
    	* source.c (info_source_command, info_line_command): Constify.
    	* solib.c (info_sharedlibrary_command): Constify.
    	* skip.c (info_skip_command): Constify.
    	* ser-go32.c (info_serial_command): Constify.
    	* reverse.c (info_bookmarks_command): Constify.
    	* printcmd.c (info_symbol_command, info_address_command)
    	(info_display_command): Constify.
    	* osdata.c (info_osdata_command): Constify.
    	* objc-lang.c (info_selectors_command, info_classes_command):
    	Constify.
    	* nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
    	* memattr.c (info_mem_command): Constify.
    	* macrocmd.c (info_macro_command, info_macros_command): Constify.
    	* linux-fork.c (info_checkpoints_command): Constify.
    	* infrun.c (info_signals_command): Constify.
    	* inflow.c (info_terminal_command): Constify.
    	* inferior.c (info_inferiors_command): Constify.
    	(print_inferior): Constify.
    	* infcmd.c (info_program_command, info_all_registers_command)
    	(info_registers_command, info_vector_command)
    	(info_float_command): Constify.
    	(registers_info): Constify.
    	* gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
    	(info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
    	Constify.
    	* f-valprint.c (info_common_command): Constify.
    	* dcache.c (info_dcache_command): Constify.
    	(dcache_info_1): Constify.
    	* darwin-nat-info.c (info_mach_tasks_command)
    	(info_mach_task_command, info_mach_ports_command)
    	(info_mach_port_command, info_mach_threads_command)
    	(info_mach_thread_command, info_mach_regions_command)
    	(info_mach_regions_recurse_command, info_mach_region_command)
    	(info_mach_exceptions_command): Constify.
    	(get_task_from_args): Constify.
    	* cp-support.c (info_vtbl_command): Constify.
    	* breakpoint.c (info_watchpoints_command)
    	(info_tracepoints_command): Constify.
    	(info_breakpoints_command): Remove non-const overload.
    	* avr-tdep.c (avr_io_reg_read_command): Constify.
    	* auxv.c (info_auxv_command): Constify.
    	* ada-tasks.c (info_tasks_command): Constify.
    	(info_task): Constify.
    	* ada-lang.c (info_exceptions_command): Constify.

commit 0b39b52e6e92cf6d465d48499c657fcb17a63c7f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 11 15:43:01 2017 -0600

    Constify add_com
    
    This changes add_com to take a cmd_const_cfunc_ftype, and then fixes
    up all the command implementations.
    
    In most cases this is trivial.
    
    In a couple of places I had to again introduce a temporary non-const
    overload.  These overloads will be removed when add_info is
    constified.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* solib.h (no_shared_libraries): Constify.
    	* frame.h (return_command): Constify.
    	* cli/cli-cmds.h (quit_command): Constify.
    	* top.h (quit_command, execute_command): Constify.
    	* target.h (flash_erase_command): Constify.
    	* inferior.h (set_inferior_args, attach_command): Constify.
    	* tracepoint.h (start_tracing, stop_tracing): Constify.
    	* breakpoint.h (break_command, tbreak_command)
    	(hbreak_command_wrapper, thbreak_command_wrapper)
    	(rbreak_command_wrapper, watch_command_wrapper)
    	(awatch_command_wrapper, rwatch_command_wrapper)
    	(get_tracepoint_by_number): Constify.
    	* symtab.c (info_variables_command, rbreak_command)
    	(symtab_symbol_info): Constify.
    	(info_variables_command): Add non-const overload.
    	* top.c (dont_repeat_command): Constify.
    	* breakpoint.c (ignore_command, commands_command)
    	(condition_command, tbreak_command, hbreak_command)
    	(thbreak_command, clear_command, break_command)
    	(info_breakpoints_command, watch_command, rwatch_command)
    	(awatch_command, trace_command, ftrace_command, strace_command)
    	(trace_pass_command, break_range_command, dprintf_command)
    	(agent_printf_command, get_tracepoint_by_number)
    	(watch_maybe_just_location, trace_pass_command): Constify.
    	(info_breakpoints_command): Add non-const overload.
    	* tracefile.c (tsave_command): Constify.
    	* infcmd.c (attach_command, disconnect_command, signal_command)
    	(queue_signal_command, stepi_command, nexti_command)
    	(finish_command, next_command, step_command, until_command)
    	(advance_command, jump_command, continue_command, run_command)
    	(start_command, starti_command, interrupt_command)
    	(run_command_1, set_inferior_args, step_1): Constify.
    	* inferior.c (add_inferior_command, remove_inferior_command)
    	(clone_inferior_command): Constify.
    	* linux-fork.c (checkpoint_command, restart_command): Constify.
    	* windows-nat.c (signal_event_command): Constify.
    	* guile/guile.c (guile_repl_command, guile_command): Constify.
    	* printcmd.c (x_command, display_command, printf_command)
    	(output_command, set_command, call_command, print_command)
    	(eval_command): Constify.
    	(non_const_set_command): Remove.
    	(_initialize_printcmd): Update.
    	* source.c (forward_search_command, reverse_search_command):
    	Constify.
    	* jit.c (jit_reader_load_command, jit_reader_unload_command):
    	Constify.
    	* infrun.c (handle_command): Constify.
    	* memattr.c (mem_command): Constify.
    	* stack.c (return_command, up_command, up_silently_command)
    	(down_command, down_silently_command, frame_command)
    	(backtrace_command, func_command, backtrace_command_1): Constify.
    	(backtrace_command): Add non-const overload.
    	* remote-sim.c (simulator_command): Constify.
    	* exec.c (set_section_command): Constify.
    	* tracepoint.c (tdump_command, trace_variable_command)
    	(tstatus_command, tstop_command, tstart_command)
    	(end_actions_pseudocommand, while_stepping_pseudocommand)
    	(collect_pseudocommand, teval_pseudocommand, actions_command)
    	(start_tracing, stop_tracing): Constify.
    	* value.c (init_if_undefined_command): Constify.
    	* tui/tui-stack.c (tui_update_command): Constify.
    	* tui/tui-win.c (tui_refresh_all_command)
    	(tui_set_tab_width_command, tui_set_win_height_command)
    	(tui_set_focus_command, tui_scroll_forward_command)
    	(tui_scroll_backward_command, tui_scroll_left_command)
    	(tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
    	(tui_set_win_height): Constify.
    	* tui/tui-layout.c (tui_layout_command): Constify.
    	* procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
    	(proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
    	(proc_untrace_sysexit_cmd): Constify.
    	* remote.c (threadlist_test_cmd, threadinfo_test_cmd)
    	(threadset_test_cmd, threadlist_update_test_cmd)
    	(threadalive_test): Constify.
    	* objc-lang.c (print_object_command): Constify.
    	* command.h (add_com): Constify.
    	* cli/cli-dump.c (restore_command): Constify.
    	* cli/cli-cmds.c (pwd_command, echo_command, quit_command)
    	(help_command, complete_command, shell_command, edit_command)
    	(list_command, disassemble_command, make_command)
    	(apropos_command, alias_command): Constify.
    	* cli/cli-script.c (document_command, define_command)
    	(while_command, if_command, validate_comname): Constify.
    	* cli/cli-decode.c (struct cmd_list_element): Change type of
    	"fun".
    	* target.c (do_monitor_command, flash_erase_command): Constify.
    	* regcache.c (reg_flush_command): Constify.
    	* reverse.c (reverse_step, reverse_next, reverse_stepi)
    	(reverse_nexti, reverse_continue, reverse_finish)
    	(save_bookmark_command, goto_bookmark_command)
    	(exec_reverse_once): Constify.
    	* python/python.c (python_interactive_command, python_command):
    	Constify.
    	* typeprint.c (ptype_command, whatis_command, whatis_exp):
    	Constify.
    	* solib.c (sharedlibrary_command, no_shared_libraries): Constify.
    	* gcore.c (gcore_command): Constify.

commit 85c4be7c83b80acf647e6ffcaed0f0cdbcb8c3eb
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 08:27:21 2017 -0600

    Add set_repeat_arguments function
    
    The "x", "list", and "show commands" commands have special repetition
    behavior: repeating the command doesn't re-run it with the same
    arguments
    
    This is currently implemented by modifying the passed-in argument; but
    that won't work properly with const arguments (and seems pretty
    obscure besides).
    
    This patch adds a new "set_repeat_arguments" function and changes the
    relevant places to call it.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* printcmd.c (x_command): Call set_repeat_arguments.
    	* cli/cli-cmds.c (list_command): Call set_repeat_arguments.
    	* top.c (repeat_arguments): New global.
    	(set_repeat_arguments): New function.
    	(execute_command): Handle repeat_arguments.
    	(show_commands): Calls set_repeat_arguments.
    	* command.h (set_repeat_arguments): Declare.

commit 022643b4456ee13752b0f3a8411238ab8c53bf6d
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 08:08:00 2017 -0600

    Remove cleanup from backtrace_command
    
    This removes a cleanup from backtrace_command, replacing it with
    std::string.  This patch temporarily changes backtrace_command so that
    the parameter is named "args_in" and is immediately constified; this
    is fixed again in the constification patch.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* stack.c (backtrace_command): Use std::string.
    	(backtrace_command_1): Make "count_exp" const.

commit 5614fb77203f5ea01edfb2d739e9d4f3d570dc09
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 11 17:04:29 2017 -0600

    Constify add_path and friends
    
    This constifies add_path, mod_path, and directory_switch.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* source.c (directory_switch, mod_path, add_path): Constify.
    	* defs.h (add_path, mod_path, directory_switch): Constify.
    	* mi/mi-cmd-env.c (env_mod_path): Constify.

commit 6be9a197d96c3c346271b46ec6270bd719eb9932
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 10 21:54:01 2017 -0600

    Make strip_bg_char return a unique_xmalloc_ptr
    
    This changes strip_bg_char to return a unique_xmalloc_ptr and removes
    several cleanups.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
    	(run_command_1, continue_command, step_1, jump_command)
    	(signal_command, until_command, advance_command, finish_command)
    	(attach_command): Update.

commit c2252c0dd8dcf3bb95598149aecd3158e89c31d7
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 10 18:14:10 2017 -0600

    Make set_cmd_cfunc private
    
    set_cmd_cfunc is only used in cli-decode.c, and I don't think there is
    a good reason to expose it directly.  So, this patch makes it private.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* command.h (set_cmd_cfunc): Don't declare.
    	* cli/cli-decode.c (set_cmd_cfunc): Now static.

commit 1ee870c5249864d36717a08864c60d7166b6b292
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 10 18:12:06 2017 -0600

    Constify add_com_suppress_notification
    
    This constifies add_com_suppress_notification and fixes the one
    caller.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* stack.c (select_frame_command): Constify.
    	* cli/cli-decode.c (add_com_suppress_notification): Constify.
    	* command.h (add_com_suppress_notification): Constify.

commit ee7ddd713206fdf02512a9fb3fe928a210200c11
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 10 17:51:52 2017 -0600

    Constify add_abbrev_prefix_cmd
    
    This changes add_abbrev_prefix_cmd to take a const-taking callback
    function and then fixes the one caller.
    
    gdb/ChangeLog
    2017-11-07  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (stop_command): Constify.
    	* cli/cli-decode.c (struct cmd_list_element): Constify.
    	* command.h (add_abbrev_prefix_cmd): Constify.

commit 52eab766df54915f8d3d71475235868285c4ca82
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Tue Nov 7 20:24:21 2017 +0000

    opcodes/arc: Fix incorrect insn_class for some nps insns
    
    A small number of NPS400 instruction incorrectly used NONE as an
    insn_class_t, which would trigger a build warning.  Fixed by changing to
    MISC.
    
    opcodes/ChangeLog:
    
    	* arc-nps400-tbl.h: Change incorrect use of NONE to MISC.

commit 016f5a3777ab6ce33616917be7795a7501f29dd7
Author: Jim Wilson <jimw@sifive.com>
Date:   Tue Nov 7 09:43:18 2017 -0800

    Fix typo in my email address.
    
    	binutils/
    	* MAINTAINERS (RISC-V): Fix typo in my email address.

commit 180093c76385b4037128109f452ce4a2414af124
Author: Palmer Dabbelt <palmer@sifive.com>
Date:   Mon Nov 6 17:53:12 2017 -0800

    RISC-V: Add Jim Wilson as a maintainer, and clean up our entries
    
    Jim has recently started working at SiFive, where he'll be contributing
    to our binutils port.  Andrew and I would like him to be a maintainer.
    My understanding is that this is right place to ask.
    
    I've also changed my address to my SiFive one, where I also work -- it
    seems cleaner to have everyone use our proper email address.  While I
    was in there, I noticed a trailing space after Andrew's name so I went
    ahead and removed it as well.
    
    binutils/ChangeLog
    
    2017-11-07  Palmer Dabbelt  <palmer@sifive.com>
    
            * MAINTAINERS (RISC-V): Add Jim Wilson as a maintainer.
            Clean up Andrew's entry (remove trailing space, add tabs).
            Change Palmer's email address, and clean up entry (add tabs).

commit f77bb6c56b4091ed863d8cd03333a79a8d554ce1
Author: Jim Wilson <jimw@sifive.com>
Date:   Mon Nov 6 16:32:08 2017 -0800

    RISC-V: Fix riscv g++ testsuite EH failures.
    
    This fixes some EH failures for the medany code model in the g++ testsuite.
    The problem is that the assembler is computing some values in the eh_frame
    section as constants, that instead should have had relocs to be resolved by
    the linker.  This happens in output_cfi_insn in the DW_CFA_advance_loc case
    where it compares label frags and immediately simplifies if they are the
    same.  We can fix that by forcing a new frag after every instruction
    that the linker can reduce in size.  I've also added a testcase to verify
    the fix.  This was tested with binutils make check, and gcc/g++ make checks on
    qemu for medlow and medany code models.
    
    	gas/
    	* config/tc-riscv.c (append_insn): Call frag_wane and frag_new at
    	end for linker optimizable relocs.
    	* testsuite/gas/riscv/eh-relocs.d: New.
    	* testsuite/gas/riscv/eh-relocs.s: New.
    	* testsuite/gas/riscv/riscv.exp: Run eh-relocs test.

commit 1270b047fdc68d89f05668ed919d17f5fceeba2a
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Mon Nov 6 13:22:42 2017 -0800

    RISC-V: Add satp as an alias for sptbr
    
    The RISC-V privileged ISA changed the name of sptbr (Supervisor Page
    Table Base Register) to satp (Supervisor Address Translation and
    Protection) to reflect the fact it could be used for more than just
    paging.  This patch adds an alias, as they're the same register.
    
    include/ChangeLog
    
    2017-11-06  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * opcode/riscv-opc.h (sptbr): Rename to satp.
            (CSR_SPTBR): Rename to CSR_SATP.
            (sptbr): Alias to CSR_SATP.
    
    gas/ChangeLog
    
    2017-11-06  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * testsuite/gas/riscv/satp.d: New test.
            testsuite/gas/riscv/satp.s: Likewise.
            testsuite/gas/riscv/riscv.exp: Likewise.
            config/tc-riscv.c (md_begin): Handle CSR aliases.

commit a02b41a7e604471e584dc2151fbd36714842710e
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 7 11:16:09 2017 +0000

    Add some more breakpoint/location range tests
    
    Some extra thoroughness tests that I had over here.
    
    gdb/testsuite/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* gdb.cp/ena-dis-br-range.exp: Add more tests.

commit 95e95a6de2e4a050870c49bf52fbac0239847b63
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 7 11:00:32 2017 +0000

    Make breakpoint/location number parsing error output consistent
    
    ... and also make GDB catch a few more cases of invalid input.
    
    This fixes the inconsistency in GDB's output (e.g., "bad" vs "Bad")
    exposed by the new tests added in the previous commit.
    
    Also, makes the "0-0" and "inverted range" cases be loud errors.
    
    Also makes GDB reject negative breakpoint number in ranges.  We
    already rejected negative number literals, but you could still subvert
    that via convenience variables, like:
    
      (gdb) set $bp -1
      (gdb) disable $bp.1-2
    
    The change to get_number_trailer fixes a bug exposed by the new tests.
    The function did not handle parsing "-$num".  [This wasn't visible in
    the gdb.multi/tids.exp (which has similar tests) because the TID range
    parsing is implemented differently.]
    
    gdb/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* breakpoint.c (extract_bp_kind): New enum.
    	(extract_bp_num, extract_bp_or_bp_range): New functions, partially
    	factored out from ...
    	(extract_bp_number_and_location): ... here.
    	* cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
    
    gdb/testsuite/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/ena-dis-br.exp (test_ena_dis_br): Adjust test.
    	* gdb.cp/ena-dis-br-range.exp: Adjust tests.
    	(disable_invalid, disable_inverted, disable_negative): New
    	procedures.
    	("bad numbers"): New set of tests.

commit cee62dbd8771e22856d950c2615fb463305a9fcb
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 7 11:00:31 2017 +0000

    Add base 'enable/disable invalid location range' tests
    
    This adds tests that exercise the "bad breakpoint number" paths.
    Specifically:
    
     - malformed ranges
     - use of explicit 0 as bp/loc number.
     - inverted ranges
    
    I'm adding this as a baseline to improve.  This shows that there's a
    lot of inconsistency in GDB's output (e.g., "bad" vs "Bad").
    
    Also, IMO, the "0-0" and inverted range cases should be loud errors.
    
    That and more will all be addressed in the next patch.
    
    gdb/testsuite/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* gdb.cp/ena-dis-br-range.exp: Add tests.

commit cc638e867c240546b4dbc791761099d3ca5fe4a9
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Nov 7 11:00:31 2017 +0000

    Breakpoint location parsing: always error instead of warning
    
    It's odd that when parsing a breakpoint or location number, we error out
    in most cases, but warn in others.
    
      (gdb) disable 1-
      bad breakpoint number at or near: '1-'
      (gdb) disable -1
      bad breakpoint number at or near: '-1'
      (gdb) disable .foo
      bad breakpoint number at or near: '.foo'
      (gdb) disable foo.1
      Bad breakpoint number 'foo.1'
      (gdb) disable 1.foo
      warning: bad breakpoint number at or near '1.foo'
    
    This changes GDB to always error out.  It required touching one testcase
    that expected the warning.
    
    gdb/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* breakpoint.c (extract_bp_number_and_location): Change return
    	type to void.  Throw error instead of warning.
    	(enable_disable_command): Adjust.
    
    gdb/testsuite/ChangeLog:
    2017-11-07  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/ena-dis-br.exp: Don't expect "warning:".

commit d0fe47010fc3289e081ba547a0bfcc6d07906cd2
Author: Xavier Roirand <roirand@adacore.com>
Date:   Tue Nov 7 11:00:31 2017 +0000

    Allow enabling/disabling breakpoint location ranges
    
    When a breakpoint has multiple locations, like e.g.:
    
     Num  Type       Disp Enb  Address    What
     1    breakpoint keep y    <MULTIPLE>
     1.1                  y    0x080486a2 in void foo<int>()...
     1.2                  y    0x080486ca in void foo<double>()...
     [....]
     1.5                  y    0x080487fa in void foo<long>()...
    
    it's possible to enable/disable the individual locations using the
    '<breakpoint_number>.<location_number>' syntax, like e.g.:
    
     (gdb) disable 1.2 1.3 1.4 1.5
    
    That's inconvenient when you have a long list of locations to disable,
    however.
    
    This patch adds shorthand for the above, by making it possible to
    specify a range of locations with the following syntax (similar to
    thread id ranges):
    
     <breakpoint_number>.<first_location_number>-<last_location_number>
    
    For example, the command above can now be simplified to:
    
     (gdb) disable 1.2-5
    
    gdb/ChangeLog:
    2017-11-07  Xavier Roirand  <roirand@adacore.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* breakpoint.c (map_breakpoint_number_range): New, factored out
    	from ...
    	(map_breakpoint_numbers): ... here.
    	(find_location_by_number): Change parameters from string to
    	breakpoint number and location.
    	(extract_bp_number_and_location): New function.
    	(enable_disable_bp_num_loc)
    	(enable_disable_breakpoint_location_range)
    	(enable_disable_command): New functions, factored out ...
    	(enable_command, disable_command): ... these functions, and
    	adjusted to support ranges.
    	* NEWS: Document enable/disable breakpoint location range feature.
    
    gdb/doc/ChangeLog:
    2017-11-07  Xavier Roirand  <roirand@adacore.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.texinfo (Set Breaks): Document support for breakpoint
    	location ranges in the enable/disable commands.
    
    gdb/testsuite/ChangeLog:
    2017-11-07  Xavier Roirand  <roirand@adacore.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/ena-dis-br.exp: Add reference to
    	gdb.cp/ena-dis-br-range.exp.
    	* gdb.cp/ena-dis-br-range.exp: New file.
    	* gdb.cp/ena-dis-br-range.cc: New file.

commit 0198d5e6fc331d50dc19b7f250ac4bc510a8dbb5
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Tue Nov 7 10:17:21 2017 +0000

    This patch similarly to the AArch64 one enables Dot Product support by default for the Cortex-A55 and Cortex-A75 which have hardware support for these instructions.
    
    gas	* config/tc-arm.c (arm_cpus):
    	Change FPU_ARCH_CRYPTO_NEON_VFP_ARMV8
    	into FPU_ARCH_CRYPTO_NEON_VFP_ARMV8_DOTPROD.
    
    include	* opcode/arm.h (FPU_ARCH_CRYPTO_NEON_VFP_ARMV8_DOTPROD):
    	New macro.

commit db84fff3f888bb3e6d51ad24b6bfa2c6e2c3a206
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 6 15:21:53 2017 +1030

    PowerPC64 statistics message
    
    Fixes "linker stubs in 1 groups".
    
    	* elf64-ppc.c (ppc64_elf_build_stubs): Correct pluralization in
    	statistics message.

commit e54e9ac577591f53bd9552210b1062c6230030be
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 7 16:32:07 2017 +1030

    bundle_lock message tidy
    
    I'd edited these thinking that there might be cases where the counts
    were one, but on further investigation it appears not.  What's left
    here are some minor tweaks.
    
    	* read.c (assemble_one, s_bundle_unlock): Formatting.
    	Consistently add comma and "bytes" to error message.
    	* testsuite/gas/i386/bundle-bad.l: Adjust to suit.

commit d3a49aa80b8a6eab1c684deddad3542c4cdaa497
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Nov 7 11:18:29 2017 +1030

    readelf ngettext fixes
    
    This patch is a first pass at fixing readelf message pluralization.
    I've deliberately not fixed the "out of memory" errors since it's very
    unlikely that they will ever be complaining about not being able to
    allocate for a single entry, and a few others where the size is very
    unlikely to be 1 byte.
    
    Then there are messages like this one:
    "Out of %lu items there are %zu bucket clashes (longest of %zu entries).\n"
    I suppose this could be split into three parts, "Of %lu items ",
    "there are %zu bucket clashes ", and "(longest of %zu entries).\n",
    each part being printed separately, but that might not be ideal for
    sentence construction in other languages.  For now I'm punting on this
    one.
    
    Changes to readelf output require lots of testsuite adjustment..
    
    binutils/
    	* dwarf.c (read_uleb128): Properly pluralize messages.
    	(display_debug_lines_raw, display_debug_loc): Likewise.
    	(display_debug_names, process_cu_tu_index): Likewise.
    	* od-macho.c (dump_code_signature_superblob): Likewise.
    	* readelf.c (process_program_headers): Likewise.
    	(process_section_header, process_relocs): Likewise.
    	(hppa_process_unwind, arm_process_unwind): Likewise.
    	(process_dynamic_section, process_version_sections): Likewise.
    	(process_symbol_table, process_syminfo): Likewise.
    	(apply_relocations, process_mips_specific): Likewise.
    	(process_gnu_liblist, process_notes_at): Likewise.
    	(process_archive): Likewise.
    	* testsuite/binutils-all/dw2-1.W,
    	* testsuite/binutils-all/dw2-3.W,
    	* testsuite/binutils-all/dw2-3gabi.W,
    	* testsuite/binutils-all/dw5.S,
    	* testsuite/binutils-all/dw5.W,
    	* testsuite/binutils-all/i386/compressed-1a.d,
    	* testsuite/binutils-all/libdw2-compressedgabi.out,
    	* testsuite/binutils-all/objdump.W,
    	* testsuite/binutils-all/readelf.r,
    	* testsuite/binutils-all/readelf.r-64,
    	* testsuite/binutils-all/x86-64/compressed-1a.d: Update
    	for pluralization fixes.
    gas/
    	* testsuite/gas/arm/got_prel.d,
    	* testsuite/gas/elf/dwarf2-1.d,
    	* testsuite/gas/elf/dwarf2-2.d,
    	* testsuite/gas/elf/dwarf2-3.d,
    	* testsuite/gas/elf/dwarf2-5.d,
    	* testsuite/gas/elf/dwarf2-6.d,
    	* testsuite/gas/i386/debug1.d,
    	* testsuite/gas/i386/dw2-compress-1.d,
    	* testsuite/gas/i386/dw2-compress-3a.d,
    	* testsuite/gas/i386/dw2-compress-3b.d,
    	* testsuite/gas/i386/dw2-compressed-1.d,
    	* testsuite/gas/i386/dw2-compressed-3a.d,
    	* testsuite/gas/i386/dw2-compressed-3b.d,
    	* testsuite/gas/i386/ilp32/x86-64-localpic.d,
    	* testsuite/gas/i386/localpic.d,
    	* testsuite/gas/i386/x86-64-localpic.d,
    	* testsuite/gas/ia64/pr13167.d,
    	* testsuite/gas/mips/loc-swap-2.d,
    	* testsuite/gas/mips/loc-swap.d,
    	* testsuite/gas/mips/micromips@loc-swap-2.d,
    	* testsuite/gas/mips/micromips@loc-swap.d,
    	* testsuite/gas/mips/mips16-dwarf2-n32.d,
    	* testsuite/gas/mips/mips16-dwarf2.d,
    	* testsuite/gas/mips/mips16@loc-swap-2.d,
    	* testsuite/gas/mips/mips16@loc-swap.d,
    	* testsuite/gas/mips/mips16e@loc-swap.d,
    	* testsuite/gas/mmix/bspec-1.d,
    	* testsuite/gas/mmix/bspec-2.d,
    	* testsuite/gas/tic6x/unwind-1.d,
    	* testsuite/gas/tic6x/unwind-2.d,
    	* testsuite/gas/tic6x/unwind-3.d: Update for pluralization
    	fixes.
    ld/
    	* testsuite/ld-aarch64/ifunc-13.d,
    	* testsuite/ld-aarch64/ifunc-15.d,
    	* testsuite/ld-aarch64/ifunc-20.d,
    	* testsuite/ld-alpha/tlsbin.rd,
    	* testsuite/ld-alpha/tlspic.rd,
    	* testsuite/ld-arm/ifunc-3.rd,
    	* testsuite/ld-arm/ifunc-9.rd,
    	* testsuite/ld-arm/unwind-mix.d,
    	* testsuite/ld-arm/unwind-rel.d,
    	* testsuite/ld-cris/hiddef1.d,
    	* testsuite/ld-cris/libdso-13.d,
    	* testsuite/ld-cris/libdso-2.d,
    	* testsuite/ld-cris/pr16044.d,
    	* testsuite/ld-cris/tls-local-63.d,
    	* testsuite/ld-cris/tls-local-64.d,
    	* testsuite/ld-cris/tls-und-38.d,
    	* testsuite/ld-cris/tls-und-42.d,
    	* testsuite/ld-cris/tls-und-46.d,
    	* testsuite/ld-cris/tls-und-50.d,
    	* testsuite/ld-cris/weakref3.d,
    	* testsuite/ld-cris/weakref4.d,
    	* testsuite/ld-elf/comm-data2r.rd,
    	* testsuite/ld-elf/discard1.d,
    	* testsuite/ld-elf/discard2.d,
    	* testsuite/ld-elf/pr19539.d,
    	* testsuite/ld-elf/pr22374-1.r,
    	* testsuite/ld-elf/pr22374-2.r,
    	* testsuite/ld-i386/combreloc.d,
    	* testsuite/ld-i386/emit-relocs-nacl.rd,
    	* testsuite/ld-i386/emit-relocs.rd,
    	* testsuite/ld-i386/pr13302.d,
    	* testsuite/ld-i386/pr17709-nacl.rd,
    	* testsuite/ld-i386/pr17709.rd,
    	* testsuite/ld-i386/pr19539.d,
    	* testsuite/ld-i386/pr19615.d,
    	* testsuite/ld-i386/pr19636-1a.d,
    	* testsuite/ld-i386/pr19636-1e.d,
    	* testsuite/ld-i386/pr19636-1f.d,
    	* testsuite/ld-i386/pr19636-2a.d,
    	* testsuite/ld-i386/pr19636-2b.d,
    	* testsuite/ld-i386/pr19636-2d-nacl.d,
    	* testsuite/ld-i386/pr19636-2e-nacl.d,
    	* testsuite/ld-i386/pr19636-3a.d,
    	* testsuite/ld-i386/pr19636-3d.d,
    	* testsuite/ld-i386/pr19636-3e.d,
    	* testsuite/ld-i386/pr19636-4a.d,
    	* testsuite/ld-i386/pr19645.d,
    	* testsuite/ld-i386/pr19827-nacl.rd,
    	* testsuite/ld-i386/pr19827.rd,
    	* testsuite/ld-i386/pr20253-4a.d,
    	* testsuite/ld-i386/pr20253-4b.d,
    	* testsuite/ld-i386/pr20253-5.d,
    	* testsuite/ld-i386/tlsbin-nacl.rd,
    	* testsuite/ld-i386/tlsbin.rd,
    	* testsuite/ld-i386/tlspic-nacl.rd,
    	* testsuite/ld-i386/tlspic.rd,
    	* testsuite/ld-i386/undefweakb.d,
    	* testsuite/ld-ia64/tlsbin.rd,
    	* testsuite/ld-ia64/tlspic.rd,
    	* testsuite/ld-ifunc/ifunc-13-i386.d,
    	* testsuite/ld-ifunc/ifunc-13-x86-64.d,
    	* testsuite/ld-ifunc/ifunc-15-i386.d,
    	* testsuite/ld-ifunc/ifunc-15-x86-64.d,
    	* testsuite/ld-ifunc/ifunc-20-i386.d,
    	* testsuite/ld-ifunc/ifunc-20-x86-64.d,
    	* testsuite/ld-ifunc/ifunc-23a-x86.d,
    	* testsuite/ld-ifunc/ifunc-23b-x86.d,
    	* testsuite/ld-ifunc/ifunc-23c-x86.d,
    	* testsuite/ld-ifunc/ifunc-24a-x86.d,
    	* testsuite/ld-ifunc/ifunc-24b-x86.d,
    	* testsuite/ld-ifunc/ifunc-24c-x86.d,
    	* testsuite/ld-ifunc/ifunc-25a-x86.d,
    	* testsuite/ld-ifunc/ifunc-25b-x86.d,
    	* testsuite/ld-ifunc/ifunc-25c-x86.d,
    	* testsuite/ld-m68k/got-1.d,
    	* testsuite/ld-mips-elf/vxworks1.rd,
    	* testsuite/ld-powerpc/ambiguousv1.d,
    	* testsuite/ld-powerpc/ambiguousv1b.d,
    	* testsuite/ld-powerpc/ambiguousv2.d,
    	* testsuite/ld-powerpc/ambiguousv2b.d,
    	* testsuite/ld-powerpc/tlsexe.r,
    	* testsuite/ld-powerpc/tlsexe32.r,
    	* testsuite/ld-powerpc/tlsexetoc.r,
    	* testsuite/ld-powerpc/tlsso.r,
    	* testsuite/ld-powerpc/tlsso32.r,
    	* testsuite/ld-powerpc/tlstocso.r,
    	* testsuite/ld-powerpc/vle-multiseg-1.d,
    	* testsuite/ld-powerpc/vle-multiseg-2.d,
    	* testsuite/ld-powerpc/vle-multiseg-3.d,
    	* testsuite/ld-s390/tlsbin.rd,
    	* testsuite/ld-s390/tlsbin_64.rd,
    	* testsuite/ld-s390/tlspic.rd,
    	* testsuite/ld-s390/tlspic_64.rd,
    	* testsuite/ld-sh/ld-r-1.d,
    	* testsuite/ld-sh/sh64/gotplt.d,
    	* testsuite/ld-sh/shared-1.d,
    	* testsuite/ld-sh/tlsbin-2.d,
    	* testsuite/ld-sh/tlspic-2.d,
    	* testsuite/ld-sparc/gotop32.rd,
    	* testsuite/ld-sparc/gotop64.rd,
    	* testsuite/ld-sparc/tlssunpic32.rd,
    	* testsuite/ld-sparc/tlssunpic64.rd,
    	* testsuite/ld-sparc/vxworks1-lib.rd,
    	* testsuite/ld-tic6x/shlib-app-1.rd,
    	* testsuite/ld-tic6x/shlib-app-1b.rd,
    	* testsuite/ld-tic6x/shlib-app-1r.rd,
    	* testsuite/ld-tic6x/shlib-app-1rb.rd,
    	* testsuite/ld-tic6x/shlib-noindex.rd,
    	* testsuite/ld-vax-elf/export-class-data.rd,
    	* testsuite/ld-x86-64/pr13082-1a.d,
    	* testsuite/ld-x86-64/pr13082-1b.d,
    	* testsuite/ld-x86-64/pr13082-2a.d,
    	* testsuite/ld-x86-64/pr13082-2b.d,
    	* testsuite/ld-x86-64/pr13082-3a.d,
    	* testsuite/ld-x86-64/pr13082-3c.d,
    	* testsuite/ld-x86-64/pr13082-4a.d,
    	* testsuite/ld-x86-64/pr13082-5a.d,
    	* testsuite/ld-x86-64/pr13082-5b.d,
    	* testsuite/ld-x86-64/pr13082-6a.d,
    	* testsuite/ld-x86-64/pr13082-6b.d,
    	* testsuite/ld-x86-64/pr17709-nacl.rd,
    	* testsuite/ld-x86-64/pr17709.rd,
    	* testsuite/ld-x86-64/pr19539a.d,
    	* testsuite/ld-x86-64/pr19539b.d,
    	* testsuite/ld-x86-64/pr19615.d,
    	* testsuite/ld-x86-64/pr19636-1a.d,
    	* testsuite/ld-x86-64/pr19636-1d.d,
    	* testsuite/ld-x86-64/pr19636-1e.d,
    	* testsuite/ld-x86-64/pr19636-2a.d,
    	* testsuite/ld-x86-64/pr19636-2e.d,
    	* testsuite/ld-x86-64/pr19636-2f.d,
    	* testsuite/ld-x86-64/pr19636-3a.d,
    	* testsuite/ld-x86-64/pr19645.d,
    	* testsuite/ld-x86-64/pr19807-2b.d,
    	* testsuite/ld-x86-64/pr19807-2d.d,
    	* testsuite/ld-x86-64/pr19827-nacl.rd,
    	* testsuite/ld-x86-64/pr19827.rd,
    	* testsuite/ld-x86-64/pr20253-4a.d,
    	* testsuite/ld-x86-64/pr20253-4b.d,
    	* testsuite/ld-x86-64/pr20253-4d.d,
    	* testsuite/ld-x86-64/pr20253-4e.d,
    	* testsuite/ld-x86-64/pr20253-5a.d,
    	* testsuite/ld-x86-64/pr20253-5b.d,
    	* testsuite/ld-x86-64/tlsbin-nacl.rd,
    	* testsuite/ld-x86-64/tlsbin.rd,
    	* testsuite/ld-x86-64/tlspic-nacl.rd,
    	* testsuite/ld-x86-64/tlspic.rd,
    	* testsuite/ld-x86-64/tlspic2-nacl.rd: Update for
    	pluralization fixes.

commit 992a06eea4acfb674659a0ce19b5fb9c985e9bc1
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 6 19:44:02 2017 +1030

    gas and ld pluralization fixes
    
    gas/
    	* as.c (main): Properly pluralize messages.
    	* frags.c (frag_grow): Likewise.
    	* read.c (emit_expr_with_reloc, emit_expr_fix): Likewise.
    	(parse_bitfield_cons): Likewise.
    	* write.c (fixup_segment, compress_debug, write_contents): Likewise.
    	(relax_segment): Likewise.
    	* config/tc-arm.c (s_arm_elf_cons): Likewise.
    	* config/tc-cr16.c (l_cons): Likewise.
    	* config/tc-i370.c (i370_elf_cons): Likewise.
    	* config/tc-m68k.c (m68k_elf_cons): Likewise.
    	* config/tc-msp430.c (msp430_operands): Likewise.
    	* config/tc-s390.c (s390_elf_cons, s390_literals): Likewise.
    	* config/tc-mcore.c (md_apply_fix): Likewise.
    	* config/tc-tic54x.c (md_assemble): Likewise.
    	* config/tc-xtensa.c (xtensa_elf_cons): Likewise.
    	(xg_expand_assembly_insn): Likewise.
    	* config/xtensa-relax.c (build_transition): Likewise.
    ld/
    	* ldlang.c (lang_size_sections_1): Properly pluralize messages.
    	(lang_check_section_addresses): Likewise.

commit f3ce9b3a00229e5c6087180a74bf533d0e5201f3
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 6 21:30:12 2017 +1030

    Require ngettext in test of system gettext implementation
    
    If binutils is going to use ngettext, then we'd better arrange for
    intl/ to be compiled if the system gettext lacks ngettext.
    
    	* configure.ac: Invole AM_GNU_GETTEXT with need_ngettext.
    	* configure: Regenerate.
    	* aclocal.m4: Regenerate.

commit 6003e27e764ff62c1269a3ac6b5806b3fa3a1740
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Nov 6 15:20:00 2017 +1030

    ngettext support
    
    binutils has lacked proper pluralization of output messages for a long
    time, for example, readelf will display information about a section
    that "contains 1 entries" or "There are 1 section headers".  Fixing
    this properly requires us to use ngettext, because other languages
    have different rules to English.
    
    This patch defines macros for ngettext and friends to handle builds
    with --disable-nls, and tidies the existing nls support.  I've
    redefined gettext rather than just defining "_" as dgettext in bfd and
    opcodes in case someone wants to use gettext there (which might
    conceivably happen with generated code).
    
    bfd/
    	* sysdep.h: Formatting, comment fixes.
    	(gettext, ngettext): Redefine when ENABLE_NLS.
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    	(_): Define using gettext.
    	(textdomain, bindtextdomain): Use safer "do nothing".
    	* hosts/alphavms.h (textdomain, bindtextdomain): Likewise.
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    opcodes/
    	* opintl.h: Formatting, comment fixes.
    	(gettext, ngettext): Redefine when ENABLE_NLS.
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    	(_): Define using gettext.
    	(textdomain, bindtextdomain): Use safer "do nothing".
    binutils/
    	* sysdep.h (textdomain, bindtextdomain): Use safer "do nothing".
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    gas/
    	* asintl.h (textdomain, bindtextdomain): Use safer "do nothing".
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    gold/
    	* system.h (textdomain, bindtextdomain): Use safer "do nothing".
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.
    ld/
    	* ld.h (textdomain, bindtextdomain): Use safer "do nothing".
    	(ngettext, dngettext, dcngettext): Define when !ENABLE_NLS.

commit 84d5321fdfdc5c086734f441fb31fa9ace2e86aa
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Nov 7 00:00:21 2017 +0000

    Automatic date update in version.in

commit 635dc5b2e5cda5b18d32c4b0f6c19cba3ef05c67
Author: Luis Machado <luis.machado@linaro.org>
Date:   Mon Nov 6 15:39:09 2017 -0200

    Update my e-mail address.
    
    gdb/ChangeLog:
    2017-11-06  Luis Machado  <luis.machado@linaro.org>
    
    	* MAINTAINERS (Write After Approval): Update my e-mail address.

commit 556e5da51349d00307bc05b7a6a813f71ac58664
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 15:36:47 2017 +0000

    Simplify child_terminal_inferior
    
    The comment about Lynx in child_terminal_init reads a bit odd, since
    it's not exactly clear what "This" in "This is for Lynx" is referring
    to.  Looking back in history makes it clearer.  When the comment was
    originally added, in commit 91ecc8efa9b9, back in 1994, the code
    looked like this:
    
    ~~~
    #ifdef PROCESS_GROUP_TYPE
    #ifdef PIDGET
          /* This is for Lynx, and should be cleaned up by having Lynx be
             a separate debugging target with a version of
             target_terminal_init_inferior which passes in the process
             group to a generic routine which does all the work (and the
             non-threaded child_terminal_init_inferior can just pass in
             inferior_pid to the same routine).  */
          inferior_process_group = PIDGET (inferior_pid);
    #else
          inferior_process_group = inferior_pid;
    #endif
    #endif
    ~~~
    
    So this looked like it was about when GDB was growing support for
    multi-threading, and inferior_pid was still a single int for most
    ports.
    
    Eventually we got ptid_t, so the comment isn't really useful today.
    Particularly more so since we no longer support Lynx as a GDB host.
    
    The only caller left of child_terminal_init_with_pgrp is gnu-nat.c
    (the Hurd), and that target uses fork-child, so when we reach
    gnu_terminal_init after spawning a new child, the current inferior
    must already have the PID set, and the child must be a process group
    leader.
    
    We can't add a 'getpgid(inf->pid) == inf->pid' assertion to
    child_terminal_init though (like a previous version of this patch was
    doing [1]), because child_terminal_init is also reached after
    attaching to a process.  If we did, the new
    gdb.base/attach-non-pgrp-leader.exp test would fail, with:
    
      (gdb) attach 12415
      Attaching to program: build/gdb/testsuite/outputs/gdb.base/attach-non-pgrp-leader/attach-non-pgrp-leader, process 12415
      src/gdb/inflow.c:180: internal-error: void child_terminal_init(target_ops*): Assertion `getpgid (inf->pid) == inf->pid' failed.
      A problem internal to GDB has been detected,
      further debugging may prove unreliable.
      Quit this debugging session? (y or n) FAIL: gdb.base/attach-non-pgrp-leader.exp: child: attach to child (GDB internal error)
    
    I'm not making GDB save the pgid for attached processes with getpgid
    for now, because the saved process group affects other things which
    I'm leaving for following patches, like e.g., the "interrupt" command.
    
    [1] - https://sourceware.org/ml/gdb-patches/2017-11/msg00039.html
    
    gdb/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* gnu-nat.c (gnu_terminal_init): Delete.
    	(gnu_target): Don't install gnu_terminal_init.
    	* inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
    	(child_terminal_init): ... this function.

commit 46f67f80ddfeea11d4a8134b347c74581faff8f6
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 15:36:47 2017 +0000

    Test attaching to a process that isn't a process group leader
    
    The patch at
    <https://sourceware.org/ml/gdb-patches/2017-11/msg00039.html> was
    proposing to add an assertion to child_terminal_init that turns out
    would fail if you tried to attach to a process that isn't a process
    group leader.
    
    Since the testsuite failed to catch the problem, this commit adds a
    new testcase that would catch it, like:
    
      (gdb) attach 12415
      Attaching to program: build/gdb/testsuite/outputs/gdb.base/attach-non-pgrp-leader/attach-non-pgrp-leader, process 12415
      src/gdb/inflow.c:180: internal-error: void child_terminal_init(target_ops*): Assertion `getpgid (inf->pid) == inf->pid' failed.
      A problem internal to GDB has been detected,
      further debugging may prove unreliable.
      Quit this debugging session? (y or n) FAIL: gdb.base/attach-non-pgrp-leader.exp: child: attach to child (GDB internal error)
    
    gdb/testsuite/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/attach-non-pgrp-leader.c: New.
    	* gdb.base/attach-non-pgrp-leader.exp: New.

commit d1928160a324c1b6cd14afeecd4c81ab927883fa
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 16:19:12 2017 +0000

    Don't check termio.h and sgtty.h in common/common.m4 either
    
    common/common.m4 still had checks for termio.h/sgtty.h that are stale
    now.  Remove them.
    
    gdb/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
    	sgtty.h.
    	* config.in, configure: Regenerate.
    
    gdb/gdbserver/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* config.in, configure: Regenerate.

commit 6aa899ce25d73c397748e4df926da3fd7e5870e5
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 15:36:47 2017 +0000

    Eliminate STOP_SIGNAL, use SIGTSTP directly
    
    The STOP_SIGNAL macro was originally added for Convex Unix
    (https://en.wikipedia.org/wiki/Convex_Computer).
    
    In:
    
      git show 7a67dd45ca1c:gdb/m-convex.h
    
    we see:
    
    ~~~
      /* Use SIGCONT rather than SIGTSTP because convex Unix occasionally
         turkeys SIGTSTP.  I think.  */
    
      #define STOP_SIGNAL SIGCONT
    ~~~
    
    That's gdb-3.5, 1990...  In gdb/ChangeLog-3.x we see:
    
    ~~~
    Tue Apr 18 13:43:37 1989  Randall Smith  (randy at apple-gunkies.ai.mit.edu)
    
            Various changes involved in 1) getting gdb to work on the convex,
    	[...]
            Made whatever signal indicates a stop configurable (via macro
            STOP_SIGNAL).
            (main): Setup use of above as a signal handler.  Added check for
            "-nw" in args already processed.
            (command_line_input): SIGTSTP ==>STOP_SIGNAL.
    ~~~
    
    Support for Convex Unix is long gone, and nothing else overrides
    STOP_SIGNAL.  So just use SIGTSTP directly, removing a little
    obfuscation.
    
    (I don't really understand why we override [1] readline's SIGTSTP
    handler (only) when reading scripts (and then fail to restore it
    properly, assuming SIG_DFL...), but I'll leave that for another pass.
    
    [1] - Actually, starting with readline 6.3, readline is no longer
    installing its handlers while GDB is in control...)
    
    gdb/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
    	(async_init_signals): Adjust.
    	(handle_stop_sig): Rename to ...
    	(handle_sigtstp): ... this.
    	(async_stop_sig): Rename to ...
    	(async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
    	SIGTSTP path.
    	* event-top.h: Move signal.h include to the top.  Check SIGTSTP
    	instead of STOP_SIGNAL thoughout.
    	(handle_stop_sig): Rename to ...
    	(handle_sigtstp): ... this.
    	* top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.

commit a94799ac1e430404fda5cbc181406cf5f3630108
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 15:36:46 2017 +0000

    Don't set terminal flags twice in a row
    
    I find this odd 'set flags twice' ancient code and comment annoyingly
    distracting.  It may well be that the reason for the double-set was
    simply a copy/paste mistake, and that we've been doing this for
    decades [1] for no good reason.  Let's just get rid of it, and if we
    find a real reason, add it back with a comment explaining why it's
    necessary.
    
    [1] This double-set was already in gdb 2.4 / 1988, the oldest release
    we have sources for, and imported in git.  From 'git show 7b4ac7e1ed2c
    inflow.c':
    
       +void
       +terminal_inferior ()
       +{
       +  if (terminal_is_ours)   /*  && inferior_thisrun_terminal == 0) */
       +    {
       +      fcntl (0, F_SETFL, tflags_inferior);
       +      fcntl (0, F_SETFL, tflags_inferior);
    
    The "is there a reason" comment was added in 1993, by:
    
      commit a88797b5eadf31e21804bc820429028bf708fbcd
      Author:     Fred Fish <fnf@specifix.com>
      AuthorDate: Thu Aug 5 01:33:45 1993 +0000
    
    gdb/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* inflow.c (child_terminal_inferior, child_terminal_ours_1): No
    	longer set flags twice in row.

commit 726e13564b615e5d8e9540b509623e58dfce2012
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Nov 6 15:36:46 2017 +0000

    Assume termios is available, remove support for termio and sgtty
    
    This commit garbage collects the termio and sgtty support.
    
    GDB's terminal handling code still has support for the old termio and
    sgtty interfaces in addition to termios.  However, I think it's pretty
    safe to assume that for a long, long time, Unix-like systems provide
    termios.  GNU/Linux, Solaris, Cygwin, AIX, DJGPP, macOS and the BSDs
    all have had termios.h for many years.  Looking around the web, I
    found discussions about FreeBSD folks trying to get rid of old sgtty.h
    a decade ago:
    
      https://lists.freebsd.org/pipermail/freebsd-hackers/2007-March/019983.html
    
    So I think support for termio and sgtty in GDB is just dead code that
    is never compiled anywhere and is just getting in the way.  For
    example, serial_noflush_set_tty_state and the raw<->cooked concerns
    mentioned in inflow.c only exist because of sgtty (see
    hardwire_noflush_set_tty_state).
    
    Regtested on GNU/Linux.
    
    Confirmed that I can still build Solaris, DJGPP and AIX GDB and that
    the resulting GDBs still include the termios.h-guarded code.
    Confirmed mingw-w64 GDB still builds and skips the termios.h-guarded
    code.
    
    gdb/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* Makefile.in (SER_HARDWIRE): Update comment.
    	(HFILES_NO_SRCDIR): Remove gdb_termios.h.
    	* common/gdb_termios.h: Delete file.
    	* common/job-control.c: Include termios.h and unistd.h instead of
    	gdb_termios.h.
    	(gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
    	check.
    	(have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
    	Remove sgtty code.
    	* configure.ac: No longer check for termio.h and sgtty.h.
    	* configure: Regenerate.
    	* inflow.c: Include termios.h instead of gdb_termios.h.  Replace
    	PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
    	Replace PROCESS_GROUP_TYPE references with pid_t references
    	throughout.
    	(gdb_getpgrp): Delete.
    	(set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
    	(child_terminal_inferior): Remove comment.  Remove sgtty code.
    	(child_terminal_ours_1): Use tcgetpgrp directly instead of
    	gdb_getpgrp.  Use serial_set_tty_state instead aof
    	serial_noflush_set_tty_state.  Remove sgtty code.
    	* inflow.h: Include unistd.h instead of gdb_termios.h.  Replace
    	PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
    	(inferior_process_group): Now returns pid_t.
    	* ser-base.c (ser_base_noflush_set_tty_state): Delete.
    	* ser-base.h (ser_base_noflush_set_tty_state): Delete.
    	* ser-event.c (serial_event_ops): Update.
    	* ser-go32.c (dos_noflush_set_tty_state): Delete.
    	(dos_ops): Update.
    	* ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
    	* ser-pipe.c (pipe_ops): Update.
    	* ser-tcp.c (tcp_ops): Update.
    	* ser-unix.c: Include termios.h instead of gdb_termios.h.  Remove
    	HAVE_TERMIOS checks.
    	[HAVE_TERMIO] (struct hardwire_ttystate): Delete.
    	[HAVE_SGTTY] (struct hardwire_ttystate): Delete.
    	(get_tty_state, set_tty_state): Drop termio and sgtty code, and
    	assume termios.
    	(hardwire_noflush_set_tty_state): Delete.
    	(hardwire_print_tty_state, hardwire_drain_output)
    	(hardwire_flush_output, hardwire_flush_input)
    	(hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
    	(hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
    	code, and assume termios.
    	(hardwire_ops): Update.
    	(_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
    	* serial.c (serial_noflush_set_tty_state): Delete.
    	* serial.h (serial_noflush_set_tty_state): Delete.
    	(serial_ops::noflush_set_tty_state): Delete.
    
    gdb/gdbserver/ChangeLog:
    2017-11-06  Pedro Alves  <palves@redhat.com>
    
    	* configure.ac: No longer check for termio.h and sgtty.h.
    	* configure: Regenerate.
    	* remote-utils.c: Include termios.h instead of gdb_termios.h.
    	(remote_open): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
    	Remove termio and sgtty code.

commit 1cfb73dbb7503d1cfb088c14d1125a5030a1f386
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 16:04:03 2017 +0100

    Target FP: Merge doublest.c and dfp.c into target-float.c
    
    Now that all target FP operations are performed via target-float.c,
    this file remains the sole caller of functions in doublest.c and dfp.c.
    Therefore, this patch merges the latter files into the former and
    makes all their function static there.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* Makefile.in (SFILES): Remove doublest.c and dfp.c.
    	(HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
    	(COMMON_OBS): Remove doublest.o and dfp.o.
    	Do not build target-float.c (instead of doublest.c)
    	with -Wformat-nonliteral.
    
    	* doublest.c: Remove file.
    	* doublest.h: Remove file.
    	* dfp.c: Remove file.
    	* dfp.h: Remove file.
    
    	* target-float.c: Do not include "doublest.h" and "dfp.h".
    	(DOUBLEST): Move here from doublest.h.
    	(enum float_kind): Likewise.
    	(FLOATFORMAT_CHAR_BIT): Likewise.
    	(FLOATFORMAT_LARGEST_BYTES): Likewise.
    	(floatformat_totalsize_bytes): Move here from doublest.c.  Make static.
    	(floatformat_precision): Likewise.
    	(floatformat_normalize_byteorder, get_field, put_field): Likewise.
    	(floatformat_is_negative, floatformat_classify, floatformat_mantissa):
    	Likewise.
    	(host_float_format, host_double_format, host_long_double_format):
    	Likewise.
    	(floatformat_to_string, floatformat_from_string): Likewise.
    	(floatformat_to_doublest): Likewise.  Also, inline the original
    	convert_floatformat_to_doublest.
    	(floatformat_from_doublest): Likewise.  Also, inline the original
    	convert_floatformat_from_doublest.
    
    	Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
    	(MAX_DECIMAL_STRING): Move here from dfp.c.
    	(match_endianness): Likewise.
    	(set_decnumber_context, decimal_check_errors): Likewise.
    	(decimal_from_number, decimal_to_number): Likewise.
    	(decimal_to_string, decimal_from_string): Likewise.  Make static.
    	(decimal_from_longest, decimal_from_ulongest): Likewise.
    	(decimal_to_longest): Likewise.
    	(decimal_binop, decimal_is_zero, decimal_compare): Likewise.
    	(decimal_convert): Likewise.

commit b07e9c466ed24af614090ac42d6730a291608f69
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 16:02:33 2017 +0100

    Target FP: Remove unused floating-point routines
    
    This patch removes the following routines, which now have no remaining
    users in GDB:
     - extract_typed_floating
     - store_typed_floating
     - convert_typed_floating
     - decimal_from_doublest
     - decimal_to_doublest
     - value_as_double
     - unpack_double
     - value_from_double
     - value_from_decfloat
    
    This completes removal of DOUBLEST from all files except doublest.{c,h}
    and target-float.c.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.c: Do not include "gdbtypes.h".
    	(extract_typed_floating): Remove.
    	(store_typed_floating): Remove.
    	(convert_typed_floating): Remove.
    	* doublest.h (struct type): Remove.
    	(DOUBLEST_PRINT_FORMAT): Remove.
    	(DOUBLEST_SCAN_FORMAT): Remove.
    	(extract_typed_floating): Remove.
    	(store_typed_floating): Remove.
    	(convert_typed_floating): Remove.
    
    	* dfp.c (decimal_from_doublest): Remove.
    	(decimal_to_doublest): Remove.
    	* dfp.h: Do not include "doublest.h".
    	(decimal_from_doublest): Remove.
    	(decimal_to_doublest): Remove.
    
    	* value.c: Do not include "doublest.h" and "dfp.h".
    	(value_as_double): Remove.
    	(unpack_double): Remove.
    	(value_from_double): Remove.
    	(value_from_decfloat): Remove.
    	* value.h: Do not include "doublest.h".
    	(value_as_double): Remove.
    	(unpack_double): Remove.
    	(value_from_double): Remove.
    	(value_from_decfloat): Remove.

commit 3b2ca8248cae742c00cb4e94138edf1403d43d47
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 16:01:37 2017 +0100

    Target FP: Remove convert_typed_floating from tdep files
    
    This patch mechanically replaces convert_typed_floating with the
    equivalent target_float_convert throughout tdep files, to prepare
    for the removal of doublest.{c,h}.
    
    No functional change intended.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* i386-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(i386_extract_return_value): Use target_float_convert.
    	(i386_store_return_value): Likewise.
    	* i387-tdep.c (i387_register_to_value): Use target_float_convert.
    	(i387_value_to_register): Likewise.
    	* ia64-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(ia64_register_to_value): Use target_float_convert.
    	(ia64_value_to_register): Likewise.
    	(ia64_extract_return_value): Likewise.
    	(ia64_store_return_value): Likewise.
    	(ia64_push_dummy_call): Likewise.
    	* m68k-tdep.c: Include "target-float.h".
    	(m68k_register_to_value): Use target_float_convert.
    	(m68k_value_to_register): Likewise.
    	(m68k_svr4_extract_return_value): Likewise.
    	(m68k_svr4_store_return_value): Likewise.
    	* ppc-sysv-tdep.c: Include "target-float.h".
    	(ppc_sysv_abi_push_dummy_call): Use target_float_convert.
    	(do_ppc_sysv_return_value): Likewise.
    	(ppc64_sysv_abi_push_freg): Likewise.
    	(ppc64_sysv_abi_return_value_base): Likewise.
    	* rs6000-aix-tdep.c: Include "target-float.h".
    	(rs6000_push_dummy_call): Use target_float_convert.
    	(rs6000_return_value): Likewise.
    	* rs6000-lynx178-tdep.c: Include "target-float.h".
    	(rs6000_lynx178_push_dummy_call): Use target_float_convert.
    	(rs6000_lynx178_return_value): Likewise.
    	* rs6000-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(rs6000_register_to_value): Use target_float_convert.
    	(rs6000_value_to_register): Likewise.
    	* arm-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(arm_extract_return_value): Use target_float_convert.
    	(arm_store_return_value): Likewise.
    	* sh-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(sh_register_convert_to_virtual): Use target_float_convert.
    	(sh_register_convert_to_raw): Likewise.
    	* sh64-tdep.c: Include "target-float.h".
    	(sh64_extract_return_value): Use target_float_convert.
    	(sh64_register_convert_to_virtual): Likewise.
    	(sh64_register_convert_to_raw): Likewise.  Fix argument types.

commit 14ad9311720fc17bd646b2ff08483fe60a489959
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 16:00:47 2017 +0100

    Target FP: Handle interfaces to scripting languages
    
    The last remaing use for DOUBLEST is in the code that interfaces to the
    scripting languages (Python and Guile).  The problem here is that we
    expose interfaces to convert a GDB value to and from native values of
    floating-point type in those languages, and those by definition use
    the host floating-point format.
    
    While we cannot completely eliminate conversions to/from the host
    floating-point format here, we still need to get rid of the uses
    of value_as_double / value_from_double, since those will go away.
    
    This patch implements two new target-float.c routine:
     - target_float_to_host_double
     - target_float_from_host_double
    which convert to/from a host "double".  Those should only ever be
    used where a host "double" is mandated by an external interface.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c (floatformat_to_host_double): New function.
    	(floatformat_from_host_double): Likewise.
    	(target_float_to_host_double): Likewise.
    	(target_float_from_host_double): Likewise.
    	* target-float.h (target_float_to_host_double): Add prototype.
    	(target_float_from_host_double): Likewise.
    
    	* guile/scm-value.c: Include "target-float.h".
    	(gdbscm_value_to_real): Use target_float_to_host_double.
    	Handle integer source values via value_as_long.
    	* guile/scm-math.c: Include "target-float.h".  Do not include
    	"doublest.h", "dfp.h", and "expression.h".
    	(vlscm_convert_typed_number): Use target_float_from_host_double.
    	(vlscm_convert_number): Likewise.
    
    	* python/py-value.c (valpy_float): Use target_float_to_host_double.
    	(convert_value_from_python): Use target_float_from_host_double.

commit 50eff16b85073287b1b184a257a8fd80e960fe02
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 15:59:36 2017 +0100

    Target FP: Perform Ada fixed-point scaling in target format
    
    One of the few still remaining uses of DOUBLEST in GDB is the Ada front-end
    code that handles scaling of Ada fixed-point types.  The target format for
    those types is some integer format; to convert those values to standard
    floating-point representation, that integer needs to be multiplied by a
    rational scale factor, given as a pair of numerator and denominator.
    
    To avoid having to deal with long integer arithmetic, the current Ada
    front-end code currently performs those scaling operations in host
    DOUBLEST arithmetic.  To eliminate this use of DOUBLEST, this patch
    changes the front-end to instead perform those operations in the
    *target* floating-point format (chosing to use the target "long double").
    
    The implementation is mostly straight-forward, using value_cast and
    value_binop to perform the target operations.
    
    Scanning in the scale numerator and denominator is now done into
    a host "long long" instead of a DOUBLEST, which should be large
    enough to hold all possible values.  (Otherwise, this can be replaced
    by target-format target_float_from_string operations as well.)
    
    Printing fixed-point types and values should be completely unchanges,
    using target_float_to_string with the same format strings as current code.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
    	(cast_from_fixed): Likewise.
    	(ada_scaling_type): New function.
    	(ada_delta): Return value instead of DOUBLEST.  Perform target
    	arithmetic instead of host arithmetic.
    	(scaling_factor): Rename to ...
    	(ada_scaling_factor) ... this.  Make non-static.  Return value instead
    	of DOUBLEST.  Perform target arithmetic instead of host arithmetic.
    	(ada_fixed_to_float): Remove.
    	(ada_float_to_fixed): Remove.
    	* ada-lang.h (ada_fixed_to_float): Remove.
    	(ada_float_to_fixed): Remove.
    	(ada_delta): Return value instead of DOUBLEST.
    	(ada_scaling_factor): Add prototype.
    
    	* ada-typeprint.c: Include "target-float.h".
    	(print_fixed_point_type): Perform target arithmetic instead of
    	host arithmetic.
    	* ada-valprint.c: Include "target-float.h".
    	(ada_val_print_num): Perform target arithmetic instead of
    	host arithmetic for fixed-point types.

commit 66c02b9ed1eabf1d7981c0c27ec9fd3c17fc5d35
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 15:58:46 2017 +0100

    Target FP: Add binop and compare routines to target-float.{c,h}
    
    This patch adds the following target floating-point routines:
     - target_float_binop
     - target_float_compare
    which call the equivalent decimal_ routines to handle decimal FP,
    and call helper routines that currently still go via DOUBLEST to
    handle binary FP (derived from current valarith.c code).
    
    These routines are used to handle both binary and decimal FP types
    in scalar_binop, value_equal, and value_less, mostly following the
    method currently used for decimal FP.  The existing value_args_as_decimal
    helper is renamed to value_args_as_target_float and extended to handle
    both binary and decimal types.
    
    The unary operations value_pos and value_neg are also simplified,
    the former by using a simple copy for all scalar types, the latter
    by using value_binop (... BINOP_SUB) to implement negation as
    subtraction from zero.
    
    ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c: Include <math.h>.
    	(floatformat_binop): New function.
    	(floatformat_compare): Likewise.
    	(target_float_binop): Likewise.
    	(target_float_compare): Likewise.
    	* target-float.h: Include "expression.h".
    	(target_float_binop): Add prototype.
    	(target_float_compare): Likewise.
    
    	* valarith.c: Do not include "doublest.h" and "dfp.h".
    	Include "common/byte-vector.h".
    	(value_args_as_decimal): Remove, replace by ...
    	(value_args_as_target_float): ... this function.  Handle both
    	binary and decimal target floating-point formats.
    	(scalar_binop): Handle both binary and decimal FP using
    	value_args_as_target_float and target_float_binop.
    	(value_equal): Handle both binary and decimal FP using
    	value_args_as_target_float and target_float_compare.
    	(value_less): Likewise.
    	(value_pos): Handle all scalar types as simple copy.
    	(value_neg): Handle all scalar types via BINOP_SUB from 0.
    	* dfp.c (decimal_binop): Throw error instead of internal_error
    	when called with an unsupported operation code.

commit 50637b26f85dc3e59b616f1b01ca8885cf98f0b4
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 15:57:31 2017 +0100

    Target FP: Add conversion routines to target-float.{c,h}
    
    This patch adds the following conversion routines:
     - target_float_to_longest
     - target_float_from_longest
     - target_float_from_ulongest
     - target_float_convert
    which call the equivalent decimal_ routines to handle decimal FP,
    and call helper routines that currently still go via DOUBLEST to
    handle binary FP.
    
    The target_float_convert routine not only handles BFP<->BFP and
    DFP<->DFP conversions, but also BFP<->DFP, which are implemented
    by converting to a string and back.
    
    These helpers are used in particular to implement conversion
    from and to FP in value_cast, without going through DOUBLEST there.
    In order to implement this for the FP<-integer case, the
    pack_long / pack_unsigned_long routines are extended to support
    floating-point values as output (thereby allowing use of
    value_from_[u]longest with a floating-point target type).
    
    This latter change also allows simplification of value_one.
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c (floatformat_to_longest): New function.
    	(floatformat_from_longest, floatformat_from_ulongest): Likewise.
    	(floatformat_convert): Likewise.
    	(target_float_to_longest): Likewise.
    	(target_float_from_longest, target_float_from_ulongest): Likewise.
    	(target_float_convert): Likewise.
    	* target-float.h (target_float_to_longest): Add prototype.
    	(target_float_from_longest, target_float_from_ulongest): Likewise.
    	(target_float_convert): Likewise.
    
    	* value.c (unpack_long): Use target_float_to_longest.
    	(pack_long): Allow FP types.  Use target_float_from_longest.
    	(pack_unsigned_long): Likewise using target_float_from_ulongest.
    	* valops.c: Include "target-float.h".  Do not include "dfp.h".
    	(value_cast): Handle conversions to FP using target_float_convert,
    	value_from_ulongest, and value_from_longest.
    	(value_one): Use value_from_longest for FP types as well.

commit f69fdf9bca80ac703890a51e124e408cbccbb743
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 15:56:35 2017 +0100

    Target FP: Add string routines to target-float.{c,h}
    
    This adds target_float_to_string and target_float_from_string,
    which dispatch to the corresponding floatformat_ or decimal_ routines.
    
    Existing users of those routines are changed to use the new
    target-float routines instead (most of those places already handle
    both binary and decimal FP).
    
    In addition, two other places are changes to use target_float_from_string:
    
    - define_symbol in stabsread.c, when parsing a floating-point literal
      from stabs debug info
    
    - gdbarch-selftest.c when initializing a target format values (to
      eliminate use of DOUBLEST there).
    
    gdb/ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* target-float.c (target_float_to_string): New function.
    	(target_float_from_string): New function.
    	* target-float.h (target_float_to_string): Add prototype.
    	(target_float_from_string): Add prototype.
    
    	* valprint.c: Include "target-float.h".  Do not include
    	"doublest.h" and "dfp.h".
    	(print_floating): Use target_float_to_string.
    	* printcmd.c: Include "target-float.h".  Do not include "dfp.h".
    	(printf_floating): Use target_float_to_string.
    	* i387-tdep.c: Include "target-float.h".  Do not include "doublest.h".
    	(print_i387_value): Use target_float_to_string.
    	* mips-tdep.c: Include "target-float.h".
    	(mips_print_fp_register): Use target_float_to_string.
    	* sh64-tdep.c: Include "target-float.h".
    	(sh64_do_fp_register): Use target_float_to_string.
    
    	* parse.c: Include "target-float.h".  Do not include
    	"doublest.h" and "dfp.h".
    	(parse_float): Use target_float_from_string.
    	* stabsread.c: Include "target-float.h".  Do not include "doublest.h".
    	(define_symbol): Use target_float_from_string.
    	* gdbarch-selftests.c: Include "target-float.h".
    	(register_to_value_test): Use target_float_from_string.

commit 701000146a01f1966c59f50d7b638915917b6378
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Mon Nov 6 15:55:11 2017 +0100

    Target FP: Introduce target-float.{c,h}
    
    This patch introduces the new set of target floating-point handling routines
    in target-float.{c,h}.  In the end, the intention is that this file will
    contain support for all operations in target FP format, fully replacing
    both the current doublest.{c,h} and dfp.{c,h}.
    
    To begin with, this patch only adds a target_float_is_zero routine,
    which handles the equivalent of decimal_is_zero for both binary and
    decimal FP.  For the binary case, to avoid conversion to DOUBLEST,
    this is implemented using the floatformat_classify routine.
    
    However, it turns out that floatformat_classify actually has a bug
    (it was not used to check for zero before), so this is fixed as well.
    
    The new routine is used in both value_logical_not and valpy_nonzero.
    
    There is one extra twist: the code previously used value_as_double
    to convert to DOUBLEST and then compare against zero.  That routine
    performs an extra task: it detects invalid floating-point values
    and raises an error.  In any place where value_as_double is removed
    in favor of some target-float.c routine, we need to replace that check.
    
    To keep this check centralized in one place, I've added a new routine
    is_floating_value, which returns a boolean determining whether a
    value's type is floating point (binary or decimal), and if so, also
    performs the validity check.  Since we need to check whether a value
    is FP before calling any of the target-float routines anyway, this
    seems a good place to add the check without much code size overhead.
    
    In some places where we only want to check for floating-point types
    and not perform a validity check (e.g. for the *output* of an operation),
    we can use the new is_floating_type routine (in gdbarch) instead.
    
    The validity check itself is done by a new target_float_is_valid
    routine in target-float, encapsulating floatformat_is_valid.
    
    ChangeLog:
    2017-11-06  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* Makefile.c (SFILES): Add target-float.c.
    	(HFILES_NO_SRCDIR): Add target-float.h.
    	(COMMON_OBS): Add target-float.o.
    	* target-float.h: New file.
    	* target-float.c: New file.
    
    	* doublest.c (floatformat_classify): Fix detection of float_zero.
    
    	* gdbtypes.c (is_floating_type): New function.
    	* gdbtypes.h (is_floating_type): Add prototype.
    
    	* value.c: Do not include "floatformat.h".
    	(unpack_double): Use target_float_is_valid.
    	(is_floating_value): New function.
    	* value.h (is_floating_value): Add prototype-
    
    	* valarith.c: Include "target-float.h".
    	(value_logical_not): Use target_float_is_zero.
    
    	* python/py-value.c: Include "target-float.h".
    	(valpy_nonzero): Use target_float_is_zero.

commit 74be0bdc3bf8ae5b2e70992730539bca1d1b43ee
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Nov 6 00:00:29 2017 +0000

    Automatic date update in version.in

commit 26a9301057457ae576b51b8127bb805b4e484a6b
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Nov 5 19:52:13 2017 +1030

    Proper bound check in _bfd_doprnt_scan
    
    While an abort after storing out of bounds by one to an array in our
    caller is probably OK in practice, it's better to check before storing.
    
    	PR 22397
    	* bfd.c (_bfd_doprnt_scan): Check args index before storing, not
    	after.

commit 7167fe4c70ea74f1bb74a6130bb7e6bf5ca354ee
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Nov 5 16:22:55 2017 +1030

    PR22397, BFD internal error when message locale isn't C
    
    This adds positional parameter support to the bfd error handler,
    something that was lost 2017-04-13 when _doprnt was added with commit
    c08bb8dd.  The number of format args is now limited to 9, which is
    sufficient for current _bfd_error_handler messages.  If someone
    exceeds 9 args they get the joy of modifying this code to support more
    args (shouldn't be too difficult).
    
    	PR 22397
    	* bfd.c (union _bfd_doprnt_args): New.
    	(PRINT_TYPE): Add FIELD arg.  Take value from args.
    	(_bfd_doprnt): Replace ap parameter with args.  Adjust all
    	PRINT_TYPE invocations and reading of format args to suit.
    	Move "%%" handling out of switch handling args.  Support
    	positional parameters.
    	(_bfd_doprnt_scan): New function.
    	(error_handler_internal): Call _bfd_doprnt_scan and read args.

commit 0724bd460babc0c3c31aa67b5f8385a4cb5279f9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Nov 5 00:00:26 2017 +0000

    Automatic date update in version.in

commit f15d0b545b9e9dada8d1398163693f67792e9e79
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Nov 4 13:41:29 2017 +1030

    powerpc TLS in PIEs
    
    This patch removes unnecessary GOT IE TLS relocations in PIEs.  Useful
    with --no-tls-optimize, or with an enormous TLS segment.  With the
    default --tls-optimize in effect IE code sequences will be edited to
    LE under the same circumstances we can remove the GOT reloc.
    
    	* elf32-ppc.c (got_entries_needed, got_relocs_needed): New functions.
    	(allocate_dynrelocs, ppc_elf_size_dynamic_sections): Use them here.
    	(ppc_elf_relocate_section): Don't output a dynamic relocation
    	for IE GOT entries in an executable.
    	* elf64-ppc.c (allocate_got): Trim unnecessary TPREL relocs.
    	(ppc64_elf_size_dynamic_sections): Likewise.
    	(ppc64_elf_relocate_section): Likewise.

commit 98bbb1b86180324b278842d8d73c79cb5d76d349
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Nov 2 08:05:03 2017 +1030

    PowerPC readonly_dynrelocs
    
    PowerPC64 lacked the mapfile textrel warning on finding dynamic relocs
    in read-only sections.  This patch adds it, and tidies the
    readonly_dynrelocs interface.  PowerPC doesn't need a SEC_ALLOC test
    because !SEC_ALLOC sections are excluded by check_relocs so will never
    have dyn_relocs.
    
    	* elf32-ppc.c (readonly_dynrelocs): Delete info param.  Update all
    	callers.  Don't bother with SEC_ALLOC test.  Return section pointer.
    	Move minfo call to..
    	(maybe_set_textrel): ..here.
    	* elf64-ppc.c (readonly_dynrelocs): Return section pointer.
    	(maybe_set_textrel): Call minfo to print textrel warning to map file.

commit 2e684e75ae3939f5f14fb89ca8a300b610d093dd
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Nov 2 12:09:34 2017 +1030

    hppa-linux TLS relocs
    
    This patch fixes various problems with TLS relocations.
    
    1) Report an error if a symbol has both TLS and normal GOT entries.
    2) The GOT entry size calculation was obscure and made use of the fact
       that a symbol shouldn't have both normal and TLS GOT entries.
    3) The second word of a GD GOT entry sometimes omitted a dynamic
       reloc, which was fine except that doing so makes it impossible for
       ld.so to differentiate GD and LD entries.  Also, a NONE reloc was
       emitted.
    4) Unnecessary relocs were emitted for GOT entries.
    5) GOT relocs didn't take note of UNDEFWEAK_NO_DYNAMIC_RELOC.
    
    	* elf32-hppa.c (enum _tls_type): Move.
    	(struct elf32_hppa_link_hash_entry): Make tls_type a bitfield.
    	(elf32_hppa_check_relocs): Set DF_STATIC_TLS only for shared libraries.
    	Tidy tls_type handling.  Set symbol tls_type for GOT_TLS_LDM too.
    	(got_entries_needed, got_relocs_needed): New functions.
    	(allocate_dynrelocs): Use them.
    	(elf32_hppa_size_dynamic_sections): Likewise.
    	(elf32_hppa_relocate_section): Delete bogus FIXME.  Formatting.
    	Correct code emitting relocs on GD/IE got entries.  Report an
    	error when a symbol has both normal and TLS GOT relocs.

commit 127e8e9f62ed0e7145dfa1172c6253275fc150dd
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 31 18:13:03 2017 +1030

    PR22394, hppa-linux-ld fails to emit dynamic relocations
    
    gcc -mfast-indirect-calls emits a function pointer initialization
    without a P% (plabel) modifier.  ld does not create the necessary
    dynamic relocations for this to work.  It turns out that the problem
    is caused by the non_got_ref symbol flag.  This flag is set for
    non-pic by check_relocs to indicate that the symbol might need copy
    relocations or dynamic relocations.  Later, the backend
    adjust_dynamic_symbol clears the flag to indicate dynamic relocations
    are needed, but leaves it set when copy relocations were created.  The
    inversion in meaning is insane, but it's that way because the backend
    adjust_dynamic_symbol function doesn't get to look at all symbols..
    Anyway, the insanity works for non-function symbols.  However, the
    flag is left set on any function symbol with a dynamic relocation.
    
    This patch fixes the non_got_ref handling for function symbols, adds
    -z nocopyreloc for hppa-elf, reports where textrel occurs, and expands
    comments.  The check_relocs change just stops creation of dyn_relocs
    we always threw away later.
    
    	PR 22394
    	* elf32-hppa.c (elf32_hppa_check_relocs): Don't create dyn_relocs
    	for plabels when non-pic.
    	(maybe_set_textrel): New function.
    	(readonly_dynrelocs): Move and rewrite.
    	(elf32_hppa_adjust_dynamic_symbol): Use it.  Don't create copy
    	relocs when def_regular or -z nocopyreloc.  Handle non_got_ref
    	for functions.  Expand non_got_ref comments.
    	(elf32_hppa_size_dynamic_sections): Use maybe_set_textrel.

commit ab4b1c4699fecd1f2461cecae108e7c583c15bc4
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 22:46:40 2017 -0600

    Use std::vector in h8300-tdep.c
    
    This changes h8300-tdep.c to use std::vector, allowing the removal of
    a cleanup.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* h8300-tdep.c (h8300_push_dummy_call): Use std::vector.

commit 454dafbdf2d1293a9b18a6fe9e9c9e0911eb740c
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 22:32:45 2017 -0600

    Introduce gdb_breakpoint_up
    
    This introduces gdb_breakpoint_up, a unique_ptr typedef that owns a
    breakpoint.  It then changes set_momentary_breakpoint to return a
    gdb_breakpoint_up and fixes up the fallout.  This then allows the
    removal of make_cleanup_delete_breakpoint.
    
    Once breakpoints are fully C++-ified, this typedef can be removed in
    favor of a plain std::unique_ptr.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (set_momentary_breakpoint): Return
    	breakpoint_up.
    	(until_break_command): Update.
    	(new_until_break_fsm): Change argument types to
    	breakpoint_up.
    	(set_momentary_breakpoint_at_pc): Return breakpoint_up.
    	(do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
    	Remove.
    	* infcmd.c (finish_forward): Update.
    	* breakpoint.h (set_momentary_breakpoint)
    	(set_momentary_breakpoint_at_pc): Return breakpoint_up.
    	(make_cleanup_delete_breakpoint): Remove.
    	(struct breakpoint_deleter): New.
    	(breakpoint_up): New typedef.
    	* infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
    	(insert_exception_resume_breakpoint): Update.
    	(insert_exception_resume_from_probe): Update.
    	(insert_longjmp_resume_breakpoint): Update.
    	* arm-linux-tdep.c (arm_linux_copy_svc): Update.
    	* elfread.c (elf_gnu_ifunc_resolver_stop): Update.
    	* infcall.c (call_function_by_hand_dummy): Update

commit 331b71e5ee226cb5455969899274f0e43e83aa1e
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 19:16:58 2017 -0600

    Use unique_xmalloc_ptr in c_type_print_base
    
    This changes c_type_print_base to use unique_xmalloc_ptr, removing a
    cleanup.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.

commit 9f584b37e36b67009fa23b6cffbec1bf691ef9ba
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 19:11:20 2017 -0600

    Remove cleanups from linux-tdep.c
    
    This removes some cleanups from linux-tdep.c, replacing them with
    def_vector or byte_vector as appropriate.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* linux-tdep.c (linux_core_info_proc_mappings): Use
    	gdb::def_vector.
    	(linux_get_siginfo_data): Return gdb::byte_vector.  Remove
    	"size" argument.
    	(linux_corefile_thread): Update.
    	(linux_make_corefile_notes): Remove unused variable.

commit 779bc38eca950c7f3b64173e99e25f0c0edfbe3b
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 18:52:30 2017 -0600

    Use gdb::byte_vector in ppc-linux-tdep.c
    
    This removes a cleanup from ppc-linux-tdep.c, replacing it with
    gdb::byte_vector.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
    	gdb::byte_vector.

commit ed2b3126d1828d55d57880c6b6045a4e58c05cde
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 18:51:15 2017 -0600

    Remove make_cleanup_free_objfile
    
    This replaces make_cleanup_free_objfile with std::unique_ptr.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* objfiles.c (do_free_objfile_cleanup): Remove.
    	* compile/compile-object-load.c (compile_object_load): Update.
    	* objfiles.h (make_cleanup_free_objfile): Remove.

commit 7f6743fd09d0f3188dd9dcdf31acf81131f9bf1f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 16:37:27 2017 -0600

    Use gdb::def_vector in sparc64-tdep.c
    
    This removes a cleanup from sparc64-tdep.c, replacing it with
    gdb::def_vector.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* sparc64-tdep.c (do_examine): Use gdb::def_vector.
    	(adi_read_versions): Change "tags" to "gdb_byte *".
    	(adi_print_versions): Likewise.

commit c80049d3b615691dc902762d5d97551aa9664442
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 09:00:09 2017 -0600

    Replace start_rbreak_breakpoints and end_rbreak_breakpoints
    
    This replaces start_rbreak_breakpoints and end_rbreak_breakpoints with
    a new scoped class.  This allows the removal of a cleanup.
    
    This also fixes an earlier memory leak regression, by changing
    "string" to be a std::string.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c
    	(scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
    	from start_rbreak_breakpoints.
    	(scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
    	* breakpoint.h (class scoped_rbreak_breakpoints): New.
    	(start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
    	* symtab.c (do_end_rbreak_breakpoints): Remove.
    	(rbreak_command): Use scoped_rbreak_breakpoints, std::string.

commit 167b0be1b5ef36a5605fcdfba0c84db2ed475e1e
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Nov 1 08:32:13 2017 -0600

    Remove directive-searched cleanups
    
    This removes a few cleanups related to the "searched" field in
    struct using_direct, replacing these with scoped_restore.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* cp-namespace.c (reset_directive_searched): Remove.
    	(cp_lookup_symbol_via_imports): Use scoped_restore.
    	* cp-support.c (reset_directive_searched): Remove.
    	(make_symbol_overload_list_using): Use scoped_restore.
    	* d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
    	(reset_directive_searched): Remove.

commit 5eae7aeaf754549d3645a0c590c5ef9f0134a32d
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 25 15:52:23 2017 -0600

    Use unique_xmalloc_ptr in find_separate_debug_file_by_debuglink
    
    This changes find_separate_debug_file_by_debuglink to use
    unique_xmalloc_ptr, removing some cleanups.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (find_separate_debug_file_by_debuglink): Use
    	unique_xmalloc_ptr.

commit c6bcad5ffc9b4021253487e46a8754e5804135cf
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 25 15:46:31 2017 -0600

    Use std::vector in compile-loc2c.c
    
    This changes compile-loc2c.c to use std::vector, removing some
    cleanups.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile-loc2c.c (compute_stack_depth_worker): Change
    	type of "info".
    	(compute_stack_depth): Likewise.
    	(do_compile_dwarf_expr_to_c): Use std::vector.

commit 20dcd8cae7d87910f6c3936bad72e78b647a8de6
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 25 15:44:56 2017 -0600

    Remove cleanups from link_callbacks_einfo
    
    This removes a cleanup from link_callbacks_einfo by using std::string.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile-object-load.c (link_callbacks_einfo): Use
    	std::string.

commit 33c7c59df060e9952fc2f608c3a6ff0a23ecd40d
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 20 09:30:48 2017 -0600

    Replace really_free_pendings with a scoped_ class
    
    This introduces scoped_free_pendings, and changes users of
    really_free_pendings to use it instead, removing some clenaups.
    
    I tried to examine the affected code to ensure there aren't dangling
    cleanups in the vicinity.
    
    gdb/ChangeLog
    2017-11-04  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2read.c (process_full_comp_unit, process_full_type_unit):
    	Use scoped_free_pendings.
    	* dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
    	scoped_free_pendings.
    	* xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
    	(xcoff_initial_scan): Likewise.
    	* buildsym.c (reset_symtab_globals): Update comment.
    	(scoped_free_pendings): Rename from really_free_pendings.
    	(prepare_for_building): Update comment.
    	(buildsym_init): Likewise.
    	* buildsym.h (class scoped_free_pendings): New class.
    	(really_free_pendings): Don't declare.

commit ebe6dbc2645081e3a166865f057e7cc9643e7e12
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Nov 4 00:00:27 2017 +0000

    Automatic date update in version.in

commit 79b0c981b8f0c912208ec305d48e775bcb6d2624
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 3 11:14:56 2017 -0700

    x86: Remove func_pointer_refcount
    
    Since check_reloc is running after gc_sections, there is no need for
    reference count.  If a function pointer relocation can be resolved at
    run-time, there is no need for PLT and it doesn't count as non-GOT/PLT
    relocation.  func_pointer_refcount can be removed.
    
    	* elf32-i386.c (elf_i386_check_relocs): Set plt.refcount to 1.
    	Don't use func_pointer_refcount.  Don't set plt.refcount nor
    	non_got_ref for function pointer reference.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
    	* elfxx-x86.c (elf_x86_allocate_dynrelocs): Don't use
    	func_pointer_refcount.
    	(_bfd_x86_elf_copy_indirect_symbol): Don't copy
    	func_pointer_refcount.
    	(_bfd_x86_elf_hide_symbol): Don't use func_pointer_refcount.
    	* elfxx-x86.h (GENERATE_DYNAMIC_RELOCATION_P): Likewise.
    	(elf_x86_link_hash_entry): Remove func_pointer_refcount.

commit 10a3785b1e4ae68bf9c6a2d39eb79aefa44a0e9d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 3 11:13:03 2017 -0700

    Apply "x86: Remove func_pointer_refcount"

commit 67fa57cfa536cefb5ae7cc4635db66d03fdbd8bb
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Fri Nov 3 16:07:23 2017 +0100

    Fix regression on ARM after Target FP patches
    
    Commit edd079d9f6ca2f9ad21322b742269aec5de61190 exposed a pre-existing bug
    in convert_doublest_to_floatformat.  In the specific case of converting
    a zero value to a floatformat using a "special" byteorder (i.e. neither
    floatformat_little nor floatformat_big), the output buffer was actually
    left uninitialized.
    
    gdb/ChangeLog:
    2017-11-03  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.c (convert_doublest_to_floatformat): Fix uninitialized
    	output when converting a zero value to a special byteorder format.

commit fdddd2900f39584e7d6cee27127593fba2cb0cf2
Author: claziss <claziss@synopsys.com>
Date:   Fri Nov 3 15:36:42 2017 +0100

    [ARC] Force the disassam to use the hexadecimal number for printing
    
    Force printing of the short/signed values using hexadecimal
    representation via disassembler option.
    
    opcode/
    2017-11-03  Claudiu Zissulescu  <claziss@synopsys.com>
    
            * arc-dis.c (print_hex): New variable.
            (parse_option): Check for hex option.
            (print_insn_arc): Use hexadecimal representation for short
            immediate values when requested.
            (print_arc_disassembler_options): Add hex option to the list.
    
    binutils/
    2017-11-03  Claudiu Zissulescu  <claziss@synopsys.com>
    
            * doc/binutils.texi (ARC): Update disassembler options.
            * testsuite/binutils-all/arc/hexprint.s: New file.
            * testsuite/binutils-all/arc/objdump.exp: Test hex printing feature.

commit 7605d944531519ddf9026bf059475a4347c83aa4
Author: Siddhesh Poyarekar <siddhesh@sourceware.org>
Date:   Fri Nov 3 19:33:03 2017 +0530

    Add option for Qualcomm Saphira part
    
    This adds an option for the Qualcomm saphira core, the corresponding
    gcc patch is here:
    
    https://gcc.gnu.org/ml/gcc-patches/2017-10/msg02055.html
    
    This was tested with an aarch64 build and make check and also by
    building and running SPEC2006.
    
    	gas/
    	* config/tc-aarch64.c (aarch64_cpus): Add saphira.
    	* doc/c-aarch64.texi: Likewise.

commit bf59c5d5f4f5b8b4da1f5f605cfa546f8029b43d
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Nov 3 13:57:15 2017 +0000

    Fix integer overflow problems when reading an ELF binary with corrupt augmentation data.
    
    	PR 22386
    	* dwarf.c (read_cie): Use bfd_size_type for
    	augmentation_data_len.
    	(display_augmentation_data): New function.
    	(display_debug_frames): Use it.
    	Check for integer overflow when testing augmentation_data_len.

commit 3334eba7f4aeaa06926d5f1fb51446c5cea43e42
Author: claziss <claziss@synopsys.com>
Date:   Fri Nov 3 14:38:05 2017 +0100

    [ARC] Sync opcode data base.
    
    New EM and HS variants are developed, sync the data base to match them.
    
    opcodes/
    2017-11-03  Claudiu Zissulescu  <claziss@synopsys.com>
    
            * arc-tbl.h (abss, abssh, adc, adcs, adds, aslacc, asls, aslsacc)
            (asrs, asrsr, cbflyhf0r, cbflyhf1r, cmacchfr, cmacchnfr, cmachfr)
            (cmachnfr, cmpychfr, cmpychnfr, cmpyhfmr, cmpyhfr, cmpyhnfr, divf)
            (dmachbl, dmachbm, dmachf, dmachfr, dmacwhf, dmpyhbl, dmpyhbm)
            (dmpyhf, dmpyhfr, dmpyhwf, dmpywhf, dsync, flagacc, getacc, macdf)
            (macf, macfr, macwhfl, macwhflr, macwhfm, macwhfmr, macwhkl)
            (macwhkul, macwhl, macwhul, mpydf, mpyf, mpyfr, mpywhfl, mpywhflr)
            (mpywhfm, mpywhfmr, mpywhkl, mpywhkul, mpywhl, mpywhul, msubdf)
            (msubf, msubfr, msubwhfl, msubwhflr, msubwhfm, msubwhfmr, mul64)
            (negs, negsh, normacc, qmachf, qmpyh, qmpyhf, rndh, satf, sath)
            (sbcs, setacc, sflag, sqrt, sqrtf, subs, swi_s, vabs2h, vabss2h)
            (vadd4b, vadds2, vadds2h, vadds4h, vaddsubs, vaddsubs2h)
            (vaddsubs4h, valgn2h, vasl2h, vasls2h, vasr2h, vasrs2h, vasrsr2h)
            (vext2bhl, vext2bhlf, vext2bhm, vext2bhmf, vlsr2h, vmac2hf)
            (vmac2hfr, vmac2hnfr, vmax2h, vmin2h, vmpy2h, vmpy2hf, vmpy2hfr)
            (vmpy2hwf, vmsub2hf, vmsub2hfr, vmsub2hnfr, vneg2h, vnegs2h)
            (vnorm2h, vpack2hbl, vpack2hblf, vpack2hbm, vpack2hbmf, vpack2hl)
            (vpack2hm, vperm, vrep2hl, vrep2hm, vsext2bhl, vsext2bhm, vsub4b)
            (vsubadds, vsubadds2h, vsubadds4h, vsubs2, vsubs2h, vsubs4h):
            Changed opcodes.
            (prealloc, prefetch*): Place them before ld instruction.
            * arc-opc.c (skip_this_opcode): Add ARITH class.

commit 50ab6ace3803ca317f265dae6064494e3b7fa8cb
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 3 12:53:53 2017 +0000

    Skip gdb.mi/list-thread-groups-available.exp if no xml support
    
    I see the following test fail in gdb (configured --with-expat=no),
    
    -list-thread-groups --available^M
    &"warning: Can not parse XML OS data; XML support was disabled at compile time\n"^M
    ^error,msg="Can not fetch data now."^M
    (gdb) ^M
    FAIL: gdb.mi/list-thread-groups-available.exp: list available thread groups (unexpected output)
    
    This patch skips it if XML parsing in GDB is disabled, like what you did
    in gdb.mi/mi-info-os.exp.
    
    gdb/testsuite:
    
    2017-11-03  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.mi/list-thread-groups-available.exp: Skip it if XML parsing
    	in GDB is disabled.

commit 6cee897971d4d7cd37d2a686bb6d2aa3e759c8ca
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Nov 3 11:55:21 2017 +0000

    Fix excessive memory allocation attempts and possible integer overfloaws when attempting to read a COFF binary with a corrupt symbol count.
    
    	PR 22385
    	* coffgen.c (_bfd_coff_get_external_symbols): Check for an
    	overlarge raw syment count.
    	(coff_get_normalized_symtab): Likewise.

commit 8e68731c8a4aecb3481803e91b9bcd2df182c135
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Nov 3 10:36:42 2017 +0000

    Skip gdb.python/py-thrhandle.exp if python is not enabled.
    
    gdb/testsuite:
    
    2017-11-03  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.python/py-thrhandle.exp: Skip it if python is not
    	enabled.

commit 3d47a7fef640b0a5a90aa7494c41982cf84a4092
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Nov 3 00:00:26 2017 +0000

    Automatic date update in version.in

commit c05e0c5af35ebbb1ca39bb1efffae2adecdfa253
Author: Siddhesh Poyarekar <siddhesh@sourceware.org>
Date:   Thu Nov 2 22:49:32 2017 +0530

    aarch64: Remove AARCH64_FEATURE_F16 from AARCH64_ARCH_V8_2
    
    The FP16 feature is optional in ARMv8.2, so it is wrong to add it to
    the default AARCH64_ARCH_V8_2 feature flags.  This patch makes the
    behaviour consistent with that of gcc, which also does not assume FP16
    for ARMv8.2.
    
    include/
    
    	* opcode/aarch64.h (AARCH64_ARCH_V8_2): Drop
    	AARCH64_FEATURE_F16.

commit 6ab2c4ed51f9c4243691755e1b1d2149c6a426f4
Author: Mingi Cho <mgcho.minic@gmail.com>
Date:   Thu Nov 2 17:01:08 2017 +0000

    Work around integer overflows when readelf is checking for corrupt ELF notes when run on a 32-bit host.
    
    	PR 22384
    	* readelf.c (print_gnu_property_note): Improve overflow checks so
    	that they will work on a 32-bit host.

commit f26ae15b471aaddee81d9d6c03af1cb0f2081735
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:42 2017 +0000

    Construct readonly regcache without address space
    
    The address space is useless to readonly regcache, so this patch removes
    the parameter to construct readonly regcache.
    
    address_space was added in regcache by 6c95b8d, but for read-write
    regcache.  regcache::aspace is used for various breakpoint/watchpoint
    checking, and these regcache are not read-only regcache.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* frame.c (do_frame_register_read): Remove aspace.
    	* jit.c (jit_frame_sniffer): Likwise.
    	* ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
    	* regcache.c (regcache::regcache): Pass nullptr.
    	(regcache_print): Caller updated.
    	* regcache.h (regcache::regcache): Remove one constructor
    	parameter aspace.

commit 6c6e9412e930c96f48b8ee78a389437328f5283c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:42 2017 +0000

    const-fy regcache::m_readonly_p
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.h (regcache) <m_readonly_p>: Change it to const bool.

commit 8b86c9592117b3ba52921af11868dc0b81ce4858
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:42 2017 +0000

    const-fy regcache::m_aspace
    
    regcache::m_aspace is a const, never changed during the lifetime of
    regcache object.  The address_space object is a const object too.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* breakpoint.c (insert_single_step_breakpoints): Update.
    	* frame.c (struct frame_info) <aspace>: Add const.
    	(frame_save_as_regcache): Add const.
    	(get_frame_address_space): Return const address_space *.
    	* frame.h (get_frame_address_space): Update declaration.
    	* infrun.c (struct step_over_info) <aspace>: Add const.
    	(set_step_over_info): Make aspace const.
    	(displaced_step_prepare_throw): Change variable const.
    	(resume): Likewise.
    	(proceed): Likewise.
    	(adjust_pc_after_break): Likewise.
    	(save_waitstatus): Likewise.
    	(handle_signal_stop): Likewise.
    	(keep_going_pass_signal): Likewise.
    	* jit.c (jit_frame_sniffer): Add const.
    	* mips-tdep.c (mips_single_step_through_delay): Likewise.
    	* ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
    	* record-full.c (record_full_wait_1): Likewise.
    	* regcache.c (regcache::regcache): Change parameter to const.
    	* regcache.h (regcache::regcache): Likewise.
    	(regcache::aspace): Return const address_space *.
    	(regcache) <m_aspace>: Add const.

commit a01bda5221f75031ea2b6d05860e46c7b9b58b55
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:41 2017 +0000

    s/get_regcache_aspace (regcache)/regcache->aspace ()/g
    
    and remove get_regcache_aspace.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
    	* frame.c (create_sentinel_frame): Likewise.
    	* infrun.c (displaced_step_prepare_throw): Likewise.
    	(resume): Likewise.
    	(thread_still_needs_step_over_bp): Likewise.
    	(proceed): Likewise.
    	(do_target_wait): Likewise.
    	(adjust_pc_after_break): Likewise.
    	(handle_syscall_event): Likewise.
    	(save_waitstatus): Likewise.
    	(handle_inferior_event_1): Likewise.
    	(handle_signal_stop): Likewise.
    	(keep_going_pass_signal): Likewise.
    	* linux-nat.c (status_callback): Likewise.
    	(save_stop_reason): Likewise.
    	(resume_stopped_resumed_lwps): Likewise.
    	* record-full.c (record_full_exec_insn): Likewise.
    	(record_full_wait_1): Likewise.
    	* regcache.c (get_regcache_aspace): Remove.
    	* regcache.h (get_regcache_aspace): Remove.

commit d999647bc427ce2e083c4449b683705449d0bb58
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:41 2017 +0000

    Remove regcache_descr::nr_raw_registers
    
    struct regcache_descr has fields nr_raw_registers and gdbarch, and
    nr_raw_registers can be got via gdbarch_num_regs (gdbarch), so it looks
    nr_raw_registers is redundant.  This patch removes it and adds a protected
    method num_raw_registers.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
    	(init_regcache_descr): Use gdbarch_num_regs.
    	(regcache::regcache): Likewise.
    	(regcache::get_register_status): Likewise.
    	(regcache::assert_raw_regnum): Likewise.
    	(regcache::cooked_read): Likewise.
    	(regcache::cooked_read_value): Likewise.
    	(regcache::cooked_write): Likewise.
    	(regcache::dump): Likewise.
    	(regcache::num_raw_registers): New method.
    	* regcache.h (class regcache) <num_raw_registers>: New.

commit 4e888c281cd19f019248bd165d7055af88641c80
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:41 2017 +0000

    New method regcache::assert_regnum
    
    class regcache has some methods checking the range of register number,
    this patch is to move it in a new method assert_regnum.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (regcache::assert_regnum): New method.
    	(regcache::invalidate): Call assert_regnum.
    	(regcache::raw_update): Likewise.
    	(regcache::raw_write): Likewise.
    	(regcache::raw_read_part): Likewise.
    	(regcache::raw_write_part): Likewise.
    	(regcache::raw_supply): Likewise.
    	(regcache::raw_supply_integer): Likewise.
    	(regcache::raw_supply_zeroed): Likewise.
    	(regcache::raw_collect): Likewise.
    	(regcache::raw_collect_integer): Likewise.
    	* regcache.h (regcache::assert_regnum): Declare.

commit 2e1b49b32ab9aec1aca94f424cbe275e5f6f9ab4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:15:41 2017 +0000

    Remove code wrapped by "#if 0"
    
    These code wrapped by "#if 0" was added by af030b9a, which added the new
    command to dump registers in 2002.  The email didn't mention this either
    https://sourceware.org/ml/gdb-patches/2002-08/msg00227.html  It was there
    for 15 years, and nobody needs it, so we can remove it.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (regcache::dump): Remove code.

commit 6c5218dfdb7b38cc1617be7753cc1ec6d0612382
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Nov 2 15:05:12 2017 +0000

    Remove regcache_descr fields sizeof_raw_register_status and sizeof_cooked_register_status
    
    struct regcache_descr has two fields sizeof_raw_register_status
    and sizeof_cooked_register_status, but they equal to nr_cooked_registers
    and nr_raw_registers respectively, so this patch removes them.
    
    gdb:
    
    2017-11-02  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
    	Remove.
    	<sizeof_cooked_register_status>: Remove.
    	(init_regcache_descr): Update.
    	(regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
    	(regcache::save): Likewise.
    	(regcache::dump): Likewise.

commit 852735806aa4343ba4bbe89656041800cf482918
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Thu Nov 2 14:16:22 2017 +0000

    [ARM] Help wince objdump on coproc tests
    
    Object files other than ELF do not have mapping symbols to indicate the
    type of data for objdump to work reliably. This is why the following
    tests FAIL on arm-wince-pe targets:
    ARMv6T2 Thumb CoProcessor Instructions (1)
    ARMv6T2 Thumb CoProcessor Instructions (2)
    
    This patch adds the force-thumb disassembler option to objdump for this
    test to PASS on these targets as well.
    
    2017-11-02  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gas/
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-1.d: Add
    	--disassembler-options=force-thumb to objdump options.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-2.d: Likewise.

commit dcc31d286ad05aa93577181f9a8292009622363e
Author: James Bowman <jamesb@excamera.com>
Date:   Wed Nov 1 18:34:25 2017 -0700

    FT32: support for FT32B processor - part 2/2
    
    FT32B is a new FT32 family member.
    This patch adds support for the compressed instructions to gdb and sim.
    
    gdb/ChangeLog:
            * ft32-tdep.c (ft32_fetch_instruction): New function.
            (ft32_analyze_prologue): Use ft32_fetch_instruction().
    
    sim/ChangeLog:
            * ft32/interp.c (step_once): Add ft32 shortcode decoder.

commit 89f3c4b6b9b565720f88636d966f22923c03e9cb
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Nov 2 00:00:15 2017 +0000

    Automatic date update in version.in

commit 29b69b1ea87d8f788a4a29022eaa2c14fe4f64d3
Merge: d55cf23 81b42bc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Nov 1 09:56:56 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 81b42bcab16f4462eb4c91db2cf09cd76e17402e
Author: James Bowman <james.bowman@ftdichip.com>
Date:   Wed Nov 1 15:33:24 2017 +0000

    FT32B is a new FT32 family member. It has a code compression scheme, which requires the use of linker relaxations. The change is quite large, so submission is in several parts.
    
    Part 2 adds a relaxation pass, which actually implements the code compression scheme.
    
    bfd	* archures.c: Add bfd_mach_ft32b.
    	* cpu-ft32.c: Add arch_info_struct.
    	* elf32-ft32.c: Add R_FT32_RELAX, SC0, SC1,
    	DIFF32. (ft32_elf_relocate_section): Add clauses
    	for R_FT32_SC0, SC1, DIFF32.  (ft32_reloc_shortable,
    	elf32_ft32_is_diff_reloc, elf32_ft32_adjust_diff_reloc_value,
    	elf32_ft32_adjust_reloc_if_spans_insn,
    	elf32_ft32_relax_delete_bytes, elf32_ft32_relax_is_branch_target,
    	ft32_elf_relax_section): New function.
    	* reloc.c: Add BFD_RELOC_FT32_RELAX, SC0, SC1, DIFF32.
    	* bfd-in2.h: Regenerate.
    	* libbfd.h: Regenerate.
    
    gas	* config/tc-ft32.c (md_assemble): add relaxation reloc
    	BFD_RELOC_FT32_RELAX.  (md_longopts): Add "norelax" and
    	"no-relax". (md_apply_fix): Add reloc BFD_RELOC_FT32_DIFF32.
    	(relaxable_section, ft32_validate_fix_sub, ft32_force_relocation,
    	ft32_allow_local_subtract): New function.
    	* config/tc-ft32.h: remove unused MD_PCREL_FROM_SECTION.
    	* testsuite/gas/ft32/insnsc.s: New test exercising all FT32B
    	shortcodes.
    
    include	* elf/ft32.h: Add R_FT32_RELAX, SC0, SC1, DIFF32.

commit a67d66eb97e7613a38ffe6622d837303b3ecd31d
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 1 15:21:46 2017 +0000

    Prevent illegal memory accesses when attempting to read excessively large COFF line number tables.
    
    	PR 22376
    	* coffcode.h (coff_slurp_line_table): Check for an excessively
    	large line number count.

commit e0115a844607b280449986e661f551dff49a9031
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 1 12:37:33 2017 +0000

    Update check for invalid values in pe_bfd_read_buildid function.
    
    	PR 22373
    	* peicode.h (pe_bfd_read_buildid): Revise check for invalid size
    	and offset in light of further possible bogus values.

commit ee357486aa87b17782111295c5e7bd4ac9e6970f
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Nov 1 11:35:42 2017 +0000

    Fix an invalid free called when attempting to link a COFF object against an ELF archive with --no-keep-memory enabled.
    
    	PR 22369
    	* coffgen.c (_bfd_coff_free_symbols): Fail if called on a non-COFF
    	file.
    	* cofflink.c (coff_link_check_archive_element): Skip non-COFF
    	members of an archive.

commit 4070243b5c1f66a36dd43a7b722e991ac9fc40e1
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Wed Nov 1 09:49:13 2017 +0000

    [ARM] Fix Coprocessor instructions availability
    
    A few coprocessor instructions introduced in ARMv2 are currently
    accepted by GAS when targeting ARMv1 due to a typo in the code. This
    patch fixes the issue and introduce a more fine grained testing for
    coprocessor instructions availability. Coprocessor instructions are
    grouped as follows:
    
    * ARM coprocessor instructions introduced in ARMv2
      Includes: ldc, stc, mcr, mrc, cdp, ldcl, stcl
      Guarded by: ARM_EXT_V2
      Tests: copro-arm_v2plus-arm_v*.d
    
    * ARM coprocessor instructions introduced in ARMv5
      Includes: ldc2, ldc2l, stc2, stc2l, cdp2, mcr2, mrc2
      Guarded by: ARM_EXT_V5
      Tests: copro-arm_v5plus-arm_v*.d
    
    * ARM coprocessor instructions introduced in ARMv5TE
      Includes: mcrr, mrrc
      Guarded by: ARM_EXT_V5E
      Tests: copro-arm_v5teplus-arm_v*.d
    
    * ARM coprocessor instructions introduced in ARMv6
      Includes: mcrr2, mrrc2
      Guarded by: ARM_EXT_V6
      Tests: copro-arm_v6plus-arm_v*.d
    
    * Thumb coprocessor instructions introduced in ARMv6T2
      Includes: ldc, ldcl, stc, stcl, mcr, mrc, mcrr, mrrc, cdp, ldc2,
      ldc2l, stc2, stc2l, cdp2, mcr2, mrc2, mcrr2, mrrc2
      Guarded by: ARM_EXT_V6T2
      Tests: copro-thumb_v6t2plus-thumb_v*.d
    
    For each of these groups, at least 2 tests are performed:
    * instructions are not available in earlier architecture
    * instructions are available in architecture where they were introduced
    More tests need to be performed when instructions in a group span
    several assembly files.
    
    Note that an instruction in the original coprocessor testcase is
    changed to unified syntax to allow the testcase to be assembled for ARM
    and Thumb state. Correct processing of legacy syntax is covered in other
    testcases.
    
    2017-11-01  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gas/
    	* config/tc-arm.c (arm_ext_v2): Define to ARM_EXT_V2 feature bit.
    	* testsuite/gas/arm/copro.s: Split into ...
    	* testsuite/gas/arm/copro-arm_v2plus-thumb_v6t2plus.s: This while
    	changing it to unified syntax and ...
    	* testsuite/gas/arm/copro-arm_v5plus-thumb_v6t2plus.s: this and ...
    	* testsuite/gas/arm/copro-arm_v5teplus-thumb_v6t2plus.s: This and ...
    	* testsuite/gas/arm/copro-arm_v6plus-thumb_v6t2plus.s: This.
    	* testsuite/gas/arm/copro.d: Split into ...
    	* testsuite/gas/arm/copro-arm_v2plus-arm_v2.d: This but target ARMv2
    	and ...
    	* testsuite/gas/arm/copro-arm_v5plus-arm_v5.d: this but target ARMv5
    	and ...
    	* testsuite/gas/arm/copro-arm_v5teplus-arm_v5te.d: This but target
    	ARMv5TE and ...
    	* testsuite/gas/arm/copro-arm_v6plus-arm_v6.d: This but target ARMv6.
    	* testsuite/gas/arm/copro-arm_v2plus-arm_v1.d: New testcase.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v4t-1.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v2plus-thumb_v6t2plus-unavail.l: Expected
    	errors for the above two testcases.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-1.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v5plus-arm_v4.d: New testcase.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v4t-2.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v5plus-thumb_v6t2plus-unavail.l:
    	Expected errors for the above two testcases.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-2.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v5teplus-arm_v5.d: New testcase.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v4t-3.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v5teplus-thumb_v6t2plus-unavail.l:
    	Expected errors for the above two testcases.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-3.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v6plus-arm_v5te.d: New testcase.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v4t-4.d: New testcase.
    	* testsuite/gas/arm/copro-arm_v6plus-thumb_v6t2plus-unavail.l:
    	Expected errors for the above two testcases.
    	* testsuite/gas/arm/copro-thumb_v6t2plus-thumb_v6t2-4.d: New testcase.

commit 3988aed54acce3c682a877b51b0e09cce1079e81
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 31 22:13:21 2017 +1030

    PR22374, PowerPC unnecessary PLT entries
    
    We don't need a PLT entry when function pointer initialization in a
    read/write section is the only reference to a given function symbol.
    This patch prevents the unnecessary PLT entry, and ensures no dynamic
    relocs are emitted when UNDEFWEAK_NO_DYNAMIC_RELOC says so.
    
    bfd/
    	PR 22374
    	* elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't create a plt
    	entry when just a dynamic reloc can serve.  Ensure no dynamic
    	relocations when UNDEFWEAK_NO_DYNAMIC_RELOC by setting non_got_ref.
    	Expand and move the non_got_ref comment.
    	* elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Likewise.
    ld/
    	* testsuite/ld-powerpc/ambiguousv2.d: Remove FIXME.

commit e48f0c8f1b9fdb195394dc7afea02ce55e4ba5e4
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 31 11:13:30 2017 +1030

    PR22374 testcase, function pointer references in .data
    
    Function pointer references in .data ought to use a dynamic reloc.
    There shouldn't be any need for a PLT entry and definitely no copy
    reloc.
    
    This test fails on quite a few targets, but isn't something that
    anyone should worry about too much.  It's really just a missed
    optimization.
    
    	PR 22374
    	* testsuite/ld-elf/pr22374a.s,
    	* testsuite/ld-elf/pr22374b.s,
    	* testsuite/ld-elf/pr22374-1.r,
    	* testsuite/ld-elf/pr22374-2.r: New test.
    	* testsuite/ld-elf/elf.exp: Run it.

commit 46b06a98d112ee433a8f81c700a8852c92ca8132
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 31 18:19:21 2017 +1030

    Tidy elf.exp
    
    	* testsuite/ld-elf/elf.exp: Merge some conditionals, a better
    	name than "shared library for next test", and use xfail arg
    	of run_ld_link_tests in a few places.

commit 3a87ae656c283e4f46ddf7d92c06ecb8992c2bf6
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Tue Oct 31 21:30:24 2017 -0400

    Use console uiout when executing breakpoint commands
    
    As reported here
    
      https://sourceware.org/ml/gdb/2017-10/msg00020.html
    
    the output of certain commands, like backtrace, doesn't appear anywhere
    when it is run as a breakpoint command and when using MI.
    
    The reason is that the current_uiout is set to the mi_ui_out while these
    commands run, whereas we want the output as CLI output.  Some commands
    like "print" work, because they use printf_filtered (gdb_stdout, ...)
    directly, bypassing the current ui_out.
    
    The fix I did is to force setting the cli_uiout as the current_uiout
    when calling execute_control_command.  I am not sure if this is the
    right way to fix the problem, comments about the approach would be
    appreciated.
    
    I enhanced gdb.mi/mi-break.exp to test the backtrace command.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* cli/cli-script.c (execute_control_command): Rename to ...
    	(execute_control_command_1): ... this.
    	(execute_control_command): New function.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.mi/mi-break.exp (test_breakpoint_commands): Test backtrace
    	as a breakpoint command.

commit 4d01dee4804d39c1671bc220caf32a327e7e4b10
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Nov 1 00:00:19 2017 +0000

    Automatic date update in version.in

commit 09b847f3a85ca29ec20ada375fe67843755b6413
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Oct 31 14:29:25 2017 -0400

    tracepoint: Remove unnecessary const_cast
    
    We are passing a const char * to a const char * parameter, the
    const_cast is not necessary.
    
    gdb/ChangeLog:
    
    	* tracepoint.c (tfind_command): Remove const_cast.

commit 0bb6961f18b8e832d88b490d421ca56cea16c45b
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Oct 31 14:29:40 2017 +0000

    Fix illegal memory access triggered when parsing a PE binary with a corrupt data dictionary.
    
    	PR 22373
    	* peicode.h (pe_bfd_read_buildid): Check for invalid size and data
    	offset values.

commit 45ac8f4f107f50d77a8514ee8a244b82c1a8ea0c
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Oct 31 13:48:03 2017 +0000

    Remind users to use the --use-dynamic command line option to dump dynamic relocations.
    
    	* readelf.c (process_relocs): Tell users if no static relocs were
    	found, but if they had added --use-dynamic to the command line
    	then relocs would have been displayed.

commit f871c4853a9725682011c2314ea4308f3c34bd8d
Author: Mike Gulick <mike.gulick@mathworks.com>
Date:   Mon Oct 30 20:11:52 2017 -0400

    gdb/Makefile.in: fix 'make tags' failure
    
    'make tags' fails with the following error:
    
      make[2]: Entering directory '/local-ssd/mgulick/gdb/git/binutils-gdb/gdb'
      make[2]: *** No rule to make target 'gdb.h', needed by 'TAGS'.  Stop.
      make[2]: Leaving directory '/local-ssd/mgulick/gdb/git/binutils-gdb/gdb'
    
    The file gdb/gdb.h was removed in commit
    65630365f7d073430e62b4fe65f34dcdc0a4b05e.
    
    gdb/ChangeLog:
    
    2017-10-30  Mike Gulick  <mgulick@mathworks.com>
    
    	* Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.

commit 916296ccea146c9b9517e00494bde307f2af7efa
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Oct 31 00:00:40 2017 +0000

    Automatic date update in version.in

commit b020ff8074af22639e3f3c0f700f45d067521249
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Oct 30 14:27:30 2017 -0400

    Introduce in_inclusive_range, fix -Wtautological-compare warnings
    
    When compiling with clang or gcc 8, we see warnings like this:
    
    /home/emaisin/src/binutils-gdb/gdb/arm-tdep.c:10013:13: error: comparison of 0 <= unsigned expression is always true [-Werror,-Wtautological-compare]
          if (0 <= insn_op1 && 3 >= insn_op1)
              ~ ^  ~~~~~~~~
    /home/emaisin/src/binutils-gdb/gdb/arm-tdep.c:11722:20: error: comparison of unsigned expression >= 0 is always true [-Werror,-Wtautological-compare]
          else if (opB >= 0 && opB <= 2)
                   ~~~ ^  ~
    
    This is because an unsigned integer (opB in this case) will always be >=
    0.  It is still useful to keep both bounds of the range in the
    expression, even if one is at the edge of the data type range.  This
    patch introduces a utility function in_inclusive_range that gets rid of
    the warning while conveying that we are checking for a range.
    
    Tested by rebuilding.
    
    gdb/ChangeLog:
    
    	* common/common-utils.h (in_inclusive_range): New function.
    	* arm-tdep.c (arm_record_extension_space): Use
    	in_inclusive_range.
    	(thumb_record_ld_st_reg_offset): Use in_inclusive_range.
    	* cris-tdep.c (cris_spec_reg_applicable): Use
    	in_inclusive_range.

commit 1b81856f5b00e7ba860e4de2f3a426f342327165
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 30 11:41:34 2017 +0000

    remote.c, QCatchSyscalls: Build std::string instead of unique_xmalloc_ptr
    
    Simplify the code a little bit using std::string + string_appendf.
    
    gdb/ChangeLog:
    2017-10-30  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi <simon.marchi@ericsson.com>
    
    	* remote.c (remote_set_syscall_catchpoint): Build a std::string
    	instead of a gdb::unique_xmalloc_ptr, using string_appendf.

commit 31b833b3eab69d91df67edc3e9a21792abc3f93e
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 30 11:41:34 2017 +0000

    Introduce string_appendf/string_vappendf
    
    string_appendf is like string_printf, but instead of allocating a new
    string, it appends to an existing string.  This allows reusing a
    std::string's memory buffer across several calls, for example.
    
    gdb/ChangeLog:
    2017-10-30  Pedro Alves  <palves@redhat.com>
    
    	* common/common-utils.c (string_appendf, string_vappendf): New
    	functions.
    	* common/common-utils.h (string_appendf, string_vappendf): New
    	declarations.
    	* unittests/common-utils-selftests.c (string_appendf_func)
    	(test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
    	(string_vappendf_tests): New functions.
    	(_initialize_common_utils_selftests): Register "string_appendf" and
    	"string_vappendf tests".

commit 4a25033455f1e4e0325fdd249e30a79efc856689
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 30 11:41:34 2017 +0000

    Merge/shared string_printf and string_vprintf unit tests
    
    Merge the string_printf and string_vprintf tests, running them all
    against both functions.
    
    gdb/ChangeLog:
    2017-10-30  Pedro Alves  <palves@redhat.com>
    
    	* unittests/common-utils-selftests.c (format_func): New typedef.
    	(string_printf_tests, string_vprintf_tests): Tests factored out
    	and merged to ...
    	(test_format_func): ... this new function.
    	(string_printf_tests, string_vprintf_tests): Reimplement on top of
    	test_format_func.

commit 16c5c17e43b34c6cc5337b40e927bc2d05c38300
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Oct 29 22:37:11 2017 -0400

    darwin-nat: Remove gdb.h include
    
    gdb.h has been removed in
    
      Eliminate catch_exceptions/catch_exceptions_with_msg
      65630365f7d073430e62b4fe65f34dcdc0a4b05e
    
    Remove the include in darwin-nat.c.  Tested by rebuilding.
    
    gdb/ChangeLog:
    
    	* darwin-nat.c: Remove include of gdb.h.

commit 7f9cb5d275e71a75e97230241ec7da6718a7a0f5
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Oct 30 12:02:42 2017 +1030

    frv-elf --gc-sections failures
    
    git commit 81742b83e9 exposed an frv-elf bug, with the object id not
    matching the hash table id.
    
    	* elf32-frv.c (ELF_TARGET_ID): Don't define for generic
    	elf target.

commit 81742b83e9f25895eaaf3a07ac1651a4e9a68251
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Oct 30 10:20:29 2017 +1030

    relocs_compatible test for gc-sections
    
    I noticed when looking at pr22300 that before calling check_relocs we
    have an elf_object_id test (added for pr11933) as well as the
    relocs_compatible test.  I believe backend gc_mark_hook and
    gc_sweep_hook ought to be protected similarly from being confused by
    unexpected relocations (for example, both elf64-ppc.c and elf32-ppc.c
    use _bfd_elf_relocs_compatible, so I think it would be possible for
    the ppc64 gc_mark_hook to be presented with a ppc32 relocatable
    object).
    
    	* elflink.c (elf_gc_sweep): Test elf_object_id in addition to
    	relocs_compatible.
    	(bfd_elf_gc_sections): Likewise.

commit d336fa6d820f50235c271ea327fadbf4ff6e1edd
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Oct 27 15:04:25 2017 +1030

    Fix hppa-linux pr22269-1 fail
    
    Adds UNDEFWEAK_NO_DYNAMIC_RELOC in the rest of places needed in this
    file, reduces dynamic relocations in a number of cases, and removes
    some bogus code that was attempting to handle dynamic common symbols
    specially.
    
    	PR 22269
    	* elf32-hppa.c (elf32_hppa_check_relocs): Move SEC_ALLOC test to
    	ensure non_got_ref is not set due to debug references.
    	(elf32_hppa_adjust_dynamic_symbol): Tidy plabel handling.  Use
    	SYMBOL_CALLS_LOCAL and UNDEFWEAK_NO_DYNAMIC_RELOC when determining
    	need for a plt entry.
    	(allocate_dynrelocs): Similarly for got entries.  Tidy code discarding
    	dynamic relocs when pic.  Remove bogus code attempting to handle
    	commons.
    	(elf32_hppa_relocate_section): Similarly.  Delete resolved_to_zero
    	and simplify.
    	(elf32_hppa_finish_dynamic_symbol): Use UNDEFWEAK_NO_DYNAMIC_RELOC
    	and SYMBOL_REFERENCES_LOCAL in GOT handling.

commit 2b2d16760741356447ae10acc93695678db5e5ee
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Oct 30 00:00:32 2017 +0000

    Automatic date update in version.in

commit 7ca51576b94fb59a41050957d5ee822d21711abc
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Oct 29 13:01:19 2017 -0400

    xtensa-xtregs: Fix formatting issues
    
    Fix a few formatting issues in that file.
    
    gdb/ChangeLog:
    
    	* xtensa-xtregs.c: Fix formatting issues.

commit c1342859dc02fd57e013ef544037a9ead4f23f60
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Oct 29 01:13:33 2017 -0400

    xtensa-xtregs: Constify field
    
    Fix:
    
    In file included from /home/emaisin/src/binutils-gdb/gdb/xtensa-linux-nat.c:46:0:
    /home/emaisin/src/binutils-gdb/gdb/xtensa-xtregs.c:37:1: error: ISO C++ forbids converting a string constant to 'char*' [-Werror=write-strings]
     };
     ^
    
    gdb/ChangeLog:
    
    	* xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.

commit 692af2271947dee1918585c2fad36618a5d47d21
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Oct 29 00:00:25 2017 +0000

    Automatic date update in version.in

commit 484d8d361de65a8489252d14511b77c142d859a1
Author: Maksim Dzabraev <dzabraew@gmail.com>
Date:   Sun Oct 29 01:14:34 2017 +0700

    Make gdb.selected_thread().inferior return a new reference
    
    thpy_get_inferior function should return a new reference to the
    existing inferior object, and therefore should increment its refcount.
    
    Fixed bug looks like this.
    If multiple time call gdb.selected_thread ().inferior, gdb throws exception:
    
    (gdb) pi gdb.selected_thread().inferior
    <gdb.Inferior object at 0x7f1952bea698>
    (gdb) pi gdb.selected_thread().inferior
    Python Exception <type 'exceptions.AttributeError'> 'NoneType' object
    has no attribute 'inferior':
    Error while executing Python code.
    (gdb) info threads
      Id   Target Id         Frame
    * 1    Thread 0x7f54f0474740 (LWP 584) "mc" 0x00007f54ef055c33 in

commit d91f0b20e561e326ee91a09a76206257bde8438b
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Oct 28 21:31:16 2017 +1030

    PR22361 readelf buffer overflow on fuzzed archive header
    
    	PR 22361
    	* readelf.c (process_archive_index_and_symbols): Ensure ar_size
    	field is zero terminated for strtoul.
    	(setup_archive, get_archive_member_name): Likewise.

commit c0e331c794d6bd75d9be9bea6145513074c33f39
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Oct 28 14:10:55 2017 +1030

    PR22300, Abort in elf32_hppa_relocate_section building polyml
    
    polyml produces object files with the wrong OS/ABI for hppa-linux.
    This, along with the fact that elf32-hppa.c is using the strictest
    backend relocs_compatible, results in wrong merging of ELF symbols.
    
    So, remove the relocs_compatible check in _bfd_elf_merge_symbol.
    _bfd_elf_merge_symbol is only called nowadays from within blocks
    protected by is_elf_hash_table, so "we are doing an ELF link" as the
    removed comment says, is true.
    
    Also relax relocs_compatible for hppa and powerpc.  relocs_compatible
    is used for more than just merging symbols, as the name suggests.
    This allows objects that are in fact reasonably compatible to be
    linked.
    
    	PR 22300
    	* elflink.c (_bfd_elf_merge_symbol): Remove relocs_compatible check.
    	* elf32-hppa.c (elf_backend_relocs_compatible): Define.
    	* elf32-ppc.c (elf_backend_relocs_compatible): Define.
    	* elf64-ppc.c (elf_backend_relocs_compatible): Define.

commit bac608e7e11fa83a648c0980883f810ebd1874b1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 23:44:12 2017 -0400

    Remove find_inferior usage for thread_search
    
    Replace it with for_each_thread.  While at it, we can inline the
    callback code.  One little change is that I am using the
    prev_general_thread variable instead of current_gen_ptid, since they
    should have the same value.
    
    gdb/gdbserver/ChangeLog:
    
    	* target.c (struct thread_search): Remove.
    	(thread_search_callback): Remove.
    	(prepare_to_access_memory): Use for_each_thread instead of
    	find_inferior.  Inline code from thread_search_callback.

commit eaddb425928bb4ae21c0c6644b4bedf3d16cb6fa
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 23:43:11 2017 -0400

    Remove usage of find_inferior in resume
    
    Change find_inferior with find_thread.  Since we can now pass arguments
    directly instead of through a void pointer, we don't need the
    visit_actioned_threads_data structure anymore.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (struct visit_actioned_threads_data): Remove.
    	(visit_actioned_threads): Change prototype to take arguments
    	directly.
    	(resume): Use find_thread instead of find_inferior.

commit 99078d344db25efc376877e0e4c95157f0c36c60
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 23:41:49 2017 -0400

    Remove usages of find_inferior in handle_status
    
    Replace one with find_thread, the other with for_each_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (queue_stop_reply_callback): Change prototype, return
    	void.
    	(find_status_pending_thread_callback): Remove.
    	(handle_status): Replace find_inferior with find_thread and
    	for_each_thread.

commit b5540b5f2b9cd5fcbac6504359b856d3f43267b5
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 23:36:19 2017 -0400

    common-utils-selftests.c: Add ATTRIBUTE_PRINTF
    
    Fix this, when building with clang:
    
    /home/emaisin/src/binutils-gdb/gdb/unittests/common-utils-selftests.c:50:40: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
      std::string result = string_vprintf (fmt, vp);
                                           ^~~
    gdb/ChangeLog:
    
    	* unittests/common-utils-selftests.c (format): Add
    	ATTRIBUTE_PRINTF.

commit 5a9dcda14c240eccee5c1de53cf4ae936230ed0c
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Oct 27 22:23:33 2017 -0400

    C++ify xml-syscall.c
    
    This patch C++ifies the structures in xml-syscall.c, by using
    std::vector instead of VEC, and std::string instead of char*.
    Using a unique_ptr in syscall_parse_xml allows to remove a cleanup.
    
    Something that seems strange with the existing code, if you look at
    syscalls_info_free_syscalls_desc and
    syscalls_info_free_syscall_group_desc, they free the structure elements
    (the strings and vectors), but they don't free the syscall_desc and
    syscall_group_desc structure themselves.  I don't see anything freeing
    those currently.  Any idea why?  According to the comment above
    syscalls_info_free_syscall_group_desc, it kinda looks like it's on
    purpose.  With this patch, those structures are deleted when the vector
    that contains them gets deleted.
    
    The only time I'm aware a syscalls_info structure gets deleted is in the
    case the data directory changes during runtime, in init_syscalls_info.
    If tried that use case (including under valgrind):
    
     (gdb) catch syscall
     (gdb) set data-directory another-data-directory
     (gdb) catch syscall
    
    I confirmed that the syscalls_info structure got deleted and recreated,
    and everything seemed fine.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* xml-syscall.c (struct syscall_desc): Add constructor.
    	<name>: Change type to std::string.
    	(syscall_desc_up): New typedef.
    	(syscall_desc_p): Remove typeder.
    	(DEF_VEC_P(syscall_desc_p)): Remove.
    	(struct syscall_group_desc): Add constructor.
    	<name>: Change type to std::string.
    	<syscalls>: Change type to std::vector.
    	(syscall_group_desc_up): New typedef.
    	(syscall_group_desc_p): Remove typedef.
    	(DEF_VEC_P(syscall_group_desc_p)): Remove.
    	(struct syscalls_info) <syscalls>: Change type to std::vector of
    	unique_ptr.
    	<groups>: Likewise.
    	<my_gdb_datadir>: Change type to std::string.
    	(syscalls_info_up): New typedef.
    	(allocate_syscalls_info): Remove.
    	(syscalls_info_free_syscalls_desc): Remove.
    	(syscalls_info_free_syscall_group_desc): Remove.
    	(free_syscalls_info): Remove.
    	(make_cleanup_free_syscalls_info): Remove.
    	(syscall_group_create_syscall_group_desc): Adjust.
    	(syscall_group_add_syscall): Adjust.
    	(syscall_create_syscall_desc): Adjust.
    	(syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
    	(init_syscalls_info): Adjust.
    	(syscall_group_get_group_by_name): Adjust.
    	(xml_get_syscall_number): Adjust.
    	(xml_get_syscall_name): Adjust.
    	(xml_list_of_syscalls): Adjust.
    	(xml_list_syscalls_by_group): Adjust.
    	(xml_list_of_groups): Adjust.

commit 45461e0dcaf4193b5b4478031f515ffb7911ad85
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 22:05:42 2017 -0400

    Get rid of VEC(probe_p)
    
    Replace the remaining usages of VEC(probe_p) with std::vector.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* probe.h: Don't include gdb_vecs.h.
    	(DEF_VEC_P (probe_p)): Remove.
    	(find_probes_in_objfile): Return an std::vector.
    	* probe.c (find_probes_in_objfile): Likewise.
    	* breakpoint.c (breakpoint_objfile_data)
    	<longjmp_probes>: Change type to std::vector.
    	<exception_probes>: Likewise.
    	(free_breakpoint_probes): Don't manually free vectors.
    	(create_longjmp_master_breakpoint): Adjust.
    	(create_exception_master_breakpoint): Adjust.
    	* solib-svr4.c (svr4_create_probe_breakpoints): Change
    	parameter type, adjust.
    	(svr4_create_solib_event_breakpoints): Adjust.

commit 43dce4394513d15ba8122c3bf442ec1028d93feb
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 22:01:21 2017 -0400

    Allocate breakpoint_objfile_data with new
    
    Allocate with new and free with delete.  This allows using an
    std::vector in the following patch.
    
    I renamed free_breakpoint_probes to free_breakpoint_objfile_data,
    because it now doesn't only free the probes vector, but also the
    breakpoint_objfile_data structure itself.
    
    gdb/ChangeLog:
    
    	* breakpoint.c (breakpoint_objfile_data): Initialize fields.
    	(get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
    	with new.
    	(free_breakpoint_probes): Rename to ...
    	(free_breakpoint_objfile_data): ... this, and call delete on
    	bp_objfile_data..

commit 6a1b9516d824a4d364040887455ba910f955f065
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Fri Oct 27 21:55:42 2017 -0400

    Get rid of VEC(loaded_script_ptr)
    
    Direct replacement with std::vector.  This allows removing a cleanup as
    well.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* auto-load.c: Don't include gdb_vecs.h, include algorithm.
    	(loaded_script_ptr): Remove typedef.
    	(DEF_VEC_P (loaded_script_ptr)): Remove.
    	(struct collect_matching_scripts_data): Add constructor.
    	<scripts_p>: Change type to (pointer to) std::vector.
    	(collect_matching_scripts_data): Adjust.
    	(sort_scripts_by_name): Make suitable for std::sort.
    	(print_scripts): Don't sort vector, adjust to std::vector.
    	(auto_load_info_scripts): Sort vectors, adjust to std::vector.

commit 593e3209f3e4e525030bc8768850f3876fd0b850
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 21:47:30 2017 -0400

    Get rid of VEC(filename_language)
    
    This patch removes VEC(filename_language), replacing its usage with
    std::vector.  filename_language::ext is changed to an std::string at the
    same time.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* symfile.c (filename_language): Make struct, not typedef.  Add
    	constructor.
    	<ext>: Change type to std::string.
    	(DEF_VEC_O (filename_language)): Remove.
    	(filename_language_table): Change type to std::vector.
    	(add_filename_language): Adjust.
    	(set_ext_lang_command): Adjust.
    	(info_ext_lang_command): Adjust.
    	(deduce_language_from_filename): Adjust.
    	(class scoped_restore_filename_language_table): Remove.
    	(test_filename_language): Use scoped_restore.
    	(test_set_ext_lang_command): Use scoped_restore, adjust to
    	std::vector change.

commit 32fa66eb88d029576cfd8f5698d0579662d2f045
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 21:46:49 2017 -0400

    Add tests for filename_language
    
    The next patch touches the filename_language area, but I noticed there
    is no test exercising that.  This patch adds some selftests for
    add_filename_language, deduce_language_from_filename and
    set_ext_lang_command.  Because these tests add entries to the global
    filename_language_table vector, it is not possible to run them
    successfully multiple times in a same GDB instance.  They can
    potentially interfere with each other for the same reason.  I therefore
    added the scoped_restore_filename_language_table class that is used to
    make sure tests leave that global vector in the same state they found it
    (it is replaced in the following patch by a simple scoped_restore).
    
    gdb/ChangeLog:
    
    	* symfile.c: Include selftest.h.
    	(class scoped_restore_filename_language_table): New.
    	(test_filename_language): New test.
    	(test_set_ext_lang_command): New test.
    	(_initialize_symfile): Register tests.

commit af5f32f82b0ece140641484d8178ead655f8a0a5
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Oct 28 00:00:30 2017 +0000

    Automatic date update in version.in

commit 4a27f119f59a44395e0a34b1526cee709e1d3fce
Author: Keith Seitz <keiths@redhat.com>
Date:   Fri Oct 27 10:57:23 2017 -0700

    Use SaL symbol name when reporting breakpoint locations
    
    Currently, "info break" can show some (perhaps) unexpected results when
    setting a breakpoint on an inlined function:
    
    (gdb) list
    1	#include <stdio.h>
    2
    3	static inline void foo()
    4	{
    5	        printf("Hello world\n");
    6	}
    7
    8	int main()
    9	{
    10	        foo();
    11	        return 0;
    12	}
    13
    (gdb) b foo
    Breakpoint 1 at 0x400434: file foo.c, line 5.
    (gdb) i b
    Num     Type           Disp Enb Address            What
    1       breakpoint     keep y   0x0000000000400434 in main at foo.c:5
    
    GDB reported that we understood what "foo" was, but we then report that the
    breakpoint is actually set in main. While that is literally true, we can
    do a little better.
    
    This is accomplished by copying the symbol for which the breakpoint was set
    into the bp_location.  From there, print_breakpoint_location can use this
    information to print out symbol information (if available) instead of calling
    find_pc_sect_function.
    
    With the patch installed,
    
    (gdb) i b
    Num     Type           Disp Enb Address            What
    1       breakpoint     keep y   0x0000000000400434 in foo at foo.c:5
    
    gdb/ChangeLog:
    
    	* breakpoint.c (print_breakpoint_location): Use the symbol saved
    	in the bp_location, falling back to find_pc_sect_function when
    	needed.
    	(add_location_to_breakpoint): Save sal->symbol.
    	* breakpoint.h (struct bp_location) <symbol>: New field.
    	* symtab.c (find_function_start_sal): Save the symbol into the SaL.
    	* symtab.h (struct symtab_and_line) <symbol>: New field.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.opt/inline-break.exp (break_info_1): New procedure.
    	Test "info break" for every inlined function breakpoint.

commit bb11dd58391459bd5ba54ec405adab663ac59e89
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 27 15:29:24 2017 +0100

    [AArch64] Mark LR clobbered by BL in inline asm
    
    LR is a caller-save register, so, if inline asm does BL (which touches
    LR), we should mark LR clobbered.
    
    gdb/testsuite:
    
    2017-10-27  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.arch/insn-reloc.c (can_relocate_bl): Mark "x30" clobbered.

commit 32ef30002cee3661eb645cd14bcc4ff77ea10f45
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 09:01:36 2017 -0400

    dwarf: Read register number as unsigned in DW_CFA_def_cfa*
    
    When displaying the .debug_frame section, the register numbers in the
    DW_CFA_def_cfa* statements are read as signed numbers.  I have come
    across a target that has register 121, encoded as 0x79 in unsigned LEB128.
    Interpreting this as signed results in -7, which makes readelf display
    "r-7".
    
    The DWARF5 standard (6.4.2.2) states that the register numbers should be
    treated as unsigned LEB128.
    
    Simply replacing READ_SLEB with READ_ULEB resulted in warnings like
    these:
    
    /home/emaisin/src/binutils-gdb/binutils/dwarf.c: In function ââ?¬Ë?display_debug_framesââ?¬â?¢:
    /home/emaisin/src/binutils-gdb/binutils/dwarf.c:355:17: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
           if ((var) != _val)     \
                     ^
    /home/emaisin/src/binutils-gdb/binutils/dwarf.c:7866:8: note: in expansion of macro ââ?¬Ë?READ_ULEBââ?¬â?¢
            READ_ULEB (fc->cfa_reg);
            ^
    ... so I also changed Frame_Chunk::cfa_reg to an unsigned int.
    
    binutils/ChangeLog:
    
    	* dwarf.c (struct Frame_Chunk) <cfa_reg>: Change type to
    	unsigned int.
    	(display_debug_frames): Read CFA reg as an unsigned number.

commit 7453e6b2ea451dfba68cf4442e58706d51f88411
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 27 08:57:10 2017 -0400

    Add PR mention to previous commit

commit a43f3893f6cb66dfca7f628cd159a008009ad06f
Author: Patrick Frants <osscontribute@gmail.com>
Date:   Thu Oct 26 22:26:08 2017 -0400

    Fix broken recursion detection when printing static members
    
    Recursion detection for static members was broken.  The implementation
    uses a growing (and shrinking) obstack object to simulate a stack of
    addresses (CORE_ADDR).  Pushing addresses is implemented by calling
    obstack_grow(), while popping is implemented by calling obstack_free().
    The latter is problematic because obstack_free() expects a pointer to
    the base of an object.  When popping elements of the stack however,
    obstack_free() was called with the new top, which potentially is not the
    same as the base of the stack.  This is unintended use and the effect is
    that obstack->next_free and obstack->object_base members are assigned
    the value of the new top, which equals an empty stack.  Summary: popping
    elements would always result in an empty stack, which breaks the
    recursion detection.
    
    The fix shrinks the stack using obstack_blank_fast() with a negative
    value as described at the bottom of this page:
    https://gcc.gnu.org/onlinedocs/libiberty/Extra-Fast-Growing.html "You
    can use obstack_blank_fast with a â??negativeâ?? size argument to make the
    current object smaller.  Just donâ??t try to shrink it beyond zero
    lengthâ??thereâ??s no telling what will happen if you do that. Earlier
    versions of obstacks allowed you to use obstack_blank to shrink objects.
    This will no longer work."
    
    The reproducer is added to gdb.cp/classes.exp, which fails without this
    patch.
    
    gdb/ChangeLog:
    
    	* cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
    	to rewind obstack.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.cp/classes.exp (test_static_members): Test printing
    	Outer::instance.
    	* gdb.cp/classes.c (struct Inner, struct Outer): New.
    	(Inner::instance, Outer::instance): New.

commit 95904ac43c21694a609b4b8016b7fdfe8c2fc0fb
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Oct 27 00:00:28 2017 +0000

    Automatic date update in version.in

commit 23cc4e1b28d445e23827a09c454aa806f2b8c720
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 26 19:53:03 2017 +0100

    Garbage collect remote.c:remote_async_terminal_ours_p
    
    remote.c:remote_async_terminal_ours_p stopped being useful after
    048094accce2 ("target remote: Don't rely on immediate_quit (introduce
    quit handlers)") and commit 41fd2b0f5d95 ("Make input_fd be per UI"),
    which turned remote's terminal_inferior/ours methods into nops.
    
    gdb/ChangeLog:
    2017-10-26  Pedro Alves  <palves@redhat.com>
    
    	* remote.c (remote_async_terminal_ours_p): Delete.
    	(remote_open_1, remote_terminal_inferior, remote_terminal_ours):
    	Remove references to 'remote_async_terminal_ours_p'.

commit 514f60231cb5a0a070712729a7c29447cae86453
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 26 11:16:41 2017 -0700

    x86: Check invalid XMM register in AVX512 gathers
    
    Extend invalid register check for AVX512 gathers to XMM register.
    
    	PR gas/22352
    	* config/tc-i386.c (check_VecOperands): Also check XMM register
    	for invalid register in AVX512 gathers.
    	* testsuite/gas/i386/vgather-check.s: Add tests for AVX512
    	gathers with XMM register.
    	* testsuite/gas/i386/x86-64-vgather-check.s: Likewise.
    	* testsuite/gas/i386/vgather-check-error.l: Updated.
    	* testsuite/gas/i386/vgather-check-none.d: Likewise.
    	* testsuite/gas/i386/vgather-check-warn.d: Likewise.
    	* testsuite/gas/i386/vgather-check-warn.e: Likewise.
    	* testsuite/gas/i386/vgather-check.d: Likewise.
    	* testsuite/gas/i386/x86-64-vgather-check-error.l: Likewise.
    	* testsuite/gas/i386/x86-64-vgather-check-none.d: Likewise.
    	* testsuite/gas/i386/x86-64-vgather-check-warn.d: Likewise.
    	* testsuite/gas/i386/x86-64-vgather-check-warn.e: Likewise.
    	* testsuite/gas/i386/x86-64-vgather-check.d: Likewise.

commit 506981afaf6c77fbc26bcdc2eb4c24edca4255ef
Author: Renlin Li <renlin.li@arm.com>
Date:   Thu Oct 26 15:40:45 2017 +0100

    [PR21703]Adjust pr21703 tests on various targets.
    
    xfail tests for certain targets.
    Check shared library support for shared test.
    Relax pr21703-r.sd and pr21703-shared.sd with additional "#..." pattern lines.
    
    ld/
    
    	* testsuite/ld-elf/elf.exp: xfail pr21703 tests on specific targets.
    	Only run shared lib test for targets which support it.
    	* testsuite/ld-elf/pr21703-r.sd: Adjust the expected output.
    	* testsuite/ld-elf/pr21703-shared.sd: Likewise.

commit 4062f504eba4835579bcc360e9eff3e7d92f5a6c
Author: James Greenhalgh <james.greenhalgh@arm.com>
Date:   Thu Oct 26 11:30:40 2017 +0100

    As Alan predicted at https://sourceware.org/ml/binutils/2017-10/msg00137.html the values in some Arm tests need updating after recent changes. These looked a bit spooky at first, but they are just a difference in the order we emit veneers and far jumps, so are not so scary after all.
    
    Checked with an arm-none-eabi tester and an arm-none-linux-gnueabi tester with no issues.
    
    	* testsuite/ld-arm/cortex-a8-far.d: Update expected disassembly.
    	* testsuite/ld-arm/farcall-group-size2: Likewise.
    	* testsuite/ld-arm/farcall-group.d: Likewise.

commit 6abc18bbbf03dc4aee0b0f2cd851d9bc9a983e20
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Oct 26 09:53:38 2017 +0100

    Remove regular_breakpoint_inserted_here_p declaration
    
    There is no regular_breakpoint_inserted_here_p definition at all, so
    this patch removes the declaration.
    
    gdb:
    
    2017-10-26  Yao Qi  <yao.qi@linaro.org>
    
    	* breakpoint.h (regular_breakpoint_inserted_here_p): Remove.

commit bd5225139c83a80aad542e46efb66fabf51bff91
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Oct 26 09:46:16 2017 +0100

    const-fy breakpoint_ops->breakpoint_hit parameter aspace
    
    gdb:
    
    2017-10-26  Yao Qi  <yao.qi@linaro.org>
    
    	* break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
    	aspace const.
    	* break-catch-syscall.c (breakpoint_hit_catch_syscall):
    	Likewise.
    	* breakpoint.c (bpstat_check_location): Remove cast.
    	(breakpoint_hit_catch_fork): Make aspce const.
    	(breakpoint_hit_catch_solib): Likewise.
    	(breakpoint_hit_catch_exec): Likewise.
    	(breakpoint_hit_ranged_breakpoint): Likewise.
    	(breakpoint_hit_watchpoint): Likewise.
    	(base_breakpoint_breakpoint_hit): Likewise.
    	(bkpt_breakpoint_hit): Likewise.
    	(dprintf_breakpoint_hit): Likewise.
    	(tracepoint_breakpoint_hit): Likewise.
    	* breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.

commit accd0bcdfe6914193bba8dec9e6311e608b5c498
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Oct 26 09:46:16 2017 +0100

    const-fy function parameter struct address_space *aspace
    
    This patch changes the parameter "struct address_space *aspace" to "const
    address_space *aspace" in many functions.
    
    gdb:
    
    2017-10-26  Yao Qi  <yao.qi@linaro.org>
    
    	* breakpoint.c (breakpoint_location_address_match): Change
    	"struct address_space *" to "const address_space".
    	(breakpoint_location_address_range_overlap): Likewise.
    	(breakpoint_here_p): Likewise.
    	(breakpoint_in_range_p): Likewise.
    	(moribund_breakpoint_here_p): Likewise.
    	(bp_location_inserted_here_p): Likewise.
    	(software_breakpoint_inserted_here_p): Likewise.
    	(hardware_breakpoint_inserted_here_p): Likewise.
    	(hardware_watchpoint_inserted_in_range): Likewise.
    	(bpstat_check_location): Likewise.
    	(bpstat_stop_status): Likewise.
    	(breakpoint_address_match): Likewise.
    	(breakpoint_address_match_range): Likewise.
    	(breakpoint_location_address_match): Likewise.
    	(breakpoint_location_address_range_overlap): Likewise.
    	(insert_single_step_breakpoint): Likewise.
    	(breakpoint_has_location_inserted_here): Likewise.
    	(single_step_breakpoint_inserted_here_p): Likewise.
    	(pc_at_non_inline_function): Likewise.
    	* breakpoint.h (bpstat_stop_status): Update declaration.
    	(breakpoint_here_p): Likewise.
    	(breakpoint_in_range_p): Likewise.
    	(moribund_breakpoint_here_p): Likewise.
    	(breakpoint_inserted_here_p): Likewise.
    	(software_breakpoint_inserted_here_p): Likewise.
    	(hardware_breakpoint_inserted_here_p): Likewise.
    	(breakpoint_has_location_inserted_here): Likewise.
    	(single_step_breakpoint_inserted_here_p): Likewise.
    	(hardware_watchpoint_inserted_in_range): Likewise.
    	(breakpoint_address_match): Likewise.
    	(insert_single_step_breakpoint): Likewise.
    	(pc_at_non_inline_function): Likewise.
    	* gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
    	* record.c (record_check_stopped_by_breakpoint): Likewise.
    	* record.h (record_check_stopped_by_breakpoint): Likewise.
    	* thread.c (thread_has_single_step_breakpoint_here): Likewise.

commit ca3e4ea52d21c5f48e12c302179daae80e5cd420
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Oct 26 00:00:22 2017 +0000

    Automatic date update in version.in

commit 238c141b9807b43a0b04923dee64ba87df79e698
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Thu Oct 26 01:11:06 2017 +0200

    testsuite/gas/all/fill-1.s: Use L2 rather than .L2.
    
    For some targets, like mmix-knuth-mmixware, .L2 (and .L1) are invalid
    symbols.

commit 8df93cb5652730d99242e7de86679d3930a2a1b6
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Oct 25 08:44:54 2017 -0700

    ld: Correct -z ibt documentation
    
    	* ld.texinfo: Correct -z ibt.

commit ac7936dfd0c85e5de2dfec45ca0dbf72baeffa51
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Oct 25 16:37:03 2017 +0100

    s/get_regcache_arch (regcache)/regcache->arch ()/g
    
    This patches removes get_regcache_arch, and use regache->arch () instead.
    The motivation of this change is that I am going to move some basic stuff
    into a base class of regcache.  I don't need to update "client" code
    regcache->arch ().  On the other hand, this patch shortens the code a
    little bit.
    
    gdb:
    
    2017-10-25  Yao Qi  <yao.qi@linaro.org>
    
    	* aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
    	regcache->arch () instead get_regcache_arch.
    	* aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
    	Likewise.
    	(aarch64_fbsd_store_inferior_registers): Likewise.
    	* aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
    	(store_gregs_to_thread): Likewise.
    	(fetch_fpregs_from_thread): Likewise.
    	(store_fpregs_to_thread): Likewise.
    	* aarch64-tdep.c (aarch64_extract_return_value): Likewise.
    	(aarch64_store_return_value): Likewise.
    	(aarch64_software_single_step): Likewise.
    	* aix-thread.c (aix_thread_wait): Likewise.
    	(supply_reg32): Likewise.
    	(supply_sprs64): Likewise.
    	(supply_sprs32): Likewise.
    	(fill_gprs64): Likewise.
    	(fill_gprs32): Likewise.
    	(fill_sprs64): Likewise.
    	(fill_sprs32): Likewise.
    	(store_regs_user_thread): Likewise.
    	(store_regs_kernel_thread): Likewise.
    	* alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
    	(alphabsd_store_inferior_registers): Likewise.
    	* alpha-tdep.c (alpha_extract_return_value): Likewise.
    	(alpha_store_return_value): Likewise.
    	(alpha_deal_with_atomic_sequence): Likewise.
    	(alpha_next_pc): Likewise.
    	(alpha_software_single_step): Likewise.
    	* amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
    	(amd64bsd_store_inferior_registers): Likewise.
    	* amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
    	Likewise.
    	(amd64_linux_store_inferior_registers): Likewise.
    	* amd64-nat.c (amd64_supply_native_gregset): Likewise.
    	(amd64_collect_native_gregset): Likewise.
    	* amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
    	(amd64obsd_collect_uthread): Likewise.
    	* amd64-tdep.c (amd64_supply_fpregset): Likewise.
    	(amd64_collect_fpregset): Likewise.
    	(amd64_supply_fxsave): Likewise.
    	(amd64_supply_xsave): Likewise.
    	(amd64_collect_fxsave): Likewise.
    	(amd64_collect_xsave): Likewise.
    	* arc-tdep.c (arc_write_pc): Likewise.
    	* arch-utils.c (default_skip_permanent_breakpoint): Likewise.
    	* arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
    	(arm_fbsd_store_inferior_registers): Likewise.
    	* arm-linux-nat.c (fetch_vfp_regs): Likewise.
    	(store_vfp_regs): Likewise.
    	(arm_linux_fetch_inferior_registers): Likewise.
    	(arm_linux_store_inferior_registers): Likewise.
    	* arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
    	(arm_linux_sigreturn_next_pc): Likewise.
    	(arm_linux_get_next_pcs_syscall_next_pc): Likewise.
    	* arm-nbsd-nat.c (arm_supply_gregset): Likewise.
    	(fetch_register): Likewise.
    	(store_register): Likewise.
    	* arm-tdep.c (arm_is_thumb): Likewise.
    	(displaced_in_arm_mode): Likewise.
    	(bx_write_pc): Likewise.
    	(arm_get_next_pcs_addr_bits_remove): Likewise.
    	(arm_software_single_step): Likewise.
    	(arm_extract_return_value): Likewise.
    	(arm_store_return_value): Likewise.
    	(arm_write_pc): Likewise.
    	* bfin-tdep.c (bfin_extract_return_value): Likewise.
    	* bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
    	(bsd_uthread_store_registers): Likewise.
    	* core-regset.c (fetch_core_registers): Likewise.
    	* corelow.c (get_core_registers): Likewise.
    	* cris-tdep.c (cris_store_return_value): Likewise.
    	(cris_extract_return_value): Likewise.
    	(find_step_target): Likewise.
    	(find_step_target): Likewise.
    	(cris_software_single_step): Likewise.
    	* ctf.c (ctf_fetch_registers): Likewise.
    	* darwin-nat.c (cancel_breakpoint): Likewise.
    	* fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
    	* frv-tdep.c (frv_extract_return_value): Likewise.
    	* ft32-tdep.c (ft32_store_return_value): Likewise.
    	(ft32_extract_return_value): Likewise.
    	* go32-nat.c (fetch_register): Likewise.
    	(go32_fetch_registers): Likewise.
    	(go32_store_registers): Likewise.
    	(store_register): Likewise.
    	* h8300-tdep.c (h8300_extract_return_value): Likewise.
    	(h8300_store_return_value): Likewise.
    	* hppa-linux-nat.c (fetch_register): Likewise.
    	(store_register): Likewise.
    	(hppa_linux_fetch_inferior_registers): Likewise.
    	(hppa_linux_store_inferior_registers): Likewise.
    	* i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
    	(i386_darwin_store_inferior_registers): Likewise.
    	* i386-gnu-nat.c (gnu_fetch_registers): Likewise.
    	(gnu_store_registers): Likewise.
    	* i386-linux-nat.c (fetch_register): Likewise.
    	(store_register): Likewise.
    	(supply_gregset): Likewise.
    	(fill_gregset): Likewise.
    	(i386_linux_fetch_inferior_registers): Likewise.
    	(i386_linux_store_inferior_registers): Likewise.
    	(i386_linux_resume): Likewise.
    	* i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
    	Likewise.
    	* i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
    	* i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
    	* i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
    	(i386obsd_collect_uthread): Likewise.
    	* i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
    	(i386_supply_gregset): Likewise.
    	(i386_collect_gregset): Likewise.
    	(i386_supply_fpregset): Likewise.
    	(i386_collect_fpregset): Likewise.
    	(i386_mpx_bd_base): Likewise.
    	* i386-v4-nat.c	(supply_fpregset): Likewise.
    	(fill_fpregset): Likewise.
    	* i387-tdep.c (i387_supply_fsave): Likewise.
    	(i387_collect_fsave): Likewise.
    	(i387_supply_fxsave): Likewise.
    	(i387_collect_fxsave): Likewise.
    	(i387_supply_xsave): Likewise.
    	(i387_collect_xsave): Likewise.
    	* ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
    	(ia64_linux_store_registers): Likewise.
    	* ia64-tdep.c (ia64_access_rse_reg): Likewise.
    	(ia64_extract_return_value): Likewise.
    	(ia64_store_return_value): Likewise.
    	(find_func_descr): Likewise.
    	* inf-child.c (inf_child_fetch_inferior_registers): Likewise.
    	* inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
    	(inf_ptrace_store_registers): Likewise.
    	* infrun.c (use_displaced_stepping): Likewise.
    	(displaced_step_prepare_throw): Likewise.
    	(resume): Likewise.
    	(proceed): Likewise.
    	(do_target_wait): Likewise.
    	(adjust_pc_after_break): Likewise.
    	(handle_inferior_event_1): Likewise.
    	(handle_signal_stop): Likewise.
    	(save_infcall_suspend_state): Likewise.
    	(restore_infcall_suspend_state): Likewise.
    	* iq2000-tdep.c (iq2000_extract_return_value): Likewise.
    	* jit.c (jit_frame_prev_register): Likewise.
    	* linux-nat.c (save_stop_reason): Likewise.
    	(linux_nat_wait_1): Likewise.
    	(resume_stopped_resumed_lwps): Likewise.
    	* linux-record.c (record_linux_sockaddr): Likewise.
    	(record_linux_msghdr): Likewise.
    	(record_linux_system_call): Likewise.
    	* linux-tdep.c (linux_collect_thread_registers): Likewise.
    	* lm32-tdep.c (lm32_extract_return_value): Likewise.
    	(lm32_store_return_value): Likewise.
    	* m32c-tdep.c (m32c_read_flg): Likewise.
    	(m32c_pseudo_register_read): Likewise.
    	(m32c_pseudo_register_write): Likewise.
    	* m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
    	(m32r_linux_collect_gregset): Likewise.
    	* m32r-tdep.c (m32r_store_return_value): Likewise.
    	(m32r_extract_return_value): Likewise.
    	* m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
    	(m68kbsd_collect_fpregset): Likewise.
    	* m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
    	* m68k-linux-nat.c (fetch_register): Likewise.
    	(old_fetch_inferior_registers): Likewise.
    	(old_store_inferior_registers): Likewise.
    	(store_regs): Likewise.
    	* m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
    	(m68k_svr4_store_return_value): Likewise.
    	* m88k-tdep.c (m88k_store_arguments): Likewise.
    	* mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
    	(mi_cmd_data_write_register_values): Likewise.
    	* mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
    	(mips_fbsd_store_inferior_registers): Likewise.
    	* mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
    	(mips_fbsd_supply_gregs): Likewise.
    	(mips_fbsd_collect_fpregs): Likewise.
    	(mips_fbsd_collect_gregs): Likewise.
    	(mips_fbsd_supply_fpregset): Likewise.
    	(mips_fbsd_collect_fpregset): Likewise.
    	(mips_fbsd_supply_gregset): Likewise.
    	(mips_fbsd_collect_gregset): Likewise.
    	* mips-linux-nat.c (supply_gregset): Likewise.
    	(fill_gregset): Likewise.
    	(supply_fpregset): Likewise.
    	(fill_fpregset): Likewise.
    	* mips-linux-tdep.c (mips_supply_gregset): Likewise.
    	(mips_fill_gregset): Likewise.
    	(mips_supply_fpregset): Likewise.
    	(mips_fill_fpregset): Likewise.
    	(mips64_supply_gregset): Likewise.
    	(micromips_linux_sigframe_validate): Likewise.
    	* mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
    	(mipsnbsd_fetch_inferior_registers): Likewise.
    	(mipsnbsd_store_inferior_registers): Likewise.
    	* mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
    	(mipsnbsd_supply_gregset): Likewise.
    	(mipsnbsd_iterate_over_regset_sections): Likewise.
    	(mipsnbsd_supply_reg): Likewise.
    	(mipsnbsd_supply_fpreg): Likewise.
    	* mips-tdep.c (mips_in_frame_stub): Likewise.
    	(mips_dummy_id): Likewise.
    	(is_octeon_bbit_op): Likewise.
    	(micromips_bc1_pc): Likewise.
    	(extended_mips16_next_pc): Likewise.
    	(mips16_next_pc): Likewise.
    	(deal_with_atomic_sequence): Likewise.
    	* moxie-tdep.c (moxie_process_readu): Likewise.
    	* nios2-tdep.c (nios2_get_next_pc): Likewise.
    	* nto-procfs.c (procfs_store_registers): Likewise.
    	* ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
    	(ppcfbsd_store_inferior_registers): Likewise.
    	* ppc-linux-nat.c (fetch_vsx_register): Likewise.
    	(fetch_altivec_register): Likewise.
    	(get_spe_registers): Likewise.
    	(fetch_spe_register): Likewise.
    	(fetch_altivec_registers): Likewise.
    	(fetch_all_gp_regs): Likewise.
    	(fetch_all_fp_regs): Likewise.
    	(store_vsx_register): Likewise.
    	(store_altivec_register): Likewise.
    	(set_spe_registers): Likewise.
    	(store_spe_register): Likewise.
    	(store_altivec_registers): Likewise.
    	(store_all_gp_regs): Likewise.
    	(store_all_fp_regs): Likewise.
    	* ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
    	(ppc_linux_collect_gregset): Likewise.
    	(ppc_canonicalize_syscall): Likewise.
    	(ppc_linux_record_signal): Likewise.
    	(ppu2spu_prev_register): Likewise.
    	* ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
    	* ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
    	(ppcobsd_store_registers): Likewise.
    	* ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
    	Likewise.
    	(ppc_ravenscar_generic_store_registers): Likewise.
    	* procfs.c (procfs_fetch_registers): Likewise.
    	(procfs_store_registers): Likewise.
    	* ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
    	(ravenscar_store_registers): Likewise.
    	(ravenscar_prepare_to_store): Likewise.
    	* record-btrace.c (record_btrace_fetch_registers): Likewise.
    	* record-full.c (record_full_wait_1): Likewise.
    	(record_full_registers_change): Likewise.
    	(record_full_store_registers): Likewise.
    	(record_full_core_fetch_registers): Likewise.
    	(record_full_save): Likewise.
    	(record_full_goto_insn): Likewise.
    	* regcache.c (regcache_register_size): Likewise.
    	(get_regcache_arch): Remove.
    	(regcache_read_pc): Likewise.
    	* regcache.h (get_regcache_arch): Remove.
    	* remote-sim.c (gdbsim_fetch_register): Likewise.
    	(gdbsim_store_register): Likewise.
    	* remote.c (fetch_register_using_p): Likewise.
    	(send_g_packet): Likewise.
    	(remote_prepare_to_store): Likewise.
    	(store_registers_using_G): Likewise.
    	* reverse.c (save_bookmark_command): Likewise.
    	(goto_bookmark_command): Likewise.
    	* rs6000-aix-tdep.c (branch_dest): Likewise.
    	* rs6000-nat.c (rs6000_ptrace64): Likewise.
    	(fetch_register): Likewise.
    	* rs6000-tdep.c (ppc_supply_reg): Likewise.
    	(ppc_collect_reg): Likewise.
    	(ppc_collect_gregset): Likewise.
    	(ppc_collect_fpregset): Likewise.
    	(ppc_collect_vsxregset): Likewise.
    	(ppc_collect_vrregset): Likewise.
    	(ppc_displaced_step_hw_singlestep): Likewise.
    	(rs6000_pseudo_register_read): Likewise.
    	(rs6000_pseudo_register_write): Likewise.
    	* s390-linux-nat.c (supply_gregset): Likewise.
    	(fill_gregset): Likewise.
    	(s390_linux_fetch_inferior_registers): Likewise.
    	* s390-linux-tdep.c (s390_write_pc): Likewise.
    	(s390_software_single_step): Likewise.
    	(s390_all_but_pc_registers_record): Likewise.
    	(s390_linux_syscall_record): Likewise.
    	* sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
    	* sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
    	(shnbsd_store_inferior_registers): Likewise.
    	* sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
    	(sh_extract_return_value_fpu): Likewise.
    	(sh_store_return_value_nofpu): Likewise.
    	(sh_corefile_supply_regset): Likewise.
    	(sh_corefile_collect_regset): Likewise.
    	* sh64-tdep.c (sh64_extract_return_value): Likewise.
    	(sh64_store_return_value): Likewise.
    	* sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
    	* sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
    	(sparc_store_inferior_registers): Likewise.
    	* sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
    	(sparc_ravenscar_prepare_to_store): Likewise.
    	* sparc-tdep.c (sparc32_store_arguments): Likewise.
    	(sparc_analyze_control_transfer): Likewise.
    	(sparc_step_trap): Likewise.
    	(sparc_software_single_step): Likewise.
    	(sparc32_gdbarch_init): Likewise.
    	(sparc_supply_rwindow): Likewise.
    	(sparc_collect_rwindow): Likewise.
    	* sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
    	* sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
    	(sparc64nbsd_collect_gregset): Likewise.
    	(sparc64nbsd_supply_fpregset): Likewise.
    	(sparc64nbsd_collect_fpregset): Likewise.
    	* sparc64-tdep.c (sparc64_store_arguments): Likewise.
    	(sparc64_supply_gregset): Likewise.
    	(sparc64_collect_gregset): Likewise.
    	(sparc64_supply_fpregset): Likewise.
    	(sparc64_collect_fpregset): Likewise.
    	* spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
    	* spu-tdep.c (spu_unwind_sp): Likewise.
    	(spu2ppu_prev_register): Likewise.
    	(spu_memory_remove_breakpoint): Likewise.
    	* stack.c (return_command): Likewise.
    	* tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
    	* tracefile-tfile.c (tfile_fetch_registers): Likewise.
    	* tracefile.c (trace_save_ctf): Likewise.
    	* windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
    	(do_windows_store_inferior_registers): Likewise.
    	(windows_resume): Likewise.
    	* xtensa-linux-nat.c (fill_gregset): Likewise.
    	(supply_gregset_reg): Likewise.
    	* xtensa-tdep.c (xtensa_register_write_masked): Likewise.
    	(xtensa_register_read_masked): Likewise.
    	(xtensa_supply_gregset): Likewise.
    	(xtensa_extract_return_value): Likewise.
    	(xtensa_store_return_value): Likewise.

commit edd079d9f6ca2f9ad21322b742269aec5de61190
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Oct 25 15:32:23 2017 +0200

    Target FP: Use target format throughout expression parsing
    
    When parsing floating-point literals, the language parsers currently
    use parse_float or some equivalent routine to parse the input string
    into a DOUBLEST, which is then stored within a OP_DOUBLE expression
    node.  When evaluating the expression, the OP_DOUBLE is finally
    converted into a value in target format.
    
    On the other hand, *decimal* floating-point literals are parsed
    directly into target format and stored that way in a OP_DECFLOAT
    expression node.  In order to eliminate the DOUBLEST, this patch
    therefore unifies the handling of binary and decimal floating-
    point literals and stores them both in target format within a
    new OP_FLOAT expression node, replacing both OP_DOUBLE and
    OP_DECFLOAT.
    
    In order to store literals in target format, the parse_float
    routine needs to know the type of the literal.  All parsers
    therefore need to be changed to determine the appropriate type
    (e.g. by detecting suffixes) *before* calling parse_float,
    instead of after it as today.  However, this change is mostly
    straightforward -- again, this is already done for decimal FP
    today.
    
    The core of the literal parsing is moved into a new routine
    floatformat_from_string, mirroring floatformat_to_string.
    The parse_float routine now calls either floatformat_from_string
    or decimal_from_sting, allowing it to handle any type of FP
    literal.
    
    All language parsers need to be updated.  Some notes on
    specific changes to the various languages:
    
    - C: Decimal FP is now handled in parse_float, and no longer
      needs to be handled specially.
    
    - D: Straightforward.
    
    - Fortran: Still used a hard-coded "atof", also replaced by
      parse_float now.  Continues to always use builtin_real_s8
      as the type of literal, even though this is probably wrong.
    
    - Go: This used to handle "f" and "l" suffixes, even though
      the Go language actually doesn't support those.  I kept this
      support for now -- maybe revisit later.  Note the the GDB
      test suite for some reason actually *verifies* that GDB supports
      those unsupported suffixes ...
    
    - Pascal: Likewise -- this handles suffixes that are not
      supported in the language standard.
    
    - Modula-2: Like Fortran, used to use "atof".
    
    - Rust: Mostly straightforward, except for a unit-testing hitch.
      The code use to set a special "unit_testing" flag which would
      cause "rust_type" to always return NULL.  This makes it not
      possible to encode a literal into target format (which type?).
      The reason for this flag appears to have been that during
      unit testing, there is no "rust_parser" context set up, which
      means no "gdbarch" is available to use its types.  To fix this,
      I removed the unit_testing flag, and instead simply just set up
      a dummy rust_parser context during unit testing.
    
    - Ada: This used to check sizeof (DOUBLEST) to determine which
      type to use for floating-point literal.  This seems questionable
      to begin with (since DOUBLEST is quite unrelated to target formats),
      and in any case we need to get rid of DOUBLEST.  I'm now simply
      always using the largest type (builtin_long_double).
    
    gdb/ChangeLog:
    2017-10-25  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.c (floatformat_from_string): New function.
    	* doublest.h (floatformat_from_string): Add prototype.
    
    	* std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
    	(OP_FLOAT): ... this.
    	* expression.h: Do not include "doublest.h".
    	(union exp_element): Replace doubleconst and decfloatconst by
    	new element floatconst.
    	* ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
    	(ada_evaluate_subexp): Likewise.
    	* eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
    	OP_DOUBLE and OP_DECFLOAT.
    	* expprint.c (print_subexp_standard): Likewise.
    	(dump_subexp_body_standard): Likewise.
    	* breakpoint.c (watchpoint_exp_is_const): Likewise.
    
    	* parse.c: Include "dfp.h".
    	(write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
    	(write_exp_elt_floatcst): New function.
    	(operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
    	and OP_DECFLOAT.
    	(operator_check_standard): Likewise.
    	(parse_float): Do not accept suffix.  Take type as input.  Return bool.
    	Return target format buffer instead of host DOUBLEST.
    	Use floatformat_from_string and decimal_from_string to parse
    	either binary or decimal floating-point types.
    	(parse_c_float): Remove.
    	* parser-defs.h: Do not include "doublest.h".
    	(write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
    	(write_exp_elt_floatcst): Add prototype.
    	(parse_float): Update prototype.
    	(parse_c_float): Remove.
    
    	* c-exp.y: Do not include "dfp.h".
    	(typed_val_float): Use byte buffer instead of DOUBLEST.
    	(typed_val_decfloat): Remove.
    	(DECFLOAT): Remove.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Update to new parse_float interface.
    	Parse suffixes and determine type before calling parse_float.
    	Handle decimal and binary FP types the same way.
    
    	* d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
    	(FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Update to new parse_float interface.
    	Parse suffixes and determine type before calling parse_float.
    
    	* f-exp.y: Replace dval by typed_val_float.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Use parse_float instead of atof.
    
    	* go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
    	(parse_go_float): Remove.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Call parse_float instead of parse_go_float.
    	Parse suffixes and determine type before calling parse_float.
    
    	* p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Update to new parse_float interface.
    	Parse suffixes and determine type before calling parse_float.
    
    	* m2-exp.y: Replace dval by byte buffer val.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	(parse_number): Call parse_float instead of atof.
    
    	* rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
    	(lex_number): Call parse_float instead of strtod.
    	(ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
    	(convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
    	Use write_exp_elt_floatcst.
    	(unit_testing): Remove static variable.
    	(rust_type): Do not check unit_testing.
    	(rust_lex_tests): Do not set uint_testing.  Set up dummy rust_parser.
    
    	* ada-exp.y (type_float, type_double): Remove.
    	(typed_val_float): Use byte buffer instead of DOUBLEST.
    	(FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
    	* ada-lex.l (processReal): Use parse_float instead of sscanf.

commit e5d70d6b5a5c2832ad199ac1b91f68324b4a12c9
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 25 21:59:14 2017 +1030

    PR22348, conflicting global vars in crx and cr16
    
    include/
    	PR 22348
    	* opcode/cr16.h (instruction): Delete.
    	(cr16_words, cr16_allWords, cr16_currInsn): Delete.
    	* opcode/crx.h (crx_cst4_map): Rename from cst4_map.
    	(crx_cst4_maps): Rename from cst4_maps.
    	(crx_no_op_insn): Rename from no_op_insn.
    	(instruction): Delete.
    opcodes/
    	PR 22348
    	* cr16-dis.c (cr16_cinvs, instruction, cr16_currInsn): Make static.
    	(cr16_words, cr16_allWords, processing_argument_number): Likewise.
    	(imm4flag, size_changed): Likewise.
    	* crx-dis.c (crx_cinvs, NUMCINVS, instruction, currInsn): Likewise.
    	(words, allWords, processing_argument_number): Likewise.
    	(cst4flag, size_changed): Likewise.
    	* crx-opc.c (crx_cst4_map): Rename from cst4_map.
    	(crx_cst4_maps): Rename from cst4_maps.
    	(crx_no_op_insn): Rename from no_op_insn.
    gas/
    	PR 22348
    	* config/tc-crx.c (instruction, output_opcode): Make static.
    	(relocatable, ins_parse, cur_arg_num): Likewise.
    	(parse_insn): Adjust for renamed opcodes globals.
    	(check_range): Likewise

commit cc628f3dbb12c720dbc9ab714feeb197dc739944
Author: Alan Hayward <alan.hayward@arm.com>
Date:   Wed Oct 25 09:06:41 2017 +0100

    Add common AARCH64 REGNUM defines
    
    gdb/
    	* aarch64-tdep.h (enum aarch64_regnum): Remove.
    	* arch/aarch64.h: New file.
    
    gdbserver/
    	* linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
    	with REGNO.
    	(aarch64_store_gregset): Likewise.
    	(aarch64_fill_fpregset): Likewise.
    	(aarch64_store_fpregset): Likewise.

commit e601d38b7cc222345d4128f45db18529b9fb477b
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 25 15:32:52 2017 +1030

    Allow for __gnu_lto_slim prefixed with extra "_"
    
    Some targets prefix global symbols with "_".
    
    bfd/
    	* archive.c (_bfd_compute_and_write_armap): Match "__gnu_lto_slim"
    	optionally prefixed with "_".
    	* linker.c (_bfd_generic_link_add_one_symbol): Likewise.
    binutils/
    	* nm.c (filter_symbols): Match "__gnu_lto_slim" optionally prefixed
    	with "_".
    gold/
    	* symtab.cc (Symbol_table::add_from_relobj): Match "__gnu_lto_slim"
    	optionally prefixed with "_".
    ld/
    	* testsuite/ld-plugin/lto-3r.d: Match "__gnu_lto_v" optionally
    	prefixed with "_".
    	* testsuite/ld-plugin/lto-5r.d: Likewise.

commit 94092126a05ee625bf05d48cb331472b8f87d235
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 25 15:31:58 2017 +1030

    Yet another fill-1 test fix
    
    tic4x fails due to being a 4 octets per byte target, while tic54x is 2
    octets per byte.
    
    mmix still fails with
    fill-1.s:4: Error: unknown pseudo-op: `.l1:'
    fill-1.s:6: Error: unknown pseudo-op: `.l2:'
    fill-1.s:3: Error: .space specifies non-absolute value
    
    and if the labels are changed to L1 and L2 then mep-elf fails with
    fill-1.s:3: Error: .space specifies non-absolute value
    
    Since both of those look like they ought to be investigated by the
    target maintainers, I'm tweaking the test to fail on both targets.
    
    	* testsuite/gas/all/fill-1.d: Exclude tic4x and tic54x.
    	* testsuite/gas/all/fill-1.s: Use L1 rather than .L1.

commit 711f5e559e8009f8033f3709d4fbe70c961a403a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Oct 25 00:00:26 2017 +0000

    Automatic date update in version.in

commit db283f44015de0ae0129688bf0e8e4e02672f6ea
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Wed Oct 25 00:46:24 2017 +0200

    Fix format typos in previous previous ld/ChangeLog entry

commit 2e30886f1fa22fd28a1a91f5aae2ec033e2e54a9
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Wed Oct 25 00:45:05 2017 +0200

    testsuite/ld-riscv-elf/ld-riscv-elf.exp: Fix typo for istarget.

commit 792ccf005f391f46e295e250f285d040ab105ab7
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 23:22:56 2017 +0100

    Fix racy test in gdb.base/new-ui.exp
    
    I noticed gdb.base/new-ui.exp failing once here with:
    
     FAIL: gdb.base/new-ui.exp: do_test: delete all breakpoints on extra console (got interactive prompt)
     FAIL: gdb.base/new-ui.exp: do_test: main console: next causes no spurious output on other console
     FAIL: gdb.base/new-ui.exp: do_test: main console: breakpoint hit reported on other console
    
    The problem is 100% reproducible with check-read1:
      $ make check-read1 TESTS="gdb.*/new-ui.exp"
    
    testsuite/gdb.log shows:
      delete
      Delete all breakpoints? (y or n) [answered Y; input not from terminal]
      (gdb) FAIL: gdb.base/new-ui.exp: do_test: delete all breakpoints on extra console (got interactive prompt)
    
    This commit fixes the problem.
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/new-ui.exp (do_test): Split "delete all breakpoints on
    	extra console" test in two stages.

commit 63a25ea0de6d2f6d45b26af8d9c808aa35962256
Author: Andrew Waterman <andrew@sifive.com>
Date:   Thu Oct 19 11:21:44 2017 -0700

    RISC-V: Fix disassembly of c.addi4spn, c.addi16sp, c.lui when imm=0
    
    These are all invalid instructions, so they should not disassemble.
    
    opcodes/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * riscv-opc.c (match_c_addi16sp) : New function.
            (match_c_addi4spn): New function.
            (match_c_lui): Don't allow 0-immediate encodings.
            (riscv_opcodes) <addi>: Use the above functions.
            <add>: Likewise.
            <c.addi4spn>: Likewise.
            <c.addi16sp>: Likewise.
    
    gas/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * testsuite/gas/riscv/c-addi16sp-fail.d: New test.
            testsuite/gas/riscv/c-addi16sp-fail.l: Likewise.
            testsuite/gas/riscv/c-addi16sp-fail.s: Likewise.
            testsuite/gas/riscv/c-addi4spn-fail.d: Likewise.
            testsuite/gas/riscv/c-addi4spn-fail.l: Likewise.
            testsuite/gas/riscv/c-addi4spn-fail.s: Likewise.
            testsuite/gas/riscv/riscv.exp: Add new tests.

commit 09a7c6aa7a07f874f5357cde62b5753a10a5e107
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Oct 24 18:34:41 2017 +0200

    Use const reference for decimal_from_string argument
    
    No functional change.
    
    gdb/ChangeLog:
    2017-10-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* dfp.h (decimal_from_string): Use const reference for argument.
    	* dfp.c (decimal_from_string): Likewise.

commit 8ba0dd515c1ba23318f28c6bb04c9da573855b50
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Oct 24 18:01:39 2017 +0200

    Target FP printing: Use floatformat_to_string in tdep code
    
    A few tdep files use target-specific printing routines to output values in
    the floating-point registers.  To get rid of host floating-point code,
    this patch changes them to use floatformat_to_string instead.
    
    No functional change intended, the resulting output should look the same.
    
    ChangeLog:
    2017-10-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* i387-tdep.c (print_i387_value): Use floatformat_to_string.
    	* sh64-tdep.c (sh64_do_fp_register): Likewise.
    	* mips-tdep.c (mips_print_fp_register): Likewise.

commit 16e812b29e68c4a6fcad73b033716c4f385ce94f
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Oct 24 18:00:50 2017 +0200

    Target FP printing: Simplify and fix ui_printf
    
    This patch adds support for handling format strings to both
    floatformat_to_string and decimal_to_string, and then uses
    those routines to implement ui_printf formatted printing.
    
    There is already a subroutine printf_decfloat that ui_printf uses to
    handle decimal FP.  This is renamed to printf_floating and updated
    to handle both binary and decimal FP.  This includes the following
    set of changes:
    
    - printf_decfloat currently parses the format string again to determine
      the intended target format.  This seems superfluous since the common
      parsing code in parse_format_string already did this, but then did
      not pass the result on to its users.  Fixed by splitting the decfloat_arg
      argument class into three distinct classes, and passing them through.
    
    - Now we can rename printf_decfloat to printf_floating and also call it
      for the argument classes representing binary FP types.
    
    - The code will now use the argclass to detect the type the value should
      be printed at, and converts the input value to this type if necessary.
      To remain compatible with current behavior, for binary FP the code
      instead tries to re-interpret the input value as a FP type of the
      same size if that exists.  (Maybe this behavior is more confusing
      than useful -- but this can be changed later if we want to ...)
    
    - Finally, we can use floatformat_to_string / decimal_to_string passing
      the format string to perform the formatted output using the desired
      target FP type.
    
    Note that we no longer generate different code depending on whether or not
    the host supports "long double" -- this check is obsolete anyway since C++11
    mandates "long double", and in any case a %lg format string is intended to
    refer to the *target* long double type, not the host version.
    
    Note also that formatted printing of DFP numbers may not work correctly,
    since it attempts to use the host printf to do so (and makes unwarranted
    assumptions about the host ABI while doing so!).  This is no change to
    the current behavior -- I simply moved the code from printf_decfloat to
    the decimal_to_string routine in dfp.c.  If we want to fix it in the
    future, that is a more appropriate place anyway.
    
    ChangeLog:
    2017-10-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* common/format.h (enum argclass): Replace decfloat_arg by
    	dec32float_arg, dec64float_arg, and dec128float_arg.
    	* common/format.c (parse_format_string): Update to return
    	new decimal float argument classes.
    
    	* printcmd.c (printf_decfloat): Rename to ...
    	(printf_floating): ... this.  Add argclass argument, and use it
    	instead of parsing the format string again.  Add support for
    	binary floating-point values, using floatformat_to_string.
    	Convert value to the target format if it doesn't already match.
    	(ui_printf): Call printf_floating instead of printf_decfloat,
    	also for double_arg / long_double_arg.  Pass argclass.
    
    	* dfp.c (decimal_to_string): Add format string argument.
    	* dfp.h (decimal_to_string): Likewise.
    
    	* doublest.c (floatformat_to_string): Add format string argument.
    	* doublest.h (floatformat_to_string): Likewise.

commit fdf0cbc2b710cb5e01249e18f5a377a55eddc39b
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Oct 24 17:59:22 2017 +0200

    Target FP printing: Simplify and fix print_floating
    
    The print_floating routine currently makes a lot of assumptions about host
    and target floating point formats.  This patch cleans up many of those.
    
    One problem is that print_floating may currently be called with types
    that are not actually floating-point types, and it tries hard to output
    those as floating-point values anyway.  However, there is only one single
    caller of print_floating where this can ever happen: print_scalar_formatted.
    And in fact, it is much simpler to handle the case where the value to be
    printed is not already of floating-point type right there.
    
    So this patch changes print_scalar_formatted to handle the 'f' format
    as follows:
    
    - If the value to be printed is already of floating-point type, just
      call print_floating on it.
    
    - Otherwise, if there is a standard target floating-point type of
      the same size as the value, call print_floating using that type.
    
    - Otherwise, just print the value as if the 'f' format had not been
      specified at all.
    
    This has the overall effect to printing everything the same way as
    the old code did, but is overall a lot simpler.  (Also, it would
    allow us to change the above strategy more easily, if that might
    be a more intuitive user interface.  For example, in the third
    case above, maybe an error would be more appropriate?)
    
    Given that change, print_floating can become much simpler.  In particular,
    we now always have a floating-point format that we can consult.  This
    means we can use the floating-point format to programmatically determine
    the number of digits necessary to print the value.
    
    The current code uses a hard-coded value of 9, 17, or 35 digits.  Note
    that this matches the DECIMAL_DIG values for IEEE-32, IEEE-64, and
    IEEE-128.  (Actually, for IEEE-128 the correct value is 36 -- the 35
    seems to be an oversight.)  The DECIMAL_DIG value is defined to be
    the smallest number so that any number in the target format, when
    printed to this number of digits and then scanned back into a binary
    floating-point number, will result in the original value.
    
    Now that we always have a FP format, we can just compute the DECIMAL_DIG
    value using the formula from the C standard.  This will be correct for
    *all* FP formats, not just the above list, and it will be correct (as
    opposed to current code) if the target formats differ from the host ones.
    
    The patch moves the new logic to a new floatformat_to_string routine
    (analogous to the existing decimal_to_string).  The print_floating
    routine now calls floatformat_to_string or decimal_to_string, making
    the separate print_decimal_floating and generic_val_print_decfloat routines
    unnecessary.
    
    gdb/ChangeLog:
    2017-10-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.c (floatformat_precision): New routine.
    	(floatformat_to_string): Likewise.
    	* doublest.c (floatformat_to_string): Add prototype.
    
    	* printcmd.c (print_scalar_formatted): Only call print_floating
    	on floating-point types.
    	* valprint.c: Do not include "floatformat.h".
    	(generic_val_print_decfloat): Remove.
    	(generic_val_print): Call generic_val_print_float for both
    	TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
    	(print_floating): Use floatformat_to_string.  Handle decimal float.
    	(print_decimal_floating): Remove, merge into floatformat_to_string.
    	* value.h (print_decimal_floating): Remove.
    
    	* Makefile.in: Do not build doublest.c with -Wformat-nonliteral.

commit 3342be5dabeeaf2218dfbf4d38f92214612436f4
Author: Andrew Waterman <andrew@sifive.com>
Date:   Sat Sep 23 18:04:16 2017 -0700

    RISC-V: Only relax to C.LUI when imm != 0 and rd != 0/2
    
    This matches the ISA specification.  This also adds two tests: one to
    make sure the assembler rejects invalid 'c.lui's, and one to make sure
    we only relax valid 'c.lui's.
    
    bfd/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * elfnn-riscv.c (_bfd_riscv_relax_lui): Don't relax to c.lui
            when rd is x0.
    
    include/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * opcode/riscv.h (VALID_RVC_LUI_IMM): c.lui can't load the
            immediate 0.
    
    gas/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * testsuite/gas/riscv/c-lui-fail.d: New testcase.
            gas/testsuite/gas/riscv/c-lui-fail.l: Likewise.
            gas/testsuite/gas/riscv/c-lui-fail.s: Likewise.
            gas/testsuite/gas/riscv/riscv.exp: Likewise.
    
    ld/ChangeLog
    
    2017-10-24  Andrew Waterman  <andrew@sifive.com>
    
            * ld/testsuite/ld-riscv-elf/c-lui.d: New testcase.
            ld/testsuite/ld-riscv-elf/c-lui.s: Likewise.
            ld/testsuite/ld-riscv-elf/ld-riscv-elf.exp: New test suite.

commit 3779bbe01b4ec1e5ae0a5c555f838999ba88ac50
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Tue Oct 24 06:58:48 2017 -0700

    Fix my previous gas/ChangeLog entry

commit da5f19a2534936376228943de85fdd60f6ddd839
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Oct 24 07:47:32 2017 -0700

    i386: Support .code64 directive only with 64-bit bfd
    
    Without 64-bit bfd, we can't properly support .code64 directive in
    32-bit mode.
    
    	* config/tc-i386.c (md_pseudo_table): Add .code64 directive
    	only if BFD64 is defined.
    	* testsuite/gas/i386/code64-inval.l: New file.
    	* gas/testsuite/gas/i386/code64-inval.s: Likewise.
    	* gas/testsuite/gas/i386/code64.d: Likewise.
    	* gas/testsuite/gas/i386/code64.s: Likewise.
    	* testsuite/gas/i386/i386.exp: Run mixed-mode-reloc32,
    	att-regs, intel-regs, intel-expr and string-ok tests only if
    	assembler supports x86-64.  Run code64 and code64-inval.

commit 5033013f17524964564dac5d422739ae5214729e
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Tue Oct 24 16:33:53 2017 +0200

    Fix gdb.opt/inline-cmds.exp regressions
    
    When sorting pending blocks in end_symtab_get_static_block, blocks
    with the same starting address must remain in the original order
    to preserve inline function caller/callee relationships.
    
    The original code seems to have implicitly relied on the fact that the
    glibc qsort implemention actually (in the common case) provides a stable
    sort, although this is not guaranteed by the standard.  But the GNU
    libstdc++ std::sort implementation is *not* stable.
    
    gdb/ChangeLog:
    2017-10-24  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* buildsym.c (end_symtab_get_static_block): Use std::stable_sort.

commit 93f4de3929aeb3e21d57950bfa96539599a92f2a
Author: Renlin Li <renlin.li@arm.com>
Date:   Tue Oct 24 12:42:30 2017 +0100

    [BFD][PR21703]Override the new defined symbol with the old normal symbol when --allow-multiple-definition is provided.
    
    The behavior of _bfd_elf_merge_symbol and _bfd_generic_link_add_one_symbol is
    inconsistent.
    
    In multiple definition case, _bfd_elf_merge_symbol decided to override the old
    symbol definition with the new defintion, (size, type, target data)
    In _bfd_generic_link_add_one_symbol, it simply return without doing anything
    because of allow-multiple-definition is provided.
    This leaves the symbol in a wrong state.
    
    Here, following the documentation, I made this patch to force the old definition
    override the new definition if the old symbol is not dynamic or weak.
    Because, in those two cases, it's expected to do some merge. I have checked
    that, those two cases are properly handled.
    
    bfd/
    	PR ld/21703
    	* elflink.c (_bfd_elf_merge_symbol): Handle multiple definition case.
    
    ld/
    
    	PR ld/21703
    	* testsuite/ld-elf/elf.exp: Run new tests.
    	* testsuite/ld-elf/pr21703-1.s: New.
    	* testsuite/ld-elf/pr21703-2.s: New.
    	* testsuite/ld-elf/pr21703-3.s: New.
    	* testsuite/ld-elf/pr21703-4.s: New.
    	* testsuite/ld-elf/pr21703-r.sd: New.
    	* testsuite/ld-elf/pr21703-shared.sd: New.
    	* testsuite/ld-elf/pr21703.sd: New.
    	* testsuite/ld-elf/pr21703.ver: New.

commit eb2bfbadc159ff1463e58daf24c4ad5d1a23796d
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:45 2017 +0100

    Reindent gdb.threads/attach-into-signal.exp
    
    A previous patch removed one nesting level.
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/attach-into-signal.exp (corefunc): Reindent.

commit 1f75a6516a4b480b5521dfb4e1a0721887ab5cdc
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:35 2017 +0100

    Drop /proc/PID/status polling from gdb.threads/attach-into-signal.exp
    
    I noticed that the 'with_test_prefix "stoppedtry $stoppedtry"' prefix
    in this testcase is unnecessary, because inside that block there are
    no pass/fail calls.  In fact the block includes a comment saying:
    
      # No PASS message as we may be looping in multiple
      # attempts.
    
    but looking deeper at this I noticed a few odd things with this code
    block:
    
    1. This code is assuming that the second line in the /proc/PID/status
       files is the "State:" line, which may have been true when this was
       originally written, but is not true on my machine at least (Linux
       4.8.13).
    
         $ cat /proc/self/status
         Name:   cat
         Umask:  0002
         State:  R (running)
    
       So nowadays, that 'string match "*(stopped)*"' is running against
       the "Umask:" line and thus always returns false, meaning the loop
       always breaks on $stoppedtry == 0.
    
    2. The loop seems to be waiting for the process to become "(stopped)",
       but if so then that 'if {![string match]}' check is reversed, it
       should be checking 'if {[string match]}' instead, because "string
       match" returns true if the string matches, not 0.
    
    3. But if we fixed all that, we'd still run into the simple fact that
       nothing is actually stopping the test's inferior process before GDB
       attaches...  The top of the testcase says:
    
        # This test was created by modifying attach-stopped.exp.
    
       ... and attach-stopped.exp does have:
    
           # Stop the program
           remote_exec build "kill -s STOP ${testpid}"
    
       but then attach-stopped.exp doesn't have an equivalent
       /proc/PID/status poll loop...  (Maybe it could.)
    
    So remove this whole loop as useless.
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/attach-into-signal.exp: Remove whole "stoppedtry"
    	loop.

commit 779990d9f0a169215b3619a8a1cd120550320793
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:35 2017 +0100

    Fix unstable test names in gdb.threads/attach-into-signal.exp
    
    Currently, if you diff testsuite/gdb.sum of two testsuite runs you'll
    often see spurious hunks like these:
    
      -PASS: gdb.threads/attach-into-signal.exp: nonthreaded: attempt 2: attach (pass 2), pending signal catch
      +PASS: gdb.threads/attach-into-signal.exp: nonthreaded: attempt 1: attach (pass 2), pending signal catch
       PASS: gdb.threads/attach-into-signal.exp: successfully compiled posix threads test case
       PASS: gdb.threads/attach-into-signal.exp: threaded: handle SIGALRM stop print pass
      -PASS: gdb.threads/attach-into-signal.exp: threaded: attempt 1: attach (pass 1), pending signal catch
      -PASS: gdb.threads/attach-into-signal.exp: threaded: attempt 1: attach (pass 2), pending signal catch
      +PASS: gdb.threads/attach-into-signal.exp: threaded: attempt 2: attach (pass 1), pending signal catch
      +PASS: gdb.threads/attach-into-signal.exp: threaded: attempt 4: attach (pass 2), pending signal catch
    
    Fix this by removing the "attempt $attempt" test prefix.  The attempt
    number can be retrieved from gdb.log instead, since the testcase is
    already using "verbose -log" to that effect.
    
    (The 'with_test_prefix "stoppedtry $stoppedtry"' prefix is unnecessary
    too, because inside that block there are no pass/fail calls.  In fact
    the block includes a comment saying:
    
      # No PASS message as we may be looping in multiple
      # attempts.
    
    but I'll drop that whole loop in the next patch instead.)
    
    After this commit we'll show:
    
      PASS: gdb.threads/attach-into-signal.exp: nonthreaded: handle SIGALRM stop print pass
      PASS: gdb.threads/attach-into-signal.exp: nonthreaded: attach (pass 1), pending signal catch
      PASS: gdb.threads/attach-into-signal.exp: nonthreaded: attach (pass 2), pending signal catch
      PASS: gdb.threads/attach-into-signal.exp: successfully compiled posix threads test case
      PASS: gdb.threads/attach-into-signal.exp: threaded: handle SIGALRM stop print pass
      PASS: gdb.threads/attach-into-signal.exp: threaded: attach (pass 1), pending signal catch
      PASS: gdb.threads/attach-into-signal.exp: threaded: attach (pass 2), pending signal catch
    
    (I've avoided reindenting to make the patch easier to maintain/read.
    I'll reindent the blocks after this is in.)
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/attach-into-signal.exp (corefunc): Remove "attach
    	$attempt" test prefix.

commit ad9b8f5d022f777f32cceab9856f47a5b6afcce1
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:34 2017 +0100

    Fix unstable test names in gdb.python/py-objfile.exp
    
    Currently, if you diff testsuite/gdb.sum of different builds you see
    this spurious hunk:
    
      -PASS: gdb.python/py-objfile.exp: get python valueof "sep_objfile.build_id" (6a0bfcab663f9810ccff33c756afdebb940037d4)
      +PASS: gdb.python/py-objfile.exp: get python valueof "sep_objfile.build_id" (1f5531c657c57777b05fc95baa0025fd1d115c3b)
    
    Fix this by syncing get_python_valueof with get_integer_valueof, which
    stopped outputting the value in commit 2f20e312aad6
    ("get_integer_valueof: Don't output value in test name").
    
    After this commit we'll show:
    
      PASS: gdb.python/py-objfile.exp: get python valueof "sep_objfile.build_id"
    
    As the comment explicitly says get_python_valueof is modeled on
    get_integer_valueof, I went ahead and also added the optional 'test'
    parameter while at it.
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* lib/gdb-python.exp (get_python_valueof): Add 'test' optional
    	parameter and handle it.  Don't output read value in test name.

commit fee6da6e1d96796f8aa8308b3833a3e4cdb409ff
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:34 2017 +0100

    Fix unstable test names in gdb.gdb/unittest.exp
    
    Currently, if you diff testsuite/gdb.sum of two builds built from different
    source directories you see this spurious hunk:
    
      -PASS: gdb.gdb/unittest.exp: maintenance check xml-descriptions /home/pedro/gdb1/src/gdb/testsuite/../features
      +PASS: gdb.gdb/unittest.exp: maintenance check xml-descriptions /home/pedro/gdb2/src/gdb/testsuite/../features
    
    After this commit we'll show instead:
    
      PASS: gdb.gdb/unittest.exp: maintenance check xml-descriptions ${srcdir}/../features
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.gdb/unittest.exp ('maintenance check xml-descriptions'): Use
    	custom test name.

commit 10389c2c8b56b2519441e55bf16f77882fb897cb
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:33 2017 +0100

    Fix unstable test names in gdb.base/startup-with-shell.exp
    
    Currently, if you diff testsuite/gdb.sum of two builds in different
    directories you see these spurious hunks:
    
      -PASS: gdb.base/startup-with-shell.exp: touch /home/pedro/gdb1/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/unique-file.unique-extension
      +PASS: gdb.base/startup-with-shell.exp: touch /home/pedro/gdb2/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/unique-file.unique-extension
    
      -PASS: gdb.base/startup-with-shell.exp: startup_with_shell = on; run_args = *.unique-extension: set args /home/pedro/gdb1/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/*.unique-extension
      +PASS: gdb.base/startup-with-shell.exp: startup_with_shell = on; run_args = *.unique-extension: set args /home/pedro/gdb2/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/*.unique-extension
    
      -PASS: gdb.base/startup-with-shell.exp: startup_with_shell = off; run_args = *.unique-extension: set args /home/pedro/gdb1/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/*.unique-extension
      +PASS: gdb.base/startup-with-shell.exp: startup_with_shell = off; run_args = *.unique-extension: set args /home/pedro/gdb2/build/gdb/testsuite/outputs/gdb.base/startup-with-shell/*.unique-extension
    
    Since the run_args arguments are already shown in the test prefix, we
    can change the "set args" test name to literally "set args $run_args".
    I.e., after this commit we'll show:
    
      PASS: gdb.base/startup-with-shell.exp: startup_with_shell = on; run_args = *.unique-extension: set args $run_args
      PASS: gdb.base/startup-with-shell.exp: startup_with_shell = off; run_args = *.unique-extension: set args $run_args
      PASS: gdb.base/startup-with-shell.exp: startup_with_shell = on; run_args = $TEST: set args $run_args
      PASS: gdb.base/startup-with-shell.exp: startup_with_shell = off; run_args = $TEST: set args $run_args
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/startup-with-shell.exp ('touch $unique_file'): Don't
    	include the unstable output directory name in the test's name.
    	(initial_setup_simple) <'set args'>: Use custom test name.

commit a80e65a9d590f8817e4acd5a62363319b6a1f961
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 24 10:43:33 2017 +0100

    Fix unstable test names in gdb.arch/arc-tdesc-cpu.exp
    
    Currently if you diff testsuite/gdb.sum of two builds built from
    different source trees you see this spurious hunk:
    
      -PASS: gdb.arch/arc-tdesc-cpu.exp: set tdesc filename /home/pedro/gdb1/src/gdb/testsuite/gdb.arch/arc-tdesc-cpu.xml
      +PASS: gdb.arch/arc-tdesc-cpu.exp: set tdesc filename /home/pedro/gdb2/src/gdb/testsuite/gdb.arch/arc-tdesc-cpu.xml
    
    After this commit we'll show this instead in gdb.sum:
      PASS: gdb.arch/arc-tdesc-cpu.exp: set tdesc filename $srcdir/gdb.arch/arc-tdesc-cpu.xml
    
    gdb/testsuite/ChangeLog:
    2017-10-24  Pedro Alves  <palves@redhat.com>
    
    	* gdb.arch/arc-tdesc-cpu.exp ('set tdesc filename'): Use gdb_test
    	with explicit test name.

commit 2c3f27ed0d6a91bc0812bb2fc6965fd03a413fee
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Fri Oct 6 12:06:45 2017 -0700

    RISC-V: Don't emit 2-byte NOPs if the C extension is disabled
    
    Systems without the C extension mandate 4-byte alignment for
    instructions, so there is no reason to allow for 2-byte alignment.  This
    change avoids emitting lots of unimplemented instructions into object
    files on non-C targets, which users keep reporting as a bug.  While this
    isn't actually a bug (as none of the offsets in object files are
    relevant until RISC-V), it is ugly.
    
    gas/ChangeLog
    
    2017-10-23  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * config/tc-riscv.c (riscv_frag_align_code): Align code by 4
            bytes on non-RVC systems.

commit fee0ea1f2d3079f7fc3d48109c2a81cc7b7f241c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Oct 24 00:00:31 2017 +0000

    Automatic date update in version.in

commit 4a8f9fc2b2467ae8bcfb75392c10fde5a0053740
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 23 14:44:04 2017 -0700

    i386: Don't add elf32_x86_64 to supported emulations
    
    For 32-bit BFD, since elf64-x86-64.o isn't compiled in, "-m elf32_x86_64"
    never worked.  Don't add elf32_x86_64 to supported emulations with 32-bit
    BFD.
    
    	* configure.tgt (i[3-7]86-*-linux-*): Move elf32_x86_64 from
    	targ_extra_libpath to targ64_extra_libpath.

commit 2739ef6db8e9a152f7b0ef8d012b394eb41a5dc5
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Mon Oct 23 13:09:26 2017 -0700

    Add missing ChangeLog entries

commit d55cf23a7208fb7065b50dffb6f409898a14e543
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 23 10:34:25 2017 -0700

    Revert "Apply "ELF: Call check_relocs after opening all inputs""
    
    This reverts commit 0c52bddddfd2afee0e650854fc2d8abf903199fc.
    
    It has been checked into master branch.

commit 7a6d7aa5ac545d64be978950425c514af0162669
Merge: 0c52bdd 66cae56
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 23 10:33:46 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 66cae56016a12f7cbdc94be6f82c1cad1c59b521
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Oct 23 18:16:49 2017 +0100

    Make sure that undefined symbols added to the linker command line via the -u option appear in the output executable, if they have not been resolved.
    
    	PR 22319
    bfd	* elflink.c (elf_link_output_extsym): Keep global undefined
    	symbols if they have been marked as needed.
    
    ld	* testsuite/ld-elf/pr22310.s: New test source file.
    	* testsuite/ld-elf/pr22310.d: New test driver.
    	* testsuite/ld-mmix/undef-3.d: Update expected output from readelf.

commit fe4e2a3c9281851c9da99a6e36a2bc96e4279476
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Mon Oct 23 19:28:46 2017 +0300

    Fix the master due to bad regenerated files
    
    	* i386-init.h: Regenerate
    	* i386-tbl.h: Likewise

commit defc8e2b3576c28fd5651763348ae23c18a94170
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Oct 23 15:39:46 2017 +0100

    MIPS: Preset EF_MIPS_ABI2 with n32 ELF objects
    
    Fix a bug in MIPS n32 ELF object file generation and make such objects
    consistent with the n32 BFD requested, by presetting the EF_MIPS_ABI2
    flag in the `e_flags' member of the newly created ELF file header, as it
    is this flag that tells n32 objects apart from o32 objects.
    
    This flag will then stay set through to output file generation for
    writers such as GAS or GDB's `generate-core-file' command.  Readers will
    overwrite the whole of `e_flags' along with the rest of the ELF file
    header in `elf_swap_ehdr_in' and then verify in `mips_elf_n32_object_p'
    that the flag is still set before accepting an input file as an n32
    object.
    
    The issue was discovered with GDB's `generate-core-file' command making
    o32 core files out of n32 debuggees.
    
    	bfd/
    	* elfn32-mips.c (mips_elf_n32_mkobject): New prototype and
    	function.
    	(bfd_elf32_mkobject): Use `mips_elf_n32_mkobject' rather than
    	`_bfd_mips_elf_mkobject'.
    
    	gas/
    	* config/tc-mips.c (mips_elf_final_processing): Don't set
    	EF_MIPS_ABI2 in `e_flags'.

commit ee6872beb1912af41a506c8aea34af7d2f873d04
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 23:56:30 2017 +0300

    Enable Intel AVX512_BITALG instructions.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add .avx512_bitalg.
    	(cpu_noarch): noavx512_bitalg.
    	* doc/c-i386.texi: Document .avx512_bitalg, noavx512_bitalg.
    	* testsuite/gas/i386/i386.exp: Add AVX512_BITALG tests.
    	* testsuite/gas/i386/avx512f_bitalg-intel.d: New test.
    	* testsuite/gas/i386/avx512f_bitalg.d: Likewise.
    	* testsuite/gas/i386/avx512f_bitalg.s: Likewise.
    	* testsuite/gas/i386/avx512vl_bitalg-intel.d: Likewise.
    	* testsuite/gas/i386/avx512vl_bitalg.d: Likewise.
    	* testsuite/gas/i386/avx512vl_bitalg.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_bitalg-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_bitalg.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_bitalg.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_bitalg-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_bitalg.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_bitalg.s: Likewise.
    
    opcodes/
    
    	* i386-dis.c (enum): Add PREFIX_EVEX_0F3854, PREFIX_EVEX_0F388F.
    	(enum): Add EVEX_W_0F3854_P_2.
    	* i386-dis-evex.h (evex_table): Updated.
    	* i386-gen.c (cpu_flag_init): Add CPU_AVX512_BITALG,
    	CPU_ANY_AVX512_BITALG_FLAGS. Update CPU_ANY_AVX512F_FLAGS.
    	(cpu_flags): Add CpuAVX512_BITALG.
    	* i386-opc.h (enum): Add CpuAVX512_BITALG.
    	(i386_cpu_flags): Add cpuavx512_bitalg..
    	* i386-opc.tbl: Add Intel AVX512_BITALG instructions.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Likewise.

commit 8cfcb7659cb844dff00efbbb644c15b650fb7e8b
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 23:52:52 2017 +0300

    Enable Intel AVX512_VNNI instructions.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add .avx512_vnni.
    	(cpu_noarch): Add noavx512_vnni.
    	* doc/c-i386.texi: Document .avx512_vnni.
    	* testsuite/gas/i386/i386.exp: Add AVX512_VNNI tests.
    	* testsuite/gas/i386/avx512vnni-intel.d: New test.
    	* testsuite/gas/i386/avx512vnni.d: Likewise.
    	* testsuite/gas/i386/avx512vnni.s: Likewise.
    	* testsuite/gas/i386/avx512vnni_vl-intel.d: Likewise.
    	* testsuite/gas/i386/avx512vnni_vl.d: Likewise.
    	* testsuite/gas/i386/avx512vnni_vl.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni_vl-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni_vl.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vnni_vl.s: Likewise.
    
    opcodes/
    
    	* i386-dis.c (enum): Add PREFIX_EVEX_0F3850, PREFIX_EVEX_0F3851.
    	* i386-dis-evex.h (evex_table): Updated.
    	* i386-gen.c (cpu_flag_init): Add CPU_AVX512_VNNI,
    	CPU_ANY_AVX512_VNNI_FLAGS. Update CPU_ANY_AVX512F_FLAGS.
    	(cpu_flags): Add CpuAVX512_VNNI.
    	* i386-opc.h (enum): Add CpuAVX512_VNNI.
    	(i386_cpu_flags): Add cpuavx512_vnni.
    	* i386-opc.tbl Add Intel AVX512_VNNI instructions.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Likewise.

commit ff1982d53a1fba573e7f9a3b455f7644440cb336
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 23:42:40 2017 +0300

    Enable Intel VPCLMULQDQ instruction.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add VPCLMULQDQ.
    	* doc/c-i386.texi: Document VPCLMULQDQ.
    	* testsuite/gas/i386/i386.exp: Run VPCLMULQDQ tests.
    	* testsuite/gas/i386/avx512f_vpclmulqdq-intel.d: New test.
    	* testsuite/gas/i386/avx512f_vpclmulqdq-wig.s: Ditto.
    	* testsuite/gas/i386/avx512f_vpclmulqdq-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/avx512f_vpclmulqdq-wig1.d: Ditto.
    	* testsuite/gas/i386/avx512f_vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/avx512f_vpclmulqdq.s: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq-intel.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq-wig.s: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq-wig1.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vpclmulqdq.s: Ditto.
    	* testsuite/gas/i386/vpclmulqdq-intel.d: Ditto.
    	* testsuite/gas/i386/vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/vpclmulqdq.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq-wig.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq-wig1.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vpclmulqdq.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq-wig.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq-wig1.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vpclmulqdq.s: Ditto.
    	* testsuite/gas/i386/x86-64-vpclmulqdq-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-vpclmulqdq.d: Ditto.
    	* testsuite/gas/i386/x86-64-vpclmulqdq.s: Ditto.
    
    opcodes/
    
    	* i386-dis.c (enum): Add PREFIX_EVEX_0F3A44.
    	(enum): Remove VEX_LEN_0F3A44_P_2.
    	(vex_len_table): Ditto.
    	(enum): Remove VEX_W_0F3A44_P_2.
    	(vew_w_table): Ditto.
    	(prefix_table): Adjust instructions (see prefixes above).
    	* i386-dis-evex.h (evex_table):
    	Add new instructions (see prefixes above).
    	* i386-gen.c (cpu_flag_init): Add VPCLMULQDQ.
    	(bitfield_cpu_flags): Ditto.
    	* i386-opc.h (enum): Ditto.
    	(i386_cpu_flags): Ditto.
    	(CpuUnused): Comment out to avoid zero-width field problem.
    	* i386-opc.tbl (vpclmulqdq): New instruction.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Ditto.

commit 8dcf1fadf2b0763962639fc5dcedc1892e502265
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 23:35:45 2017 +0300

    Enable Intel VAES instructions.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add VAES.
    	* doc/c-i386.texi: Document VAES.
    	* testsuite/gas/i386/i386.exp: Run VAES tests.
    	* testsuite/gas/i386/avx512f_vaes-intel.d: New test.
    	* testsuite/gas/i386/avx512f_vaes-wig.s: Ditto.
    	* testsuite/gas/i386/avx512f_vaes-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/avx512f_vaes-wig1.d: Ditto.
    	* testsuite/gas/i386/avx512f_vaes.d: Ditto.
    	* testsuite/gas/i386/avx512f_vaes.s: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes-intel.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes-wig.s: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes-wig1.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes.d: Ditto.
    	* testsuite/gas/i386/avx512vl_vaes.s: Ditto.
    	* testsuite/gas/i386/vaes-intel.d: Ditto.
    	* testsuite/gas/i386/vaes.d: Ditto.
    	* testsuite/gas/i386/vaes.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes-wig1.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512f_vaes.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig.s: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig1-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes-wig1.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes.d: Ditto.
    	* testsuite/gas/i386/x86-64-avx512vl_vaes.s: Ditto.
    	* testsuite/gas/i386/x86-64-vaes-intel.d: Ditto.
    	* testsuite/gas/i386/x86-64-vaes.d: Ditto.
    	* testsuite/gas/i386/x86-64-vaes.s: Ditto.
    
    opcodes/
    
    	* i386-dis.c (enum): Add PREFIX_EVEX_0F38DC, PREFIX_EVEX_0F38DD,
    	PREFIX_EVEX_0F38DE, PREFIX_EVEX_0F38DF.
    	(enum): Remove VEX_LEN_0F38DC_P_2, VEX_LEN_0F38DD_P_2,
    	VEX_LEN_0F38DE_P_2, VEX_LEN_0F38DF_P_2.
    	(vex_len_table): Ditto.
    	(enum): Remove VEX_W_0F38DC_P_2, VEX_W_0F38DD_P_2,
    	VEX_W_0F38DE_P_2, VEX_W_0F38DF_P_2.
    	(vew_w_table): Ditto.
    	(prefix_table): Adjust instructions (see prefixes above).
    	* i386-dis-evex.h (evex_table):
    	Add new instructions (see prefixes above).
    	* i386-gen.c (cpu_flag_init): Add VAES.
    	(bitfield_cpu_flags): Ditto.
    	* i386-opc.h (enum): Ditto.
    	(i386_cpu_flags): Ditto.
    	* i386-opc.tbl (vaes{enc,dec}{last,}): New instructions.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Ditto.

commit 48521003d5300e1390d78dbbcae83febe5808aaf
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 23:26:11 2017 +0300

    Enable Intel GFNI instructions.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add .gfni.
    	* doc/c-i386.texi: Document .gfni.
    	* testsuite/gas/i386/i386.exp: Add GFNI tests.
    	* testsuite/gas/i386/avx.s: New GFNI test.
    	* testsuite/gas/i386/x86-64-avx.s: Likewise.
    	* testsuite/gas/i386/avx.d: Adjust.
    	* testsuite/gas/i386/avx-intel.d: Likewise
    	* testsuite/gas/i386/ilp32/x86-64-avx-intel.d: Likewise.
    	* testsuite/gas/i386/ilp32/x86-64-avx.d: Likewise.
    	* testsuite/gas/i386/avx512f_gfni-intel.d: New test.
    	* testsuite/gas/i386/avx512f_gfni.d: Likewise.
    	* testsuite/gas/i386/avx512f_gfni.s: Likewise.
    	* testsuite/gas/i386/avx512vl_gfni-intel.d: Likewise.
    	* testsuite/gas/i386/avx512vl_gfni.d: Likewise.
    	* testsuite/gas/i386/avx512vl_gfni.s: Likewise.
    	* testsuite/gas/i386/gfni-intel.d: Likewise.
    	* testsuite/gas/i386/gfni.d: Likewise.
    	* testsuite/gas/i386/gfni.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_gfni-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_gfni.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512f_gfni.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_gfni-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_gfni.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vl_gfni.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx_gfni-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx_gfni.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx_gfni.s: Likewise.
    	* testsuite/gas/i386/x86-64-gfni-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-gfni.d: Likewise.
    	* testsuite/gas/i386/x86-64-gfni.s: Likewise.
    
    opcodes/
    
    	* i386-dis.c (enum): Add PREFIX_0F38CF, PREFIX_0F3ACE, PREFIX_0F3ACF,
    	PREFIX_VEX_0F38CF, PREFIX_VEX_0F3ACE, PREFIX_VEX_0F3ACF,
    	PREFIX_EVEX_0F38CF, PREFIX_EVEX_0F3ACE, PREFIX_EVEX_0F3ACF.
    	(enum): Add VEX_W_0F38CF_P_2, VEX_W_0F3ACE_P_2, VEX_W_0F3ACF_P_2,
    	EVEX_W_0F3ACE_P_2, EVEX_W_0F3ACF_P_2.
    	(prefix_table): Updated (see prefixes above).
    	(three_byte_table): Likewise.
    	(vex_w_table): Likewise.
    	* i386-dis-evex.h: Likewise.
    	* i386-gen.c (cpu_flag_init): Add CPU_GFNI_FLAGS, CpuGFNI.
    	(cpu_flags): Add CpuGFNI.
    	* i386-opc.h (enum): Add CpuGFNI.
    	(i386_cpu_flags): Add cpugfni.
    	* i386-opc.tbl: Add Intel GFNI instructions.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Likewise.

commit 53467f5707ec796c0490d55e74854258a78013f8
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Oct 20 22:52:59 2017 +0300

    Enable Intel AVX512_VBMI2 instructions.
    
    Intel has disclosed a set of new instructions. The spec is
    https://software.intel.com/sites/default/files/managed/c5/15/architecture-instruction-set-extensions-programming-reference.pdf
    
    gas/
    
    	* config/tc-i386.c (cpu_arch): Add .avx512_vbmi2.
    	(cpu_noarch): noavx512_vbmi2.
    	* doc/c-i386.texi: Document .avx512_vbmi2, noavx512_vbmi2.
    	* testsuite/gas/i386/i386.exp: Add AVX512_VBMI2 tests.
    	* testsuite/gas/i386/avx512vbmi2-intel.d: New test.
    	* testsuite/gas/i386/avx512vbmi2.d: Likewise.
    	* testsuite/gas/i386/avx512vbmi2.s: Likewise.
    	* testsuite/gas/i386/avx512vbmi2_vl-intel.d: Likewise.
    	* testsuite/gas/i386/avx512vbmi2_vl.d: Likewise.
    	* testsuite/gas/i386/avx512vbmi2_vl.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2.s: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2_vl-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2_vl.d: Likewise.
    	* testsuite/gas/i386/x86-64-avx512vbmi2_vl.s: Likewise.
    
    opcodes/
    
    	* i386-dis.c (enum): Add b_scalar_mode, w_scalar_mode.
    	Define EXbScalar and EXwScalar for OP_EX.
    	(enum): Add PREFIX_EVEX_0F3862, PREFIX_EVEX_0F3863,
    	PREFIX_EVEX_0F3870, PREFIX_EVEX_0F3871, PREFIX_EVEX_0F3872,
    	PREFIX_EVEX_0F3873, PREFIX_EVEX_0F3A70, PREFIX_EVEX_0F3A71,
    	PREFIX_EVEX_0F3A72, PREFIX_EVEX_0F3A73.
    	(enum): Add EVEX_W_0F3862_P_2, EVEX_W_0F3863_P_2,
    	EVEX_W_0F3870_P_2, EVEX_W_0F3871_P_2, EVEX_W_0F3872_P_2,
    	EVEX_W_0F3873_P_2, EVEX_W_0F3A70_P_2, EVEX_W_0F3A71_P_2,
    	EVEX_W_0F3A72_P_2, EVEX_W_0F3A73_P_2.
    	(intel_operand_size): Handle b_scalar_mode and w_scalar_mode.
    	(OP_E_memory): Likewise.
    	* i386-dis-evex.h: Updated.
    	* i386-gen.c (cpu_flag_init): Add CPU_AVX512_VBMI2,
    	CPU_ANY_AVX512_VBMI2_FLAGS. Update CPU_ANY_AVX512F_FLAGS.
    	(cpu_flags): Add CpuAVX512_VBMI2.
    	* i386-opc.h (enum): Add CpuAVX512_VBMI2.
    	(i386_cpu_flags): Add cpuavx512_vbmi2.
    	* i386-opc.tbl: Add Intel AVX512_VBMI2 instructions.
    	* i386-init.h: Regenerate.
    	* i386-tbl.h: Likewise.

commit f6af9f3428fa86030ba8ecd2da7d11e4ee1ed989
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Oct 23 00:00:26 2017 +0000

    Automatic date update in version.in

commit 67c04379acee0da10f148edc3d8903859d928f68
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Sun Oct 22 13:32:44 2017 +0200

    Fix spurious left-over quotes from last edit.
    
    With a 32-bit bfd (default on an ILP32 system) the previous markings
    on tests *were* correct.  There, the results have been consistent
    since they were added.  The tests would appear to "spuriously" xpass
    "only" on LP64 hosts, which were not the norm in 2000.  (But, now CRIS
    requires a 64-bit BFD.)

commit 56fbd041853a4008532d20b898f5b41f594a868f
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Sun Oct 22 13:05:07 2017 +0200

    Fix gas/22304 by forcing a 64-bit bfd for cris*-*.
    
    	PR gas/22304
    	* config.bfd (cris-*-* | crisv32-*-*): Require a 64-bit BFD.

commit a73ca552593ec2903fd5485b8c8f40a250645110
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Oct 22 00:00:28 2017 +0000

    Automatic date update in version.in

commit 4e15b78be4bf008fb4f97bffbc0865dd0e4833ce
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Sat Oct 21 19:46:22 2017 +0200

    PR ld/21233
    
    * testsuite/ld-elf/shared.exp: Remove kfails.
    
    The test-cases started passing with 5c3261b0e834647c,
    "ELF: Call check_relocs after opening all inputs".
    
    The lists could now be re-concatenated (see other run_ld_link_tests
    calls in shared.exp), but are for now left separate to simplify future
    kfail/xfailing.

commit 4d3bb80e5db40cd2308157db3c446f35ae97a915
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 21 12:20:21 2017 -0400

    Add overloads of for_each_thread/find_thread that filter on pid
    
    It happens often that we want to iterate or find threads restricted to a
    given pid.  I think it's worth having an overload to help with this.
    Right now there is a single user of each of the find_thread and
    for_each_thread overload, but as we replace the usages of find_inferior
    with for_each_thread/find_thread, more usages will pop up.
    
    gdb/gdbserver/ChangeLog:
    
    	* gdbthread.h (find_thread, for_each_thread): New functions.
    	* inferiors.c (thread_of_pid): Remove.
    	(find_any_thread_of_pid): Use find_thread.
    	* linux-low.c (num_lwps): Use for_each_thread.

commit a664f67e50eff30198097d51cec0ec4690abb2a1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 21 12:06:42 2017 -0400

    Get rid of VEC (mem_region)
    
    This patch removes VEC (mem_region).  Doing so requires touching a lot
    of little things here and there.
    
    The fields in mem_attrib are now initialized during construction.  The
    values match those that were in default_mem_attrib (now removed).
    unknown_mem_attrib is also removed, and replaced with a static method
    (mem_attrib::unknown) that returns the equivalent.
    
    mem_region is initialized in a way similar to mem_region_init (now
    removed) did.
    
    I found the organization of mem_region_list and target_mem_region_list a
    bit confusing.  Sometimes mem_region_list points to the same vector as
    target_mem_region_list (and therefore does not own it), and sometimes
    (when the user manually edits the mem regions) points to another vector,
    and in this case owns it.  To avoid this ambiguity, I think it is
    simpler to have two vectors, one for target-defined regions and one for
    user-defined regions, and have mem_region_list point to one or the
    other.  There are now no vector objects dynamically allocated, both are
    static.
    
    The make-target-delegates script does not generate valid code when a
    target method returns a type with a parameter list.  For this reason, I
    created a typedef (mem_region_vector) that's only used in the target_ops
    structure.  If you speak perl, you are welcome to improve the script!
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* memattr.h: Don't include vec.h.
    	(struct mem_attrib): Initialize fields.
    	<unknown>: New static method.
    	(struct mem_region): Add constructors, operator<, initialize
    	fields.
    	* memattr.c: Include algorithm.
    	(default_mem_attrib, unknown_mem_attrib): Remove.
    	(user_mem_region_list): New global.
    	(target_mem_region_list, mem_region_list): Change type to
    	std::vector<mem_region>.
    	(mem_use_target): Now a function.
    	(target_mem_regions_valid): Change type to bool.
    	(mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
    	(require_user_regions): Adjust.
    	(require_target_regions): Adjust.
    	(create_mem_region): Adjust.
    	(lookup_mem_region): Adjust.
    	(invalidate_target_mem_regions): Adjust.
    	(mem_clear): Rename to...
    	(user_mem_clear): ... this, and adjust.
    	(mem_command): Adjust.
    	(info_mem_command): Adjust.
    	(mem_enable, enable_mem_command, mem_disable,
    	disable_mem_command): Adjust.
    	(mem_delete): Adjust.
    	(delete_mem_command): Adjust.
    	* memory-map.h (parse_memory_map): Return an std::vector.
    	* memory-map.c (parse_memory_map): Likewise.
    	(struct memory_map_parsing_data): Add constructor.
    	<memory_map>: Point to std::vector.
    	(memory_map_start_memory): Adjust.
    	(memory_map_end_memory): Adjust.
    	(memory_map_end_property): Adjust.
    	(clear_result): Remove.
    	* remote.c (remote_memory_map): Return an std::vector.
    	* target-debug.h (target_debug_print_VEC_mem_region_s__p):
    	Remove.
    	(target_debug_print_mem_region_vector): New.
    	* target-delegates.c: Regenerate.
    	* target.h (mem_region_vector): New typedef.
    	(to_memory_map): Return mem_region_vector.
    	(target_memory_map): Return an std::vector.
    	* target.c (target_memory_map): Return an std::vector.
    	(flash_erase_command): Adjust.

commit 6e17c56511104abd605bd2d122104467fc4f0089
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 21 12:06:22 2017 -0400

    Use std::string in memory_map_parsing_data
    
    Replace the fixed-size array with a string.
    
    gdb/ChangeLog:
    
    	* memory-map.c (struct memory_map_parsing_data) <property_name>:
    	Change type to std::string.
    	(memory_map_start_property): Adjust.
    	(memory_map_end_property): Adjust.

commit cfba98720f62473abc54457a376a3b7aa7ab1e40
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 21 11:27:52 2017 -0400

    Create a displaced_step_closure class hierarchy
    
    displaced_step_closure is a type defined in multiple -tdep.c files.
    Trying to xfree it from the common code (infrun.c) is a problem when we
    try to poison xfree for non-POD types.  Because there can be multiple of
    these types in the same build, this patch makes a hierarchy of classes
    with a virtual destructor.  When the common code deletes the object
    through a displaced_step_closure pointer, it will invoke the right
    destructor.
    
    The amd64 used a last-member array with a variable size.  That doesn't
    work with new, so I changed it for an std::vector.  Other architectures
    which used a simple byte buffer as a closure now use a shared
    buf_displaced_step_closure, a closure type that only contains a
    gdb::byte_vector.
    
    Reg-tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* infrun.h: Include common/byte-vector.h.
    	(struct displaced_step_closure): New struct.
    	(struct buf_displaced_step_closure): New struct.
    	* infrun.c (displaced_step_closure::~displaced_step_closure):
    	Provide default implementation.
    	(displaced_step_clear): Deallocate step closure with delete.
    	* aarch64-tdep.c (displaced_step_closure): Rename to ...
    	(aarch64_displaced_step_closure): ... this, extend
    	displaced_step_closure.
    	(aarch64_displaced_step_data) <dsc>: Change type to
    	aarch64_displaced_step_closure.
    	(aarch64_displaced_step_copy_insn): Adjust to type change, use
    	unique_ptr.
    	(aarch64_displaced_step_fixup): Add cast for displaced step
    	closure.
    	* amd64-tdep.c (displaced_step_closure): Rename to ...
    	(amd64_displaced_step_closure): ... this, extend
    	displaced_step_closure.
    	<insn_buf>: Change type to std::vector<gdb_byte>.
    	<max_len>: Remove.
    	(fixup_riprel): Change type of DSC parameter, adjust to type
    	change of insn_buf.
    	(fixup_displaced_copy): Change type of DSC parameter.
    	(amd64_displaced_step_copy_insn): Instantiate
    	amd64_displaced_step_closure.
    	(amd64_displaced_step_fixup): Add cast for closure type, adjust
    	to type change of insn_buf.
    	* arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
    	parameter DSC.
    	(arm_linux_copy_svc): Likewise.
    	(cleanup_kernel_helper_return): Likewise.
    	(arm_catch_kernel_helper_return): Likewise.
    	(arm_linux_displaced_step_copy_insn): Instantiate
    	arm_displaced_step_closure.
    	* arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
    	(displaced_read_reg): Change type of parameter DSC.
    	(branch_write_pc): Likewise.
    	(load_write_pc): Likewise.
    	(alu_write_pc): Likewise.
    	(displaced_write_reg): Likewise.
    	(arm_copy_unmodified): Likewise.
    	(thumb_copy_unmodified_32bit): Likewise.
    	(thumb_copy_unmodified_16bit): Likewise.
    	(cleanup_preload): Likewise.
    	(install_preload): Likewise.
    	(arm_copy_preload): Likewise.
    	(thumb2_copy_preload): Likewise.
    	(install_preload_reg): Likewise.
    	(arm_copy_preload_reg): Likewise.
    	(cleanup_copro_load_store): Likewise.
    	(install_copro_load_store): Likewise.
    	(arm_copy_copro_load_store) Likewise.
    	(thumb2_copy_copro_load_store): Likewise.
    	(cleanup_branch): Likewise.
    	(install_b_bl_blx): Likewise.
    	(arm_copy_b_bl_blx): Likewise.
    	(thumb2_copy_b_bl_blx): Likewise.
    	(thumb_copy_b): Likewise.
    	(install_bx_blx_reg): Likewise.
    	(arm_copy_bx_blx_reg): Likewise.
    	(thumb_copy_bx_blx_reg): Likewise.
    	(cleanup_alu_imm): Likewise.
    	(arm_copy_alu_imm): Likewise.
    	(thumb2_copy_alu_imm): Likewise.
    	(cleanup_alu_reg): Likewise.
    	(install_alu_reg): Likewise.
    	(arm_copy_alu_reg): Likewise.
    	(thumb_copy_alu_reg): Likewise.
    	(cleanup_alu_shifted_reg): Likewise.
    	(install_alu_shifted_reg): Likewise.
    	(arm_copy_alu_shifted_reg): Likewise.
    	(cleanup_load): Likewise.
    	(cleanup_store): Likewise.
    	(arm_copy_extra_ld_st): Likewise.
    	(install_load_store): Likewise.
    	(thumb2_copy_load_literal): Likewise.
    	(thumb2_copy_load_reg_imm): Likewise.
    	(arm_copy_ldr_str_ldrb_strb): Likewise.
    	(cleanup_block_load_all): Likewise.
    	(cleanup_block_store_pc): Likewise.
    	(cleanup_block_load_pc): Likewise.
    	(arm_copy_block_xfer): Likewise.
    	(thumb2_copy_block_xfer): Likewise.
    	(cleanup_svc): Likewise.
    	(install_svc): Likewise.
    	(arm_copy_svc): Likewise.
    	(thumb_copy_svc): Likewise.
    	(arm_copy_undef): Likewise.
    	(thumb_32bit_copy_undef): Likewise.
    	(arm_copy_unpred): Likewise.
    	(arm_decode_misc_memhint_neon): Likewise.
    	(arm_decode_unconditional): Likewise.
    	(arm_decode_miscellaneous): Likewise.
    	(arm_decode_dp_misc): Likewise.
    	(arm_decode_ld_st_word_ubyte): Likewise.
    	(arm_decode_media): Likewise.
    	(arm_decode_b_bl_ldmstm): Likewise.
    	(arm_decode_ext_reg_ld_st): Likewise.
    	(thumb2_decode_dp_shift_reg): Likewise.
    	(thumb2_decode_ext_reg_ld_st): Likewise.
    	(arm_decode_svc_copro): Likewise.
    	(thumb2_decode_svc_copro): Likewise.
    	(install_pc_relative): Likewise.
    	(thumb_copy_pc_relative_16bit): Likewise.
    	(thumb_decode_pc_relative_16bit): Likewise.
    	(thumb_copy_pc_relative_32bit): Likewise.
    	(thumb_copy_16bit_ldr_literal): Likewise.
    	(thumb_copy_cbnz_cbz): Likewise.
    	(thumb2_copy_table_branch): Likewise.
    	(cleanup_pop_pc_16bit_all): Likewise.
    	(thumb_copy_pop_pc_16bit): Likewise.
    	(thumb_process_displaced_16bit_insn): Likewise.
    	(decode_thumb_32bit_ld_mem_hints): Likewise.
    	(thumb_process_displaced_32bit_insn): Likewise.
    	(thumb_process_displaced_insn): Likewise.
    	(arm_process_displaced_insn): Likewise.
    	(arm_displaced_init_closure): Likewise.
    	(arm_displaced_step_fixup): Add cast for closure.
    	* arm-tdep.h: Include infrun.h.
    	(displaced_step_closure): Rename to ...
    	(arm_displaced_step_closure): ... this, extend
    	displaced_step_closure.
    	<u::svc::copy_svc_os>: Change type of parameter DSC.
    	<cleanup>: Likewise.
    	(arm_process_displaced_insn): Likewise.
    	(arm_displaced_init_closure): Likewise.
    	(displaced_read_reg): Likewise.
    	(displaced_write_reg): Likewise.
    	* i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
    	Adjust.
    	* i386-tdep.h: Include infrun.h.
    	(i386_displaced_step_closure): New typedef.
    	* i386-tdep.c (i386_displaced_step_copy_insn): Use
    	i386_displaced_step_closure.
    	(i386_displaced_step_fixup): Adjust.
    	* rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
    	(ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
    	and unique_ptr.
    	(ppc_displaced_step_fixup): Adjust.
    	* s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
    	(s390_displaced_step_copy_insn): Use s390_displaced_step_closure
    	and unique_ptr.
    	(s390_displaced_step_fixup): Adjust.

commit b392b304b92ddd81ecfb4902c3fc3501ff90e999
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 21 10:15:48 2017 -0400

    Remove leftover declarations in interps.h
    
    The corresponding definitions have already been removed.
    
    gdb/ChangeLog:
    
    	* interps.h (interp_resume, interp_suspend, interp_set_temp):
    	Remove declarations.

commit 881b33774d75e632ed9099210c41f16c33dc7db8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Oct 21 00:00:31 2017 +0000

    Automatic date update in version.in

commit d63613596fa297dd19781eec61269186653f544d
Author: Sriraman Tallam <tmsriram@google.com>
Date:   Fri Oct 20 11:21:45 2017 -0700

    Fix ChangeLog entry.

commit 3b4190ccb31be262a5aac78238e6d659746f1f0f
Author: Sriraman Tallam <tmsriram@google.com>
Date:   Fri Oct 20 11:00:28 2017 -0700

    New gold linker option -z,text-unlikely-segment.
    
    2017-10-04  Sriraman Tallam  <tmsriram@google.com>
    
    	* options.h (-z,text_unlikely_segment): New option.
    	* layout.cc (Layout::layout): Create new output section
    	for .text.unlikely sections with the new option.
    	(Layout::segment_precedes): Check for the new option
    	when segment flags match.
    	* testsuite/text_unlikely_segment.cc: New test source.
    	* testsuite/text_unlikely_segment.sh: New test script.
    	* testsuite/Makefile.am (text_unlikely_segment): New test.
    	* testsuite/Makefile.in: Regenerate.

commit f3012016f008030b48597b578a5fb1e550907374
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 20 09:47:08 2017 -0700

    Add a compile-time test for PR ld/22269
    
    This compile-time test requires a target C compiler to run.  It fails
    on many targets where ELF backend linkers fail to check undefined weak
    symbol in static PIE via UNDEFWEAK_NO_DYNAMIC_RELOC.
    
    	PR ld/22269
    	* testsuite/ld-elf/pr22269-1.rd: New file.
    	* testsuite/ld-elf/pr22269-1.c: Likewise.
    	* testsuite/ld-elf/shared.exp: Run pr22269-1.

commit d5833c62d93e8176b70e8509ab36cc38801c3ebd
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 15 11:31:46 2017 -0600

    Use std::vector in gdb_bfd_data
    
    This changes gdb_bfd_data to use std::vector rather than VEC.
    
    ChangeLog
    2017-10-20  Tom Tromey  <tom@tromey.com>
    
    	* gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
    	std::vector.
    	(gdb_bfd_record_inclusion): Update.
    	(bfdp): Remove typedef.

commit 06d5bbc8e5f7541b13509c33b8b3eb8afac27b2f
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 15 11:23:22 2017 -0600

    Use "new" to allocate gdb_bfd_data
    
    This changes gdb_bfd_data to be allocated with new and destroyed with
    delete.
    
    ChangeLog
    2017-10-20  Tom Tromey  <tom@tromey.com>
    
    	* gdb_bfd.c (gdb_bfd_ref): Use new.
    	(struct gdb_bfd_data): Add constructor, destructor, and member
    	initializers.
    	(gdb_bfd_unref): Use delete.

commit 2712ce2e659f82168154d4533f53d2963ae82571
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 15 11:13:29 2017 -0600

    Introduce new_bfd_ref
    
    This introduces a helper function, new_bfd_ref, that calls gdb_bfd_ref
    and returns a gdb_bfd_ref_ptr.  Then it updates several places to use
    this.
    
    ChangeLog
    2017-10-20  Tom Tromey  <tom@tromey.com>
    
    	* exec.c (exec_file_attach): Use new_bfd_ref.
    	* symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
    	* gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
    	(gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
    	new_bfd_ref.
    	* gdb_bfd.h (new_bfd_ref): New function.

commit 15763a09d4aea85fc3153d6746c040dd48565637
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 20 15:33:57 2017 +0100

    Fix 'gdb.base/quit.exp hangs forever' if the test fails
    
    The [wait -i $gdb_spawn_id] in the test is dangerous in the sense that
    it won't be subject to timeout logic.  So if GDB fails quiting, this
    testcase hangs forever, hanging the test run with it.  See:
      https://sourceware.org/ml/gdb-patches/2016-10/msg00728.html
    
    Instead of 'wait'ing directly, use gdb_test_multiple and expect 'eof'.
    
    Tested that the testcase no longer hangs by hacking the test to send
    "info threads" instead of "quit".
    
    Tested with
      --target_board={unix, native-gdbserver,native-extended-gdbserver}
    and tested with
      --host_board=local-remote-host
    as well.
    
    gdb/testsuite/ChangeLog:
    2017-10-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/quit.exp: Use gdb_test_multiple and expect 'eof' before
    	'wait -i'.  Use gdb_assert and remote_close.

commit fcc8fb2f3de370f2def30bb18c98243ed4f3fb8c
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 20 14:47:24 2017 +0100

    Fix gdb.gdb/ selftest tests when testing optimized GDB builds
    
    After commit bf4692711232 ("Eliminate catch_errors"), GCC started
    inlining captured_command_loop in captured_main.  And setting a
    breakpoint on captured_command_loop makes the inferior GDB stop in
    captured_main, _after_ captured_command_loop's call to
    interp_pre_command_loop, which prints the inferior GDB's prompt, has
    already executed, confusing the gdb.gdb/ selftest tests:
    
      (gdb) FAIL: gdb.gdb/complaints.exp: run until breakpoint at captured_command_loop
      WARNING: Couldn't test self
    
    Debugging GDB with GDB manually, we see:
    
      (top-gdb) b captured_command_loop
      Breakpoint 1 at 0x71ee60: file src/gdb/main.c, line 324.
      (top-gdb) r
      [....]
      (gdb)                  <<<<<< PROMPT HERE
      Thread 1 "gdb" hit Breakpoint 1, captured_main (data=<optimized out>) at src/gdb/main.c:1147
      1147              captured_command_loop ();
      (top-gdb)
    
    Note the stop at 'captured_main', and the "PROMPT HERE" line.  That
    prompt does not show up when debugging a non-optimized build of GDB.
    
    Fix this by preventing inlining of captured_command_loop.
    
    Ref: https://sourceware.org/ml/gdb-patches/2017-10/msg00522.html
    
    gdb/ChangeLog:
    2017-10-20  Pedro Alves  <palves@redhat.com>
    
    	* main.c (captured_command_loop): Add attribute noinline.

commit 808811a36951c6bc2ee9d56124603d7ef88a019e
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Oct 20 11:45:19 2017 +0100

    Improve handling of REPT pseudo op with a negative count.
    
    	PR 22324
    	* read.c (s_rept): Use size_t type for count parameter.
    	(do_repeat): Change type of count parameter to size_t.
    	Issue an error is the count parameter is negative.
    	(do_repeat_with_expression): Likewise.
    	* read.h: Update prototypes for do_repeat and
    	do_repeat_with_expression.
    	* doc/as.texinfo (Rept): Document that a zero count is allowed but
    	negative counts are not.
    	* config/tc-rx.c (rx_rept): Use size_t type for count parameter.
    	* config/tc-tic54x.c (tic54x_loop): Cast count parameter to size_t
    	type.
    	* testsuite/gas/macros/end.s: Add a test using a negative repeat
    	count.
    	* testsuite/gas/macros/end.l: Add expected error message.

commit 36862fc052b7006c78024952c4024c60b8a2733f
Author: Umesh Kalappa <ukalappa@cisco.com>
Date:   Thu Oct 19 20:53:14 2017 -0700

    Implement BE8 support for ARM.
    
    gold/
    	* arm.cc (Stub::do_fixed_endian_write):Far call stubs support for arm
    	in the be8 mode.
    	* testsuite/Makefile.am: New test cases.
    	* testsuite/Makefile.in: Regenerate.
    	* testsuite/arm_farcall_arm_arm_be8.sh: New script for arm to arm far
    	call stubs.
    	* testsuite/arm_farcall_thumb_thumb_be8.sh: New script for thumb to
    	thumb far call stubs.

commit 4c2287b0bdfbed95d37d09222fc253f4c5086ada
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Oct 19 22:07:15 2017 -0400

    Get rid of VEC(interp_factory_p)
    
    Replace it with an std::vector.
    
    gdb/ChangeLog:
    
    	* interps.c (struct interp_factory): Add constructor.
    	(interp_factory_p): Remove typedef.
    	(DEF_VEC_P(interp_factory_p)): Remove.
    	(interpreter_factories): Change type to std::vector.
    	(interp_factory_register): Adjust.
    	(interp_lookup): Adjust.
    	(interpreter_completer): Adjust.

commit b5f6e7409243ca9b016753966a6404cdcfd41d95
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Oct 20 00:00:28 2017 +0000

    Automatic date update in version.in

commit 3d415c26bad3a15eed00d2ddf85c4268df77a4cc
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 16 17:36:32 2017 -0600

    Remove cleanups from break-catch-syscall.c
    
    This removes the remaining cleanups from break-catch-syscall.c by
    storing temporary strings in a vector.
    
    ChangeLog
    2017-10-19  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-syscall.c (catch_syscall_completer): Use
    	std::string, gdb::unique_xmalloc_ptr.

commit 395423c418da2cba1240e39ae944510fe9ffcccc
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 16 17:27:21 2017 -0600

    Remove cleanup from call_function_by_hand_dummy
    
    This changes call_function_by_hand_dummy to use std::string, removing
    a cleanup.
    
    ChangeLog
    2017-10-19  Tom Tromey  <tom@tromey.com>
    
    	* infcall.c (call_function_by_hand_dummy): Use std::string.

commit 54f70bc14586878ee14891ecb11efb8a90405874
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 16 17:26:09 2017 -0600

    Remove cleanups from prepare_execute_command
    
    This changes prepare_execute_command to return a scoped_value_mark
    rather than a cleanup.
    
    ChangeLog
    2017-10-19  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (mi_cmd_execute): Update.
    	* top.h (prepare_execute_command): Return scoped_value_mark.
    	* value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
    	Add move constructor.
    	* top.c (prepare_execute_command): Return scoped_value_mark.
    	(execute_command): Update.

commit 49a4ce2eae231ae627ab9a312256c6e402b5a27e
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Fri Oct 13 15:22:17 2017 +0100

    gdb: Remove hard-coded line number from test
    
    Removes the use of a hard-coded line number from a test.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.linespec/ls-errs.exp (do_test): Update comment, use line
    	number from variable rather than hard-coded.

commit 63929e843d54d327676bed4d86dad280f4675547
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 19 18:12:03 2017 +0100

    Fix build breakage in gdb/xml-support.c
    
    The buildbots are showing that the previous change to
    xml_fetch_content_from_file causes __wur warnings/errors:
    
      ../../binutils-gdb/gdb/xml-support.c: In function gdb::unique_xmalloc_ptr<char> xml_fetch_content_from_file(const char*, void*):
      ../../binutils-gdb/gdb/xml-support.c:1028:43: error: ignoring return value of size_t fread(void*, size_t, size_t, FILE*), declared with attribute warn_unused_result [-Werror=unused-result]
         fread (text.get (), 1, len, file.get ());
    					     ^
    
    This commit fixes it.
    
    gdb/ChangeLog:
    2017-10-19  Pedro Alves  <palves@redhat.com>
    
    	* xml-support.c (xml_fetch_content_from_file): Check fread's
    	return.

commit 9d06997adb88a71487a2f5627de032c6fb994604
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Thu May 18 18:13:09 2017 -0700

    RISC-V: Relax RISCV_PCREL_* to RISCV_GPREL_*
    
    In the medany code model the compiler generates PCREL_HI20+PCREL_LO12
    relocation pairs against local symbols because HI20+LO12 relocations
    can't reach high addresses.  We relax HI20+LO12 pairs to GPREL
    relocations when possible, which is an important optimization for
    Dhrystone.  Without this commit we are unable to relax
    PCREL_HI20+PCREL_LO12 pairs to GPREL when possible, causing a 10%
    permormance hit on Dhrystone on Rocket.
    
    Note that we'll now relax
    
      la gp, __global_pointer$
    
    to
    
      mv gp, gp
    
    which probably isn't what you want in your entry code.  Users who want
    gp-relative symbols to continue to resolve should add ".option norelax"
    accordingly.  Due to this, the assembler now pairs PCREL relocations
    with RELAX relocations when they're expected to be relaxed just like
    every other relaxable relocation.
    
    bfd/ChangeLog
    
    2017-10-19  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * elfnn-riscv.c (riscv_pcgp_hi_reloc): New structure.
            (riscv_pcgp_lo_reloc): Likewise.
            (riscv_pcgp_relocs): Likewise.
            (riscv_init_pcgp_relocs): New function.
            (riscv_free_pcgp_relocs): Likewise.
            (riscv_record_pcgp_hi_reloc): Likewise.
            (riscv_record_pcgp_lo_reloc): Likewise.
            (riscv_delete_pcgp_hi_reloc): Likewise.
            (riscv_use_pcgp_hi_reloc): Likewise.
            (riscv_record_pcgp_lo_reloc): Likewise.
            (riscv_find_pcgp_lo_reloc): Likewise.
            (riscv_delete_pcgp_lo_reloc): Likewise.
            (_bfd_riscv_relax_pc): Likewise.
            (_bfd_riscv_relax_section): Handle R_RISCV_PCREL_* relocations
            via the new functions above.
    
    gas/ChangeLog
    
    2017-10-19  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * config/tc-riscv.c (md_apply_fix): Mark
            BFD_RELOC_RISCV_PCREL_HI20 as relaxable when relaxations are
            enabled.

commit ff6f4d9b2d6c25ac144bab869df6e3d6123a6f8f
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Thu May 18 18:08:25 2017 -0700

    RISC-V: Add R_RISCV_DELETE, which marks bytes for deletion
    
    We currently delete bytes by shifting an entire BFD backwards to
    overwrite the bytes we no longer need.  The result is that relaxing a
    BFD is quadratic time.
    
    This patch adds an additional relocation that specifies a byte range
    that will be deleted from the final object file, and adds a relaxation
    pass (between the existing passes that delete bytes and the alignment
    pass) that actually deletes the bytes.  Note that deletion is still
    quadratic time, and nothing uses R_RISCV_DELETE yet.
    
    I've been meaning to go convert all the other relaxations to use
    R_RISCV_DELETE and then make it faster, but this patch has been sitting
    around for months so it looks like that won't happen for a bit.  The
    PCREL->GPREL relaxation that comes next uses this, and since we've been
    using these two patches out of tree since I wrote them months ago I
    figure it's better to just get them in now.  I (or someone else :)) can
    convert all the relocations later...
    
    R_RISCV_DELETE will never be emitted into ELF objects, so therefor isn't
    exposed to the rest of binutils.  As such, we're not considering this as
    part of the ABI.
    
    bfd/ChangeLog
    
    2017-10-19  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * elfnn-riscv (R_RISCV_DELETE): New define.
            (_bfd_riscv_relax_delete): New function.
            (perform_relocation): Handle R_RISCV_DELETE.
            (_bfd_riscv_relax_section): Likewise.
    
    ld/ChangeLog
    
    2017-10-19  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * emultempl/riscvelf.em (riscv_elf_before_allocation): Add a
            third relaxation pass.

commit 95e42ad4425f0ab0ebfb90035a891be576f9fca4
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 19 16:21:51 2017 +0100

    Fix the AVR assembler so that it will correctly issue warnings about skipped instructions even if subsections are used.
    
    	PR 21621
    	* config/tc-avr.h (struct avr_frag_data): Add prev_opcode field.
    	(TC_FRAG_INIT): Define.
    	(avr_frag_init): Add prototype.
    	* config/tc-avr.c (avr_frag_init): New function.
    	(avr_operands): Replace static local 'prev' variable with
    	prev_opcode field in current frag.
    	* testsuite/gas/avr/pr21621.s: New test source file.
    	* testsuite/gas/avr/pr21621.d: New test driver file.
    	* testsuite/gas/avr/pr21621.s: New test error output file.

commit a75868f50ba72e9aa906702ae038fa29feda7743
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 19 16:00:21 2017 +0100

    Fix inferior deadlock with "target remote | CMD"
    
    Comparing test results between
    
      --target_board=native-gdbserver
      --target_board=native-stdio-gdbserver
    
    I noticed that gdb.base/bigcore.exp is failing with native-stdio-gdbserver:
    
      Running src/gdb/testsuite/gdb.base/bigcore.exp ...
      FAIL: gdb.base/bigcore.exp: continue (timeout)
      ...
    
    The problem is that:
    
      1. When debugging with "target remote | CMD", the inferior's
         stdout/stderr streams are connected to a pipe.
    
      2. The bigcore.c program prints a lot to the screen before it
         reaches the breakpoint location that the "continue" shown above
         wants to reach.
    
      3. GDB is not flushing the inferior's output pipe while the inferior
         is running.
    
      4. The pipe becomes full.
    
      5. The inferior thus deadlocks.
    
    The bug is #3 above, which is what this commit fixes.  A new test is
    added, that specifically exercises this scenario.  The test fails
    before the fix, and passes after, and gdb.base/bigcore.exp also starts
    passing.
    
    gdb/ChangeLog:
    2017-10-19  Pedro Alves  <palves@redhat.com>
    
    	* ser-base.c (ser_base_read_error_fd): Delete the file handler if
    	async.
    	(handle_error_fd): New function.
    	(ser_base_async): Add/delete an event loop file handler for
    	error_fd.
    
    gdb/testsuite/ChangeLog:
    2017-10-19  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/long-inferior-output.c: New file.
    	* gdb.base/long-inferior-output.exp: New file.

commit 2edf834e298b15c882678db22e86745f701807fa
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 19 15:25:59 2017 +0100

    xml_fetch_content_from_file: Read in whole file in one go
    
    There doesn't seem to be a good reason we're reading the file one
    chunk at a time.
    
    gdb/ChangeLog:
    2017-10-19  Pedro Alves  <palves@redhat.com>
    
    	* xml-support.c (xml_fetch_content_from_file): Don't read in
    	chunks.  Instead use fseek to determine the file's size, and read
    	it in one go.

commit 280958942b74f3164708700f195188c4d3446f58
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 19 05:22:23 2017 -0700

    tilegx: Check bfd_link_executable for TLS check
    
    Copied from x86, check bfd_link_executable, instead of bfd_link_pic,
    for TLS transition check.  Not sure if it works correctly.  All usages
    of bfd_link_pic should be audited.
    
    	PR ld/22263
    	* elfxx-tilegx.c (tilegx_elf_tls_transition): Replace
    	bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
    	bfd_link_executable for TLS check.
    	(tilegx_elf_check_relocs): Likewise.
    	(allocate_dynrelocs): Likewise.
    	(tilegx_elf_relocate_section): Likewise.

commit 1ba1f393faac96f6ad80499d7133df23d6187b8c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 19 05:20:44 2017 -0700

    tilepro: Check bfd_link_executable for TLS check
    
    Copied from x86, check bfd_link_executable, instead of bfd_link_pic,
    for TLS transition check.  Not sure if it works correctly.  All usages
    of bfd_link_pic should be audited.
    
    	PR ld/22263
    	* elf32-tilepro.c (tilepro_elf_tls_transition): Replace
    	bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
    	bfd_link_executable for TLS check.
    	(tilepro_elf_check_relocs): Likewise.
    	(allocate_dynrelocs): Likewise.
    	(tilepro_elf_relocate_section): Likewise.

commit 0fb7012e88683b8bd67a4fb8f782359fa0e11724
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 19 05:18:07 2017 -0700

    sparc: Check bfd_link_executable for TLS check
    
    Copied from x86, check bfd_link_executable, instead of bfd_link_pic,
    for TLS transition check.  Not sure if it works correctly.  All usages
    of bfd_link_pic should be audited.
    
    	PR ld/22263
    	* elfxx-sparc.c (sparc_elf_tls_transition): Replace
    	bfd_link_pic with !bfd_link_executable, !bfd_link_pic with
    	bfd_link_executable for TLS check.
    	(_bfd_sparc_elf_check_relocs): Likewise.
    	(allocate_dynrelocs): Likewise.
    	(_bfd_sparc_elf_relocate_section): Likewise.

commit fa57faa0dad237b3f418f17e7ee2114c32da818a
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Thu Oct 19 09:02:15 2017 +0200

    Fix fill-1 testcase
    
    This fixes various issues with the fill-1 testcase causing fails on a
    couple of targets.
    
    gas/ChangeLog:
    
    2017-10-19  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* testsuite/gas/all/fill-1.s: Use normal labels.  Change .text to
    	.data. Pick different values.  Use .dc.w instead of .word.
    	* testsuite/gas/all/fill-1.d: New objdump output check.
    	* testsuite/gas/all/gas.exp: Use run_dump_test to execute fill-1
    	testcase.

commit d7dd155841641df62761f79a35362371811d9739
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Oct 19 00:00:32 2017 +0000

    Automatic date update in version.in

commit 8e354058532d48dce19fdf0b2e0653609a69f19e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Oct 18 15:46:57 2017 -0700

    tile: Mark __tls_get_addr in gc_mark_hook
    
    TLS_GD_CALL relocations implicitly reference __tls_get_addr.  Since
    elf_gc_mark_hook is called before check_relocs now, we need to call
    _bfd_generic_link_add_one_symbol to mark __tls_get_addr for garbage
    collection.
    
    	* elf32-tilepro.c (tilepro_elf_gc_mark_hook): Call
    	_bfd_generic_link_add_one_symbol to mark __tls_get_addr.
    	* elfxx-tilegx.c (tilegx_elf_gc_mark_hook): Likewise.

commit 8dfa5d5a6389b7f0fdd7baaedc5f316f05debf63
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Tue Oct 17 10:51:38 2017 -0700

    RISC-V: Mark unsupported gas testcases
    
    There are individual comments that explain why each test isn't
    supported, but the vast majority of them are due to RISC-V's aggressive
    linker relaxation.  The SLEB test cases should eventually be supported,
    but the remaining ones probably won't ever be.
    
    2017-10-18  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * testsuite/gas/all/align.d: Mark as unsupported on RISC-V.
            testsuite/gas/all/relax.d: Likewise.
            testsuite/gas/all/sleb128-2.d: Likewise.
            testsuite/gas/all/sleb128-4.d: Likewise.
            testsuite/gas/all/sleb128-5.d: Likewise.
            testsuite/gas/all/sleb128-7.d: Likewise.
            testsuite/gas/elf/section11.d: Likewise.
            testsuite/gas/all/gas.exp (diff1.s): Likewise.

commit c8ba13ad37c98262b94f99cc4f84ac0066c48cc2
Author: Keith Seitz <keiths@redhat.com>
Date:   Wed Oct 18 11:05:45 2017 -0700

    Canonicalize conversion operators
    
    Consider a conversion operator such as:
    
    operator foo const* const* ();
    
    There are two small parser problems, highlighted by this test:
    
    (gdb) p operator foo const* const*
    There is no field named operatorfoo const* const *
    
    GDB is looking up the symbol "operatorfoo const* const*" -- it is missing a
    space between the keyword "operator" and the type name "foo const* const*".
    
    Additionally, this input of the user-defined type needs to be canonicalized
    so that different "spellings" of the type are recognized:
    
    (gdb) p operator const foo* const *
    There is no field named operator const foo* const *
    
    gdb/ChangeLog:
    
    	* c-exp.y (oper): Canonicalize conversion operators of user-defined
    	types.
    	Add whitespace to front of type name.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.cp/cpexprs.cc (base) <operator fluff const* const*>: New
    	method.
    	(main): Call it.
    	* gdb.cp/cpexprs.exp: Add new conversion operator to test matrix.
    	Add additional user-defined conversion operator tests.

commit 3753468682a9c7982b6eba0fca58fbfc1cd5b9fb
Author: Keith Seitz <keiths@redhat.com>
Date:   Tue Oct 17 14:15:36 2017 -0700

    Issue complaint instead of assert for invalid/unhandled DW_AT_accessibility
    
    A previous patch called gdb_assert_not_reached whenever reading
    the accessibility of a nested typedef definition. Wisely, Pedro has asked me
    not do this.
    
    This patch changes the previous one so that it issues a complaint instead.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
    	DW_AT_accessibility.

commit 2a6969e1738859ea8c12837fb0cba3845bc87ceb
Author: Eric Botcazou <ebotcazou@gcc.gnu.org>
Date:   Wed Oct 18 16:30:24 2017 +0200

    [Visium] Disassemble the operands of the stop instruction.
    
    binutils/
            * MAINTAINERS: Add myself as Visium maintainer.
    opcodes/
            * visium-dis.c (disassem_class1) <case 0>: Print the operands.

commit 8ef027f00ba0252e22ce548c3d270db978184b5a
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 18 15:07:36 2017 +0100

    Update Cris assembler tests for checks that now pass where they used to fail.
    
    	PR gas/22304
    	* testsuite/gas/cris/range-err-1.s: Remove spurious xfails.
    	* testsuite/gas/cris/cris.exp: Expect the shexpr-1 test to pass.

commit 94ea37b3e93d4400cb0ae1e97b1241a552a4ab5e
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 18 14:50:49 2017 +0100

    Update the Swedish translation in the GAS subdirectory.
    
    	* po/sv.po: Updated Swedish translation.

commit 8071ec0990927fd747483ffaad3b5d3b16355643
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 18 14:40:06 2017 +0100

    Add a warning to the how-to-make-a-release notes to check the permissions on the files in the tarball.
    
    	* README-how-to-make-a-release: A note about checking file and
    	directory permissions.

commit 482366c31ebf90361f0da350608887bf7b6f0f41
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 18 14:36:48 2017 +0100

    Move Svein Seldal to Past Maintainers section.
    
    	* MAINTAINERS: Move Svein Seldal to Past Maintainers section.

commit 28c7c158766513a1c6f599c08f85851fcab855e6
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Oct 18 12:48:12 2017 +0100

    Remove features/tic6x-c62x-linux.c
    
    c40c7bf (Remove features/tic6x-*.c files) doesn't remove
    features/tic6x-c62x-linux.c.  This patch removes it.
    
    gdb:
    
    2017-10-18  Yao Qi  <yao.qi@linaro.org>
    
    	* features/tic6x-c62x-linux.c: Remove.

commit 5396a86e439653fb5cd714b955708250777a32e5
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 18 12:05:39 2017 +1030

    PR22303, print_core_note out of bounds read
    
    The print_core_note change here fixes the PR, the rest is making
    readelf a little more bombproof against maliciously crafted binaries.
    
    	PR 22303
    	* readelf.c (print_core_note): Ensure "count" sanity check
    	calculation doesn't overflow.
    	(process_notes_at): Perform note namesz and descsz checks
    	using unsigned comparisons against data remaining.  Catch
    	alignment overflow of namesz and descsz too.  Don't allocate a
    	temp for terminating "name" when there is space available
    	before descdata.

commit b7213666d6035713c3a2786ee418085e07cb3cca
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Oct 17 17:15:02 2017 -0700

    microblaze: Check for indirect and warning symbols
    
    Relocations against indirect and warning symbols should be applied to real
    symbols.
    
    	* elf32-microblaze.c (microblaze_elf_check_relocs): Check for
    	indirect and warning symbols.

commit da15dcb0aadfcd73cd3ed3ef2e2abf1c743f8ef8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Oct 18 00:00:29 2017 +0000

    Automatic date update in version.in

commit 412294daf8786fd9060059b8be7fc59a35e13922
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 18 00:33:05 2017 +1030

    [GOLD] Fix powerpc64 optimization of TOC accesses
    
    Fixes a thinko.  Given code that puts variables into the TOC (a bad
    idea, but some see the TOC as a small data section) this bug could
    result in an attempt to optimize a sequence that should not be
    optimized.
    
    	* powerpc.cc (Target_powerpc::Scan::local): Correct dst_off
    	calculation for TOC16 relocs.
    	(Target_powerpc::Scan::global): Likewise.

commit b27de576d41eed16936cf639857df4e1e27a8e9e
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 17 19:45:35 2017 +0100

    Really make the native-stdio-gdbserver board non-remote
    
    I've noticed now that due to a last-minute change, commit 739b3f1d8ff7
    ("Make native gdbserver boards no longer be "remote" (in DejaGnu
    terms)") managed to miss loading "local-board" in the
    native-stdio-gdbserver board...
    
    gdb/testsuite/ChangeLog:
    2017-10-17  Pedro Alves  <palves@redhat.com>
    
    	* boards/native-stdio-gdbserver.exp: Load "local-board".

commit be459434b6f98abe587f51a374abc38821be304d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 17 09:37:33 2017 -0600

    Add myself as dwarf-mode.el maintainer
    
    In https://sourceware.org/ml/binutils/2017-10/msg00160.html, Nick said I
    should update MAINTAINERS to mention that I'm the dwarf-mode.el
    maintainer.  So, I'm checking this in.
    
    2017-10-17  Tom Tromey  <tom@tromey.com>
    
    	* MAINTAINERS: Add myself as dwarf-mode.el maintainer.

commit 8484c9554519c25c73a349d0581cc269f102c5d2
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 17 14:58:54 2017 +0100

    Add several "quit with live inferior" tests
    
    In my multi-target branch, I had managed to break GDB exiting
    successfuly in response to "quit" or SIGHUP/SIGTERM when:
    
     - you're debugging with "target extended-remote",
     - have more than one inferior loaded in gdb, some running, and at
       least one not running, and,
     - quit gdb with the inferior that is not running yet selected.
    
    The testsuite still passed cleanly anyway.  I only noticed because I
    was left with a bunch of core dumps in the gdb/testsuite/ directory --
    the testsuite infrastructure closes GDB's pty after running each
    testcase, which results in GDB getting a SIGHUP and should make GDB
    exit gracefully.  If GDB crashes at that point though, there's no
    indication about it in gdb.sum/gdb.log.
    
    This commit adds a multitude of tests exercising quitting GDB with
    live inferiors, some of which would have caught the problem.
    
    gdb/testsuite/ChangeLog:
    2017-10-17  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/quit-live.c: New file.
    	* gdb.base/quit-live.exp: New file.

commit 30f0b1015897466fb88ed26c56a0b4f42808edbc
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 15:07:35 2017 -0600

    Remove cleanups from disasm.c
    
    This changes the remaining spots in disasm.c to use the RAII ui-out
    emitters, removing a few cleanups.  This also fixes a regression that
    Simon pointed out.
    
    2017-10-17  Tom Tromey  <tom@tromey.com>
    
    	* disasm.c (do_mixed_source_and_assembly_deprecated): Use
    	gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
    	(do_mixed_source_and_assembly): Likewise.

commit 57e12da97f8dbe2ad5b4f59bf89c709c4d66600d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 17 06:40:22 2017 -0600

    Remove obsolete assertion from regcache.c
    
    When building I got:
    
    ../../binutils-gdb/gdb/regcache.c:935:24: error: the address of â??ssize_t read(int, void*, size_t)â?? will never be NULL [-Werror=address]
    
    This happens because "read" used to be a parameter to this function,
    which was then removed; but the assertion wasn't updated.
    
    I don't think the assertion is relevant any more, to this removes it.
    I'm checking it in as obvious.
    
    2017-10-17  Tom Tromey  <tom@tromey.com>
    
    	* regcache.c (regcache::xfer_part): Remove assertion.

commit cf54ebff3b7361989712fd9c0128a9b255578163
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 17 21:57:29 2017 +1030

    PR22307, Heap out of bounds read in _bfd_elf_parse_gnu_properties
    
    When adding an unbounded increment to a pointer, you can't just check
    against the end of the buffer but also must check that overflow
    doesn't result in "negative" pointer movement.  Pointer comparisons
    are signed.  Better, check the increment against the space left using
    an unsigned comparison.
    
    	PR 22307
    	* elf-properties.c (_bfd_elf_parse_gnu_properties): Compare datasz
    	against size left rather than comparing pointers.  Reorganise loop.

commit 7b7009999ab8daac9db776c850b7df6e1f586334
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 17 12:41:00 2017 +0100

    Fix double-free corruption
    
    Fixes a double-free regression introduced by commit b7b030adc405
    ("Return unique_xmalloc_ptr from target_read_stralloc"):
    
    gdb.sum:
      Running src/gdb/testsuite/gdb.base/catch-syscall.exp ...
      ERROR: Process no longer exists
    
    Valgrind shows:
    
      (gdb) catch syscall
      ==3687== Thread 1:
      ==3687== Invalid free() / delete / delete[] / realloc()
      ==3687==    at 0x4C29CF0: free (vg_replace_malloc.c:530)
      ==3687==    by 0x610862: xfree(void*) (common-utils.c:101)
      ==3687==    by 0x440D5D: gdb::xfree_deleter<char>::operator()(char*) const (gdb_unique_ptr.h:34)
      ==3687==    by 0x446CC6: std::unique_ptr<char, gdb::xfree_deleter<char> >::reset(char*) (unique_ptr.h:344)
      ==3687==    by 0x81BE50: xml_fetch_content_from_file(char const*, void*) (xml-support.c:1042)
      ==3687==    by 0x81DA86: xml_init_syscalls_info(char const*) (xml-syscall.c:366)
      ==3687==    by 0x81DBDD: init_syscalls_info(gdbarch*) (xml-syscall.c:398)
      ==3687==    by 0x81E131: get_syscall_by_number(gdbarch*, int, syscall*) (xml-syscall.c:599)
      ==3687==    by 0x5BE86F: catch_syscall_command_1(char*, int, cmd_list_element*) (break-catch-syscall.c:481)
      ==3687==    by 0x4B46B1: do_sfunc(cmd_list_element*, char*, int) (cli-decode.c:138)
      ==3687==    by 0x4B76B8: cmd_func(cmd_list_element*, char*, int) (cli-decode.c:1952)
      ==3687==    by 0x7E91C7: execute_command(char*, int) (top.c:615)
      ==3687==  Address 0x14332ae0 is 0 bytes inside a block of size 4,096 free'd
      ==3687==    at 0x4C2AB8B: realloc (vg_replace_malloc.c:785)
      ==3687==    by 0x610792: xrealloc (common-utils.c:62)
      ==3687==    by 0x81BE3E: xml_fetch_content_from_file(char const*, void*) (xml-support.c:1042)
      ==3687==    by 0x81DA86: xml_init_syscalls_info(char const*) (xml-syscall.c:366)
      ==3687==    by 0x81DBDD: init_syscalls_info(gdbarch*) (xml-syscall.c:398)
      ==3687==    by 0x81E131: get_syscall_by_number(gdbarch*, int, syscall*) (xml-syscall.c:599)
      ==3687==    by 0x5BE86F: catch_syscall_command_1(char*, int, cmd_list_element*) (break-catch-syscall.c:481)
      ==3687==    by 0x4B46B1: do_sfunc(cmd_list_element*, char*, int) (cli-decode.c:138)
      ==3687==    by 0x4B76B8: cmd_func(cmd_list_element*, char*, int) (cli-decode.c:1952)
      ==3687==    by 0x7E91C7: execute_command(char*, int) (top.c:615)
      ==3687==    by 0x6A422D: command_handler(char*) (event-top.c:583)
      ==3687==    by 0x6A45F2: command_line_handler(char*) (event-top.c:773)
      [...]
    
    The problem is that if xrealloc decides it needs a new memory block,
    it frees the previous block/pointer, and then text.reset() frees it
    again.
    
    gdb/ChangeLog:
    2017-10-17  Pedro Alves  <palves@redhat.com>
    
    	* xml-support.c (xml_fetch_content_from_file): Call
    	unique_ptr::release() instead unique_ptr::get() when passing
    	through xrealloc.

commit d3037ba6a398d37585b3d34ff9ed439848ba98a1
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Oct 17 12:29:26 2017 +0100

    Simplify regcache::xfer_part
    
    Since xfer_part is already a class method, and only
    {raw,cooked}_{read,write} are passed to it.  We can remove these two
    arguments, but add a bool argument is_raw, indicating raw registers or
    cooked registers are accessed.
    
    gdb:
    
    2017-10-17  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (regcache::xfer_part): Remove parameters read and
    	write, add parameter is_raw.  All callers are updated.

commit 7a7cdfa04b0225dfa6879384075e08d73eaee862
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Oct 17 12:12:04 2017 +0100

    [GDBserver] Move aarch64-insn.o to arch/ and remove one Makefile rule
    
    gdb/gdbserver:
    
    2017-10-17  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in: Remove one rule.
    	* configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.

commit e675d1703fbdec643ec42aa67b9720cb199f4375
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Oct 17 12:12:04 2017 +0100

    [GDBserver] Move arm-linux.o and arm-get-next-pcs.o to arch/
    
    gdb/gdbserver:
    
    2017-10-17  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv: Rename arm-linux.o with arch/arm-linux.o.
    	Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.

commit 7eb4e0f95641edebbc28a710f28111f0ecb9f0d1
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Oct 17 12:12:04 2017 +0100

    [GDBserver] Move arm.o to arch/arm.o
    
    gdb/gdbserver:
    
    2017-10-17  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv: Rename arm.o with arch/arm.o.

commit 60d6cfc99e67c3f94e31e26112873719b12b738f
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Oct 17 12:12:04 2017 +0100

    [GDBserver] Replicate src dir in build dir
    
    Similar to f38307f5 (Replicate src dir in build dir), this patch change
    configure and Makefile to generate object files in arch/ directory.
    
    gdb/gdbserver:
    
    2017-10-17  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (CONFIG_SRC_SUBDIR): New variable.
    	(clean): Remove .o files in CONFIG_SRC_SUBDIR.
    	(distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
    	(arch-i386.o, arch-amd64.o): Remove rules.
    	(arch/%.o): New rule.
    	Update POSTCOMPILE and COMPILE.pre.
    	* configure.ac: Invoke AC_CONFIG_COMMANDS.
    	* configure: Re-generated.
    	* configure.srv: Replace arch-i386.o with arch/i386.o.
    	Replace arch-amd64.o with arch/amd64.o.

commit 0301ce1486b1450f219202677f30d0fa97335419
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 17 16:43:47 2017 +1030

    PR22306, Invalid free() in slurp_symtab()
    
    	PR 22306
    	* aoutx.h (aout_get_external_symbols): Handle stringsize of zero,
    	and error for any other size that doesn't cover the header word.

commit e6e2dfbdc1e0df3844401f7a8be64e98823a7846
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 17 16:47:05 2017 +1030

    Correct -z text and other -z documentation
    
    -z text applies to all dynamic binaries, not just shared libraries.
    A lot of the other options needed attention too.
    
    	* ld.texinfo (-z): Combine negative options with corresponding
    	positive option.  Sort the table.  Expand and correct "combreloc",
    	"common", "common-page-size", "interpose", "loadfltr",
    	"max-page-size", "muldefs", "nodefaultlib", "nodelete", "nodlopen",
    	"nodump", "noextern-protected-data", "now", "origin", and "text".

commit 83d5a34dd4e11263f6c6dd356b410799c6cb7970
Author: Keith Seitz <keiths@redhat.com>
Date:   Mon Oct 16 22:19:55 2017 -0700

    Add missing ChangeLog entries.

commit 487958d1e995ab05420f9a8468535b4399602a3f
Author: Sandra Loosemore <sandra@codesourcery.com>
Date:   Mon Oct 16 20:45:55 2017 -0700

    Fix segfault processing nios2 pseudo-instructions with too few arguments.
    
    2017-10-16  Sandra Loosemore  <sandra@codesourcery.com>
    	    Henry Wong  <henry@stuffedcow.net>
    
    	gas/
    	* config/tc-nios2.c (nios2_translate_pseudo_insn): Check for
    	correct number of arguments.
    	(md_assemble): Handle failure of nios2_translate_pseudo_insn.
    	* testsuite/gas/nios2/illegal_pseudoinst.l: New file.
    	* testsuite/gas/nios2/illegal_pseudoinst.s: New file.
    	* testsuite/gas/nios2/nios2.exp: Add illegal_pseudoinst test.

commit c191a6875b118fce30e7dc4d9e4bd20eff850270
Author: Keith Seitz <keiths@redhat.com>
Date:   Mon Oct 16 17:19:29 2017 -0700

    Record and output access specifiers for nested typedefs
    
    We currently do not record access information for typedefs defined inside
    classes.  Consider:
    
    struct foo
    {
       typedef int PUBLIC;
     private:
       typedef int PRIVATE;
       PRIVATE b;
    };
    
    (gdb) ptype foo
    type = struct foo {
      private:
        PRIVATE b;
    
        typedef int PRIVATE;
        typedef int PUBLIC;
    }
    
    This patch fixes this:
    
    (gdb) ptype foo
    type = struct foo {
      private:
        PRIVATE b;
    
        typedef int PRIVATE;
      public:
        typedef int PUBLIC;
    }
    
    gdb/ChangeLog:
    
    	* c-typeprint.c (enum access_specifier): Moved here from
    	c_type_print_base.
    	(output_access_specifier): New function.
    	(c_type_print_base): Consider typedefs when assessing
    	whether access labels are needed.
    	Use output_access_specifier as needed.
    	Output access specifier for typedefs, if needed.
    	* dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
    	* gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
    	fields.
    	(TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
    	accessor macros.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.cp/classes.cc (class_with_typedefs, class_with_public_typedef)
    	(class_with_protected_typedef, class_with_private_typedef)
    	(struct_with_public_typedef, struct_with_protected_typedef)
    	(struct_with_private_typedef): New classes/structs.
    	* gdb.cp/classes.exp (test_ptype_class_objects): Add tests for
    	typedefs and access specifiers.

commit 087ce8fa0249fa0167a73f25be51e12fb1a2b336
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Oct 17 00:00:26 2017 +0000

    Automatic date update in version.in

commit 87028b873938aa3cc756c99e33a328640dbc30bc
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 18:20:09 2017 -0600

    Return unique_xmalloc_ptr from target_fileio_read_stralloc
    
    Change target_fileio_read_stralloc to return unique_xmalloc_ptr and
    fix up the callers.  This removes a number of cleanups.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
    	(linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
    	* target.c (target_fileio_read_stralloc): Update.
    	* sparc64-tdep.c (adi_is_addr_mapped): Update.
    	* target.h (target_fileio_read_stralloc): Return
    	unique_xmalloc_ptr.

commit b7b030adc405017f01e996a90f85e40730ef8397
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 16:48:35 2017 -0600

    Return unique_xmalloc_ptr from target_read_stralloc
    
    This changes target_read_stralloc to return a unique_xmalloc_ptr, and
    then fixes all the callers.  unique_xmalloc_ptr is used, rather than
    std::string, because target_read_stralloc gives a special meaning to a
    NULL return.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* xml-syscall.c (xml_init_syscalls_info): Update.
    	* xml-support.c (xinclude_start_include): Update.
    	(xml_fetch_content_from_file): Return unique_xmalloc_ptr.
    	* xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
    	(xml_fetch_content_from_file): Likewise.
    	* osdata.c (get_osdata): Update.
    	* target.h (target_read_stralloc, target_get_osdata): Return
    	unique_xmalloc_ptr.
    	* solib-aix.c (solib_aix_get_library_list): Update.
    	* solib-target.c (solib_target_current_sos): Update.
    	* solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
    	* xml-tdesc.c (fetch_available_features_from_target): Update.
    	(target_fetch_description_xml): Update.
    	(file_read_description_xml): Update.
    	* remote.c (remote_get_threads_with_qxfer, remote_memory_map)
    	(remote_traceframe_info, btrace_read_config, remote_read_btrace)
    	(remote_pid_to_exec_file): Update.
    	* target.c (target_read_stralloc): Return unique_xmalloc_ptr.
    	(target_get_osdata): Likewise.

commit b80406accc70791a1789e40f24d64161bc41de34
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 16:40:01 2017 -0600

    Simple cleanup removals in remote.c
    
    This removes a few cleanups in remote.c using the usual techniques:
    std::vector, unique_xmalloc_ptr, and gdb::def_vector.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* remote.c (remote_register_number_and_offset): Use std::vector.
    	(remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
    	(putpkt_binary): Use gdb::def_vector.
    	(compare_sections_command): Use gdb::byte_vector.

commit a90ecff85af9d9275f540227825ba62bdafc976d
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 16:24:13 2017 -0600

    Remove cleanup from ppc-linux-nat.c
    
    This removes a cleanup from ppc-linux-nat.c, by using
    unique_xmalloc_ptr.  It also slightly simplifies the code by using
    XDUP rather than XNEW and memcpy.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* ppc-linux-nat.c (hwdebug_insert_point): Use
    	gdb::unique_xmalloc_ptr, XDUP.

commit 2dc0e219715356c6acbc3bea85ddec288f752f1f
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 16:19:55 2017 -0600

    Remove some cleanups from probe.c
    
    This removes some cleanups from parse_probes by using std::string; and
    removes some unnecessary cleanups from elsewhere in probe.c.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* probe.c (parse_probes): Use std::string.
    	(info_probes_for_ops, enable_probes_command)
    	(disable_probes_command): Remove cleanups.

commit b05628f0a878cdd64492bbc49d60003d699763ad
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Oct 12 15:46:42 2017 -0600

    Use std::vector in end_symtab_get_static_block
    
    Change end_symtab_get_static_block to use std::vector.  This removes a
    cleanup.
    
    ChangeLog
    2017-10-16  Tom Tromey  <tom@tromey.com>
    
    	* buildsym.c (block_compar): Remove.
    	(end_symtab_get_static_block): Use std::vector.

commit 739b3f1d8ff7072dcc66240c25b026c6433bda1a
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 16 20:24:21 2017 +0100

    Make native gdbserver boards no longer be "remote" (in DejaGnu terms)
    
    This commit finally clears the "isremote" flag in the native-gdbserver
    and native-stdio-gdbserver boards.  The goal is to make all "native"
    boards be considered not remote in DejaGnu terms, like the
    native-extended-gdbserver board is too.
    
    DejaGnu automatically considers boards remote if their names don't
    match the local hostname.  That means that native-gdbserver and
    native-extended-gdbserver are considered remote by default by DejaGnu,
    even though they run locally.  native-extended-gdbserver, however,
    overrides its isremote flag to force it to be not remote.  So we are
    in that weird state where native-gdbserver is considered remote, and
    native-extended-gdbserver is considered not remote.
    
    A recent set of commits fixed all the problems (and some more) exposed
    by testing with --target_board=native-gdbserver and
    --target_board=native-stdio-gdbserver with isremote forced off on
    x86-64 GNU/Linux.  I believe we're good to go now.
    
    The native-stdio-gdbserver.exp/remote-stdio-gdbserver.exp boards
    required deep non-obvious modifications unfortunately...  The problem
    is that if a board is not remote, then DejaGnu doesn't call
    ${board}_spawn / ${board}_exec at all, and the
    native-stdio-gdbserver.exp board relies on those procedures being
    called.  To fix that, this commit redesigns how the stdio boards hook
    into the testing framework to spawn gdbserver.  IMO, this is a good
    change anyway, because the way its done currently is a bit of a hack,
    and the result turns out to be simpler, even.  With this commit, they
    now no longer load the "gdbserver" generic config, and hook at the
    mi_gdb_target_load/gdb_reload level instead, making them more like
    traditional board files.
    
    To share code between native-stdio-gdbserver.exp and
    remote-stdio-gdbserver.exp, a new shared stdio-gdbserver-base.exp file
    is created.
    
    Instead of having each native board clear isremote manually, boards
    source the new "local-board.exp" file.
    
    This also adds a new section to testsuite/README file discussing
    local/remote/native, so that we can easily refer to it.
    
    gdb/testsuite/ChangeLog:
    2017-10-16  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi  <simon.marchi@polymtl.ca>
    
    	* README (Local vs Remote vs Native): New section.
    	* boards/local-board.exp: New file, with bits factored out from
    	...
    	* boards/native-extended-gdbserver.exp: ... here.  Load
    	"local-board".
    	* boards/native-gdbserver.exp: Load "local-board".
    	(${board}_spawn, ${board}_exec): Delete.
    	* boards/native-stdio-gdbserver.exp: Most contents factored out to
    	...
    	* boards/stdio-gdbserver-base.exp: ... this new file.
    	* boards/native-stdio-gdbserver.exp: Reimplement, by loading
    	"stdio-gdbserver-base" and defining a get_target_remote_pipe_cmd
    	procedure.
    	* boards/remote-stdio-gdbserver.exp: Load stdio-gdbserver-base
    	instead of native-stdio-gdbserver.  Don't set gdb_server_prog nor
    	stdio_gdbserver_command.
    	(${board}_get_remote_address, ${board}_get_comm_port)
    	(${board}_download, ${board}_upload): Delete.
    	(get_target_remote_pipe_cmd): New.

commit fe68b9530f6ec45d57838b96dbe11723b90467f4
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Oct 16 15:06:14 2017 -0400

    Use proc_with_prefix in py-breakpoint.exp
    
    Use proc_with_prefix to avoid having to call with_test_prefix with a
    duplicate of the proc name.  The diff is mostly lines being re-indented.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-breakpoint.exp (test_bkpt_basic,
    	test_bkpt_deletion, test_bkpt_cond_and_cmds,
    	test_bkpt_invisible, test_watchpoints, test_bkpt_internal,
    	test_bkpt_eval_funcs, test_bkpt_temporary, test_bkpt_address,
    	test_bkpt_pending, test_bkpt_events): Use proc_with_prefix,
    	remove with_test_prefix.

commit a79b1bc6f690f3d146a3caddabd9f13a886c856a
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Oct 16 10:14:53 2017 -0400

    Get rid of VEC(mem_range_s)
    
    This patch replaces the last usages of VEC(mem_range_s) with
    std::vector<mem_range>.  This allows getting rid of a few cleanups and
    of the DEF_VEC_O(mem_range_s).
    
    I added a test for normalize_mem_ranges to make sure I didn't break
    anything there.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog:
    
    	* memrange.h (struct mem_range): Define operator< and operator==.
    	(mem_range_s): Remove.
    	(DEF_VEC_O (mem_range_s)): Remove.
    	(normalize_mem_ranges): Change parameter type to std::vector.
    	* memrange.c (compare_mem_ranges): Remove.
    	(normalize_mem_ranges): Change parameter type to std::vector,
    	adjust to vector change.
    	* exec.c (section_table_available_memory): Return vector, remove
    	parameter.
    	(section_table_read_available_memory): Adjust to std::vector
    	change.
    	* remote.c (remote_read_bytes): Adjust to std::vector
    	change.
    	* tracepoint.h (traceframe_available_memory): Change parameter
    	type to std::vector.
    	* tracepoint.c (traceframe_available_memory): Change parameter
    	type to std::vector, adjust.
    	* gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
    	std::vector change.
    	* gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
    	unittests/memrange-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
    	* gdb/unittests/memrange-selftests.c: New file.

commit 63f0e930d4667eb7dbc95c78f770cd58acd328ef
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 16 13:39:12 2017 +0100

    Work around GCC 6.3.1 bug
    
    This commit works around a GCC 6.3.1 bug several people are hitting:
    
      https://sourceware.org/ml/gdb-patches/2017-09/msg00270.html
      https://sourceware.org/ml/gdb-patches/2017-10/msg00418.html
    
    It manifests like this:
    
      ../../../binutils-gdb/gdb/probe.c:68:12: error: types may not be defined in a for-range-declaration [-Werror]
    	 for (struct probe *probe : probes)
    	      ^~~~~~
    
    Fix it by renaming the range-for named variables to something different
    from their type's name.
    
    gdb/ChangeLog:
    2017-10-16  Pedro Alves  <palves@redhat.com>
    
    	* elfread.c (probe_key_free): Rename range-for variable.
    	* probe.c (parse_probes_in_pspace, find_probes_in_objfile)
    	(find_probe_by_pc, collect_probes): Rename range-for variable.

commit 5c3261b0e834647cf9eb555320e20871b7854f98
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 16 03:49:54 2017 -0700

    ELF: Call check_relocs after opening all inputs
    
    For all ELF targers, call check_relocs after opening all inputs and
    garbage collection.  Since the symbol resolution is known, check_relocs
    can be simplified.  Also garbage collection doesn't need to undo what
    check_relocs has done for symbols which have been garbage collected.
    Since ELF targets never see the removed sections, gc_sweep_hook can be
    removed from elf_backend_data and we can avoid GOT/PLT with garbage
    collection now.
    
    Set link_info.check_relocs_after_open_input to TRUE for all linker
    targets which use ELF linker and update garbage collection tests to
    remove unused GOT section.
    
    ldemul_after_check_relocs is added for powerpc to support --secure-plt,
    --bss-plt and --sdata-got.
    
    Tested natively without regressions on i686, x86-64 and x32.  Tested
    cross binutils on x86-64 without regressions for aarch64-linux,
    alpha-linux, arm-linux, bfin-elf, cr16-elf, cris-elf, crx-elf, frv-linux,
    hppa64-linux, hppa-linux, ia64-linux, lm32-elf, m32r-elf, m68k-linux,
    mcore-elf, metag-elf, microblaze-linux, mips-linux, mmix, mn10300-elf,
    nds32le-linux, nios2-linux, or1k-elf, powerpc64-linux, powerpc-linux,
    riscv32-linux, riscv64-linux, s390-linux, s390x-linux, score-elf,
    sh3-linux, sparc64-linux, sparc-linux, tic6x-elf, tilegx-linux,
    tilepro-linux, vax-linux, x86_64-mingw32 and xtensa-linux.
    
    bfd/
    
    	* elf-bfd.h (elf_backend_data): Remove gc_sweep_hook.
    	* elf32-arm.c (elf32_arm_gc_sweep_hook): Removed.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-bfin.c (bfin_gc_sweep_hook): Likewise.
    	(bfinfdpic_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-cr16.c (elf32_cr16_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-cris.c (cris_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-hppa.c (elf32_hppa_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-lm32.c (lm32_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-m32r.c (m32r_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-m68k.c (elf_m68k_got_entry): Remove elf_m68k_gc_sweep_hook
    	from comments.
    	(elf_m68k_remove_got_entry_type): Removed.
    	(elf_m68k_find_got_entry_ptr): Likewise.
    	(elf_m68k_remove_got_entry): Likewise.
    	(elf_m68k_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-mcore.c (mcore_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-metag.c (elf_metag_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-microblaze.c (elf_backend_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-mips.c (elf_backend_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-nds32.c (nds32_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-nios2.c (nios2_elf32_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-or1k.c (or1k_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-ppc.c (ppc_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-s390.c (elf_s390_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-sparc.c (elf_backend_gc_sweep_hook): Likewise.
    	* elf32-tic6x.c (elf32_tic6x_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-tilegx.c (elf_backend_gc_sweep_hook): Likewise.
    	* elf32-tilepro.c (tilepro_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf32-xtensa.c (elf_xtensa_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf64-alpha.c (elf64_alpha_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf64-mips.c (elf_backend_gc_sweep_hook): Likewise.
    	* elf64-mmix.c (mmix_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf64-ppc.c (elf_backend_gc_sweep_hook): Likewise.
    	(ppc64_elf_gc_sweep_hook): Likewise.
    	* elf64-s390.c (elf_s390_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elf64-sparc.c (elf_backend_gc_sweep_hook): Likewise.
    	* elf64-tilegx.c (elf_backend_gc_sweep_hook): Likewise.
    	* elflink.c (elf_link_add_object_symbols): Don't call
    	_bfd_elf_link_check_relocs here.
    	(gc_sweep_hook_fn): Removed.
    	(elf_gc_sweep): Remove gc_sweep_hook.
    	* elfnn-aarch64.c (elfNN_aarch64_gc_sweep_hook): Removed.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elfnn-riscv.c (riscv_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elfxx-mips.c (_bfd_mips_elf_gc_sweep_hook): Likewise.
    	* elfxx-mips.h (_bfd_mips_elf_gc_sweep_hook): Likewise.
    	(elf_backend_gc_sweep_hook): Likewise.
    	* elfxx-sparc.c (_bfd_sparc_elf_gc_sweep_hook): Likewise.
    	* elfxx-sparc.h (_bfd_sparc_elf_gc_sweep_hook): Likewise.
    	* elfxx-target.h (elf_backend_gc_sweep_hook): Likewise.
    	(elfNN_bed): Remove elf_backend_gc_sweep_hook.
    	* elfxx-tilegx.c (tilegx_elf_gc_sweep_hook): Removed.
    	* elfxx-tilegx.h (tilegx_elf_gc_sweep_hook): Likewise.
    
    ld/
    
    	* emulparams/elf32_x86_64.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Removed.
    	* emulparams/elf_i386_be.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_i386_chaos.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_i386_ldso.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_i386_vxworks.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_iamcu.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_k1om.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_l1om.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/elf_x86_64.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/i386lynx.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/i386moss.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/i386nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/i386nw.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shelf.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shelf32.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shelf_nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shelf_vxworks.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shlelf32_linux.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shlelf_linux.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emulparams/shlelf_nto.sh (CHECK_RELOCS_AFTER_OPEN_INPUT):
    	Likewise.
    	* emultempl/aarch64elf.em (gld${EMULATION_NAME}_before_parse):
    	Set link_info.check_relocs_after_open_input to TRUE.
    	* emultempl/armelf.em (gld${EMULATION_NAME}_before_parse):
    	Likewise.
    	* emultempl/scoreelf.em (gld${EMULATION_NAME}_before_parse):
    	Likewise.
    	* emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Add
    	after_parse_default.
    	* emultempl/armcoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/beos.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/generic.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/gld960.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/gld960c.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/lnk960.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/m68kcoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/msp430.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/pe.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/pep.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/sunos.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/ticoff.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/vanilla.em (ld_${EMULATION_NAME}_emulation): Likewise.
    	* emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Always
    	set link_info.check_relocs_after_open_input to TRUE.
    	(ld_${EMULATION_NAME}_emulation): Add $LDEMUL_AFTER_CHECK_RELOCS.
    	* emultempl/linux.em (gld${EMULATION_NAME}_before_parse):
    	Set link_info.check_relocs_after_open_input to TRUE.
    	(ld_${EMULATION_NAME}_emulation): Add after_check_relocs_default.
    	* emultempl/mmix-elfnmmo.em (mmix_before_parse): New function.
    	(LDEMUL_BEFORE_PARSE): New.
    	* emultempl/mmixelf.em (elfmmix_before_parse): Replace
    	gld${EMULATION_NAME}_before_parse with mmix_before_parse.
    	* emultempl/ppc32elf.em (ppc_after_open): Renamed to ...
    	(ppc_after_check_relocs): This.  Call after_check_relocs_default
    	instead of gld${EMULATION_NAME}_after_open.
    	(LDEMUL_AFTER_OPEN): Removed.
    	(LDEMUL_AFTER_CHECK_RELOCS): New.
    	* ldemul.c (ldemul_after_check_relocs): New.
    	(after_check_relocs_default): Likewise.
    	* ldemul.h (ldemul_after_check_relocs): Likewise.
    	(after_check_relocs_default): Likewise.
    	(ld_emulation_xfer_struct): Add after_check_relocs.
    	* ldlang.c (lang_process): Call ldemul_after_check_relocs after
    	lang_check_relocs.
    	* testsuite/ld-aarch64/gc-got-relocs.d: Don't expect GOT section.
    	* testsuite/ld-aarch64/gc-tls-relocs.d: Likewise.
    	* testsuite/ld-cris/tls-gc-68.d: Likewise.
    	* testsuite/ld-cris/tls-gc-69.d: Likewise.
    	* testsuite/ld-cris/tls-gc-70.d: Likewise.
    	* testsuite/ld-cris/tls-gc-75.d: Likewise.
    	* testsuite/ld-cris/tls-gc-79.d: Likewise.
    	* testsuite/ld-mmix/bpo-10.d: Don't expect .MMIX.reg_contents
    	section.

commit 5bfda25568c34410129c91042cdfdf10c143edac
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Oct 16 11:26:38 2017 +0100

    Regenerate gdbserver/configure
    
    4fa7574 (Fix gdb 8.1 Solaris compilation) changes warning.m4 and updates
    configure, but gdbserver/configure is not updated.
    
    gdb/gdbserver:
    
    2017-10-16  Yao Qi  <yao.qi@linaro.org>
    
    	* configure: Regenerated.

commit c40c7bfcf12408f9f8fb1bb61882f1ffd78d4e8b
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Oct 16 09:27:43 2017 +0100

    Remove features/tic6x-*.c files
    
    features/*.c are generated from *.xml files, in order to get pre-defined
    target descriptions, (for native debugging, for example).  However, these
    pre-generated tdesc_tic6x_* are not used in GDB at all.  This patch removes
    features/tic6x-*.c files.
    
    gdb:
    
    2017-10-16  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (XMLTOC): Remove tic6x-*.xml.
    	* features/tic6x-c62x.c: Remove.
    	* features/tic6x-c64x-linux.c: Remove.
    	* features/tic6x-c64x.c: Remove.
    	* features/tic6x-c64xp-linux.c: Remove.
    	* features/tic6x-c64xp.c: Remove.
    	* tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
    	initialize_tdesc_tic6x_*_linux functions.
    	* tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
    	initialize_tdesc_tic6x_* functions.

commit df27ae6a09c6e1d3e92e67b19e43c24d5f1842b2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Oct 16 09:15:07 2017 +0100

    Remove regformats/tic6x-{c62x,c64x,c64xp}.dat
    
    tic6x-uclinux GDBserver uses linux target descriptions, instead of these
    non-linux target descriptions.  So we can remove these *.dat files.
    
    gdb:
    
    2017-10-16  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
    	tic6x-c62x.
    	* regformats/tic6x-c62x.dat: Remove.
    	* regformats/tic6x-c64x.dat: Remove.
    	* regformats/tic6x-c64xp.dat: Remove.

commit 8676616596351876612aa84be798537625348086
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Oct 15 22:13:22 2017 -0400

    Fix GDB build without expat
    
    An earlier patch of mine changed parse_traceframe_info to make it return
    a unique_ptr.  I forgot to update the version of the function used in an
    expat-less build, this patch fixes it.
    
    gdb/ChangeLog:
    
    	* tracepoint.c (parse_traceframe_info): Return a unique_ptr
    	(the !HAVE_LIBEXPAT version).

commit 86e17b6fbc9b224ecceece7a8bb4dd7989f07c7d
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Oct 16 00:00:19 2017 +0000

    Automatic date update in version.in

commit 631859b65bf9f242c1d408d54052df25d5e983e7
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Oct 15 00:00:28 2017 +0000

    Automatic date update in version.in

commit 0c52bddddfd2afee0e650854fc2d8abf903199fc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:51:51 2017 -0700

    Apply "ELF: Call check_relocs after opening all inputs"

commit c3d427c069443bc5f0b6abd48f6bd55b2f93ec00
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:50:50 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit 44b0db8570e8c7abfeac95800e2a97ef98828e3a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:38:49 2017 -0700

    Revert "Apply 2 elfxx-x86 patches"
    
    This reverts commit 8057eafd5c0d64feb4c3ca381028d5e554558be6.
    
    They have been checked into master branch.

commit 5eb013a5ac76db1268765bdd9c0fbd77a0f95b55
Merge: 5f93de4 851b6fa
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:38:12 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 851b6fa13707d187e068c8773f21d376391387a9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:32:29 2017 -0700

    x86: Add elf_x86_backend_data
    
    Add plt0_pad_byte and target_os fields to elf_x86_link_hash_table.
    Replace elf_i386_backend_data and elf_x86_64_backend_data with
    elf_x86_backend_data.
    
    	* elf32-i386.c (elf_i386_backend_data): Removed.
    	(get_elf_i386_backend_data): Likewise.
    	(elf_i386_arch_bed): Replace elf_i386_backend_data with
    	elf_x86_backend_data.
    	(elf_i386_get_synthetic_symtab): Likewise.
    	(elf_i386_nacl_arch_bed): Likewise.
    	(elf_i386_vxworks_arch_bed): Likewise.
    	(elf_i386_relocate_section): Check target_os instead of
    	is_vxworks.
    	(elf_i386_finish_dynamic_symbol): Likewise.
    	(elf_i386_finish_dynamic_sections): Use htab->plt0_pad_byte.
    	Check target_os instead of is_vxworks.
    	(elf_i386_link_setup_gnu_properties): Remove normal_target and
    	is_vxworks.  Initialize plt0_pad_byte.
    	* elf64-x86-64.c (elf_x86_64_backend_data); Removed.
    	(get_elf_x86_64_arch_data): Likewise.
    	(get_elf_x86_64_backend_data): Likewise.
    	(elf_x86_64_arch_bed): Replace elf_x86_64_backend_data with
    	elf_x86_backend_data.
    	(elf_x86_64_get_synthetic_symtab): Likewise.
    	(elf_x86_64_nacl_arch_bed): Likewise.
    	(elf_x86_64_link_setup_gnu_properties): Remove is_vxworks and
    	normal_target.  Initialize plt0_pad_byte.
    	* elfxx-x86.c (elf_x86_allocate_dynrelocs): Check target_os
    	instead of is_vxworks.
    	(_bfd_x86_elf_size_dynamic_sections): Likewise.
    	(_bfd_x86_elf_finish_dynamic_sections): Likewise.
    	(_bfd_x86_elf_adjust_dynamic_symbol): Likewise.
    	(_bfd_x86_elf_link_hash_table_create): Initialize target_os.
    	(_bfd_x86_elf_link_setup_gnu_properties): Remove is_vxworks.
    	Update normal_target.  Set up plt0_pad_byte.  Check target_os
    	instead of is_vxworks.
    	* elfxx-x86.h (elf_x86_target_os): New.
    	(elf_x86_backend_data): Likewise.
    	(get_elf_x86_backend_data): Likewise.
    	(elf_x86_link_hash_table): Remove is_vxworks.  Add plt0_pad_byte
    	and target_os.
    	(elf_x86_init_table): Remove normal_target and is_vxworks.  Add
    	plt0_pad_byte.

commit 9577f60b5a19ce93536f49cba3af4be39e39c327
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:29:58 2017 -0700

    x86: Add _bfd_x86_elf_finish_dynamic_sections
    
    Extract the common parts of elf_i386_finish_dynamic_sections and
    elf_x86_64_finish_dynamic_sections into a separate function in
    elfxx-x86.c.
    
    	* elf32-i386.c (elf_i386_finish_dynamic_sections): Call
    	_bfd_x86_elf_finish_dynamic_sections.
    	* elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_finish_dynamic_sections): New
    	function.
    	* elfxx-x86.h (_bfd_x86_elf_finish_dynamic_sections): New
    	prototype.

commit 5d84490bf6ac806c15781a833f0e1e7a191f334f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:23:45 2017 -0700

    cris: Don't hide symbol which was forced to be dynamic
    
    h->root.dynamic is set on symbols which were forced to be dynamic due
    to a version script file.  Don't remove such symbols from dynamic symbol
    table.  This fixes:
    
    FAIL: ld-elf/pr21384
    
    	PR ld/21384
    	* elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
    	hide symbol which was forced to be dynamic.

commit e01c16a83893b03433c8edf4ccae536d9b9f4831
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:09:29 2017 -0700

    cris: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    bfd/
    
    	PR ld/22269
    	* elf32-cris.c (cris_elf_relocate_section): Don't generate
    	dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(cris_elf_check_relocs): Don't allocate dynamic relocation
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    
    ld/
    
    	PR ld/22269
    	* testsuite/ld-cris/weakhiddso.d: Update and remove R_CRIS_NONE.

commit 6ee6e05af482b356f9be4b0db877802fb47b2a12
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:07:18 2017 -0700

    sh: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-sh.c (allocate_dynrelocs): Discard dynamic relocations
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(sh_elf_relocate_section): Don't generate dynamic relocation if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit b27bb18f45a99330600ab57892c3620343425910
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:06:00 2017 -0700

    s390: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-s390.c (allocate_dynrelocs): Discard dynamic
    	relocations if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elf_s390_relocate_section): Don't generate dynamic relocation
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	* elf64-s390.c (allocate_dynrelocs): Discard dynamic
    	relocations if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elf_s390_relocate_section): Don't generate dynamic relocation
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 31a53da5418528b9ba94bb80a97f0084f40e0c64
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:04:32 2017 -0700

    nios2: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-nios2.c (nios2_elf32_relocate_section): Don't generate
    	dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_dynrelocs): Discard dynamic relocations if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 112fef4084ff0bdd6dd9aacca85f5fe62e1a5423
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:03:26 2017 -0700

    microblaze: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-microblaze.c (microblaze_elf_relocate_section): Don't
    	generate dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is
    	true.
    	(allocate_dynrelocs): Discard dynamic relocations if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 5056ba1d4df19006b873bc8e752f85fcc712b65b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 11:02:20 2017 -0700

    m68k: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-m68k.c (elf_m68k_check_relocs): Don't allocate dynamic
    	relocations if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elf_m68k_adjust_dynamic_symbol): Don't make symbol dynamic if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elf_m68k_relocate_section): Don't generate dynamic relocation
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 60c1b909dfcc984f3aecb70032e90a34d71b44bc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:54:50 2017 -0700

    hppa: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-hppa.c (ensure_undef_dynamic): Don't make undefined
    	symbol dynamic if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_dynrelocs): Discard dynamic relocations if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elf32_hppa_relocate_section): Don't generate dynamic
    	relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit db41f6eb5234ea3c74c1ce4798cf9923d4a45a98
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:53:43 2017 -0700

    ia64: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elfnn-ia64.c (elfNN_ia64_check_relocs): Don't allocate
    	dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_fptr): Don't allocate function pointer if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_dynrel_entries): Don't allocate dynamic relocation
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(set_got_entry): Don't set GOT entry if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(set_pltoff_entry): Don't set PLTOFF entry if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(elfNN_ia64_relocate_section): Don't install dynamic relocation
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit ad9512030937e79e28d08108fde7adf18635c58b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:52:12 2017 -0700

    mips: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elfxx-mips.c (mips_elf_calculate_relocation): Don't generate
    	dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_dynrelocs): Don't allocate dynamic relocations if
    	UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 95b03e4ad68e7a90f5096b47df595636344b783a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:27:33 2017 -0700

    arm: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-arm.c (elf32_arm_final_link_relocate): Don't generate
    	dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(allocate_dynrelocs_for_symbol): Discard dynamic relocations
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit a3cd202aae50abe5a571fb8c186b6b6af68edce2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:25:33 2017 -0700

    tile: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elf32-tilepro.c (allocate_dynrelocs): Discard dynamic
    	relocations if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(tilepro_elf_relocate_section): Don't generate dynamic
    	relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	* elfxx-tilegx.c (allocate_dynrelocs): Discard dynamic
    	relocations if UNDEFWEAK_NO_DYNAMIC_RELOC is true.
    	(tilegx_elf_relocate_section): Don't generate dynamic
    	relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit ddb7fd0f7b43e4c755c4b8c7752948e050363525
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:23:48 2017 -0700

    aarch64: Check UNDEFWEAK_NO_DYNAMIC_RELOC
    
    Don't generate dynamic relocation against weak undefined symbol if it
    is resolved to zero.  FIXME: UNDEFWEAK_NO_DYNAMIC_RELOC may need to be
    checked in more places.
    
    	PR ld/22269
    	* elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Don't
    	generate dynamic relocation if UNDEFWEAK_NO_DYNAMIC_RELOC is
    	true.
    	(elfNN_aarch64_allocate_dynrelocs): Discard dynamic relocations
    	if UNDEFWEAK_NO_DYNAMIC_RELOC is true.

commit 62cd30f167be56e68cb0a37789d400b47bbdbc6c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 14 10:19:30 2017 -0700

    Move UNDEFWEAK_NO_DYNAMIC_RELOC to elf-bfd.h
    
    Move UNDEFWEAK_NO_DYNAMIC_RELOC to elf-bfd.h so that it can be used by
    other ELF linker backends.
    
    	* elf32-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Moved to ...
    	* elf-bfd.h (UNDEFWEAK_NO_DYNAMIC_RELOC): Here.
    	* elf64-ppc.c (UNDEFWEAK_NO_DYNAMIC_RELOC): Removed.

commit 824dfcc311958af08c25d29956da2bab99e240c9
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 14 09:28:07 2017 -0400

    Fix build failure in linux-osdata.c
    
    Commit
    
      Use std::vector in linux_xfer_osdata_processgroups
      b129dcac882da87767cb863ad8b2572f90e9e5bc
    
    broke the build with older gcc (at least 4.7 and 4.8):
    
    In file included from /usr/include/c++/4.7/algorithm:63:0,
                     from /home/emaisin/src/binutils-gdb/gdb/nat/linux-osdata.c:40:
    /usr/include/c++/4.7/bits/stl_algo.h: In instantiation of â??_RandomAccessIterator std::__unguarded_partition(_RandomAccessIterator, _RandomAccessIterator, const _Tp&) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >; _Tp = pid_pgid_entry]â??:
    /usr/include/c++/4.7/bits/stl_algo.h:2315:70:   required from â??_RandomAccessIterator std::__unguarded_partition_pivot(_RandomAccessIterator, _RandomAccessIterator) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >]â??
    /usr/include/c++/4.7/bits/stl_algo.h:2347:54:   required from â??void std::__introsort_loop(_RandomAccessIterator, _RandomAccessIterator, _Size) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >; _Size = long int]â??
    /usr/include/c++/4.7/bits/stl_algo.h:5483:4:   required from â??void std::sort(_RAIter, _RAIter) [with _RAIter = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >]â??
    /home/emaisin/src/binutils-gdb/gdb/nat/linux-osdata.c:480:57:   required from here
    /usr/include/c++/4.7/bits/stl_algo.h:2277:4: error: passing â??const pid_pgid_entryâ?? as â??thisâ?? argument of â??bool pid_pgid_entry::operator<(const pid_pgid_entry&)â?? discards qualifiers [-fpermissive]
    
    Making the operator< method const fixes it.
    
    gdb/ChangeLog:
    
    	* nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
    	const.

commit 9c80ecd646a604fadcc290fca23b34c9454f5feb
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 09:11:12 2017 -0400

    gdbserver: use std::list for all_threads
    
    Remove the usage of inferior_list for the all_threads list in
    gdbserver.  The entry field in thread_info is removed, and replaced by a
    simple ptid field.
    
    I added some functions to iterate (for_each_thread) and find threads
    (find_thread).  However, changing all the users of find_inferior & co to
    use these new functions would have made the patch way too big.  So I
    opted instead to make find_inferior & co some shims, so that the
    existing code only needs to be updated minimally.  We can then update
    the existing code to use the new functions incrementally (I've started
    to do the work, but I'll post it afterwards, see [1] if you want a peek).
    
    This patch has been built-tested on all relevant platforms, except
    lynx.  I also regtested using the native-gdbserver and
    native-extended-gdbserver boards on x86.
    
    [1] https://github.com/simark/binutils-gdb/commits/kill-inferior-list-entry
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h: (struct inferior_list): Remove.
    	(struct inferior_list_entry); Remove.
    	(add_inferior_to_list, clear_inferior_list, one_inferior_p,
    	A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
    	get_first_inferior): Remove.
    	(for_each_inferior, for_each_inferior_with_data, find_inferior,
    	find_inferior_id, find_inferior_in_random): Change signature.
    	* inferiors.c (all_threads): Change type to
    	std::list<thread_info *>.
    	(get_thread): Remove macro.
    	(find_inferior, find_inferior_id): Change signature, implement
    	using find_thread.
    	(find_inferior_in_random): Change signature, implement using
    	find_thread_in_random.
    	(for_each_inferior, for_each_inferior_with_data): Change
    	signature, implement using for_each_thread.
    	(add_inferior_to_list, remove_inferior): Remove.
    	(add_thread, get_first_thread, thread_of_pid,
    	find_any_thread_of_pid, free_one_thread, remove_thread): Update.
    	(get_first_inferior, one_inferior_p, clear_inferior_list):
    	Remove.
    	(clear_inferiors, get_thread_process): Update.
    	* gdbthread.h: Include <list>.
    	(struct thread_info) <entry>: Remove field.
    	<id>: New field.
    	(all_threads): Change type to std::list<thread_info *>.
    	(get_first_inferior): Add doc.
    	(find_thread, for_each_thread, find_thread_in_random): New
    	functions.
    	(current_ptid, pid_of, ptid_of, lwpid_of): Update.
    	* linux-arm-low.c (update_registers_callback): Update.
    	* linux-low.c (second_thread_of_pid_p): Update.
    	(kill_one_lwp_callback, linux_detach_lwp_callback,
    	delete_lwp_callback, status_pending_p_callback, same_lwp,
    	find_lwp_pid, num_lwps, iterate_over_lwps_filter,
    	iterate_over_lwps, not_stopped_callback,
    	resume_stopped_resumed_lwps, count_events_callback,
    	select_singlestep_lwp_callback, select_event_lwp_callback,
    	unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
    	suspend_and_send_sigstop_callback, wait_for_sigstop,
    	stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
    	lwp_running, linux_set_resume_request, resume_status_pending_p,
    	need_step_over_p, start_step_over, linux_resume_one_thread,
    	proceed_one_lwp, unsuspend_and_proceed_one_lwp,
    	reset_lwp_ptrace_options_callback): Update.
    	* linux-mips-low.c (update_watch_registers_callback): Update.
    	* regcache.c (regcache_invalidate_one, regcache_invalidate):
    	Update.
    	(free_register_cache_thread_one): Remove.
    	(regcache_release): Update.
    	* server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
    	handle_qxfer_threads_worker): Update.
    	(handle_query): Update, use list iterator.
    	(visit_actioned_threads, handle_pending_status,
    	queue_stop_reply_callback, gdb_wants_all_threads_stopped,
    	clear_pending_status_callback, set_pending_status_callback,
    	find_status_pending_thread_callback, handle_status,
    	process_serial_event): Update.
    	* target.c (thread_search_callback): Update.
    	* thread-db.c (thread_db_get_tls_address): Update.
    	* tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
    	Update.
    	* win32-i386-low.c (update_debug_registers_callback): Update.
    	* win32-low.c (delete_thread_info, child_delete_thread,
    	continue_one_thread, suspend_one_thread,
    	get_child_debug_event): Adjust.

commit 9179355e655d78cf44ffdfb432e134eabceaebab
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 09:10:42 2017 -0400

    gdbserver: Use std::list for all_processes
    
    Remove the usage of inferior_list for the all_processes list in
    gdbserver, replace it with an std::list. The entry field in process_info
    is removed, and replaced by a simple pid field.
    
    The pid_of macro, used for both processes and threads, is replaced with
    separate functions.  For completeness, I changed ptid_of and lwpid_of to
    functions as well.
    
    gdb/gdbserver/ChangeLog:
    
    	* gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
    	* inferiors.h: Include <list>.
    	(struct process_info) <entry>: Remove field.
    	<pid>: New field.
    	(pid_of): Change macro to function.
    	(ptid_of, lwpid_of): Remove macro.
    	(all_processes): Change type to std::list<process_info *>.
    	(ALL_PROCESSES): Remove macro.
    	(for_each_process, find_process): New function.
    	* inferiors.c (all_processes): Change type to
    	std::list<process_info *>.
    	(find_thread_process): Adjust.
    	(add_process): Likewise.
    	(remove_process): Likewise.
    	(find_process_pid): Likewise.
    	(get_first_process): Likewise.
    	(started_inferior_callback): Remove.
    	(have_started_inferiors_p): Adjust.
    	(attached_inferior_callback): Remove.
    	(have_attached_inferiors_p): Adjust.
    	* linux-low.c (check_zombie_leaders): Likewise.
    	* linux-x86-low.c (x86_arch_setup_process_callback): Remove.
    	(x86_linux_update_xmltarget): Adjust.
    	* server.c (handle_query): Likewise.
    	(gdb_reattached_process): Remove.
    	(handle_status): Adjust.
    	(kill_inferior_callback): Likewise.
    	(detach_or_kill_inferior): Remove.
    	(print_started_pid): Likewise.
    	(print_attached_pid): Likewise.
    	(detach_or_kill_for_exit): Update.
    	(process_serial_event): Likewise.
    	* linux-arm-low.c (arm_new_fork): Likewise.

commit c9cb8905b489d094c6c42e103d4bc6e231e00cf0
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 09:09:21 2017 -0400

    gdbserver: Use std::list for all_dlls
    
    As a small step towards removing inferior_list/inferior_list_entry, this
    patch replaces the usage of inferior_list for the list of dlls by an
    std::list.  The dll_info type now uses an std::string for name and has a
    simple constructor.
    
    I am able to build gdbserver with mingw on Linux, but I am not able to
    test this on a Windows machine (the only platform that uses this code).
    
    gdb/gdbserver/ChangeLog:
    
    	* dll.h: Include <list>.
    	(struct dll_info): Add constructor.
    	<entry>: Remove field.
    	(all_dlls): Change type to std::list<dll_info>.
    	* dll.c: Include <algorithm>.
    	(get_dll): Remove macro.
    	(all_dlls): Change type to std::list<dll_info *>.
    	(free_one_dll): Remove.
    	(match_dll): Likewise.
    	(loaded_dll): Adjust.
    	(unloaded_dll): Adjust to all_dlls type change, use
    	std::find_if.  Inline code from match_dll.
    	(clear_dlls): Adjust to all_dlls type change.
    	* server.c (emit_dll_description): Remove.
    	(handle_qxfer_libraries): Adjust to all_dlls type change,
    	integrate emit_dll_description's functionality.

commit 2098b39391a5ade9ed308d76f2dfc7ceedd2d9a3
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 08:47:44 2017 -0400

    Make to_traceframe_info return a unique_ptr
    
    Since this target method returns an allocated object, return a
    unique_ptr.  It allows getting rid a some cleanups here and there.
    
    I had to shuffle the includes around.  First, target.h now needs to
    include tracepoint.h, to get the definition of traceframe_info_up.
    However, the definition of enum trace_find_type was later in target, so
    I had to move it to tracepoint.h, so that the declaration of tfind_1
    could know about it.  I then had to remove the include of target.h from
    tracepoint.h, which caused a circular dependency (it was probably
    included to get enum trace_find_type in the first place anyway).
    
    Regression tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* target.h: Include tracepoint.h.
    	(enum trace_find_type): Move to tracepoint.h.
    	(struct target_ops) <to_traceframe_info>: Return a unique ptr.
    	* tracepoint.h: Don't include target.h
    	(enum trace_find_type): Move from target.h.
    	(parse_traceframe_info): Return a unique ptr.
    	* tracepoint.c (current_traceframe_info): Change type to unique
    	ptr.
    	(free_traceframe_info): Remove.
    	(clear_traceframe_info): Don't manually free
    	current_traceframe_info.
    	(free_result): Remove.
    	(parse_traceframe_info): Return a unique ptr.
    	(get_traceframe_info): Adjust to unique ptr.
    	* ctf.c (ctf_traceframe_info): Return a unique ptr.
    	* remote.c (remote_traceframe_info): Return a unique ptr.
    	* tracefile-tfile.c (tfile_traceframe_info): Return a unique
    	ptr.
    	* target-debug.h (target_debug_print_traceframe_info_up): New
    	macro.
    	* target-delegates.c: Regenerate.

commit 4cdd21a8d3fd943d6993e9d053edf09583802744
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 08:43:54 2017 -0400

    Use std::vector for traceframe_info::memory
    
    Straightforward change from a VEC to std::vector.  This allows making
    the destruction of a traceframe_info trivial.
    
    I added a constructor with parameters to mem_range to be able to
    emplace_back directly with the values.  It is necessary to leave a
    default constructor there because mem_range is still used in a VEC.
    
    gdb/ChangeLog:
    
    	* memrange.h (struct mem_range): Add constructors.
    	* tracepoint.h (struct traceframe_info) <memory>: Change type to
    	std::vector<mem_range>.
    	* tracepoint.c (free_traceframe_info): Don't manually free
    	vector.
    	(traceframe_info_start_memory): Adjust to vector change.
    	(traceframe_available_memory): Likewise.
    	* tracefile-tfile.c (build_traceframe_info): Likewise.
    	* ctf.c (ctf_traceframe_info): Likewise.

commit d0d292a27402ee2d3f91d541371f134f91730373
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 08:42:23 2017 -0400

    Use std::vector for traceframe_info::tvars
    
    Straightforward change to get rid of a VEC.  We need to new/delete
    traceframe_info instead of malloc/free it.  I found three places that
    allocate a traceframe_info (ctf_traceframe_info, tfile_traceframe_info
    and parse_traceframe_info) and only one that frees it
    (free_traceframe_info).
    
    gdb/ChangeLog:
    
    	* tracepoint.h (struct traceframe_info) <tvars>: Change type to
    	std::vector<int>.
    	* tracepoint.c (free_traceframe_info): Deallocate with delete.
    	(traceframe_info_start_tvar): Adjust to vector change.
    	(parse_traceframe_info): Allocate with new.
    	* ctf.c (ctf_traceframe_info): Allocate with new, adjust to
    	vector change.
    	* tracefile-tfile.c (build_traceframe_info): Adjust to vector
    	change.
    	tfile_traceframe_info): Allocate with new.
    	* mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
    	change.

commit 8d3c73ef6b1aff1b22296bd48ec302b4b1d4808c
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 14 08:41:01 2017 -0400

    Rename traceframe_info variable to current_traceframe_info
    
    ... so it doesn't shadow the traceframe_info type.  It think it's a
    clearer name anyway.
    
    gdb/ChangeLog:
    
    	* tracepoint.c (traceframe_info): Rename to...
    	(current_traceframe_info): ...this.
    	(clear_traceframe_info): Adjust.
    	(get_traceframe_info): Adjust.

commit b129dcac882da87767cb863ad8b2572f90e9e5bc
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 14 08:38:02 2017 -0400

    Use std::vector in linux_xfer_osdata_processgroups
    
    This simplifies the code quite a bit, by removing the array of PID_T
    that's actually an array of pairs of PID_T.
    
    This code is only used to implement "info os procgroups".  I tested by hand
    as well as by running gdb.base/info-os.exp for unix, native-gdbserver
    and native-extended-gdbserver.
    
    gdb/ChangeLog:
    
    	* nat/linux-osdata.c: Include algorithm.
    	(compare_processes): Remove.
    	(struct pid_pgid_entry): New struct.
    	(linux_xfer_osdata_processgroups): Use std::vector instead of
    	XNEWVEC.

commit af5bf4ada48ff65b6658be1fab8f9c8f8ab5f319
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Oct 14 08:06:29 2017 -0400

    Replace psymbol_allocation_list with std::vector
    
    psymbol_allocation_list is basically a vector implementation.  We can
    replace it with an std::vector, now that objfile has been C++-ified.
    
    I sent this to the buildbot, there are a few suspicious failures, but
    I don't think they are related to this patch.  For example on powerpc:
    
    new FAIL: gdb.base/catch-syscall.exp: execve: syscall execve has returned
    new FAIL: gdb.base/catch-syscall.exp: execve: continue to main
    new FAIL: gdb.base/catch-syscall.exp: execve: continue until exit
    
    I get the same failures when testing manually on gcc112, without this
    patch.
    
    gdb/ChangeLog:
    
    	* objfiles.h: Don't include symfile.h.
    	(struct partial_symbol): Remove forward-declaration.
    	(struct objfile) <global_psymbols, static_psymbols>: Change type
    	to std::vector<partial_symbol *>.
    	* objfiles.c (objfile::objfile): Don't memset those fields.
    	(objfile::~objfile): Don't free those fields.
    	* psympriv.h (struct psymbol_allocation_list): Remove
    	forward-declaration.
    	(add_psymbol_to_list): Change psymbol_allocation_list parameter
    	to std::vector.
    	(start_psymtab_common): Change parameters to std::vector.
    	* psymtab.c: Include algorithm.
    	(require_partial_symbols): Call shrink_to_fit.
    	(find_pc_sect_psymbol): Adjust to vector change.
    	(match_partial_symbol): Likewise.
    	(lookup_partial_symbol): Likewise.
    	(psym_relocate): Likewise.
    	(dump_psymtab): Likewise.
    	(recursively_search_psymtabs): Likewise.
    	(compare_psymbols): Remove.
    	(sort_pst_symbols): Adjust to vector change.
    	(start_psymtab_common): Likewise.
    	(end_psymtab_common): Likewise.
    	(psymbol_bcache_full): De-constify return value.
    	(add_psymbol_to_bcache): Likewise.
    	(extend_psymbol_list): Remove.
    	(append_psymbol_to_list): Adjust to vector change.
    	(add_psymbol_to_list): Likewise.
    	(init_psymbol_list): Likewise.
    	(maintenance_info_psymtabs): Likewise.
    	(maintenance_check_psymtabs): Likewise.
    	* symfile.h (struct psymbol_allocation_list): Remove.
    	* symfile.c (reread_symbols): Adjust to vector change.
    	* dbxread.c (start_psymtab): Change type of parameters.
    	(dbx_symfile_read): Adjust to vector change.
    	(read_dbx_symtab): Likewise.
    	(start_psymtab): Change type of parameters.
    	* dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
    	(create_partial_symtab): Likewise.
    	(add_partial_symbol): Likewise.
    	(write_one_signatured_type): Likewise.
    	(recursively_write_psymbols): Likewise.
    	* mdebugread.c (parse_partial_symbols): Likewise.
    	* xcoffread.c (xcoff_start_psymtab): Change type of parameters.
    	(scan_xcoff_symtab): Adjust to vector change.
    	(xcoff_initial_scan): Likewise.

commit 3ec5942fbf8501db10784b0dff7d24222a113728
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Oct 13 22:45:14 2017 -0400

    ada: Use std::string in print_dynamic_range_bound
    
    Replace this usage of GROW_VECT with an std::string.  I don't think
    there's a reason for this variable to be static, other than it was
    cumbersome to manage its lifetime (i.e. use a cleanup) before.
    
    Tested by comparing the gdb.ada/*.exp test results before and after the
    patch.
    
    gdb/ChangeLog:
    
    	* ada-typeprint.c (print_dynamic_range_bound): Use std::string.

commit 867d918419528a1bc18286f4f13ff69fcf17e0c9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Oct 14 00:00:20 2017 +0000

    Automatic date update in version.in

commit 300b6685f17cae131166eaf2fcafe10dab06466b
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 18:20:25 2017 +0100

    Skip a few tests on targets that can't use the "run" commmand.
    
    These tests want to use raw "run", so skip them on targets that can't
    do that.
    
    Also adds a small utility procedure that clearly conveys intent instead of
    explicitly checking use_gdb_stub in the testcases.
    
    This makes sure these testcases continue to be skipped with
    --target_board=native-gdbserver once that board stops setting
    is_remote.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* lib/gdb.exp (target_can_use_run_cmd): New procedure.
    	* gdb.base/annota1.exp: Use it instead of is_remote.
    	* gdb.base/annota3.exp: Use it instead of is_remote.
    	* gdb.cp/annota2.exp: Use it instead of is_remote.
    	* gdb.cp/annota3.exp: Use it instead of is_remote.
    	* gdb.multi/bkpt-multi-exec.exp: Use it instead of is_remote.

commit 50500caf810fcc6c05e3fd89bc37fe8f9e4adb07
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 18:27:20 2017 +0100

    Fix gdb.base/testenv.exp against --target_board=native-extended-gdbserver
    
    Currently we get:
    
      Running ..../src/gdb/testsuite/gdb.base/testenv.exp ...
      FAIL: gdb.base/testenv.exp: test no TEST_GDB var
      FAIL: gdb.base/testenv.exp: test with one TEST_GDB var
      FAIL: gdb.base/testenv.exp: test with two TEST_GDB var
      FAIL: gdb.base/testenv.exp: test with one TEST_GDB var, after unset
      FAIL: gdb.base/testenv.exp: test with TEST_GDB_GLOBAL
      FAIL: gdb.base/testenv.exp: test with TEST_GDB_GLOBAL unset
    
    The problem is that the testcase relies on stdio.  While we could fix
    this for gdbserver by read output from inferior_spawn_id, a better fix
    it to not rely on stdio at all.  That's what this commit does.
    Instead, it reads variables off of the inferior to extract the
    necessary information.
    
    Along the way, most of the .exp file is reimplemented/cleaned up using
    more modern mechanisms.  E.g., with_test_prefix, proc_with_prefix,
    save_vars, etc.  Also, a missing check for "is_remote host" is added.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/testenv.exp: Check use_gdb_stub instead of is_remote.
    	(test_num_test_vars, run_and_count_vars, find_env)
    	(test_set_unset_env, test_inherit_env_var): New procedures.
    	(top level): Use them.

commit dad0c6d2f7410d3b451800f856f3c6818303c316
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 18:29:21 2017 +0100

    Don't run gdb.gdb/ selftests if use_gdb_stub is true
    
    If we make the native-gdbserver board be !is_remote, then the few
    tests that use the selftest-support.exp routines to debug gdb itself
    start running, and fail, with something like:
    
      Running ..../src/gdb/testsuite/gdb.gdb/selftest.exp ...
      ERROR: tcl error sourcing ..../src/gdb/testsuite/gdb.gdb/selftest.exp.
      ERROR: gdbserver does not support run [....] without extended-remote
          while executing
      "error "gdbserver does not support $command without extended-remote""
          (procedure "gdb_test_multiple" line 25)
          invoked from within
      "gdb_test_multiple "run $INTERNAL_GDBFLAGS" "$description" {
    	  -re "Starting program.*Breakpoint \[0-9\]+,.*$function \\(\\).* at .*main.c:.*$gdb..."
          (procedure "selftest_setup" line 45)
    
    This commit makes sure those tests continue to be skipped.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* lib/selftest-support.exp (selftest_setup): Extend comments, and
    	also skip on stub-like targets.

commit 8b0553c18f0dc63ab0ae930f2e8eed2bce4cd32c
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 16:34:50 2017 +0100

    Make gdb.base/find-unmapped.exp pass on remote targets
    
    Currently, with --target_board=native-extended-gdbserver, we get:
    
      Running .../src/gdb/testsuite/gdb.base/find-unmapped.exp ...
      FAIL: gdb.base/find-unmapped.exp: find global_var_0, global_var_2, 0xff
      FAIL: gdb.base/find-unmapped.exp: find global_var_1, global_var_2, 0xff
      FAIL: gdb.base/find-unmapped.exp: find global_var_2, (global_var_2 + 16), 0xff
    
    This commit makes the test pass there, and also enables in on
    --target_board=native-gdbserver, and other remote targets.
    
    I've filed PR gdb/22293 to track the missing-warning problem.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/22293
    	* gdb.base/find-unmapped.exp: Don't skip if is_remote target.
    	(top level): Move some tests to ...
    	(test_not_found): ... this new procedure.
    	(top level): Call it.

commit 2399fe6ab0b6ee64c569992e4bc3bbae3b5b2193
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 13 15:36:49 2017 +0100

    Simplify tic6x and s390x expedite registers
    
    Nowadays, we have six tic6x expedite registers, which are duplicated.
    
    tic6x-c64xp-expedite = A15,PC
    tic6x-c64x-expedite = A15,PC
    tic6x-c62x-expedite = A15,PC
    tic6x-c64xp-linux-expedite = A15,PC
    tic6x-c64x-linux-expedite = A15,PC
    tic6x-c62x-linux-expedite = A15,PC
    
    in features/Makefile, we have
    
       echo "expedite:$(if $($*-expedite),$($*-expedite),$($(firstword $(subst -, ,$(notdir $*)))-expedite))" \
            >> $(outdir)/$*.tmp
    
    which means for a given bar/foo-baz.xml, we'll look for either
    bar/foo-baz-expedite or foo-expedite.  We can define only one generic
    expedite register for all different ti6cx and s390x target descriptions.
    Actually, we've done that for x86 target descriptions.
    
    Re-run 'make GDB=/path/build/gdb all' to regenerate regformats/*.dat files,
    and they are not changed.
    
    gdb:
    
    2017-10-13  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
    	Remove s390x-*-expedite, add s390x-expedite.

commit 4bf3f4a810813214213ad4f7d869eb24e79d77af
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 13 15:28:10 2017 +0100

    Regenerate features/s390-gs-linux64.c and features/s390x-gs-linux64.c
    
    gdb:
    
    2017-10-13  Yao Qi  <yao.qi@linaro.org>
    
    	* features/s390-gs-linux64.c: Regenerated.
    	* features/s390x-gs-linux64.c: Regenerated.

commit 354bac403e9a19bbbfb676d854db5f11f0e84c27
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Oct 13 15:23:35 2017 +1030

    PR22263 testcase
    
    A number of targets need dynamic relocs in PIEs for reasons other than
    relocating thread variables.  The PR is about text relocations, and,
    reading between the lines, unnecessary dynamic tprel relocations.
    Change the test to check for those conditions rather than no dynamic
    relocations
    
    	PR ld/22263
    	* testsuite/ld-elf/tls.exp: Link with -z text.
    	* testsuite/ld-elf/pr22263-1.rd: Test for tprel relocs.

commit 9e86da0760aa1e52178cc5b90cd92a7cd4a338f9
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Oct 11 14:43:57 2017 -0600

    Change objfile to use new/delete
    
    This changes objfiles to use new and delete rather than xmalloc and
    free.  Simon noticed that it uses a non-POD and so shouldn't be
    allocated with XCNEW; and I wanted to be able to use another non-POD as
    a member; this patch is the result.
    
    Regression tested by the buildbot.
    
    2017-10-13  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile-object-run.c (do_module_cleanup): Use delete.
    	* solib.c (update_solib_list, reload_shared_libraries_1): Use
    	delete.
    	* symfile.c (symbol_file_add_with_addrs): Use new.
    	(symbol_file_add_separate): Update comment.
    	(syms_from_objfile_1, remove_symbol_file_command): Use delete.
    	* jit.c (jit_object_close_impl): Use new.
    	(jit_unregister_code): Use delete.
    	* objfiles.c (objfile::objfile): Rename from allocate_objfile.
    	(~objfile): Rename from free_objfile.
    	(free_objfile_separate_debug, do_free_objfile_cleanup)
    	(free_all_objfiles, objfile_purge_solibs): Use delete.
    	* objfiles.h (struct objfile): Add constructor and destructor.
    	Use DISABLE_COPY_AND_ASSIGN.  Add initializers to data members.
    	(allocate_objfile, free_objfile): Don't declare.
    	(struct objstats): Add initializers.

commit 7594f6236073fcc8696c43e1f5267e61f7d5c226
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 13:38:24 2017 +0100

    Fix gdb.base/term.exp on non-"target native" boards
    
    With --target_board=native-extended-gdbserver, we get:
    
      Running .../src/gdb/testsuite/gdb.base/term.exp ...
      FAIL: gdb.base/term.exp: info terminal at breakpoint
    
      (gdb) info terminal
      No saved terminal information.
    
    Fix it by running the test everywhere, and expecting different output
    on non-native targets.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/term.exp: Don't skip if is_remote target.  Instead,
    	expect different "info terminal" output if testing with a
    	non-native target.

commit ebe3b40202042fc644df5ea3bd111425ba1aeeee
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 13:25:20 2017 +0100

    Remove is_remote kfail from gdb.python/py-evthreads.exp
    
    This testcase works fine with gdbserver nowadays.  So remove the
    kfail.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi  <simon.marchi@polymtl.ca>
    
    	PR python/12966
    	* gdb.python/py-evthreads.exp: Remove is_remote target kfail.

commit 42f1b1617e4f8c8f485318897c5154cbff58eeb0
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 13:15:04 2017 +0100

    Fix gdb.python/py-evthreads.exp with --target_board=native-extended-gdbserver
    
    Fixes:
      Running ..../src/gdb/testsuite/gdb.python/py-evthreads.exp ...
      FAIL: gdb.python/py-evthreads.exp: run to breakpoint 1
      FAIL: gdb.python/py-evthreads.exp: reached breakpoint 2
      FAIL: gdb.python/py-evthreads.exp: thread 2
      FAIL: gdb.python/py-evthreads.exp: reached breakpoint 3
      FAIL: gdb.python/py-evthreads.exp: thread 3
      FAIL: gdb.python/py-evthreads.exp: continue thread 1
      [... cascading time outs ...]
    
    By following the usual pattern that makes sure that non-stop is enabled
    before connecting to gdbserver.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.python/py-evthreads.exp: Start GDB with "set non-stop on"
    	already.

commit 8d6ef72b0470dfb1133525c8c4556d3578744ac4
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 12:27:49 2017 +0100

    kfail gdb.python/py-evsignal.exp on RSP targets properly
    
    Fixes, with --target_board=native-extended-gdbserver:
    
       Running ..../src/gdb/testsuite/gdb.python/py-evsignal.exp ...
       FAIL: gdb.python/py-evsignal.exp: signal Thread 3
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.python/py-evsignal.exp: Check gdb_protocol instead of
    	is_remote.

commit d7bcd5b8e55c54543389196fd18453db6961e314
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 12:18:50 2017 +0100

    Skip gdb.threads/thread_events.exp on RSP targets properly
    
    Fixes, with --target_board=native-extended-gdbserver:
    
      Running ..../src/gdb/testsuite/gdb.threads/thread_events.exp ...
      FAIL: gdb.threads/thread_events.exp: continue to after_join_func with messages enabled (saw 0, expected 1)
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/thread_events.exp: Check gdb_protocol instead of
    	is_remote.

commit df479dc6e045beb77052f96280798e48ee1feb6c
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 11:25:42 2017 +0100

    Tweak gdb.base/corefile.exp is_remote check
    
    1. Otherwise, when we make native-gdbserver board no longer is_remote,
       we get:
    
      Running .../src/gdb/testsuite/gdb.base/corefile.exp ...
      ERROR: tcl error sourcing .../src/gdb/testsuite/gdb.base/corefile.exp.
      ERROR: gdbserver does not support attach 9327 without extended-remote
          while executing
      "error "gdbserver does not support $command without extended-remote""
    
      That's fixed by using can_spawn_for_attach instead.
    
    2. The gdb_protocol check fixes this current problem with
       --target_board=extended-remote-gdbserver:
    
         Running .../src/gdb/testsuite/gdb.base/corefile.exp ...
         FAIL: gdb.base/corefile.exp: run: with core
         FAIL: gdb.base/corefile.exp: run: core file is cleared
         FAIL: gdb.base/corefile.exp: attach: with core
         FAIL: gdb.base/corefile.exp: attach: core file is cleared
    
       gdb.log:
         (...)
         attach 10859
         Don't know how to attach.  Try "help target".
         (...)
    
    The fix for #2 alone would fix #1 too, but can_spawn_for_attach
    expresses the requirement directly, so I still left it there.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/corefile.exp (corefile_test_run): Skip if gdb_protocol
    	is set.
    	(corefile_test_attach): Likewise.  Check can_spawn_for_attach
    	instead of is_remote.

commit 23fb630af09f2601e7cb75233837399d67cfd017
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 10:48:42 2017 +0100

    Fix is_remote check in gdb.base/remote.exp
    
    1. Otherwise, when the native-gdbserver board stops setting is_remote,
       this test would stop running there.
    
    2. Makes the test run with --target_board=native-extended-gdbserver
       too.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/remote.exp: Check gdb_protocol instead of is_remote.
    	(top level): Add comment.

commit cc77b1dc33790bcb852c8c72e2efebaa3b505b01
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 11:14:06 2017 +0100

    gdb.base/remote.exp: Fix typo and add missing return
    
    (Dropped 'u' while at it because we're supposed to prefer American
    English spelling...)
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/remote.exp (top level): Fix comment typo and add
    	missing return.

commit 27c9e813f93974c2d1e237f3c4f25029627bcb58
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 10:26:06 2017 +0100

    Make gdb.base/solib-nodir.exp work with --target_board=native-extended-gdbserver
    
    Fixes:
     Running .../src/gdb/testsuite/gdb.base/solib-nodir.exp ...
     FAIL: gdb.base/solib-nodir.exp: library loaded
    
    ... by using the new "set cwd" command.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi <simon.marchi@polymtl.ca>
    
    	* gdb.base/solib-nodir.exp: Split is_remote and skip_shlib_tests
    	calls and add comments.  Skip test if use_gdb_stub is set.
    	(top level): Use "set cwd" command instead of "cd" command.

commit 5e830d9807b91f806524ff822d953443c8fb3d2f
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 10:11:57 2017 +0100

    Eliminate is_remote check in gdb.base/shlib-call.exp
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/shlib-call.exp (top level): Use gdb_run_cmd and remove
    	is_remote target check.

commit c2508e905f956c5a5e0d2a7fff58b4c746180237
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Oct 12 21:42:05 2017 -0400

    Remove simple_displaced_step_copy_insn
    
    Nothing uses this function.  Remove it, and adjust comments referring to
    it.
    
    gdb/ChangeLog:
    
    	* arch-utils.h (simple_displaced_step_copy_insn): Remove.
    	* arch-utils.c (simple_displaced_step_copy_insn): Remove.
    	* gdbarch.sh (displaced_step_copy_insn): Adjust comment.
    	* gdbarch.h: Regenerate.
    	* i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
    	Adjust comment.
    	* i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
    	(i386_displaced_step_fixup): Adjust comment.
    	* rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.

commit 3b4b0a629a972bf80fc0ac6202f89681fab1df37
Author: James Bowman <jamesb@excamera.com>
Date:   Thu Oct 12 18:37:40 2017 -0700

    FT32: support for FT32B processor - part 1
    
    FT32B is a new FT32 family member. It has a code
    compression scheme, which requires the use of linker
    relaxations. The change is quite large, so submission
    is in several parts.
    
    Part 1 adds a 15-bit instruction field, and CPU-specific functions for
    the code compression that are used in binutils and GDB.
    
    bfd/ChangeLog:
    
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* bfd-in2.h: Regenerate.
    	* libbfd.h: Regenerate.
    	* elf32-ft32.c: Add HOWTO R_FT32_15.
    	* reloc.c: Add BFD_RELOC_FT32_15.
    
    gas/ChangeLog:
    
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* config/tc-ft32.c (md_assemble): Replace FT32_FLD_K8 with
    	K15.
    	(md_apply_fix, tc_gen_reloc): Add BFD_RELOC_FT32_15.
    
    include/ChangeLog:
    
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* elf/ft32.h: Add R_FT32_15.
    	* opcode/ft32.h: Replace FT32_FLD_K8 with K15.
    	(ft32_shortcode, sc_compar, ft32_split_shortcode,
    	ft32_merge_shortcode, ft32_merge_shortcode): New functions.
    
    opcodes/ChangeLog:
    
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* opcodes/ft32-dis.c (print_insn_ft32): Replace FT32_FLD_K8 with K15.
    	* opcodes/ft32-opc.c (ft32_opc_info): Replace FT32_FLD_K8 with
    	K15. Add jmpix pattern.
    
    sim/ChangeLog:
    
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* sim/ft32/interp.c (step_once): Replace FT32_FLD_K8 with K15.

commit d268bbaff7da90caf5fbc94456ae58315ffa1802
Author: James Bowman <jamesb@excamera.com>
Date:   Thu Oct 12 18:12:42 2017 -0700

    Add myself as ft32 maintainer for sim.
    
    sim/ChangeLog:
    2017-10-12  James Bowman  <james.bowman@ftdichip.com>
    
    	* MAINTAINERS (ft32): Add myself.

commit f5ca00321dd8da526b8a6a894465bdc7a14d30ac
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 01:27:18 2017 +0100

    Eliminate is_remote check in gdb.base/scope.exp
    
    This commit makes --target_board=native-gdbserver (and in principle
    all other is_remote boards) pass all the same gdb.base/scope.exp tests
    as native testing.
    
    I first wrote the gdb.base/scope.exp change described in the ChangeLog
    below and in the new comments in the patch, knowing that gdb_file_cmd
    was the right thing to use here.
    
    However, that revealed that the native-extended-gdbserver board should
    be overriding gdb_file_cmd+gdb_reload instead of gdb_load, as is
    hinted at by the comments on top of the default implementations in
    testsuite/lib/gdb.exp, because otherwise a gdb_run_cmd after
    gdb_file_cmd misses setting "set remote exec-file".  However, if we do
    that and remove gdb_load, then we regress gdb.base/dbx.exp, so for now
    keep the gdb_load override as well.
    
    gdb/testsuite/ChangeLog:
    2017-10-13  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/scope.exp: Use build_executable + clean_restart +
    	gdb_file_cmd instead of prepare_for_testing and no longer skip
    	"before run" tests on is_remote target boards.  Update comments.
    	* boards/native-extended-gdbserver.exp
    	(extended_gdbserver_load_last_file): New, factored out from ...
    	(gdb_load): ... this.  Move further below and add comment.
    	(extended_gdbserver_gdb_file_cmd, gdb_file_cmd, gdb_reload): New.

commit 52a58c224d5d45cc6d7749e2d93827c218562a30
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Oct 13 00:00:29 2017 +0000

    Automatic date update in version.in

commit 8aed1c0d04e6d0eb7d0790c4691665cffef573b7
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 13 00:40:23 2017 +0100

    Remove references to gdb64 in the testsuite
    
    I'm not sure whether this gdb64 was ever a thing in the upstream repo,
    but it certainly doesn't exist nowadays.
    
    AFAICT, this came in with the original big merge with the HP tree:
    https://sourceware.org/ml/gdb-patches/1999-q2/msg00149.html
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/attach.exp: Remove references to gdb64.
    	* gdb.base/dbx.exp: Remove references to gdb64.

commit cfa34c871c6644bd7b132b5ca7f2217880f5fa9b
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Thu Oct 12 23:14:09 2017 +0100

    Remove is_remote check in labels.exp
    
    This works fine with remote target boards.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Simon Marchi  <simon.marchi@polymtl.ca>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/label.exp: Remove is_remote target check.

commit 9192b7decc7256a41502bf68df36f429cceffc89
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 23:06:15 2017 +0100

    Make gdb.base/auvx.exp work with --target_board=native-extended-gdbserver
    
    Currently we get:
     Running .../src/gdb/testsuite/gdb.base/auxv.exp ...
     WARNING: can't generate a core file - core tests suppressed - check ulimit -c
    
    After this commit we get all the same PASSes as when native testing.
    
    The problem is that the testcase wants to create a core dump in a
    temporary directory and it is using the "cd" command to start the
    inferior with that directory as current directory, but that command
    only affects the inferior's cwd when native debugging.  Fix it by
    using using the new "set cwd" command instead, which works with
    gdbserver as well.
    
    This still won't work with stub-like targets, because with those when
    we connect the inferior is already running.  It'd be possible to make
    it work by making the inferior itself change dirs, but we'll need to
    make the native-gdbserver board no longer set is_remote first.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/auvx.exp (coredir): Update comment.
    	(top level) <core_works>: Use "set cwd" command instead of "cd"
    	command.

commit 74ffa566739c7e98568a9aa8b5ab8d8f3730d30d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 12 14:41:22 2017 -0700

    Add a compile-time test for PR ld/22263
    
    This compile-time test requires a target C compiler to run.  It fails
    on many targets where ELF backend linkers incorrectly check bfd_link_pic
    for TLS relocations, which should check bfd_link_executable instead.
    
    	PR ld/22263
    	* testsuite/ld-elf/pr22263-1.rd: New file.
    	* testsuite/ld-elf/pr22263-1a.c: Likewise.
    	* testsuite/ld-elf/pr22263-1b.c: Likewise.
    	* testsuite/ld-elf/tls.exp: Likewise.

commit a900ff724a725ea951ba8b17232577e1a4b4866e
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Oct 7 20:13:42 2017 -0600

    Use bool in pv_area
    
    This updates a couple of member functions in pv_area to return bool.
    
    gdb/ChangeLog
    2017-10-12  Tom Tromey  <tom@tromey.com>
    
    	* prologue-value.h (pv_area::store_would_trash): Return bool.
    	(pv_area::find_reg): Likewise.
    	* prologue-value.c (pv_area::store_would_trash): Return bool.
    	(pv_area::find_reg): Likewise.

commit f7b7ed97a23e2bf4a2ec27bef0fe0af55a080a94
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Oct 7 18:23:36 2017 -0600

    C++-ify prologue-value's pv_area
    
    This patch is an initial C++-ification of pv_area, from
    prologue-value.  It turns pv_area into a class with a constructor and
    destructor; renames the data members; and changes various functions to
    be member functions.  This allows the removal of
    make_cleanup_free_pv_area.
    
    gdb/ChangeLog
    2017-10-12  Tom Tromey  <tom@tromey.com>
    
    	* s390-linux-tdep.c (s390_store, s390_load)
    	(s390_check_for_saved, s390_analyze_prologue): Update.
    	* rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
    	* rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
    	* prologue-value.h (class pv_area): Move from prologue-value.c.
    	Change names of members.  Add constructor, destructor, member
    	functions.
    	(make_pv_area, free_pv_area, make_cleanup_free_pv_area)
    	(pv_area_store, pv_area_fetch, pv_area_store_would_trash)
    	(pv_area_fetch, pv_area_scan): Don't declare.
    	* prologue-value.c (struct pv_area::area_entry): Now member of
    	pv_area.
    	(struct pv_area): Move to prologue-value.h.
    	(pv_area::pv_area): Rename from make_pv_area.
    	(pv_area::~pv_area): Rename from free_pv_area.
    	(do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
    	(clear_entries, find_entry, overlaps, store_would_trash, store)
    	(fetch, find_reg, scan): Now member of pv_area.
    	Remove "area" argument.  Update.
    	* msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
    	Update.
    	* mn10300-tdep.c (push_reg, check_for_saved)
    	(mn10300_analyze_prologue): Update.
    	* mep-tdep.c (is_arg_spill, check_for_saved)
    	(mep_analyze_prologue): Update.
    	* m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
    	(m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
    	(m32c_is_struct_return, m32c_analyze_prologue): Update.
    	* arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
    	Update.
    	* arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
    	* aarch64-tdep.c (aarch64_analyze_prologue): Update.

commit 04ec7890fccfa5ddd9cc92961a4df58957ca181b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Oct 12 16:49:27 2017 -0400

    linux low: Make the arch code free arch_process_info
    
    For the same reason as the previous patch, we need to make the
    arch-specific code free the arch_process_info structure it allocates.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.h (struct linux_target_ops) <delete_process>: New
    	field.
    	* linux-low.c (linux_mourn): Call the_low_target.delete_process.
    	* linux-aarch64-low.c (aarch64_linux_delete_process): New.
    	(struct linux_target_ops): Add delete_process callback.
    	* linux-arm-low.c (arm_delete_process): New.
    	(struct linux_target_ops): Add delete_process callback.
    	* linux-bfin-low.c (struct linux_target_ops): Likewise.
    	* linux-crisv32-low.c (struct linux_target_ops): Likewise.
    	* linux-m32r-low.c (struct linux_target_ops): Likewise.
    	* linux-mips-low.c (mips_linux_delete_process): New.
    	(struct linux_target_ops): Add delete_process callback.
    	* linux-ppc-low.c (struct linux_target_ops): Likewise.
    	* linux-s390-low.c (struct linux_target_ops): Likewise.
    	* linux-sh-low.c (struct linux_target_ops): Likewise.
    	* linux-tic6x-low.c (struct linux_target_ops): Likewise.
    	* linux-tile-low.c (struct linux_target_ops): Likewise.
    	* linux-x86-low.c (x86_linux_delete_process): New.
    	(struct linux_target_ops): Add delete_process callback.
    	* linux-xtensa-low.c (struct linux_target_ops): Likewise.

commit 466eeceef409597388dd2b4e8b907cf080bedcf1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Oct 12 16:48:22 2017 -0400

    lwp_info: Make the arch code free arch_lwp_info
    
    I have the goal of "poisoning" the XNEW/xfree-family of functions, so
    that we catch their usages with non-POD types.  A few things need to be
    fixed in the mean time, this is one.
    
    The common lwp code in linux-nat.c and gdbserver/linux-low.c xfrees the
    private lwp data of type arch_lwp_info.  However, that type is opaque
    from its point of view, as its defined differently in each arch-specific
    implementation.  This trips on the std::is_pod<T> check, since the
    compiler can't tell whether the type is POD or not if it doesn't know
    about it.
    
    My initial patch [1] made a class hierarchy with a virtual destructor.
    However, as Pedro pointed out, we only have one native architecture at
    the time built in gdb and gdbserver, so that's overkill.  Instead, we
    can move the responsibility of free'ing arch_lwp_info to the arch code
    (which is also the one that allocated it in the first place).  This is
    what this patch does.
    
    Also, I had the concern that if we wanted to use C++ features in these
    structures, we would have a problem with the one-definition rule.
    However, since a build will only have one version of arch_lwp_info,
    that's not a problem.
    
    There are changes in arch-specific files, I was only able to built-test
    this patch with the following cross-compilers:
    
      aarch64-linux-gnu
      alpha-linux-gnu
      arm-linux-gnueabihf
      hppa-linux-gnu
      m68k-linux-gnu
      mips64el-linux-gnuabi64
      powerpc64-linux-gnu
      s390x-linux-gnu
      sh4-linux-gnu
      sparc64-linux-gnu
      x86_64-linux-gnu
      x86_64-w64-mingw32
    
    A buildbot run didn't find any regression.
    
    [1] https://sourceware.org/ml/gdb-patches/2017-08/msg00255.html
    
    gdb/ChangeLog:
    
    	* linux-nat.h (linux_nat_set_delete_thread): New declaration.
    	* linux-nat.c (linux_nat_delete_thread): New variable.
    	(lwp_free): Invoke linux_nat_delete_thread if set.
    	(linux_nat_set_delete_thread): New function.
    	* aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
    	thread delete callback.
    	* arm-linux-nat.c (arm_linux_delete_thread): New function.
    	(_initialize_arm_linux_nat): Assign thread delete callback.
    	* s390-linux-nat.c (s390_delete_thread): New function.
    	(_initialize_s390_nat): Assign thread delete callback.
    	* x86-linux-nat.c (x86_linux_add_target): Likewise.
    	* nat/aarch64-linux.c (aarch64_linux_delete_thread): New
    	function.
    	* nat/aarch64-linux.h (aarch64_linux_delete_thread): New
    	declaration.
    	* nat/x86-linux.c (x86_linux_delete_thread): New function.
    	* nat/x86-linux.h (x86_linux_delete_thread): New declaration.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-aarch64-low.c (the_low_target): Add thread delete
    	callback.
    	* linux-arm-low.c (arm_delete_thread): New function.
    	(the_low_target): Add thread delete callback.
    	* linux-bfin-low.c (the_low_target): Likewise.
    	* linux-crisv32-low.c (the_low_target): Likewise.
    	* linux-low.c (delete_lwp): Invoke delete_thread callback if
    	set.
    	* linux-low.h (struct linux_target_ops) <delete_thread>: New
    	field.
    	* linux-m32r-low.c (the_low_target): Add thread delete callback.
    	* linux-mips-low.c (mips_linux_delete_thread): New function.
    	(the_low_target): Add thread delete callback.
    	* linux-ppc-low.c (the_low_target): Likewise.
    	* linux-s390-low.c (the_low_target): Likewise.
    	* linux-sh-low.c (the_low_target): Likewise.
    	* linux-tic6x-low.c (the_low_target): Likewise.
    	* linux-tile-low.c (the_low_target): Likewise.
    	* linux-x86-low.c (the_low_target): Likewise.
    	* linux-xtensa-low.c (the_low_target): Likewise.

commit 6bf0052db8bbeed41e512d1d3ce14ba2a446723d
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 20:06:59 2017 +0100

    Run gdb.base/catch-fork-static.exp on remote target boards
    
    Another case of a stale check.  We support following forks in the
    remote protocol nowadays.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi  <simon.marchi@polymtl.ca>
    
    	* gdb.base/catch-fork-static.exp: No longer skip on is_remote
    	target boards.

commit e48ef82dd2fc85560d14a45a632c82eaaadca7ce
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 19:54:34 2017 +0100

    checkpoint.exp: Check for non-"target native" instead of isnative/is_remote
    
    This gets rid of a number of FAILs with
    --target_board=native-extended-gdbserver.
    
    The fact that checkpointing does not work has nothing to do with
    dejagnu's native and remote concepts.  It only works with native Linux
    targets because the implementation is currently baked with
    linux-nat.c.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi  <simon.marchi@polymtl.ca>
    
    	* gdb.base/checkpoint.exp: Don't check is_remote or isnative.
    	Instead skip if there's any gdb_protocol set.

commit 8d7aea574a8ab3a235088866860df75b542ae4a3
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sun Jan 24 11:22:24 2016 -0500

    Remove is_remote target check from gdb.base/dprintf-non-stop.exp
    
    1. is_remote is not the right check.
    
    2. Both Simon & Pedro ran it continuously for some time against
       native-gdbserver and didn't see a failure.
    
    3. The test has been running against native-extended-gdbserver anyway.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Simon Marchi  <simon.marchi@polymtl.ca>
    	    Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/dprintf-non-stop.exp: Remove is_remote target check.

commit 30440677f3d0cdd2085bea40496774ffa24f6bb1
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 19:16:47 2017 +0100

    Tighten remote check in gdb.base/argv0-symlink.exp
    
    Check for gdbserver instead of dejagnu remote.  Unlike what the
    comment says, the test actually fails with target remote + gdbserver
    (it does pass with extended-remote).  The result is:
    
     FAIL -> KFAIL with --target_board=native-gdbserver
     KPASS -> PASS with --target_board=native-extended-gdbserver
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi  <simon.marchi@polymtl.ca>
    
    	* gdb.base/argv0-symlink.exp: kfail on remote gdbserver,
    	instead of on dejagnu remote boards.

commit 4e04f0450f83d8d0ad08579b5e6c8b4e8a8e693f
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 18:36:08 2017 +0100

    Enable gdb.base/inferior-died.exp on is_remote target boards
    
    We support follow-fork in the remote protocol nowadays.
    
    Also, the right way to enable non-stop mode is to do it before
    connecting, and for use_gdb_stub boards, that means we have to do it
    at gdb_load time.  The "modern" pattern for that is to pass non-stop
    in GDBFLAGS.
    
    This makes the test pass with --target_board=native-gdbserver.
    
    gdb/testsuite/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    	    Simon Marchi <simon.marchi@polymtl.ca>
    
    	* gdb.base/inferior-died.exp: Remove is_remote and isnative
    	checks.  Use build_executable + clean_restart instead of
    	prepare_for_testing.  Pass "set non-stop on" via GDBFLAGS instead
    	of enabling non-stop after starting gdb.

commit 871a186e41aeb7f966c6570b8f1659aec9d2c15d
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 12 18:05:33 2017 +0100

    Enable gdb.threads/non-ldr-exc-*.exp on is_remote target boards
    
    This commit makes the gdb.threads/non-ldr-exc-*.exp tests run (and
    pass) with --target_board=native-gdbserver.
    
    (These tests were already running with
    --target_board=native-extended-gdbserver, because that board is not
    is_remote.)
    
    The "No exec event support in the remote protocol." comment is stale.
    It's actually supported.
    
    gdb/ChangeLog:
    2017-10-12  Pedro Alves  <palves@redhat.com>
    
    	* gdb.threads/non-ldr-exc-1.exp: No longer skip if is_remote target.
    	* gdb.threads/non-ldr-exc-2.exp: Ditto.
    	* gdb.threads/non-ldr-exc-3.exp: Ditto.
    	* gdb.threads/non-ldr-exc-4.exp: Ditto.

commit 6c19b93bcd0d136f7be4d1e1e3f2e8d7b5917009
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Oct 12 21:28:30 2017 +1030

    ld whitespace fixes
    
    	* pe-dll.c: Formatting, whitespace fixes.
    	* NEWS: Whitespace fixes.
    	* configure.ac: Likewise.
    	* configure.tgt: Likewise.
    	* deffilep.y: Likewise.
    	* genscripts.sh: Likewise.
    	* ld.texinfo: Likewise.
    	* ldgram.y: Likewise.
    	* ldlang.c: Likewise.
    	* ldlex.l: Likewise.
    	* lexsup.c: Likewise.
    	* plugin.c: Likewise.
    	* emulparams/arc-endianness.sh: Likewise.
    	* emulparams/elf32_x86_64.sh: Likewise.
    	* emulparams/elf64mmix.sh: Likewise.
    	* emulparams/elf_x86_64.sh: Likewise.
    	* emulparams/h8300elf.sh: Likewise.
    	* emulparams/h8300elf_linux.sh: Likewise.
    	* emulparams/vxworks.sh: Likewise.
    	* emultempl/aarch64elf.em: Likewise.
    	* emultempl/aix.em: Likewise.
    	* emultempl/armelf.em: Likewise.
    	* emultempl/avrelf.em: Likewise.
    	* emultempl/beos.em: Likewise.
    	* emultempl/hppaelf.em: Likewise.
    	* emultempl/m68kcoff.em: Likewise.
    	* emultempl/m68kelf.em: Likewise.
    	* emultempl/metagelf.em: Likewise.
    	* emultempl/msp430.em: Likewise.
    	* emultempl/nds32elf.em: Likewise.
    	* emultempl/pe.em: Likewise.
    	* emultempl/pep.em: Likewise.
    	* emultempl/ppc64elf.em: Likewise.
    	* emultempl/sh64elf.em: Likewise.
    	* emultempl/spu_ovl.S: Likewise.
    	* emultempl/spuelf.em: Likewise.
    	* emultempl/tic6xdsbt.em: Likewise.
    	* emultempl/ticoff.em: Likewise.
    	* emultempl/vms.em: Likewise.
    	* po/Make-in: Likewise.
    	* scripttempl/DWARF.sc: Likewise.
    	* scripttempl/aix.sc: Likewise.
    	* scripttempl/alpha.sc: Likewise.
    	* scripttempl/alphavms.sc: Likewise.
    	* scripttempl/aout.sc: Likewise.
    	* scripttempl/arclinux.sc: Likewise.
    	* scripttempl/armaout.sc: Likewise.
    	* scripttempl/armbpabi.sc: Likewise.
    	* scripttempl/armcoff.sc: Likewise.
    	* scripttempl/avr.sc: Likewise.
    	* scripttempl/crisaout.sc: Likewise.
    	* scripttempl/delta68.sc: Likewise.
    	* scripttempl/dlx.sc: Likewise.
    	* scripttempl/elf.sc: Likewise.
    	* scripttempl/elf32cr16.sc: Likewise.
    	* scripttempl/elf32cr16c.sc: Likewise.
    	* scripttempl/elf32crx.sc: Likewise.
    	* scripttempl/elf32msp430.sc: Likewise.
    	* scripttempl/elf32msp430_3.sc: Likewise.
    	* scripttempl/elf32sh-symbian.sc: Likewise.
    	* scripttempl/elf32xc16x.sc: Likewise.
    	* scripttempl/elf32xc16xl.sc: Likewise.
    	* scripttempl/elf32xc16xs.sc: Likewise.
    	* scripttempl/elf64hppa.sc: Likewise.
    	* scripttempl/elf_chaos.sc: Likewise.
    	* scripttempl/elfarc.sc: Likewise.
    	* scripttempl/elfarcv2.sc: Likewise.
    	* scripttempl/elfd10v.sc: Likewise.
    	* scripttempl/elfd30v.sc: Likewise.
    	* scripttempl/elfi370.sc: Likewise.
    	* scripttempl/elfm68hc11.sc: Likewise.
    	* scripttempl/elfm68hc12.sc: Likewise.
    	* scripttempl/elfmicroblaze.sc: Likewise.
    	* scripttempl/elfxgate.sc: Likewise.
    	* scripttempl/elfxtensa.sc: Likewise.
    	* scripttempl/epiphany_4x4.sc: Likewise.
    	* scripttempl/epocpe.sc: Likewise.
    	* scripttempl/h8300.sc: Likewise.
    	* scripttempl/h8300h.sc: Likewise.
    	* scripttempl/h8300hn.sc: Likewise.
    	* scripttempl/h8300s.sc: Likewise.
    	* scripttempl/h8300sn.sc: Likewise.
    	* scripttempl/h8300sx.sc: Likewise.
    	* scripttempl/h8300sxn.sc: Likewise.
    	* scripttempl/h8500.sc: Likewise.
    	* scripttempl/h8500b.sc: Likewise.
    	* scripttempl/h8500c.sc: Likewise.
    	* scripttempl/h8500m.sc: Likewise.
    	* scripttempl/h8500s.sc: Likewise.
    	* scripttempl/hppaelf.sc: Likewise.
    	* scripttempl/i386beos.sc: Likewise.
    	* scripttempl/i386coff.sc: Likewise.
    	* scripttempl/i386go32.sc: Likewise.
    	* scripttempl/i386msdos.sc: Likewise.
    	* scripttempl/i860coff.sc: Likewise.
    	* scripttempl/i960.sc: Likewise.
    	* scripttempl/ia64vms.sc: Likewise.
    	* scripttempl/ip2k.sc: Likewise.
    	* scripttempl/iq2000.sc: Likewise.
    	* scripttempl/m68kaux.sc: Likewise.
    	* scripttempl/m68kcoff.sc: Likewise.
    	* scripttempl/m88kbcs.sc: Likewise.
    	* scripttempl/mcorepe.sc: Likewise.
    	* scripttempl/mep.sc: Likewise.
    	* scripttempl/mips.sc: Likewise.
    	* scripttempl/mipsbsd.sc: Likewise.
    	* scripttempl/mmo.sc: Likewise.
    	* scripttempl/moxie.sc: Likewise.
    	* scripttempl/nds32elf.sc: Likewise.
    	* scripttempl/nw.sc: Likewise.
    	* scripttempl/pe.sc: Likewise.
    	* scripttempl/pep.sc: Likewise.
    	* scripttempl/pj.sc: Likewise.
    	* scripttempl/ppcpe.sc: Likewise.
    	* scripttempl/psos.sc: Likewise.
    	* scripttempl/riscix.sc: Likewise.
    	* scripttempl/sh.sc: Likewise.
    	* scripttempl/sparccoff.sc: Likewise.
    	* scripttempl/st2000.sc: Likewise.
    	* scripttempl/tic30aout.sc: Likewise.
    	* scripttempl/tic30coff.sc: Likewise.
    	* scripttempl/tic4xcoff.sc: Likewise.
    	* scripttempl/tic54xcoff.sc: Likewise.
    	* scripttempl/tic80coff.sc: Likewise.
    	* scripttempl/v850.sc: Likewise.
    	* scripttempl/v850_rh850.sc: Likewise.
    	* scripttempl/vanilla.sc: Likewise.
    	* scripttempl/visium.sc: Likewise.
    	* scripttempl/w65.sc: Likewise.
    	* scripttempl/xstormy16.sc: Likewise.
    	* scripttempl/z80.sc: Likewise.
    	* scripttempl/z8000.sc: Likewise.
    	* configure: Regenerate.

commit 1d75a8e26e6def4f492c84a5f678e41ddebda799
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 12 13:38:20 2017 +0100

    Force the AArch64 linker backend to refuse to link when it encounters unresoleable relocations.
    
    	* reloc.c (enum bfd_reloc_status): Start values at 2.
    	* bfd-in2.h: Regenerate.
    	* elfnn-aarch64.c (aarch64_relocate): Invert sense of function, so
    	that a TRUE return indicates success.  Compare the result of
    	calling _bfd_aarch64_elf_put_addend against bfd_reloc_ok.
    	(build_one_stub): Change sense of tests against aarch64_relocate
    	return value.
    	(elfNN_aarch64_tls_relax): Return bfd_reloc_notsupported, rather
    	than FALSE, when an error is detected.
    	(elfNN_aarch64_final_link_relocate): Likewise.
    
    	* testsuite/ld-aarch64/pcrel_pic_defined.d: Expect errors not
    	warnings.  Expect errors about unsupported relocations.
    	* testsuite/ld-aarch64/pcrel_pic_undefined.d: Likewise.

commit 9f8575350f980aa6da8c488c6aa30862620eaa1f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 12 02:12:47 2017 -0700

    x86: Add _bfd_x86_elf_hide_symbol
    
    When there is no dynamic interpreter in PIE, make the undefined weak
    symbol dynamic so that PC relative branch to the undefined weak symbol
    will land to address 0.
    
    	* elf32-i386.c (elf_backend_hide_symbol): New.
    	* elf64-x86-64.c (elf_backend_hide_symbol): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_hide_symbol): Likewise.
    	* elfxx-x86.h (_bfd_x86_elf_hide_symbol): Likewise.

commit 359987e21867b730564ff46ddceaafdc93d0fb49
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 12 01:52:33 2017 -0700

    ld: Update tests for warning of "-z dynamic-undefined-weak ignored"
    
    Update tests to expect warning of "-z dynamic-undefined-weak ignored"
    from
    
    commit 22b1ee183d19a92cc57859c04307d31c06792d13
    Author: Alan Modra <amodra@gmail.com>
    Date:   Thu Oct 12 13:19:10 2017 +1030
    
        Set dynamic_undefined_weak to zero for static PIEs
    
    	* testsuite/ld-elf/pr22269b.d: Expect warning of
    	"-z dynamic-undefined-weak ignored".
    	* testsuite/ld-i386/pr19636-1j.d: Likewise.
    	* testsuite/ld-i386/pr19636-1k.d: Likewise.
    	* testsuite/ld-i386/pr19636-1l.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2j.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2k.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2l.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2m.d: Likewise.

commit 22b1ee183d19a92cc57859c04307d31c06792d13
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Oct 12 13:19:10 2017 +1030

    Set dynamic_undefined_weak to zero for static PIEs
    
    I believe we should be warning if ld is given both --no-dynamic-linker
    and -z dynamic-undefined-weak.  The two options are contradictory, the
    first says an executable has no dynamic interpreter to resolve dynamic
    symbols, while the second is asking for dynamic symbols to be emitted.
    (And even if a static PIE's relocation code, which is needed to
    process R_*_RELATIVE relocs, could process symbols, there are no
    DT_NEEDED dynamic objects to define such symbols.)
    
    I also think that dynamic_undefined_weak is the right flag to control
    whether undefined weaks are made dynamic, whether in static PIEs or
    anywhere else.  So force it to 0 for static PIEs, fixing PR 22269 for
    powerpc and any other target where the backend usually defaults to
    undefined weaks being made dynamic.
    
    This patch introduces regressions.  I'd normally not do that, but
    these are all in very recently added test cases, or expose bugs in the
    x86 backend.  The test cases were added after I'd made it known that
    this patch or one like it was imminent.
    
    	PR 22269
    	* emultempl/elf32.em (after_parse): Warn on --no-dynamic-linker
    	-z dynamic-undefined-weak combination.  Set dynamic_undefined_weak
    	to zero when nointerp.

commit 559192d89d743834951fc386530c6bc7f89b358d
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Oct 12 09:01:54 2017 +1030

    _bfd_elf_link_hash_hide_symbol calls in generic ELF code
    
    This function shouldn't be called directly, except from backend code.
    
    bfd/
    	* elflink.c (_bfd_elf_adjust_dynamic_symbol): Call
    	elf_backend_hide_symbol, not _bfd_elf_link_hash_hide_symbol.
    	(bfd_elf_define_start_stop): Likewise.
    ld/
    	* emultempl/elf32.em (before_allocation): Call
    	elf_backend_hide_symbol, not _bfd_elf_link_hash_hide_symbol.
    	Formatting.

commit f5233a1611d7d459a762b5fa93d7594a6965971f
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 11 22:43:42 2017 +1030

    Fix remaining targets using wrong .interp conditions
    
    	* elf32-nds32.c (nds32_elf_size_dynamic_sections): Set .interp
    	when executable rather than non-PIC.
    	* elf32-score.c (s3_bfd_score_elf_size_dynamic_sections): Likewise.
    	* elf32-score7.c (s7_bfd_score_elf_size_dynamic_sections): Likewise.

commit ff0769882d2338d334eb799179332c39bb9d8ddc
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Oct 12 00:00:33 2017 +0000

    Automatic date update in version.in

commit f71c8822611a552e76843142a52b8197be0ea34a
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 9 19:13:31 2017 -0600

    Remove cleanups from TUI
    
    This removes the last cleanups from the TUI, by using std::string
    rather than manual memory management.
    
    Regression tested against gdb.tui/*.exp on Fedora 26 x86-64.
    
    gdb/ChangeLog
    2017-10-09  Tom Tromey  <tom@tromey.com>
    
    	* tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
    	std::string.
    	* tui/tui-layout.c (enum tui_status): Use std::string.

commit 981a3fb3594dddae266b7a5014c3001727200d7b
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Sep 25 22:28:30 2017 -0600

    Constify add_prefix_cmd
    
    This changes add_prefix_cmd to accept a const-taking function as an
    argument; then fixes up all the callers.
    
    In a couple of spots I had to add a non-const overload of a function,
    because the function is passed to two different command-adding
    "constructors".  These overloads are temporary; once constification is
    complete they can be removed.
    
    This patch also fixes a typo I happened to notice while constifying.
    
    Note that this touches a couple of files (gnu-nat.c and go32-nat.c)
    that I can't build.  So, while I made a best-effort there, I am not
    certain they will still compile.
    
    Tested by rebuilding.
    
    gdb/ChangeLog
    2017-10-11  Tom Tromey  <tom@tromey.com>
    
    	* gdbthread.h (thread_command): Constify.
    	* inferior.h (detach_command): Constify.
    	* top.h (set_history, show_history): Constify.
    	* arm-tdep.c (set_arm_command, show_arm_command): Constify.
    	* serial.c (serial_set_cmd, serial_show_cmd): Constify.
    	* bsd-kvm.c (bsd_kvm_cmd): Constify.
    	* printcmd.c (set_command): Constify.
    	(non_const_set_command): New function.
    	* dcache.c (set_dcache_command, show_dcache_command): Constify.
    	* breakpoint.c (enable_command, disable_command, delete_command)
    	(catch_command, tcatch_command, set_breakpoint_cmd)
    	(show_breakpoint_cmd): Constify.
    	* macrocmd.c (macro_command): Constify.
    	* infcmd.c (unset_command, kill_command, detach_command)
    	(info_proc_cmd): Constify.
    	* i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
    	* auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
    	(info_auto_load_cmd): Constify.
    	* target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
    	(unset_tdesc_cmd): Constify.
    	* ada-lang.c (set_ada_command, show_ada_command)
    	(maint_set_ada_cmd, maint_show_ada_cmd): Constify.
    	* guile/guile.c (set_guile_command, show_guile_command)
    	(info_guile_command): Constify.
    	* tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
    	Constify.
    	* skip.c (skip_command): Constify.
    	* compile/compile.c (_initialize_compile): Constify.
    	* dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
    	* btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
    	(maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
    	(maint_btrace_pt_show_cmd): Constify.
    	* remote.c (set_remote_cmd, show_remote_cmd, remote_command):
    	Constify.
    	* python/python.c (user_show_python, user_set_python): Constify.
    	* mips-tdep.c (set_mips_command, show_mips_command)
    	(set_mipsfpu_command): Constify.
    	* record-btrace.c (cmd_record_btrace_start)
    	(cmd_set_record_btrace, cmd_show_record_btrace)
    	(cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
    	(cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
    	* rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
    	Constify.
    	* symfile.c (overlay_command): Constify.
    	* spu-tdep.c (set_spu_command, show_spu_command): Constify.
    	* cli/cli-logging.c (set_logging_command, show_logging_command):
    	Constify.
    	* cli/cli-dump.c (dump_command, append_command)
    	(srec_dump_command, ihex_dump_command, verilog_dump_command)
    	(tekhex_dump_command, binary_dump_command)
    	(binary_append_command): Constify.
    	* cli/cli-decode.c (struct cmd_list_element): Change type of
    	"fun".
    	* cli/cli-cmds.c (info_command, show_command, set_debug)
    	(show_debug): Constify.
    	(show_command): Add non-const overload.
    	* top.c (set_history, show_history): Constify.
    	* sh-tdep.c (set_sh_command, show_sh_command): Constify.
    	* command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
    	* target.c (target_command): Constify.
    	* sparc64-tdep.c (info_adi_command): Constify.
    	* record-full.c (cmd_record_full_start): Constify.
    	(set_record_full_command): Constify.  Fix typo.
    	(show_record_full_command): Constify.
    	* thread.c (thread_command, thread_apply_command): Constify.
    	* memattr.c (dummy_cmd): Constify.
    	* value.c (function_command): Constify.
    	* frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
    	* probe.c (info_probes_command): Constify.
    	* ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
    	* gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
    	(show_thread_cmd, set_thread_default_cmd)
    	(show_thread_default_cmd): Constify.
    	(check_empty): Constify.
    	* tracepoint.c (tfind_command): Constify.
    	* cp-support.c (maint_cplus_command): Constify.
    	* windows-tdep.c (info_w32_command): Constify.
    	* record.c (cmd_record_start, set_record_command)
    	(show_record_command, info_record_command, cmd_record_goto):
    	Constify.
    	* ravenscar-thread.c (set_ravenscar_command)
    	(show_ravenscar_command): Constify.
    	* utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
    	Constify.
    	(add_internal_problem_command): Remove casts.
    	* arc-tdep.c (maintenance_print_arc_command): Constify.
    	* valprint.c (set_print, show_print, set_print_raw)
    	(show_print_raw): Constify.
    	* maint.c (maintenance_command, maintenance_info_command)
    	(maintenance_print_command, maintenance_set_cmd)
    	(maintenance_show_cmd, set_per_command_cmd)
    	(show_per_command_cmd, maintenance_check_command): Constify.
    	* language.c (set_check, show_check): Constify.
    	* typeprint.c (show_print_type, set_print_type): Constify.
    	* go32-nat.c (go32_info_dos_command): Constify.

commit fdf44873ec6e37417bf8c8ce33bb9b1a6b4ddcef
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 14:03:41 2017 -0600

    Remove prepare_re_set_context
    
    prepare_re_set_context returns a null cleanup and doesn't seem
    generally useful.  This patch removes it plus a few more cleanups; and
    changes breakpoint_re_set to use scoped_restore rather than its own
    manual mechanism.
    
    2017-10-11  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (prepare_re_set_context): Remove.
    	(breakpoint_re_set_one): Update.  Don't use cleanups.
    	(breakpoint_re_set): Use scoped_restore, std::string, and
    	scoped_restore_current_language.

commit 81b1e71c4a1370c77ad1d462e1a761402d48b1c0
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 13:58:07 2017 -0600

    Remove some cleanups from breakpoint.c
    
    This removes some cleanups from breakpoint.c, replacing them with C++
    data structures.
    
    2017-10-11  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (commands_command_1): Use std::string.
    	(cleanup_executing_breakpoints): Remove.
    	(bpstat_do_actions_1): Use scoped_restore.
    	(bpstat_check_watchpoint): Use std::string.
    	(decode_static_tracepoint_spec): Likewise.
    	(break_range_command): Likewise.
    	(watch_command_1): Likewise.
    	(compare_breakpoints): Change argument types.
    	(clear_command): Use std::vector.
    	(cleanup_executing_breakpoints): Remove.
    	(update_global_location_list): Use unique_xmalloc_ptr.
    	(strace_command): Remove unused declaration.

commit 4b97e3893ed2af7bdb9dcaa34fae1a207e2d7042
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 7 03:07:36 2017 -0700

    Add 2 testcases for PR ld/22269
    
    Since undefined weak symbols in static PIE are always resolved to 0 at
    run-time, linker should resolve them as 0 at link-time, regardless of
    whether "-z dynamic-undefined-weak" is used.  "-z dynamic-undefined-weak"
    only makes undefined weak symbols dynamic, but doesn't change undefined
    weak symbol resolution in static PIE at link-time.  These tests currently
    pass on x86, but fails on many other targets.
    
    The framework to resolve weak symbols in static PE at link-time is
    posted at
    
    https://sourceware.org/ml/binutils/2017-10/msg00087.html
    
    which requires users/hjl/check_relocs branch to call check_relocs after
    opening all inputs.  I will submit backend patches for failling targets
    after merging users/hjl/check_relocs branch next.
    
    	* PR ld/22269
    	* testsuite/ld-elf/pr22269.s: New file.
    	* testsuite/ld-elf/pr22269a.d: Likewise.
    	* testsuite/ld-elf/pr22269b.d: Likewise.

commit 853ee16fcdf7e60f297b3456353b3a69f4822bec
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Oct 11 13:32:20 2017 -0700

    x86: Run PR ld/19636 tests with -z dynamic-undefined-weak
    
    "-z dynamic-undefined-weak" makes undefined weak symbols dynamic, but
    undefined weak symbols are still resolved to 0 at link-time if there
    is no dynamic linker in executable.
    
    	* testsuite/ld-i386/i386.exp: Run pr19636-1j, pr19636-1k,
    	pr19636-1l, pr19636-3h and pr19636-3i.
    	* testsuite/ld-i386/pr19636-1j.d: New file.
    	* testsuite/ld-i386/pr19636-1k.d: Likewise.
    	* testsuite/ld-i386/pr19636-1l.d: Likewise.
    	* testsuite/ld-i386/pr19636-3h.d: Likewise.
    	* testsuite/ld-i386/pr19636-3i.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-1h.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-1i.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-1j.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2j.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2k.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2l.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2m.d: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run pr19636-1h, pr19636-1i,
    	pr19636-1j, pr19636-2j, pr19636-2k, pr19636-2l and pr19636-2m.

commit 4f9d99066edcefab0e5868d20cb9ddaa7b76da52
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Oct 11 11:16:34 2017 -0700

    Add native target for FreeBSD/arm.
    
    gdb/ChangeLog:
    
    	* Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
    	* NEWS: Mention new FreeBSD/arm native configuration.
    	* configure.host: Add arm*-*-freebsd*.
    	* configure.nat: Likewise.
    	* arm-fbsd-nat.c: New file.

commit 7176dfd28d1a2a74e6d8dd698aeb857eb6edfb98
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Oct 11 11:16:34 2017 -0700

    Add FreeBSD/arm architecture.
    
    Support for collecting and supplying general purpose and floating
    point registers is provided along with signal frame unwinding.  While
    FreeBSD/arm kernels do populate NT_FPREGSET notes, they are always
    zero-filled, so this implementation ignores them.  Recent FreeBSD/arm
    kernels generate NT_ARM_VFP notes which are used to supply
    floating-point registers.  As with Linux, the AT_HWCAP feature flags
    are used to determine the correct target description.
    
    gdb/ChangeLog:
    
    	* Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
    	(ALLDEPFILES): Add arm-fbsd-tdep.c.
    	* NEWS: Mention new FreeBSD/arm target.
    	* configure.tgt: Add arm*-*-freebsd*.
    	* arm-fbsd-tdep.c: New file.
    	* arm-fbsd-tdep.h: New file.

commit 39865a7f420ab4ca4dec6ed27339618a5d5dc366
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 11 16:48:16 2017 +0100

    Disable the inclusion of logical input files in the assembler listing output unless high level source listing has been enabled.
    
    	PR 21977
    	* listing.c (listing_newline): Use the name of the current
    	physical input file, rather than the current logical input file,
    	unless including high level source in the listing.
    	* input-scrub.c (as_where_physical): New function.  Returns the
    	name of the current physical input file.
    	* as.h: Add prototype for as_where_physical.

commit fe22022617a7122491aa83c893a10a8d861cde73
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Oct 11 15:01:41 2017 +0100

    GDB: Remove Linux core PRPSINFO note writer override
    
    Revert parts of commit b3ac9c77560a ("Put more info in NT_PRPSINFO Linux
    notes"), <https://sourceware.org/ml/binutils/2013-02/msg00024.html>, and
    remove support for a Linux core PRPSINFO note writer override, now that
    all variants are handled automatically within BFD itself.
    
    	gdb/
    	* linux-tdep.c (linux_make_corefile_notes): Remove call to
    	`gdbarch_elfcore_write_linux_prpsinfo'.
    	* gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
    	method.
    	(elf_internal_linux_prpsinfo): Remove declaration.
    	* gdbarch.h: Regenerate.
    	* gdbarch.c: Regenerate.

commit 3c9a7b0d6d84425ea24d222a1a31e206e587374f
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Oct 11 15:01:41 2017 +0100

    ELF/BFD: Handle both variants of the 64-bit Linux core PRPSINFO note
    
    Fix commit 70a38d42c5b3 ("New entry points for writing Linux NT_PRPSINFO
    notes."), <https://sourceware.org/ml/binutils/2013-02/msg00023.html>,
    and handle both variants of the 64-bit Linux core PRPSINFO note across
    all targets.
    
    The 64-bit Linux core PRPSINFO note matches the 64-bit kernel structure,
    defined as follows:
    
    (gdb) ptype struct elf_prpsinfo
    type = struct elf_prpsinfo {
        char pr_state;
        char pr_sname;
        char pr_zomb;
        char pr_nice;
        unsigned long pr_flag;
        __kernel_uid_t pr_uid;
        __kernel_gid_t pr_gid;
        pid_t pr_pid;
        pid_t pr_ppid;
        pid_t pr_pgrp;
        pid_t pr_sid;
        char pr_fname[16];
        char pr_psargs[80];
    }
    (gdb)
    
    where the individual data types of most members are the same across all
    64-bit Linux ports, with the exception of `__kernel_uid_t' and
    `__kernel_gid_t'.  These are defined in <asm-generic/posix_types.h> as
    32-bit `unsigned int' by default, however overridden as 16-bit `unsigned
    short' in port-specific <asm/posix_types.h> for the SuperH target.
    
    The default is already handled, as from the commit referred.  Add the
    other variant then and provide a backend flag to switch between the two
    cases possible, with the 32-bit one being the default and the 16-bit one
    explicitly selected.  Set the flag in the SuperH target backend.  This
    arrangement is analogous to how the 32-bit Linux core PRPSINFO note is
    handled.
    
    	bfd/
    	* elf-bfd.h (elf_backend_data): Add `linux_prpsinfo64_ugid16'
    	member.
    	* elf-linux-core.h (elf_external_linux_prpsinfo64): Rename to...
    	(elf_external_linux_prpsinfo64_ugid32): ... this.
    	(swap_linux_prpsinfo32_out): Rename to...
    	(swap_linux_prpsinfo32_ugid32_out): ... this.
    	(elf_external_linux_prpsinfo64_ugid16): New structure.
    	(swap_linux_prpsinfo64_ugid16_out): New function.
    	* elfxx-target.h [!elf_backend_linux_prpsinfo64_ugid16]
    	(elf_backend_linux_prpsinfo64_ugid16): Define.
    	(elfNN_bed): Initialize `linux_prpsinfo64_ugid16' member.
    	* elf.c (elfcore_write_linux_prpsinfo64): Handle both variants
    	of the 64-bit Linux core PRPSINFO note.
    	* elf64-sh64.c (elf_backend_linux_prpsinfo64_ugid16): Define.

commit a2f63b2e7a5da01ff828b45c7e0e57265ee24131
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Oct 11 15:01:40 2017 +0100

    ELF/BFD,GDB: Handle both variants of the 32-bit Linux core PRPSINFO note
    
    Fix commit 70a38d42c5b3 ("New entry points for writing Linux NT_PRPSINFO
    notes."), <https://sourceware.org/ml/binutils/2013-02/msg00023.html>,
    and commit b3ac9c77560a ("Put more info in NT_PRPSINFO Linux notes"),
    <https://sourceware.org/ml/binutils/2013-02/msg00024.html>, and handle
    both variants of the 32-bit Linux core PRPSINFO note across all targets.
    
    The 32-bit Linux core PRPSINFO note matches the 32-bit kernel structure,
    defined as follows:
    
    (gdb) ptype struct elf_prpsinfo
    type = struct elf_prpsinfo {
        char pr_state;
        char pr_sname;
        char pr_zomb;
        char pr_nice;
        unsigned long pr_flag;
        __kernel_uid_t pr_uid;
        __kernel_gid_t pr_gid;
        pid_t pr_pid;
        pid_t pr_ppid;
        pid_t pr_pgrp;
        pid_t pr_sid;
        char pr_fname[16];
        char pr_psargs[80];
    }
    (gdb)
    
    where the individual data types of most members are the same across all
    32-bit Linux ports, with the exception of `__kernel_uid_t' and
    `__kernel_gid_t'.  These are defined in <asm-generic/posix_types.h> as
    32-bit `unsigned int' by default, however overridden as 16-bit `unsigned
    short' in port-specific <asm/posix_types.h> for a few targets, mostly
    earlier ports of Linux, specifically: ARM, CRIS, FR-V, M32R, m68k,
    MN10300/AM33, s390, SuperH, SPARC and i386.
    
    The default is the same as the PowerPC variant already handled, as from
    the commits referred.  Make the special PowerPC case generic then,
    removing the GDB part, and provide a backend flag to switch between the
    two cases possible, with the 32-bit one being the default and the 16-bit
    one explicitly selected.  Set the flag in the target backends affected.
    
    	bfd/
    	* elf-bfd.h (elf_backend_data): Add `linux_prpsinfo32_ugid16'
    	member.
    	(elfcore_write_ppc_linux_prpsinfo32): Remove prototype.
    	* elf32-ppc.c (elfcore_write_ppc_linux_prpsinfo32): Remove.
    	(elf_external_ppc_linux_prpsinfo32)
    	(swap_ppc_linux_prpsinfo32_out): Move to...
    	* elf-linux-core.h (elf_external_linux_prpsinfo32_ugid32)
    	(swap_linux_prpsinfo32_ugid32_out): ... these.
    	(elf_external_linux_prpsinfo32): Rename to...
    	(elf_external_linux_prpsinfo32_ugid16): ... this.
    	(swap_linux_prpsinfo32_out): Rename to...
    	(swap_linux_prpsinfo32_ugid16_out): ... this.
    	* elfxx-target.h [!elf_backend_linux_prpsinfo32_ugid16]
    	(elf_backend_linux_prpsinfo32_ugid16): Define.
    	(elfNN_bed): Initialize `linux_prpsinfo32_ugid16' member.
    	* elf.c (elfcore_write_linux_prpsinfo32): Handle both variants
    	of the 32-bit Linux core PRPSINFO note.
    	* elf32-am33lin.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-arm.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-cris.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-frv.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-i386.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-m32r.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-m68k.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-s390.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-sh.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    	* elf32-sparc.c (elf_backend_linux_prpsinfo32_ugid16): Define.
    
    	gdb/
    	* ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
    	`set_gdbarch_elfcore_write_linux_prpsinfo'.

commit 72bc1bb934ba99bc9182179a866c0d2c77d027c8
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Oct 11 15:01:40 2017 +0100

    ELF/BFD: Fix padding in `elf_external_linux_prpsinfo64'
    
    Fix commit 70a38d42c5b3 ("New entry points for writing Linux NT_PRPSINFO
    notes."), <https://sourceware.org/ml/binutils/2013-02/msg00023.html>,
    and move the padding of the `elf_external_linux_prpsinfo64' structure to
    match the corresponding 64-bit Linux kernel `elf_prpsinfo' structure.
    
    The 64-bit kernel structure is defined as follows:
    
    (gdb) ptype struct elf_prpsinfo
    type = struct elf_prpsinfo {
        char pr_state;
        char pr_sname;
        char pr_zomb;
        char pr_nice;
        unsigned long pr_flag;
        __kernel_uid_t pr_uid;
        __kernel_gid_t pr_gid;
        pid_t pr_pid;
        pid_t pr_ppid;
        pid_t pr_pgrp;
        pid_t pr_sid;
        char pr_fname[16];
        char pr_psargs[80];
    }
    (gdb) print /x &((struct elf_prpsinfo *)0)->pr_nice
    $1 = 0x3
    (gdb) print /x &((struct elf_prpsinfo *)0)->pr_flag
    $2 = 0x8
    (gdb) print /x &((struct elf_prpsinfo *)0)->pr_uid
    $3 = 0x10
    (gdb) print sizeof(((struct elf_prpsinfo *)0)->pr_flag)
    $4 = 8
    (gdb)
    
    with implicit padding present before the `pr_flag' member, to correctly
    align it to a multiple of 8.  Conversely `elf_external_linux_prpsinfo64'
    has padding after its `pr_flag' member:
    
    (top-gdb) ptype struct elf_external_linux_prpsinfo64
    type = struct elf_external_linux_prpsinfo64 {
        char pr_state;
        char pr_sname;
        char pr_zomb;
        char pr_nice;
        char pr_flag[8];
        char gap[4];
        char pr_uid[4];
        char pr_gid[4];
        char pr_pid[4];
        char pr_ppid[4];
        char pr_pgrp[4];
        char pr_sid[4];
        char pr_fname[16];
        char pr_psargs[80];
    }
    (top-gdb) print /x &((struct elf_external_linux_prpsinfo64 *)0)->pr_nice
    $1 = 0x3
    (top-gdb) print /x &((struct elf_external_linux_prpsinfo64 *)0)->pr_flag
    $2 = 0x4
    (top-gdb) print /x &((struct elf_external_linux_prpsinfo64 *)0)->pr_uid
    $3 = 0x10
    (top-gdb)
    
    and consequently `pr_flag' is misplaced.  Move `gap' ahead of `pr_flag'
    then.
    
    	bfd/
    	* elf-linux-core.h (elf_external_linux_prpsinfo64): Move the
    	`gap' member ahead of `pr_flag'.

commit 458ca1d02e47db0af0e22d524df0e4b88fc54b6e
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 11 14:45:17 2017 +0100

    Garbage collect reattach_breakpoints
    
    Not used anywhere.
    
    gdb/ChangeLog:
    2017-10-11  Pedro Alves  <palves@redhat.com>
    
    	* breakpoint.c (reattach_breakpoints): Delete.
    	* breakpoint.h (reattach_breakpoints): Delete.

commit 905014d7205d4f171c5cabf695fe1ec3da9b33d3
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Oct 11 09:34:08 2017 -0400

    Use std::vector for symtab_fns
    
    Simple replacement of VEC with std::vector.
    
    gdb/ChangeLog:
    
    	* symfile.c (registered_sym_fns): Make struct, not typedef.
    	(DEF_VEC_O (registered_sym_fns)): Remove.
    	(symtab_fns): Change type to std::vector.
    	(add_symtab_fns): Adjust.
    	(find_sym_fns): Adjust.

commit 56d704daee44b036d1eff86123de6dec0c55f61b
Author: Anton Kolesov <Anton.Kolesov@synopsys.com>
Date:   Tue Jun 27 19:12:14 2017 +0300

    arc: Pass proper CPU value to the disassembler
    
    There was a problem with generation of the disassembler options for ARC in GDB,
    because a BFD architecture name was used as a CPU name, but they have different
    meaning even if some architectures have same name as respective CPUs.  Target
    description specifies a BFD architecture, which is different from ARC CPU, as
    accepted by the disassembler (and most other ARC tools), because CPU values are
    much more fine grained - there can be multiple CPU values per single BFD
    architecture.  As a result this code should translate architecture to some CPU
    value.  Since there is no info on exact CPU configuration, it is best to use
    the most feature-rich CPU, so that the disassembler will recognize all
    instructions available to the specified architecture.
    
    gdb/ChangeLog
    yyyy-mm-dd  Anton Kolesov  <Anton.Kolesov@synopsys.com>
    
    	* arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
    	* arc-tdep.h (arc_arch_is_em): New function.
    	(arc_arch_is_hs): Likewise.
    
    gdb/testsuite/ChangeLog
    yyyy-mm-dd  Anton Kolesov  <Anton.Kolesov@synopsys.com>
    
    	* gdb.arch/arc-tdesc-cpu.exp: New file.
    	* gdb.arch/arc-tdesc-cpu.xml: Likewise.

commit 8f314ad58ec824ce6c8467af29f11583f79a80ea
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 11 12:47:25 2017 +0100

    Rename _doprnt -> _bfd_doprnt to fix DJGPP bfd build (and likely others)
    
    Building bfd/ for DJGPP, I see:
    
     ../../src/bfd/bfd.c:642:1: error: conflicting types for '_doprnt'
      _doprnt (FILE *stream, const char *format, va_list ap)
      ^~~~~~~
     In file included from ../../src/bfd/sysdep.h:37:0,
    		  from ../../src/bfd/bfd.c:367:
     /usr/lib64/gcc/i586-pc-msdosdjgpp/6.1.0/include-fixed/stdio.h:171:5: note: previous declaration of '_doprnt' was here
      int _doprnt(const char *_fmt, va_list _args, FILE *_f);
          ^~~~~~~
    
    Possible fixes the build on other systems too -- _doprnt was/is an
    exported symbol on old Unix/BSD systems too.
    
    bfd/ChangeLog:
    2017-10-11  Pedro Alves  <palves@redhat.com>
    
    	* bfd.c (_doprnt): Rename to ...
    	(_bfd_doprnt): ... this.
    	(error_handler_internal): Adjust.

commit 04914e3707e210a071b3af3c52cc5e5b2ad41a61
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Oct 11 12:02:51 2017 +0100

    Display more information when decoding DW_AT_endianity, DW_AT_decimal_sign, DW_AT_defaulted and DW_AT_discr_list DWARF attributes.
    
    	* dwarf.c (read_and_display_attr_value): Handle DW_AT_endianity,
    	DW_END_default, DW_END_big, DW_END_little, DW_ATE_UCS,
    	DW_ATE_ASCII, DW_CC_pass_by_reference, DW_CC_pass_by_value,
    	DW_CC_GNU_renesas_sh, DW_CC_GNU_borland_fastcall_i386,
    	DW_AT_decimal_sign, DW_AT_defaulted, DW_AT_discr_list.
    	(get_TAG_name): Report user generated tag values.
    	* testsuite/binutils-all/dwarf-attributes.S: New test.
    	* testsuite/binutils-all/dwarf-attributes.W. Expected output from
    	readelf.
    	* testsuite/binutils-all/readelf.exp: Run the new test.

commit 7fa29be949a96f68ee65dcdb4f56f132609170db
Author: Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
Date:   Wed Oct 11 11:00:48 2017 +0100

    Remove unnecessary parentheses in declarations
    
    GCC commit a94975e57 ("C++ warning on vexing parse") introduces new
    warnings "unnecessary parentheses in the declaration of ...".  These
    cause the build of binutils and gdb to fail.  This patch removes those
    parentheses for a successful build.
    
    gdb/ChangeLog:
    2017-10-11  Egeyar Bagcioglu  <egeyar.bagcioglu@oracle.com>
    
    	* macrotab.h (macro_lookup_inclusion): Remove unnecessary
    	parentheses in the declaration.
    	(macro_lookup_inclusion): Likewise.
    	(macro_lookup_definition): Likewise.
    	* p-lang.h (pascal_builtin_types): Likewise.
    	* tui/tui-data.c (tui_win_list): Likewise.
    	* tui/tui-data.h (tui_win_list): Likewise.
    	* utils.h (make_cleanup_free_section_addr_info): Likewise.

commit d9b477e3b7388732ed5293d929ceb5fc609916fe
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Oct 10 22:47:01 2017 -0700

    Flash memory size not aligned to address
    
    (This patch is from Mark Rages <markrages@gmail.com>.)
    
    The Nordic nRF52 memory map, reported from black magic probe:
    
    Num Enb Low Addr High Addr Attrs
    0 y 0x00000000 0x00080000 flash blocksize 0x1000 nocache
    1 y 0x10001000 0x10001210 flash blocksize 0x210 nocache
    2 y 0x20000000 0x20010000 rw nocache
    
    The region at 0x10001000 is "UICR" and it is a section of flash that is
    erased all at once.
    
    Notice the odd size: 0x210 is the size of the region defined in the
    datasheet.
    
    But because the block size was listed as 0x210, gdb was insisting on
    issuing two erase commands divisible by 0x210, starting below 0x10001000.
    
    This patch fixes it by doing the alignment computation from the start of
    the region, not from address 0.
    
    gdb/ChangeLog:
    
    	* target-memory.c (block_boundaries): Fix for block address not
    	aligned on block size.

commit d003af558092dc521f93d16628b9ccbf434370e3
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 11 14:48:45 2017 +1030

    ld internationalization fixes
    
    	* emultempl/aarch64elf.em: Wrap einfo strings in _().  Formatting.
    	* emultempl/aix.em: Likewise.
    	* emultempl/armcoff.em: Likewise.
    	* emultempl/armelf.em: Likewise.
    	* emultempl/avrelf.em: Likewise.
    	* emultempl/beos.em: Likewise.
    	* emultempl/cr16elf.em: Likewise.
    	* emultempl/elf-generic.em: Likewise.
    	* emultempl/elf32.em: Likewise.
    	* emultempl/genelf.em: Likewise.
    	* emultempl/hppaelf.em: Likewise.
    	* emultempl/linux.em: Likewise.
    	* emultempl/lnk960.em: Likewise.
    	* emultempl/m68hc1xelf.em: Likewise.
    	* emultempl/m68kcoff.em: Likewise.
    	* emultempl/m68kelf.em: Likewise.
    	* emultempl/metagelf.em: Likewise.
    	* emultempl/mipself.em: Likewise.
    	* emultempl/mmix-elfnmmo.em: Likewise.
    	* emultempl/mmo.em: Likewise.
    	* emultempl/msp430.em: Likewise.
    	* emultempl/nds32elf.em: Likewise.
    	* emultempl/nios2elf.em: Likewise.
    	* emultempl/pe.em: Likewise.
    	* emultempl/pep.em: Likewise.
    	* emultempl/ppc32elf.em: Likewise.
    	* emultempl/ppc64elf.em: Likewise.
    	* emultempl/riscvelf.em: Likewise.
    	* emultempl/s390.em: Likewise.
    	* emultempl/scoreelf.em: Likewise.
    	* emultempl/spuelf.em: Likewise.
    	* emultempl/sunos.em: Likewise.
    	* emultempl/tic6xdsbt.em: Likewise.
    	* emultempl/v850elf.em: Likewise.
    	* emultempl/vms.em: Likewise.
    	* emultempl/vxworks.em: Likewise.
    	* ldcref.c: Likewise.
    	* ldlang.c: Likewise.
    	* ldlex.l: Likewise.
    	* ldmain.c: Likewise.
    	* pe-dll.c: Likewise.
    	* plugin.c: Likewise.

commit e8b8ffd3c0676f69d1edd3859d4eebf10d1d62d7
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Oct 11 00:00:22 2017 +0000

    Automatic date update in version.in

commit 0f09b4d8d8f7c5d249c8375c5c42d4eba3bdc858
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Oct 10 15:52:39 2017 -0700

    x86: Set GOT refcount to 1
    
    Since x86 check_relocs is called after opening all inputs and garbage
    collection, they never see the removed sections.  There is no need
    for incrementing GOT refcount.  But since PLT refcount is also used in
    
      /* Don't create the PLT entry if there are only function pointer
         relocations which can be resolved at run-time.  */
      else if (htab->elf.dynamic_sections_created
               && (h->plt.refcount > eh->func_pointer_refcount
                   || eh->plt_got.refcount > 0))
        {
    
    we must increment it.
    
    	* elf32-i386.c (elf_i386_check_relocs): Set GOT refcount to 1
    	instead of incrementing it.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.

commit 2f20e312aad64c0f5257b9725fa5ffa3e8a93ca2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Oct 10 15:10:25 2017 -0400

    get_integer_valueof: Don't output value in test name
    
    The get_integer_valueof outputs the value it has read as part of the
    test name.  This causes test names to vary from run to run, and adds
    some noise when diffing test results.  e.g.:
    
    -PASS: gdb.threads/process-dies-while-detaching.exp: multi-process: continue: killed outside: get integer valueof "mypid" (28770)
    +PASS: gdb.threads/process-dies-while-detaching.exp: multi-process: continue: killed outside: get integer valueof "mypid" (32238)
    
    This patch removes that, since it's probably not very useful.
    
    gdb/testsuite/ChangeLog:
    
    	* lib/gdb.exp (get_integer_valueof): Don't output read value in test name.

commit eb8c0d308be8525f7c25962a9c581f44af23a364
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 6 14:38:36 2017 -0600

    Bump dwarf-mode version number
    
    Bump the dwarf-mode version number, so it can be installed by package.el
    users who installed an earlier verision.
    
    2017-10-10  Tom Tromey  <tom@tromey.com>
    
    	* dwarf-mode.el: Bump to version 1.4.

commit c85fa91b5c0dc70641d75d6ab9315ad547487c1f
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 6 14:36:44 2017 -0600

    Asynchronous insertion for dwarf-mode.el
    
    I was recently examining a very large .debug file.  I tried to use
    dwarf-mode, but it blocked Emacs for a very long time while reading
    output.
    
    This patch changes dwarf-mode to run the objdump process asynchronously.
    This way, I can still do other things in Emacs while waiting for the
    dumping to finish.
    
    2017-10-10  Tom Tromey  <tom@tromey.com>
    
    	* dwarf-mode.el (dwarf--process, dwarf--deletion-region): New
    	defvar.
    	(dwarf--check-running, dwarf--sentinel, dwarf--invoke)
    	(dwarf--filter): New functions.
    	(dwarf-do-insert-substructure, dwarf-do-refresh): Call
    	dwarf--check-running, dwarf--invoke.
    	(dwarf-browse): Initialize new variables.

commit e4905c7464d23367248bdd5d8eccaebb495b8274
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 6 13:42:49 2017 -0600

    Set lexical-binding in dwarf-mode
    
    Emacs has had lexical binding for a while, and it's a good practice to
    use it; so enable it in dwarf-mode.el.
    
    2017-10-10  Tom Tromey  <tom@tromey.com>
    
    	* dwarf-mode.el: Set lexical-binding.

commit 22b63797983f485041a2a424e6cd7732f4318885
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Oct 6 13:18:31 2017 -0600

    Bind keys in dwarf-mode-map definition
    
    It's bad Emacs style to define keys from a top-level form.  Instead, one
    should define a mode map separately and binding keys in the definition.
    This lets users completely override the map by defining it before
    loading the mode.
    
    2017-10-10  Tom Tromey  <tom@tromey.com>
    
    	* dwarf-mode.el (dwarf-mode-map): New defvar.

commit 65630365f7d073430e62b4fe65f34dcdc0a4b05e
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 10 16:45:51 2017 +0100

    Eliminate catch_exceptions/catch_exceptions_with_msg
    
    This patch gets rid of catch_exceptions / catch_exceptions_with_msg.
    The latter is done mostly by getting rid of the three remaining
    vestigial libgdb wrapper functions, which are really pointless
    nowadays.  This results in a good number of simplifications.
    
    (I checked that Insight doesn't use those functions.)
    
    The gdb.mi/mi-pthreads.exp change is necessary because this actually
    fixes a bug, IMO -- the patch stops MI's -thread-select causing output
    on the CLI stream.
    
    I.e., before:
     -thread-select 123456789
     &"Thread ID 123456789 not known.\n"
     ^error,msg="Thread ID 123456789 not known."
     (gdb)
    
    After:
     -thread-select 123456789
     ^error,msg="Thread ID 123456789 not known."
     (gdb)
    
    gdb/ChangeLog
    2017-10-10  Pedro Alves <palves@redhat.com>
    	    Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (struct captured_breakpoint_query_args)
    	(do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
    	(print_breakpoint): New.
    	* breakpoint.h (print_breakpoint): Declare.
    	* common/common-exceptions.h (enum return_reason): Remove
    	references to catch_exceptions.
    	* exceptions.c (catch_exceptions, catch_exceptions_with_msg):
    	Delete.
    	* exceptions.h (catch_exceptions_ftype, catch_exceptions)
    	(catch_exception_ftype, catch_exceptions_with_msg): Delete.
    	* gdb.h: Delete.
    	* gdbthread.h (thread_select): Declare.
    	* mi/mi-cmd-break.c: Don't include gdb.h.
    	(breakpoint_notify): Use print_breakpoint.
    	* mi/mi-cmd-catch.c: Don't include gdb.h.
    	* mi/mi-interp.c: Don't include gdb.h.
    	(mi_print_breakpoint_for_event): New.
    	(mi_breakpoint_created, mi_breakpoint_modified): Use
    	mi_print_breakpoint_for_event.
    	* mi/mi-main.c: Don't include gdb.h.
    	(mi_cmd_thread_select): Parse the global thread ID here.  Use
    	thread_select instead of gdb_thread_select.
    	(mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
    	of using gdb_list_thread_ids.
    	* remote-fileio.c (do_remote_fileio_request): Change type.  Reply
    	FILEIO_ENOSYS here.
    	(remote_fileio_request): Use TRY/CATCH instead of
    	catch_exceptions.
    	* symfile-mem.c (struct symbol_file_add_from_memory_args)
    	(symbol_file_add_from_memory_wrapper): Delete.
    	(add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
    	* thread.c: Don't include gdb.h.
    	(do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
    	(thread_alive): Use thread_select.
    	(do_captured_thread_select): Delete, parts salvaged as ...
    	(thread_select): ... this new function.
    	(gdb_thread_select): Delete.
    
    gdb/testsuite/ChangeLog
    2017-10-10  Pedro Alves <palves@redhat.com>
    
    	* gdb.mi/mi-pthreads.exp (check_mi_thread_command_set): Don't
    	expect CLI output.

commit bf4692711232eb96cd840f96d88897a2746d8190
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Oct 10 16:45:50 2017 +0100

    Eliminate catch_errors
    
    If you want to use catch_errors with a function with parameters, then
    currently you have to manually write a "capture" struct wrapping the
    arguments and marshall/unmarshall that.
    
    https://sourceware.org/ml/gdb-patches/2017-09/msg00834.html proposed
    adjusting catch_errors to use gdb::function_view, which would allow
    passing lambdas with automatic captures.  However, it seems like using
    TRY/CATCH directly instead ends up producing clearer and easier to
    debug code.  This is what this commit does.
    
    Note that removing catch_errors exposes further cleanup opportunities
    around no longer having to follow catch_errors callback type, and also
    removes a few cleanups.
    
    I didn't do anything to save/restore current_uiout because I think
    that should be the responsibility of the code that changes
    current_uiout in the first place.
    
    (Another approach could be to make catch_errors a variadic template
    like:
    
      template<typename Function, typename... Args>
      int catch_errors (const char *errstring, return_mask mask,
    		    Function &&func, Args... args);
    
    and then with:
    
      extern void function_with_args (int, int);
      extern void function_with_no_args ();
    
    calls to the above functions would be wrapped like this:
    
      catch_errors ("some error happened", RETURN_MASK_ERROR,
                    function_with_args, arg1, arg2);
    
      catch_errors ("some error happened", RETURN_MASK_ERROR,
                    function_with_no_args);
    
    but I'm thinking that that doesn't improve much if at all either.)
    
    gdb/ChangeLog
    2017-10-10  Pedro Alves  <palves@redhat.com>
    	    Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (breakpoint_cond_eval): Change return type to bool
    	and reverse logic.
    	(WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
    	No longer macros.  Instead ...
    	(enum wp_check_result): They're now values of this new
    	enumeration.
    	(watchpoint_check): Change return type to wp_check_result and
    	parameter type to bpstat.
    	(bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
    	(bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
    	catch_errors.  Reverse logic of watchpoint_check call.
    	(breakpoint_re_set_one): Now returns void and takes a breakpoint
    	pointer as parameter.
    	(breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
    	* common/common-exceptions.c (throw_exception_sjlj): Update
    	comments to avoid mentioning catch_errors.
    	* exceptions.c (catch_errors): Delete.
    	* exceptions.h: Update comments to avoid mentioning catch_errors.
    	(catch_errors_ftype, catch_errors): Delete.
    	* infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
    	(hook_stop_stub): Delete.
    	(restore_selected_frame): Change return type to void, and
    	parameter type to const frame_id &.
    	(restore_infcall_control_state): Use TRY/CATCH instead of
    	catch_errors.
    	* main.c (captured_command_loop): Return void and remove
    	parameter.  Remove references to catch_errors.
    	(captured_main): Use TRY/CATCH instead of catch_errors.
    	* objc-lang.c (objc_submethod_helper_data)
    	(find_objc_msgcall_submethod_helper): Delete.
    	(find_objc_msgcall_submethod): Use TRY/CATCH instead of
    	catch_errors.
    	* record-full.c (record_full_message): Return void.
    	(record_full_message_args, record_full_message_wrapper): Delete.
    	(record_full_message_wrapper_safe): Return bool and use TRY/CATCH
    	instead of catch_errors.
    	* solib-aix.c (solib_aix_open_symbol_file_object): Change
    	parameter type to int.
    	* solib-darwin.c (open_symbol_file_object): Ditto.
    	* solib-dsbt.c (open_symbol_file_object): Ditto.
    	* solib-frv.c (open_symbol_file_object): Ditto.
    	* solib-svr4.c (open_symbol_file_object): Ditto.
    	* solib-target.c (solib_target_open_symbol_file_object): Ditto.
    	* solib.c (update_solib_list): Use TRY/CATCH instead of
    	catch_errors.
    	* solist.h (struct target_so_ops) <open_symbol_file_object>:
    	Change type.
    	* symmisc.c (struct print_symbol_args): Remove.
    	(dump_symtab_1): Use TRY/CATCH instead of catch_errors.
    	(print_symbol): Change type.
    	* windows-nat.c (handle_load_dll, handle_unload_dll): Return void
    	and remove parameters.
    	(catch_errors): New.
    	(get_windows_debug_event): Adjust.
    
    gdb/testsuite/ChangeLog:
    2017-10-10  Pedro Alves  <palves@redhat.com>
    
    	* lib/selftest-support.exp (selftest_setup): Update for
    	captured_command_loop's prototype change.

commit 6c699715f68be7d8c468e965fbefce997f7ed937
Author: Renlin Li <renlin.li@arm.com>
Date:   Mon Sep 25 11:41:54 2017 +0100

    [ARM] PR ld/21402, only override the symbol dynamic decision on undefined weak symbol.
    
    Similar as aarch64 backend, arm backend only overrides the decision on undefined
    weak symbols. arm backend part already emits necessary relative relocation for
    this case.
    
    bfd/
    
    	PR ld/21402
    	* elf32-arm.c (allocate_dynrelocs_for_symbol): Only make undefined weak
    	symbols into dynamic.
    
    ld/
    
    	PR ld/21402
    	* testsuite/ld-arm/tls-app.d: Update address.
    	* testsuite/ld-arm/tls-app.r: Remove relocations.
    	* testsuite/ld-arm/unresolved-1-dyn.d: Update.

commit ae7e78255666733d238e676a0bab14986a1483dd
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Oct 10 13:37:58 2017 +0100

    Improve the speed of the --dwarf-start option by skipping processing of any comp unit that ends before the specified start address.
    
    	PR 22249
    	* dwarf.c (process_debug_info): Skip any comp unit that ends
    	before dwarf_start_die.

commit fc3c534364ca6d6de4f0dbcaf347ec85f5e2f8ff
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 9 22:03:42 2017 -0700

    riscv: Cache the max alignment of output sections
    
    Cache the max alignment of output sections instead of scanning all
    output sections for each input section, which can take a very long
    time if there are millions of input/output sections.
    
    	PR ld/22274
    	* elfnn-riscv.c (riscv_elf_link_hash_table): Add max_alignment.
    	(riscv_elf_link_hash_table_create): Initialize max_alignment to
    	(bfd_vma) -1.
    	(_bfd_riscv_relax_section): Cache the max alignment of output
    	sections if possible.

commit b9399fcf4ec90d898a610e39bd9141e85c008fbb
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 10 11:52:06 2017 +1030

    Prepare powerpc64 for late check_relocs
    
    check_relocs was setting up some data used by the --gc-sections
    gc_mark_hook.  If we change ld to run check_relocs after gc_sections
    that data needs to be set up elsewhere.  Done by this patch in the
    backend check_directives function (ppc64_elf_before_check_relocs).
    
    	* elf64-ppc.c (ppc64_elf_before_check_relocs): Set sec_type for
    	.opd whenever .opd is present and non-zero size.  Move code
    	setting abiversion to/from output file earlier.  Only set
    	u.opd.func_sec when --gc-sections.  Read relocs and set up
    	u.opd.func_sec values here..
    	(ppc64_elf_check_relocs): ..rather than here.  Simplify opd
    	section tests.
    	(ppc64_elf_edit_opd): Don't set sec_type for .opd here.

commit cbd3b1c155ed4f4986bf50754b1c57ad85700f7c
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 10 11:41:10 2017 +1030

    Correct ld/Makefile earmelfb_fuchsia dependencies
    
    There were two copies of earmelf_fuchsia.c dependencies.
    
    	* Makefile.am (earmelfb_fuchsia.c): Rename rule from earmelf_fuchsia.c.
    	* Makefile.in: Regenerate.

commit f8f762b2fd203755c51875e979dfdeb69b66743b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Oct 10 00:00:24 2017 +0000

    Automatic date update in version.in

commit 1a56bfa56ed967c5f6ed98f75834408417a062ff
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 16:37:46 2017 -0600

    Remove free_splay_tree cleanup
    
    One spot in gdb uses a cleanup to free a splay tree.  This patch
    introduces a unique_ptr specialization for this case.
    
    ChangeLog
    2017-10-09  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (free_splay_tree): Remove.
    	(list_available_thread_groups): Use splay_tree_up.
    	* common/gdb_splay_tree.h: New file.

commit 0c478e2d060bebea341696806fed6f67122efab6
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 16:19:48 2017 -0600

    Remove "do_nothing"
    
    The do_nothing function in mi-main.c is used as a splay tree
    key-deleting function; but NULL serves the same purpose and is used
    elsewhere in gdb.  This patch removes the unneeded function.
    
    ChangeLog
    2017-10-09  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (do_nothing): Remove.
    	(list_available_thread_groups): Update.

commit 478c006f9b4a64d59c31aed081c14c1d7dd4ba68
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 9 15:05:03 2017 -0700

    mn10300: Don't free cached internal symbol table
    
    Since ELF linker may cache internal symbol table in init_reloc_cookie,
    we should check if it is cached, before free it.
    
    	* elf-m10300.c (mn10300_elf_check_relocs): Don't free cached
    	isymbuf.

commit 9d45a7de8b80336b9965ee99353c34be85b1b98f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 9 12:45:57 2017 -0700

    bfin: Don't create .interp section for info->nointerp
    
    Don't create the .interp section with "ld --no-dynamic-linker".  This
    fixed:
    
    FAIL: PR ld/20828 forcibly exported symbol version without section GC
    FAIL: PR ld/20828 forcibly exported symbol version with section GC
    FAIL: readelf version information
    
    	* elf32-bfin.c (bfin_size_dynamic_sections): Don't create the
    	.interp section with "ld --no-dynamic-linker".

commit 777a42f1f86b60d11cfe0e5964036823e6920f79
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 9 18:11:02 2017 +0100

    gdb.multi/multi-arch-exec.exp: Also test -m32 => -m64
    
    The gdb.multi/multi-arch-exec.exp testcase currently tests execing
    from -m64 to -m32, but does not test the other direction.  For
    thoroughness, this commit fixes that.  Without the fix in the previous
    commit for example ("Multi-arch exec, more register reading
    avoidance"), on x86_64 we would get different symptoms depending on
    "execing direction".  Vis:
    
      Continuing.
      Truncated register 50 in remote 'g' packet
      Truncated register 50 in remote 'g' packet
      (gdb) FAIL: gdb.multi/multi-arch-exec.exp: first_arch=1: selected_thread=2: follow_exec_mode=same: continue across exec that changes architecture
    
    Vs:
    
      Continuing.
      Remote 'g' packet reply is too long (expected 440 bytes, got 816 bytes): daffffffffffffff0000[snip]
      Remote 'g' packet reply is too long (expected 440 bytes, got 816 bytes): daffffffffffffff0000[snip]
      (gdb) FAIL: gdb.multi/multi-arch-exec.exp: first_arch=2: selected_thread=2: follow_exec_mode=same: continue across exec that changes architecture
    
    gdb/testsuite/ChangeLog:
    2017-10-09  Pedro Alves  <palves@redhat.com>
    
    	Test both arch1=>arch2 and arch2=>arch1.
    
    	* gdb.multi/multi-arch-exec.exp (exec1, srcfile1, binfile1, exec2)
    	(srcfile2, binfile2, march1, march2): Remove globals.  Largely
    	factored out to...
    	(append_arch1_options, append_arch2_options, append_arch_options)
    	(build_executables): New procedures.
    	(do_test): New 'first_arch' parameter.  Use it to define 'from_exec'
    	local.
    	(top level): Add new 'first_arch' testing axis.

commit cbd2b4e316370ab740433b06ed65786831232c8f
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 9 18:11:01 2017 +0100

    Multi-arch exec, more register reading avoidance
    
    As mentioned in commit bf93d7ba9931 ("Add thread after updating
    gdbarch when exec'ing"), we should avoid doing register reads after a
    process does an exec and before we've updated that inferior's gdbarch.
    Otherwise, we may interpret the registers using the wrong
    architecture.
    
    There's still (at least) one case where we still read registers
    post-exec with the pre-exec architecture.  That's when infrun decides
    it needs to switch context to the exec'ing thread.  I.e., if the exec
    event is processed at a time when the current thread is not already
    the exec'ing thread, then we get (with the test added by this commit):
    
      continue
      Continuing.
      Truncated register 50 in remote 'g' packet
      Truncated register 50 in remote 'g' packet
      (gdb) FAIL: gdb.multi/multi-arch-exec.exp: selected_thread=2: follow_exec_mode=same: continue across exec that changes architecture
    
    The fix is to avoid reading registers when switching context in this
    case.
    
    (I'd be nice to get rid of the constant stop_pc reading when switching
    threads, but that'd be a deeper change.)
    
    gdb/ChangeLog:
    2017-10-09  Pedro Alves  <palves@redhat.com>
    
    	* infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
    	reading registers when switching context.
    
    gdb/testsuite/ChangeLog:
    2017-10-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.multi/multi-arch-exec.c: Include <pthread.h> and <assert.h>.
    	(barrier): New.
    	(thread_start, all_started): New functions.
    	(main): Spawn new thread and wait until it is scheduled.
    	* gdb.multi/multi-arch-exec.exp: Build $srcfile1 with the pthreads
    	option.
    	(do_test): Add 'selected_thread' parameter.  Run to all_started
    	instead of main.  Explicitly set the breakpoint at main.  Switch
    	to the SELECTED_THREAD thread.
    	(top level): Test handling the exec event with either the main
    	thread or the second thread selected.

commit a181c0bf7461c28cdb72a4074c6d7608119fb575
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Oct 9 09:54:42 2017 -0700

    Use gdbarch_long_bit to determine layout of FreeBSD siginfo_t.
    
    FreeBSD architectures are either ILP32 or LP64 resulting in two
    different layouts for siginfo_t.  Previously, the 'bits_per_word'
    member of bfd_arch_info was used to determine the layout to use for a
    given FreeBSD architecture.  However, mipsn32 architectures inherit
    from a 64-bit mips architecture where bits_per_word is 64.  As a
    result, $_siginfo was not properly extracted from FreeBSD/mipsn32 core
    dumps.  Fix this by using gdbarch_long_bit instead of 'bits_per_word'
    to determine if a FreeBSD architecture is ILP32 or LP64.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
    	(fbsd_convert_siginfo): Likewise.
    	* fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.

commit 6e66f7538112d2f5fb1af17dbde33ba37a7171be
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Mon Oct 9 12:50:58 2017 -0400

    Don't try building gdb against guile-2.2
    
    GDB currently doesn't build with Guile 2.2 (see PR 21104).  If one has
    both Guile 2.2 and 2.0 installed, GDB will pick up Guile 2.2 first and
    fail building.  Until somebody does the work of adapting the GDB code to
    Guile 2.2, we should not try using it.  This patch therefore removes it
    from configure.
    
    gdb/ChangeLog:
    
    	* configure.ac (try_guile_versions): Remove guile-2.2.
    	* configure: Regenerate.

commit 8e464506d2131fc931c4f81a22cc7125b7adf434
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Oct 9 18:37:53 2017 +0200

    S/390: Sync with latest POP - 3 new instructions
    
    prno, tpei, and irbm are missing in the optable.
    
    gas/ChangeLog:
    
    2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* testsuite/gas/s390/zarch-arch12.d (prno, tpei, irbm): New
    	instructions added.
    	* testsuite/gas/s390/zarch-arch12.s: Likewise.
    	* testsuite/gas/s390/zarch-z13.d: Rename ppno to prno.
    
    opcodes/ChangeLog:
    
    2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* s390-opc.txt (prno, tpei, irbm): New instructions added.

commit ee6767daf13a13867f8e716c2a53b748ab0da536
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Oct 9 18:37:53 2017 +0200

    S/390: Sync with IBM z14 POP - SI_RD format
    
    The recent POP adjusted a few of the instruction formats.  This patch
    adjusts our optable accordingly.  No user visible change - hopefully.
    
    opcodes/ChangeLog:
    
    2017-10-09  Heiko Carstens  <heiko.carstens@de.ibm.com>
    
    	* s390-opc.c (INSTR_SI_RD): New macro.
    	(INSTR_S_RD): Adjust example instruction.
    	* s390-opc.txt (lpsw, ssm, ts): Change S_RD instruction format to
    	SI_RD.

commit 890e97902a21a3b88f9b6028852736b813303029
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 17:12:19 2017 -0600

    Fix automatic dependency tracking
    
    Commit f38307f5 changed COMPILE.post and POSTCOMPILE to remove
    $(basename) from the dependency file name computation.  However, it
    did not update the `-include' at the end of the Makefile.in; this in
    effect disabled automatic dependency tracking.
    
    This patch restores the $(basename) wrapper so that the dependency
    files are named "file.Po" rather than "file.o.Po".
    
    I also tested the non-gcc3 dependency mode, which pointed out that
    this case hadn't been working since the switch to C++.  This is also
    fixed in this patch.
    
    Tested by rebuilding.
    
    ChangeLog
    2017-10-09  Tom Tromey  <tom@tromey.com>
    
    	* Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
    	(COMPILE.pre): Use $(CXX).

commit 109483d9eec3f0d0c3eaafd5d829435059167c52
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 9 15:57:36 2017 +0100

    Make cp_remove_params return a gdb::unique_xmalloc_ptr
    
    Use the type system instead of callers needing to know how the
    returned string's memory is supposed to be managed.
    
    gdb/ChangeLog:
    2017-10-09  Pedro Alves  <palves@redhat.com>
    
    	* cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
    	Use bool.
    	(overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
    	* cp-support.h (cp_remove_params): Now returns a
    	gdb::unique_xmalloc_ptr.
    	* dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
    	Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
    	* psymtab.c (psymtab_search_name): Adjust to cp_remove_params
    	returning a gdb::unique_xmalloc_ptr.
    	(lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
    	* stack.c (find_frame_funname): Adjust to cp_remove_params
    	returning a gdb::unique_xmalloc_ptr.

commit c474ea1a5f1524668cb8ce91c3682cb0cb837e08
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Oct 9 15:32:09 2017 +0100

    Fix link time warning message when running the srec linker tests.
    
    	* testsuite/ld-srec/srec.exp (run_srec_test): Set start address.

commit 6753e38a5c71b4b4ae81bba41fb67890abfa4e0f
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Oct 9 15:00:31 2017 +0100

    Fix compile time warning message when running the PR19874 linker test.
    
    	PR ld/19874
    	* testsuite/ld-x86-64/pr19784c.c (bar): Change return type to void.

commit e61933afce961c4b23c5e173b4b8f46b949bef30
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Oct 9 15:40:15 2017 +0200

    Add missing changelog entries

commit 5c9e4427a745e5e26fba320ecc62e4285b613e4f
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 9 12:33:31 2017 +0100

    Fix gdb.base/print-file-var-main.c value check logic
    
    Fix a typo introduced in commit c56e7c4390ed ("Make ctxobj.exp and
    print-file-var.exp work on all platforms.").
    
    This doesn't really affect the outcome of the testcase.  I only
    noticed the typo because I stepped through the program manually.
    
    To avoid such problems if the test is extended, this moves the STOP
    marker until after the program self-validates the values.  With the
    typo in place, this alone would have resulted in a test FAIL.  I.e.,
    it'd have caught the typo.
    
    gdb/testsuite/ChangeLog:
    2017-10-09  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/print-file-var-main.c: Fix get_version_2 value check
    	logic.  Move STOP marker after the value checks.
    	* gdb.base/print-file-var.exp (continue to STOP marker): Tighten
    	regexp.

commit 76f361eb4934dcda0626517c311b34fbc92d09b9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Oct 9 04:17:10 2017 -0700

    ld: Don't allow '~' as the first char in symbol name
    
    Don't allow '~' as the first character in symbol name in linker script.
    
    	PR ld/22267
    	* ldlex.l (SYMBOLNAMECHAR1) New.
    	(DEFSYMEXP): Replace FILENAMECHAR1 with SYMBOLNAMECHAR1.
    	(EXPRESSION): Likewise.
    	* testsuite/ld-scripts/expr.exp: Run pr22267.
    	* testsuite/ld-scripts/pr22267.d: New file.
    	* testsuite/ld-scripts/pr22267.s: Likewise.
    	* testsuite/ld-scripts/pr22267.t: Likewise.

commit 5d3b558acd329de9dcbd63d9bb04242b31fad490
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Mon Oct 9 12:24:11 2017 +0200

    Replace nop in fill-1.s testcase.
    
    gas/ChangeLog:
    
    2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* testsuite/gas/all/fill-1.s: Replace nop with .word 42

commit 4f2358bca6910cafbe9b37a713fd96e5ab84d4e8
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Fri Oct 6 13:12:32 2017 +0200

    Enable .fill forward labels
    
    gas/ChangeLog:
    
    2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* read.c (s_fill): Invoke expression instead of
    	get_known_segmented_expression.
    	* testsuite/gas/all/fill-1.s: New testcase.
    	* testsuite/gas/all/gas.exp: Run fill-1 testcase

commit 791afaa233ca9f4baa59aa16062296a00aa2c4da
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 13:29:18 2017 -0600

    Remove some cleanups from dwarf2read.c
    
    This removes a number of cleanups from dwarf2read.c in a
    straightforward way.
    
    Note that some places in dwarf2read create dangling cleanups.  I don't
    believe any of the changes in this patch interact with those spots.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-10-08  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2read.c (dwarf2_get_dwz_file): Use
    	gdb::unique_xmalloc_ptr.
    	(find_slot_in_mapped_hash): Likewise.
    	(dwarf2_physname): Likewise.
    	(create_dwo_unit_in_dwp_v1): Use std::string.
    	(create_dwo_unit_in_dwp_v2): Likewise.
    	(lookup_dwo_cutu): Likewise.
    	(inherit_abstract_dies): Use std::vector.
    	(read_array_type): Likewise.
    	(dwarf_decode_macros): Remove unused declaration.
    	(unsigned_int_compar): Remove.
    	(dwarf2_build_psymtabs_hard): Use scoped_restore.
    	(psymtabs_addrmap_cleanup): Remove.

commit 30a9c02feff56bd58a276c2a7262f364baa558ac
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 12:40:07 2017 -0600

    Remove cleanup from frame_prepare_for_sniffer
    
    Currently frame_prepare_for_sniffer returns a cleanup.  This patch
    changes it to return void, and exposes frame_cleanup_after_sniffer to
    the caller.
    
    Normally I would write an RAII class for this sort of thing; but
    because there was just a single caller of frame_prepare_for_sniffer,
    and because this caller is already using try/catch, I thought it
    seemed ok to require explicit calls in this instance.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-10-08  Tom Tromey  <tom@tromey.com>
    
    	* frame-unwind.c (frame_unwind_try_unwinder): Update.
    	* frame.h (frame_cleanup_after_sniffer): Declare.
    	(frame_prepare_for_sniffer): Return void.
    	* frame.c (frame_cleanup_after_sniffer): No longer static.  Change
    	type of argument.
    	(frame_prepare_for_sniffer): Return void.

commit 757325a3f24e01bf8e7b7214f33c546bc52d1d12
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 12:20:49 2017 -0600

    Remove make_cleanup_value_free
    
    This removes make_cleanup_value_free, in favor of a unique_ptr
    specialization.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-10-08  Tom Tromey  <tom@tromey.com>
    
    	* utils.h (make_cleanup_value_free): Remove.
    	* utils.c (do_value_free, struct cleanup): Remove.
    	* dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
    	Use gdb_value_up.
    	* value.h (struct value_deleter): New.
    	(gdb_value_up): New typedef.

commit b9c04fb2681dd5706d2cafa5dcc6bdcd99016cf4
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Oct 8 12:11:18 2017 -0600

    Change search_symbols to return std::vector
    
    This changes search_symbols to return a std::vector, replacing the
    previous linked list approach.  This allows the removal of some
    cleanups, as well as the use of std::sort and std::unique, saving some
    code and extra allocations in sort_search_symbols_remove_dups.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-10-08  Tom Tromey  <tom@tromey.com>
    
    	* symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
    	(make_cleanup_free_search_symbols): Remove.
    	(search_symbols): Return std::vector.
    	(symbol_search::compare_search_syms): Now member of
    	symbol_search.  Change arguments.
    	(sort_search_symbols_remove_dups): Change arguments.  Rewrite.
    	(symtab_symbol_info, rbreak_command): Update.
    	* symtab.h (struct symbol_search) <next>: Remove.
    	Add constructors.
    	(symbol_search::operator<): New function.
    	(symbol_search::operator==): New function.
    	(search_symbols): Remove std::vector.
    	(free_search_symbols, make_cleanup_free_search_symbols): Remove.
    	(symbol_search::compare_search_syms): Declare.

commit b55ec8b676ed05d93ee49d6c79ae0403616c4fb0
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Oct 9 13:21:44 2017 +1030

    PR22212, memory leak in nm
    
    	PR 22212
    	* dwarf2.c (_bfd_dwarf2_cleanup_debug_info): Free
    	funcinfo_hash_table and varinfo_hash_table.

commit a72f95f7760bf85693af393c5e01dd3aedbe5bde
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Oct 8 17:17:29 2017 -0700

    sh: Dump dynamic relocation info to the map file
    
    Dump dynamic relocation info to the map file when generating dynamic
    relocation in read-only section relocations if -Map is used.
    
    	* elf32-sh.c (readonly_dynrelocs): Dump dynamic relocation
    	in read-only section with minfo.
    	(sh_elf_size_dynamic_sections): Likewise.

commit f9799aae8e51948c1d87fbe7249b3d76dcb4585d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Oct 8 17:09:26 2017 -0700

    sparc: Remove a strayed comment
    
    	* elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): Remove
    	a strayed comment.

commit effaa0a1e8d63a7063e8c7b42fe1f9b98a4da2fe
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Oct 9 00:00:30 2017 +0000

    Automatic date update in version.in

commit 4c7236d3cb7b971bbdc97b6aec348a4aa0594a9b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Oct 8 14:29:52 2017 -0700

    tilegx: Set this_hdr.sh_entsize only if section size > 0
    
    This fixes:
    
    /export/build/gnu/binutils-cross/build-tilegx-linux/ld/ld-new   -o tmpdir/comm-data -z norelro -L/export/gnu/import/git/sources/binutils-gdb/ld/testsuite/ld-elf  -T comm-data2.ld -Ltmpdir -lcomm-data tmpdir/comm-data2.o
    sh: line 1:  9208 Segmentation fault      (core dumped) /export/build/gnu/binutils-cross/build-tilegx-linux/ld/ld-new -o tmpdir/comm-data -z norelro -L/export/gnu/import/git/sources/binutils-gdb/ld/testsuite/ld-elf -T comm-data2.ld -Ltmpdir -lcomm-data tmpdir/comm-data2.o 2>&1
    FAIL: Common symbol override test
    
    	* elfxx-tilegx.c (tilegx_elf_finish_dynamic_sections): Set
    	this_hdr.sh_entsize only if section size > 0.

commit 70090aa5f629dcbdfa88b20c29951fa8f50f0545
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Oct 8 13:20:17 2017 -0700

    Reformat elf_x86_allocate_dynrelocs
    
    	* elfxx-x86.c (elf_x86_allocate_dynrelocs): Reformat.

commit f0f07ad1825e9b7f539e410562993b25f76e5627
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 7 17:30:12 2017 -0700

    sparc: Dump dynamic relocation info to the map file
    
    Dump dynamic relocation info to the map file when generating dynamic
    relocation in read-only section relocations if -Map is used.
    
    	* elfxx-sparc.c (readonly_dynrelocs): Dump dynamic relocation
    	in read-only section with minfo.
    	(_bfd_sparc_elf_size_dynamic_sections): Likewise.

commit b05c287c1820c5a86e08afec26f5f73b65b416aa
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Oct 8 00:00:25 2017 +0000

    Automatic date update in version.in

commit 2458d83bbc190f92f7718b30438dd7e5775e0d3c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Oct 7 16:10:56 2017 -0700

    ld-elf/merge.d: Don't expect to fail for sparc
    
    It passed with cross binutils to sparc-linux and sparc64-linux.
    
    	* testsuite/ld-elf/merge.d: Don't expect to fail for sparc.

commit 0ee6e554c4f8b23cdd629774ae94a74af5826976
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Oct 7 00:00:17 2017 +0000

    Automatic date update in version.in

commit 99180bccaf09413c9ddb28e51fa30f1ca4966583
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 16:45:37 2017 -0700

    x86: Update UNDEFINED_WEAK_RESOLVED_TO_ZERO comments
    
    	* elfxx-x86.h (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Update
    	comments.

commit 98b273dc13b1e45db8c66821efc9e514884f3c25
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 15:25:07 2017 -0700

    x86: Use zero_undefweak in elf_x86_link_hash_entry
    
    Replace has_got_reloc and has_non_got_reloc in elf_x86_link_hash_entry
    with zero_undefweak:
    
    Bit 0: Symbol has no GOT nor PLT relocations.
    Bit 1: Symbol has non-GOT/non-PLT relocations in text sections.
    
    zero_undefweak is initialized to 1 and undefined weak symbol should be
    resolved to 0 if zero_undefweak > 0.
    
    	* elf32-i386.c (elf_i386_check_relocs): Replace has_got_reloc
    	and has_non_got_reloc with zero_undefweak.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_newfunc): Initialize
    	zero_undefweak to 1.
    	(_bfd_x86_elf_copy_indirect_symbol): Replace has_got_reloc and
    	has_non_got_reloc with zero_undefweak.
    	* elfxx-x86.h (UNDEFINED_WEAK_RESOLVED_TO_ZERO): Replace
    	has_got_reloc and has_non_got_reloc with zero_undefweak.
    	(elf_x86_link_hash_entry): Likewise.

commit b3b7c423883ad8d8b81f166ad2d2d4b637086bc0
Author: Sandra Loosemore <sandra@codesourcery.com>
Date:   Fri Oct 6 15:24:01 2017 -0700

    Skip gdb.mi/mi-threads-interrupt.exp if nointerrupts.
    
    2017-10-06  Sandra Loosemore  <sandra@codesourcery.com>
    
    	gdb/testsuite/
    	* gdb.mi/mi-threads-interrupt.exp: Skip test if nointerrupts.

commit 544c67cda1686c1b204cb96c0d7885b08d37b8d6
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Fri Oct 6 11:41:45 2017 -0700

    Account for padding in FreeBSD/mipsn32 NT_PRSTATUS notes.
    
    Add a new ELF backend method to grok FreeBSD NT_PRSTATUS core dump
    notes.  Define a method for MIPS N32 to override the default
    elfcore_grok_freebsd_prstatus that accounts for additional padding
    between pr_pid and pr_reg that is not present in other 32-bit FreeBSD
    platforms.
    
    	* elf-bfd.h (struct elf_backend_data): Add
    	`elf_backend_grok_freebsd_prstatus'.
    	* elf.c (elfcore_grok_freebsd_note): Call
    	`elf_backend_grok_freebsd_prstatus' to handle NT_PRSTATUS if
    	present.
    	* elfn32-mips.c (elf_n32_mips_grok_freebsd_prstatus): New
    	function.
    	(elf_backend_grok_freebsd_prstatus): Define.
    	* elfxx-target.h (elf_backend_grok_freebsd_prstatus): Define.
    	(elfNN_bed): Initialize `elf_backend_grok_freebsd_prstatus'.

commit 0d28b0a5caa6b04129e21a9aff371d4032c7ef17
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 6 14:53:39 2017 +0100

    Move aarch64-insn.o to arch/aarch64-insn.o and Remove a rule for arch/*.c
    
    This patch moves aarch64-insn.o to arch/aarch64-insn.o.  Then, all
    arch/*.c are built to arch/*.o, so we don't need a Makefile rule to build
    *.o from arch/*.c.  This patch removes it too.
    
    gdb:
    
    2017-10-06  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
    	arch/aarch64-insn.o.
    	Remove one rule.
    	* configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.

commit 71917808c3490b4d4df9c6e848e3c5d75f5278d2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 6 14:36:04 2017 +0100

    Move arm.o arm-get-next-pcs.o arm-linux.o to arch/
    
    It is tested by building GDB for some targets, arm-elf, arm-netbsd,
    arm-linux, and aarch64-linux.
    
    gdb:
    
    2017-10-06  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
    	and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
    	arch/arm-linux.o respectively.
    	* configure.tgt: Likewise.

commit 2081b2b2ca30d7c3b6464a3e167ce2c336c0465f
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 6 14:07:29 2017 +0100

    Move i386.o to arch/i386.o
    
    This patch changes the build that arch/i386.c is built to arch/i386.o,
    instead of i386.o.
    
    gdb:
    
    2017-10-06  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
    	* configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.

commit e0d8f43169368abf354e596c7725dee1dd609cb8
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 05:49:48 2017 -0700

    Add "do/while(0);" to COPY_INPUT_RELOC_P/VERIFY_COPY_RELOC
    
    Add "do/while(0);" to COPY_INPUT_RELOC_P/VERIFY_COPY_RELOC to avoid
    potential dangling else problems.
    
    	* elfxx-x86.h (COPY_INPUT_RELOC_P): Add "do/while(0);".
    	(VERIFY_COPY_RELOC): Likewise.

commit a1b85d282f408dfd18a27539874846197f7e4044
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Oct 6 11:58:56 2017 +0100

    Fix more GDB build breakage on mingw32
    
    With F23's mingw gcc 5.3.0, I'm seeing:
    
     i686-w64-mingw32-g++ -x c++ -std=gnu++11 -g3 -O0   -I. -I../../src/gdb -I../../src/gdb/common -I../../src/gdb/config -DLOCALEDIR="\"/usr/local/share/locale\"" -DHAVE_CONFIG_H -I../../src/gdb/../include/opcode -I../../src/gdb/../opcodes/.. -I../../src/gdb/../readline/.. -I../../src/gdb/../zlib -I../bfd -I../../src/gdb/../bfd -I../../src/gdb/../include -I../libdecnumber -I../../src/gdb/../libdecnumber  -I../../src/gdb/gnulib/import -Ibuild-gnulib/import   -I/home/pedro/src/expat/install-win32//include   -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable -Wno-sign-compare -Wno-narrowing -Wno-error=maybe-uninitialized -Wno-format -Werror -c -o windows-nat.o -MT windows-nat.o -MMD -MP -MF ./.deps/windows-nat.o.Tpo ../../src/gdb/windows-nat.c
     ../../src/gdb/windows-nat.c: In function 'void windows_create_inferior(target_ops*, const char*, const string&, char**, int)':
     ../../src/gdb/windows-nat.c:2476:7: error: 'replace' is not a member of 'std'
    	std::replace (expanded_infcwd.begin (), expanded_infcwd.end (),
    	^
    
    gdb/Changelog:
    2017-10-06  Pedro Alves  <palves@redhat.com>
    
    	* windows-nat.c: Include <algorithm>.

commit b79f7801a2c555ee4ff4bc3050141e83158f66d4
Author: Yuanhui Zhang <asmwarrior@gmail.com>
Date:   Fri Oct 6 11:44:54 2017 +0100

    Fix GDB build under msys+mingw gcc 32bit
    
    I see a build error when building GDB under msys+mingw gcc 32bit:
    
     g++ -x c++ -std=gnu++11 -g -O2    -I. -I../../../binutils-gdb/gdb/gdbserver -I../../../binutils-gdb/gdb/gdbserver/../common -I../../../binutils-gdb/gdb/gdbserver/../regformats -I../../../binutils-gdb/gdb/gdbserver/.. -I../../../binutils-gdb/gdb/gdbserver/../../include -I../../../binutils-gdb/gdb/gdbserver/../gnulib/import -Ibuild-gnulib-gdbserver/import  -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wunused-but-set-parameter -Wunused-but-set-variable -Wno-sign-compare -Wno-narrowing -Wno-error=maybe-uninitialized -Wno-format -Werror -DGDBSERVER -c -o win32-low.o -MT win32-low.o -MMD -MP -MF .deps/win32-low.Tpo ../../../binutils-gdb/gdb/gdbserver/win32-low.c
     ../../../binutils-gdb/gdb/gdbserver/win32-low.c: In function 'BOOL create_process(const char*, char*, DWORD, PROCESS_INFORMATION*)':
     ../../../binutils-gdb/gdb/gdbserver/win32-low.c:566:48: error: 'get_inferior_cwd' was not declared in this scope
        const char *inferior_cwd = get_inferior_cwd ();
    						 ^
     make[4]: *** [win32-low.o] Error 1
    
    It can be fixed by simply including the right header file.
    
    gdb/gdbserver/ChangeLog:
    2017-10-06  Yuanhui Zhang  <asmwarrior@gmail.com>
    
    	* win32-low.c: Include "common-inferior.h".

commit d97987e219b80c670e37eb0e25e31b36fa295509
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 6 11:18:48 2017 +0100

    Share code updating gdb_target_obs
    
    Nowadays, there are much duplications in configure.tgt to update
    gdb_target_obs, some cpu specific object files are added to gdb_target_obs
    to some different target triplets of the same cpu.  The same problem
    exists for os specific object files too.  It is fragile to update them,
    and build with all targets enabled doesn't find the problem.
    
    This patch splits the gdb_target_obs update to three steps, cpu steps, os
    steps, and the rest.
    
    I tested this patch by build gdb for each different target triplets
    respectively,
    
    aarch64-elf aarch64-rtems aarch64-freebsd aarch64-linux alpha-elf
    alpha-linux alpha-netbsd alpha-openbsd arm-elf arm-wince-pe arm-linux
    arm-netbsd arm-symbianelf avr cris-elf frv-elf h8300-elf i386-elf
    i386-darwin i386-dicos i386-freebsd i386-netbsdelf i386-openbsd
    i386-nto i386-solaris i386-linux i386-gnu i386-cygwin i386-mingw32
    i386-go32 ia64-linux-gnu ia64-vms lm32-elf m32c-elf m32r-elf m32r-linux
    m68hc11-elf m68k-elf m68k-linux m68k-netbsd m68k-openbsd m88k-openbsd
    mep-elf microblaze-xilinx-elf microblaze-linux-gnu mips-elf moxie-elf
    ms1-elf nios2-elf nios2-linux-gnu hppa-elf hppa-linux hppa-netbsd
    hppa-openbsd powerpc-eabi powerpc-freebsd powerpc-netbsd powerpc-openbsd
    powerpc-linux powerpc-lynx178 rl78-elf rx-elf s390-linux-gnu score-elf
    sh-elf sh-linux sh-openbsd sh64-elf sh64-linux sh64-openbsd sparc64-linux
    sparc-linux sparc-freebsd sparc64-freebsd sparc-netbsd sparc64-netbsd
    sparc-openbsd sparc64-openbsd spu-elf tic6x-elf tic6x-uclinux v850-elf
    vax-netbsd vax-openbsd x86_64-linux-gnu x86_64-darwin x86_64-dicos
    x86_64-elf x86_64-freebsd x86_64-mingw32 x86_64-netbsd x86_64-openbsd
    x86_64-rtems xstormy16-elf xtensa-elf xtensa-linux
    
    gdb:
    
    2017-10-06  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.tgt (i386_tobjs): New variable.
    	(amd64_tobjs): New variable.
    	Set $cpu_obs and $os_obs.

commit f38307f593cb8189c82fb39e46e0cd899022e2fb
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Oct 6 11:13:30 2017 +0100

    [RFC] Replicate src dir in build dir
    
    Nowadays, GDB build tree is almost flat, but source tree isn't.  We
    have arch/ nat/ target/ common/ cli/ mi/ tui/ python/ guile/ directories.
    We need to some rules in Makefile for source files in different source
    directories, like,
    
     # Rules for compiling .c files in the various source subdirectories.
    %.o: ${srcdir}/arch/%.c
    	$(COMPILE) $<
    	$(POSTCOMPILE)
    
    %.o: ${srcdir}/nat/%.c
    	$(COMPILE) $<
    	$(POSTCOMPILE)
    
    so we should take care of some special case that files' base name is the
    same, like,
    
     # Specify an explicit rule for gdb/common/agent.c, to avoid a clash with the
     # object file generate by gdb/agent.c.
    common-agent.o: $(srcdir)/common/agent.c
    	$(COMPILE) $(srcdir)/common/agent.c
    	$(POSTCOMPILE)
    
    As we add more and more files in different directories, it becomes tricky
    to name files, because we need take this into account.
    
    This patch takes the first step toward "Replicate src dir in build dir",
    that is, we create arch/ directory in buildtree, and put amd64.o there
    as an example.  Dependency tracking is updated for files with directory
    name.  Currently, when we build amd64.o,
    
      "-c -o amd64.o -MT amd64.o -MMD -MP -MF .deps/amd64.Tpo"
    
    with this patch applied, it becomes,
    
      "-c -o arch/amd64.o -MT arch/amd64.o -MMD -MP -MF arch/.deps/amd64.o.Tpo"
    
    "make clean" removes the object files, and "make distclean" removes .deps
    additionally.  configure file create .deps directory in each of
    CONFIG_SRC_SUBDIR, and pass it to Makefile.in, so that "make clean" and
    "make distclean" can remove stuffs there.
    
    If people agree with this change, I'll add more directories to
    CONFIG_SRC_SUBDIR.
    
    gdb:
    
    2017-10-06  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (CONFIG_SRC_SUBDIR): New.
    	(ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
    	(clean): Remove object files and dependency files.
    	(distclean): Remove the directory.
    	* configure.ac: Invoke AC_CONFIG_COMMANDS.
    	* configure: Re-generated.
    	* configure.tgt: Replace amd64.o with arch/amd64.o.

commit 2f924de654ff8f719faf60b84948397809baaac6
Author: Jose E. Marchesi <jose.marchesi@oracle.com>
Date:   Fri Oct 6 11:49:39 2017 +0200

    gdb: Fix decoding of ARM neon memory hint insns.
    
    gdb/ChangeLog:
    
    2017-10-05  Jose E. Marchesi  <jose.marchesi@oracle.com>
    
    	PR build/22188
    	* arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
    	and SETEND.

commit ff38b4cc55dade4c9970cac2149a946d5dc0adc7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:50:12 2017 -0700

    x86: Add VERIFY_COPY_RELOC
    
    Add VERIFY_COPY_RELOC to verify that symbol supports copy relocation.
    
    	* elfxx-x86.h (VERIFY_COPY_RELOC): New.
    	* elf32-i386.c (elf_i386_finish_dynamic_symbol): Use it.
    	* elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.

commit f3180fa9ee8917fa9547cd5f79c822761f5d87a0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:46:56 2017 -0700

    x86: Add VERIFY_PLT_ENTRY
    
    Add VERIFY_PLT_ENTRY to verify that symbol has an entry in the procedure
    linkage table.
    
    	* elfxx-x86.h (VERIFY_PLT_ENTRY): New.
    	* elf32-i386.c (elf_i386_finish_dynamic_symbol): Use it.
    	* elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Likewise.

commit e74399c47c76b8111651f41b52a05401852cf799
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:43:31 2017 -0700

    x86: Add COPY_INPUT_RELOC_P
    
    Add COPY_INPUT_RELOC_P which returns TRUE if input relocation should
    be copied to output.
    
    	* elfxx-x86.h (COPY_INPUT_RELOC_P): New.
    	* elf32-i386.c (elf_i386_relocate_section): Use it.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.

commit aebcc8ffd201adbee973b414818b01876dabe1a0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:40:56 2017 -0700

    x86: Add GENERATE_DYNAMIC_RELOCATION_P
    
    Add GENERATE_DYNAMIC_RELOCATION_P which returns TRUE if dynamic
    relocation should be generated.
    
    	* elf32-i386.c (X86_SIZE_TYPE_P): New.
    	(elf_i386_relocate_section): Use GENERATE_DYNAMIC_RELOCATION_P.
    	* elf64-x86-64.c (X86_SIZE_TYPE_P): New.
    	(elf_x86_64_relocate_section): Use GENERATE_DYNAMIC_RELOCATION_P.
    	* elfxx-x86.h (GENERATE_DYNAMIC_RELOCATION_P): New.

commit cf1070f1a1ca1f8be1cd88aa6ece55a25e6a887b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:35:13 2017 -0700

    x86: Add POINTER_LOCAL_IFUNC_P/PLT_LOCAL_IFUNC_P
    
    Add POINTER_LOCAL_IFUNC_P which returns TRUE for pointer reference to
    local IFUNC symbol.  Add PLT_LOCAL_IFUNC_P which returns TRUE for PLT
    reference to local IFUNC symbol.
    
    	* elfxx-x86.h (POINTER_LOCAL_IFUNC_P): New.
    	(PLT_LOCAL_IFUNC_P): Likewise.
    	* elf32-i386.c (elf_i386_relocate_section): Use them.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.

commit f70656b2604eff12cea2e9bef27c1e00a3077f30
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:29:16 2017 -0700

    x86: Add GENERATE_RELATIVE_RELOC_P
    
    Add GENERATE_RELATIVE_RELOC_P which returns TRUE if dynamic relative
    relocation should be generated.
    
    	* elfxx-x86.h (GENERATE_RELATIVE_RELOC_P): New.
    	* elf32-i386.c (elf_i386_relocate_section): Use it.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.

commit 1f92404c505db7ca2255dad73647889234013a0a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:26:17 2017 -0700

    x86: Add RESOLVED_LOCALLY_P
    
    Add RESOLVED_LOCALLY_P which returns TRUE if symbol is resolved to
    local definition at link-time.
    
    	* elfxx-x86.h (RESOLVED_LOCALLY_P): New.
    	* elf32-i386.c (elf_i386_relocate_section): Use it.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.

commit 2eba97c207399d8b541092a7b0a4428dc02f5cf1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 5 14:36:58 2017 -0700

    Add RESOLVED_LOCALLY_P

commit daf1c414a48baf090f005ce4b319b6881d5d6872
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:21:48 2017 -0700

    x86: Add NEED_DYNAMIC_RELOCATION_P
    
    Add NEED_DYNAMIC_RELOCATION_P which returns TRUE if dynamic relocation
    is needed.
    
    	* elf32-i386.c (X86_PCREL_TYPE_P): New.
    	(elf_i386_check_relocs): Use NEED_DYNAMIC_RELOCATION_P.
    	* elf64-x86-64.c (IS_X86_64_PCREL_TYPE): Renamed to ...
    	(X86_PCREL_TYPE_P): This.
    	(elf_x86_64_check_relocs): Use NEED_DYNAMIC_RELOCATION_P.
    	Replace IS_X86_64_PCREL_TYPE with X86_PCREL_TYPE_P.
    	(elf_x86_64_relocate_section): Replace IS_X86_64_PCREL_TYPE with
    	X86_PCREL_TYPE_P.
    	* elfxx-x86.h (NEED_DYNAMIC_RELOCATION_P): New.

commit 51537393bd939e79f6e9291629fb65a17e6f19da
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Oct 6 00:11:41 2017 -0700

    x86: Add TLS_TRANSITION_IE_TO_LE_P
    
    Add TLS_TRANSITION_IE_TO_LE_P which returns TRUE if TLS IE->LE transition
    is OK.
    
    	* elfxx-x86.h (TLS_TRANSITION_IE_TO_LE_P): New.
    	* elf32-i386.c (elf_i386_tls_transition): Use it.
    	* elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.

commit e98fdf1ab07243fe467caadd0d033b44b8ca20c7
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Oct 6 14:14:21 2017 +1030

    DWARF header checks
    
    This patch tidies DWARF header checks, consolidating the "negative"
    checks (which are really overflow checks) with the section size
    check.  In a number of cases this also ensures that small negative
    lengths are caught.  For instance
    
          hdrptr = start + arange.ar_length + initial_length_size;
          if (hdrptr < start || hdrptr > end)
    
    does not detect ar_length in the range [-initial_length_size,-1].
    
    	* dwarf.c (process_debug_info): Consolidate header length checks.
    	(display_debug_pubnames_worker): Use "start" to read header.
    	Properly check header length and report errors earlier.
    	Simplify loop printing pubnames.
    	(get_line_filename_and_dirname): Catch small negative "length"
    	values.
    	(display_debug_aranges): Likewise.  Report header errors
    	earlier using standardized message.
    	(display_debug_names): Likewise.

commit 0caf6c82ab23ece570d14499ed02653968cd8abd
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 5 18:09:07 2017 -0700

    powerpc: Dump dynamic relocation info to the map file
    
    Dump dynamic relocation info to the map file when generating dynamic
    relocation in read-only section relocations if -Map is used.
    
    	* elf32-ppc.c (readonly_dynrelocs): Add a link_info argument.
    	Dump dynamic relocation in read-only section with minfo if
    	needed.
    	(ppc_elf_adjust_dynamic_symbol): Pass NULL to readonly_dynrelocs.
    	(maybe_set_textrel): Likewise.
    	(ppc_elf_size_dynamic_sections): Dump dynamic relocation in
    	read-only section with minfo.

commit 46e31de783dd29036370f2a1a233bd0e65ab2dd0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Oct 6 00:00:28 2017 +0000

    Automatic date update in version.in

commit 2fd9d7ca17539ce983862b25e0abc27cfb706189
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Oct 5 18:33:22 2017 +0100

    Fix fork-related regressions on GNU/Linux
    
    Commit 5cd63fda035d ("Fix "Remote 'g' packet reply is too long"
    problems with multiple inferiors") caused a number of regressions on
    native GNU/Linux, all related to follow-fork support.  E.g.:
    
      src/gdb/target.c:3141: internal-error: gdbarch* default_thread_architecture(target_ops*, ptid_t): Assertion `inf != NULL' failed.
      A problem internal to GDB has been detected,
      further debugging may prove unreliable.
      Quit this debugging session? (y or n)
      Resyncing due to internal error.
      FAIL: gdb.base/catch-signal-fork.exp: got SIGHUP after fork (GDB internal error)
    
    This commit fixes it.
    
    gdb/ChangeLog:
    2017-10-05  Pedro Alves  <palves@redhat.com>
    
    	* linux-nat.c (linux_child_follow_fork): When following the parent
    	and detaching the child, consult the parent thread's architecture
    	instead of the child's.

commit d13b8493cbd2891b5886e6176d468eb63c73606a
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Thu Oct 5 19:15:11 2017 +0200

    Remove unused "union agent_val" from ax.h
    
    The ax.h header file contains a use of DOUBLEST in the type "union agent_val".
    
    However, that type is never used anywhere, so it can be simply removed.
    
    gdb/ChangeLog:
    2017-10-05  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* ax.h: Do not include "doublest.h".
    	(union agent_val): Remove.

commit 3b4b2f160d288b85a1379d24fd0f4de19062f3fd
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Thu Oct 5 19:14:08 2017 +0200

    Clean up some DFP interfaces
    
    This cleans up a number of interfaces in dfp.c / dfp.h.  Specifically:
    
    - The decimal_from_string / decimal_to_string routines are C++-ified
      to operate on std::string instead of character buffers.  In the
      decimal_from_string, the boolean return value now actually is bool
      instead of an int.
    
    - The decimal_from_integral and decimal_from_doublest routines take
      an struct value as input.  This is not really appropriate at the low
      level the DFP routines sit, so this replaced them with new routines
      decimal_from_longest / decimal_from_ulongest / decimal_from_doublest
      that operate on contents instead.
    
    - To mirror the decimal_from_[u]longest, a new decimal_to_longest
      routine is added as well, which can be used in unpack_long to
      avoid an unnecessary conversion via DOUBLEST.
    
    Note that the decimal_from_longest / decimal_from_ulongest routines
    are actually more powerful than decimal_from_integral: the old routine
    would only accept integer *types* of at most four bytes size, while
    the new routines accept all integer *values* that fit in an [u]int32_t,
    no matter which type they came from.  The DFP tests are updated to
    allow for this larger range of integers that can be converted.
    
    gdb/ChangeLog:
    2017-10-05  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
    	(decimal_to_string): Return std::string object.
    	(decimal_from_string): Accept std::string object.  Return bool.
    	(decimal_from_integral, decimal_from_doublest): Remove.
    	(decimal_from_longest): Add prototype.
    	(decimal_from_ulongest): Likewise.
    	(decimal_to_longest): Likewise.
    	(decimal_from_doublest): Likewise.
    	* dfp.c: Do not include "gdbtypes.h" or "value.h".
    	(MAX_DECIMAL_STRING): Move here.
    	(decimal_to_string): Return std::string object.
    	(decimal_from_string): Accept std::string object.  Return bool.
    	(decimal_from_integral): Remove, replace by ...
    	(decimal_from_longest, decimal_from_ulongest): ... these new functions.
    	(decimal_to_longest): New function.
    	(decimal_from_floating): Remove, replace by ...
    	(decimal_from_doublest): ... this new function.
    	(decimal_to_doublest): Update to new decimal_to_string interface.
    
    	* value.c (unpack_long): Use decimal_to_longest.
    	* valops.c (value_cast): Use decimal_from_doublest instead of
    	decimal_from_floating.  Use decimal_from_[u]longest isntead of
    	decimal_from_integral.
    	* valarith.c (value_args_as_decimal): Likewise.
    	* valprint.c (print_decimal_floating): Update to new
    	decimal_to_string interface.
    	* printcmd.c (printf_decfloat): Likewise.
    	* c-exp.y (parse_number): Update to new decimal_from_string interface.
    
    gdb/testsuite/ChangeLog:
    2017-10-05  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdb.base/dfp-exprs.exp: Update tests to larger range of supported
    	integer-to-dfp conversion.
    	* gdb.base/dfp-test.exp: Likewise.

commit 1841ee5d0300cf00022c8aadfe16725c5e86fe1d
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Thu Oct 5 19:12:45 2017 +0200

    Clean up includes of doublest.h and floatformat.h
    
    As a first small step to getting rid of doublest.h, this patch removes the
    include of "floatformat.h" in "doublest.h".  This is actually not needed
    for the file itself.  A few source files now need to include "floatformat.h"
    directly, since they got it indirectly via "doublest.h" and still need it.
    
    In reviewing which files need it, I found a number of files that include
    "floatformat.h" directly without actually needing it at all.  Similarly,
    a number of files include "doublest.h" without needing it.  I've also
    removed those unnecessary include statements.
    
    gdb/ChangeLog:
    2017-10-05  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.h: Do not include "floatformat.h".  Remove stale comments.
    	* gdbtypes.c: Include "floatformat.h".
    	* value.c: Likewise.
    	* m68k-tdep.c: Likewise.
    
    	* findvar.c: Do not include "floatformat.h".
    	* amd64-darwin-tdep.c: Likewise.
    	* arm-linux-tdep.c: Likewise.
    	* i386-darwin-tdep.c: Likewise.
    	* i387-tdep.c: Likewise.
    	* m68k-linux-tdep.c: Likewise.
    	* mep-tdep.c: Likewise.
    	* mips-tdep.c: Likewise.
    	* nios2-tdep.c: Likewise.
    	* s390-linux-tdep.c: Likewise.
    	* sparc-obsd-tdep.c: Likewise.
    	* sparc-tdep.c: Likewise.
    	* sparc64-tdep.c: Likewise.
    	* spu-tdep.c: Likewise.
    	* tic6x-tdep.c: Likewise.
    	* tilegx-tdep.c: Likewise.
    	* vax-tdep.c: Likewise.
    	* xstormy16-tdep.c: Likewise.
    	* xtensa-tdep.c: Likewise.
    
    	* top.c: Do not include "doublest.h".
    	* aarch64-tdep.c: Likewise.
    	* alpha-tdep.c: Likewise.
    	* arm-linux-tdep.c: Likewise.
    	* m68k-linux-tdep.c: Likewise.
    	* tilegx-tdep.c: Likewise.
    	* xstormy16-tdep.c: Likewise.

commit a80a647180bf92692e0f01efe7b323afe7d317c9
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Thu Oct 5 09:50:01 2017 -0700

    Add a signal frame unwinder for FreeBSD/mipsn32.
    
    The N32 signal frame uses an identical layout to N64, so reuse the N64
    handler.  The N32 signal trampoline does use one different instruction
    relative to N64, so a separate tramp_frame is required.
    
    gdb/ChangeLog:
    
    	* mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
    	(mipsn32_fbsd_sigframe): Define.
    	(mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
    	for FreeBSD/mipsn32.

commit 6d5be5d6b8b4412e65bc037472aa2e727c25ccf5
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Thu Oct 5 09:50:01 2017 -0700

    Handle the NT_ARM_VFP core dump note on FreeBSD.
    
    bfd/ChangeLog:
    
    	* elf.c (elfcore_grok_freebsd_note): Handle NT_ARM_VFP.

commit 12c4bd7f53e9cefcf7c3a7f8cbf9e552526cb963
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Thu Oct 5 09:50:01 2017 -0700

    Handle FreeBSD-specific AT_EHDRFLAGS and AT_HWCAP auxiliary vector types.
    
    FreeBSD recently added two additional ELF auxiliary vectors.  FreeBSD's
    AT_HWCAP uses a different number compared to AT_HWCAP on Linux as the
    numerical value was already in use for a different vector on FreeBSD.
    
    include/ChangeLog:
    
    	* elf/common.h (AT_FREEBSD_EHDRFLAGS, AT_FREEBSD_HWCAP): Define.
    
    gdb/ChangeLog:
    
    	* fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
    	AT_HWCAP.

commit 2bfa0cdfadd313f3cc35329a17ba3c62865208a3
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 16:17:22 2017 +0100

    Fix the MSP430 assembler so that it detects and reports extraneous text at the end of operands.
    
    	PR 22133
    	* config/tc-msp430.c (parse_exp): Skip an 'h' suffix to constant
    	expressions.
    	(msp430_srcoperand): Check that the entire text was parsed by
    	parse_exp.
    	(msp430_operands): Likewise.
    	* testsuite/gas/msp430/pr22133.s: New test file.
    	* testsuite/gas/msp430/pr22133.d: New test driver.
    	* testsuite/gas/msp430/pr22133.s: Expected error output.
    	* testsuite/gas/msp430/msp430.exp: Run the new test.

commit 97953bab05cca82bd3119de4d5cf26103b649597
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Thu Oct 5 14:19:39 2017 +0000

    Avoid spurious readelf error status from decode_arm_unwind.
    
    readelf.c:decode_arm_unwind has a variable res that is used as a
    return value, with FALSE meaning unsuccessful and TRUE meaning
    successful.  This is initialized to FALSE (and then various code in
    the function sets it to FALSE again on error), meaning that when the
    function is successful, if it reaches returning res is still returns
    FALSE, resulting eventually in exit status 1 from readelf without any
    error message to indicate an error.
    
    This patch fixes the initialization to use TRUE, so avoiding those
    spurious errors.  I don't have a self-contained test for this issue;
    it was observed as many prelink tests failing without the patch and
    passing with it.
    
    	* readelf.c (decode_arm_unwind): Initialize res to TRUE.

commit 64f7152491727daf8d0b294aa5ddf49f08c63ca2
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 14:10:27 2017 +0100

    Update the Hungarian translation in the gprof directory.
    
    	* po/hu.po: Updated Hungarian translation.

commit 94750c06e89e273751d54148b649098677ecdff2
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 14:02:10 2017 +0100

    Updated Turkish translation for the ld sub-directory.
    
    	* po/tr.po: Updated Turkish translation.

commit 007873f54e41eaef2f7a89b8adbb63a563d98b65
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Oct 5 06:01:18 2017 -0700

    tile: Dump dynamic relocation info to the map file
    
    Dump dynamic relocation info to the map file when generating dynamic
    relocation in read-only section relocations if -Map is used.
    
    	* elf32-tilepro.c (readonly_dynrelocs): Dump dynamic relocation
    	in read-only section with minfo.
    	(tilepro_elf_size_dynamic_sections): Likewise.
    	* elfxx-tilegx.c (readonly_dynrelocs): Likewise.
    	(tilegx_elf_size_dynamic_sections): Likewise.

commit ea8fae9fe75706235ac49c507f1c5e039f4b4e1e
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 13:48:32 2017 +0100

    Fix strip so that is accepts -M as an abbreviation for --merge-notes.
    
    	PR 22260
    	* objcopy.c (strip_main): Add 'M' character to short options list
    	when calling getopt_long.

commit 5c144731ed7b9ad39c947f8411b1dde4fbdda2e6
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 13:25:44 2017 +0100

    Change readelf so that when --wide is active a relocation's full name is displayed.
    
    	PR 22262
    binutils* readelf.c (dump_relocations): Do not truncate reloc names when
    	displaying output in wide mode.
    
    ld	* testsuite/ld-powerpc/relocsort.d: Update expected output (for
    	longer reloc names).

commit ef336cb09a4193b3c86284a875c7bc4c2978bfad
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Oct 5 10:52:04 2017 +0100

    Update README-how-to-make-a-release with the correct sequence for creating the source tarball.
    
    	* README-how-to-make-a-release: Merge steps 3, 4 and 5, and insert
    	the git tag operation at the correct location.

commit 9c0f3d3f2017829ffd908c9893b85094985c3b58
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Oct 5 17:32:18 2017 +1030

    PR22239 - invalid memory read in display_debug_frames
    
    Pointer comparisons have traps for the unwary.  After adding a large
    unknown value to "start", the test "start < end" depends on where
    "start" is originally in memory.
    
    	PR 22239
    	* dwarf.c (read_cie): Don't compare "start" and "end" pointers
    	after adding a possibly wild length to "start", compare the length
    	to the difference of the pointers instead.  Remove now redundant
    	"negative" length test.

commit c91933e9e33654c7b8973cb449b93f5152afcbcb
Author: Tristan Gingold <tgingold@free.fr>
Date:   Thu Oct 5 06:34:06 2017 +0200

    Update my email address.
    
    Also refer to global maintainers for branch release approval.

commit 2ca7de3746be7484aa5affceafa1ad2e1d789381
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 14:20:51 2017 +0100

    bfd_set_input_error
    
    A downside to the 2017-10-04 PR22245 fix is that bfd_set_error can now
    silently accept invalid errors if/when someone passes the a value of
    the wrong enumeration type, which previously would be caught by the
    -Wenum-conversion warning.
    
    	PR 22245
    	* bfd.c (bfd_set_error): Revert 2017-10-04 change.  Remove
    	ellipsis parameter.  Split out bfd_error_on_input code to..
    	(bfd_set_input_error): .. New function.
    	* archive.c (_bfd_write_archive_contents): Use bfd_set_input_error.
    	* vms-lib.c (_bfd_vms_lib_write_archive_contents): Likewise.
    	* bfd-in2.h: Regenerate.

commit 7d36e2799141d206651410c68080f40b88809a3b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Oct 4 18:01:47 2017 -0700

    Add an assembler test for PR gas/21167
    
    	PR gas/21167
    	* testsuite/gas/elf/elf.exp: Run group3.
    	* testsuite/gas/elf/group3.d: New file.
    	* testsuite/gas/elf/group3.s: Likewise.

commit 8c6716e57eb991ba6ceb07011045d626652aaf01
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Oct 5 11:06:44 2017 +1030

    bfd_error_on_input is for archives
    
    	* elflink.c (elf_link_input_bfd): Correct ctor/dtor in init_array/
    	fini_array error value.

commit e6fef60069f64ee19600e96dbb1f56f80b388bc8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Oct 5 00:00:13 2017 +0000

    Automatic date update in version.in

commit db4677b8bd90b49f826807352c6c3c7eb0d57814
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 4 09:53:53 2017 +1030

    PR21167, relocation sections not included in groups
    
    This fixes a wart I've known about for years, but haven't done
    anything about because BFD treats relocation sections as an adjunct to
    the section they relocate.  SHF_GROUP on the section thus implicitly
    applies to its relocation section(s), but it is an error that the
    reloc sections aren't part of the group.
    
    Like many patches to gas, this wasn't as straightforward as it could
    be due to a number of backends, i386, cr16 and others, removing relocs
    in tc_get_reloc rather than marking them as "done" earlier in
    md_apply_reloc.  So it isn't possible for the group support to
    reliably detect the presence of relocs by looking at fixups earlier
    than write_relocs.  However the group support needs to create
    signature symbols, and that must be done before the symbol table is
    frozen, before write_relocs.  So split off the group sizing from
    elf_adjust_symtab and put it in elf_frob_file_after_relocs.
    
    bfd/
    	PR 21167
    	* elf.c (_bfd_elf_setup_sections): Don't trim reloc sections from
    	groups.
    	(_bfd_elf_init_reloc_shdr): Pass sec_hdr, use it to copy SHF_GROUP
    	flag from section.
    	(elf_fake_sections): Adjust calls.  Exit immediately on failure.
    	(bfd_elf_set_group_contents): Add associated reloc section indices
    	to group contents
    gas/
    	PR 21167
    	* config/obj-elf.c (struct group_list): Delete elt_count.
    	(groups): New static.
    	(build_group_lists): Don't count elements.
    	(elf_adjust_symtab): Use groups rather than auto list.  Set up
    	pointer from group member to SHT_GROUP section.  Don't size
    	SHT_GROUP section or clean up here..
    	(elf_frob_file_after_relocs): ..do so here instead.
    	* testsuite/gas/arc/jli-1.d,
    	* testsuite/gas/elf/groupautob.d,
    	* testsuite/gas/mips/compact-eh-eb-2.d,
    	* testsuite/gas/mips/compact-eh-eb-5.d,
    	* testsuite/gas/mips/compact-eh-el-2.d,
    	* testsuite/gas/mips/compact-eh-el-5.d: Adjust.
    ld/
    	PR 21167
    	* testsuite/ld-elf/group9b.d: Adjust for relocs included in group.

commit 5cd63fda035d4ba949e6478406162c4673b3c9ef
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 18:21:10 2017 +0100

    Fix "Remote 'g' packet reply is too long" problems with multiple inferiors
    
    When debugging two inferiors (or more) against gdbserver, and the
    inferiors have different architectures, such as e.g., on x86_64
    GNU/Linux and one inferior is 64-bit while the other is 32-bit, then
    GDB can get confused with the different architectures in a couple
    spots.
    
    In both cases I ran into, GDB incorrectly ended up using the
    architecture of whatever happens to be the selected inferior instead
    of the architecture of some other given inferior:
    
    #1 - When parsing the expedited registers in stop replies.
    
    #2 - In the default implementation of the target_thread_architecture
         target method.
    
    These resulted in instances of the infamous "Remote 'g' packet reply
    is too long" error.  For example, with the test added in this commit,
    we get:
    
    ~~~
      Continuing.
      Remote 'g' packet reply is too long (expected 440 bytes, got 816 bytes): ad064000000000000[snip]
      (gdb) FAIL: gdb.multi/multi-arch.exp: inf1 event with inf2 selected: continue to hello_loop
    
      c
      Continuing.
      Truncated register 50 in remote 'g' packet
      (gdb) PASS: gdb.multi/multi-arch.exp: inf2 event with inf1 selected: c
    ~~~
    
    This commit fixes that.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* remote.c (get_remote_arch_state): New 'gdbarch' parameter.  Use
    	it instead of target_gdbarch.
    	(get_remote_state, get_remote_packet_size): Adjust
    	get_remote_arch_state calls, passing down target_gdbarch
    	explicitly.
    	(packet_reg_from_regnum, packet_reg_from_pnum): New parameter
    	'gdbarch' and use it instead of target_gdbarch.
    	(get_memory_packet_size): Adjust get_remote_arch_state calls,
    	passing down target_gdbarch explicitly.
    	(struct stop_reply) <arch>: New field.
    	(remote_parse_stop_reply): Use the stopped thread's architecture,
    	not the current inferior's.  Save the architecture in the
    	stop_reply.
    	(process_stop_reply): Use the stop reply's architecture.
    	(process_g_packet, remote_fetch_registers)
    	(remote_prepare_to_store, store_registers_using_G)
    	(remote_store_registers): Adjust get_remote_arch_state calls,
    	using the regcache's architecture.
    	(remote_get_trace_status): Adjust get_remote_arch_state calls,
    	passing down target_gdbarch explicitly.
    	* spu-multiarch.c (spu_thread_architecture): Defer to the target
    	beneath instead of calling target_gdbarch.
    	* target.c (default_thread_architecture): Use the specified
    	inferior's architecture, instead of the current inferior's
    	architecture (via target_gdbarch).
    
    gdb/testsuite/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.multi/hangout.c: Include <unistd.h>.
    	(hangout_loop): New function.
    	(main): Call alarm.  Call hangout_loop in a loop.
    	* gdb.multi/hello.c: Include <unistd.h>.
    	(hello_loop): New function.
    	(main): Call alarm.  Call hangout_loop in a loop.
    	* gdb.multi/multi-arch.exp: Test running to a breakpoint one
    	inferior with the other selected.

commit ed4227b7c6d62767c9c323dd95d8ead75be51a6c
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 18:21:10 2017 +0100

    Reimplement support for "maint print registers" with no running inferior yet
    
    A following patch will change the default target_thread_architecture
    method, like this:
    
       struct gdbarch *
       default_thread_architecture (struct target_ops *ops, ptid_t ptid)
       {
      -  return target_gdbarch ();
      +  inferior *inf = find_inferior_ptid (ptid);
      +  gdb_assert (inf != NULL);
      +  return inf->gdbarch;
       }
    
    This is because target_gdbarch is really just
    current_inferior()->gdbarch, and it's wrong to return that
    architecture when the inferior of the passed in PTID is NOT the
    current inferior -- the inferior for PTID may be running a different
    architecture.  E.g., a mix of 64-bit and 32-bit inferiors in the same
    debug session.
    
    Doing that change above however exposes a problem in "maint print
    registers", caught be the testsuite:
    
     -PASS: gdb.base/maint.exp: maint print registers
     +FAIL: gdb.base/maint.exp: maint print registers (GDB internal error)
    ...
      gdb/inferior.c:309: internal-error: inferior* find_inferior_pid(int): Assertion `pid != 0' failed.
      A problem internal to GDB has been detected,
    
    The call stack looks like this:
    
      #0  0x000000000068b707 in internal_error(char const*, int, char const*, ...) (file=0xa9b958 "gdb/inferior.c", line=309, fmt=0xa9b8e0 "%s: Assertion `%s' failed.") at gdb/common/errors.c:54
      #1  0x00000000006e1c40 in find_inferior_pid(int) (pid=0) at gdb/inferior.c:309
      #2  0x00000000006e1c8d in find_inferior_ptid(ptid_t) (ptid=...) at gdb/inferior.c:323
      #3  0x00000000007c18dc in default_thread_architecture(target_ops*, ptid_t) (ops=0xf86d60 <dummy_target>, ptid=...)
          at gdb/target.c:3134
      #4  0x00000000007b5414 in delegate_thread_architecture(target_ops*, ptid_t) (self=0xf86d60 <dummy_target>, arg1=...)
          at gdb/target-delegates.c:2527
      #5  0x00000000007647b3 in get_thread_regcache(ptid_t) (ptid=...) at gdb/regcache.c:466
      #6  0x00000000007647ff in get_current_regcache() () at gdb/regcache.c:475
      #7  0x0000000000767495 in regcache_print(char const*, regcache_dump_what) (args=0x0, what_to_dump=regcache_dump_none)
          at gdb/regcache.c:1599
      #8  0x0000000000767550 in maintenance_print_registers(char const*, int) (args=0x0, from_tty=1)
          at gdb/regcache.c:1613
    
    I.e., the test does "maint print registers" while the inferior is not
    running yet.  This is expected to work, and there's already a hack in
    get_thread_arch_regcache to make it work.
    
    Instead of pilling on hacks in the internal of regcache and
    target_ops, this commit moves the null_ptid special casing to where it
    belongs -- higher up in the call chain in the implementation of "maint
    print registers" & co directly.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* regcache.c (get_thread_arch_regcache): Remove null_ptid special
    	case.
    	(regcache_print): Handle !target_has_registers here instead.

commit 55b11ddf16b97b9c50ed480bc9da8b3e1c6c4198
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 18:21:09 2017 +0100

    Redesign mock environment for gdbarch selftests
    
    A following patch will remove this hack from within regcache's
    implementation:
    
      struct regcache *
      get_thread_arch_regcache (ptid_t ptid, struct gdbarch *gdbarch)
      {
        struct address_space *aspace;
    
        /* For the benefit of "maint print registers" & co when debugging an
           executable, allow dumping the regcache even when there is no
           thread selected (target_thread_address_space internal-errors if
           no address space is found).  Note that normal user commands will
           fail higher up on the call stack due to no
           target_has_registers.  */
        aspace = (ptid_equal (null_ptid, ptid)
    	      ? NULL
    	      : target_thread_address_space (ptid));
    
    i.e., it'll no longer be possible to try to build a regcache for
    null_ptid.  That change alone would regress the gdbarch self tests
    though, causing this:
    
      (gdb) maintenance selftest
      [...]
      Running selftest register_to_value.
      src/gdb/inferior.c:309: internal-error: inferior* find_inferior_pid(int): Assertion `pid != 0' failed.
      A problem internal to GDB has been detected,
      further debugging may prove unreliable.
      Quit this debugging session? (y or n) FAIL: gdb.gdb/unittest.exp: maintenance selftest (GDB internal error)
    
    The problem is that the way the mocking environment for those unit
    tests is written is a bit fragile: it creates a special purpose
    regcache (and sentinel's frame), using whatever is the current
    inferior_ptid (usually null_ptid), and assumes get_current_regcache
    will find that in the regcache::current_regcache list.
    
    This commit changes the way the mock environment is created.  It
    eliminates the special regcache and frame and instead creates a fuller
    mock environment, with a custom mock target_ops, and then a mock
    inferior and thread "running" on that target.
    
    If there's already a running target when you type "maint selftest",
    then we error out, instead of pushing a new target on top of the
    existing one (and thus killing the debug session).  This results in:
    
      (gdb) maint selftest
      (...)
      Self test failed: arch i386: target already pushed
      Self test failed: arch i386:x86-64: target already pushed
      Self test failed: arch i386:x64-32: target already pushed
      Self test failed: arch i8086: target already pushed
      Self test failed: arch i386:intel: target already pushed
      Self test failed: arch i386:x86-64:intel: target already pushed
      Self test failed: arch i386:x64-32:intel: target already pushed
      Self test failed: arch i386:nacl: target already pushed
      Self test failed: arch i386:x86-64:nacl: target already pushed
      Self test failed: arch i386:x64-32:nacl: target already pushed
      Self test failed: self-test failed at /home/pedro/gdb/mygit/src/gdb/selftest-arch.c:86
      (...)
      Ran 19 unit tests, 1 failed
    
    I think that's OK, because self tests are really meant to be run from
    a clean state right after GDB is started.  I'm adding that erroring
    out just as safe measure just in case someone types "maint selftest"
    on the command line while already debugging something (as I've done
    it).
    
    (In my multi-target branch, where this patch originated from, we don't
    actually need to error out, because there each inferior has its own
    target stack).
    
    Also, note that the current code was doing:
    
     current_inferior()->gdbarch = gdbarch;
    
    without taking care to restore the previous gdbarch.  This means that
    GDB's state was being left inconsistent after running the self tests,
    further supporting the point that there's probably not much
    expectation that mixing "maint selftests" and regular debugging in the
    same GDB invocation really works.  This patch fixes that, regardless.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* frame.c (create_test_frame): Delete.
    	* frame.h (create_test_frame): Delete.
    	* gdbarch-selftests.c: Include gdbthread.h and target.h.
    	(class regcache_test): Delete.
    	(test_target_has_registers, test_target_has_stack)
    	(test_target_has_memory, test_target_prepare_to_store)
    	(test_target_store_registers): New functions.
    	(test_target_ops): New class.
    	(register_to_value_test): Error out if there's already a
    	process_stratum (or higher) target pushed.  Create a fuller mock
    	environment, with mock target_ops, inferior, address space, thread
    	and inferior_ptid.
    	* progspace.c (struct address_space): Move to ...
    	* progspace.h (struct address_space): ... here.
    	* regcache.h (regcache::~regcache, regcache::raw_write)
    	[GDB_SELF_TEST]: No longer virtual.

commit 4c71c1059f876fcca9809f7b6372b721ddb83635
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Oct 4 12:44:01 2017 -0400

    Fix -list-thread-groups --available logic and add test
    
    New in v3:
    
    - Replace use_gdb_stub with can_spawn_for_attach.
    - Call kill_wait_spawned_process on spawn_ids.
    
    Commit
    
      Use std::set in mi-main.c
      52f9abe4c739f42cc5f80b2629276493ac6306f9
    
    changed the logic of the "-list-thread-groups --available" by mistake
    when a pid is passed.  It prints all the processes except the one
    specified by the given pid.  The correct behavior is to only print the
    process corresponding to that pid.  this patch fixes that and adds a test.
    
    gdb/ChangeLog:
    
    	* mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.mi/list-thread-groups-available.exp: New file.
    	* gdb.mi/list-thread-groups-available.c: New file.

commit 73dcd72d4eeec176f769660ddcdefd1f25d0a2ec
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 11:07:28 2017 +0100

    Move code out of 'between TRY and CATCH'
    
    I tried building GDB with TRY/CATCH mapped to raw C++ try/catch (by
    defining GDB_XCPT to GDB_XCPT_RAW_TRY in
    gdb/common/common-exceptions.h), and that caught a case of code
    written between try and catch.  This commit fixes it.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
    	out of 'between TRY and CATCH'.

commit 44704526e482d24baa104764495ca376561a85bf
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 13:00:13 2017 +0100

    Add missing-END_CATCH detection/protection (to gdb's TRY/CATCH/END_CATCH)
    
    (Adding missing ChangeLog entry)
    
    While we still have cleanups (i.e., make_cleanup & co), we must be
    sure to add END_CATCH at the end of a TRY/CATCH/END_CATCH construct.
    However, it's currently too easy to miss adding the END_CATCH, because
    the code compiles anyway without it.  I realized this when I noticed
    that another patch I was working on missed several adding END_CATCH in
    several new TRY/CATCH uses.
    
    This commit fixes that by making TRY open a new scope that is only
    closed by END_CATCH.  This way, if you forget to add the END_CATCH,
    then compilation fails due to the unbalanced curly braces.
    
    This caught a couple places where we were missing END_CATCH in current
    master, also fixed by the patch.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (complete_command): Add missing END_CATCH.
    	* common/common-exceptions.h (TRY): Open an outermost scope.
    	Expand intro comment.
    	(CATCH): Reindent.
    	(END_CATCH): Close the outermost scope.
    	* completer.c (complete_line_internal): Add missing END_CATCH.

commit a87c142792e4dcbec2bb3825e71f3ace044c2096
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Oct 4 09:55:29 2017 +0100

    Add missing-END_CATCH detection/protection (to gdb's TRY/CATCH/END_CATCH)
    
    While we still have cleanups (i.e., make_cleanup & co), we must be
    sure to add END_CATCH at the end of a TRY/CATCH/END_CATCH construct.
    However, it's currently too easy to miss adding the END_CATCH, because
    the code compiles anyway without it.  I realized this when I noticed
    that another patch I was working on missed several adding END_CATCH in
    several new TRY/CATCH uses.
    
    This commit fixes that by making TRY open a new scope that is only
    closed by END_CATCH.  This way, if you forget to add the END_CATCH,
    then compilation fails due to the unbalanced curly braces.
    
    This caught a couple places where we were missing END_CATCH in current
    master, also fixed by the patch.
    
    gdb/ChangeLog:
    2017-10-04  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (complete_command): Add missing END_CATCH.
    	* common/common-exceptions.h (TRY): Open an outermost scope.
    	Expand intro comment.
    	(CATCH): Reindent.
    	(END_CATCH): Close the outermost scope.
    	* completer.c (complete_line_internal): Add missing END_CATCH.

commit bc3b087de2401c65c02730d346e8bea4dc0504ae
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Wed Sep 20 19:15:40 2017 -0400

    Extend "set cwd" to work on gdbserver
    
    This is the "natural" extension necessary for the "set cwd" command
    (and the whole "set the inferior's cwd" logic) to work on gdbserver.
    
    The idea here is to have a new remote packet, QSetWorkingDir (name
    adopted from LLDB's extension to the RSP, as can be seen at
    <https://raw.githubusercontent.com/llvm-mirror/lldb/master/docs/lldb-gdb-remote.txt>),
    which sends an hex-encoded string representing the working directory
    that the remote inferior will use.  There is a slight difference from
    the packet proposed by LLDB: GDB's version will accept empty
    arguments, meaning that the user wants to clear the previously set
    working directory for the inferior (i.e., "set cwd" without arguments
    on GDB).
    
    For UNIX-like targets this feature is already implemented on
    nat/fork-inferior.c, and all gdbserver has to do is to basically
    implement "set_inferior_cwd" and call it whenever such packet arrives.
    For other targets, like Windows, it is possible to use the existing
    "get_inferior_cwd" function and do the necessary steps to make sure
    that the inferior will use the specified working directory.
    
    Aside from that, the patch consists basically of updates to the
    testcase (making it available on remote targets) and the
    documentation.
    
    No regressions found.
    
    gdb/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* NEWS (Changes since GDB 8.0): Add entry about new
    	'set-cwd-on-gdbserver' feature.
    	(New remote packets): Add entry for QSetWorkingDir.
    	* common/common-inferior.h (set_inferior_cwd): New prototype.
    	* infcmd.c (set_inferior_cwd): Remove "static".
    	(show_cwd_command): Expand text to include remote debugging.
    	* remote.c: Add PACKET_QSetWorkingDir.
    	(remote_protocol_features) <QSetWorkingDir>: New entry for
    	PACKET_QSetWorkingDir.
    	(extended_remote_set_inferior_cwd): New function.
    	(extended_remote_create_inferior): Call
    	"extended_remote_set_inferior_cwd".
    	(_initialize_remote): Call "add_packet_config_cmd" for
    	QSetWorkingDir.
    
    gdb/gdbserver/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* inferiors.c (set_inferior_cwd): New function.
    	* server.c (handle_general_set): Handle QSetWorkingDir packet.
    	(handle_query): Inform that QSetWorkingDir is supported.
    	* win32-low.c (create_process): Pass the inferior's cwd to
    	CreateProcess.
    
    gdb/testsuite/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.base/set-cwd.exp: Make it available on
    	native-extended-gdbserver.
    
    gdb/doc/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.texinfo (Starting your Program) <The working directory.>:
    	Mention remote debugging.
    	(Working Directory) <Your Program's Working Directory>:
    	Likewise.
    	(Connecting) <Remote Packet>: Add "set-working-dir"
    	and "QSetWorkingDir" to the table.
    	(Remote Protocol) <QSetWorkingDir>: New item, explaining the
    	packet.

commit d092c5a2465ece3435131ae6fef1ccb6e70986cb
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Sep 11 01:13:50 2017 -0400

    Implement "set cwd" command on GDB
    
    This commit adds new "set/show cwd" commands, which are used to
    set/show the current working directory of the inferior that will be
    started.
    
    The idea here is that "set cwd" will become the de facto way of
    setting the inferior's cwd.  Currently, the user can use "cd" for
    that, but there are side effects: with "cd", GDB also switches to
    another directory, and that can impact the loading of scripts and
    other files.  With "set cwd", we separate the logic into a new
    command.
    
    To maintain backward compatibility, if the user issues a "cd" command
    but doesn't use "set cwd", then the inferior's cwd will still be
    changed according to what the user specified.  However, "set cwd" has
    precedence over "cd", so it can always be used to override it.
    
    "set cwd" works in the following way:
    
    - If the user sets the inferior's cwd by using "set cwd", then this
      directory is saved into current_inferior ()->cwd and is used when
      the inferior is started (see below).
    
    - If the user doesn't set the inferior's cwd by using "set cwd", but
      rather use the "cd" command as before, then this directory is
      inherited by the inferior because GDB will have chdir'd into it.
    
    On Unix-like hosts, the way the directory is changed before the
    inferior execution is by expanding the user set directory before the
    fork, and then "chdir" after the call to fork/vfork on
    "fork_inferior", but before the actual execution.  On Windows, the
    inferior cwd set by the user is passed directly to the CreateProcess
    call, which takes care of the actual chdir for us.
    
    This way, we'll make sure that GDB's cwd is not affected by the user
    set cwd.
    
    gdb/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* NEWS (New commands): Mention "set/show cwd".
    	* cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
    	"cd" command's help text.
    	* common/common-inferior.h (get_inferior_cwd): New prototype.
    	* infcmd.c (inferior_cwd_scratch): New global variable.
    	(set_inferior_cwd): New function.
    	(get_inferior_cwd): Likewise.
    	(set_cwd_command): Likewise.
    	(show_cwd_command): Likewise.
    	(_initialize_infcmd): Add "set/show cwd" commands.
    	* inferior.h (class inferior) <cwd>: New field.
    	* nat/fork-inferior.c: Include "gdb_tilde_expand.h".
    	(fork_inferior): Change inferior's cwd before its execution.
    	* windows-nat.c (windows_create_inferior): Pass inferior's cwd
    	to CreateProcess.
    
    gdb/gdbserver/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* inferiors.c (current_inferior_cwd): New global variable.
    	(get_inferior_cwd): New function.
    	* inferiors.h (struct process_info) <cwd>: New field.
    
    gdb/doc/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.texinfo (Starting your Program) <The working directory.>:
    	Mention new "set cwd" command.
    	(Working Directory) <Your Program's Working Directory>:
    	Rephrase to explain that "set cwd" exists and is the default
    	way to change the inferior's cwd.
    
    gdb/testsuite/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.base/set-cwd.c: New file.
    	* gdb.base/set-cwd.exp: Likewise.

commit 7da0a8867419fc4a2a64d49cc71a14bd145cebff
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Sep 11 01:03:51 2017 -0400

    Introduce gdb_tilde_expand
    
    Currently, whenever we want to handle paths provided by the user and
    perform tilde expansion on GDB, we rely on "tilde_expand", which comes
    from readline.  This was enough for our use cases so far, but the
    situation will change when we start dealing with paths on gdbserver as
    well, which is what the next patches implement.
    
    Unfortunately it is not possible to use "tilde_expand" in this case
    because gdbserver doesn't use readline.  For that reason I decided to
    implement a new "gdb_tilde_expand" function, which is basically a
    wrapper for "glob" and its GNU extension, GLOB_TILDE_CHECK.  With the
    import of the "glob" module from gnulib, we're sure that "glob" always
    supports this extension.
    
    gdb/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* Makefile.in (SFILES): Add gdb_tilde_expand.c.
    	(HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
    	(COMMON_OBS): Add gdb_tilde_expand.o.
    	* common/gdb_tilde_expand.c: New file.
    	* common/gdb_tilde_expand.h: Likewise.
    
    gdb/gdbserver/ChangeLog:
    2017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
    	(OBS): Add gdb_tilde_expand.o.

commit a5259595e7a6faac0240d257f7e9cfa599557d2e
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Oct 4 09:54:52 2017 +1030

    PowerPC64 ELFv2 symbols not needed in get_synthetic_symtab
    
    	* elf64-ppc.c (ppc64_elf_get_synthetic_symtab): Don't sort or
    	classify symbols for ELFv2.

commit 9ba5f27cdd15d22d6c5739ff5d2b1c81d796e114
Author: Pavel I. Kryukov <kryukov@frtk.ru>
Date:   Tue Oct 3 22:42:07 2017 +0300

    PR22245, Fix potential UB in bfd_set_error
    
    Passing enum as a first argument to variadic argument function
    may lead to undefined behavior. The explanation on CERT site:
    https://www.securecoding.cert.org/confluence/display/cplusplus/
    EXP58-CPP.+Pass+an+object+of+the+correct+type+to+va_start
    
    The bug was found by Kirill Nedostoev (nedostoev.ka@phystech.edu)
    when he tried to build GNU binutils with Clang 7.
    
    	PR 22245
    	* bfd.c (bfd_set_error): Avoid UB on passing arg to va_start that
    	undergoes default promotion.
    	* bfd-in2.h: Regenerate.

commit ca2a727a5b9389190ce86c52b0303ad8c3e2bcc6
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Oct 4 00:00:20 2017 +0000

    Automatic date update in version.in

commit db8dd1601ee4d0629957bcc8b4156d65f42a218d
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Oct 3 23:46:28 2017 +0100

    gdbarch: Remove duplicate `struct objfile' declaration
    
    Remove a duplicate `struct objfile' declaration mistakenly added with
    commit 3e29f34a4eef ("MIPS: Keep the ISA bit in compressed code
    addresses").
    
    	gdb/
    	* gdbarch.sh (objfile): Remove duplicate declaration.
    	* gdbarch.h: Regenerate.

commit c0107b0f57bc958b640dabafd4c6c618ea023397
Author: Jim Wilson <jim.wilson@linaro.org>
Date:   Tue Oct 3 14:23:56 2017 -0700

    Update my email address.
    
    	sim/
    	* MAINTAINERS (aarch64): Update my email address.

commit f8bfbf22251f6c2772a9a1059c3180c638ad2830
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Oct 3 08:26:16 2017 -0600

    Fix incorrect string_printf use in utils.c
    
    I made a mistake earlier and used string_printf where I should have used
    string_vprintf.
    
    I'm checking this in as obvious.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (internal_vproblem): Use string_vprintf.

commit 5178ed487f813639e660fba23215fa7ba69a769e
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:49:36 2017 -0600

    Use std::string in info_symbol_command
    
    This removes a cleanup by using std::string in info_symbol_command.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* printcmd.c (info_symbol_command): Use std::string.

commit 8cff8730f43548d17530c9d31aac1d381351addc
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:49:00 2017 -0600

    Use std::string in gdb_safe_append_history
    
    This removes a cleanup by using std::string in
    gdb_safe_append_history.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* top.c (gdb_safe_append_history): Use std::string.

commit 895b8f306b1f54d85915ca0d24368f40b2e42554
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:35:58 2017 -0600

    Remove make_delete_ui_cleanup
    
    This removes new_ui and delete_ui in favor of ordinary 'new' and
    'delete', and then removes make_delete_ui_cleanup in favor of
    std::unique_ptr.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* event-top.c (stdin_event_handler): Update.
    	* main.c (captured_main_1): Update.
    	* top.h (make_delete_ui_cleanup): Remove.
    	(struct ui): Add constructor and destructor.
    	(new_ui, delete_ui): Remove.
    	* top.c (make_delete_ui_cleanup): Remove.
    	(new_ui_command): Use std::unique_ptr.
    	(delete_ui_cleanup): Remove.
    	(ui::ui): Rename from new_ui.  Update.
    	(free_ui): Remove.
    	(ui::~ui): Rename from delete_ui.  Update.

commit 0efef6405493c0bf438486819bec70b304276e16
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:32:00 2017 -0600

    Use gdb::byte_vector in load_progress
    
    This changes load_progress to use gdb::byte_vector, removing a
    cleanup.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (load_progress): Use gdb::byte_vector.

commit 245ad7d373aef22013b347504d30d2306da1bdbf
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:22:49 2017 -0600

    Remove unused declarations
    
    This removes some unused cleanup declarations.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
    	declaration.
    	* printcmd.c (x_command): Remove unused declaration.
    	* symfile.c (symbol_file_command): Remove unused declaration.

commit e05550d7a409a0637d87bef377e5d4b9a4b379ac
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:11:33 2017 -0600

    Use std::string in utils.c
    
    This converts internal_vproblem and defaulted_query to use
    std::string.
    
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (internal_vproblem): Use std::string.
    	(defaulted_query): Likewise.

commit b95de2b7aeb30081345954cb15970a582b49a866
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 22:07:37 2017 -0600

    Remove set_batch_flag_and_make_cleanup_restore_page_info
    
    This removes set_batch_flag_and_make_cleanup_restore_page_info and
    make_cleanup_restore_page_info in favor of a new RAII class.  This
    then allows for the removal of make_cleanup_restore_uinteger and
    make_cleanup_restore_integer
    
    ChangeLog
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
    	* top.c (execute_command_to_string): Update.
    	* utils.c (make_cleanup_restore_page_info): Remove.
    	(do_restore_page_info_cleanup): Remove.
    	(set_batch_flag_and_restore_page_info):
    	New.
    	(make_cleanup_restore_page_info): Remove.
    	(set_batch_flag_and_make_cleanup_restore_page_info): Remove.
    	(~set_batch_flag_and_restore_page_info): New
    	(make_cleanup_restore_uinteger): Remove.
    	(make_cleanup_restore_integer): Remove.
    	(struct restore_integer_closure): Remove.
    	(restore_integer): Remove.
    	* utils.h (struct set_batch_flag_and_restore_page_info): New
    	class.
    	(set_batch_flag_and_make_cleanup_restore_page_info): Remove.
    	(make_cleanup_restore_page_info): Remove.
    	(make_cleanup_restore_uinteger) Remove.
    	(make_cleanup_restore_integer) Remove.

commit 070365117b5727394e271399c5738a27bf9716d5
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 29 21:49:04 2017 -0600

    Change record_full_gdb_operation_disable_set not to return a cleanup
    
    This changes record_full_gdb_operation_disable_set to return a
    scoped_restore rather than a cleanup, and fixes all the users.
    
    ChangeLog
    2017-10-03  Tom Tromey  <tom@tromey.com>
    
    	* record-full.h (record_full_gdb_operation_disable_set): Return
    	scoped_restore_tmpl<int>.
    	* infrun.c (adjust_pc_after_break): Update.
    	(handle_signal_stop): Update.
    	* record-full.c (record_full_gdb_operation_disable_set): Return
    	scoped_restore_tmpl<int>.
    	(record_full_wait_1, record_full_insert_breakpoint)
    	(record_full_remove_breakpoint, record_full_save)
    	(record_full_goto_insn): Update.

commit 9194f82dc372d5045ae06c617a49a5a9b17c1d24
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 3 15:10:28 2017 +1030

    PR21294, Binary size regression on PPC embedded
    
    	PR 21294
    	* NEWS: Note that defaulting to -z relro results in increased
    	memory and disk size.

commit 40c0777b1709480526429f90eaa354c8e0da2dc8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Oct 3 00:00:16 2017 +0000

    Automatic date update in version.in

commit def5c83c02fcc1c91d3f0da21005e0503b8ec881
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Oct 3 08:46:39 2017 +1030

    ld -z relro documentation
    
    	* ld.texinfo (-z relro): Expand description.
    	(DATA_SEGMENT_ALIGN): Note that -z relro is not effective when
    	running with system page size larger than commonpagesize.
    	(DATA_SEGMENT_RELRO_END): Be explicit about the alignment.

commit 45320ffa0450b27e232d933d2a1c6a09d94ac18b
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 2 13:55:42 2017 -0600

    Fix &str printing in Rust
    
    Printing a string slice ("&str") in Rust would print until the
    terminating \0; but that is incorrect because a slice has a length.
    This fixes &str printing, and arranges to preserve the type name when
    slicing a slice, so that printing a slice of an "&str" works as well.
    
    This is PR rust/22236.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	PR rust/22236:
    	* rust-lang.c (rust_val_print_str): New function.
    	(val_print_struct): Call it.
    	(rust_subscript): Preserve name of slice type.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	PR rust/22236:
    	* gdb.rust/simple.rs (main): New variable "fslice".
    	* gdb.rust/simple.exp: Add slice tests.  Update string tests.

commit b3e3859bc577db5b79bb3d39048fd46c0a0420ef
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 2 13:47:15 2017 -0600

    Fix ptype of Rust slices
    
    Something like "ptype &x[..]" (where "x" was a slice) would crash gdb.
    rust_subscript wasn't handling slicing in the EVAL_AVOID_SIDE_EFFECTS
    case.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	* rust-lang.c (rust_subscript): Handle slices in
    	EVAL_AVOID_SIDE_EFFECTS case.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	* gdb.rust/simple.exp: Test ptype of a slice.

commit 01af5e0d09ac9c621e7b280f44a2c7ef55784493
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Oct 2 12:15:52 2017 -0600

    Allow indexing of &str in Rust
    
    rust_slice_type_p was not recognizing &str as a slice type, so indexing
    into (or making a slice of) a slice was not working.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	* rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	* gdb.rust/simple.exp: Test index of slice.

commit 888e3ddb20f541220f18709fce832ad0163c3e71
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Jun 6 14:27:42 2017 -0600

    Add missing "extern" in rust-lang.h
    
    I noticed that one function in rust-lang.h was not declared using
    "extern".  In the interested of uniformity, this patch adds it.
    
    Tested by rebuilding.
    
    2017-10-02  Tom Tromey  <tom@tromey.com>
    
    	* rust-lang.h (rust_slice_type): Add "extern".

commit cc536b21677586455973f81ee05257ada8efdcb8
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Oct 2 10:18:30 2017 +0100

    Fix GDB build with G++ 4.8
    
    G++ 4.8 trips on:
    
      In file included from /opt/gcc-4.8/include/c++/4.8.5/algorithm:62:0,
    		   from ../../src/gdb/ada-lang.c:65:
      /opt/gcc-4.8/include/c++/4.8.5/bits/stl_algo.h: In instantiation of â??_RandomAccessIterator std::__unguarded_partition(_RandomAccessIterator, _RandomAccessIterator, const _Tp&) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<ada_exc_info*, std::vector<ada_exc_info> >; _Tp = ada_exc_info]â??:
      /opt/gcc-4.8/include/c++/4.8.5/bits/stl_algo.h:2283:70:   required from â??_RandomAccessIterator std::__unguarded_partition_pivot(_RandomAccessIterator, _RandomAccessIterator) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<ada_exc_info*, std::vector<ada_exc_info> >]â??
      /opt/gcc-4.8/include/c++/4.8.5/bits/stl_algo.h:2315:54:   required from â??void std::__introsort_loop(_RandomAccessIterator, _RandomAccessIterator, _Size) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<ada_exc_info*, std::vector<ada_exc_info> >; _Size = long int]â??
      /opt/gcc-4.8/include/c++/4.8.5/bits/stl_algo.h:5461:36:   required from â??void std::sort(_RAIter, _RAIter) [with _RAIter = __gnu_cxx::__normal_iterator<ada_exc_info*, std::vector<ada_exc_info> >]â??
      ../../src/gdb/ada-lang.c:13153:61:   required from here
      /opt/gcc-4.8/include/c++/4.8.5/bits/stl_algo.h:2245:19: error: passing â??const ada_exc_infoâ?? as â??thisâ?? argument of â??bool ada_exc_info::operator<(const ada_exc_info&)â?? discards qualifiers [-fpermissive]
          while (__pivot < *__last)
    		     ^
    
    Seems to be a libstdc++ bug meanwhile fixed by:
      https://gcc.gnu.org/ml/libstdc++/2012-04/msg00074.
    
    In any case, there's no reason these methods can't be const.
    
    gdb/ChangeLog:
    2017-10-02  Tom Tromey  <tom@tromey.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.h (ada_exc_info::operator<): Make const.
    	(ada_exc_info::operator==): Make const.
    	* ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
    	Make const.

commit 289a6840c1ed80f71d58632bb6d702d97d114387
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Oct 2 11:00:30 2017 +0200

    nto & lynx x86: call init_target_desc
    
    In gdbserver, target descriptions need to be initialized by calling
    init_target_desc.  Because i386_create_target_description is shared with
    GDB, it doesn't do that, the callers must take care of it.  These two
    platforms currently don't.
    
    I am not able to build them, so I couldn't test.
    
    gdb/gdbserver/ChangeLog:
    
    	* lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
    	* nto-x86-low.c (nto_x86_arch_setup): Likewise.

commit dcd2b8a0144f4f5f81887861542609ef858a28c9
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Oct 2 16:57:06 2017 +1030

    Fix powerpc comment typo
    
    	* elf32-ppc.c (ppc_elf_relocate_section): Fix comment typo.
    	* elf64-ppc.c (ppc64_elf_relocate_section): Likewise.

commit 7a0c60fea0f237b9de95e47a0f75200ac9ebaa28
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Oct 2 00:00:13 2017 +0000

    Automatic date update in version.in

commit bfec0f11eadd7ed3597bc9b550a5595421a4cb31
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Oct 1 21:40:23 2017 +1030

    PR22232, NULL pointer dereference in load_specific_debug_section
    
    	PR 22232
    	PR 22230
    	* objdump.c (load_specific_debug_section): Introduce a temp to
    	stop bfd_get_full_section_contents NULLing out section->start.

commit 8cb1232a8cc0d1a6db2de51398acfe978a5c7e68
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Oct 1 19:02:35 2017 +1030

    PR21970, assertion failed when more than one overlay has subalign specified
    
    	PR 21970
    	* ldlang.c (lang_leave_overlay): Reset overlay_subalign.

commit 20230942fe3674150ab661738d72f1618b3d4b1b
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Oct 1 17:39:00 2017 +1030

    PR21957, addr2line incorrectly handles non-increasing sequences in line table
    
    	PR 21957
    	* dwarf2.c (new_line_sorts_after): Remove end_sequence comparison.
    	(add_line_info): Always put end_sequence last.

commit d2e6c9a3682f0ac811ac1676d221c55162938b61
Author: Alexander Fedotov <alfedotov@gmail.com>
Date:   Sat Sep 30 12:31:37 2017 +0300

    Add new mnemonics for VLE multiple load instructions
    
    opcodes/
    	* ppc-opc.c (vle_opcodes): Add e_lmvsprw, e_lmvgprw,
    	e_lmvsrrw, e_lmvcsrrw and e_lmvcsrrw as official mnemonics for
    	VLE multimple load/store instructions. Old e_ldm* variants are
    	kept as aliases.
    	Add missing e_lmvmcsrrw and e_stmvmcsrrw.
    gas/
    	* testsuite/gas/ppc/vle-mult-ld-st-insns.s: New file: Tests the
    	support for the VLE multiple load/store instructions.
    	* testsuite/gas/ppc/vle-mult-ld-st-insns.d: New file: Test
    	driver.
    	* testsuite/gas/ppc/ppc.exp: Run it.

commit 4b04bba2eb6b646e11a2c38c77667875b3db6828
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Oct 1 12:07:59 2017 +1030

    PR22047, Heap out of bounds read in parse_comp_unit
    
    Like the PR22230 fix, we can allocate a buffer with an extra byte
    rather than letting bfd_simple_get_relocated_section_contents malloc
    and return a buffer.  Much better than allocating another buffer
    afterwards.
    
    	PR 22047
    	* dwarf2.c (read_section): Allocate buffer with extra byte for
    	bfd_simple_get_relocated_section_contents rather than copying
    	afterwards.

commit 4f1881b94473f1034f950feb863b464435a8fb5f
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Oct 1 12:07:07 2017 +1030

    PR22230, buffer overflow in display_debug_macro
    
    	PR 22230
    	* objdump.c (load_specific_debug_section): Allocate an extra byte
    	for a terminating NUL.

commit 3678b25d0c5fee04a91ad90ed2965513ba0ca11f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Oct 1 00:00:25 2017 +0000

    Automatic date update in version.in

commit 2715765b0fd357b4b58166850a23f509aacde161
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 30 03:04:52 2017 -0700

    Add a test for PR binutils/21978
    
    	PR binutils/21978
    	* testsuite/ld-elf/pr21978.od: New file.
    	* testsuite/ld-elf/pr21978a.c: Likewise.
    	* testsuite/ld-elf/pr21978b.c: Likewise.
    	* testsuite/ld-elf/shared.exp: Run PR binutils/21978 test.

commit 386c8614d5e65431e977b1b20cc4642f944faca1
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 11:21:58 2017 -0600

    Remove free_memory_read_result_vector
    
    This changes read_memory_robust to return a std::vector, allowing the
    removal of free_memory_read_result_vector and associated cleanups.
    This patch also changes the functions it touches to be a bit more
    robust with regards to deallocation; it's perhaps possible that
    read_memory_robust could have leaked in some situations.
    
    This patch is based on my earlier series to remove some MI cleanups.
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* target.c (read_whatever_is_readable): Change type of "result".
    	Update.
    	(free_memory_read_result_vector): Remove.
    	(read_memory_robust): Change return type.  Update.
    	* mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update.  Use
    	bin2hex, std::string.
    	* target.h (memory_read_result_s): Remove typedef.
    	(free_memory_read_result_vector): Remove.
    	(read_memory_robust): Return std::vector.

commit 789c4b5ea14b0c441e6021f07503e61ccfacb427
Author: Tom Tromey <tom@tromey.com>
Date:   Thu May 4 21:25:55 2017 -0600

    Change captured_mi_execute_command to use scoped_restore
    
    Change captured_mi_execute_command to use a scoped_restore, removing a
    cleanup.  The old code copied the current token, but I don't believe
    that is necessary.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (captured_mi_execute_command): Use scope_restore.

commit ab816a274505933da2f854014b54901c3c3db9d2
Author: Tom Tromey <tom@tromey.com>
Date:   Thu May 4 16:35:09 2017 -0600

    Use a std::vector for ada_exceptions_list
    
    Change ada_exceptions_list to return a std::vector and fix up the
    users.  This allows removing a cleanup in MI.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
    	* ada-lang.h (struct ada_exc_info): Remove typedef.  Declare
    	operator< and operator==.
    	(ada_exceptions_list): Return a std::vector.
    	* ada-lang.c (ada_exc_info::operator<): Rename from
    	compare_ada_exception_info.
    	(ada_exc_info::operator==): New.
    	(sort_remove_dups_ada_exceptions_list): Change type of
    	"exceptions".
    	(ada_add_standard_exceptions, ada_add_exceptions_from_frame)
    	(ada_add_global_exceptions): Likewise.
    	(ada_exceptions_list_1): Return a std::vector.
    	(ada_exceptions_list): Likewise.

commit 52f9abe4c739f42cc5f80b2629276493ac6306f9
Author: Tom Tromey <tom@tromey.com>
Date:   Thu May 4 16:07:04 2017 -0600

    Use std::set in mi-main.c
    
    Change a couple of spots in mi-main.c to use std::set.  This
    simplifies the code and removes some cleanups.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
    	'std::set *'.
    	(print_one_inferior): Update.
    	(free_vector_of_ints): Remove.
    	(list_available_thread_groups): Change "ids" to std::set.
    	(mi_cmd_list_thread_groups): Update.
    	(struct collect_cores_data) <core>: Now a std::set.
    	(collect_cores): Update.
    	(unique): Remove.
    	(print_one_inferior): Update.

commit dcd5ddccd7d7917caf42b8d429a7535857c6e9b2
Author: Tom Tromey <tom@tromey.com>
Date:   Thu May 4 16:01:41 2017 -0600

    Use std::string in mi-main.c
    
    Change a couple of spots in mi-main.c to use std::string, and change
    one place to use field_fmt.  This removes some cleanups.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (mi_execute_cli_command): Use std::string.
    	(mi_execute_async_cli_command): Likewise.
    	(mi_cmd_trace_frame_collected): Use field_fmt.

commit 45d288cc64e08dd68938f1d9bcc70906b5343652
Author: Tom Tromey <tom@tromey.com>
Date:   Thu May 4 15:44:27 2017 -0600

    Use gdb::byte_vector in mi_cmd_data_write_memory_bytes
    
    This changes mi_cmd_data_write_memory_bytes to use gdb::byte_vector,
    removing some cleanups.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
    	gdb::byte_vector.

commit 6afe2f4a39badf0ea1ccf9fd34417e729577c6e6
Author: Tom Tromey <tom@tromey.com>
Date:   Wed May 3 17:40:10 2017 -0600

    Remove unused declaration
    
    There was a leftover cleanup declaration in mi_parse.  Remove it.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-parse.c (mi_parse): Remove unused declaration.

commit 9813429a729dbcd761dfbb02d2d7a3449af0881d
Author: Tom Tromey <tom@tromey.com>
Date:   Wed May 3 17:28:08 2017 -0600

    Don't copy a string in mi_cmd_disassemble
    
    This string copy in mi_cmd_disassemble seems not to be needed, so
    don't do it.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".

commit 2d6960b4568869baaa3cb40f75caed4021938e1c
Author: Tom Tromey <tom@tromey.com>
Date:   Wed May 3 17:26:47 2017 -0600

    Remove cleanups from mi-cmd-var.c
    
    This removes some cleanups from mi-cmd-var.c.  varobj_gen_name now
    returns a string, simplifying mi_cmd_var_create.  In
    mi_cmd_var_delete, a string copy is apparently unnecessary, so it's
    simply removed.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* varobj.h (varobj_gen_name): Return std::string.
    	* varobj.c (varobj_gen_name): Return std::string.
    	* mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
    	(mi_cmd_var_delete): Don't copy "name".

commit 784c453a4f1aeee237203dd6257a6ed24bee28c3
Author: Tom Tromey <tom@tromey.com>
Date:   Wed May 3 17:22:07 2017 -0600

    Remove cleanups from mi_cmd_break_insert_1
    
    This changes mi_argv_to_format to return a string, allowing the
    removal of some cleanups.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
    	(mi_cmd_break_insert_1): Update.

commit a9bc57b97840a874ad2802e29a44fbf557668808
Author: Tom Tromey <tom@tromey.com>
Date:   Wed May 3 17:13:04 2017 -0600

    Remove make_cleanup_defer_target_commit_resume
    
    This removes make_cleanup_defer_target_commit_resume in favor of using
    scoped_restore.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* target.h (make_scoped_defer_target_commit_resume): Update.
    	* target.c (make_scoped_defer_target_commit_resume): Rename from
    	make_cleanup_defer_target_commit_resume.  Return a
    	scoped_restore.
    	* infrun.c (proceed): Use make_scoped_defer_target_commit_resume.

commit 9754d8c4c48209eaefb044d03dc25f14dca8a263
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:43:27 2017 -0600

    Remove some unused declarations
    
    This removes a couple of unused cleanup-related declarations.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* main.c (captured_main_1): Remove unused declaration.
    	* spu-multiarch.c (parse_spufs_run): Remove unused declaration.

commit 99ef965c6e812cc73691873c965cff0d2d5b89a0
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 21:17:40 2017 -0600

    Remove a cleanup from symtab.c
    
    This removes an unused outer cleanup from symtab.c, and an unused
    cleanup declaration as well.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* symtab.c (search_symbols): Remove unused outer cleanup.
    	(make_source_files_completion_list): Remove unused declaration.

commit 42518ba746b5b6cb7c169a55430e73551be345f5
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 21:08:05 2017 -0600

    Remove cleanup from mt-tdep.c
    
    Remove a cleanup from mt-tdep.c, using gdb::byte_vector.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.

commit 726b2169b4cda6a0267cb2986ada758270cff093
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 21:06:21 2017 -0600

    Remove cleanup from xstormy16-tdep.c
    
    This removes a cleanup from xstormy16-tdep.c, using gdb::byte_vector.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* xstormy16-tdep.c (xstormy16_push_dummy_call): Use
    	gdb::byte_vector.

commit 55b064321eed6cccf511fd698c732890e3ba4c6b
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:54:17 2017 -0600

    Remove cleanup from complaints.c
    
    This removes a cleanup from complaints.c by using std::string.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* complaints.c (vcomplaint): Use std::string.

commit 8abcee91738bf0be98e949049c559839ef811ae4
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:52:48 2017 -0600

    Remove some cleanups from tracepoint.c
    
    This removes some cleanups from tracepoint.c by using std::string.  It
    also removes some unused cleanup declarations.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* tracepoint.c (trace_variable_command): Use std::string.
    	(encode_actions_1): Remove unused declarations.
    	(create_tsv_from_upload): Use std::string.

commit 6ad94bc76615933a234a219368f1b9af2a64d746
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:46:18 2017 -0600

    Remove cleanups from cp-support.c
    
    This removes some cleanups from cp-support.c, using std::string.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* cp-support.c (gdb_demangle): Use std::string.

commit 2003f3d839fa887811ff65380191e0beaeff719e
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:42:21 2017 -0600

    Remove some cleanups from stack.c
    
    This removes some cleanups from stack.c by using std::string or
    gdb::unique_xmalloc_ptr.  One cleanup remains in this file; I did not
    remove it here because it is handled in another patch series that has
    yet to be resolved.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* stack.c (parse_frame_specification): Use std::string
    	(info_frame_command): Use gdb::unique_xmalloc_ptr.

commit 8f8accb58078b1f249dc6865b8784a0a8e8881dd
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:39:32 2017 -0600

    Remove cleanup from tilegx-tdep.c
    
    This removes a cleanup from tilegx-tdep.c, by using gdb::byte_vector.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.

commit 200aa7b154b25423eb72ceecade0fcd76edc4686
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:38:07 2017 -0600

    Remove cleanups from utils.c
    
    This removes a couple of cleanups from utils.c through the use of
    std::string.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (vfprintf_maybe_filtered): Use std::string.
    	(vfprintf_unfiltered): Likewise.

commit 606aae8a73177dde47ff01a6eb7ec883309bdfa6
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 27 20:30:19 2017 -0600

    Remove cleanup from display_gdb_prompt
    
    This removes a cleanup from display_gdb_prompt by using std::string.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* event-top.c (top_level_prompt): Return std::string.
    	(display_gdb_prompt): Update.

commit bd413795d364d3bed8dbb8c596cb45c82ed31041
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Sep 28 07:44:50 2017 -0600

    Introduce string_vprintf
    
    This adds string_vprintf, a va_list variant of string_printf.  This
    will be used in later patches.
    
    gdb/ChangeLog
    2017-09-29  Tom Tromey  <tom@tromey.com>
    
    	* unittests/common-utils-selftests.c (format): New function.
    	(string_vprintf_tests): New function.
    	(_initialize_common_utils_selftests): Register new tests.
    	* common/common-utils.c (string_vprintf): New function.
    	* common/common-utils.h (string_vprintf): Declare.

commit 8b5b25295998e10723bd51d127c87249a779f628
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Sep 30 08:20:08 2017 +0930

    PR21978, objdump does not display line numbers in certain cases
    
    Same line but different file ought to display file and line.
    
    	PR 21978
    	* objdump.c: Formatting.
    	(show_line): Reset prev_line when function name changes.

commit 1755697b1df1286cbee20dc487d656025964a7a9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Sep 30 00:00:28 2017 +0000

    Automatic date update in version.in

commit 256642e857886f1e3da86ce2484f9df5a5a6b904
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 29 17:15:36 2017 +0100

    Constify unpack_varlen_hex & fix fallout
    
    I ran into non-const unpack_varlen_hex while working on something
    else, and decided to just fix it first.  Ends up constifying a good
    deal of remote packet parsing.
    
    gdb/ChangeLog:
    2017-09-29  Pedro Alves  <palves@redhat.com>
    
    	* common/rsp-low.c (unpack_varlen_hex): Constify.
    	* common/rsp-low.h (unpack_varlen_hex): Constify.
    	* linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
    	Constify.
    	* remote.c (remote_set_permissions, read_ptid)
    	(remote_current_thread, remote_get_threads_with_qthreadinfo)
    	(remote_static_tracepoint_marker_at)
    	(remote_static_tracepoint_markers_by_strid)
    	(stop_reply_extract_thread, remote_parse_stop_reply): Constify.
    	* tracepoint.c (parse_trace_status, parse_tracepoint_status)
    	(parse_tracepoint_definition, parse_tsv_definition)
    	(parse_static_tracepoint_marker_definition): Constify.
    	* tracepoint.h (parse_static_tracepoint_marker_definition)
    	(parse_trace_status, parse_tracepoint_status)
    	(parse_tracepoint_definition, parse_tsv_definition): Constify.
    
    gdb/gdbserver/ChangeLog:
    2017-09-29  Pedro Alves  <palves@redhat.com>
    
    	* ax.c (gdb_parse_agent_expr): Constify.
    	* ax.h (gdb_parse_agent_expr): Constify.
    	* mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
    	Constify.
    	* mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
    	* remote-utils.c (hex_or_minus_one, read_ptid): Constify.
    	* remote-utils.h (read_ptid): Constify.
    	* server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
    	(process_point_options, process_serial_event): Constify.
    	* tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
    	(cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
    	(cmd_qtbuffer): Constify.

commit b6bb34680b9c99961b6cd635853552ec6569a2a4
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 29 17:09:05 2017 +0100

    gdb/remote.c: Eliminate target_buf/target_buf_size hack
    
    This finally eliminates an old hack left in place when tracepoint RSP
    support was migrated from tracepoint.c to remote.c, back in
    35b1e5cca081 ("Make tracepoint operations go through target vector.")
    over 7 years ago.
    
    Tested on x86_64 GNU/Linux.
    
    gdb/ChangeLog:
    2017-09-29  Pedro Alves  <palves@redhat.com>
    
    	* remote.c (target_buf, target_buf_size): Delete.
    	(remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
    	Use the connection's packet buffer instead.
    	All callers adjusted.
    	(_initialize_remote): Remove references to target_buf and
    	target_buf_size.

commit 5b9ca4d43ba0313612e8ad6e50221e8f20ebd129
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 29 12:33:41 2017 +0100

    gdbserver/libthread_db: Don't ignore memory reading failures
    
    If we had this in place before, then the regression fixed by the
    previous commit would have been been visible is all test runs.  E.g.:
    
      Running src/gdb/testsuite/gdb.threads/multi-create-ns-info-thr.exp ...
      FAIL: gdb.threads/multi-create-ns-info-thr.exp: continue to breakpoint 6
    
    Debugging manually we'd see this:
      gdbserver: Cannot get thread handle for LWP 1467: generic error
    
    Instead of:
      gdbserver: PID mismatch!  Expected 27472, got 27471
    
    which is misleading - gdbserver didn't 27471, that was stale stack
    data from previous function invocations.
    
    gdb/gdbserver/ChangeLog:
    2017-09-29  Pedro Alves  <palves@redhat.com>
    
    	* proc-service.c (ps_pdread): Return PS_ERR if reading memory
    	fails.

commit 94c207e097a3a30ce71fc8f700325113968c276b
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 29 13:06:34 2017 +0100

    Fix gdbserver regression exposed by gdb.threads/multi-create-ns-info-thr.exp
    
    Commit 8629910955a7 ("Add thread_db_notice_clone to gdbserver")
    introduced calls into libthread_db without making sure that the
    current thread is pointing to a know-stopped thread.  This resulted in
    sometimes thread_db_notice_clone failing->find_one_thread failing like
    this, as seen when running gdb.threads/multi-create-ns-info-thr.exp:
    
    ~~~
      Thread <6> executing
      Thread <7> executing
      gdbserver: PID mismatch!  Expected 27472, got 27471
      gdbserver: Cannot find thread after clone.
    
      Thread <1000> executing
      Thread <1001> executing
    ~~~
    
    Things go south from here and sometimes that ends up resulting in
    gdbserver crashing and the test failing.
    
    gdb/gdbserver/ChangeLog:
    2017-09-29  Pedro Alves  <palves@redhat.com>
    
    	* linux-low.c (handle_extended_wait): Pass parent thread instead
    	of process to thread_db_notice_clone.
    	* linux-low.h (thread_db_notice_clone): Replace parent process
    	parameter with parent thread parameter.
    	* thread-db.c (find_one_thread): Add comment.
    	(thread_db_notice_clone): Replace parent process parameter with
    	parent thread parameter.  Temporarily switch to the parent thread.

commit f6ac8c52c955b487dcb56d05fc93fced7b203294
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 29 13:07:56 2017 +0930

    Fail when string merge can't alloc memory
    
    I was looking at Debian bug #874674 again today, and think I might
    have spotted the problem.  It appears that merge.c tries to cope with
    memory allocation failures in some circumstances, but doesn't quite
    manage to get everything right.  This patch will make ld report memory
    allocation failures instead of silently not merging strings.
    
    	* merge.c (merge_strings): Return FALSE on malloc failure.
    	(_bfd_merge_sections): Return failures from record_section and
    	merge_strings.

commit 1b8f6c7f827726b5f91745149f7d4329f10de7fd
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Sep 29 00:00:24 2017 +0000

    Automatic date update in version.in

commit b2f8eb7a30dcf7c33ea26dfca31401a6786dcd99
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Sep 28 22:31:42 2017 +0100

    Move utils-selftests.c -> gdb/unittests/
    
    This file was only under gdb/ currently because it predates the
    gdb/unittests/ directory.
    
    gdb/ChangeLog:
    2017-09-28  Pedro Alves  <palves@redhat.com>
    
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
    	unittests/common-utils-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
    	(COMMON_OBS): Remove utils-selftests.o.
    	* utils-selftests.c: Move to ...
    	* unittests/common-utils-selftests.c: ... here and rename self
    	test to "string_printf".

commit 08302ed2cb8b175e3bbd4308879154baf64e6d98
Author: Doug Evans <dje@google.com>
Date:   Thu Sep 28 09:20:59 2017 -0700

    (open_and_init_dwp_file): Protect against some segvs
    
    This is a "tiny patch", no assignment required.
    
    2017-09-28  Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com>
    
    	* dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
    	having NULL cus or tus.

commit 231ca753239211b72eb761593083a0ee859274e7
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Sep 28 11:33:20 2017 +0100

    Skip the PR 14918 linker test for ARM targets.
    
     I am applying a patch that has been lying around in the Fedora
      binutils sources for a while.  It skips the PR14918 linker test for
      ARM based targets.  This test checks that libgcc is not included in a
      link of an empty executable.  This works for most targets, but on the
      ARM the crt1.o startup code calls __libc_csu_init which is in
      /usr/lib/libc_nonshared.a(elf-init.oS).  This in turn needs
      __aeabi_unwind_cpp_pr0@@GCC_3.5 which is provided by libgcc_s.so.1,
      and so the test fails.

commit 1a3b5c34fe371f618402f811a981839c9191ff9f
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Sep 28 17:11:38 2017 +0930

    PR22220, BFD linker wrongly marks symbols as PREVAILING_DEF_IRONLY
    
    non_ir_ref_dynamic wasn't being set in the case where we have a
    versioned dynamic symbol definition with a non-versioned matching IR
    symbol.
    
    bfd/
    	PR 22220
    	* elflink.c (_bfd_elf_merge_symbol): Set non_ir_ref_dynamic in
    	a case where plugin_notice isn't called.
    ld/
    	* testsuite/ld-plugin/pr22220.h,
    	* testsuite/ld-plugin/pr22220lib.cc,
    	* testsuite/ld-plugin/pr22220lib.ver,
    	* testsuite/ld-plugin/pr22220main.cc: New test.
    	* testsuite/ld-plugin/lto.exp: Run it.

commit 50300765aa46894d9347f760fd10dab829d564f7
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Sep 28 00:00:30 2017 +0000

    Automatic date update in version.in

commit 96a5a1d3780a46b578842d9aeea3e98211dc20ec
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Sep 27 19:05:21 2017 +0200

    Complete tdep move to convert_typed_floating
    
    Many tdep files need to perform conversions between two floating-point
    types, usually when accessing FP registers.  Most targets now use the
    convert_typed_floating helper routine to do so.  However, a small number
    still use the old method of converting via a DOUBLEST.  Since we want
    to get rid of DOUBLEST, these targets need to be moved to the new
    method as well.
    
    The main obstacle is that for convert_typed_floating we need an actual
    *type*, not just a floatformat.
    
    In arm-tdep.c, this is very straightforward, since there is already a
    type using the ARM extended floatformat.
    
    For sh-tdep.c and sh64-tdep.c, no such type already exists, so I've
    added one to the gdbarch_tdep struct as done on other targets.
    
    gdb/ChangeLog
    2017-09-27  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* arm-tdep.c: (convert_from_extended): Remove.
    	(convert_to_extended): Likewise.
    	(arm_extract_return_value): Use convert_typed_floating.
    	(arm_store_return_value): Likewise.
    
    	* sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
    	* sh-tdep.c: Do not include "floatformat.h".
    	(sh_littlebyte_bigword_type): New function.
    	(sh_register_convert_to_virtual): Use convert_typed_floating.
    	(sh_register_convert_to_raw): Likewise.
    	* sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
    	(sh64_littlebyte_bigword_type): New function.
    	(sh64_extract_return_value): Use convert_typed_floating.
    	(sh64_register_convert_to_virtual): Likewise.
    	(sh64_register_convert_to_raw): Likewise.

commit 0db7851f9f490f0b60689df5a218ccce60896e3d
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Sep 27 19:03:36 2017 +0200

    Simplify floatformat_from_type
    
    For historical reasons, the TYPE_FLOATFORMAT element is still set to hold
    an array of two floatformat structs, one for big-endian and the other for
    little-endian.  When accessing the element via floatformat_from_type,
    the code would check the type's byte order and return the appropriate
    floatformat.
    
    However, these days this is quite unnecessary, since the type's byte order
    is already known at the time the type is allocated and the floatformat is
    installed into TYPE_FLOATFORMAT.  Therefore, we can just install the correct
    version here.
    
    Also, moves the (now trivially simple) floatformat_from_type accessor to
    gdbtypes.{c,h}, since it doesn't really need to be in doublest.c now.
    
    gdb/ChangeLog
    2017-09-27  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* doublest.h (floatformat_from_type): Move to gdbtypes.h.
    	* doublest.c (floatformat_from_type): Move to gdbtypes.c.
    
    	* gdbtypes.h (union type_specific): Make field floatformat hold
    	just a single struct floatformat, not an array.
    	(floatformat_from_type): Move here.
    	* gdbtypes.c (floatformat_from_type): Move here.  Update to
    	changed TYPE_FLOATFORMAT definition.
    	(verify_floatformat): Update to changed TYPE_FLOATFORMAT.
    	(recursive_dump_type): Likewise.
    	(init_float_type): Install correct floatformat for byte order.
    	(arch_float_type): Likewise.

commit 77b7c781e9f03cdd903dad76f47ea0bb25277b06
Author: Ulrich Weigand <ulrich.weigand@de.ibm.com>
Date:   Wed Sep 27 19:02:00 2017 +0200

    Make init_type/arch_type take a size in bits
    
    This changes the interfaces to init_type and arch_type to take the
    type length in bits as input (instead of as bytes).  The routines
    assert that the length is a multiple of TARGET_CHAR_BIT.
    
    For consistency, arch_flags_type is changed likewise, so that now
    all type creation interfaces always use length in bits.
    
    All callers are updated in the straightforward manner.
    
    The assert actually found a bug in read_range_type, where the
    init_integer_type routine was called with a wrong argument (probably
    a bug introduced with the conversion to use init_integer_type).
    
    gdb/ChangeLog
    2017-09-27  Ulrich Weigand  <uweigand@de.ibm.com>
    
    	* gdbtypes.c (init_type): Change incoming argument from
    	length-in-bytes to length-in-bits.  Assert length is a
    	multiple of TARGET_CHAR_BITS.
    	(arch_type, arch_flags_type): Likewise.
    	(init_integer_type): Update call to init_type.
    	(init_character_type): Likewise.
    	(init_boolean_type): Likewise.
    	(init_float_type): Likewise.
    	(init_decfloat_type): Likewise.
    	(init_complex_type): Likewise.
    	(init_pointer_type): Likewise.
    	(objfile_type): Likewise.
    	(arch_integer_type): Update call to arch_type.
    	(arch_character_type): Likewise.
    	(arch_boolean_type): Likewise.
    	(arch_float_type): Likewise.
    	(arch_decfloat_type): Likewise.
    	(arch_complex_type): Likewise.
    	(arch_pointer_type): Likewise.
    	(gdbtypes_post_init): Likewise.
    
    	* dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
    	(read_base_type): Likewise.
    	* mdebugread.c (basic_type): Likewise.
    	* stabsread.c (dbx_init_float_type): Likewise.
    	(rs6000_builtin_type): Likewise.
    	(read_range_type): Likewise.  Also, fix call to init_integer_type
    	with erroneous length argument.
    
    	* ada-lang.c (ada_language_arch_info): Update call to arch_type.
    	* d-lang.c (build_d_types): Likewise.
    	* f-lang.c (build_fortran_types): Likewise.
    	* go-lang.c (build_go_types): Likewise.
    	* opencl-lang.c (build_opencl_types): Likewise.
    	* jit.c (finalize_symtab): Likewise.
    	* gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
    	(build_std_type_info_type): Likewise.
    	* target-descriptions.c (tdesc_gdb_type): Likewise.  Also,
    	update call to arch_flags_type.
    
    	* linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
    	arch_type.
    	* fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
    	* windows-tdep.c (windows_get_tlb_type): Likewise.
    
    	* avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
    	* ft32-tdep.c (ft32_gdbarch_init): Likewise.
    	* m32c-tdep.c (make_types): Likewise.
    	* rl78-tdep.c (rl78_gdbarch_init): Likewise.
    	(rl78_psw_type): Update call to arch_flags_type.
    	* m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
    	* rx-tdep.c (rx_psw_type): Likewise.
    	(rx_fpsw_type): Likewise.
    	* sparc-tdep.c (sparc_psr_type): Likewise.
    	(sparc_fsr_type): Likewise.
    	* sparc64-tdep.c (sparc64_pstate_type): Likewise.
    	(sparc64_ccr_type): Likewise.
    	(sparc64_fsr_type): Likewise.
    	(sparc64_fprs_type): Likewise.

commit 8e43602e34ba404d82f7c74f6629f01e40c740e0
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Sep 27 16:21:36 2017 +0100

    Add support for the new names of the RISC-V fmv.x.s and fmv.s.x instructions, vis: fmv.x.w and fmv.w.x.
    
    	PR 22179
    opcodes	* riscv-opc.c (riscv_opcodes): Add fmv.x.w and fmv.w.x as the new
    	names for the fmv.x.s and fmv.s.x instructions respectively.
    
    gas	* testsuite/gas/riscv/fmv.x.s: New file: Tests the support for the
    	renamed fmv.x.s and fmv.s.x instructions.
    	* testsuite/gas/riscv/fmv.x.d: New file: Test driver.

commit f21b4d5c59136c38bb6d94eb6a29ad80d02043f4
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:33:48 2017 -0600

    Constify find_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* findcmd.c (find_command): Constify.

commit 643c2ffafea7397461daea339bb8f0ef2f23b31f
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:33:21 2017 -0600

    Constify some commands in ada-tasks.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* ada-tasks.c (task_command_1, task_command): Constify.

commit 510e5e562796a5d2bbd4c7208155bd8a3c03b50d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:32:30 2017 -0600

    Constify some commands in symtab.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* symtab.c (maintenance_print_symbol_cache)
    	(maintenance_flush_symbol_cache)
    	(maintenance_print_symbol_cache_statistics): Constify.

commit e503b1919bc5d06684ba6b1d09a6ccdf0a50b879
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:32:18 2017 -0600

    Constify some commands in inferior.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* inferior.c (detach_inferior_command, kill_inferior_command)
    	(inferior_command): Constify.

commit 4e00131263d4de2e8b7a1d0da7e27e423d94fb52
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:31:41 2017 -0600

    Constify some commands in regcache.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* regcache.c (regcache_print, maintenance_print_registers)
    	(maintenance_print_raw_registers)
    	(maintenance_print_cooked_registers)
    	(maintenance_print_register_groups)
    	(maintenance_print_remote_registers): Constify.

commit 7776370010db4d85a89a0dfde391aa9170ac1bbe
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:30:50 2017 -0600

    Constify some commands in printcmd.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* printcmd.c (map_display_numbers, undisplay_command)
    	(enable_disable_display_command, enable_display_command)
    	(disable_display_command): Constify.

commit 4495129abde9922d77215233837fb47738722de9
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:25:07 2017 -0600

    Constify some commands in breakpoint.c
    
    This also makes delete_command static; but now I wonder if it is used
    in Insight and should not be touched.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.h (delete_command): Don't declare.
    	* breakpoint.c (delete_command, enable_once_command)
    	(enable_count_command, enable_delete_command, breakpoint_1)
    	(maintenance_info_breakpoints, stopin_command, stopat_command)
    	(delete_command, delete_trace_command, save_breakpoints)
    	(save_breakpoints_command, save_tracepoints_command): Constify.

commit 3088cf40a57ec7b5276f192238603684b4608a90
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:22:55 2017 -0600

    Constify some commands in macrocmd.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* macrocmd.c (macro_expand_command, macro_expand_once_command)
    	(skip_ws, extract_identifier, macro_define_command)
    	(macro_undef_command, macro_list_command): Constify.

commit 69f476a36f475210807cb70d10183df9b838a9eb
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:20:36 2017 -0600

    Constify some commands in infcmd.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* infcmd.c (environment_info, set_environment_command)
    	(unset_environment_command, path_info, info_proc_cmd_1)
    	(info_proc_cmd_mappings, info_proc_cmd_stat)
    	(info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
    	(info_proc_cmd_exe, info_proc_cmd_all): Constify.

commit c4a3e68e33b78c68d63c35bbed01782ff9eff4d1
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:17:26 2017 -0600

    Constify some commands in i386-tdep.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
    	Constify.

commit c9d31bd6579d5bbd672937a76258031675d40f34
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:17:01 2017 -0600

    Constify add_symbol_file_from_memory_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* symfile-mem.c (add_symbol_file_from_memory_command): Constify.

commit 1f3f85eba696bfff4fea5e66167ee001c07c4b0b
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:16:47 2017 -0600

    Constify demangle_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* demangle.c (demangle_command): Constify.

commit 9c504b5d34803ca2520e554aceaa2e69c141dc89
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:15:46 2017 -0600

    Constify maintenance_info_program_spaces_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* progspace.c (maintenance_info_program_spaces_command):
    	Constify.

commit 6663cf9161f7ed9cbd1ac1c0afba36c952d84140
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:14:41 2017 -0600

    Constify some commands in compile.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile.c (check_raw_argument, compile_file_command)
    	(compile_code_command, compile_print_command): Constify.

commit 34e5fa26b758250fca879799375f27c1fd8ed36d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:13:51 2017 -0600

    Constify maintenance_print_reggroups
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* reggroups.c (maintenance_print_reggroups): Constify.

commit 8384c35618fdfa66ea3ec6e84072cccc6192dd48
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:13:40 2017 -0600

    Constify save_gdb_index_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2read.c (save_gdb_index_command): Constify.

commit 884beb0c41d8479e3c05f3492cb65da05ed882d1
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:13:21 2017 -0600

    Constify info_probes_stap_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* stap-probe.c (info_probes_stap_command): Constify.

commit e0b2930cdc0153d871f80ad728d6e3fa90324b5e
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:13:03 2017 -0600

    Constify unset_exec_wrapper_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* fork-child.c (unset_exec_wrapper_command): Constify.

commit f938677d425cd0453e26f7f51d9e94c87c92a25d
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:12:42 2017 -0600

    Constify some commands in btrace.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* btrace.c (get_uint, get_context_size, no_chunk)
    	(maint_btrace_packet_history_cmd)
    	(maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
    	(maint_info_btrace_cmd): Constify.

commit 8949cb878d5daae969db6326e1e1323bfa3ad9d4
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:09:47 2017 -0600

    Constify delete_bookmark_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* reverse.c (delete_bookmark_command): Constify.

commit ac88e2de8314efd9aaa9132c5643ecbf715de508
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:09:35 2017 -0600

    Constify some commands in remote.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* remote.c (set_memory_packet_size)
    	(set_memory_write_packet_size, show_memory_write_packet_size)
    	(set_memory_read_packet_size, show_memory_read_packet_size)
    	(compare_sections_command, packet_command, remote_put_command)
    	(remote_get_command, remote_delete_command): Constify.

commit bd4c9dfe673d8af39cf400ba0118ffadb0e6111a
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:05:40 2017 -0600

    Constify some commands in mips-tdep.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
    	(set_mipsfpu_double_command, set_mipsfpu_none_command)
    	(set_mipsfpu_auto_command): Constify.

commit 5e93d4c64bbc3b4fb306e54cdcd79bc8ff86b2f0
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 21:02:08 2017 -0600

    Constify cd_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-cmds.h (cd_command): Constify.
    	* cli/cli-cmds.c (cd_command): Constify.

commit fc41a75bee01fbd0883e6df1e031d4d9e998c437
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 20:45:21 2017 -0600

    Constify some commands in thread.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* thread.c (thread_name_command, thread_find_command): Constify.

commit 67810076681180b74d92f98d11c4a3d94885c9e5
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 20:42:32 2017 -0600

    Constify some commands in probes.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* probe.c (enable_probes_command, disable_probes_command):
    	Constify.

commit 1d8b34a7a233d89938fd173389f7884aa7d105b3
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 18:39:07 2017 -0600

    Constify some commands in exec.c, plus symbol_file_command
    
    Note that this commit also changes deprecated_file_changed_hook -- not
    used in the tree, but Insight will require a (presumably minor)
    change.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (symbol_file_command): Constify.
    	* gdbcore.h (deprecated_file_changed_hook): Constify.
    	* exec.c (deprecated_file_changed_hook, exec_file_command)
    	(file_command): Constify.
    	* defs.h (symbol_file_command): Constify.

commit 442019e118afb6bdbae490c0b072e8f024f2d9a2
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 18:38:19 2017 -0600

    Constify some commands in remote-fileio.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* remote-fileio.c (set_system_call_allowed)
    	(show_system_call_allowed): Constify.

commit 2983f7cbdb245e516799f1a5b8ddc0450bce98c9
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 18:37:46 2017 -0600

    Constify some commands in tracepoint.c
    
    In addition to the constification, this fixes a command-repeat bug.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* tracepoint.c (delete_trace_variable_command)
    	(tfind_end_command, tfind_start_command, tfind_pc_command)
    	(tfind_tracepoint_command, tfind_line_command)
    	(tfind_range_command, tfind_outside_command): Constify.

commit 4fd41b2486e0c3407d39a6a4c0bbeedd057eb20e
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 15:00:06 2017 -0600

    Constify some commands in ax-gdb.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* ax-gdb.c (maint_agent_printf_command, agent_command)
    	(agent_eval_command): Constify.

commit f2fc30156cb71a3e616186f09f0ffa0da26780fa
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 18:32:41 2017 -0600

    Constify some linespec functions
    
    This changes a few linespec functions to work on "const char *" and
    then fixes up all the callers.  This allows further constification
    elsewhere.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* tracepoint.c (info_scope_command): Constify.
    	* python/python.c (gdbpy_decode_line): Constify.
    	* python/py-breakpoint.c (bppy_init): Constify.
    	* mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
    	* location.h: (new_linespec_location)
    	(string_to_event_location_basic, string_to_event_location):
    	Constify.
    	* location.c (new_linespec_location)
    	(string_to_event_location_basic, string_to_event_location):
    	Constify.
    	* linespec.h (decode_line_with_current_source)
    	(decode_line_with_last_displayed, linespec_lex_to_end): Constify.
    	* linespec.c (linespec_lex_to_end)
    	(decode_line_with_current_source)
    	(decode_line_with_last_displayed): Constify.
    	* guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
    	Constify.
    	* cli/cli-cmds.c (edit_command, list_command): Constify.
    	* breakpoint.h (until_break_command, watch_command_wrapper)
    	(awatch_command_wrapper, rwatch_command_wrapper)
    	(init_ada_exception_breakpoint): Constify.
    	* breakpoint.c (break_command_1, dprintf_command)
    	(break_range_command, watch_command_wrapper)
    	(rwatch_command_wrapper, awatch_command_wrapper)
    	(until_break_command, init_ada_exception_breakpoint)
    	(strace_marker_create_sals_from_location, trace_command)
    	(ftrace_command, strace_command, struct tracepoint): Constify.
    	* ax-gdb.c (agent_command_1): Constify.
    	* ada-lang.c (ada_exception_sal): Constify.

commit 8c2f95f4346a4ed6593b1e0cb60d1839176e42c2
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 14:56:48 2017 -0600

    Constify some commands in record.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
    	(cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
    	(get_context_size, no_chunk, get_insn_history_modifiers)
    	(cmd_record_insn_history, get_call_history_modifiers)
    	(cmd_record_call_history): Constify.

commit a0d65762f11272996095870affe18f4c2cf354dc
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 14:45:14 2017 -0600

    Constify some commands in source.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* source.c (show_substitute_path_command)
    	(unset_substitute_path_command, set_substitute_path_command):
    	Constify.

commit 58971144622629bd11acc82b61140f8c47f0e306
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 14:40:43 2017 -0600

    Constify commands maint.c, plus maintenance_print_type
    
    In addition to the constification, this fixes a command-repeat bug.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* typeprint.c (maintenance_print_type): Constify.
    	* maint.c (maintenance_dump_me, maintenance_demangle)
    	(maintenance_time_display, maintenance_info_sections)
    	(maintenance_print_statistics, maintenance_deprecate)
    	(maintenance_undeprecate): Constify.
    	(maintenance_do_deprecate): Constify.  Use std::string.
    	(maintenance_selftest): Constify.
    	* gdbtypes.h (maintenance_print_type): Constify.

commit c482f52ccfbd5609aef5482fb0872545bdcabaf2
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:52:56 2017 -0600

    Constify unwind_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* hppa-tdep.c (unwind_command): Constify.

commit e100df1a2ea356a8a311114bc2927215a33eefcb
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:52:05 2017 -0600

    Constify some commands in target-descriptions.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* target-descriptions.c (unset_tdesc_filename_cmd)
    	(maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
    	Constify.

commit 31d56ade0e943aca57acbc030334d65ae0b6f866
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:51:39 2017 -0600

    Constify maintenance_print_dummy_frames
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* dummy-frame.c (maintenance_print_dummy_frames): Constify.

commit b961da0bb033e0058059695fdc28c5fbe0057c1a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:51:21 2017 -0600

    Constify some commands in tui.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* tui/tui.c (tui_enable_command, tui_disable_command): Constify.

commit e2d8ae16c0c9a4f6c61ddb9af3d6ec8b2b71db2a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:51:10 2017 -0600

    Constify tui_reg_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* tui/tui-regs.c (tui_reg_command): Constify.

commit 863779b0c64917a1580a9e505762642ef5833575
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:50:56 2017 -0600

    Constify some commands in skip.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* skip.c (skip_file_command, skip_function_command)
    	(skip_enable_command, skip_disable_command, skip_delete_command):
    	Constify.

commit cdb34d4a1cf2553a58dc993bfb6f78716e0d1c43
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:46:34 2017 -0600

    Constify some commands in record-btrace.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* record-btrace.c (cmd_record_btrace_bts_start)
    	(cmd_record_btrace_pt_start): Constify.

commit e99c83e741949cb7ae9f4ed449768e8f89ae02bf
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:45:47 2017 -0600

    Constify some commands in symmisc.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* symmisc.c (maintenance_print_symbols)
    	(maintenance_print_msymbols, maintenance_print_objfiles)
    	(maintenance_info_symtabs, maintenance_check_symtabs)
    	(maintenance_expand_symtabs, maintenance_info_line_tables):
    	Constify.

commit 32faf971cd86d0a13c6b3db4626d4c8bd119e6c5
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:44:55 2017 -0600

    Constify new_ui_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* top.c (new_ui_command): Constify.

commit 2cf311ebadb5058afb983c61363fc2595c01b9e4
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:44:31 2017 -0600

    Constify some commands in symfile.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (add_symbol_file_command)
    	(remove_symbol_file_command, list_overlays_command)
    	(map_overlay_command, unmap_overlay_command)
    	(overlay_auto_command, overlay_manual_command)
    	(overlay_off_command, overlay_load_command): Constify.

commit e6738699f704ae1ece43e9758f60d084b45e5308
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:41:50 2017 -0600

    Constify some commands in spu-tdep.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* spu-tdep.c (info_spu_event_command, info_spu_signal_command)
    	(info_spu_mailbox_command, info_spu_dma_command)
    	(info_spu_proxydma_command): Constify.

commit aa360cd5dd21a527f67f93ef75db92bac6cf02d5
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:40:53 2017 -0600

    Constify some commands in cli-logging.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-logging.c (set_logging_on, set_logging_off): Constify.

commit 898241a5ba617eb3e0bad4eb0bafaa9320320178
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:40:16 2017 -0600

    Constify user_defined_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-script.c (user_defined_command): Constify.

commit 2d0ac1068babfe8800607b17ddb2f31189bdb334
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:39:18 2017 -0600

    Constify commands in cli-dump.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-dump.c (dump_memory_command, dump_value_command)
    	(dump_srec_memory, dump_srec_value, dump_ihex_memory)
    	(dump_ihex_value, dump_verilog_memory, dump_verilog_value)
    	(dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
    	(dump_binary_value, append_binary_memory, append_binary_value):
    	Constify.
    	(struct dump_context) <func>: Constify.
    	(add_dump_command): Update.

commit dede02ce4d2267d044db41a0896af4d670647a04
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:37:20 2017 -0600

    Constify some commands in  cli-cmds.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-cmds.c (show_version, show_configuration)
    	(source_command, show_user): Constify.

commit d3cb6b99c5127911f94c782be8214e2093fbe82c
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:34:29 2017 -0600

    Constify maintenance_print_target_stack
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* target.c (maintenance_print_target_stack): Constify.

commit 1970a12f32f788f22b641737e846350e1ff9dd04
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:32:11 2017 -0600

    Constify interpreter_exec_cmd
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* interps.c (interpreter_exec_cmd): Constify.

commit 41243651350688a9a0f3a3542871d37e7f3c5f20
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:31:57 2017 -0600

    Constify cmd_record_full_restore
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* record-full.c (cmd_record_full_restore): Constify.

commit 4465d9db2f8962640f3799a17851bef3b1be1a33
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:30:40 2017 -0600

    Constify some functions in memattr.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* memattr.c (enable_mem_command, disable_mem_command)
    	(delete_mem_command): Constify.

commit ad25e4234a3f370a693b9c392c5b54216aab4592
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:29:57 2017 -0600

    Constify show_convenience
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* value.c (show_convenience): Constify.

commit d64097b17c88ae18781ecce59d1b265b41e9551a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:25:44 2017 -0600

    Constify core_file_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* gdbcore.h (core_file_command): Update.
    	* corefile.c (core_file_command): Constify.

commit 4d4589ef76b975eead8da6bfa65db4a9dc85089a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:24:08 2017 -0600

    Constify maintenance_print_user_registers
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* user-regs.c (maintenance_print_user_registers): Constify.

commit 32a7bf17c94a81c08535ea045f43fe8c8271d3fd
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:23:03 2017 -0600

    Constify maintenance_cplus_namespace
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cp-namespace.c (maintenance_cplus_namespace): Constify.

commit 4a47555179bfcfd3c9e4ad2752e38ae398fc7dcd
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:22:52 2017 -0600

    Constify first_component_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cp-support.c (first_component_command): Constify.

commit 990b9f9f5a301cef9c16035c341a7b0b7ccc983d
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:22:28 2017 -0600

    Constify some functions in psymtab.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* psymtab.c (maintenance_print_psymbols)
    	(maintenance_info_psymtabs, maintenance_check_psymtabs):
    	Constify.

commit c281872eec33c92db0565afdbfdee91558e5d8e0
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:22:05 2017 -0600

    Constify display_tib
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* windows-tdep.c (display_tib): Constify.

commit 5b64bf744c04f550a9d15b49a8cb0245904afb13
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 21:00:26 2017 -0600

    Constify two functions in linux-fork.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* linux-fork.c (delete_checkpoint_command)
    	(detach_checkpoint_command): Constify.

commit 4ada038f6a8330b27769ad0227c7f716aa29b649
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:59:50 2017 -0600

    Constify two functions in cp-abi.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.

commit 57f5a81bd240459edbdac1628800291e7535ed02
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:59:14 2017 -0600

    Constify dump_arc_instruction_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* arc-tdep.c (dump_arc_instruction_command): Constify.

commit b0a8e6c4431a2e762dac88f3d73efca4bc47c90a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:58:42 2017 -0600

    Constify two functions in valprint.c
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* valprint.c (set_radix, show_radix): Constify.

commit 8d97dc1cea4d1dafff2ce2f55e0b84cfe444e6cf
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:57:56 2017 -0600

    Constify info_probes_dtrace_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* dtrace-probe.c (info_probes_dtrace_command): Constify.

commit eb7c454d737322be2d810e1a5a2dc7b88fd636e6
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:57:10 2017 -0600

    Constify not_just_help_class_command
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* command.h (not_just_help_class_command): Update.
    	* cli/cli-decode.h (not_just_help_class_command): Update.
    	* cli/cli-decode.c (not_just_help_class_command): Constify.

commit e4e3333549c96d2915bb888b7b347566c938e75a
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:55:20 2017 -0600

    Constify add_cmd gdb_bfd.c
    
    This constifies a command function in gdb_bfd.c.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* gdb_bfd.c (maintenance_info_bfds): Constify.

commit 0450cc4ce8b4775c47e9aaa1c5a34e181b10ae98
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 20:51:33 2017 -0600

    Add add_cmd function overloads
    
    This adds two add_cmd overloads: one whose callback takes a const char *,
    and one that doesn't accept a function at all.  The no-function overload
    was introduced to avoid ambiguity when NULL was passed as the function.
    
    Long term the goal is for all commands to take const arguments, and
    for the non-const variants to be removed entirely.
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
    	overloads.
    	(do_add_cmd): Rename from add_cmd.  Don't call set_cmd_cfunc.
    	(do_const_cfunc): New function.
    	(cmd_cfunc_eq): New overload.
    	(cli_user_command_p): Check do_const_cfunc.
    	* cli/cli-decode.h (struct cmd_list_element) <function>: New field
    	const_cfunc.
    	* command.h (add_cmd): Add const overload and no-function
    	overload.
    	(set_cmd_cfunc): Add const overload.
    	(cmd_const_cfunc_ftype): Declare.
    	(cmd_cfunc_eq): Add const overload.
    	* breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
    	python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
    	overload.

commit a9bbfbd85fddfea2db30810c33c4bb130a2ef773
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 17 20:36:41 2017 -0600

    Add support for __VA_OPT__
    
    C++2a adds a "__VA_OPT__" feature that can be used to control the
    pesky "," emission when the final (variable) argument of a variadic
    macro is empty.  This patch implements this feature for gdb.  (A patch
    to implement it for gcc is pending.)
    
    gdb/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* macroexp.c (get_next_token_for_substitution): New function.
    	(substitute_args): Call it.  Check for __VA_OPT__.
    
    gdb/testsuite/ChangeLog
    2017-09-27  Tom Tromey  <tom@tromey.com>
    
    	* gdb.base/macscp.exp: Add __VA_OPT__ tests.

commit 19485196044b2521af979f1e5c4a89bfb90fba0b
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Sep 27 10:42:51 2017 +0100

    Prevent an infinite loop in the DWARF parsing code when encountering a CU structure with a small negative size.
    
    	PR 22219
    	* dwarf.c (process_debug_info): Add a check for a negative
    	cu_length field.

commit 6bd6a03d6975a96802b37741a99644570e52a72b
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Sep 27 15:14:00 2017 +0930

    PR22216, infinite loop in readelf process_symbol_table
    
    This should make readelf bombproof given a fuzzed DT_HASH.  Also
    removes a bogus check that would have resulted in wrong histograms.
    
    	PR 22216
    	* readelf.c (process_symbol_table): Check that DT_HASH symbol
    	chains are only visited once, and report an error if not.  Display
    	invalid symbol index if chain is out of range.  Use the same logic
    	when calculating histograms rather than the PR 17531 fix.  Delete
    	bogus check that chained index is less than number of buckets.

commit cd28e7aaf35f7de5033ecd619b56064136bb190b
Author: Kuan-Lin Chen <kuanlinchentw@gmail.com>
Date:   Wed Sep 27 13:04:35 2017 +0800

    nds32: Fix a tautological comparison.

commit 25c7861f70b2fcde6c4e3454c269da20ff141883
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Sep 27 00:00:23 2017 +0000

    Automatic date update in version.in

commit ac69a0d75bf472a140e5405c8a90420d5f63a998
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Sep 26 14:41:22 2017 -0700

    x86-64: Don't pass output_bfd to info->callbacks->minfo
    
    Don't pass output_bfd to info->callbacks->minfo when dumping local IFUNC
    functions in the map file.
    
    	PR ld/22199
    	* elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Don't pass
    	output_bfd to info->callbacks->minfo.

commit 5230b05a94b964da335a0758686b92a8efcc823d
Author: Walfred Tedeschi <walfred.tedeschi@intel.com>
Date:   Tue Sep 26 18:26:41 2017 +0100

    dwarf2read: Restrict ICC workaround to ICC<14
    
    GDB has a workaround for DWARF output by ICC, related to missing
    DW_AT_declaration on incomplete types.  The bug was fixed in ICC 14,
    so this commit adjusts GDB accordingly.
    
    For the version check, this adds a new parser function for the ICC
    producer string.  While at it, it also adds unit tests for the
    producer parsing covering the new function and preexisting parsers.
    
    gdb/ChangeLog:
    2017-09-26  Walfred Tedeschi  <walfred.tedeschi@intel.com>
    	    Pedro Alves <palves@redhat.com>
    
    	* dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
    	producer_is_icc_lt_14.
    	(producer_is_icc_lt_14): New function.
    	(check_producer): Add code for checking version of ICC.
    	(producer_is_icc): Move to producer.c.
    	(read_structure_type): Restrict ICC workaround to ICC<14.
    	* producer.c: Include selftest.h.
    	(producer_is_icc, producer_parsing_tests, _initialize_producer):
    	New functions.
    	* producer.h (producer_is_icc): New declaration.

commit b32b108aba2c0119d0e231d203d3284539da2379
Author: Walfred Tedeschi <walfred.tedeschi@intel.com>
Date:   Tue Sep 26 18:26:41 2017 +0100

    Move GDB producer parsing routines to a separate file
    
    gdb/ChangeLog:
    2017-09-26  Walfred Tedeschi  <walfred.tedeschi@intel.com>
    
    	* Makefile.in (SFILES): Add producer.c.
    	(COMMON_OBS): Add producer.o
    	* amd64-tdep.c (producer.h): Add new include.
    	* dwarf2read.c (producer.h): Add new include.
    	* producer.c: New file.
    	* producer.h: New file.
    	* utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
    	producer.c.
    	* utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
    	producer.h.

commit 75352e283fb2b265d14c750859156943f6eb2693
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Sep 15 00:27:53 2017 -0400

    Use "switch_to_thread" more thoroughly on gdbserver
    
    This is a technical debt that I left when I ported "switch_to_thread"
    to gdbserver.  It's a simple patch that converts occurences of:
    
      current_thread = find_thread_ptid (ptid);
    
    to:
    
      switch_to_thread (ptid);
    
    This patch also converts a simple "if" to a "gdb_assert" on
    gdbserver's version of "switch_to_thread":
    
      gdb_assert (ptid != minus_one_ptid);
    
    This change makes the code more similar to what GDB already does.
    
    Regtested on BuildBot.
    
    gdb/gdbserver/ChangeLog:
    2017-09-26  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdbthread.h: Include "common-gdbthread.h".
    	* inferiors.c (switch_to_thread): Use "gdb_assert" instead of
    	"if" when validating the ptid.
    	* remote-utils.c: Include "gdbthread.h".
    	(prepare_resume_reply): Use "switch_to_thread".
    	* target.c (done_accessing_memory): Likewise.

commit 5007d765ae09c10c7f3b18bb16841b9d2d59e181
Author: Matthias Klose <doko@ubuntu.com>
Date:   Tue Sep 26 16:23:19 2017 +0100

    Allow linking GDB with ncursesw
    
    Triggered by https://launchpad.net/bugs/1275210, to be able to cope
    with UTF-8 characters in gdbtui.
    
    Reference:
      https://sourceware.org/ml/gdb-patches/2017-09/msg00356.html
    
    gdb/ChangeLog:
    2017-09-26  Matthias Klose  <doko@ubuntu.com>
    
    	* configure.ac: Search ncursesw before ncurses.
    	Check ncursesw/ncurses.h before ncurses/ncurses.h.
    	* gdb_curses.h: Include <ncursesw/ncurses.h>
    	* config.in, configure: Regenerate.

commit 262c0a877f91b9102fd42523598b46ea79a8970e
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 26 16:03:10 2017 +0100

    Fix an assertion failure when parsing a fuzzed x86_64 ELF binary.
    
    	PR 22172
    	* elf64-x86-64.c (elf_x86_64_info_to_howto): Do not trigger an
    	assertion failure if elf_x86_64_rtype_to_howto has already issued
    	an error message.

commit 00956d3a8ab1b56fcdf63aee4ed5c5a1d46a7a48
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Tue Sep 26 07:33:04 2017 -0700

    Fix incorrect register mask.
    
    	PR gold/22213
    	* sparc.cc (Target_sparc): Fix incorrect register mask.

commit 33e0a9a056bd23e923b929a4f2ab049ade0b1c32
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 26 23:20:06 2017 +0930

    Tidy reading data in read_formatted_entries
    
    Using read_attribute_value accomplishes two things: It checks for
    unexpected formats, and ensures the buffer pointer always increments.
    
    	PR 22210
    	* dwarf2.c (read_formatted_entries): Use read_attribute_value to
    	read data.

commit 30d0157a2ad64e64e5ff9fcc0dbe78a3e682f573
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 26 14:37:47 2017 +0100

    Avoid needless resource usage when processing a corrupt DWARF directory or file name table.
    
    	PR 22210
    	* dwarf2.c (read_formatted_entries): Fail early if we know that
    	the loop parsing data entries will overflow the end of the
    	section.

commit 281c4447738409888d9659924937da182a65b4e1
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date:   Tue Sep 26 15:19:10 2017 +0200

    Remove support for Solaris < 10 (PR gdb/22185)
    
    Given that GCC has obsoleted/removed support for Solaris 9 in GCC 4.9/5 in 2013:
    
        https://gcc.gnu.org/gcc-4.9/changes.html
        https://gcc.gnu.org/ml/gcc-patches/2013-05/msg00728.html
    
    and the last gdb version that can be compiled with gcc 4.9 is 7.12.1 only when
    configured with --disable-build-with-cxx, it's time to obsolete/remove support
    for Solaris < 10.
    
    This patch does this, simplifying configure.nat along the way (only a single
    sol2 configuration with variants for i386 and sparc).
    
    Some configure checks for older Solaris versions can go, too, and the check
    for libthread_db.so.1 removed:
    
    * Since Solaris 10, dlopen has moved to libc and libdl.so is just a
      filter on ld.so.1, so no need to check.
    
    * $RDYNAMIC is already handled above (and is a no-op with Solaris ld
      anyway).
    
    Both proc-service.c and sol-thread.c lose support for (Solaris-only)
    PROC_SERVICE_IS_OLD.
    
    The attached revised patch has been tested on sparcv9-sun-solaris2.10,
    sparcv9-sun-solaris2.11.4, amd64-pc-solaris2.10, amd64-pc-solaris2.11.4,
    and x86_64-pc-linux-gnu.
    
    I've also started an i386-pc-solaris2.9 build to check that it really
    stops as expected.
    
    	PR gdb/22185
    	* configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
    	obsolete.
    	Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
    	Remove i386sol2 support.
    	* configure.nat <i386sol2>: Remove.
    	<sol2-64>: Fold into ...
    	<sol2>: ... this.
    	Move common settings to default section.
    	Add sol-thread.o.
    	* configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
    	x86_64-*-solaris2.1[0-9]*>: Rename to ...
    	<i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
    	<i[34567]86-*-solaris*>: Remove.
    	<sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
    
    	* configure.ac: Remove wctype in libw check.
    	(_MSE_INT_H): Don't define on Solaris 7-9.
    	<solaris*>: Remove libthread_db.so.1 check.
    	* configure: Regenerate.
    	* config.in: Regenerate.
    
    	* proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
    	(gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
    	(gdb_ps_size_t): Remove.
    	Use base types in users.
    	* sol-thread.c: Likewise, also for gdb_ps_addr_t.
    
    	* NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.

commit 39b06c208fb7b7edb98866252cbd05ba0918f666
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date:   Tue Sep 26 14:58:53 2017 +0200

    Fix gdb 8.1 Solaris/SPARC compilation (PR build/22206)
    
    When testing my Solaris < 10 removal patch on Solaris/SPARC, I found
    that gdb mainline is currently broken there due to the recent SPARC M7
    ADI patches:
    
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:1876:0: error: "PSR_ICC" redefined [-Werror]
     #define PSR_ICC  0x00f00000
     ^
    In file included from /usr/include/v7/sys/privregs.h:24:0,
                     from /usr/include/sys/regset.h:420,
                     from /usr/include/sys/ucontext.h:21,
                     from /usr/include/sys/signal.h:231,
                     from /usr/include/sys/procset.h:23,
                     from /usr/include/sys/wait.h:25,
                     from /usr/include/stdlib.h:21,
                     from build-gnulib/import/stdlib.h:36,
                     from /vol/src/gnu/gdb/gdb/local/gdb/common/common-defs.h:53,
                     from /vol/src/gnu/gdb/gdb/local/gdb/defs.h:28,
                     from /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:20:
    /usr/include/v7/sys/psr.h:35:0: note: this is the location of the previous definition
     #define PSR_ICC  0x00F00000 /* integer condition codes */
     ^
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:1878:0: error: "PSR_IMPL" redefined [-Werror]
     #define PSR_IMPL 0xf0000000
     ^
    In file included from /usr/include/v7/sys/privregs.h:24:0,
                     from /usr/include/sys/regset.h:420,
                     from /usr/include/sys/ucontext.h:21,
                     from /usr/include/sys/signal.h:231,
                     from /usr/include/sys/procset.h:23,
                     from /usr/include/sys/wait.h:25,
                     from /usr/include/stdlib.h:21,
                     from build-gnulib/import/stdlib.h:36,
                     from /vol/src/gnu/gdb/gdb/local/gdb/common/common-defs.h:53,
                     from /vol/src/gnu/gdb/gdb/local/gdb/defs.h:28,
                     from /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:20:
    /usr/include/v7/sys/psr.h:41:0: note: this is the location of the previous definition
     #define PSR_IMPL 0xF0000000 /* implementation */
     ^
    
    Comparing Solaris 11.4 <v7/sys/psr.h> and sparc64-tdep.c, there are more
    inconsistencies:
    
    <v7/sys/psr.h>:
    
    #define	PSR_S		0x00000080	/* supervisor mode */
    #define	PSR_ICC		0x00F00000	/* integer condition codes */
    #define	PSR_VER		0x0F000000	/* mask version */
    #define	PSR_IMPL	0xF0000000	/* implementation */
    #define	PSR_RSV		0x000FC000	/* reserved */
    
    sparc64-tdep.c:
    
    #define PSR_S		0x00000080
    #define PSR_ICC		0x00f00000
    #define PSR_VERS	0x0f000000
    #define PSR_IMPL	0xf0000000
    #define PSR_V8PLUS	0xff000000
    #define PSR_XCC		0x000f0000
    
    Apart from the capitalization differences that trip g++, the names
    differ (PSR_VER vs. PSR_VERS), PSR_XCC is included in Solaris' PSR_RSV,
    and there's no PSR_V8PLUS on Solaris either.
    
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c: In function `int adi_tag_fd()':
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:296:63: error: format `%d' expects argument of type `int', but argument 4 has type `pid_t {aka long int}' [-Werror=format=]
       snprintf (cl_name, sizeof(cl_name), "/proc/%d/adi/tags", pid);
                                                                   ^
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c: In function `bool adi_is_addr_mapped(CORE_ADDR, std::size_t)':
    /vol/src/gnu/gdb/gdb/local/gdb/sparc64-tdep.c:314:64: error: format `%d' expects argument of type `int', but argument 4 has type `pid_t {aka long int}' [-Werror=format=]
       snprintf (filename, sizeof filename, "/proc/%d/adi/maps", pid);
                                                                    ^
    
    You cannot always print a pid_t, which can be either int or long on
    Solaris, as an int.
    
    Obviously, the ADI patch which modifies code shared between all SPARC
    targets, hasn't been tested on anything but Linux/SPARC.
    
    The patch below includes the minimal fixes necessary to unbreak the
    Solaris/SPARC build.
    
    However, as detailed in the PR, there's more breakage here: apart from
    not bothering to implement ADI support on Solaris, the code contains
    several more changes to shared/common SPARC code that are simply wrong
    on anything but Linux/SPARC.
    
    The patch was tested on sparcv9-sun-solaris2.10 and
    sparcv9-sun-solaris2.11.4 (build and gdb/gdb gdb/gdb smoke test only).
    
    	PR build/22206
    	* sparc64-tdep.c (adi_tag_fd): Print pid as long.
    	(adi_is_addr_mapped): Likewise.
    	(PSR_ICC): Don't redefine.
    	(PSR_IMPL): Likewise.

commit 1b86808a86077722ee4f42ff97f836b12420bb2a
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 26 21:47:24 2017 +0930

    PR22209, invalid memory read in find_abstract_instance_name
    
    This patch adds bounds checking for DW_FORM_ref_addr die refs, and
    calculates them relative to the first .debug_info section.  See the
    big comment for why calculating relative to the current .debug_info
    section was wrong for relocatable object files.
    
    	PR 22209
    	* dwarf2.c (struct comp_unit): Delete sec_info_ptr field.
    	(find_abstract_instance_name): Calculate DW_FORM_ref_addr relative
    	to stash->info_ptr_memory, and check die_ref is within that memory.
    	Set info_ptr_end correctly when another CU is refd.  Check die_ref
    	for DW_FORM_ref4 etc. is within CU.

commit 5c1c468d0eddd0fda1ec8c5f33888657f94e3266
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 26 12:14:42 2017 +0100

    Fix address violations when parsing a corrupt DWARF linenumber table.
    
    	PR 22154
    	* dwarf.c (get_line_filename_and_dirname): Add extra checks for
    	buffer overruns.

commit 28d810f7ffd7fefd88117e9d830e7588591fd35c
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Sep 26 12:09:50 2017 +0100

    LD/testsuite: Fix undefined symbol tests for MIPS and S+core targets
    
    Fix commit 647d4de92e06 ("Test undefined symbols in shared libraries")
    and remove "undefined symbols in shared lib (dyn reloc)" test failures
    for MIPS and S+core targets.
    
    This test assumes 3 dynamic relocation entries, however the respective
    psABIs define an extra single dummy *_NONE relocation at the beginning
    of the dynamic relocation table, which results in test output like the
    following for MIPS:
    
    Relocation section '.rel.dyn' at offset 0x33c contains 4 entries:
     Offset     Info    Type            Sym.Value  Sym. Name
    00000000  00000000 R_MIPS_NONE
    00010364  00000903 R_MIPS_REL32      00000000   undef_pfun
    00010360  00000a03 R_MIPS_REL32      00000000   undef_data
    00010368  00000b03 R_MIPS_REL32      00000000   undef_notype
    
    and S+core:
    
    Relocation section '.rel.dyn' at offset 0x274 contains 4 entries:
     Offset     Info    Type            Sym.Value  Sym. Name
    00000000  00000000 R_SCORE_NONE
    5ffe0464  00000e12 R_SCORE_REL32     00000000   undef_notype
    5ffe045c  00000f12 R_SCORE_REL32     00000000   undef_data
    5ffe0460  00001012 R_SCORE_REL32     00000000   undef_pfun
    
    targets respectively, and also n64 MIPS targets pad relocation triplets
    they use with extra *_NONE relocations, resulting in output like this:
    
    Relocation section '.rel.dyn' at offset 0x4c0 contains 4 entries:
      Offset          Info           Type           Sym. Value    Sym. Name
    000000000000  000000000000 R_MIPS_NONE
                        Type2: R_MIPS_NONE
                        Type3: R_MIPS_NONE
    000000010508  000900001203 R_MIPS_REL32      0000000000000000 undef_pfun
                        Type2: R_MIPS_64
                        Type3: R_MIPS_NONE
    000000010500  000a00001203 R_MIPS_REL32      0000000000000000 undef_data
                        Type2: R_MIPS_64
                        Type3: R_MIPS_NONE
    000000010510  000b00001203 R_MIPS_REL32      0000000000000000 undef_notype
                        Type2: R_MIPS_64
                        Type3: R_MIPS_NONE
    
    Expect the right number of *_NONE relocations then, and adjust the total
    number of relocations expected accordingly.
    
    	ld/
    	* testsuite/ld-undefined/undefined.exp: Correct the dyn reloc
    	test for MIPS and S+core targets.

commit 58a0b827444d0d6baad47f5fd010f33e541ed16e
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 26 10:33:32 2017 +0100

    Allow the macw and macl instructions to be used on CPUs that have emacs support.
    
    From PR 22123:
    
      The common opcodes of emac and mac seem to be only implemented for mac.
    
      To reproduce:
    
        echo "macw %d3l,%a0l" > /tmp/dummy.S
        m68k-unknown-elf-as -m5208  /tmp/dummy.S
    
      Outputs something like:
        /tmp/dummy.S: Assembler messages:
        /tmp/dummy.S:1: Error: operands mismatch -- statement `macw %d3l,%a0l' ignored
    
      This behavior occurs only if the CPU supports only emac but not explicitly mac (but emac is a superset of mac).

commit 78b2179a8e085b34ad7872450e5fadff4f7e5eb0
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 26 10:07:23 2017 +0100

    Add README file for creating binutils releases

commit df8899e5c8b60ffbbe93e35315ebb76a9c80ee37
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Tue Sep 26 09:57:18 2017 +0100

    Fix FAILs in compare-sections.exp
    
    compare-sections.exp has two cases that are not handled appropriately:
    1) value read with msb set
    2) error while patching that section
    
    This patch adapts the "get value of read-only section" test to print
    the value as an unsigned integer to fix 1) and test for the error
    message to not set the written variable if read-only section cannot
    be written to so as to solve 2).
    
    2017-09-26  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    	    Pedro Alves  <palves@redhat.com>
    
    gdb/testsuite/
    	* gdb.base/compare-sections.exp (get value of read-only section): Read
    	as unsigned value.
    	(corrupt read-only section): Likewise and don't set written if patching
    	failed.

commit 66cfc0fd0d9daadc2dac5a783b69b4050c0b1722
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 26 11:28:04 2017 +0930

    PR21732, String-concatenated message can not be translated
    
    Preprocessor tokens like DWARF_VMA_FMT and BFD_VMA_FMT are not
    understood by gettext, and cause the translation string to be
    truncated.  Even if it were not truncated, we wouldn't want a value
    that changes depending on host or configure options to be put in a
    translation string.
    
    	PR 21732
    	* dwarf.c (READ_ULEB): Don't use DWARF_VMA_FMT in translated string.
    	(READ_SLEB): Likewise.
    	* readelf.c (bfd_vmatoa): New function.
    	(get_data, get_dynamic_data): Use it for printing error messages.

commit 6c3e20f177102519cf4f8b3c7e7e17996ed7cd7f
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 15:54:36 2017 -0600

    Remove the last cleanup from regcache.c
    
    This removes the last cleanup from regcache.c by changing one function
    to use std::string.
    
    gdb/ChangeLog
    2017-09-25  Tom Tromey  <tom@tromey.com>
    
    	* regcache.c (regcache::dump): Use string_printf.

commit b292235f666ff2123e26794db73d5a27a685e7be
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 15:53:30 2017 -0600

    Remove make_cleanup_regcache_invalidate
    
    This removes make_cleanup_regcache_invalidate in favor of a simple
    RAII class that handles register invalidation.
    
    gdb/ChangeLog
    2017-09-25  Tom Tromey  <tom@tromey.com>
    
    	* regcache.c (class regcache_invalidator): New.
    	(struct register_to_invalidate): Remove.
    	(make_cleanup_regcache_invalidate): Remove.
    	(regcache::raw_write): Use regcache_invalidator.

commit 9ac86b52da268147b2565e4920357432bb7a34c3
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 15:34:30 2017 -0600

    Remove make_cleanup_regcache_xfree
    
    This removes make_cleanup_regcache_xfree in favor of using
    std::unique_ptr as the return type of frame_save_as_regcache.
    
    gdb/ChangeLog
    2017-09-25  Tom Tromey  <tom@tromey.com>
    
    	* spu-tdep.c (spu2ppu_sniffer): Update.
    	* regcache.h (make_cleanup_regcache_xfree): Don't declare.
    	* regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
    	Remove.
    	* ppc-linux-tdep.c (ppu2spu_sniffer): Update.
    	* mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
    	* frame.h (frame_save_as_regcache): Return std::unique_ptr.
    	* frame.c (frame_save_as_regcache): Return std::unique_ptr.
    	(frame_pop): Update.

commit c0e383c63818baee1daf51b8fb1bae34d1e0597f
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 14:41:07 2017 -0600

    Remove regcache_xfree
    
    This removes regcache_xfree in favor of plain "delete".
    
    gdb/ChangeLog
    2017-09-25  Tom Tromey  <tom@tromey.com>
    
    	* spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
    	* regcache.h (regcache_xfree): Don't declare.
    	* regcache.c (regcache_xfree): Remove.
    	(do_regcache_xfree): Use delete.
    	* ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
    	* linux-fork.c (free_fork): Use delete.
    	(fork_save_infrun_state): Likewise.
    	* jit.c (jit_dealloc_cache): Use delete.
    	* infrun.c (discard_infcall_suspend_state): Use delete.

commit 791199cc75fd294a4f5a228f83abdcbfb4c64c7e
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 14:39:56 2017 -0600

    Remove regcache_xmalloc
    
    This patch removes regcache_xmalloc in favor of plain "new".
    
    gdb/ChangeLog
    2017-09-25  Tom Tromey  <tom@tromey.com>
    
    	* regcache.h (regcache_xmalloc): Don't declare.
    	(regcache_raw_set_cached_value): Update comment.
    	* regcache.c (regcache_xmalloc): Remove.
    	* ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
    	* jit.c (jit_frame_sniffer): Use new.
    	* frame.c (frame_save_as_regcache): Use new.

commit a54018b72d75abf2e74bf36016702da06399c1d9
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 26 09:38:26 2017 +0930

    PR22205, .debug_line file table NULL filename
    
    The PR22200 fuzzer testcase found one way to put NULLs into .debug_line
    file tables.  PR22205 finds another.  This patch gives up on trying to
    prevent NULL files in the file table and instead just copes with them.
    Arguably, this is better than giving up and showing no info from
    .debug_line.  I've also fixed a case where the fairly recent DWARF5
    support in handling broken DWARG could result in uninitialized memory
    reads, and made a small tidy.
    
    	PR 22205
    	* dwarf2.c (concat_filename): Return "<unknown>" on NULL filename.
    	(read_formatted_entries): Init "fe".
    	(decode_line_info <DW_LNE_define_file>): Use line_info_add_file_name.

commit e338894dc2e603683bed2172e8e9f25b29051005
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 26 09:32:18 2017 +0930

    PR22204, Lack of DW_LNE_end_sequence causes "infinite" loop
    
    	PR 22204
    	* dwarf2.c (decode_line_info): Ensure line_ptr stays within
    	bounds in inner loop.

commit 898f57a89f3f75d542892c891e0736a8d91f42d3
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Sep 26 00:00:21 2017 +0000

    Automatic date update in version.in

commit 8dba52b60488265e66073130ef77c03f05dcaabc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Sep 25 14:07:01 2017 -0700

    Free memory returned from bfd_get_synthetic_symtab
    
    	PR binutils/22203
    	* nm.c (display_rel_file): Free memory returned from
    	bfd_get_synthetic_symtab.

commit 289e23aa03084b22c73ebdcf18371f1e6666ead0
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Sep 25 16:02:24 2017 +0200

    S390: Document guarded-storage register support
    
    This documents the newly added support for guarded-storage registers on
    IBM z.
    
    gdb/ChangeLog:
    
    	* NEWS: Advertise support for guarded-storage registers on IBM z.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (S/390 and System z Features): Document the new
    	features org.gnu.gdb.s390.gs and org.gnu.gdb.s390.gsbc.

commit ad3396348e0ebb61fdf71cff307bac08175ed366
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Sep 25 16:02:23 2017 +0200

    S390: Add guarded-storage register support to gdbserver
    
    Enable gdbserver to deal with the new guarded-storage register sets.
    
    gdb/gdbserver/ChangeLog:
    
    	* configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
    	s390x-gs-linux64.o to srv_regobj.  Add s390-gs-linux64.xml,
    	s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
    	srv_xmlfiles.  Add s390-gs-linux64-ipa.o and
    	s390x-gs-linux64-ipa.o to ipa_obj.
    	* linux-s390-low.c (HWCAP_S390_GS): New define.
    	(s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
    	New functions.
    	(s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
    	(s390_arch_setup): Check for guarded-storage support and choose
    	appropriate tdesc.
    	(initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
    	init_registers_s390x_gs_linux64.
    	* linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
    	enum value.
    	(init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
    	(init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.

commit 1b63490c9173f8c9770b7885def720516aa9b9f8
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Sep 25 16:02:23 2017 +0200

    S390: Add guarded-storage register support to GDB
    
    Recognize targets with the new guarded-storage feature and then present
    the guarded-storage registers and the Linux-specific guarded-storage
    broadcast control block appropriately.
    
    gdb/ChangeLog:
    
    	* s390-linux-nat.c (have_regset_gs): New static variable.
    	(s390_linux_fetch_inferior_registers): Handle guarded-storage
    	control block and guarded-storage broadcast control regsets.
    	(s390_read_description): Detect whether the target has
    	guarded-storage support, return appropriate tdesc.
    	* s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
    	(features/s390x-gs-linux64.c): Likewise.
    	(struct gdbarch_tdep) <have_gs>: New field.
    	(s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
    	(s390_gsbc_regset): New variables.
    	(s390_iterate_over_regset_sections): Iterate over s390_gs_regset
    	and s390_gsbc_regset, if applicable.
    	(s390_core_read_description): Check whether core file was from a
    	target with guarded-storage support; include appropriate regsets.
    	(s390_gdbarch_init): Add registers for guarded-storage support.
    	(_initialize_s390_tdep): Initialize new target descriptions that
    	include registers for guarded-storage support.
    	* s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
    	(S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
    	(S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
    	(S390_NUM_REGS): Adjust macro definition.
    	(s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
    	(tdesc_s390x_gs_linux64): New declarations.

commit 96235dc1ac3730c4e490d19db2e8287c0a40f307
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Sep 25 16:02:23 2017 +0200

    S390: Add guarded-storage register definitions and tdescs
    
    Newer Linux kernel versions offer two new register sets in support of the
    z/Architecture's guarded storage facility.  This patch adds XML
    descriptions and the respective autogenerated .c and .dat files for
    s390/s390x targets with this feature.
    
    gdb/ChangeLog:
    
    	* features/s390-gs-linux64.xml: New file.
    	* features/s390-gs.xml: New file.
    	* features/s390-gsbc.xml: New file.
    	* features/s390x-gs-linux64.xml: New file.
    	* features/Makefile (WHICH): Add s390-gs-linux64 and
    	s390x-gs-linux64.
    	(s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
    	(XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
    	* features/s390-gs-linux64.c: New generated file.
    	* features/s390x-gs-linux64.c: New file.
    	* regformats/s390-gs-linux64.dat: New file.
    	* regformats/s390x-gs-linux64.dat: New file.

commit 1da5c9a485f3dcac4c45e96ef4b7dae5948314b5
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Sep 25 20:20:38 2017 +0930

    PR22202, buffer overflow in parse_die
    
    There was a complete lack of sanity checking in dwarf1.c
    
    	PR 22202
    	* dwarf1.c (parse_die): Sanity check pointer against section limit
    	before dereferencing.
    	(parse_line_table): Likewise.

commit 11855d8a1f11b102a702ab76e95b22082cccf2f8
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Sep 25 19:46:34 2017 +0930

    PR22201, DW_AT_name with out of bounds reference
    
    DW_AT_name ought to always have a string value.
    
    	PR 22201
    	* dwarf2.c (scan_unit_for_symbols): Ignore DW_AT_name unless it
    	has string form.
    	(parse_comp_unit): Likewise.

commit c361faae8d964db951b7100cada4dcdc983df1bf
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Sep 25 19:03:46 2017 +0930

    PR22200, DWARF5 .debug_line sanity check
    
    The format_count entry can't be zero unless the count is also zero.
    
    	PR 22200
    	* dwarf2.c (read_formatted_entries): Error on format_count zero.

commit 57a024f4650d7562e963efb6b00c4a4cd74185c4
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Thu Sep 21 11:46:48 2017 -0400

    Initialize 'imm' on opcodes/aarch64-opc.c:expand_fp_imm (and fix breakage on mingw)
    
    Hi,
    
    While compiling GDB using a mingw compiler from Fedora 26:
    
      ../gdb/configure --host=x86_64-w64-mingw32 --target=x86_64-w64-mingw32 \
        --disable-binutils --disable-ld --disable-gold --disable-gas --disable-sim \
        --disable-gprof  --enable-targets=all
    
    I stumbled upon a simple occurrence of -Werror=maybe-uninitialized:
    
      ../../gdb/opcodes/aarch64-opc.c: In function 'expand_fp_imm':
      ../../gdb/opcodes/aarch64-opc.c:2880:10: error: 'imm' may be used uninitialized in this function [-Werror=maybe-uninitialized]
         return imm;
    	    ^~~
    
    It is the compiler's fault, because this function always assigns to
    'imm' if the necessary conditions are met, and it calls "assert (0)"
    otherwise, but I thought it'd be clearer to have 'imm' explicitly set
    to zero anyway.
    
    opcodes/ChangeLog:
    2017-09-21  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* aarch64-opc.c (expand_fp_imm): Initialize 'imm'.

commit 5b3fd0aac2b70d860ba34f0e290d87773b09bd11
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Sep 25 00:00:24 2017 +0000

    Automatic date update in version.in

commit 52b36c51e5bf6d7600fdc6ba115b170b0e78e31d
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 21:36:18 2017 +0930

    PR22197, buffer overflow in bfd_get_debug_link_info_1
    
    	PR 22197
    	* opncls.c (bfd_get_debug_link_info_1): Properly check that crc is
    	within section bounds.

commit a26a013f22a19e2c16729e64f40ef8a7dfcc086e
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 17:10:14 2017 +0930

    PR22191, memory leak in dwarf2.c
    
    table->sequences is a linked list before it is replaced by a bfd_alloc
    array in sort_line_sequences.
    
    	PR 22191
    	* dwarf2.c (decode_line_info): Properly free line sequences on error.

commit 52a93b95ec0771c97e26f0bb28630a271a667bd2
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 14:37:16 2017 +0930

    PR22187, infinite loop in find_abstract_instance_name
    
    This patch prevents the simple case of infinite recursion in
    find_abstract_instance_name by ensuring that the attributes being
    processed are not the same as the previous call.
    
    The patch also does a little cleanup, and leaves in place some changes
    to the nested_funcs array that I made when I wrongly thought looping
    might occur in scan_unit_for_symbols.
    
    	PR 22187
    	* dwarf2.c (find_abstract_instance_name): Add orig_info_ptr and
    	pname param.  Return status.  Make name const.  Don't abort,
    	return an error.  Formatting.  Exit if current info_ptr matches
    	orig_info_ptr.  Update callers.
    	(scan_unit_for_symbols): Start at nesting_level of zero.  Make
    	nested_funcs an array of structs for extensibility.  Formatting.

commit d8010d3e75ec7194a4703774090b27486b742d48
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 14:36:48 2017 +0930

    PR22186, divide-by-zero in decode_line_info
    
    	PR 22186
    	* dwarf2.c (decode_line_info): Fail on lh.line_range of zero
    	rather than dividing by zero.

commit 515f23e63c0074ab531bc954f84ca40c6281a724
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 14:36:16 2017 +0930

    PR22169, heap-based buffer overflow in read_1_byte
    
    The .debug_line header length field doesn't include the length field
    itself, ie. it's the size of the rest of .debug_line.
    
    	PR 22169
    	* dwarf2.c (decode_line_info): Correct .debug_line unit_length check.

commit 0d76029f92182c3682d8be2c833d45bc9a2068fe
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 14:35:33 2017 +0930

    PR22167, NULL pointer dereference in scan_unit_for_symbols
    
    	PR 22167
    	* dwarf2.c (scan_unit_for_symbols): Check u.blk->data is non-NULL.

commit bd61e135492ecf624880e6b78e5fcde3c9716df6
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 24 14:34:57 2017 +0930

    PR22166, SHT_GNU_verneed memory allocation
    
    The sanity check covers the previous minimim size, plus that the size
    is at least enough for sh_info verneed entries.
    
    Also, since we write all verneed fields or exit with an error, there
    isn't any need to zero the memory allocated for verneed entries.
    
    	PR 22166
    	* elf.c (_bfd_elf_slurp_version_tables): Test sh_info on
    	SHT_GNU_verneed section for sanity.  Don't zalloc memory for
    	verref.

commit 8d296e2d4d8ed6ffbe29bb8cc6548a3871de6ad1
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Sep 24 00:00:26 2017 +0000

    Automatic date update in version.in

commit b4a7c699688bd88313893cbb59ee0df5b8cd009b
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 23 14:00:21 2017 -0600

    Removed unused declaration
    
    An earlier patch of mine removed make_cleanup_override_quit_handler,
    but neglected to remove the declaration.  This patch removes it.
    Tested by rebuilding.  I'm committing this as obvious.
    
    ChangeLog
    2017-09-23  Tom Tromey  <tom@tromey.com>
    
    	* defs.h (make_cleanup_override_quit_handler): Don't declare.

commit 4102159923c90abd636d73e78777b98b1c680e53
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Sep 23 00:00:27 2017 +0000

    Automatic date update in version.in

commit c2f97536b77f9d9531a1a2c37008b454eb67a82e
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Sep 21 09:54:25 2017 -0600

    Change type of scoped_input_handler::m_quit_handler
    
    Simon pointed out that scoped_input_handler::m_quit_handler must have
    the correct scoped_restore_tmpl type, to avoid binding to a temporary.
    This patch fixes the problem.
    
    gdb/ChangeLog
    2017-09-22  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (class scoped_input_handler) <m_quit_handler>: Change
    	type to scoped_restore_tmpl.
    	<scoped_input_handler>: Initialize m_quit_handler directly.
    
    Reviewed-By: Pedro Alves <palves@redhat.com>

commit 61e3bf5f83f7e505b6bc51ef65426e5b31e6e360
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 22 14:15:40 2017 -0700

    x86: Guard against corrupted PLT
    
    There should be only one entry in PLT for a given symbol.  Set howto to
    NULL after processing a PLT entry to guard against corrupted PLT so that
    the duplicated PLT entries are skipped.
    
    	PR binutils/22170
    	* elfxx-x86.c (_bfd_x86_elf_get_synthetic_symtab): Guard against
    	corrupted PLT.

commit 59ca4c1bbd48a47073eed2c4b933045674cafe41
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 22 14:09:56 2017 -0700

    Update ChangeLog entry for PR 22163

commit 9f272209118972864b2c3799ddf2b39683c1a7b7
Author: Alexandre Oliva <aoliva@redhat.com>
Date:   Fri Sep 22 17:05:51 2017 -0300

    LVU: dump loclists with locviews
    
    When dumping location lists, also dump locview lists that may be
    interspersed with them, and bring view pairs next to the corresponding
    location list entries.
    
    This patch supports DW_AT_GNU_locviews as a separate attribute for
    DWARF4- loc_lists and split (dwo) loclists, as well as DWARF5
    loclists.
    
    It also supports, in DWARF5 loclists, the proposed
    DW_LLE_GNU_view_pair loclist entry type proposed for DWARF6.
    
    
    The tests use 32-bit DWARF, even on 64-bit targets, resolving offsets
    to constants so as to reduce the risk that relocations be created for
    them, or that the offsets be rejected as nonconstants.
    
    
    The patch also adds an xfail to an unrelated test, namely dw5, so that
    no unexpected fails remain on nds32*-elf, one of the tested targets.
    
    
    Reviewed-by: Alan Modra <amodra@gmail.com>
    
    
    for  include/ChangeLog
    
    	* dwarf2.def (DW_AT_GNU_locviews): New.
    	* dwarf2.h (enum dwarf_location_list_entry_type): Add
    	DW_LLE_GNU_view_pair.
    	(DW_LLE_view_pair): Define.
    
    for  binutils/ChangeLog
    
    	* dwarf.h (debug_info): Add loc_views and num_loc_views.
    	* dwarf.c (vm1): New constant.
    	(print_dwarf_view): New function.
    	(read_and_display_attr_value): Support DW_AT_GNU_locviews.
    	(process_debug_info): Keep num_loc_offsets and num_loc_views
    	in sync.
    	(display_view_pair_list): New function.
    	(display_loc_list_dwo): Take vstart_ptr; update it.  Dump
    	location view pairs before the range they apply to, when a
    	viewlist augments the loc list.
    	(display_loc_list): Likewise.  Check view numbers in range
    	tests.
    	(display_loclists_list): Likewise.  Handle view pair entries,
    	and warn on trailing ones.
    	(loc_views): New variable.
    	(loc_offsets_compar): Compare loc_views if loc_offsets are the
    	same.
    	(display_debug_loc): Check and sort loc_views too.  Accept
    	loc_view as expected_start.  Skip if lists and views are the
    	same.  Dump locview list separately in order, and pass the
    	locview list base to each list dump function.  Warn and skip
    	overlap and hole checking if we find loclists and locviews to
    	not be adjacent.
    	* testsuite/binutils-all/locview-1.s: New.
    	* testsuite/binutils-all/readelf.locview-1: New.
    	* testsuite/binutils-all/locview-2.s: New.
    	* testsuite/binutils-all/readelf.locview-2: New.
    	* testsuite/binutils-all/readelf.exp: Run new tests.  Fix
    	option spelling in pr18374 fail message.  XFAIL dw5 test on
    	nds32*-elf.

commit 43573013c9836f2b91b74b9b29dac35fdb41e06b
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Mon Sep 11 00:54:33 2017 -0400

    Get rid of "gdb_dirbuf" and use "getcwd (NULL, 0)"
    
    Currently we have "current_directory" and "gdb_dirbuf" globals, which
    means that we basically have two possible places to consult when we
    want to know GDB's current working directory.
    
    This is not ideal and can lead to confusion.  Moreover, the way we're
    using "gdb_difbuf" along with "getcwd" is problematic because we
    declare the buffer with "1024" elements hardcoded, which does not take
    into account longer pathnames that are possible in many filesystems.
    Using "PATH_MAX" would also not be a solution because of portability
    problems.  Therefore, the best solution is to rely on the fact that
    "getcwd (NULL, 0)" will "do the right thing" and return a
    heap-allocated string containing the full path.  With the new "getcwd"
    module from gnulib, it is now possible to do that without worrying
    about breaking some host.
    
    With this patch "current_directory" is now the only place to check for
    GDB's cwd.
    
    Reviewed-by: Pedro Alves <palves@redhat.com>
    
    gdb/ChangeLog:
    2017-09-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
    	(cd_command): Likewise.  Free "current_directory" before
    	assigning to it.
    	* main.c (captured_main_1): Use "getcwd (NULL, 0)".
    	* mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
    	* top.c (gdb_dirbuf): Remove global declaration.
    	* top.h (gdb_dirbuf): Likewise.

commit 6ec2e0f5bddc69d55e09fe56792edf7a109ff8ae
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Fri Sep 8 20:09:12 2017 -0400

    Import "glob" and "getcwd" modules from gnulib
    
    These two modules are necessary because of the rework that will be
    done in the "change directory" logic on GDB/gdbserver in the next
    commits.
    
    First, we will get rid of the "gdb_dirbuf" global variable and instead
    rely on the fact that "getcwd (NULL, 0)", which is a GNU extension,
    returns a heap-allocated string with the necessary bytes to hold the
    full path.  This is a good practice not only because globals are not
    ideal but also because there is no good way to know beforehand the
    size of the full pathname allowed in the filesystem ("PATH_MAX" is not
    portable and does not reflect all the possible filesystems out there).
    
    We will also have a way to "cd" to a directory also on gdbserver, but
    in order to do that uniformly, there must be a way to do tilde
    expansion on directories provided by the user.  Currently, GDB uses
    "tilde_expand" from readline to do that, but gdbserver doesn't link
    against readline and therefore cannot use this function.  The solution
    is to use "glob" instead, which can perform tilde expansion as a GNU
    extension.  Therefore, we need gnulib's version of "glob".
    
    A special note is necessary for gdb/ser-tcp.c.  It defines "close" as
    "closesocket" on Win32 targets.  If we leave the code as is, this
    would conflict with gnulib's definition of "close".  Therefore, in
    order to keep the same code path from before this import, I decided to
    "#undef close" first, and then let the original (re)definition of it
    take place.
    
    gdb/ChangeLog:
    2017-09-22  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gnulib/aclocal.m4: Regenerate.
    	* gnulib/config.in: Regenerate.
    	* gnulib/configure: Regenerate.
    	* gnulib/import/Makefile.am: Regenerate.
    	* gnulib/import/Makefile.in: Regenerate.
    	* gnulib/import/assure.h: New file.
    	* gnulib/import/at-func.c: Likewise
    	* gnulib/import/chdir-long.c: New file.
    	* gnulib/import/chdir-long.h: New file.
    	* gnulib/import/cloexec.c: New file.
    	* gnulib/import/cloexec.h: New file.
    	* gnulib/import/close.c: New file.
    	* gnulib/import/closedir.c: New file.
    	* gnulib/import/dirent-private.h: New file.
    	* gnulib/import/dup-safer.c: New file.
    	* gnulib/import/dup.c: New file.
    	* gnulib/import/dup2.c: New file.
    	* gnulib/import/error.c: New file.
    	* gnulib/import/error.h: New file.
    	* gnulib/import/exitfail.c: New file.
    	* gnulib/import/exitfail.h: New file.
    	* gnulib/import/fchdir.c: New file.
    	* gnulib/import/fcntl.c: New file.
    	* gnulib/import/fcntl.in.h: New file.
    	* gnulib/import/fd-hook.c: New file.
    	* gnulib/import/fd-hook.h: New file.
    	* gnulib/import/fd-safer.c: New file.
    	* gnulib/import/fdopendir.c: New file.
    	* gnulib/import/filename.h: New file.
    	* gnulib/import/filenamecat-lgpl.c: New file.
    	* gnulib/import/filenamecat.h: New file.
    	* gnulib/import/fstat.c: New file.
    	* gnulib/import/fstatat.c: New file.
    	* gnulib/import/getcwd-lgpl.c: New file.
    	* gnulib/import/getcwd.c: New file.
    	* gnulib/import/getdtablesize.c: New file.
    	* gnulib/import/getlogin_r.c: New file.
    	* gnulib/import/getprogname.c: New file.
    	* gnulib/import/getprogname.h: New file.
    	* gnulib/import/gettext.h: New file.
    	* gnulib/import/glob-libc.h: New file.
    	* gnulib/import/glob.c: New file.
    	* gnulib/import/glob.in.h: New file.
    	* gnulib/import/intprops.h: New file.
    	* gnulib/import/m4/chdir-long.m4: New file.
    	* gnulib/import/m4/close.m4: New file.
    	* gnulib/import/m4/closedir.m4: New file.
    	* gnulib/import/m4/d-ino.m4: New file.
    	* gnulib/import/m4/d-type.m4: New file.
    	* gnulib/import/m4/dup.m4: New file.
    	* gnulib/import/m4/dup2.m4: New file.
    	* gnulib/import/m4/error.m4: New file.
    	* gnulib/import/m4/fchdir.m4: New file.
    	* gnulib/import/m4/fcntl.m4: New file.
    	* gnulib/import/m4/fcntl_h.m4: New file.
    	* gnulib/import/m4/fdopendir.m4: New file.
    	* gnulib/import/m4/filenamecat.m4: New file.
    	* gnulib/import/m4/fstat.m4: New file.
    	* gnulib/import/m4/fstatat.m4: New file.
    	* gnulib/import/m4/getcwd-abort-bug.m4: New file.
    	* gnulib/import/m4/getcwd-path-max.m4: New file.
    	* gnulib/import/m4/getcwd.m4: New file.
    	* gnulib/import/m4/getdtablesize.m4: New file.
    	* gnulib/import/m4/getlogin_r.m4: New file.
    	* gnulib/import/m4/getprogname.m4: New file.
    	* gnulib/import/m4/glob.m4: New file.
    	* gnulib/import/m4/gnulib-cache.m4: Regenerate.
    	* gnulib/import/m4/gnulib-comp.m4: Regenerate.
    	* gnulib/import/m4/mempcpy.m4: New file.
    	* gnulib/import/m4/memrchr.m4: New file.
    	* gnulib/import/m4/mode_t.m4: New file.
    	* gnulib/import/m4/msvc-inval.m4: New file.
    	* gnulib/import/m4/msvc-nothrow.m4: New file.
    	* gnulib/import/m4/open.m4: New file.
    	* gnulib/import/m4/openat.m4: New file.
    	* gnulib/import/m4/opendir.m4: New file.
    	* gnulib/import/m4/readdir.m4: New file.
    	* gnulib/import/m4/realloc.m4: New file.
    	* gnulib/import/m4/rewinddir.m4: New file.
    	* gnulib/import/m4/save-cwd.m4: New file.
    	* gnulib/import/m4/strdup.m4: New file.
    	* gnulib/import/m4/strerror.m4: New file.
    	* gnulib/import/m4/unistd-safer.m4: New file.
    	* gnulib/import/mempcpy.c: New file.
    	* gnulib/import/memrchr.c: New file.
    	* gnulib/import/msvc-inval.c: New file.
    	* gnulib/import/msvc-inval.h: New file.
    	* gnulib/import/msvc-nothrow.c: New file.
    	* gnulib/import/msvc-nothrow.h: New file.
    	* gnulib/import/open.c: New file.
    	* gnulib/import/openat-die.c: New file.
    	* gnulib/import/openat-priv.h: New file.
    	* gnulib/import/openat-proc.c: New file.
    	* gnulib/import/openat.c: New file.
    	* gnulib/import/openat.h: New file.
    	* gnulib/import/opendir.c: New file.
    	* gnulib/import/pipe-safer.c: New file.
    	* gnulib/import/readdir.c: New file.
    	* gnulib/import/realloc.c: New file.
    	* gnulib/import/rewinddir.c: New file.
    	* gnulib/import/save-cwd.c: New file.
    	* gnulib/import/save-cwd.h: New file.
    	* gnulib/import/strdup.c: New file.
    	* gnulib/import/strerror-override.c: New file.
    	* gnulib/import/strerror-override.h: New file.
    	* gnulib/import/strerror.c: New file.
    	* gnulib/import/unistd--.h: New file.
    	* gnulib/import/unistd-safer.h: New file.
    	* gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
    	"getcwd" and "glob".
    	* ser-tcp.c: Undefine "close" before redefining it.

commit 0cf44ec826eab1f149285b8919aa9dc4140d8d78
Author: Jim Wilson <jim.wilson@linaro.org>
Date:   Fri Sep 22 07:58:28 2017 -0700

    [GOLD] Set non-exec stack for aarch64
    
    GNU-stack notes added in 2004, aarch64 port added in 2012, so no old object
    files with missing GNU-stack notes that we need to worry about.
    
    	gold/
    	* aarch64.cc (Target_aarch64::aarch64_info): Set
    	is_default_stack_executable to false.

commit cc4d742f4ce05bf933397a513b953c0feeae0663
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 22 16:51:55 2017 +0200

    gdbserver x86 on win32: call init_target_desc
    
    When trying to run gdbserver compiled for x86 win32 under wine, I get:
    
      $ wine ./gdbserver/gdbserver.exe --once :1234 ./test
      /home/emaisin/src/binutils-gdb/gdb/gdbserver/regcache.c:177: A problem internal to GDBserver has been detected.
      regcache* new_register_cache(const target_desc*): Assertion `tdesc->registers_size != 0' failed.
    
    It seems like on that platform, init_target_desc is never called, so
    registers_size is never computed.
    
    My first thought was to call init_target_desc somewhere in win32-low.c,
    but it turns out that when using win32 on arm, the target description is
    already initialized by the generated code.  My second thought was to
    call it in {i386,amd64}_create_target_description, but those functions
    are shared with GDB, and init_target_desc is gdbserver-specific.  So I
    ended up with the simplest fix, calling it in i386_arch_setup.
    
    Now I hit some other problem:
    
      $ wine ./gdbserver/gdbserver.exe --once :1234 ./test
      Killing process(es): 39
      No program to debug
      Exiting
    
    but still, I think fixing the tdesc issue this is a step forward.
    
    gdb/gdbserver/ChangeLog:
    
    	* win32-i386-low.c (i386_arch_setup): Call init_target_desc.

commit b69e9267d15a09ce3f3d4599eae2952dfc6df502
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 22 07:25:16 2017 -0700

    x86: Return -1 if bfd_canonicalize_dynamic_reloc returns 0
    
    Stop if bfd_canonicalize_dynamic_reloc returns 0.
    
    	PR ld/22163
    	* elfxx-x86.c (_bfd_x86_elf_get_synthetic_symtab): Also return
    	-1 if bfd_canonicalize_dynamic_reloc returns 0.

commit be2b629f6427812a24f38802ba1c472a2cbfab7d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 22 06:58:48 2017 -0700

    Add a test for PR ld/22150
    
    	PR ld/22150
    	* testsuite/ld-elf/pr22150.vd: New file.
    	* testsuite/ld-elf/pr22150.ver: Likewise.
    	* testsuite/ld-elf/pr22150a.s: Likewise.
    	* testsuite/ld-elf/pr22150b.s: Likewise.
    	* testsuite/ld-elf/shared.exp: Run PR ld/22150 tests.

commit b877d21f34211915953487d68a07697f4cb4f771
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 22 14:57:52 2017 +0100

    bfd/version.h: Add rationale for BFD_VERSION_DATE
    
    bfd/ChangeLog:
    2017-09-22  Pedro Alves  <palves@redhat.com>
    	    Alan Modra  <amodra@gmail.com>
    
    	* version.h: Add comment.

commit 432ae719d35c81324e01ae6bd9970cc43e69fa5e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 21 16:37:40 2017 +0200

    Fix sometimes-uninitialized warning in gdbscm_value_address
    
    I am getting this warning with clang:
    
    /home/emaisin/src/binutils-gdb/gdb/guile/scm-value.c:439:11: error: variable 'address' is used uninitialized whenever 'if' condition is false [-Werror,-Wsometimes-uninitialized]
          if (res_val != NULL)
              ^~~~~~~~~~~~~~~
    /home/emaisin/src/binutils-gdb/gdb/guile/scm-value.c:444:32: note: uninitialized use occurs here
          if (gdbscm_is_exception (address))
                                   ^~~~~~~
    /home/emaisin/src/binutils-gdb/gdb/guile/scm-value.c:439:7: note: remove the 'if' if its condition is always true
          if (res_val != NULL)
          ^~~~~~~~~~~~~~~~~~~~
    /home/emaisin/src/binutils-gdb/gdb/guile/scm-value.c:427:18: note: initialize the variable 'address' to silence this warning
          SCM address;
                     ^
                      = nullptr
    
    We can get rid of it with a small refactoring.  I think it's a bit
    cleaner/safer to initialize address with a pessimistic value and assign
    it on success.  Then there's no chance of using it uninitialized.  If I
    understand correctly, the NULL check on res_val was to check whether
    value_addr threw, and that if value_addr returns without throwing, the
    result will never be NULL.  If that's true, we can skip the res_val
    variable.
    
    Tested by running gdb.guile/*.exp locally.
    
    gdb/ChangeLog:
    
    	* guile/scm-value.c (gdbscm_value_address): Initialize address,
    	get rid of res_val.

commit 4fa7574eecb9a92ef40f77de572541e402a2749e
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date:   Fri Sep 22 10:42:45 2017 +0200

    Fix gdb 8.1 Solaris compilation
    
    I just tried to compile gdb trunk on Solaris 11.4 (formerly 12), and
    failed for a couple of reasons:
    
    *
    
    In file included from /usr/include/python2.7/Python.h:128:0,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/python/python-internal.h:94,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/python/py-instruction.h:23,
                     from /vol/src/gnu/gdb/gdb/dist/gdb/python/py-instruction.c:21:
    /usr/include/python2.7/ceval.h:67:0: error: ignoring #pragma no_inline  [-Werror=unknown-pragmas]
     #pragma no_inline(PyEval_EvalFrameEx)
     ^
    
      New in Solaris 11.4: <python2.7/ceval.h> uses a Studio-only #pragma.
      I've disabled the warning in warnings.m4.
    
    *
    
    /vol/src/gnu/gdb/gdb/dist/gdb/ser-pipe.c: In function â??int pipe_open(serial*, const char*)â??:
    /vol/src/gnu/gdb/gdb/dist/gdb/ser-pipe.c:77:9: error: â??pid_t vfork()â?? is deprecated (declared at /usr/include/unistd.h:659) [-Werror=deprecated-declarations]
       pid = vfork ();
             ^
    /vol/src/gnu/gdb/gdb/dist/gdb/ser-pipe.c:77:16: error: â??pid_t vfork()â?? is deprecated (declared at /usr/include/unistd.h:659) [-Werror=deprecated-declarations]
       pid = vfork ();
                    ^
    
      Since Solaris 11, vfork () is marked deprecated in <unistd.h>.
    
      cf. vfork(2):
    
           The  vfork()  and vforkx() functions are deprecated. Their sole legiti-
           mate use as a prelude to an immediate call to a function from the  exec
           family can be achieved safely by posix_spawn(3C) or posix_spawnp(3C).
    
      Again, I've disabled the warning.
    
    *
    
    /vol/src/gnu/gdb/gdb/dist/gdb/cli/cli-cmds.c: In function â??void shell_escape(const char*, int)â??:
    /vol/src/gnu/gdb/gdb/dist/gdb/cli/cli-cmds.c:750:14: error: â??pid_t vfork()â?? is deprecated (declared at /usr/include/unistd.h:659) [-Werror=deprecated-declarations]
       if ((pid = vfork ()) == 0)
                  ^
    /vol/src/gnu/gdb/gdb/dist/gdb/cli/cli-cmds.c:750:21: error: â??pid_t vfork()â?? is deprecated (declared at /usr/include/unistd.h:659) [-Werror=deprecated-declarations]
       if ((pid = vfork ()) == 0)
                         ^
    
      Same problem.
    
    *
    
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c: In function â??void procfs_init_inferior(target_ops*, int)â??:
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c:4380:30: error: â??START_INFERIOR_TRAPS_EXPECTEDâ?? was not declared in this scope
       gdb_startup_inferior (pid, START_INFERIOR_TRAPS_EXPECTED);
                                  ^
    
      defined in nat/fork-inferior.h, need to include that header
    
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c: In function â??void procfs_create_inferior(target_ops*, const char*, const string&, char**, int)â??:
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c:4605:38: error: â??fork_inferiorâ?? was not declared in this scope
              NULL, NULL, shell_file, NULL);
                                          ^
    
      likewise
    
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c: In function â??void procfs_info_proc(target_ops*, const char*, info_proc_what)â??:
    /vol/src/gnu/gdb/gdb/dist/gdb/procfs.c:5124:20: error: â??argvâ?? was not declared in this scope
       for (char *arg : argv)
                        ^
    
      Typo, should be built_argv instead!
    
    *
    
    Undefined                       first referenced
     symbol                             in file
    fork_inferior(char const*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, char**, void (*)(), void (*)(int), void (*)(), char const*, void (*)(char const*, char* const*, char* const*)) procfs.o
    startup_inferior(int, int, target_waitstatus*, ptid_t*) fork-child.o
    ld: fatal: symbol referencing errors
    collect2: error: ld returned 1 exit status
    make[2]: *** [Makefile:2249: gdb] Error 1
    
      Need to add fork-inferior.o to NATDEPFILES.
    
    With the changes below, I can build gdb on sparcv9-sun-solaris2.11 and
    amd64-pc-solaris2.11 and a simple smoke test (gdb/gdb gdb/gdb) works.

commit 7790bd6c748fc8e46c621b065562729735114f6b
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 22 15:11:12 2017 +0930

    [GOLD] clone assert breakage
    
    	* resolve.cc (clone): Fix got_offset_list test.

commit ec76901011c5af6a565936d4ad87247c51901b58
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 22 11:04:41 2017 +0930

    [GOLD] Set non-exec stack for ppc64
    
    gcc doesn't emit stack notes for ELFv1, since ELFv1 never needs an
    executable stack.  Note that ELFv1 is usually big-endian and ELFv2
    little-endian, but the ABI is really orthogonal to endiannes.
    
    	* powerpc.cc (Target_powerpc<64,*>::powerpc_info): Set
    	is_default_stack_executable false.

commit 11bb0c7abcb26fcc4ce75c66c38eca1f7b3e3480
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 22 08:27:01 2017 +0930

    readelf tests
    
    We have multiple tests that report failure to assemble without saying
    exactly what test is failing.
    
    	* testsuite/binutils-all/readelf.exp: Don't perror and exit on
    	bintest.s assembly failure.  Report tests unresolved instead.
    	Likewise for version note test, pr18374, decompress, and dw5
    	tests.
    	(readelf_test): Set testname to include both option and binary
    	file name.  Use for pass/fail.

commit df52f331ed2dd79fc8461784abfaf3c1a9c827dc
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Sep 22 00:00:27 2017 +0000

    Automatic date update in version.in

commit ef272caa7482bd9031e82a2e6f1b81870fe2129e
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Fri Sep 22 00:54:19 2017 +0100

    readelf: Handle E_MIPS_MACH_5900
    
    Fix commit e407c74b5b60 ("Support for MIPS R5900 (Sony Playstation 2)"),
    <https://sourceware.org/ml/binutils/2012-12/msg00240.html>, and add the
    handling of E_MIPS_MACH_5900, correctly showing `5900' among `Flags:' in
    the output of `-h' rather than `unknown CPU'.
    
    	binutils/
    	* readelf.c (get_machine_flags) <E_MIPS_MACH_5900>: New case.
    
    	gas/
    	* testsuite/gas/mips/elf_mach_5900.d: New test.
    	* testsuite/gas/mips/mips.exp: Run it.

commit 42c0794e961fd7922ad1358bd7221a8c85278ccc
Author: James Cowgill <James.Cowgill@imgtec.com>
Date:   Fri Sep 22 00:54:19 2017 +0100

    PR gas/21762: MIPS: Fix .stabs directive marking labels as MIPS16
    
    If a .stabs directive was used before another .set directive in a MIPS
    source file, s_mips_stab would call mips_mark_labels without having
    initialized the mips_opts structure yet.  Fix this by calling
    file_mips_check_options which will initialize mips_opts if necessary.
    
    gas/
    	PR gas/21762
    	* config/tc-mips.c (s_mips_stab): Insert call to
    	file_mips_check_options.
    	* testsuite/gas/mips/micromips@stabs-symbol-type.d: New test.
    	* testsuite/gas/mips/mips.exp: Run the new tests.
    	* testsuite/gas/mips/mips16@stabs-symbol-type.d: New test.
    	* testsuite/gas/mips/stabs-symbol-type.d: New test.
    	* testsuite/gas/mips/stabs-symbol-type.s: New test source.

commit 757bf54bb48a8417154cfdd7128c1775d43478d8
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Thu May 5 12:39:36 2016 -0700

    Test case for Inferior.thread_from_thread_handle
    
    As the title says, this is a test case for
    Inferior.thread_from_thread_handle, a python method which will,
    given a thread library dependent thread handle, find the GDB thread
    which corresponds to that thread handle (in the inferior under
    consideration).
    
    The C file for this test case causes the thread handles for the
    main thread and two child threads to be placed into an array.  The
    test case runs to one of the functions (do_something()) at which point,
    it retrieves the thread handles from the array and attempts to find the
    corresponding thread in GDB's internal thread list.
    
    I use barriers to make sure that both threads have actually started;
    execution will stop when one of the threads breaks at do_something.
    
    Thanks to Simon Marchi for suggestions for forcing the thread
    numbering to be stable.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-thrhandle.c, gdb.python/py-thrhandle.exp: New
    	files.

commit f2ff95c5837bd41848e7156aa2677498518d0d18
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Thu Apr 6 14:55:32 2017 -0700

    Documentation for qXfer:threads:read handle attribute
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (qXfer:threads:read): Add documentation for handle
    	attribute.

commit f6327dcbf0bc91bb9d99e12232d2b1a2f959fce6
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Apr 4 16:17:05 2017 -0700

    Add thread_handle_to_thread_info support for remote targets
    
    This patch adds support to remote targets for converting a thread
    handle to a thread_info struct pointer.
    
    A thread handle is fetched via a "handle" attribute which has been
    added to the qXfer:threads:read query packet.  An implementation is
    provided in gdbserver for targets using the Linux kernel.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.h (struct lwp_info): Add new field, thread_handle.
    	(thread_db_thread_handle): Declare.
    	* linux-low.c (linux_target_ops): Initialize thread_handle.
    	* server.c (handle_qxfer_threads_worker): Add support for
    	"handle" attribute.
    	* target.h (struct target_ops): Add new function pointer,
    	thread_handle.
    	(target_thread_handle): Define.
    	* thread-db.c (find_one_thread, attach_thread): Set thread_handle
    	field in lwp.
    	(thread_db_thread_handle): New function.
    
    gdb/ChangeLog:
    
    	* remote.c (vector): Include.
    	(struct private_thread_info): Add field, thread_handle.
    	(free_private_thread_info): Deallocate storage associated with
    	thread handle.
    	(get_private_info_thread): Initialize `thread_handle' field.
    	(struct thread_item): Add field, thread_handle.
    	(clear_threads_listing_context): Deallocate storage associated
    	with thread handle.
    	(start_thread): Add support for "handle" attribute.
    	(thread_attributes): Add "handle".
    	(remote_get_threads_with_qthreadinfo): Initialize thread_handle
    	field.
    	(remote_update_thread_list): Update thread_handle.
    	(remote_thread_handle_to_thread_info): New function.
    	(init_remote_ops): Initialize to_thread_handle_to_thread_info.

commit 8629910955a751a93f2f12389ff1f497556cc260
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Tue Apr 4 15:25:43 2017 -0700

    Add thread_db_notice_clone to gdbserver
    
    While working on a patch for fetching a thread handle in gdbserver, I
    ran into a circumstance in which tests in gdb.mi/mi-nsmoribund.exp
    would occasionally fail.  Over a large enough number of runs, it would
    fail roughly 2% of the time.
    
    That thread handle patch caused find_one_thread() to be called on
    every stop.  find_one_thread() calls td_ta_map_lwp2thr() which, in
    turn, can cause ps_get_thread_area() to be called.
    ps_get_thread_area() makes a call to ptrace() for getting the thread
    area address.  If this should happen when the thread is not stopped,
    the call to ptrace will return error which in turn propogates back to
    find_one_thread().  find_one_thread() calls error() in this instance
    which causes the program to die.
    
    This patch causes find_one_thread() to be called upon reciept of a
    clone event.  Since the clone is stopped, the circumstances described
    above cannot occur.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
    	* linux-low.h (thread_db_notice_clone): Declare.
    	* thread-db.c (thread_db_notice_clone): New function.

commit da2c323bff3405add97c37333668de3aad36ec70
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Wed May 4 16:46:50 2016 -0700

    Documentation for Inferior.thread_from_thread_handle
    
    gdb/doc/ChangeLog:
    
    	* python.texi (Inferiors In Python): Add description for method
    	Inferior.thread_from_thread_handle.

commit fbbe5337a6d839309c0415765803a19f3e38f6e4
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Wed May 4 16:23:08 2016 -0700

    Add `thread_from_thread_handle' method to (Python) gdb.Inferior
    
    gdb/ChangeLog:
    	* python/py-inferior.c (gdbpy_thread_from_thread_handle): New
    	function.
    	(inferior_object_methods): Add gdbpy_thread_from_thread_handle.
    	* python/python-internal.h (thread_object_type): Declare.

commit e04ee09e24563f013c35cdebd7e9de3092b99b83
Author: Kevin Buettner <kevinb@redhat.com>
Date:   Wed May 4 15:21:12 2016 -0700

    Add target method for converting thread handle to thread_info struct pointer
    
    This patch adds a target method named `to_thread_handle_to_thread_info'.
    It is intended to map a thread library specific thread handle (such as
    pthread_t for the pthread library) to the corresponding GDB internal
    thread_info struct (pointer).
    
    An implementation is provided for Linux pthreads; see linux-thread-db.c.
    
    gdb/ChangeLog:
    
    	* target.h (struct target_ops): Add to_thread_handle_to_thread_info.
    	(target_thread_handle_to_thread_info): Declare.
    	* target.c (target_thread_handle_to_thread_info): New function.
    	* target-delegates.c: Regenerate.
    	* gdbthread.h (find_thread_by_handle): Declare.
    	* thread.c (find_thread_by_handle): New function.
    	* linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
    	function.
    	(init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.

commit f557a88ab120b75ddcc507c03d565c28e5f88c16
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Sep 21 16:52:33 2017 +0100

    gdbserver: Remove traces of ancient Hc handling
    
    Back in commit f0db101d9897 ("gdbserver: don't pick a random thread if
    the current thread dies"), a couple years ago, the last references to
    set_desired_thread(0) [select the Hc thread] were removed, and all the
    remaining calls to set_desired_thread pass '1', meaning general
    thread.  This means we can simplify set_desired_thread.
    
    gdb/gdbserver/ChangeLog:
    2017-09-21  Pedro Alves  <palves@redhat.com>
    
    	* server.c (gdb_read_memory, handle_status, process_serial_event)
    	(handle_serial_event, handle_target_event): Adjust to
    	set_desired_thread prototype change.
    	* target.c (set_desired_thread): Remove 'use_general' parameter
    	and adjust.
    	* target.h (set_desired_thread): Remove 'use_general' parameter.

commit 8fe09d7421db51bc13c9228547d63e6315bd6bd0
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Thu Sep 21 17:45:18 2017 +0200

    S/390: Fix Elf note swap s390_gs_bc vs. s390_gs_cb
    
    Fix two typos that resulted in swapping the BFD names for the core note
    register sections NT_S390_GS_CB and NT_S390_GS_BC.
    
    bfd/ChangeLog:
    
    	* elf.c (elfcore_grok_note): For the cases NT_S390_GS_CB and
    	NT_S390_GS_BC, correct the previously swapped invocations of
    	elfcore_grok_s390_gs_bc and elfcore_grok_s390_gs_cb.

commit ba52cbb9d024f2e51bd50fac36a18a15ab88344c
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Sep 21 09:54:04 2017 +0930

    Reduce excessive .eh_frame alignment for powerpc
    
    PowerPC64 .cfi directives use DW_EH_PE_sdata4 encoding for .eh_frame,
    so there is no real reason why .eh_frame should be 8 byte aligned.
    
    gas/
    	* config/tc-ppc.h (EH_FRAME_ALIGNMENT): Define.
    ld/
    	* testsuite/ld-powerpc/tlsopt5.wf: Update for reduced alignment.

commit 1e5b66ed4285ecf063e7801a46178ebb0ce5be41
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 21 15:19:40 2017 +0200

    linux-waitpid: Get rid of format string warning
    
    Clang gives this warning:
    
    /home/emaisin/src/binutils-gdb/gdb/gdbserver/../nat/linux-waitpid.c:45:25: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
          vfprintf (stderr, format, args);
                            ^~~~~~
    
    Get rid of it by adding ATTRIBUTE_PRINTF.
    
    gdb/ChangeLog:
    
    	* nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.

commit ebe48ba0856dcccaa7a60d873c61e6f1f96f5887
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 21 14:09:33 2017 +0200

    microblaze-tdep: Add ATTRIBUTE_PRINTF to microblaze_debug
    
    I am getting this warning with clang:
    
    /home/emaisin/src/binutils-gdb/gdb/microblaze-tdep.c:94:28: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
           vprintf_unfiltered (fmt, args);
                               ^~~
    
    Adding ATTRIBUTE_PRINTF to microblaze_debug gets rid of it.  Strangely,
    gcc doesn't warn about non-literal format strings when calling vprintf
    (or a vprintf-style function, like vprintf_unfiltered).  I filed this
    gcc bug:
    
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82206
    
    gdb/ChangeLog:
    
    	* microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.

commit 0a0bf5dc149ad79b325cdffb6b4e57be6c5ecbc2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Sep 21 09:19:23 2017 +0100

    Fix aarch64-freebsd build failure
    
    I happen to see that fbsd-tdep.o is missing for target aarch64-freebsd,
    and it causes the build failure,
    
    aarch64-fbsd-tdep.o: In function `aarch64_fbsd_init_abi(gdbarch_info, gdbarch*)':
    binutils-gdb/gdb/aarch64-fbsd-tdep.c:186: undefined reference to `fbsd_init_abi(gdbarch_info, gdbarch*)'
    binutils-gdb/gdb/aarch64-fbsd-tdep.c:189: undefined reference to `svr4_lp64_fetch_link_map_offsets()'
    binutils-gdb/gdb/aarch64-fbsd-tdep.c:189: undefined reference to `set_solib_svr4_fetch_link_map_offsets(gdbarch*, link_map_offsets* (*)())'
    
    This patch fixed it.
    
    gdb:
    
    2017-09-21  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
    	to gdb_target_obs.

commit ea5cf0fe291966845fb62f173d407a0dad69819b
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Sep 21 09:04:43 2017 +0100

    oops - changelog entry omitted from previous delta

commit 88240b186d224d634633d9996832f1235364b6d4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Thu Sep 21 09:02:25 2017 +0100

    [SIM, ARM] Fix build failure
    
    This patch fixes the build failure by using disassembler to get
    disassemble function pointer, and do the disassembly, because
    print_insn_little_arm is no longer visible outside opcodes/
    
    binutils-gdb/sim/arm/wrapper.c:98:10: error: implicit declaration of function 'print_insn_little_arm' [-Werror=implicit-function-declaration]
       size = print_insn_little_arm (0, & info);
              ^
    
    sim/arm:
    
    2017-09-21  Yao Qi  <yao.qi@linaro.org>
    
    	* wrapper.c (print_insn): Use disassembler instead of
    	print_insn_little_arm.

commit d1b0a7bfd3df05fd2009b62b19b7535bbc6555c0
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 21 21:51:11 2017 -0600

    Change counted_command_line to a shared_ptr
    
    This changes counted_command_line to be a typedef for std::shared_ptr
    and removes the associated cleanups.  In the long run I believe that
    cmd_list_element should also be changed to use a shared_ptr.
    
    gdb/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (struct counted_command_line): Remove.
    	(breakpoint_commands): Update.
    	(alloc_counted_command_line, incref_counted_command_line)
    	(decref_counted_command_line, do_cleanup_counted_command_line)
    	(make_cleanup_decref_counted_command_line): Remove.
    	(breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
    	(bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
    	(bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
    	(save_breakpoints): Update.
    	* breakpoint.h (counted_command_line): Now a typedef to
    	shared_ptr.
    	(struct breakpoint) <commands>: Now a counted_command_line.
    	(struct bpstats) <command>: Likewise.

commit 48649e1bfe2ef4cceff15a34e5a9e37201894ecd
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 21 21:37:45 2017 -0600

    Use function_view in a couple of places in breakpoint.c
    
    This changes iterate_over_related_breakpoints and
    map_breakpoint_numbers to take a function_view.  Then, it simplifies
    the callers by using lambdas.  This then allows the removal of some
    bookkeeping types.
    
    gdb/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (struct commands_info, do_map_commands_command):
    	Remove.
    	(commands_command_1): Update.
    	(iterate_over_related_breakpoints): Take a function_view.
    	(do_delete_breakpoint, do_map_delete_breakpoint): Remove.
    	(delete_command): Update.
    	(map_breakpoint_numbers): Take a function_view.
    	(do_disable_breakpoint, do_map_delete_breakpoint): Remove.
    	(disable_command): Update.
    	(do_enable_breakpoint, do_map_enable_breakpoint): Remove.
    	(enable_command): Update.
    	(struct disp_data, do_enable_breakpoint_disp)
    	(do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
    	(do_map_enable_delete_breakpoint): Remove.
    	(enable_once_command, enable_count_command, enable_delete_command)
    	(delete_trace_variable_command): Update.

commit 04afa70c8e1c931dd44db76eb9f0ddd4949ed00c
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 21 21:08:59 2017 -0600

    Allocate bpstats with new
    
    This changes struct bpstats to be allocated with new and freed with
    delete, adding constructors and a destructor in the process.  This
    allows the removal of one cleanup and clears the way for more to
    follow.
    
    gdb/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (~bpstats): Rename from bpstat_free.  Update.
    	(bpstat_clear): Use delete.
    	(bpstats): New constructors.
    	(bpstat_copy, bpstat_stop_status): Use new.
    	(dprintf_after_condition_true): Update.
    	* breakpoint.h (bpstats::bpstats): Add constructors.
    	(bpstats::~bpstats): Add destructor.

commit f5b358c8aa564c58b0a3201b82cc782124d80bb9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Sep 21 00:00:27 2017 +0000

    Automatic date update in version.in

commit c83833f49353e1fe7fa727291210be751161ade1
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Sep 21 00:34:41 2017 +0100

    eval.c:evaluate_subexp_standard: Use RAII to avoid leaks
    
    While working on the no-debug-info debugging improvements series, I
    noticed these bare xfree calls, which lead to leaks if
    evaluate_subexp_standard throws.
    
    Fix that by reworking make_params as a RAII class.  Ends up
    eliminating a couple heap allocations too.
    
    gdb/ChangeLog:
    2017-09-20  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (make_params): Delete, refactored as ...
    	(class fake_method): ... this new type's ctor.
    	(fake_method::~fake_method): New.
    	(evaluate_subexp_standard): Use 'fake_method'.

commit ca464aac1b0a444f7debb8fc1e5e8b3f30602a35
Author: Teresa Johnson <tejohnson@google.com>
Date:   Wed Sep 20 15:43:37 2017 -0700

    Check for export dynamic symbol options when doing symbol resolution in plugins.
    
    2017-09-20  Teresa Johnson  <tejohnson@google.com>
    	* plugin.cc (is_visible_from_outside): Check for export dynamic symbol
            option and list.
    	* testsuite/Makefile.am (plugin_test_12): New test.
    	* testsuite/Makefile.in: Regenerate.
    	* testsuite/export_dynamic_plugin.cc: New test source.
    	* testsuite/plugin_test_12.sh: New test script.

commit 223ffa714ce1cf1dc6e0c361189fa80417ff90d9
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 19 21:56:36 2017 -0600

    Remove make_cleanup_restore_target_terminal
    
    This removes make_cleanup_restore_target_terminal and generally
    C++-ifies target terminal handling.  It changes all target_terminal_*
    functions to be static members of a new target_terminal class and
    changes the cleanup to be a scoped_* class.
    make_cleanup_override_quit_handler is also removed in favor of simply
    using scoped_restore.
    
    Note that there are some files in this patch that I could not compile.
    Considering that some of the rewrites were automated, and that none of
    these files involed cleanups, I feel that this is relatively safe.
    
    Regression tested by the buildbot.
    
    gdb/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* windows-nat.c (get_windows_debug_event, windows_wait)
    	(do_initial_windows_stuff, windows_attach): Update.
    	* utils.c (vwarning, internal_vproblem): Update.
    	(ui_unregister_input_event_handler_cleanup)
    	(prepare_to_handle_input): Remove.
    	(class scoped_input_handler): New.
    	(defaulted_query, prompt_for_continue): Update.
    	* tui/tui-hooks.c (tui_refresh_frame_and_register_information):
    	Update.
    	* top.c (undo_terminal_modifications_before_exit): Update.
    	* target/target.h (target_terminal_init, target_terminal_inferior)
    	(target_terminal_ours): Don't declare.
    	(class target_terminal): New.
    	* target.h (target_terminal_is_inferior, target_terminal_is_ours)
    	(target_terminal_ours_for_output)
    	(make_cleanup_restore_target_terminal): Don't declare.
    	(target_terminal_info): Remove.
    	* target.c (enum terminal_state, terminal_state): Remove.
    	(target_terminal::terminal_state): Define.
    	(target_terminal::init): Rename from target_terminal_init.
    	(target_terminal::inferior): Rename from
    	target_terminal_inferior.
    	(target_terminal::ours): Rename from target_terminal_ours.
    	(target_terminal::ours_for_output): Rename from
    	target_terminal_ours_for_output.
    	(target_terminal::info): New method.
    	(cleanup_restore_target_terminal)
    	(make_cleanup_restore_target_terminal): Remove.
    	* solib.c (handle_solib_event): Update.
    	* remote.c (remote_serial_quit_handler): Update.
    	(remote_terminal_inferior, remote_wait_as): Update.
    	* record-full.c (record_full_wait_1): Update.
    	* nto-procfs.c (procfs_create_inferior): Update.
    	* nat/fork-inferior.c (startup_inferior): Update.
    	* mi/mi-interp.c (mi_new_thread, mi_thread_exit)
    	(mi_record_changed, mi_inferior_added, mi_inferior_appeared)
    	(mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
    	(mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
    	(mi_breakpoint_created, mi_breakpoint_deleted)
    	(mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
    	(mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
    	(mi_user_selected_context_changed, report_initial_inferior):
    	Update.
    	* linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
    	(linux_nat_terminal_inferior): Update.
    	* infrun.c (follow_fork_inferior)
    	(handle_vfork_child_exec_or_exit, do_target_resume)
    	(check_curr_ui_sync_execution_done, handle_inferior_event_1)
    	(handle_signal_stop, maybe_remove_breakpoints, normal_stop):
    	Update.
    	* inflow.c (child_terminal_init, info_terminal_command): Update.
    	* infcmd.c (post_create_inferior, continue_1, prepare_one_step)
    	(attach_command): Update.
    	* infcall.c (call_thread_fsm_should_stop): Update.
    	* gnu-nat.c (gnu_attach): Update.
    	* extension.c (struct active_ext_lang_state)
    	(restore_active_ext_lang): Update.
    	* exceptions.c (print_flush): Update.
    	* event-top.c (async_enable_stdin, default_quit_handler): Update.
    	(struct quit_handler_cleanup_data, restore_quit_handler)
    	(restore_quit_handler_dtor, make_cleanup_override_quit_handler):
    	Remove.
    	* cp-support.c (gdb_demangle): Update.
    	* breakpoint.c (update_inserted_breakpoint_locations)
    	(insert_breakpoint_locations, handle_jit_event)
    	(disable_breakpoints_in_unloaded_shlib): Update.
    	* annotate.c (annotate_breakpoints_invalid)
    	(annotate_frames_invalid): Update.
    
    gdb/gdbserver/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* target.c (target_terminal::terminal_state): Define.
    	(target_terminal::init): Rename from target_terminal_init.
    	(target_terminal::inferior): Rename from
    	target_terminal_inferior.
    	(target_terminal::ours): Rename from target_terminal_ours.
    	(target_terminal::ours_for_output, target_terminal::info): New.

commit 013af3fc8eba48d081f0e83303cd800097e5b7a8
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 12 14:14:33 2017 -0600

    Overload catch_command_errors
    
    This changes catch_command_errors_const to be an overload of
    catch_command_errors, which may mildly help future constification
    efforts.
    
    Tested by rebuilding.
    
    gdb/ChangeLog
    2017-09-20  Tom Tromey  <tom@tromey.com>
    
    	* main.c (catch_command_errors): Rename from
    	catch_command_errors_const.
    	(captured_main_1): Update.

commit 06871ae84096ed1672eb76f44cea4d5dbe79ae24
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Sep 20 16:12:54 2017 +0100

    Make "list ambiguous" show symbol names too
    
    Currently, with an ambiguous "list first,last", we get:
    
      (gdb) list bar,main
      Specified first line 'bar' is ambiguous:
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 97
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 98
    
    This commit makes gdb's output above a bit clearer by printing the
    symbol name as well:
    
      (gdb) list bar,main
      Specified first line 'bar' is ambiguous:
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 97, symbol: "bar(A)"
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 98, symbol: "bar(B)"
    
    And while at it, makes gdb print the symbol name when actually listing
    multiple locations too.  I.e., before (with "set listsize 2"):
    
      (gdb) list bar
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 97
      96
      97      int bar (A) { return 11; }
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 98
      97      int bar (A) { return 11; }
      98      int bar (B) { return 22; }
    
    After:
    
      (gdb) list bar
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 97, symbol: "bar(A)"
      96
      97      int bar (A) { return 11; }
      file: "src/gdb/testsuite/gdb.cp/overload.cc", line number: 98, symbol: "bar(B)"
      97      int bar (A) { return 11; }
      98      int bar (B) { return 22; }
    
    Currently, the result of decoding a linespec loses information about
    the original symbol that was found.  All we end up with is an address.
    This makes it difficult to find the original symbol again to get at
    its print name.  Fix that by storing a pointer to the symbol in the
    sal.  We already store the symtab and obj_section, so it feels like a
    natural progression to me.  This avoids having to do any extra symbol
    lookup too.
    
    gdb/ChangeLog:
    2017-09-20  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (list_command): Use print_sal_location.
    	(print_sal_location): New function.
    	(ambiguous_line_spec): Use print_sal_location.
    	* linespec.c (symbol_to_sal): Record the symbol in the sal.
    	* symtab.c (find_function_start_sal): Likewise.
    	* symtab.h (symtab_and_line::symbol): New field.
    
    gdb/testsuite/ChangeLog:
    2017-09-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/list-ambiguous.exp (test_list_ambiguous_symbol): Expect
    	symbol names in gdb's output.
    	* gdb.cp/overload.exp ("list all overloads"): Likewise.

commit e5f25bc5d6dba5a5c4dd36e08afd57e918c63dea
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Sep 20 16:12:54 2017 +0100

    Fix "list ambiguous_variable"
    
    The "list" command allows specifying the name of variables as
    argument, not just functions, so that users can type "list
    a_global_variable".
    
    That support is a broken when it comes to ambiguous locations though.
    
    If there's more than one such global variable in the program, e.g.,
    static globals in different compilation units, GDB ends up listing the
    source of the first variable it finds, only.
    
    linespec.c does find both symbol and minsym locations for all the
    globals.  The problem is that it ends up merging all the resulting
    sals into one, because they all have address, zero.  I.e., all sals
    end up with sal.pc == 0, so maybe_add_address returns false for all
    but the first.
    
    The zero addresses appear because:
    
    - in the minsyms case, linespec.c:minsym_found incorrectly treats all
      minsyms as if they were function/text symbols.  In list mode we can
      end up with data symbols there, and we shouldn't be using
      find_pc_sect_line on data symbols.
    
    - in the debug symbols case, symbol_to_sal misses recording an address
      (sal.pc) for non-block, non-label symbols.
    
    gdb/ChangeLog:
    2017-09-20  Pedro Alves  <palves@redhat.com>
    
    	* linespec.c (minsym_found): Handle non-text minsyms.
    	(symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
    
    gdb/testsuite/ChangeLog:
    2017-09-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/list-ambiguous.exp (test_list_ambiguous_function):
    	Rename to ...
    	(test_list_ambiguous_symbol): ... this and add a symbol name
    	parameter.  Adjust.
    	(test_list_ambiguous_function): Reimplement on top of
    	test_list_ambiguous_symbol and also test listing ambiguous
    	variables.
    	* gdb.base/list-ambiguous0.c (ambiguous): Rename to ...
    	(ambiguous_fun): ... this.
    	(ambiguous_var): New.
    	* gdb.base/list-ambiguous1.c (ambiguous): Rename to ...
    	(ambiguous_fun): ... this.
    	(ambiguous_var): New.

commit 1b7fa39ed9678fded7264636c1e5cc14c6d6ebc6
Author: Walfred Tedeschi <walfred.tedeschi@intel.com>
Date:   Wed Sep 20 15:24:47 2017 +0200

    [OBV] amd64-features-makefile: add missing backslash.
    
    In an old commit the backslash of was missing in the rule for creating the
    i386-avx-mpx-avx512-pku.dat file.  No need to regenerate the files, this
    was done by another commit from Yao.
    
    2017-09-20  Walfred Tedeschi  <walfred.tedeschi@intel.com>
    
    	* features/Makefile (i386-avx-mpx-avx512-pku.dat): Add backslash.

commit 37dd0825964048f8cb2b1ec0e5e43ab73b8bb69c
Author: Walfred Tedeschi <walfred.tedeschi@intel.com>
Date:   Wed Sep 20 14:47:04 2017 +0200

    add ChangeLog from previous commit

commit 6470a84860b11ba6e7258604ae78f047a1af2f5d
Author: Walfred Tedeschi <walfred.tedeschi@intel.com>
Date:   Wed Sep 20 13:42:21 2017 +0200

    gdb - avx512: tests were failing due to missing memory aligment.
    
    Test was running on a fault during code execution.  Analysis have shown
    that the wrong instruction had been used.  An instruction that takes
    not alligned memory is more appropriated for the task.
    
    ChangeLog:
    
    2017-09-20  Walfred Tedeschi  <walfred.tedeschi@intel.com>
    
    gdb/testesuite/ChangeLog:
    	* gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
    	vmovups instead vmovaps.
    	(move_zmm_data_to_memory): Use vmovups instead vmovaps.
    
    Change-Id: I4a95560861ef1792ed6ce86578fdd726162863f1

commit 64b5d6d785eb4c337b7c071ab9607186541a8b14
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Sep 20 09:17:56 2017 +0930

    [GOLD] PowerPC function address in non-PIC
    
    ppc32, like many targets, defines the address of a function as the PLT
    call stub code for functions referenced but not defined in a non-PIC
    executable.  ppc32 gold, unlike other targets, inherits the ppc64
    multiple stub capability for dealing with very large binaries where
    one set of stubs can't be reached from all code locations.  This means
    there can be multiple choices of address for a function, which might
    cause function pointer comparison failures.  So for ppc32, make
    non-branch references always use the first stub group.
    
    (PowerPC64 ELFv1 is always PIC so doesn't need to define the address
    of an external function as the PLT stub.  PowerPC64 ELFv2 needs a
    special set of global entry stubs to serve as the address of external
    functions, so it too is not affected by this bug.)
    
    	* powerpc.cc (Target_powerpc::Branch_info::make_stub): Put
    	stubs for ppc32 non-branch relocs in first stub table.
    	(Target_powerpc::Relocate::relocate): Resolve similarly.

commit dba74cb2b725ee8857dee865fb7f49c86aad1aed
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Sep 20 00:00:30 2017 +0000

    Automatic date update in version.in

commit 4e5a4f5850487740eb7549f1d0b8625ce577faab
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 11 14:57:37 2017 -0700

    Add a 'starti' command.
    
    This works like 'start' but it stops at the first instruction rather
    than the first line in main().  This is useful if one wants to single
    step through runtime linker startup.
    
    While here, introduce a RUN_ARGS_HELP macro for shared help text
    between run, start, and starti.  This includes expanding the help for
    start and starti to include details from run's help text.
    
    gdb/ChangeLog:
    
    	* NEWS (Changes since GDB 8.0): Add starti.
    	* infcmd.c (enum run_break): New.
    	(run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
    	case.
    	(run_command): Use enum run_how.
    	(start_command): Likewise.
    	(starti_command): New function.
    	(RUN_ARGS_HELP): New macro.
    	(_initialize_infcmd): Use RUN_ARGS_HELP for run and start
    	commands.  Add starti command.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (Starting your Program): Add description of
    	starti command.  Mention starti command as an alternative for
    	debugging the elaboration phase.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/starti.c: New file.
    	* gdb.base/starti.exp: New file.
    	* lib/gdb.exp (gdb_starti_cmd): New procedure.

commit b7f54058d9cd409ada192bfefd4c99c98caaef2e
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Sep 19 15:20:41 2017 +0100

    MIPS/LD: Add OpenBSD/mips64 support
    
    Complement commit 26eebcf553d7 ("Update OpenBSD/mips64 support"),
    <https://sourceware.org/ml/binutils/2005-04/msg00382.html>, which added
    OpenBSD/mips64 support to GAS, and also add it to LD, avoiding a build
    failure at the configuration stage, like:
    
    *** ld does not support target mips64-unknown-openbsd
    *** see ld/configure.tgt for supported targets
    make[1]: *** [configure-ld] Error 1
    
    As per OS support only include n64 MIPS emulations, and use the
    traditional ones, matching the choice already made with the addition of
    GAS support.
    
    	ld/
    	* configure.tgt <mips64el-*-openbsd*, mips64-*-openbsd*>: New
    	targets.

commit aa70c9f1950b25b48f8fd6770f5d38a8252c24a4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 19 10:18:57 2017 +0100

    Remove one explicit rule for monitor.o
    
    gdb/monitor.c was removed by 40e0b27 (Delete the remaining ROM monitor
    targets).
    
    gdb:
    
    2017-09-19  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (monitor.o): Remove the rule.

commit d6541620447f43985b34e9a39488bafb38158221
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 19 10:10:03 2017 +0100

    Use DISABLE_COPY_AND_ASSIGN
    
    We have many classes that copy cotr and assignment operator are deleted,
    so this patch replaces these existing mechanical code with macro
    DISABLE_COPY_AND_ASSIGN.
    
    gdb:
    
    2017-09-19  Yao Qi  <yao.qi@linaro.org>
    
    	* annotate.h (struct annotate_arg_emitter): Use
    	DISABLE_COPY_AND_ASSIGN.
    	* common/refcounted-object.h (refcounted_object): Likewise.
    	* completer.h (struct completion_result): Likewise.
    	* dwarf2read.c (struct dwarf2_per_objfile): Likewise.
    	* filename-seen-cache.h (filename_seen_cache): Likewise.
    	* gdbcore.h (thread_section_name): Likewise.
    	* gdb_regex.h (compiled_regex): Likewise.
    	* gdbthread.h (scoped_restore_current_thread): Likewise.
    	* inferior.h (scoped_restore_current_inferior): Likewise.
    	* jit.c (jit_reader): Likewise.
    	* linespec.h (struct linespec_result): Likewise.
    	* mi/mi-parse.h (struct mi_parse): Likewise.
    	* nat/fork-inferior.c (execv_argv): Likewise.
    	* progspace.h (scoped_restore_current_program_space): Likewise.
    	* python/python-internal.h (class gdbpy_enter): Likewise.
    	* regcache.h (regcache): Likewise.
    	* target-descriptions.c (struct tdesc_reg): Likewise.
    	(struct tdesc_type): Likewise.
    	(struct tdesc_feature): Likewise.
    	* ui-out.h (ui_out_emit_type): Likewise.

commit 25516cc573ff3551a7ac0538e1d3de5811c7199e
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 19 13:22:49 2017 +0930

    PowerPC64 stubs don't match calculated size
    
    After the PR 21411 fix, the linker generated .eh_frame for ppc64 glink
    can be edited by the generic code.  The sequence of events goes
    something like:
    1) Some object file adds .eh_frame aligned to 8, making the output
       .eh_frame aligned to at least 8, so linker generated .eh_frame FDE
       is padded to an 8 byte boundary.
    2) All .eh_frame past the glink .eh_frame is garbage collected.
    3) Generic code detects that last FDE (the glink .eh_frame) doesn't
       need to be padded to an 8 byte boundary, reducing size from 88 to
       84.
    4) elf64-ppc.c check fails.
    
    	PR 21441
    	* elf64-ppc.c (ppc64_elf_build_stubs): Don't check glink_eh_frame
    	size.

commit 3d13f3e9bda5aada68915f5d958f731ae79ed41d
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 19 11:59:30 2017 +0930

    PR22150, ld keeps a version reference for gc'd symbols
    
    elf_gc_sweep_symbol should run after verdefs are calculated, since
    the verdef code creates symbols for the versions.  However,
    elf_gc_sweep_symbol needs to run before verrefs so as to not emit
    useless verrefs for symbols that are gc'd.
    
    I've also removed a _bfd_elf_link_renumber_dynsyms calls added by
    Maciej after I fussed about it when reviewing.  On further examination
    the call appears to be unnecessary.  Looking at renumber_dynsyms also
    made me realize that the test to exclude .gnu.version has been wrong
    since 2016-04-26 (git commit d5486c4372), so fix that too.
    
    	PR 22150
    	* elflink.c (bfd_elf_size_dynamic_sections): Garbage collect
    	symbols before calculating verrefs.  Don't renumber dynsyms
    	after gc.  Exclude .gnu.version when zero or one dynsym.
    	Localize some vars and reindent.

commit ab502e635e78a6c6c9c8abf3072bfeedaca9c26f
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Sep 19 11:45:51 2017 +0930

    [GOLD, PowerPC] Add --no-stub-group-multi
    
    The trouble with stubs per output section is that ppc32 uses a plt
    stub as the address of a global function.  This needs to be unique,
    otherwise we'll get multiple addresses for a function.
    
    Obviously this is only a partial solution, since ppc32 will get
    multiple stubs when code is larger than 33M.  A proper fix will
    involve selecting a unique stub to use for non-branch relocs.
    
    	* options.h (stub-group-multi): Default to true.  Add
    	--no-stub-group-multi.

commit ced154d810b8e6ef10449030ba94fc8e66add468
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Sep 19 00:00:29 2017 +0000

    Automatic date update in version.in

commit 94670f6cf11fc29cc6db6814b38c4305d9bcac96
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Sep 18 13:05:25 2017 -0700

    Check error return from bfd_canonicalize_dynamic_reloc
    
    Since bfd_canonicalize_dynamic_reloc returns -1 on error, check it in
    _bfd_x86_elf_get_synthetic_symtab.
    
    	PR ld/22148
    	* elfxx-x86.c (_bfd_x86_elf_get_synthetic_symtab): Check error
    	return from bfd_canonicalize_dynamic_reloc.

commit 0615127c587253a6386fe49468fd64abf827273e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 18 13:09:20 2017 +0200

    dwarf2expr: Remove unused abort_expression label in execute_stack_op
    
    The label abort_expression is unused, so remove it.
    
    gdb/ChangeLog:
    
    	* dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
    	label abort_expression.

commit e4114cb89e65c53839d5beb80cec956476ecb5dc
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Sep 18 09:21:38 2017 +0100

    [PATCH] Sync libiberty/ & include/ with GCC - addendum: update elfcpp/dwarf.h with the new DW_CFA_DUP macro.
    
    From the original email:
      Note this brings in the interface files for libcc1/G++ as well, which
      we will be needing in GDB soon anyway.  That commit renamed a method
      in the C interface and that required a small update to GDB's compile/
      code, which I've included that in this patch to keep the tree
      building.
    
    From the follow up email:
      That breaks gold:
    
      g++ -DHAVE_CONFIG_H -I. -I../../binutils/gold  -I../../binutils/gold -I../../binutils/gold/../include -I../../binutils/gold/../elfcpp -DLOCALEDIR="\"/usr/share/locale\"" -DBINDIR="\"/usr/bin\"" -DTOOLBINDIR="\"/usr/x86_64-linux/bin\"" -DTOOLLIBDIR="\"/usr/x86_64-linux/lib\""   -W -Wall    -Werror -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -frandom-seed=dwarf_reader.o  -O2 -g -MT dwarf_reader.o -MD -MP -MF .deps/dwarf_reader.Tpo -c -o dwarf_reader.o ../../binutils/gold/dwarf_reader.cc
      In file included from ../../binutils/gold/../elfcpp/dwarf.h:83:0,
                       from ../../binutils/gold/dwarf_reader.cc:30:
      ../../binutils/gold/../include/dwarf2.def:781:1: error: expected ?}? before ?DW_CFA_DUP?
       DW_CFA_DUP (DW_CFA_AARCH64_negate_ra_state, 0x2d)

commit 35d3b1d74fd5e17174c97dac422f8c8d4ca0d8b8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Sep 18 00:00:30 2017 +0000

    Automatic date update in version.in

commit d9d0d1bc3f90ce4c1a86070a9832f706f2fb9200
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Sep 17 00:00:32 2017 +0000

    Automatic date update in version.in

commit 04fd3ba9b63936653fff2b1657b3824c94a8efd6
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 14:22:11 2017 +0200

    Refactor handle_qxfer_libraries and friends to use std::string
    
    Using std::string in handle_qxfer_libraries and friends allow to
    simplify the code.  We don't have to manually free the buffer, and we
    don't have to pre-compute the required space.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (accumulate_file_name_length): Remove.
    	(emit_dll_description): Adjust to std::string change.
    	(handle_qxfer_libraries): Use std::string to hold document.

commit 5e1875543df7413d3cbc3831390445e347064b75
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 14:19:31 2017 +0200

    Make xml_escape_text return an std::string
    
    This is a simple replacement, it allows removing some manual free'ing in
    the callers.
    
    gdb/ChangeLog:
    
    	* common/buffer.c (buffer_xml_printf): Adjust.
    	* common/xml-utils.c (xml_escape_text): Change return type to
    	std::string, update code accordingly.
    	* common/xml-utils.h (xml_escape_text): Change return type to
    	std::string.
    	* rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
    	* windows-tdep.c (windows_xfer_shared_library): Adjust.
    	* unittests/xml-utils-selftests.c (test_xml_escape_text):
    	Adjust.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
    	return type of xml_escape_text.
    	* server.c (emit_dll_description): Likewise.

commit c3d7b541fa920e6ecb0f06ffe1e0e3f070fa295d
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 14:16:27 2017 +0200

    Add unit test for xml_escape_text
    
    The following patch modifies xml_escape_text, so I took the opportunity
    to write a unit test for it.
    
    gdb/ChangeLog:
    
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
    	(SUBDIR_UNITTESTS_OBS): Add new object file.
    	* unittests/xml-utils-selftests.c: New file.

commit 1526853e34c063bef25bd7d0eb15c1449c28e999
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 14:06:03 2017 +0200

    Add selftests run filtering
    
    With the growing number of selftests, I think it would be useful to be
    able to run only a subset of the tests.  This patch associates a name to
    each registered selftest.  It then allows doing something like:
    
      (gdb) maintenance selftest aarch64
      Running self-tests.
      Running selftest aarch64-analyze-prologue.
      Running selftest aarch64-process-record.
      Ran 2 unit tests, 0 failed
    
    or with gdbserver:
    
      ./gdbserver --selftest=aarch64
    
    In both cases, only the tests that contain "aarch64" in their name are
    ran.  To help validate that the tests you want to run were actually ran,
    it also prints a message with the test name before running each test.
    
    Right now, all the arch-dependent tests are registered as a single test
    of the selftests.  To be able to filter those too, I made them
    "first-class citizen" selftests.  The selftest type is an interface,
    with different implementations for "simple selftests" and "arch
    selftests".  The run_tests function simply iterates on that an invokes
    operator() on each test.
    
    I changed the tests data structure from a vector to a map, because
    
      - it allows iterating in a stable (alphabetical) order
      - it allows to easily verify if a test with a given name has been
        registered, to avoid duplicates
    
    There's also a new command "maintenance info selftests" that lists the
    registered selftests.
    
    gdb/ChangeLog:
    
    	* common/selftest.h (selftest): New struct/interface.
    	(register_test): Add name parameter, add new overload.
    	(run_tests): Add filter parameter.
    	(for_each_selftest_ftype): New typedef.
    	(for_each_selftest): New declaration.
    	* common/selftest.c (tests): Change type to
    	map<string, unique_ptr<selftest>>.
    	(simple_selftest): New struct.
    	(register_test): New function.
    	(register_test): Add name parameter and use it.
    	(run_tests): Add filter parameter and use it.  Add prints.
    	Adjust to vector -> map change.
    	* aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
    	registering selftests.
    	* arm-tdep.c (_initialize_arm_tdep): Likewise.
    	* disasm-selftests.c (_initialize_disasm_selftests): Likewise.
    	* dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
    	* dwarf2loc.c (_initialize_dwarf2loc): Likewise.
    	* findvar.c (_initialize_findvar): Likewise.
    	* gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
    	* maint.c (maintenance_selftest): Update call to run_tests.
    	(maintenance_info_selftests): New function.
    	(_initialize_maint_cmds): Register "maintenance info selftests"
    	command.  Update "maintenance selftest" doc.
    	* regcache.c (_initialize_regcache): Add names when registering
    	selftests.
    	* rust-exp.y (_initialize_rust_exp): Likewise.
    	* selftest-arch.c (gdbarch_selftest): New struct.
    	(gdbarch_tests): Remove.
    	(register_test_foreach_arch): Add name parameter.  Call
    	register_test.
    	(tests_with_arch): Remove, move most content to
    	gdbarch_selftest::operator().
    	(_initialize_selftests_foreach_arch): Remove.
    	* selftest-arch.h (register_test_foreach_arch): Add name
    	parameter.
    	(run_tests_with_arch): New declaration.
    	* utils-selftests.c (_initialize_utils_selftests): Add names
    	when registering selftests.
    	* utils.c (_initialize_utils): Likewise.
    	* unittests/array-view-selftests.c
    	(_initialize_array_view_selftests): Likewise.
    	* unittests/environ-selftests.c (_initialize_environ_selftests):
    	Likewise.
    	* unittests/function-view-selftests.c
    	(_initialize_function_view_selftests): Likewise.
    	* unittests/offset-type-selftests.c
    	(_initialize_offset_type_selftests): Likewise.
    	* unittests/optional-selftests.c
    	(_initialize_optional_selftests): Likewise.
    	* unittests/scoped_restore-selftests.c
    	(_initialize_scoped_restore_selftests): Likewise.
    	* NEWS: Document "maintenance selftest" and "maint info
    	selftests".
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (captured_main): Accept argument for --selftest.
    	Update run_tests call.
    	* linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
    	when registering selftests.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (Maintenance Commands): Document filter parameter
    	of "maint selftest".  Document "maint info selftests" command.

commit 5846367a24e24f334077ceb7f7389acbd072b11a
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 13:45:56 2017 +0200

    mi_load_progress: Restore current_uiout using a scoped_restore
    
    Simply use a scoped_restore instead of manually saving and restoring
    current_uiout.
    
    gdb/ChangeLog:
    
    	* mi/mi-main.c (mi_load_progress): Restore current_uiout using a
    	scoped_restore.

commit bd77e8ff276864d6622f2433b8a499bf4332fa65
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 16 13:45:55 2017 +0200

    mi_load_progress: Use unique_ptr to manage ui_out lifetime
    
    In mi_load_progress, we xfree a ui_out object.  Because ui_out is not
    trivially destructible, it should be freed with delete.  This patch
    makes use of a unique_ptr to do it.
    
    gdb/ChangeLog:
    
    	* mi/mi-main.c (mi_load_progress): Make uiout variable
    	a unique_ptr.
    
    diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c index 0ee2605..0359dc1
    100644 --- a/gdb/mi/mi-main.c +++ b/gdb/mi/mi-main.c @@ -2325,7 +2325,6
    @@ mi_load_progress (const char *section_name, static char
    *previous_sect_name = NULL; int new_section; struct ui_out *saved_uiout;
    -  struct ui_out *uiout; struct mi_interp *mi = (struct mi_interp *)
       current_interpreter ();
    
       /* This function is called through deprecated_show_load_progress
    @@ -2333,17 +2332,19 @@ mi_load_progress (const char *section_name,
          of this function.  */
       saved_uiout = current_uiout;
    
    +  std::unique_ptr<ui_out> uiout;
    +
       if (current_interp_named_p (INTERP_MI)
           || current_interp_named_p (INTERP_MI2))
    -    current_uiout = mi_out_new (2);
    +    uiout.reset (mi_out_new (2));
       else if (current_interp_named_p (INTERP_MI1))
    -    current_uiout = mi_out_new (1);
    +    uiout.reset (mi_out_new (1));
       else if (current_interp_named_p (INTERP_MI3))
    -    current_uiout = mi_out_new (3);
    +    uiout.reset (mi_out_new (3));
       else
         return;
    
    -  uiout = current_uiout;
    +  current_uiout = uiout.get ();
    
       new_section = (previous_sect_name ?
     		 strcmp (previous_sect_name, section_name) : 1);
    @@ -2356,12 +2357,12 @@ mi_load_progress (const char *section_name,
     	fputs_unfiltered (current_token, mi->raw_stdout);
           fputs_unfiltered ("+download", mi->raw_stdout);
           {
    -	ui_out_emit_tuple tuple_emitter (uiout, NULL);
    +	ui_out_emit_tuple tuple_emitter (uiout.get (), NULL);
     	uiout->field_string ("section", section_name);
     	uiout->field_int ("section-size", total_section);
     	uiout->field_int ("total-size", grand_total);
           }
    -      mi_out_put (uiout, mi->raw_stdout);
    +      mi_out_put (uiout.get (), mi->raw_stdout);
           fputs_unfiltered ("\n", mi->raw_stdout);
           gdb_flush (mi->raw_stdout);
         }
    @@ -2374,19 +2375,18 @@ mi_load_progress (const char *section_name,
     	fputs_unfiltered (current_token, mi->raw_stdout);
           fputs_unfiltered ("+download", mi->raw_stdout);
           {
    -	ui_out_emit_tuple tuple_emitter (uiout, NULL);
    +	ui_out_emit_tuple tuple_emitter (uiout.get (), NULL);
     	uiout->field_string ("section", section_name);
     	uiout->field_int ("section-sent", sent_so_far);
     	uiout->field_int ("section-size", total_section);
     	uiout->field_int ("total-sent", total_sent);
     	uiout->field_int ("total-size", grand_total);
           }
    -      mi_out_put (uiout, mi->raw_stdout);
    +      mi_out_put (uiout.get (), mi->raw_stdout);
           fputs_unfiltered ("\n", mi->raw_stdout);
           gdb_flush (mi->raw_stdout);
         }
    
    -  xfree (uiout);
       current_uiout = saved_uiout;
     }

commit c4dfafabc575f4995a5aa18241adc275e63c846c
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sun Sep 10 12:17:18 2017 -0400

    Use std::vector on tdesc->reg_defs (gdbserver/tdesc.h)
    
    This is a followup patch to the build breakage fix on AArch64.  While
    doing the fix, I found it better to convert tdesc->reg_defs (on
    gdbserver/tdesc.h) from using VEC to using std::vector.  This makes
    the code easier to read and maintain, and also is one more step
    towards the C++fication.
    
    Regtested on BuildBot.
    
    2017-09-16  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* regcache.c (get_thread_regcache): Update code to use "std::vector"
    	instead of "VEC" for "target_desc.reg_defs".
    	(regcache_cpy): Likewise.
    	(registers_to_string): Likewise.
    	(registers_from_string): Likewise.
    	(find_regno): Likewise.
    	(supply_regblock): Likewise.
    	(regcache_raw_read_unsigned): Likewise.
    	* tdesc.c (init_target_desc): Likewise.
    	(tdesc_create_reg): Likewise.
    	* tdesc.h: Remove declaration of "tdesc_reg_p".  Include <vector>.
    	(struct target_desc) <reg_defs>: Convert to "std::vector".
    	(target_desc): Do not initialize "reg_defs".
    	(~target_desc): Update code to use "std::vector" instead of "VEC"
    	for "target_desc.reg_defs".
    	(operator==): Likewise.

commit ebee3285b3a44ef2854e9ec84a0c92f5cca4da68
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Sep 16 00:00:34 2017 +0000

    Automatic date update in version.in

commit 26a67918a501370a8fe62db18a74761a0073016f
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Sep 15 17:40:33 2017 +0100

    Sync libiberty/ & include/ with GCC
    
    Note this brings in the interface files for libcc1/G++ as well, which
    we will be needing in GDB soon anyway.  That commit renamed a method
    in the C interface and that required a small update to GDB's compile/
    code, which I've included that in this patch to keep the tree
    building.
    
    include/ChangeLog:
    2017-09-15  Pedro Alves  <palves@redhat.com>
    
    	* ansidecl.h (DISABLE_COPY_AND_ASSIGN): New macro.
    
    	2017-09-12  Jiong Wang  <jiong.wang@arm.com>
    
    	* dwarf2.def (DW_CFA_AARCH64_negate_ra_state): New DW_CFA_DUP.
    	* dwarf2.h (DW_CFA_DUP): New define.
    
    	2017-08-21  Richard Biener  <rguenther@suse.de>
    
    	* simple-object.h (simple_object_copy_lto_debug_sections): New
    	function.
    
    	2017-05-18  Martin Liska  <mliska@suse.cz>
    
    	* ansidecl.h: Define CONSTEXPR macro.
    
    	2017-05-24  Nathan Sidwell  <nathan@acm.org>
    
    	* libiberty.h (ASTRDUP): Adjust cast to avoid warning.
    
    	2017-01-30  Alexandre Oliva <aoliva@redhat.com>
    
    	Introduce C++ support in libcc1.
    	* gcc-c-fe.def (int_type_v0): Rename from...
    	(int_type): ... this.  Introduce new version.
    	(float_type_v0): Rename from...
    	(float_type): ... this.  Introduce new version.
    	(char_type): New.
    	* gcc-c-interface.h (gcc_c_api_version): Add GCC_C_FE_VERSION_1.
    	(gcc_type_array): Move...
    	* gcc-interface.h: ... here.
    	* gcc-cp-fe.def: New.
    	* gcc-cp-interface.h: New.
    
    	2016-04-29  Oleg Endo  <olegendo@gcc.gnu.org>
    
    	* longlong.h (umul_ppmm): Remove SHMEDIA checks.
    	(__umulsidi3, count_leading_zeros): Remove SHMEDIA implementations.
    
    	2017-09-15  Yao Qi  <yao.qi@linaro.org>
    	    Pedro Alves  <palves@redhat.com>
    
    	* ansidecl.h (DISABLE_COPY_AND_ASSIGN): New macro.
    
    	2017-09-12  Jiong Wang  <jiong.wang@arm.com>
    
    	* dwarf2.def (DW_CFA_AARCH64_negate_ra_state): New DW_CFA_DUP.
    	* dwarf2.h (DW_CFA_DUP): New define.
    
    	2017-08-21  Richard Biener  <rguenther@suse.de>
    
    	* simple-object.h (simple_object_copy_lto_debug_sections): New
    	function.
    
    	2017-05-18  Martin Liska  <mliska@suse.cz>
    
    	* ansidecl.h: Define CONSTEXPR macro.
    
    	2017-05-24  Nathan Sidwell  <nathan@acm.org>
    
    	* libiberty.h (ASTRDUP): Adjust cast to avoid warning.
    
    	2017-01-30  Alexandre Oliva <aoliva@redhat.com>
    
    	Introduce C++ support in libcc1.
    	* gcc-c-fe.def (int_type_v0): Rename from...
    	(int_type): ... this.  Introduce new version.
    	(float_type_v0): Rename from...
    	(float_type): ... this.  Introduce new version.
    	(char_type): New.
    	* gcc-c-interface.h (gcc_c_api_version): Add GCC_C_FE_VERSION_1.
    	(gcc_type_array): Move...
    	* gcc-interface.h: ... here.
    	* gcc-cp-fe.def: New.
    	* gcc-cp-interface.h: New.
    
    	2016-04-29  Oleg Endo  <olegendo@gcc.gnu.org>
    
    	* longlong.h (umul_ppmm): Remove SHMEDIA checks.
    	(__umulsidi3, count_leading_zeros): Remove SHMEDIA implementations.
    
    libiberty/ChangeLog:
    2017-09-15  Nathan Sidwell  <nathan@acm.org>
    
    	PR demangler/82195
    	* cp-demangle.c (d_name): Add 'toplevel' parm.  Pass to	...
    	(d_local_name): ... here.  Parse trailing function args on nested
    	local_name.
    	(d_encoding, d_special_name, d_class_enum_type): Adjust d_name calls.
    	* testsuite/demangle-expected: Add tests.
    
    2017-09-15  Richard Biener  <rguenther@suse.de>
    
    	PR lto/81968
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
    	Iterate marking dependent sections necessary.
    
    2017-09-15  Nathan Sidwell  <nathan@acm.org>
    
    	* cp-demangle.c (is_fnqual_component_type): Reimplement using
    	FNQUAL_COMPONENT_CASE.
    	(d_encoding): Hold bare_function_type in local var.
    	(d_local_name): Build name in both cases and build result once.
    	Collapse switch-if to single conditional.
    	(d_local_name):
    
    	* testsuite/demangle-expected: Realign blank lines with tests.
    
    2017-09-12  Jiong Wang  <jiong.wang@arm.com>
    
    	* dwarfnames.c (DW_CFA_DUP): New define.
    
    gdb/ChangeLog:
    2017-09-15  Pedro Alves  <palves@redhat.com>
    
    	* compile/compile-c-types.c (convert_enum, convert_int)
    	(convert_float): Adjust to refer to int_type_v0 and float_type_v0.

commit 124aceb46dfd1f836f35d6075ead4e00e705f6f3
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 18:02:51 2017 +0200

    gdbserver: Remove thread_to_gdb_id
    
    As explained in the previous patch, the gdb_id concept is no longer
    relevant.  The function thread_to_gdb_id is trivial, it returns the
    thread's ptid.  Remove it and replace its usage with ptid_of.
    
    The changes in nto-low.c and lynx-low.c are fairly straightforward, but
    I was not able to build test them.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h (thread_to_gdb_id): Remove.
    	* inferiors.c (thread_to_gdb_id): Remove.
    	* server.c (handle_qxfer_threads_worker, handle_query): Adjust.
    	* lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
    	lynx_store_registers, lynx_read_memory, lynx_write_memory):
    	Likewise.
    	* nto-low.c (nto_fetch_registers, nto_store_registers,
    	nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.

commit 96cde54f0adf2315404f3eba35dc3dfbc57f98c8
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 18:02:51 2017 +0200

    gdbserver: Remove gdb_id_to_thread_id
    
    From what I understand, this function is not doing anything useful as of
    today.
    
    Here's the result of my archeological research:
    
    - The field thread_info::gdb_id was added in
    
      a06660f7  Use LWP IDs for thread IDs in gdbserver
    
      There was problem when using a 32-bits gdb with a 64-bits gdbserver.
      For some reason that I don't fully understand, the thread ids
      exchanged between gdb and gdbserver could overflow a 32 bits data
      type.  My guess is that they were the thread address (e.g. the
      0x7ffff7f20b40 in "Thread 0x7ffff7f20b40 (LWP 1058)" today).  This
      patch changed that so gdb/gdbserver would talk in terms of the OS
      assigned numerical id (as shown in ps).  It therefore added a way to
      convert between this gdb_id (the numerical id) and the thread id (the
      address).
    
    - 95954743cb  Implement the multiprocess extensions, and add linux
                  multiprocess supportNon-stop mode support.
    
      This patch made gdbserver deal with threads using their numerical ids
      and not the address-like id.  Starting from there, the gdb_id <->
      thread id conversion was not needed anymore, since the remote protocol
      and gdbserver were using the same kind of ids again.  The gdb_id field
      in the thread_info structure was also unused starting there.
    
    - d50171e4  Teach linux gdbserver to step-over-breakpoints.
    
      This patch moved the thread_info structure around, and got rid of the
      gdb_id field (which was unused).
    
    Looking at the implementation of gdb_id_to_thread_id, it is not doing
    anything useful.  It is looking up a thread by ptid using
    find_thread_ptid, which basically loops over all threads looking at
    their entry.id field.  If a thread with that ptid is found, it returns
    its entry.id field.  So it will always return the same thing as it input
    (with the exception of if no thread exist with that ptid, then it will
    return null_ptid).
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h (gdb_id_to_thread_id): Remove.
    	* inferiors.c (gdb_id_to_thread_id): Remove.
    	* server.c (process_serial_event): Adjust to gdb_id_to_thread_id
    	removal.  Move pid declaration closer to where it's used.

commit e8ca139ed036e6da8adf42fc6fbd93973b724d3c
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 17:59:37 2017 +0200

    gdbserver: Move detach code to its own function
    
    The code required to handle the 'D' packet is non trivial, so move it
    out to its own function.
    
    The moved out code is identical, except for the call to strtol and some
    breaks that became returns.
    
    Tested manually, and by running gdb.base/*detach*.exp with
    native-gdbserver and native-extended-gdbserver.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (handle_detach): New function.
    	(process_serial_event): Move code out, call handle_detach.

commit f8a4e1192032044cdae544848865636f6e07a925
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 17:59:36 2017 +0200

    Deduplicate require_running macros and move them up
    
    I find it very confusing to define the require_running in the middle of
    the file, and re-define it to something else later in the middle of the
    same file.  I think it would be better if those macros had different
    names so that we know exactly what they do.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (require_running): Rename to ...
    	(require_running_or_return): ... this ...
    	(require_running_or_break): ... and this.
    	(handle_query, process_serial_event): Adjust.

commit ef87240fd95c5f29a697eccf20b2f1f6dc3593a6
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Sep 15 16:18:20 2017 +0100

    Add -l option to src-release script.
    
    Since we are updating src-release.sh I thought I would check in this
    small patch.  It adds the option to create lzip compressed tarballs
    via the -l command line option.
    
    	* src-release.sh (LZIPPROG): New define.  Provides the name of the
    	lzip program.
    	(do_lz): New function.  Compresses a tarball using the lzip
    	program.
    	(do_compress): Add support for lzip compression.
    	(usage): Mention -l option.
    	(build_release): Support -l option to invoke lzip compression.

commit 0eb0a40713c6479e782e5a257793d28f647e38bd
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 16:41:35 2017 +0200

    linux-low: Remove unused variables
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (linux_set_resume_request): Remove unused
    	variables.

commit 3f8a7804287d3153fb4a8676b7304e67cca32be4
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 16:41:34 2017 +0200

    dwarf2read: Replace copy_string usages with savestring
    
    copy_string does the exact same thing as savestring, so replace the
    usages of the former with the latter.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (copy_string): Remove.
    	(parse_macro_definition): Replace copy_string with savestring.

commit 785922a559529420ce9b11342d7abe6ad32b3595
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Sep 15 14:53:07 2017 +0200

    gdbserver: Remove duplicate functions to find any thread of process
    
    We have about 6 functions/callbacks to find_inferior meant to find a
    thread that belongs to a given pid.  Remove all but
    find_any_thread_of_pid and replace their uses with
    find_any_thread_of_pid.
    
    gdb/gdbserver/ChangeLog:
    
    	* server.c (first_thread_of): Remove.
    	(process_serial_event): Replace usage of first_thread_of with
    	find_any_thread_of_pid.
    	* tracepoint.c (same_process_p): Remove.
    	(gdb_agent_about_to_close): Replace usage of same_process_p with
    	find_any_thread_of_pid.
    	* linux-x86-low.c (same_process_callback): Remove.
    	(x86_arch_setup_process_callback): Replace usage of
    	same_process_callback with find_any_thread_of_pid.
    	* thread-db.c (any_thread_of): Remove.
    	(switch_to_process): Replace usage of any_thread_of with
    	find_any_thread_of_pid.
    	* inferiors.c (thread_pid_matches_callback): Remove.
    	(find_thread_process): Adjust to use find_any_thread_of_pid.

commit 8d20070632b608587f372cf2d36ead339487e49c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Sep 15 13:05:39 2017 +0100

    Fix x86 build failures
    
    Christophe Lyon told me that GDB build failed on i386-linux with
    --enable-64-bit-bfd=yes, so I audit the gdb/configure.tgt again.  I
    find that i386-darwin has the same issue too.  Additionally, GDB
    for solaris target fails to build too.  This patch fixes all of them.
    
    gdb:
    
    2017-09-15  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
    	gdb_target_obs.
    	(i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
    	Likewise.
    	(i[34567]86-*-linux*): Likewise.

commit 8fd138c43b3a820e1d7deec80c9290b458f09d63
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 15 20:08:02 2017 +0930

    PR22118, Incorrectly-capitalized regexp
    
    	PR 22118
    	* testsuite/ld-aarch64/erratum843419.d: Correct regexp.

commit 817b77113459d8b66a75f4fdbba0a3f5f6936c9b
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 15 14:33:58 2017 +0930

    Enable/disable various dirs in src-release.sh
    
    gold needs to be enabled for a binutils release, but it's rather odd
    to do so for gas, gdb or sim.  This patch passes various --enable and
    --disable options depending on the directories being released.
    
    	* src-release.sh (do_proto_toplev): Revert last patch.  Enable or
    	disable binutils, gas, gdb, gold, gprof, ld, libdecnumber, readline,
    	and sim depending on $tool and $support_files.  Echo configure line.

commit 21d0a60620b306d6471ddedff04ac23912596cc6
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Sep 15 10:22:13 2017 +0930

    Error when 32-bit ar tries to handle 4G or larger files
    
    We used to silently truncate the size returned by stat() to 32 bits.
    While it is possible to make binutils handle a 64-bit off_t on a
    32-bit host, to me the effort needed doesn't seem worth the benefit.
    Instead, error if we truncate the size.  I've written the test the way
    I have to avoid a signed/unsigned warning.
    
    	PR 22116
    	* archive.c (bfd_ar_hdr_from_filesystem): Detect when status.st_size
    	overflows bfd_size_type.

commit cc3e190059e6c817203049a52c8bc4b37b58ce74
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Sep 15 00:00:28 2017 +0000

    Automatic date update in version.in

commit d185219da329805075ba5e0e72ec4c89c925cff2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 14 22:36:57 2017 +0200

    Make dwarf_expr_context::stack an std::vector
    
    Replace the manually managed array with a vector.  It is mostly
    straightforward, except maybe one thing in execute_stack_op, in the
    handling of DW_OP_fbreg.  When the code stumbles on that opcode while
    evaluating an expression, it needs to evaluate a subexpression to find
    where the fb reg has been saved.  Rather than creating a new context, it
    reuses the current context.  It saves the size of the stack before and
    restores the stack to that size after.
    
    I think we can do a little bit better by saving the current stack
    locally and installing a new empty stack.  This way, if the
    subexpression is malformed and underflows, we'll get an exception.
    Before, it would have overwritten the top elements of the top-level
    expression.  The evaluation of the top-level expression would have then
    resumed with the same stack size, but possibly some corrupted elements.
    
    gdb/ChangeLog:
    
    	* dwarf2expr.h (dwarf_stack_value): Add constructor.
    	(dwarf_expr_context) <~dwarf_expr_context>: Define as default.
    	<stack>: Change type to std::vector.
    	<stack_len, stack_allocated>: Remove.
    	<grow_stack>: Remove.
    	* dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
    	(dwarf_expr_context::~dwarf_expr_context): Remove.
    	(dwarf_expr_context::grow_stack): Remove.
    	(dwarf_expr_context::push): Adjust.
    	(dwarf_expr_context::pop): Adjust.
    	(dwarf_expr_context::fetch): Adjust.
    	(dwarf_expr_context::fetch_in_stack_memory): Adjust.
    	(dwarf_expr_context::stack_empty_p): Adjust.
    	(dwarf_expr_context::execute_stack_op): Adjust.

commit 5f93de4cca61a449e507b8bd12a2ea2379469c3f
Merge: 8057eaf 79254a5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 14 12:50:33 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 79254a5260cf49887b4017700bd75b27f483b322
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 14 12:45:18 2017 -0700

    globalaudit.rd: Allow additional bits in DT_FLAGS_1
    
    With -PIE on x86-64, we get
    
     0x000000006ffffffb (FLAGS_1)            Flags: GLOBAUDIT PIE
    
    We should allow additional bits in DT_FLAGS_1.
    
    	PR ld/22139
    	* testsuite/ld-elf/globalaudit.rd: Allow additional bits in
    	DT_FLAGS_1.

commit 5e5e02aeca4a6edccbf11b5f900d95bba59b9932
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 14 11:41:58 2017 -0700

    x86: Cache section contents and relocations
    
    bfd/
    
    	PR ld/22135
    	* elf32-i386.c (elf_i386_convert_load_reloc): Add an argument
    	to indicate if conversion is performed.
    	(elf_i386_check_relocs): Cache section contents and relocations
    	if conversion is performed.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Cache section
    	contents and relocations if conversion is performed.
    
    ld/
    
    	PR ld/22135
    	* testsuite/ld-i386/i386.exp: Run pr22135.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-i386/pr22135.d: New file.
    	* testsuite/ld-i386/pr22135.s: Likewise.
    	* testsuite/ld-x86-64/pr22135.d: Likewise.
    	* testsuite/ld-x86-64/pr22135.s: Likewise.

commit 26e53f3eace35cabeec4559d417df99a48f6477a
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Sep 14 18:09:42 2017 +0100

    gdb.base/nodebug.exp: Rename called functions
    
    I'm seeing these failures on my system:
    
      FAIL: gdb.base/nodebug.exp: p (double) mult (2.0, 3.0)
      FAIL: gdb.base/nodebug.exp: p ((double (*) (double, double)) mult)(2.0f, 3.0f)
      FAIL: gdb.base/nodebug.exp: p ((double (*) (double, double)) mult)(2, 3)
    
    The problem is simply that GDB is finding a symbol named "mult" from
    glibc's debug info:
    
      (gdb) ptype mult
      type = enum expression_operator {var, num, lnot, mult, divide, module, plus, minus, less_than, greater_than, less_or_equal, greater_or_equal, equal, not_equal, land, lor,  qmop}
    
      (gdb) info types expression_operator
      All types matching regular expression "expression_operator":
    
      File plural-exp.h:
      enum expression_operator;
    
    Fix this by unloading symbols from shared libraries.
    
    gdb/testsuite/ChangeLog:
    2017-09-14  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/nodebug.exp (nodebug_runto): New procedure.
    	(top level): Use it instead of runto.

commit 8057eafd5c0d64feb4c3ca381028d5e554558be6
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 14 08:46:15 2017 -0700

    Apply 2 elfxx-x86 patches
    
    1. x86: Add _bfd_x86_elf_finish_dynamic_sections
    2. x86: Add elf_x86_backend_data

commit 365ccbe036f44e8c08251cbc42c84fca3765ecc6
Merge: 372b26b eccd80d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 14 08:27:10 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit eccd80d69487586578b7e085d8bd48657a4d7322
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 14 16:54:37 2017 +0200

    Make dwarf_expr_context::stack_empty_p return a bool
    
    gdb/ChangeLog:
    
    	* dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
    	return type to bool.
    	* dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.

commit 690098826e36cbadf618e15eed5f6ebf606cbf74
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 14 16:13:33 2017 +0200

    Make dwarf_stack_value::in_stack_memory a bool
    
    Replace int with bool, because that's what it is.
    
    gdb/ChangeLog:
    
    	* dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
    	Change type to bool.
    	(dwarf_stack_value) <in_stack_memory>: Likewise.
    	(dwarf_expr_context) <push_address>: Change parameter type to
    	bool.
    	<fetch_in_stack_memory>: Change return type to bool.
    	<push>: Change parameter type to bool.
    	* dwarf2expr.c (dwarf_expr_context::push): Change parameter type
    	to bool.
    	(dwarf_expr_context::push_address): Likewise.
    	(dwarf_expr_context::fetch_in_stack_memory): Change return type
    	to bool.
    	(dwarf_expr_context::execute_stack_op): Adjust.
    	* dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.

commit 1e467161932b6385b51d0bd365a91cf205b399b9
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Sep 14 15:57:01 2017 +0200

    Make dwarf_expr_piece::pieces an std::vector
    
    Change the manually managed array dwarf_expr_piece::piece with an
    std::vector.  After passing the pieces array to allocate_piece_closure,
    dwarf2_evaluate_loc_desc_full doesn't need that data anymore.  We can
    therefore move the content of the vector to avoid copying it.
    
    Reg-tested on the buildbot.
    
    gdb/ChangeLog:
    
    	* dwarf2expr.h (struct dwarf_expr_piece): Move up.
    	(struct dwarf_expr_context) <n_pieces>: Remove.
    	<pieces>: Change type to std::vector.
    	* dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
    	(dwarf_expr_context::~dwarf_expr_context): Don't manually free
    	pieces.
    	(dwarf_expr_context::add_piece): Adjust.
    	* dwarf2loc.c (struct piece_closure): Initialize fields.
    	<n_pieces>: Remove.
    	<pieces>: Change type to std::vector.
    	(allocate_piece_closure): Adjust, change parameter to
    	std::vector rvalue and std::move it to piece_closure.
    	(rw_pieced_value): Adjust.
    	(check_pieced_synthetic_pointer): Adjust.
    	(indirect_synthetic_pointer): Adjust.
    	(coerce_pieced_ref): Adjust.
    	(free_pieced_value_closure):  Adjust.  Use delete to free
    	piece_closure.
    	(dwarf2_evaluate_loc_desc_full): Adjust.  std::move ctx.pieces
    	to allocate_piece_closure.
    	(dwarf2_loc_desc_get_symbol_read_needs): Adjust.

commit 4d465c689a8fb27212ef358d0aee89d60dee69a6
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Sep 14 11:15:55 2017 +0100

    Fix address violation when parsing a corrupt PE binary.
    
    	PR binutils/22113
    	* peXXigen.c (pe_print_idata): Extend check for HintName vector
    	entries.

commit 255300f5a96079a9860934c44bb9521e7aca45de
Author: matt rice <ratmice@gmail.com>
Date:   Wed Sep 13 09:46:22 2017 -0700

    Add enable-gold and enable-ld to src-release
    
    So that the tarball picks up gold bison output.
    
    	* src-release.sh (do_proto_toplev): Enable gold during release process.

commit 2578f2f307f7e80caa0bce32c7fa880d579e736b
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Sep 14 10:19:31 2017 +0930

    PR22127, as segfaults assembling invalid .reloc
    
    "sec" gets set to NULL on errors in the offset expression.  This patch
    disables part of the reloc expression processing that needs "sec"
    valid.  I didn't disable the entire reloc expression handling so that
    errors in the reloc expression are reported even when the offset
    expression has an error.
    
    	PR 22127
    	* write.c (resolve_reloc_expr_symbols): Don't segfault when
    	sec has been set to NULL.

commit 0952b7101e85b205f93389216a7733caccb8f267
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Sep 14 00:00:26 2017 +0000

    Automatic date update in version.in

commit f47432d4b99a453f9107b7fd5e173384f983e679
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 13 04:25:14 2017 -0700

    elfxx-x86.h: Fix a typo in comments
    
    	* elfxx-x86.h: Fix a typo in comments.

commit 9f2815a079efa19ae520293c455ec2910a9879ac
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Sep 13 00:00:31 2017 +0000

    Automatic date update in version.in

commit 0782db848b52ecaf29e13d9f12a2c7cfabec2bdb
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 12 14:15:23 2017 +0200

    probe: Replace VEC(probe_ops_cp) with std::vector
    
    This patch replaces the usage of VEC to store pointers to probe_ops with
    an std::vector.  The sole usage of that vector type is one global
    variable that holds the ops for the various kinds of probes, so this is
    pretty straightforward (no allocation/deallocation issues).
    
    gdb/ChangeLog:
    
    	* probe.h (probe_ops_cp): Remove typedef.
    	(DEF_VEC_P (probe_ops_cp)): Remove.
    	(all_probe_ops): Change type to std::vector.
    	* probe.c (info_probes_for_ops): Adjust to vector change.
    	(probe_linespec_to_ops): Likewise.
    	(all_probe_ops): Change type to std::vector.
    	(_initialize_probe): Adjust to vector change.
    	* dtrace-probe.c (_initialize_dtrace_probe): Likewise.
    	* elfread.c (elf_get_probes): Likewise.
    	* stap-probe.c (_initialize_stap_probe): Likewise.

commit 1eac6bea98f41ee12ba9e750a9578bd8585011c9
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 12 13:55:32 2017 +0200

    Make collect_probes return an std::vector
    
    Change collect_probes so it returns an std::vector<bound_probe> instead
    of a VEC(bound_probe_s).  This allows removing some cleanups.  It also
    seems like enable_probes_command and disable_probes_command were not
    freeing that vector.
    
    The comparison function compare_probes needs to be updated to return a
    bool indicating whether the first parameter is "less than" the second
    parameter.
    
    I defined two constructors to bound_probe.  The default constructor is
    needed, for example, so the instance in struct bp_location can be
    constructed without parameters.  The constructor with parameters is
    useful so we can use emplace_back and pass the values directly.
    
    The s390 builder on the buildbot shows a weird failure that I can't
    explain:
    
    ../../binutils-gdb/gdb/elfread.c: In function void probe_key_free(bfd*, void*):
    ../../binutils-gdb/gdb/elfread.c:1346:8: error: types may not be defined in a for-range-declaration [-Werror]
       for (struct probe *probe : *probes)
            ^~~~~~
    
    I guess it's a bug with that specific version< of the compiler, since no
    other gcc gives me that error.  It is using:
    
      g++ (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1)
    
    Any idea about this problem?
    
    gdb/ChangeLog:
    
    	* probe.h (struct bound_probe): Define constructors.
    	* probe.c (bound_probe_s): Remove typedef.
    	(DEF_VEC_O (bound_probe_s)): Remove VEC.
    	(collect_probes): Change return type to std::vector, remove
    	cleanup.
    	(compare_probes): Return bool, change parameter type.  Change
    	semantic to "less than".
    	(gen_ui_out_table_header_info): Change parameter to std::vector
    	and update.
    	(exists_probe_with_pops): Likewise.
    	(info_probes_for_ops): Update to std::vector change.
    	(enable_probes_command): Likewise.
    	(disable_probes_command): Likewise.

commit aaa63a31909946c4f68da64a93662147d67630bd
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 12 13:37:00 2017 +0200

    Make probe_ops::get_probes fill an std::vector
    
    This patch changes one usage of VEC to std::vector.  It is a relatively
    straightforward 1:1 change.  The implementations of
    sym_probe_fns::sym_get_probes return a borrowed reference to their probe
    vectors, meaning that the caller should not free it.  In the new code, I
    made them return a const reference to the vector.
    
    This patch and the following one were tested by the buildbot.  I didn't
    see any failures that looked related to this one.
    
    gdb/ChangeLog:
    
    	* probe.h (struct probe_ops) <get_probes>: Change parameter from
    	vec to std::vector.
    	* probe.c (parse_probes_in_pspace): Update.
    	(find_probes_in_objfile): Update.
    	(find_probe_by_pc): Update.
    	(collect_probes): Update.
    	(probe_any_get_probes): Update.
    	* symfile.h (struct sym_probe_fns) <sym_get_probes> Change
    	return type to reference to std::vector.
    	* dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
    	std::vector and update.
    	(dtrace_process_dof): Likewise.
    	(dtrace_get_probes): Likewise.
    	* elfread.c (elf_get_probes): Change return type to std::vector,
    	store an std::vector in bfd_data.
    	(probe_key_free): Update to std::vector.
    	* stap-probe.c (handle_stap_probe): Change parameter to
    	std::vector and update.
    	(stap_get_probes): Likewise.
    	* symfile-debug.c (debug_sym_get_probes): Change return type to
    	std::vector and update.

commit 331f81b22cb6b2a8dec2acc0a728c4159c1c7b5e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Sep 12 00:00:28 2017 +0000

    Automatic date update in version.in

commit cb85b21ba1c0014787129d3f53cb8755aba64930
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 10:47:10 2017 -0600

    Remove make_show_memory_breakpoints_cleanup
    
    This removes make_show_memory_breakpoints_cleanup, replacing it with
    make_scoped_restore_show_memory_breakpoints and updating all callers.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (program_breakpoint_here_p): Update.
    	* target.c (make_scoped_restore_show_memory_breakpoints): Rename
    	from make_show_memory_breakpoints_cleanup.  Return a
    	scoped_restore_tmpl<int>.
    	(restore_show_memory_breakpoints): Remove.
    	* ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
    	* mem-break.c (memory_validate_breakpoint): Update.
    	* ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
    	(ia64_memory_remove_breakpoint): Update.
    	(ia64_breakpoint_from_pc): Update.
    	* target.h (make_scoped_restore_show_memory_breakpoints): Rename
    	from make_show_memory_breakpoints_cleanup.

commit 8fbc99ef16dfb49981e275f735cb591e68983d08
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 10:46:36 2017 -0600

    Use std::string in d-namespace.c
    
    This removes some cleanups from d-namespace.c by replacing manual
    string management with std::string.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* d-namespace.c (d_lookup_symbol): Use std::string.
    	(find_symbol_in_baseclass): Likewise.

commit 50feb4bd435b86c73ea55049b7cf87cc709c1388
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 10:17:11 2017 -0600

    Use std::string in ctf_start
    
    This changes ctf_start to use std::string, allowing for some cleanup
    removal.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* ctf.c (ctf_start): Use std::string.

commit c6dc63a16299e22fcb5bc13b34cb402a1bfcf6b9
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 10:14:52 2017 -0600

    Remove cleanups from find_frame_funname
    
    This changes find_frame_funname to return a unique_xmalloc_ptr and
    then fixes up the callers.  This removes several cleanups.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* ada-lang.c (is_known_support_routine): Update.
    	(ada_unhandled_exception_name_addr_from_raise): Update.
    	* guile/scm-frame.c (gdbscm_frame_name): Update.
    	* python/py-frame.c (frapy_name): Update.
    	(frapy_function): Update.
    	* stack.h (find_frame_funname): Update.
    	* stack.c (find_frame_funname): Return unique_xmalloc_ptr.
    	(print_frame): Update.

commit d6b9b80f9483b6c1a3a018c0fcaf813ca098d8af
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 09:56:27 2017 -0600

    Remove cleanups from findcmd.c
    
    This removes cleanups from findcmd.c, replacing manual buffer
    management with a gdb::byte_vector.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* findcmd.c (put_bits): Take a gdb::byte_vector.
    	(parse_find_args): Return gdb::byte_vector.  "args" now const.
    	Remove "pattern_bufp" and "pattern_lenp" parameters.  Remove
    	cleanups.
    	(find_command): Update.

commit a9921622de0a7332a333c5206ce8cd632803df97
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 14:44:08 2017 -0600

    Replace clear_hook_in_cleanup with scoped_restore_hook_in
    
    This removes clear_hook_in_cleanup in favor of a scoped_restore-like
    class.  scoped_restore itself can't be used because hook_in is a
    bitfield.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-script.c (class scoped_restore_hook_in): New.
    	(clear_hook_in_cleanup): Remove.
    	(execute_cmd_pre_hook, execute_cmd_post_hook): Use
    	scoped_restore_hook_in.

commit be0d7abb5e3b0be4cb928845e70a9134f1b19700
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 14:40:46 2017 -0600

    Replace interp_set_temp with scoped_restore_interp
    
    This removes interp_set_temp and an associated cleanup, in favor of a
    new RAII class, scoped_restore_interp.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-script.c (restore_interp): Remove.
    	(read_command_lines): Use scoped_restore_interp.
    	* interps.c (scoped_restore_interp::set_temp): Rename from
    	interp_set_temp.
    	* interps.h (class scoped_restore_interp): New.
    	(interp_set_temp): Remove.

commit 00f675ff65ff6f78712a46e9699856e935d86d86
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:55:28 2017 -0600

    Change setup_breakpoint_reporting to return a scoped_restore
    
    This changes setup_breakpoint_reporting to return a scoped_restore,
    allowing for some cleanup removal.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-catch.c (mi_cmd_catch_assert)
    	(mi_cmd_catch_exception, mi_catch_load_unload): Update.
    	* mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
    	scoped_restore.
    	(mi_cmd_break_insert_1): Update.
    	* mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
    	scoped_restore.

commit cb791d59489576280e416262eb61ab59765a0baf
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 10 14:48:30 2017 -0600

    Make extract_arg return a std::string
    
    Change extract_arg to return a std::string and fix up all the users.
    I think string is mildly better than unique_xmalloc_ptr<char>, when
    possible, because it provides a more robust API.
    
    I changed the error messages emitted from find_location_by_number to
    avoid either writing to a string or an extra allocation; this can be
    changed but I thought that the new message was not any less clear.
    You can see an example in the testsuite patch.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* demangle.c (demangle_command): Update.
    	* breakpoint.c (disable_command): Update.
    	(enable_command): Update.
    	(find_location_by_number): Make "number" const.  Use
    	get_number_trailer.
    	* cli/cli-utils.c (extract_arg): Return std::string.
    	* probe.c (parse_probe_linespec): Update.  Change types.
    	(collect_probes): Take string arguments.
    	(parse_probe_linespec): Likewise.
    	(info_probes_for_ops): Update.
    	(enable_probes_command): Update.
    	(disable_probes_command): Update.
    	* break-catch-sig.c (catch_signal_split_args): Update.
    	* mi/mi-parse.c (mi_parse): Update.
    
    testsuite/ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* gdb.base/ena-dis-br.exp (test_ena_dis_br): Update test.

commit 2039bd9f0ce667f3f0ee99c18e25de1ea18a2288
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 10 14:29:22 2017 -0600

    Constify language_enum
    
    Change language_enum to take a const argument.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* language.h (language_enum): Make argument const.
    	* language.c (language_enum): Make argument const.

commit f1735a53a63040cc4b4a735bf18a3f20d308e519
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 10 14:19:19 2017 -0600

    Rename _const functions to use overloading instead
    
    This renames a few functions -- skip_spaces_const,
    skip_to_space_const, get_number_const, extract_arg_const -- to drop
    the "_const" suffix and instead rely on overloading.
    
    This makes future const fixes simpler by reducing the number of lines
    that must be changed.  I think it is also not any less clear, as all
    these functions have the same interface as their non-const versions by
    design.  Furthermore there's an example of using an overload in-tree
    already, namely check_for_argument.
    
    This patch was largely created using some perl one-liners; then a few
    fixes were applied by hand.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* common/common-utils.h (skip_to_space): Remove macro, redeclare
    	as function.
    	(skip_to_space): Rename from skip_to_space_const.
    	* common/common-utils.c (skip_to_space): New function.
    	(skip_to_space): Rename from skip_to_space_const.
    	* cli/cli-utils.h (get_number): Rename from get_number_const.
    	(extract_arg): Rename from extract_arg_const.
    	* cli/cli-utils.c (get_number): Rename from get_number_const.
    	(extract_arg): Rename from extract_arg_const.
    	(number_or_range_parser::get_number): Use ::get_number.
    	* aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
    	break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
    	cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
    	completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
    	linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
    	minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
    	python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
    	stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.

commit 7d221d749c0239f06ca571be6c9452cd22b5d582
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 8 15:38:12 2017 -0600

    Make it simpler to add events to Python
    
    The first patch in this series went through several iterations as I'd
    forgotten how many places had to be touched to add a new event and a
    new event type.
    
    This patch simplifies the process using two new ".def" files.  Now, a
    new event type can be added by adding a line to "py-event-types.def",
    and a new event registry can be added by adding a line to
    "py-all-events.def".
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* python/python.c (do_start_initialization): Use
    	py-event-types.def to initialize types.
    	Define all object type structures.
    	* python/python-internal.h: Don't declare event initialization
    	functions.
    	* python/py-threadevent.c (thread_event_object_type): Don't
    	define.
    	* python/py-stopevent.c (stop_event_object_type): Don't define.
    	* python/py-signalevent.c (signal_event_object_type): Don't
    	declare or define.
    	* python/py-newobjfileevent.c (new_objfile_event_object_type)
    	(clear_objfiles_event_object_type): Don't declare or define.
    	* python/py-infevents.c (inferior_call_pre_event_object_type)
    	(inferior_call_post_event_object_type)
    	(register_changed_event_object_type)
    	(memory_changed_event_object_type): Don't declare or define.
    	* python/py-inferior.c (new_thread_event_object_type)
    	(new_inferior_event_object_type)
    	(inferior_deleted_event_object_type): Don't declare or define.
    	* python/py-exitedevent.c (exited_event_object_type): Don't
    	declare or define.
    	* python/py-evts.c (gdbpy_initialize_py_events): Use
    	py-all-events.def.
    	* python/py-events.h (thread_event_object_type): Don't declare.
    	(events_object): Use py-all-events.def.
    	* python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove.  Use
    	py-event-types.def.
    	* python/py-event-types.def: New file.
    	* python/py-continueevent.c (create_continue_event_object): Don't
    	declare or define.
    	* python/py-bpevent.c (breakpoint_event_object_type): Don't
    	declare or define.
    	* python/py-all-events.def: New file.

commit 35c61a1dd5462ceab42618c48c9a60238245761b
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Sep 8 14:26:43 2017 -0600

    Small event ownership clean up in Python layer
    
    It seems cleaner to me for functions like create_thread_event_object,
    which pass object ownership to their callers, to directly return a
    gdb_ref<>.  This way the ownership transfer is part of the API.  This
    patch makes this change.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* python/py-threadevent.c (create_thread_event_object): Return
    	gdbpy_ref.
    	* python/py-stopevent.h (create_stop_event_object)
    	(create_breakpoint_event_object, create_signal_event_object):
    	Update.
    	* python/py-stopevent.c (create_stop_event_object): Return
    	gdbpy_ref.
    	(emit_stop_event): Update.
    	* python/py-signalevent.c (create_signal_event_object): Return
    	gdbpy_ref.
    	* python/py-infevents.c (create_inferior_call_event_object):
    	Update.
    	* python/py-event.h (create_event_object)
    	(create_thread_event_object): Update.
    	* python/py-event.c (create_event_object): Return gdbpy_ref.
    	* python/py-continueevent.c: Return gdbpy_ref.
    	* python/py-bpevent.c (create_breakpoint_event_object): Return
    	gdbpy_ref.

commit 7c96f8c1dae023c7d0b1cabc5e50c4d18fd06960
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Sep 5 12:07:00 2017 -0600

    Add new_inferior, inferior_deleted, and new_thread events
    
    This adds a few new events to gdb's Python layer: new_inferior,
    inferior_deleted, and new_thread.  I wanted to be able to add a
    combined inferior/thread display window to my GUI, and I needed a few
    events to make this work.  This is PR python/15622.
    
    ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	PR python/15622:
    	* NEWS: Add entry.
    	* python/python.c (do_start_initialization): Initialize new event
    	types.
    	* python/python-internal.h (gdbpy_initialize_new_inferior_event)
    	(gdbpy_initialize_inferior_deleted_event)
    	(gdbpy_initialize_new_thread_event): Declare.
    	* python/py-threadevent.c (create_thread_event_object): Add option
    	"thread" parameter.
    	* python/py-inferior.c (new_thread_event_object_type)
    	(new_inferior_event_object_type)
    	(inferior_deleted_event_object_type): Declare.
    	(python_new_inferior, python_inferior_deleted): New functions.
    	(add_thread_object): Emit new_thread event.
    	(gdbpy_initialize_inferior): Attach new functions to corresponding
    	observers.
    	(new_thread, new_inferior, inferior_deleted): Define new event
    	types.
    	* python/py-evts.c (gdbpy_initialize_py_events): Add new
    	registries.
    	* python/py-events.h (events_object) <new_inferior,
    	inferior_deleted, new_thread>: New fields.
    	* python/py-event.h (create_thread_event_breakpoint): Add optional
    	"thread" parameter.
    
    doc/ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* python.texi (Events In Python): Document new events.
    
    testsuite/ChangeLog
    2017-09-11  Tom Tromey  <tom@tromey.com>
    
    	* gdb.python/py-infthread.exp: Add tests for new_thread event.
    	* gdb.python/py-inferior.exp: Add tests for new inferior events.

commit 4ec521f238627f7682306d699c8826390a2cc9e7
Author: Kuan-Lin Chen <kuanlinchentw@gmail.com>
Date:   Mon Sep 11 13:46:27 2017 +0800

    nds32: Rename __BIT() to N32_BIT().

commit 555cb1688148f41582b1e7e9af57e2fc3fbf21bf
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Sep 11 00:00:31 2017 +0000

    Automatic date update in version.in

commit a059f00c857d088a7fe55d2dbded9d3210af4989
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sun Sep 10 17:50:29 2017 -0400

    Fix build breakage on GNU/Linux AArch64, take 2
    
    The last commit unfortunately was not enough to fix the build breakage
    on AArch64.  I made a mistake and did not test it alone on BuildBot,
    but along with another patch that was responsible for fixing the
    breakage.
    
    The failure is:
    
      In file included from /usr/include/string.h:640:0,
    		   from build-gnulib-gdbserver/import/string.h:41,
    		   from ../../../binutils-gdb/gdb/gdbserver/../common/common-defs.h:56,
    		   from ../../../binutils-gdb/gdb/gdbserver/server.h:22,
    		   from ../../../binutils-gdb/gdb/gdbserver/regcache.c:19:
      In function â??void* memset(void*, int, size_t)â??,
          inlined from â??regcache* init_register_cache(regcache*, const target_desc*, unsigned char*)â?? at ../../../binutils-gdb/gdb/gdbserver/regcache.c:150:50:
      /usr/include/aarch64-linux-gnu/bits/string3.h:81:32: error: call to â??__warn_memset_zero_lenâ?? declared with attribute warning: memset used with constant zero length parameter; this could be due to transposed parameters [-Werror]
    	 __warn_memset_zero_len ();
    				  ^
      In function â??void* memset(void*, int, size_t)â??,
          inlined from â??regcache* get_thread_regcache(thread_info*, int)â?? at ../../../binutils-gdb/gdb/gdbserver/regcache.c:57:60:
      /usr/include/aarch64-linux-gnu/bits/string3.h:81:32: error: call to â??__warn_memset_zero_lenâ?? declared with attribute warning: memset used with constant zero length parameter; this could be due to transposed parameters [-Werror]
    	 __warn_memset_zero_len ();
    
    This is likely due to a GCC bug, because for some reason the compiler
    assumes that the third argument to the memset:
    
      memset (regcache->register_status, REG_UNAVAILABLE,
    	  VEC_length (tdesc_reg_p, regcache->tdesc->reg_defs));
    
    is always zero, which is not always true.
    
    Anyway, the simple fix for this is to guard the memset calls with:
    
      if (!VEC_empty (tdesc_reg_p, regcache->tdesc->reg_defs))
    
    This time, I made sure to regtest only this patch on BuildBot, and it
    finally solved the breakage.
    
    gdb/gdbserver/ChangeLog:
    2017-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* regcache.c (get_thread_regcache): Guard calls to "memset"
              with "!VEC_empty".

commit cc397f3a236509257acfd5cd17c2f15f87a482d7
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sun Sep 10 12:16:54 2017 -0400

    Fix build breakage on GNU/Linux AArch64
    
    This patch fixes the build breakage that has been happening on AArch64
    since September 5th.  The breakage was introduced by the following
    commit:
    
      author        Yao Qi <yao.qi@linaro.org>
              Tue, 5 Sep 2017 04:54:52 -0400 (09:54 +0100)
      committer     Yao Qi <yao.qi@linaro.org>
              Tue, 5 Sep 2017 04:54:52 -0400 (09:54 +0100)
      commit        f7000548a2b79d7e5cb924468117ca4245e6b820
    
      Use VEC for target_desc.reg_defs
    
    The build log for this commit can be seen here:
    
      <https://gdb-build.sergiodj.net/builders/Ubuntu-AArch64-native-gdbserver-m64/builds/2696/steps/compile%20gdb/logs/stdio>
    
    And the underlying problem is that the code is not calling the new
    function "allocate_target_description" to allocate the "struct
    target_desc" using "new" instead of XNEW, which end up not properly
    initializing the fields of the structure.
    
    Regtested on BuildBot.
    
    gdb/gdbserver/ChangeLog:
    2017-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* linux-low.c (handle_extended_wait): Use
    	"allocate_target_description" instead of "XNEW".
    	* linux-x86-low.c (initialize_low_arch): Likewise.

commit 72542b8ee6558677bed21dd880b68dc2e541c9c7
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Sun Aug 6 21:45:08 2017 +0100

    gdb: Remove check for gdb_stderr == NULL
    
    Recent changes made gdb_stderr a macro:
    
      #define gdb_stderr (*current_ui_gdb_stderr_ptr ())
    
    and current_ui_gdb_stderr_ptr return this:
    
       &current_ui->m_gdb_stderr
    
    The problem is that this is undefined if current_ui is NULL, which can
    happen early on during gdb start up.
    
    If we run into an error during early gdb start up then we write the
    error message to gdb_stderr.  However, if we are too early during the
    start up then current_ui is NULL, and using the gdb_stderr macro
    triggers undefined behaviour.
    
    We try to avoid this using a check 'gdb_stderr == NULL' which was fine
    before the recent changes, but now, still triggers undefined behaviour.
    
    A better check is instead 'current_ui == NULL' which is what I use in
    this patch.
    
    Triggering this failure is pretty hard, most of the really early errors
    are only triggered if pretty basic things are not as expected, for
    example, if the default signal handlers are not as expected.  Seeing one
    of these errors trigger usually means that someone working on gdb has
    made an incorrect change.  Still, the errors are present in gdb, and
    should we ever trigger one it would be nice if gdb didn't crash.
    
    For testing this change I've been applying this patch which adds an
    unconditional error into a function called early during gdb start up.
    Later in the same function is a real error call which, in some
    circumstances could be triggered:
    
      ## START ##
      diff --git a/gdb/common/signals-state-save-restore.c b/gdb/common/signals-state-save-restore.c
      index d11a9ae006c..d75ba70f894 100644
      --- a/gdb/common/signals-state-save-restore.c
      +++ b/gdb/common/signals-state-save-restore.c
      @@ -37,6 +37,9 @@ static sigset_t original_signal_mask;
       void
       save_original_signals_state (void)
       {
      +
      +  internal_error (__FILE__, __LINE__, "example error");
      +
       #ifdef HAVE_SIGACTION
         int i;
         int res;
      ## END ##
    
    gdb/ChangeLog:
    
    	* utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
    	check current_ui instead.
    	(internal_vproblem): Likewise.

commit 502b834c1a6712d9bbe0beba98727c8365429cd2
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Sep 10 00:00:33 2017 +0000

    Automatic date update in version.in

commit 0d64823e51de0b0e0a94bdf88940310342a6e6fa
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Sep 9 22:51:58 2017 +0200

    Remove unnecessary calls to is_mi_like_p in print_thread_info_1
    
    There are two calls to uiout->is_mi_like_p in the else branch of a
    if (uiout->is_mi_like_p ()), we already know they will return false.
    
    A bit lower, there are two if (!uiout->is_mi_like_p ()) that we can
    merge.
    
    gdb/ChangeLog:
    
    	* thread.c (print_thread_info_1): Remove unnecessary calls to
    	uiout->is_mi_like_p.

commit eb1e02fd05688c28686a02f197c5e7cb0a5d6a27
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 6 17:18:23 2017 -0600

    Use std::vector in add_using_directive
    
    This changes add_using_directive to accept a std::vector and then
    changes the callers.  This allows removing a cleanup.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* namespace.h (add_using_directive): Update.
    	* namespace.c (add_using_directive): Change type of excludes to
    	std::vector.
    	* dwarf2read.c (read_import_statement): Use std::vector.
    	(read_namespace): Update.
    	* cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.

commit 0fc21fd8cf92de78c3c383378e70a2955e2631c3
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 6 16:16:38 2017 -0600

    Use gdb::def_vector in create_sals_line_offset
    
    This changes create_sals_line_offset to use gdb::def_vector, removing
    some cleanups.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* linespec.c (create_sals_line_offset): Use gdb::def_vector.

commit 49663d051c70e1366f9b94f586459a329e9b7053
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 14 00:15:33 2017 -0600

    Use gdb::byte_vector in pascal_object_print_value
    
    This changes pascal_object_print_value to use a gdb::byte_vector.
    This removes a cleanup.  This change also points out how the previous
    code had a possible use-after-free bug.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.

commit 0b868b60c97b13566cefc8c8f1984225b0165eec
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 6 16:03:28 2017 -0600

    Use gdb::def_vector in func_command
    
    This changes func_command to use gdb::def_vector, removing a cleanup.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* stack.c (func_command): Use gdb::def_vector.

commit c0470d489b47f0bbe57893b31d56d2d4ef945f4c
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Sep 6 21:41:40 2017 -0600

    Use ui_out_emit_list and ui_out_emit_tuple with gdb::optional
    
    This changes a few spots to use ui_out_emit_list and/or
    ui_out_emit_tuple with gdb::optional, to preserve existing behavior.
    This allows for the removal of a few more cleanups.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
    	ui_out_emit_list, ui_out_emit_tuple.
    	(mi_cmd_var_update): Likewise.

commit ca5909c7de7353d8005bf8fdcc020b8f14cc1603
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:47:32 2017 -0600

    Remove make_cleanup_ui_out_redirect_pop
    
    This patch introduces ui_out_redirect_pop.  All uses of
    make_cleanup_ui_out_redirect_pop are replaced with this new class.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-interp.c (mi_user_selected_context_changed): Use
    	ui_out_redirect_pop.
    	* guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
    	ui_out_redirect_pop.
    	* utils.c (do_ui_out_redirect_pop)
    	(make_cleanup_ui_out_redirect_pop): Remove.
    	* top.c (execute_command_to_string): Use ui_out_redirect_pop.
    	* utils.h (make_cleanup_ui_out_redirect_pop): Remove.
    	* ui-out.h (ui_out_redirect_pop): New class.

commit e6a2252ac3e3dc748df33b38ac66cd78c80be5ad
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 11 15:17:59 2017 -0600

    Use ui_out_emit_list in more places
    
    This changes various spots to use ui_out_emit_list, removing some
    cleanups.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-main.c (output_cores): Use ui_out_emit_list.
    	(list_available_thread_groups, mi_cmd_list_thread_groups)
    	(mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
    	(mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
    	Likewise.

commit 393702cd59d21237c7db99c26dd8c4737a3ae303
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 11 15:17:26 2017 -0600

    Use ui_out_emit_tuple in disasm.c
    
    This changes one spot in disasm.c to use ui_out_emit_tuple.  This
    patch required a large reindentation, so I've separated it out.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
    	ui_out_emit_tuple.

commit 76f9c9cfd42eb8df90ce8455a92109c0f71b41e1
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 11 15:02:04 2017 -0600

    Use ui_out_emit_tuple in more places
    
    This changes more places to use ui_out_emit_tuple, removing cleanups.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* target.c (flash_erase_command): Use ui_out_emit_tuple.
    	* stack.c (print_frame): Use ui_out_emit_tuple.
    	* spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
    	(info_spu_mailbox_command, info_spu_dma_command)
    	(info_spu_proxydma_command): Likewise.
    	* mi/mi-main.c (mi_cmd_trace_frame_collected): Use
    	ui_out_emit_tuple, gdb::byte_vector, bin2hex.
    	* mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
    	ui_out_emit_tuple.
    	* breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.

commit dc9fe180a4437b437015a8b835d05e32d64dff3d
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 09:16:49 2017 -0600

    Remove make_cleanup_ui_out_table_begin_end
    
    This changes the few remaining uses of
    make_cleanup_ui_out_table_begin_end to use ui_out_emit_table instead,
    and then removes the cleanup.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
    	(class ui_out_emit_table): Update comment.
    	* ui-out.c (do_cleanup_table_end)
    	(make_cleanup_ui_out_table_begin_end): Remove.
    	* spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
    	(info_spu_dma_cmdlist): Likewise.
    	* probe.c (info_probes_for_ops): Use ui_out_emit_table.
    	* darwin-nat-info.c (darwin_debug_regions_recurse): Use
    	ui_out_emit_table.

commit f8cc3da6e4548529eabb1ff4e9693261aae1cfee
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Sep 9 09:15:23 2017 -0600

    Use ui_out_emit_table and ui_out_emit_list in print_thread_info_1
    
    This changes print_thread_info_1 to use ui_out_emit_table and
    ui_out_emit_list.  Which one is used depends on whether the ui-out is
    mi-like; so the emitters are wrapped in gdb::optional.
    
    ChangeLog
    2017-09-09  Tom Tromey  <tom@tromey.com>
    
    	* thread.c (print_thread_info_1): Use ui_out_emit_table,
    	ui_out_emit_list, gdb::optional.

commit 481695ed5f6e0a8a9c9c50bfac1cdd2b3151e6c9
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Sat Sep 9 11:02:37 2017 -0700

    Remove unnecessary function prototypes.
    
    These prototypes were required when compiling GDB as C but are not
    required for C++.
    
    gdb/ChangeLog:
    
    	* aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
    	prototype.
    	* aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
    	prototype.
    	* aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
    	prototype.
    	* aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
    	* ada-exp.y: Remove _initialize_ada_exp prototype.
    	* ada-lang.c: Remove _initialize_ada_language prototype.
    	* ada-tasks.c: Remove _initialize_tasks prototype.
    	* addrmap.c: Remove _initialize_addrmap prototype.
    	* agent.c: Remove _initialize_agent prototype.
    	* aix-thread.c: Remove _initialize_aix_thread prototype.
    	* alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
    	* alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
    	* alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
    	prototype.
    	* alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
    	* alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
    	* alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
    	* amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
    	prototype.
    	* amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
    	prototype.
    	* amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
    	* amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
    	* amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
    	* amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
    	prototype.
    	* amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
    	* amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
    	* amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
    	* amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
    	* amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
    	* amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
    	* amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
    	prototype.
    	* amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
    	prototype.
    	* annotate.c: Remove _initialize_annotate prototype.
    	* arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
    	* arc-tdep.c: Remove _initialize_arc_tdep prototype.
    	* arch-utils.c: Remove _initialize_gdbarch_utils prototype.
    	* arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
    	* arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
    	* arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
    	* arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
    	* arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
    	prototype.
    	* arm-tdep.c: Remove _initialize_arm_tdep prototype.
    	* arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
    	* auto-load.c: Remove _initialize_auto_load prototype.
    	* auxv.c: Remove _initialize_auxv prototype.
    	* avr-tdep.c: Remove _initialize_avr_tdep prototype.
    	* ax-gdb.c: Remove _initialize_ax_gdb prototype.
    	* bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
    	* bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
    	* break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
    	* break-catch-syscall.c: Remove _initialize_break_catch_syscall
    	prototype.
    	* break-catch-throw.c: Remove _initialize_break_catch_throw
    	prototype.
    	* breakpoint.c: Remove _initialize_breakpoint prototype.
    	* bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
    	* btrace.c: Remove _initialize_btrace prototype.
    	* charset.c: Remove _initialize_charset prototype.
    	* cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
    	* cli/cli-dump.c: Remove _initialize_cli_dump prototype.
    	* cli/cli-interp.c: Remove _initialize_cli_interp prototype.
    	* cli/cli-logging.c: Remove _initialize_cli_logging prototype.
    	* cli/cli-script.c: Remove _initialize_cli_script prototype.
    	* coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
    	* coffread.c: Remove _initialize_coffread prototype.
    	* compile/compile.c: Remove _initialize_compile prototype.
    	* complaints.c: Remove _initialize_complaints prototype.
    	* completer.c: Remove _initialize_completer prototype.
    	* copying.awk: Remove _initialize_copying prototype.
    	* copying.c: Regenerate.
    	* core-regset.c: Remove _initialize_core_regset prototype.
    	* corefile.c: Remove _initialize_core prototype.
    	* corelow.c: Remove _initialize_corelow prototype.
    	* cp-abi.c: Remove _initialize_cp_abi prototype.
    	* cp-namespace.c: Remove _initialize_cp_namespace prototype.
    	* cp-support.c: Remove _initialize_cp_support prototype.
    	* cp-valprint.c: Remove _initialize_cp_valprint prototype.
    	* cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
    	* cris-tdep.c: Remove _initialize_cris_tdep prototype.
    	* ctf.c: Remove _initialize_ctf prototype.
    	* d-lang.c: Remove _initialize_d_language prototype.
    	* darwin-nat-info.c: Remove _initialize_darwin_info_commands
    	prototype.
    	* darwin-nat.c: Remove _initialize_darwin_inferior prototype.
    	* dbxread.c: Remove _initialize_dbxread prototype.
    	* dcache.c: Remove _initialize_dcache prototype.
    	* demangle.c: Remove _initialize_demangler prototype.
    	* disasm-selftests.c: Remove _initialize_disasm_selftests
    	prototype.
    	* disasm.c: Remove _initialize_disasm prototype.
    	* dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
    	* dummy-frame.c: Remove _initialize_dummy_frame prototype.
    	* dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
    	prototype.
    	* dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
    	* dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
    	* dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
    	* dwarf2read.c: Remove _initialize_dwarf2_read prototype.
    	* elfread.c: Remove _initialize_elfread prototype.
    	* exec.c: Remove _initialize_exec prototype.
    	* extension.c: Remove _initialize_extension prototype.
    	* f-lang.c: Remove _initialize_f_language prototype.
    	* f-valprint.c: Remove _initialize_f_valprint prototype.
    	* fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
    	* fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
    	* filesystem.c: Remove _initialize_filesystem prototype.
    	* findcmd.c: Remove _initialize_mem_search prototype.
    	* fork-child.c: Remove _initialize_fork_child prototype.
    	* frame-base.c: Remove _initialize_frame_base prototype.
    	* frame-unwind.c: Remove _initialize_frame_unwind prototype.
    	* frame.c: Remove _initialize_frame prototype.
    	* frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
    	* frv-tdep.c: Remove _initialize_frv_tdep prototype.
    	* ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
    	* gcore.c: Remove _initialize_gcore prototype.
    	* gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
    	* gdbarch.c: Regenerate.
    	* gdbarch.sh: Remove _initialize_gdbarch prototype.
    	* gdbtypes.c: Remove _initialize_gdbtypes prototype.
    	* gnu-nat.c: Remove _initialize_gnu_nat prototype.
    	* gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
    	* gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
    	* go-lang.c: Remove _initialize_go_language prototype.
    	* go32-nat.c: Remove _initialize_go32_nat prototype.
    	* guile/guile.c: Remove _initialize_guile prototype.
    	* h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
    	* hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
    	* hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
    	* hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
    	* hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
    	* hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
    	* hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
    	* hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
    	* i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
    	* i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
    	prototype.
    	* i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
    	prototype.
    	* i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
    	* i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
    	* i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
    	* i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
    	* i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
    	* i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
    	* i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
    	* i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
    	* i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
    	* i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
    	* i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
    	* i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
    	* i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
    	* i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
    	* i386-tdep.c: Remove _initialize_i386_tdep prototype.
    	* i386-windows-nat.c: Remove _initialize_i386_windows_nat
    	prototype.
    	* ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
    	prototype.
    	* ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
    	* ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
    	* ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
    	* ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
    	* infcall.c: Remove _initialize_infcall prototype.
    	* infcmd.c: Remove _initialize_infcmd prototype.
    	* inferior.c: Remove _initialize_inferiors prototype.
    	* inflow.c: Remove _initialize_inflow prototype.
    	* infrun.c: Remove _initialize_infrun prototype.
    	* interps.c: Remove _initialize_interpreter prototype.
    	* iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
    	* jit.c: Remove _initialize_jit prototype.
    	* language.c: Remove _initialize_language prototype.
    	* linux-fork.c: Remove _initialize_linux_fork prototype.
    	* linux-nat.c: Remove _initialize_linux_nat prototype.
    	* linux-tdep.c: Remove _initialize_linux_tdep prototype.
    	* linux-thread-db.c: Remove _initialize_thread_db prototype.
    	* lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
    	* m2-lang.c: Remove _initialize_m2_language prototype.
    	* m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
    	* m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
    	* m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
    	* m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
    	* m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
    	* m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
    	* m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
    	* m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
    	* m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
    	* m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
    	* m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
    	* m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
    	* machoread.c: Remove _initialize_machoread prototype.
    	* macrocmd.c: Remove _initialize_macrocmd prototype.
    	* macroscope.c: Remove _initialize_macroscope prototype.
    	* maint.c: Remove _initialize_maint_cmds prototype.
    	* mdebugread.c: Remove _initialize_mdebugread prototype.
    	* memattr.c: Remove _initialize_mem prototype.
    	* mep-tdep.c: Remove _initialize_mep_tdep prototype.
    	* mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
    	* mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
    	* mi/mi-interp.c: Remove _initialize_mi_interp prototype.
    	* mi/mi-main.c: Remove _initialize_mi_main prototype.
    	* microblaze-linux-tdep.c: Remove
    	_initialize_microblaze_linux_tdep prototype.
    	* microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
    	* mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
    	* mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
    	* mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
    	* mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
    	* mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
    	* mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
    	* mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
    	* mips-tdep.c: Remove _initialize_mips_tdep prototype.
    	* mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
    	* mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
    	prototype.
    	* mipsread.c: Remove _initialize_mipsread prototype.
    	* mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
    	prototype.
    	* mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
    	* moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
    	* msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
    	* mt-tdep.c: Remove _initialize_mt_tdep prototype.
    	* nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
    	* nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
    	prototype.
    	* nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
    	* nto-procfs.c: Remove _initialize_procfs prototype.
    	* nto-tdep.c: Remove _initialize_nto_tdep prototype.
    	* objc-lang.c: Remove _initialize_objc_language prototype.
    	* objfiles.c: Remove _initialize_objfiles prototype.
    	* observer.c: Remove observer_test_first_notification_function,
    	observer_test_second_notification_function,
    	observer_test_third_notification_function, and
    	_initialize_observer prototypes.
    	* opencl-lang.c: Remove _initialize_opencl_language prototypes.
    	* osabi.c: Remove _initialize_gdb_osabi prototype.
    	* osdata.c: Remove _initialize_osdata prototype.
    	* p-valprint.c: Remove _initialize_pascal_valprint prototype.
    	* parse.c: Remove _initialize_parse prototype.
    	* ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
    	* ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
    	* ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
    	* ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
    	* ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
    	* ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
    	* ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
    	* ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
    	* printcmd.c: Remove _initialize_printcmd prototype.
    	* probe.c: Remove _initialize_probe prototype.
    	* proc-api.c: Remove _initialize_proc_api prototype.
    	* proc-events.c: Remove _initialize_proc_events prototype.
    	* proc-service.c: Remove _initialize_proc_service prototype.
    	* procfs.c: Remove _initialize_procfs prototype.
    	* psymtab.c: Remove _initialize_psymtab prototype.
    	* python/python.c: Remove _initialize_python prototype.
    	* ravenscar-thread.c: Remove _initialize_ravenscar prototype.
    	* record-btrace.c: Remove _initialize_record_btrace prototype.
    	* record-full.c: Remove _initialize_record_full prototype.
    	* record.c: Remove _initialize_record prototype.
    	* regcache.c: Remove _initialize_regcache prototype.
    	* reggroups.c: Remove _initialize_reggroup prototype.
    	* remote-notif.c: Remove _initialize_notif prototype.
    	* remote-sim.c: Remove _initialize_remote_sim prototype.
    	* remote.c: Remove _initialize_remote prototype.
    	* reverse.c: Remove _initialize_reverse prototype.
    	* rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
    	* rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
    	* rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
    	prototype.
    	* rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
    	* rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
    	* rust-exp.y: Remove _initialize_rust_exp prototype.
    	* rx-tdep.c: Remove _initialize_rx_tdep prototype.
    	* s390-linux-nat.c: Remove _initialize_s390_nat prototype.
    	* s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
    	* score-tdep.c: Remove _initialize_score_tdep prototype.
    	* selftest-arch.c: Remove _initialize_selftests_foreach_arch
    	prototype.
    	* ser-go32.c: Remove _initialize_ser_dos prototype.
    	* ser-mingw.c: Remove _initialize_ser_windows prototype.
    	* ser-pipe.c: Remove _initialize_ser_pipe prototype.
    	* ser-tcp.c: Remove _initialize_ser_tcp prototype.
    	* ser-unix.c: Remove _initialize_ser_hardwire prototype.
    	* serial.c: Remove _initialize_serial prototype.
    	* sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
    	* sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
    	* sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
    	* sh-tdep.c: Remove _initialize_sh_tdep prototype.
    	* skip.c: Remove _initialize_step_skip prototype.
    	* sol-thread.c: Remove _initialize_sol_thread prototype.
    	* solib-aix.c: Remove _initialize_solib_aix prototype.
    	* solib-darwin.c: Remove _initialize_darwin_solib prototype.
    	* solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
    	* solib-frv.c: Remove _initialize_frv_solib prototype.
    	* solib-spu.c: Remove _initialize_spu_solib prototype.
    	* solib-svr4.c: Remove _initialize_svr4_solib prototype.
    	* solib-target.c: Remove _initialize_solib_target prototype.
    	* solib.c: Remove _initialize_solib prototype.
    	* source.c: Remove _initialize_source prototype.
    	* sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
    	* sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
    	prototype.
    	* sparc-nat.c: Remove _initialize_sparc_nat prototype.
    	* sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
    	* sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
    	* sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
    	prototype.
    	* sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
    	* sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
    	* sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
    	* sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
    	prototype.
    	* sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
    	prototype.
    	* sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
    	prototype.
    	* sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
    	prototype.
    	* sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
    	* sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
    	prototype.
    	* sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
    	prototype.
    	* sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
    	prototype.
    	* sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
    	prototype.
    	* sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
    	prototype.
    	* spu-linux-nat.c: Remove _initialize_spu_nat prototype.
    	* spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
    	* spu-tdep.c: Remove _initialize_spu_tdep prototype.
    	* stabsread.c: Remove _initialize_stabsread prototype.
    	* stack.c: Remove _initialize_stack prototype.
    	* stap-probe.c: Remove _initialize_stap_probe prototype.
    	* std-regs.c: Remove _initialize_frame_reg prototype.
    	* symfile-debug.c: Remove _initialize_symfile_debug prototype.
    	* symfile-mem.c: Remove _initialize_symfile_mem prototype.
    	* symfile.c: Remove _initialize_symfile prototype.
    	* symmisc.c: Remove _initialize_symmisc prototype.
    	* symtab.c: Remove _initialize_symtab prototype.
    	* target-dcache.c: Remove _initialize_target_dcache prototype.
    	* target-descriptions.c: Remove _initialize_target_descriptions
    	prototype.
    	* thread.c: Remove _initialize_thread prototype.
    	* tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
    	prototype.
    	* tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
    	* tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
    	* tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
    	prototype.
    	* tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
    	* tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
    	* tracefile.c: Remove _initialize_tracefile prototype.
    	* tracepoint.c: Remove _initialize_tracepoint prototype.
    	* tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
    	* tui/tui-interp.c: Remove _initialize_tui_interp prototype.
    	* tui/tui-layout.c: Remove _initialize_tui_layout prototype.
    	* tui/tui-regs.c: Remove _initialize_tui_regs prototype.
    	* tui/tui-stack.c: Remove _initialize_tui_stack prototype.
    	* tui/tui-win.c: Remove _initialize_tui_win prototype.
    	* tui/tui.c: Remove _initialize_tui prototype.
    	* typeprint.c: Remove _initialize_typeprint prototype.
    	* user-regs.c: Remove _initialize_user_regs prototype.
    	* utils.c: Remove _initialize_utils prototype.
    	* v850-tdep.c: Remove _initialize_v850_tdep prototype.
    	* valarith.c: Remove _initialize_valarith prototype.
    	* valops.c: Remove _initialize_valops prototype.
    	* valprint.c: Remove _initialize_valprint prototype.
    	* value.c: Remove _initialize_values prototype.
    	* varobj.c: Remove _initialize_varobj prototype.
    	* vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
    	* vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
    	* vax-tdep.c: Remove _initialize_vax_tdep prototype.
    	* windows-nat.c: Remove _initialize_windows_nat,
    	_initialize_check_for_gdb_ini, and _initialize_loadable
    	prototypes.
    	* windows-tdep.c: Remove _initialize_windows_tdep prototype.
    	* xcoffread.c: Remove _initialize_xcoffread prototype.
    	* xml-support.c: Remove _initialize_xml_support prototype.
    	* xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
    	* xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
    	prototype.
    	* xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
    	prototype.
    	* xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.

commit 2420fff633eff03ec1f85eba82a926cd0ecf4229
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Sep 9 21:55:22 2017 +0930

    PowerPC64 --plt-align
    
    This changes the PowerPC64 --plt-align option to perform the usual
    alignment of code as suggested by its name, as well as the previous
    behaviour of padding so as to reduce boundary crossing.  The old
    behaviour is had by using a negative parameter.
    
    The default is also changed to align plt stub code by default to 32
    byte boundaries, the point being to get better bctr branch prediction
    on power8 and power9 hardware.
    
    bfd/
    	* elf64-ppp.c (plt_stub_pad): Handle positive and negative
    	plt_stub_align.
    ld/
    	* ld.texinfo (--plt-align): Describe new behaviour of option.
    	* emultempl/ppc64elf.em (params): Default plt_stub_align to 5.
    	* testsuite/ld-powerpc/powerpc.exp: Pass --no-plt-align for
    	selected tests.
    	* testsuite/ld-powerpc/relbrlt.d: Pass --no-plt-align.
    	* testsuite/ld-powerpc/elfv2so.d: Adjust expected output.

commit 372b26b932ad782092b0a9c7236bdae1247034db
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 07:38:57 2017 -0700

    Remove binutils-pr22115.patch
    
    It has been checked into master branch.

commit 246a85081158907401a9e46fc4266a6ed107c28a
Merge: 3484638 c5bce5c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 07:37:34 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit c5bce5c69721af8dae5c607e085e545cdba33ab1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 07:29:15 2017 -0700

    x86: Update UNDEFINED_WEAK_RESOLVED_TO_ZERO
    
    Since the only information which SYMBOL_REFERENCES_LOCAL_P doesn't check
    is relocations, UNDEFINED_WEAK_RESOLVED_TO_ZERO only needs to check for
    relocations with SYMBOL_REFERENCES_LOCAL_P.
    
    	* elf32-i386.c (elf_i386_relocate_section): Update usage of
    	UNDEFINED_WEAK_RESOLVED_TO_ZERO.
    	(elf_i386_finish_dynamic_symbol): Likewise.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
    	(elf_x86_64_finish_dynamic_symbol): Likewise.
    	* elfxx-x86.c (elf_x86_allocate_dynrelocs): Likewise.
    	(_bfd_x86_elf_fixup_symbol): Likewise.

commit 8fbf0ba18c8a63bd4974086f6709b2bf050b0b0b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 07:19:36 2017 -0700

    x86: Don't check has_non_got_reloc
    
    _bfd_x86_elf_link_symbol_references_local should depend only on symbol
    references, not relocations, to work in check_relocs.
    
    	* elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
    	check has_non_got_reloc.

commit 4e9ac44a8925c7da81735ef24beb5456a0c0fa24
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 05:31:30 2017 -0700

    x86: Remove restriction on NOTRACK prefix position
    
    Since the NOTRACK prefix is no longer required to be the last prefix
    before the REX prefix, restriction on the NOTRACK prefix position is
    removed from assembler as well as disassembler.  Assembler encodes the
    NOTRACK prefix the same way as the DS segment register, which places
    it before other prefixes.  Disassembler displays prefixes in the order
    they appear.
    
    gas/
    
    	* config/tc-i386.c (NOTRACK_PREFIX): Removed.
    	(REX_PREFIX): Updated.
    	(MAX_PREFIXES): Likewise.
    	(parse_insn): Remove restriction on NOTRACK prefix position.
    	* testsuite/gas/i386/notrack.s: Add tests with NOTRACK prefix
    	before other prefixes.
    	* testsuite/gas/i386/x86-64-notrack.s: Likewise.
    	* testsuite/gas/i386/notrackbad.s: Remove tests with NOTRACK
    	prefix before other prefixes.
    	* testsuite/gas/i386/x86-64-notrackbad.s: Likewise.
    	* testsuite/gas/i386/notrack-intel.d: Updated.
    	* testsuite/gas/i386/notrack.d: Likewise.
    	* testsuite/gas/i386/notrackbad.l: Likewise.
    	* testsuite/gas/i386/x86-64-notrack-intel.d: Likewise.
    	* testsuite/gas/i386/x86-64-notrack.d: Likewise.
    	* testsuite/gas/i386/x86-64-notrackbad.l: Likewise.
    
    opcodes/
    
    	* i386-dis.c (last_active_prefix): Removed.
    	(ckprefix): Don't set last_active_prefix.
    	(NOTRACK_Fixup): Don't check last_active_prefix.

commit 0a27fed72d4190cc70025c671b5133e6c58d9c09
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 9 05:05:16 2017 -0700

    x86: Properly handle __ehdr_start
    
    After _bfd_i386_elf_convert_load and _bfd_x86_64_elf_convert_load are
    removed, elf_i386_convert_load_reloc and elf_x86_64_convert_load_reloc
    see __ehdr_start as an undefined symbol when they are called from
    check_relocs to convert GOT relocations against local symbols.  But
    __ehdr_start will be defined as a hidden symbol by linker at the later
    stage if it is referenced.  This patch marks __ehdr_start as a defined
    local symbol at the start of check_relocs if it is referenced and not
    defined.
    
    bfd/
    
    	PR ld/22115
    	* elf32-i386.c (elf_i386_convert_load_reloc): Check linker_def.
    	Don't use UNDEFINED_WEAK_RESOLVED_TO_ZERO.
    	* elf64-x86-64.c (elf_x86_64_convert_load_reloc): Check
    	linker_def.  Don't use UNDEFINED_WEAK_RESOLVED_TO_ZERO.
    	* elfxx-x86.c (_bfd_x86_elf_link_check_relocs): Set local_ref
    	and linker_def on __ehdr_start if it is referenced and not
    	defined.
    	(_bfd_x86_elf_link_symbol_references_local): Also set local_ref
    	and return TRUE when building executable, if a symbol has
    	non-GOT/non-PLT relocations in text section or there is no
    	dynamic linker.
    	* elfxx-x86.h (elf_x86_link_hash_entry): Add linker_def.
    
    ld/
    
    	PR ld/22115
    	* ld-i386/i386.exp: Run PR ld/22115 tests,
    	* ld/testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-i386/pr22115-1.s: New file.
    	* testsuite/ld-i386/pr22115-1a.d: Likewise.
    	* testsuite/ld-i386/pr22115-1b.d: Likewise.
    	* testsuite/ld-i386/pr22115-1c.d: Likewise.
    	* testsuite/ld-i386/pr22115-1d.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1.s: Likewise.
    	* testsuite/ld-x86-64/pr22115-1a-x32.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1a.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1b-x32.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1b.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1c-x32.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1c.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1d-x32.d: Likewise.
    	* testsuite/ld-x86-64/pr22115-1d.d: Likewise.

commit 90d499086b5d35ac5b58c925f23513f6af2c3639
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Sep 9 00:00:19 2017 +0000

    Automatic date update in version.in

commit a611b5cb00f47a47426bf1d4fdca9cf3b7eadb53
Author: Keith Seitz <keiths@redhat.com>
Date:   Fri Sep 8 16:44:30 2017 -0700

    Remove unused field field_info.fnfields
    
    Since at least 7.3 the "fnfields" field in struct field_info has been
    unused.  This patch simply removes it.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (struct field_info) <fnfields>: Remove unused
    	field.

commit 3484638ee0bb2fabe2e6be558ca6f78a50eb0658
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 8 14:49:51 2017 -0700

    Apply binutils-pr22115.patch

commit 9924d308c85b4c17ff8292eeccba6129163a6513
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 8 14:37:03 2017 -0700

    Remove binutils-x86-convert-load.patch
    
    It has been checked into master branch.

commit f1a1c6c47c678263564ebead27bb4b4ec7309b69
Merge: 512a8d4 c7df954
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 8 14:34:52 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit c7df954fc4be9eea78a812d04beb6a5534d9a5e7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 8 09:15:25 2017 -0700

    x86: Update comments in elfxx-x86.h
    
    	* elfxx-x86.h: Update comments.

commit 469412dd9ccc4de5874fd3299b105833f36b34cd
Author: Christoph Weinmann <christoph.t.weinmann@intel.com>
Date:   Fri Sep 8 15:11:47 2017 +0200

    Remove C/C++ relevant code in Fortran specific file.
    
    Remove code relevant for printing C/C++ Integer values in a
    Fortran specific file to unify printing of Fortran values.
    This does not change the output.

commit e0f86435f8b3c61e21070a232a07c03928c2d544
Author: Bernhard Heckel <bernhard.heckel@intel.com>
Date:   Fri Sep 8 15:11:47 2017 +0200

    fortran: Testsuite, fix typos in vla-value.

commit 9e9af4be9f656f82922e6aaeb3b6421508403ea4
Author: Bernhard Heckel <bernhard.heckel@intel.com>
Date:   Fri Sep 8 15:11:47 2017 +0200

    Fortran: Testsuite, fix differences in type naming.

commit a5ad232b3e6f39cf2955a8ec3aa4355359a9f72e
Author: Frank Penczek <frank.penczek@intel.com>
Date:   Fri Sep 8 15:11:47 2017 +0200

    Fix indentation for printing Fortran types with pointers
    
    Printing the prefix "PTR TO -> (" resp. "REF TO ->(" ignored the active
    indentation level.  This caused inconsistent appearance of user-defined
    Fortran types containing pointers.  Fix by using "fprintfi_filtered" with the
    current indentation level for outputting the prefix string.  Add test case
    ptr-indentation.
    
    Example using 'ptype' on object of type:
      type TypeWithPointer
        integer i
        integer, pointer:: p
      end type TypeWithPointer
    
    Before:
      type = Type typewithpointer
          integer(kind=4) :: i
      PTR TO -> ( integer(kind=4) :: p)
      End Type typewithpointer
    
    After:
      type = Type typewithpointer
          integer(kind=4) :: i
          PTR TO -> ( integer(kind=4) :: p)
      End Type typewithpointer

commit 1de031c80b121db6f59d189d150ab2b69f6ede21
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 8 04:10:34 2017 -0700

    x86: Replace elf_x86_plt_layout_table with elf_x86_init_table
    
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Replace
    	elf_x86_plt_layout_table with elf_x86_init_table.
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties):
    	Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_link_setup_gnu_properties):
    	Likewise.
    	* elfxx-x86.h (elf_x86_plt_layout_table): Renamed to ...
    	(elf_x86_init_table): This.
    	(_bfd_x86_elf_link_setup_gnu_properties): Replace
    	elf_x86_plt_layout_table with elf_x86_init_table.

commit 7a382c1c50fca0d4bc4c2e618ff6ac222c4e2137
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 7 17:19:10 2017 -0700

    x86; Don't add elf64-x86-64.lo nor elf64.lo together with elfxx-x86.lo
    
    Don't set r_info and r_sym fields in _bfd_x86_elf_link_hash_table_create.
    Instead, set them in _bfd_x86_elf_link_setup_gnu_properties.  We can
    avoid adding elf64-x86-64.lo and elf64.lo together with elfxx-x86.lo to
    bfd_backends.
    
    	* configure.ac (bfd_backends): Don't add elf64-x86-64.lo nor
    	elf64.lo together with elfxx-x86.lo for 64-bit BFD.
    	* configure: Regenerated.
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Set r_info
    	and r_sym fields of plt_layout.
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties):
    	Likewise.
    	* elfxx-x86.c (elf_x86_64_is_reloc_section): Remove BFD64 check.
    	(_bfd_x86_elf_link_hash_table_create): Likewise.  Don't set
    	r_info nor r_sym fields.
    	(_bfd_x86_elf_link_setup_gnu_properties): Set r_info and r_sym
    	fields of htab.
    	* elfxx-x86.h (elf_x86_plt_layout_table): Add r_info and r_sym.

commit bd757a5bf293aaed6c6aa79776bbef13ca2da92b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Sep 8 00:00:20 2017 +0000

    Automatic date update in version.in

commit ed0816bd936492aa7dc00e4fbbf8ff8de1253854
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Fri Jun 16 14:33:16 2017 -0700

    RISC-V: Avoid emitting invalid instructions in mixed RVC/no-RVC code
    
    When linking the following code
    
        .global _prog_start
        _prog_start:
                mv x1, x1
                mv x2, x2
        .align 2
        rvc_boundry:
        .option norvc
        .align 3
                mv x3, x3
    
    we currently emit an invalid two-byte 0 instruction.  The actual output
    code looks like
    
        0000000080000000 <_prog_start>:
            80000000:   8086                    mv      ra,ra
            80000002:   810a                    mv      sp,sp
    
        0000000080000004 <rvc_boundry>:
            80000004:   0000                    unimp
            80000006:   0001                    nop
            80000008:   00018193                mv      gp,gp
    
    This ends up manifesting due to the two-byte compressed NOP that's
    pessimisticly emitted by the ".align 2", which results in "rvc_boundry"
    being 2-byte aligned.  frag_align_code() then goes and outputs a 2-byte
    NOP (which is invalid in no-RVC mode) to align the code back to a 4-byte
    boundry, which can't be relaxed away by the linker as it's not part of
    the R_RISCV_RELAX relocation.
    
    The fix is to just always emit the worst case possible alignment into
    the output as a single R_RISCV_RELAX, which the linker will then fix up.
    
    With this patch I get the expected code generation
    
        0000000080000000 <_prog_start>:
            80000000:   8086                    mv      ra,ra
            80000002:   810a                    mv      sp,sp
    
        0000000080000004 <rvc_boundry>:
            80000004:   00000013                nop
            80000008:   00018193                mv      gp,gp
    
    gas/ChangeLog
    
    2017-09-07  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * config/tc-riscv.c (riscv_frag_align_code): Emit the entire
            alignment sequence inside R_RISCV_ALIGN.

commit 9eb7b0acb54e18e7cbca196a8bdb320844a858b3
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Fri Jun 16 14:19:55 2017 -0700

    RISC-V: Print an error when unable to align a section
    
    This used to just print "can't relax section: Success", which is a silly
    error message.
    
    bfd/ChangeLog
    
    2017-09-07  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * elfnn-riscv.c (_bfd_riscv_relax_align): Call bfd_set_error and
            print an error message when unable to relax a .align directive.

commit b1308d2c3749cc454f00b70768ee33724d919527
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Wed Aug 16 10:41:56 2017 -0700

    RISC-V: Support PCREL_* relocations agaist weak undefined symbols
    
    I recently modified our Linux port's base address such the absolute
    address 0 is no longer addressable as a 32-bit PC-relative offset.
    Since Linux links a weak undefined symbol in an intermediate binary, it
    needs to be able to reference absolute address 0.
    
    This patch changes R_RISCV_PCREL_* relocations to absolute relocations
    while resolving them in order to allow these symbols to be referenced in
    PC-relative programs linked at high addresses.  Note that this doesn't
    apply to PIC, which also uses PC-relative relocations, just to
    position-dependent objects, which we use to allow programs to be linked
    at high addresses.
    
    In case some of our embedded users are using R_RISCV_PCREL_* as a hacked
    up method of getting position-independent binaries (which can work if
    you have very simple programs), we only convert the relocations when the
    PC-relative version would overflow.
    
    bfd/ChangeLog:
    
    2017-09-07  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * elfnn-riscv.c (riscv_zero_pcrel_hi_reloc): New function.
            (riscv_record_pcrel_hi_reloc): Add absolute argument.
            (riscv_elf_relocate_section): Call riscv_zero_pcrel_hi_reloc for
            R_RISCV_PCREL_HI20 relocs, and pass the result to
            riscv_record_pcrel_hi_reloc.

commit e50142270b699c4960e56824a0300865589dc292
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Sep 7 07:40:10 2017 -0700

    Document the GDB 8.0.1 release in gdb/ChangeLog
    
    gdb/ChangeLog:
    
    	GDB 8.0.1 released.

commit 63c99141deff52f22aa36b9d6cb02e7331aedd1c
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Thu Sep 7 07:24:33 2017 -0700

    remove QStartupWithShell entry from NEWS::Changes in GDB 7.11
    
    This entry was added twice within the same commit, back in Dec 2017
    by the following change:
    
        commit aefd8b33d97bded58e51d75271f99e1eaec9fb28
        Date:   Thu Dec 22 22:14:02 2016 -0500
        Subject: Implement proper "startup-with-shell" support on gdbserver
    
    I think the second entry is just a rebase/merge oversight, and it wasn't
    meant to be added there, particularly since the 7.11 branch was no longer
    active at that time anymore.
    
    This patch just removes the entry.
    
    gdb/ChangeLog:
    
    	* NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.

commit 6999821f8b1e898f02d0c1196c4c83337c3b565e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Sep 7 04:03:15 2017 -0700

    x86: Remove _bfd_{i386,x86_64}_elf_convert_load
    
    Instead of converting GOT relocations when sizing dynamic sections, we
    convert GOT relocations during relocation check.  Add a field, local_ref,
    to elf_x86_link_hash_entry to indicate if symbol references are always
    local with a new function to check if symbol references are always local,
    which works in check_relocs.
    
    	* elf32-i386.c (elf_i386_convert_load_reloc): Add an argument,
    	r_type_p.  Remove the converted argument.  Replace
    	SYMBOL_REFERENCES_LOCAL with SYMBOL_REFERENCES_LOCAL_P.  Return
    	the new relocation type via r_type_p.
    	(elf_i386_relocate_section): Likewise.
    	(elf_i386_finish_dynamic_symbol): Likewise.
    	(need_convert_load): Removed.
    	(check_relocs_failed): Updated.
    	(elf_i386_check_relocs): Call elf_i386_convert_load_reloc,
    	instead of setting need_convert_load.
    	(_bfd_i386_elf_convert_load): Removed.
    	* elf64-x86-64.c (need_convert_load): Removed.
    	(check_relocs_failed): Updated.
    	(elf_x86_64_convert_load_reloc): Add an argument, r_type_p.
    	Replace SYMBOL_REFERENCES_LOCAL with SYMBOL_REFERENCES_LOCAL_P.
    	Return the new relocation type via r_type_p.
    	(elf_x86_64_check_relocs): Call elf_x86_64_convert_load_reloc,
    	instead of setting need_convert_load.
    	(elf_x86_64_check_relocs): Don't check PIC if relocation has
    	been converted.
    	(_bfd_x86_64_elf_convert_load): Removed.
    	(elf_x86_64_relocate_section): Replace SYMBOL_REFERENCES_LOCAL
    	with SYMBOL_REFERENCES_LOCAL_P.
    	(elf_x86_64_finish_dynamic_symbol): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Don't
    	set convert_load.
    	(_bfd_x86_elf_size_dynamic_sections): Don't call convert_load.
    	(_bfd_x86_elf_link_symbol_references_local): New function.
    	* elfxx-x86.h (SYMBOL_REFERENCES_LOCAL_P): New.
    	(UNDEFINED_WEAK_RESOLVED_TO_ZERO): Replace elf.forced_local with
    	SYMBOL_REFERENCES_LOCAL_P.
    	(elf_x86_link_hash_entry): Add local_ref.
    	(elf_x86_link_hash_table): Remove convert_load.
    	(_bfd_i386_elf_convert_load): Removed.
    	(_bfd_x86_64_elf_convert_load): Likewise.
    	(_bfd_x86_elf_link_symbol_references_local): New.

commit 512a8d4309099c041e9bff303f3c42f2037f9e1d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 19:21:11 2017 -0700

    Update binutils-x86-convert-load.patch

commit 4c291a8d9ae9db421a70a8d6f15e835913645378
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 18:03:46 2017 -0700

    Update binutils-x86-convert-load.patch

commit d354a13465f8a85a6ec9346d42b62a9598588c72
Merge: 2dfb2ca 639257e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 18:03:15 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 639257e981e61472e5fc215eb60c5d545ac5e2ab
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Sep 7 00:00:25 2017 +0000

    Automatic date update in version.in

commit 69c1e056df50e931ca9cbb4b5881e574583cf9ab
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 3 21:50:47 2017 -0600

    Change funcall_chain to be a std::vector
    
    This simplifies the handling of funcall_chain, by changing it to be a
    std::vector<int> and then fixing the users.  This allows the removal
    of a cleanup.
    
    It would be even cleaner to replace this with better logic in the
    parsers; but a baby step seemed ok.
    
    gdb/ChangeLog
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	* parse.c (funcall_chain): Now a std::vector.
    	(start_arglist, end_arglist): Simplify.
    	(free_funcalls): Remove.
    	(parse_exp_in_context_1): Remove cleanup.

commit fef704bfec3fdec29b08fca2bd0a5226a04c3113
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:40:35 2017 -0600

    Remove last cleanups from go-exp.y
    
    This removes the last remaining cleanups from go-exp.y.
    
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	* go-exp.y (go_parse): Don't create a cleanup.

commit 5613c5857a020ca5189a73df7b58a234d0311bfb
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:38:53 2017 -0600

    Remove last cleanups from d-exp.y
    
    This removes the last remaining cleanups from d-exp.y.
    
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	* d-exp.y (PrimaryExpression): Use std::string.
    	(d_parse): Don't create a cleanup.

commit eae49211e13efa075d57ab354ea4207666eadc96
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:37:13 2017 -0600

    Remove make_cleanup_clear_parser_state
    
    This removes make_cleanup_clear_parser_state in favor of
    scoped_restore.
    
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (do_clear_parser_state): Remove.
    	(make_cleanup_clear_parser_state): Remove.
    	* p-exp.y (pascal_parse): Use scoped_restore.
    	* m2-exp.y (m2_parse): Use scoped_restore.
    	* f-exp.y (f_parse): Use scoped_restore.
    	* d-exp.y (d_parse): Use scoped_restore.
    	* c-exp.y (c_parse): Use scoped_restore.
    	* ada-exp.y (ada_parse): Use scoped_restore.
    	* utils.h (make_cleanup_clear_parser_state): Remove.

commit 73b9be8b5301c4ac056e10c38a47414867ee892a
Author: Keith Seitz <keiths@redhat.com>
Date:   Wed Sep 6 12:50:52 2017 -0700

    Introduce dw2_linkage_name and dw2_linkage_name_attr.
    
    The DWARF reader is littered with the following idiom to read a linkage name
    from the debug info:
    
      mangled = dwarf2_string_attr (die, DW_AT_linkage_name, cu);
      if (mangled == NULL)
        mangled = dwarf2_string_attr (die, DW_AT_MIPS_linkage_name, cu);
    
    This patch introduces functions to simplify this to:
    
      mangled = dw2_linkage_name (die, cu);
    
    or
    
      attr = dw2_linkage_name_attr (die, cu);
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (dw2_linkage_name_attr): New function.
    	(dw2_linkage_name): New function.
    	(dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
    	(guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
    	(anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.

commit 5c887dd5f699f953e274ba5981fe331eec8e224d
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Sep 6 10:16:12 2017 -0700

    Honor an existing CC_FOR_BUILD in the environment for sim.
    
    This matches the equivalent bits in bfd/acinclude.m4
    
    sim/ChangeLog:
    
    	* configure.ac: Honor existing CC_FOR_BUILD in environment.
    	* configure: Regenerate.
    
    sim/aarch64/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/arm/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/avr/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/bfin/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/common/ChangeLog:
    
    	* acinclude.m4 (SIM_AC_COMMON) Honor existing CC_FOR_BUILD in
    	environment.
    
    sim/cr16/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/cris/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/d10v/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/erc32/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/frv/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/ft32/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/h8300/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/iq2000/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/lm32/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/m32c/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/m32r/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/m68hc11/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/mcore/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/microblaze/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/mips/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/mn10300/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/moxie/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/msp430/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/rl78/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/rx/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/sh/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/sh64/ChangeLog:
    
    	* configure: Regenerate.
    
    sim/v850/ChangeLog:
    
    	* configure: Regenerate.

commit 5aec60eb2f6f0905bfc76f5949fd5d55c6a10f10
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Aug 30 16:12:56 2017 -0600

    Cast char constant to int in sizeof.exp
    
    PR gdb/22010 concerns a regression I introduced with the scalar
    printing changes.  The bug is that this code in sizeof.exp:
    
        set signof_byte [get_integer_valueof "'\\377'" -1]
    
    can incorrectly compute sizeof_byte.  One underlying problem here is
    that gdb's C parser doesn't treat a char constant as an int (this is
    PR 19973).
    
    However, it seems good to have an immediate fix for the regression.
    The simplest is to cast to an int here.
    
    testsuite/ChangeLog
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	PR gdb/22010:
    	* gdb.base/sizeof.exp (check_valueof): Cast char constant to int.

commit a102602bc56e418f9794d653ef103a65f08a5a49
Author: Kamil Rytarowski <n54@gmx.com>
Date:   Wed Sep 6 18:48:49 2017 +0200

    Correct shell compatibility issue detected with pkgsrc.
    
    String comparison of in a POSIX bourne shell must be done
    with '=', not '=='. For example the NetBSD sh(1) does not
    support it.
    
    gdb/ChangeLog
    2017-09-06  Kamil Rytarowski  <n54@gmx.com>
    
    	* config/djgpp/djconfig.sh: Correct shell portability issue.

commit 8f8f815255bf36800cdfff93fd88a62aaa39ce16
Author: Thomas Preud'homme <thomas.preudhomme@arm.com>
Date:   Wed Sep 6 17:54:26 2017 +0100

    Fix calls in gdb.arch/thumb2-it.exp
    
    Tests in gdb.arch/thumb2-it.exp call functions defined in assembly
    without type debugging information. Since
    7022349d5c86bae74b49225515f42d2e221bd368 ("Stop assuming no-debug-info
    functions return int") this triggers an error which leads to many tests
    to FAIL. This patch cast the call to indicate the return type of the
    functions when calling them.
    
    2017-09-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
    
    gdb/testsuite/
    	* gdb.arch/thumb2-it.exp: Cast call to assembly defined function.

commit 28ad437d7af2fe5bf83dafb4e733978d0b142edb
Author: Kamil Rytarowski <n54@gmx.com>
Date:   Wed Sep 6 18:33:46 2017 +0200

    Define HAVE_NATIVE_GCORE_HOST on NetBSD
    
    NetBSD ships with gcore(1) againg since the version 2.0.
    This tool is functional and actively maintained.
    
    gdb/ChangeLog
    2017-09-06  Kamil Rytarowski  <n54@gmx.com>
    
    	* configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.

commit 351787dd4cb8439c0b49472648dd97ebedb5f575
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Thu Aug 10 11:00:42 2017 -0700

    Add native target for FreeBSD/aarch64.
    
    gdb/ChangeLog:
    
    	* Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
    	* NEWS: Mention new FreeBSD/mips native configuration.
    	* configure.host: Add aarch64*-*-freebsd*.
    	* configure.nat: Likewise.
    	* aarch64-fbsd-nat.c: New file.

commit c0f84956d0df0f004e31a987ecc77ea0d293e62c
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Aug 8 23:25:42 2017 -0700

    Add FreeBSD/aarch64 architecture.
    
    Support for collecting and supplying general purpose and floating point
    register sets is provided along with signal frame unwinding.
    
    gdb/ChangeLog:
    
    	* Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
    	(ALLDEPFILES): Add aarch64-fbsd-tdep.c.
    	* NEWS: Mention new FreeBSD/aarch64 target.
    	* configure.tgt: Add aarch64*-*-freebsd*.
    	* aarch64-fbsd-tdep.c: New file.
    	* aarch64-fbsd-tdep.h: New file.

commit 7610297ab578854a5e9ff1247a77398a60d70f91
Author: Kamil Rytarowski <n54@gmx.com>
Date:   Wed Sep 6 17:57:39 2017 +0200

    Add myself as a write-after-approval GDB maintainer.
    
    gdb/ChangeLog:
    2017-09-06  Kamil Rytarowski  <n54@gmx.com>
    
    	* MAINTAINERS (Write After Approval): Add Kamil Rytarowski.

commit 2dfb2ca2d1f31b991d078ef605ff7167ba072962
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 07:42:59 2017 -0700

    Apply x86: Remove _bfd_{i386,x86_64}_elf_convert_load

commit 3a53d12a690e50d2814f0b5001f88e67a30cd123
Merge: de64ecc 7898495
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 05:37:54 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 78984959cb385388e29dcc88dc169449344f22d7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 05:06:35 2017 -0700

    x86-64: Add R_X86_64_converted_reloc_bit
    
    Add R_X86_64_converted_reloc_bit to relocation type to indicate if a
    relocation is converted from a GOTPCREL relocation.  Linker now generates
    
    failed to convert GOTPCREL relocation; relink with --no-relax
    
    for all cases, including relocations against local symbols.
    
    bfd/
    
    	* elf64-x86-64.c (R_X86_64_converted_reloc_bit): New.
    	(elf_x86_64_info_to_howto): Get the real relocation type by
    	masking out R_X86_64_converted_reloc_bit.
    	(elf_x86_64_check_tls_transition): Get the real relocation type
    	by masking out R_X86_64_converted_reloc_bit.
    	(elf_x86_64_convert_load_reloc): Set R_X86_64_converted_reloc_bit
    	instead of setting converted_reloc.
    	(elf_x86_64_relocate_section): Check R_X86_64_converted_reloc_bit
    	instead of converted_reloc. Get the real relocation type by
    	masking out R_X86_64_converted_reloc_bit.
    	(elf_x86_64_link_setup_gnu_properties): Verify that the value of
    	R_X86_64_converted_reloc_bit is valid.
    	* elfxx-x86.h (converted_reloc): Removed.
    
    ld/
    
    	* testsuite/ld-x86-64/pr19609-2a.d: Updated.
    	* testsuite/ld-x86-64/pr19609-2b.d: Likewise.
    	* testsuite/ld-x86-64/pr19609-4a.d: Likewise.
    	* testsuite/ld-x86-64/pr19609-4c.d: Likewise.

commit 419414eafcee7cd749ee4622ef25020e48b52cc4
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Sep 6 04:49:47 2017 -0700

    x86: Don't change r_type when performing TLS transitions
    
    Don't change r_type when performing TLS transitions to avoid getting
    the relocation type with ELF32_R_TYPE again.
    
    	* elf32-i386.c (elf_i386_relocate_section): Don't change r_type
    	when calling elf_i386_tls_transition.  Don't use ELF32_R_TYPE
    	to get the relocation type again.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Don't change
    	r_type when calling elf_x86_64_tls_transition.  Don't use
    	ELF32_R_TYPE to get the relocation type again.

commit fbd1b77155bd8139033b72871dbe7bf5be6031b1
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Wed Sep 6 12:32:46 2017 +0100

    Fix accessing TLS variables with no debug info
    
    Since 2273f0ac95a7 ("change minsyms not to be relocated at
    read-time"), printing TLS symbols of objfiles with a non-zero base
    address, without debug info, fails.
    
    E.g., with:
    
     $ mv /usr/lib/debug /usr/lib/debug-x
    
    to get debug info out of the way, we get:
    
     $ echo 'int main(){}' | gcc -pthread -x c -
     $ ./gdb -q -ex start -ex 'p (int) errno' ./a.out
     Cannot access memory at address 0xffffef7c0698
    
    instead of the expected:
    
     $1 = 0
    
    The regression is not visible with glibc debuginfo installed.
    
    The problem is that we compute the address of TLS minsyms incorrectly.
    
    To trigger the problem, it is important that the variable is in an
    objfile with a non-zero base address.  While glibc is a shared library
    for 'errno', it's easier for the testcase to use PIE instead of a
    shlib.  For TLS variables in PT_EXEC the regression obviously does not
    happen.
    
    gdb/ChangeLog
    2017-09-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* parse.c (find_minsym_type_and_address): Don't relocate addresses
    	of TLS symbols.
    
    gdb/testsuite/ChangeLog
    2017-09-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gdb.threads/tls-nodebug-pie.c: New file.
    	* gdb.threads/tls-nodebug-pie.exp: New file.

commit 39250b0a1c788215a39aea51dee9ba4f9937d404
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Sep 6 00:00:18 2017 +0000

    Automatic date update in version.in

commit dc089072135ec2e30337879b1f6147b77c77b341
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Sep 5 13:41:18 2017 -0700

    x86-64: Properly set converted_reloc
    
    Linker now generates
    
    failed to convert GOTPCREL relocation; relink with --no-relax
    
    for more cases.
    
    bfd/
    
    	* elf64-x86-64.c (elf_x86_64_convert_load_reloc): Properly set
    	converted_reloc.
    
    ld/
    
    	* testsuite/ld-x86-64/pr19609-5d.d: Updated.
    	* testsuite/ld-x86-64/pr19609-7a.d: Likewise.
    	* testsuite/ld-x86-64/pr19609-7c.d: Likewise.

commit 5ca79eae06a692cca5bb795045ffb8961e2b8ae8
Author: Philippe Waroquiers <philippe.waroquiers@skynet.be>
Date:   Tue Sep 5 20:51:23 2017 +0200

    Fix leak of auto_obstack objfile_per_bfd_storage->storage_obstack;
    
      commit 23732b1e32dd58f7c731d9aee56ff0b22a645d53
      Author: Pedro Alves <palves@redhat.com>
      Date:   Tue Jun 27 16:22:08 2017 +0100
    changed objfile_per_bfd_storage->storage_obstack
    from  'struct obstack storage_obstack;'
    to    'auto_obstack storage_obstack;'
    So the obstack is auto allocated when the  objfile_per_bfd_storage ctor is
    manually called by get_objfile_bfd_data).
    However, the ctor call was still followed by a manual call to
          obstack_init (&storage->storage_obstack);
    
    This results in a bunch of leaks detected by valgrind, such as:
    ==24665== 4,064 bytes in 1 blocks are definitely lost in loss record 11,469 of 11,590
    ==24665==    at 0x4C27BF5: malloc (vg_replace_malloc.c:299)
    ==24665==    by 0x5437B7: xmalloc (common-utils.c:44)
    ==24665==    by 0x77CAA7: _obstack_begin_worker (obstack.c:141)
    ==24665==    by 0x60168F: auto_obstack (gdb_obstack.h:70)
    ==24665==    by 0x60168F: get_objfile_bfd_data(objfile*, bfd*) (objfiles.h:188)
    ==24665==    by 0x601DB6: allocate_objfile(bfd*, char const*, enum_flags<objfile_flag>) (objfiles.c:423)
    ==24665==    by 0x647753: symbol_file_add_with_addrs(bfd*, char const*, enum_flags<symfile_add_flag>, section_addr_info*, enum_flags<objfile_flag>, objfile*) (symfile.c:1158)
    ==24665==    by 0x647C7B: symbol_file_add_separate(bfd*, char const*, enum_flags<symfile_add_flag>, objfile*) (symfile.c:1252)
    ==24665==    by 0x4C7D79: elf_symfile_read(objfile*, enum_flags<symfile_add_flag>) (elfread.c:1270)
    ==24665==    by 0x647CB4: read_symbols(objfile*, enum_flags<symfile_add_flag>) (symfile.c:861)
    ==24665==    by 0x647809: syms_from_objfile_1 (symfile.c:1062)
    
    -> remove the manual call to obstack_init.
    Reg-tested on Debian 8/amd64, tests results are the same before/after the patch.
    valgrind still show some leaks, but less.
    
    gdb/ChangeLog
    2017-09-05  Philippe Waroquiers  <philippe.waroquiers@skynet.be>
    
    	* objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
    	call.

commit 8b43e456886c5b3aaba1ef93195ed888b15de242
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Sep 5 11:24:01 2017 -0700

    x86-64: Improve GOTPCREL relocation conversion
    
    When GOTPCREL relocation conversion leads to relocation overflow, we
    may get a mysterious linker message, like
    
    relocation truncated to fit: R_X86_64_32S against symbol `foo'
    
    This patch changes the linker message to
    
    failed to convert GOTPCREL relocation; relink with --no-relax
    
    bfd/
    
    	* elf64-x86-64.c (elf_x86_64_convert_load_reloc): Remove the sec
    	argument.  Don't check relocation overflow.  Avoid relocation
    	overflow if --no-relax is used.  Set converted_reloc on symbol
    	if a GOTPCREL relocation is converted.
    	(elf_x86_64_relocate_section): Issue a fatal error and suggest
    	--no-relax if GOTPCREL relocation conversion leads to relocation
    	overflow.
    	* elfxx-x86.h (elf_x86_link_hash_entry): Add converted_reloc.
    
    ld/
    
    	* testsuite/ld-x86-64/pr19609-4e.d: Updated.
    	* testsuite/ld-x86-64/pr19609-6a.d: Likewise.

commit 5eb5f85062a3d43bf449ded1b256d761d487f0d6
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Sep 3 23:15:03 2017 -0600

    Don't use -fdiagnostics-color=never for rustc
    
    I noticed that the gdb.rust tests fail because the test suite passes
    -fdiagnostics-color=never to rustc.  This is not a recognized rustc
    option, and the test suite already handles passing the appropriate
    option to the Rust compiler.
    
    This patch fixes the problem.
    
    testsuite/ChangeLog
    2017-09-05  Tom Tromey  <tom@tromey.com>
    
    	* lib/gdb.exp (gdb_compile): Don't use universal_compile_options
    	for rust.

commit ae780a21f25455e4ca4b2fa7e350e7f994e0f198
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 5 17:40:44 2017 +0200

    Test different follow-exec-mode settings in gdb.multi/multi-arch-exec.exp
    
    Using follow-exec-mode "new" takes a different code path than "same", so
    it's interesting to test this path in combination with a change in
    architecture of the inferior.  This test fails if you remove the
    previous patch.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.multi/multi-arch-exec.exp: Test with different
    	"follow-exec-mode" settings.
    	(do_test): New procedure.

commit bf93d7ba99319c4ff5f23f35d9645dc9c3d391c2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 5 17:30:27 2017 +0200

    Add thread after updating gdbarch when exec'ing
    
    As mentioned in the previous patch, we should avoid doing register reads
    after a process does an exec and before we've updated that inferior's
    gdbarch.  Otherwise, we may interpret the registers using the wrong
    architecture.  When a process does an exec with "follow-exec-mode new",
    a new inferior is added by follow_exec.  The gdbarch of that new
    inferior is at first set to some default value, probably specific to the
    gdb build (I get "i386" here), which may not be the right one.  It is
    updated later by the call to target_find_description.  Before that
    point, if we try to read the inferior's registers, we may not interpret
    them correctly.  This has been exposed by a failure in
    gdb.base/foll-exec-mode.exp after the previous patch, with:
    
      Remote 'g' packet reply is too long (expected 312 bytes, got 816 bytes)
    
    The call to "add_thread" done just after adding the inferior is
    problematic, because it ends up reading the registers (because the ptid
    is re-used, we end up doing a switch_to_thread to it, which tries to
    update stop_pc).  The registers returned by gdbserver are the x86-64
    ones, while we try to interpret them using the "i386" gdbarch.
    
    Postponing the call to add_thread to until the target
    description/gdbarch has been updated seems to fix the issue.
    
    As to why this issue was uncovered by the previous patch: what I think
    happened before that patch is that since we were updating stop_pc before
    switching to the new inferior, we were filling the regcache associated
    to the ptid (this worked fine as long as the architectures of the
    previous and new process images were the same).  The call to
    switch_to_thread then worked, because the register read hit the
    regcache.  Now, it triggers a register read, while the gdbarch is not
    set correctly, leading to the "reply is too long" error.  If this is
    right, it sounds wrong that we delete and re-add a thread with the same
    ptid, and are able to access the registers from the deleted thread.
    When we delete a thread, should we clear the regcache associated to that
    ptid, so that the new thread starts with a fresh/empty regcache?
    
    gdb/ChangeLog:
    
    	* infrun.c (follow_exec): Call add_thread after
    	target_find_description.

commit 1bb7c059779218d2db7dc4668f998617603e86df
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 5 16:45:10 2017 +0200

    Read stop_pc after updating the gdbarch when exec'ing
    
    When an inferior execs and changes architecture (e.g. 64 bits to 32
    bits), the gdbarch associated to the inferior is updated by the
    follow_exec call in handle_inferior_event_1.  We should avoid doing any
    register read before that point, because the registers sent by the
    remote side will be those of the new architecture, but we would
    interpret them using the old architecture.  We do just that by setting
    stop_pc during this window, which obviously requires reading the
    registers.  This results in gdb.multi/multi-arch-exec.exp failing, GDB
    outputting the following error:
    
      Truncated register 50 in remote 'g' packet
    
    This patch fixes that by postponing the setting of stop_pc to after
    we've updated the inferior gdbarch.
    
    This bug was hiding another problem, and as such introduces some
    failures in gdb.base/foll-exec-mode.exp.  The following patch takes care
    of that.
    
    gdb/ChangeLog:
    
    	* infrun.c (handle_inferior_event_1): When exec'ing, read
    	stop_pc after follow_exec.

commit fc8098275751f48404a547fd027b2671c5350302
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 5 16:43:07 2017 +0200

    Improve "'g' reply is is to long" error message
    
    ... by adding the expected size, and the received size.  I found this
    useful when debugging gdbarch/remote issues, since it gives a hint of
    what gdb expects and what the remote sent.
    
    gdb/ChangeLog:
    
    	* remote.c (process_g_packet): Update error message.

commit d2fcdd85466668c06dda0fa02ac8c1f4cef3910d
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 14:46:47 2017 +0100

    Add i386.o to gdb_target_obs for x86_64-* targets
    
    This patch fixes the build failure caused by 22916b0
    (Convert the rest x86 target descriptions).
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
    	targets.

commit e69570ee1886d64fb60c5d9d31f2e6ed76ab2dfc
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Sep 5 12:13:57 2017 +0100

    eval.c:evaluate_subexp_standard: Factor out function call handling
    
    While working on the no-debug-info debugging improvements, I found
    evaluate_subexp_standard's function call code unnecessarily long and
    hard to navigate and debug.  The use of goto doesn't help either.
    
    This commit tries to improve things by factoring out the
    function-call-related code to separate helper functions.
    
    gdb/ChangeLog:
    2017-09-05  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (eval_call, evaluate_funcall): New functions, factored
    	out from ...
    	(evaluate_subexp_standard): ... this.

commit f17e9d8ab58474cfa24910f9066f3b9823e190e7
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Sep 5 12:09:14 2017 +0100

    Fix a buffer overrun when parsing a corrupt MIPS ELF binary.
    
    	PR 21995
    	* readelf.c (process_mips_specific): Add checks for a NULL data
    	pointer.

commit 22916b0786336394bf84f68ba71875ac3cd48fea
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    Convert the rest x86 target descriptions
    
    This patch changes the rest of x86 target descriptions in GDB and
    GDBserver.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-tdep.c (amd64_target_description): Create target
    	descriptions.
    	(_initialize_amd64_tdep): Don't call functions
    	initialize_tdesc_amd64_*.  Add self tests.
    	* arch/amd64.c (amd64_create_target_description): Add parameter
    	is_linux.  Call set_tdesc_osabi if is_linux is true.
    	* arch/amd64.h (amd64_create_target_description): Update the
    	declaration.
    	* arch/i386.c (i386_create_target_description): Add parameter
    	is_linux.  Call set_tdesc_osabi if is_linux is true.
    	* arch/i386.h (i386_create_target_description): Update
    	declaration.
    	* configure.tgt: Add i386.o to gdb_target_obs.
    	* features/Makefile (XMLTOC): Remove i386/*.xml.
    	* features/i386/amd64-avx-avx512.c: Remove.
    	* features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
    	* features/i386/amd64-avx-mpx.c: Remove.
    	* features/i386/amd64-avx.c: Remove.
    	* features/i386/amd64-mpx.c: Remove.
    	* features/i386/amd64.c: Remove.
    	* features/i386/i386-avx-avx512.c: Remove.
    	* features/i386/i386-avx-mpx-avx512-pku.c: Remove.
    	* features/i386/i386-avx-mpx.c: Remove.
    	* features/i386/i386-avx.c: Remove.
    	* features/i386/i386-mmx.c: Remove.
    	* features/i386/i386-mpx.c: Remove.
    	* features/i386/i386.c: Remove.
    	* i386-tdep.c: Don't include features/i386/i386*.c., include
    	target-descriptions.h and arch/i386.h.
    	(i386_target_description): Create target descriptions.
    	(i386_gdbarch_init): Don't call initialize_tdesc_i386_*
    	functions.  Do self tests.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_i386_regobj): Remove.
    	(srv_amd64_regobj): Remove.
    	(srv_regobj): Set it to "" for x86 non-linux targets.
    	* linux-x86-tdesc.c (i386_linux_read_description):
    	* lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
    	(init_registers_i386): Remove the declaration.
    	(tdesc_i386): Remove the declaration.
    	(lynx_i386_arch_setup): Call i386_create_target_description.
    	* nto-x86-low.c: Likewise.
    	* win32-i386-low.c [__x86_64__]: include arch/amd64.h.
    	[!__x86_64__]: include arch/i386.h.
    	(i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.

commit 0854b7b1878dc9f8b8519e2efed605acecc14745
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    Remove features/i386/amd64-*linux.c and features/i386/x32-*linux.c
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
    	* features/i386/amd64-avx-avx512-linux.c: Removed.
    	* features/i386/amd64-avx-linux.c: Removed.
    	* features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
    	* features/i386/amd64-avx-mpx-linux.c: Removed.
    	* features/i386/amd64-linux.c: Removed.
    	* features/i386/amd64-mpx-linux.c: Removed.
    	* features/i386/x32-avx-avx512-linux.c: Removed.
    	* features/i386/x32-avx-linux.c: Removed.
    	* features/i386/x32-linux.c: Removed.

commit 38602d55e09bc9a28b5476ec3614a2483153ccaa
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    [GDBserver] Shorten srv_amd64_linux_xmlfiles
    
    GDBserver now is able to generate target descriptions from features, so
    don't need to remember these target description files.
    
    Note that it should be i386/amd64-avx-avx512-linux.xml instead of
    i386/amd64-avx-avx512.xml in $srv_amd64_linux_xmlfiles.  This patch
    removes it anyway.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_amd64_linux_xmlfiles): Remove
    	i386/amd64-XXX-linux from it.

commit 44b886ff15eccb555dda65f93c269ac9d8dd793b
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    [GDBserver] Use pre-generated amd64-linux tdesc as test
    
    Now, all these amd64-linux pre-generated tdesc can be used as test, so
    don't need to build them if $development is false.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv: Empty srv_amd64_linux_regobj if $development is
    	false.
    	(ipa_amd64_linux_regobj): Remove.
    	(ipa_x32_linux_regobj): Remove.

commit b4570e4b3032f9f4a508dbacd8136f79cf42c249
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    Convert amd64-linux target descriptions
    
    This patch changes amd64-linux target descriptions so that they can be
    dynamically generated in both GDB and GDBserver.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (arch-amd64.o): New rule.
    	* configure.srv: Append arch-amd64.o.
    	* linux-amd64-ipa.c: Include common/x86-xstate.h.
    	(get_ipa_tdesc): Call amd64_linux_read_description.
    	(initialize_low_tracepoint): Don't call init_registers_x32_XXX
    	and init_registers_amd64_XXX.
    	* linux-x86-low.c (x86_linux_read_description): Call
    	amd64_linux_read_description.
    	(x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
    	(initialize_low_arch): Don't call init_registers_x32_XXX and
    	init_registers_amd64_XXX.
    	* linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
    	and tdesc_amd64_XXX.
    	[__x86_64__] (amd64_tdesc_test): New function.
    	(initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
    	and init_registers_amd64_XXX.
    	* linux-x86-tdesc.c: Include arch/amd64.h.
    	(xcr0_to_tdesc_idx): New function.
    	(i386_linux_read_description): New function.
    	(amd64_get_ipa_tdesc_idx): New function.
    	* linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
    	(amd64_get_ipa_tdesc): Declare.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-linux-tdep.c: Include arch/amd64.h.  Don't include
    	features/i386/*.c.
    	(amd64_linux_read_description): Call
    	amd64_create_target_description.
    	* arch/amd64.c: New file.
    	* arch/amd64.h: New file.
    	* configure.tgt (x86_64-*-linux*): Append amd64.o.
    	* Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.

commit 6c73f67f9c545425befde590f06d690a068a69e2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:54 2017 +0100

    Lazily and dynamically create amd64-linux target descriptions
    
    This patch starts to use the generate c feature files to dynamically
    create amd64-linux target descriptions.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-linux-tdep.c: Don't include amd64-XXX-linux and
    	x32-XXX-linux.c.  Include 64bit-XX.c and x32-XX.c.
    	(amd64_linux_read_description): Create target descriptions.
    	(_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
    	functions.  Add unit tests.
    	* features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
    	x32-core.xml.
    	* features/i386/64bit-avx.c: Generated.
    	* features/i386/64bit-avx512.c: Generated.
    	* features/i386/64bit-core.c: Generated.
    	* features/i386/64bit-linux.c: Generated.
    	* features/i386/64bit-mpx.c: Generated.
    	* features/i386/64bit-pkeys.c: Generated.
    	* features/i386/64bit-segments.c: Generated.
    	* features/i386/64bit-sse.c: Generated.
    	* features/i386/x32-core.c: Generated.
    	* target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
    	c files for amd64-linux and x32-linux.

commit 9d3d478be5e21151d3755d7b2e6f1cd8ff92d726
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    Centralize amd64-linux target descriptions
    
    This patch adds a new function amd64_linux_read_description, which
    creates amd64-linux target descriptions according to its two
    arguments, xcr0 and is_x32.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-linux-tdep.c (amd64_linux_read_description): New
    	function.
    	(amd64_linux_core_read_description): Call
    	amd64_linux_read_description.
    	(amd64_linux_init_abi): Likewise.
    	(amd64_x32_linux_init_abi): Likewise.
    	* amd64-linux-tdep.h (amd64_linux_read_description): Declare.
    	* x86-linux-nat.c (x86_linux_read_description): Call
    	amd64_linux_read_description.

commit b9f1d50ffcac4c4b65cb05c2971106cb06e8774c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    Update comments in amd64_linux_core_read_description
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-linux-tdep.c (amd64_linux_core_read_description): Update
    	comments.

commit d1f28ea24a5232d3ea690de9bc8abfb77837f2c7
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    [GDBserver] Shorten srv_i386_linux_xmlfiles
    
    GDBserver now is able to generate target descriptions from features, so
    don't need to remember these target description files.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_i386_linux_xmlfiles): Remove
    	i386/i386-XXX-linux.xml from it.

commit 25a93583f34f5abfe9c1b24393738547a8de657c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    [GDBserver] Use pre-generated tdesc as test
    
    Now, these *-generate.c files are only used in GDBserver for unit test.
    If $development is false (in release), these *-generate.c files won't be
    used at all.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv: Set srv_i386_linux_regobj empty if $development
    	is false.
    	* linux-i386-ipa.c (initialize_low_tracepoint): Don't call
    	initialize_low_tdesc.
    	* linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
    	with #if initialize_low_tdesc.
    	* linux-x86-tdesc-selftest.c: New file.
    	* linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.

commit 188c9e6dcb2f1342f1ca51e8f68c22852522277e
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    Remove features/i386/i386-*linux.c
    
    Now, features/i386/i386-XXX-linux.c are not used, remove them.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
    	* features/i386/i386-avx-avx512-linux.c: Remove.
    	* features/i386/i386-avx-linux.c: Remove.
    	* features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
    	* features/i386/i386-avx-mpx-linux.c: Remove.
    	* features/i386/i386-linux.c: Remove.
    	* features/i386/i386-mmx-linux.c: Remove.
    	* features/i386/i386-mpx-linux.c: Remove.

commit 5f035c0716c3b6b310a736841b16088d984be917
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    Share i386-linux target description between GDB and GDBserver
    
    The code on creating i386-linux target descriptions are quite similar
    between GDB and GDBserver, so this patch moves them into a shared file
    arch/i386.c.  I didn't name it as i386-linux.c, because I want to reuse it
    to create other i386 non-linux target descriptions later.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (ALL_TARGET_OBS): Add i386.o.
    	(SFILES): Add arch/i386.c.
    	(HFILES_NO_SRCDIR): Add arch/i386.h.
    	* arch/i386.c: New file.
    	* arch/i386.h: New file.
    	* arch/tdesc.h (allocate_target_description): Declare.
    	(set_tdesc_architecture): Declare.
    	(set_tdesc_osabi): Declare.
    	* configure.tgt (i[34567]86-*-linux*): Add i386.o.
    	* i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
    	include arch/i386.h.
    	(i386_linux_read_description): Remove code and call
    	i386_create_target_description.
    	(set_tdesc_architecture): New function.
    	(set_tdesc_osabi): New function.
    	* target-descriptions.h (allocate_target_description): Remove.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (arch-i386.o): New rule.
    	* configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
    	(x86_64-*-linux*): Likewise.
    	* linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
    	include arch/i386.h.
    	(i386_linux_read_description): Remove code and call
    	i386_create_target_description.
    	* tdesc.c (allocate_target_description): New function.
    	* tdesc.h (set_tdesc_architecture): Remove declaration.
    	(set_tdesc_osabi): Likewise.

commit 0abe8a8992948559d225ff120095e42a1a6a36f4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    Dynamically composite xml in reply to GDB
    
    GDBserver still uses pre-generated target descriptions in order to
    reply to GDB's query on target description (see xml-builtin-generated.c
    in GDBserver build directory).  This patch teaches GDBserver to
    create XML contents according to the target descriptions rather than
    using pre-generated ones.
    
    First, change target feature c files to pass the feature xml file
    name to tdesc_create_feature, so that target description in GDBserver
    can record them, and create XML contents from these features in
    buffer, like
    
      ...
      <xi:include href="$FEATURE1_XML_NAME"/>
      <xi:include href="$FEATURE2_XML_NAME"/>
      ...
    
    and send this buffer back to GDB.
    
    Note that this patch reuses target_desc.xmltarget a little bit, which is
    to hold the XML contents dynamically generated in tdesc_get_features_xml.
    However, it is not xfree'ed in ~target_desc, because we can't tell it is
    from xstrdup or a literal string.  Since we don't delete target_desc,
    there is no memory leak yet.  After we change all target descriptions to
    the new style, target_desc.xmltarget is from xstrdup, then, we can safely
    xfree it in ~target_desc.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* arch/tdesc.h (tdesc_create_feature): Add an argument xml.
    	* target-descriptions.c (tdesc_create_feature): Likewise, and
    	adjust code.
    	* features/i386/32bit-avx.c: Re-generated.
    	* features/i386/32bit-avx512.c: Re-generated.
    	* features/i386/32bit-core.c: Re-generated.
    	* features/i386/32bit-linux.c: Re-generated.
    	* features/i386/32bit-mpx.c: Re-generated.
    	* features/i386/32bit-pkeys.c: Re-generated.
    	* features/i386/32bit-sse.c: Re-generated.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-x86-tdesc.c: Don't include <inttypes.h>.
    	(i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
    	set_tdesc_architecture and set_tdesc_osabi.  Remove code setting
    	.xmltarget.
    	* server.c (get_features_xml): Call tdesc_get_features_xml.
    	* tdesc.c (set_tdesc_architecture): New function.
    	(set_tdesc_osabi): New function.
    	(tdesc_get_features_xml): New function.
    	(tdesc_create_feature): Add an argument.
    	* tdesc.h (struct target_desc) <features>: New field.
    	<arch, osabi>: New field.
    	(~target_desc): xfree features, arch, and osabi.
    	(target_desc::oerator==): Don't compare .xmltarget.
    	[!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
    	(set_tdesc_osabi): Likewise.
    	(tdesc_get_features_xml): Likewise.

commit 0a188386c032126045979b7fb7c238d715c81eb5
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    [GDBserver] unit test to i386_tdesc
    
    This patch adds a unit test in GDBserver to test dynamically created
    target descriptions equal these pre-generated ones.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-x86-tdesc.c: Include selftest.h.
    	(i386_tdesc_test): New function.
    	(initialize_low_tdesc): Call selftests::register_test.
    	* tdesc.h: Include regdef.h.
    	(target_desc): Override operator == and !=.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* regformats/regdef.h (struct reg): Override operator == and !=.

commit f49ff00066929bf7c38f9c89ad640561bbb331f6
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:53 2017 +0100

    [GDBserver] Centralize tdesc for i386-linux
    
    tdesc_i386_XXX_linux is used in many places in linux-x86-low.c and this
    patch adds a new function i386_linux_read_description to return the right
    tdesc according to xcr0.  i386_linux_read_description is quite similar to
    the counterpart in GDB, and the following patch will share the duplicated
    code, so this patch adds arch/tdesc.h includes the declarations of various
    tdesc apis which are used by the shared code.  The generated c feature
    files can include arch/tdesc.h only.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
    	(ipa_obj): Likewise.
    	* linux-i386-ipa.c: Include common/x86-xstate.h
    	(get_ipa_tdesc): Call i386_linux_read_description.
    	(initialize_low_tracepoint): Don't call  init_registers_XXX
    	functions, call initialize_low_tdesc instead.
    	* linux-x86-low.c (x86_linux_read_description): Call
    	i386_linux_read_description.
    	(initialize_low_arch): Don't call init_registers_i386_XXX
    	functions, call initialize_low_tdesc.
    	* linux-x86-tdesc.c: New file.
    	* linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
    	(i386_get_ipa_tdesc_idx): Declare.
    	(i386_get_ipa_tdesc): Declare.
    	(initialize_low_tdesc): Declare.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* arch/tdesc.h: New file.
    	* regformats/regdat.sh: Generate code using tdesc_create_reg.
    	* target-descriptions.c: Update comments.
    	* target-descriptions.h: Include "arch/tdesc.h".  Remove the
    	declarations.
    	* features/i386/32bit-avx.c: Re-generated.
    	* features/i386/32bit-avx512.c: Re-generated.
    	* features/i386/32bit-core.c: Re-generated.
    	* features/i386/32bit-linux.c: Re-generated.
    	* features/i386/32bit-mpx.c: Re-generated.
    	* features/i386/32bit-pkeys.c: Re-generated.
    	* features/i386/32bit-sse.c: Re-generated.

commit 2b68ef2f11daef3ab3c6941ebf53dfcd0fb79fbf
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:52 2017 +0100

    Return X86_TDESC_MMX in x86_get_ipa_tdesc_idx
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
    	instead of 0.

commit f7000548a2b79d7e5cb924468117ca4245e6b820
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:52 2017 +0100

    Use VEC for target_desc.reg_defs
    
    Nowadays, target_desc.reg_defs is a pointer points to a pre-generated
    array, which is not flexible.  This patch changes it from an array
    to a VEC so that GDBserver can create target descriptions dynamically
    later.  Instead of using pre-generated array, the -generated.c calls
    VEC_safe_push to add each register to vector.
    
    Since target_desc.reg_defs is used in IPA, we need to build common/vec.c
    for IPA too.
    
    gdb/gdbserver:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (IPA_OBJS): Add vec-ipa.o
    	* regcache.c (get_thread_regcache): Use VEC_length.
    	(init_register_cache): Likewise.
    	(regcache_cpy): Likewise.
    	(registers_to_string): Iterate reg_defs via VEC_iterate.
    	(find_regno): Likewise.
    	(find_register_by_number): Use VEC_index.
    	(register_size): Call find_register_by_number.
    	(register_data): Call find_register_by_number.
    	(supply_regblock): Use VEC_length.
    	(regcache_raw_read_unsigned): Likewise.
    	* tdesc.c (init_target_desc): Iterate reg_defs via
    	VEC_iterate.
    	(default_description): Update initializer.
    	(copy_target_description): Don't update field num_registers.
    	* tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
    	<num_registers>: Remove.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* regformats/regdat.sh: Update generated code.

commit c9a5e2a5b2b20d83f60026459d3a6b68481566c9
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Sep 5 09:54:52 2017 +0100

    Adjust code generated by regformats/regdat.sh
    
    regformats/regdat.sh generate some *-generated.c files when GDBserver
    is built.  Each .c file has some static variables, which are only used
    within function init_registers_XXX, like this,
    
    static struct reg regs_i386_linux[] = {
      { "eax", 0, 32 },
      { "ecx", 32, 32 },
      ...
    };
    
    static const char *expedite_regs_i386_linux[] = { "ebp", "esp", "eip", 0 };
    static const char *xmltarget_i386_linux = "i386-linux.xml";
    
    void
    init_registers_i386_linux (void)
    {
      ...
    }
    
    This patch moves these static variables' definitions to function
    init_registers_XXX, so the generated files look like this,
    
    void
    init_registers_i386_linux (void)
    {
      static struct target_desc tdesc_i386_linux_s;
      struct target_desc *result = &tdesc_i386_linux_s;
    static struct reg regs_i386_linux[] = {
      ...
    };
    
    static const char *expedite_regs_i386_linux[] = { "ebp", "esp", "eip", 0 };
    static const char *xmltarget_i386_linux = "i386-linux.xml";
    
      ...
    }
    
    We want GDBserver create target descriptions dynamically in each
    init_registers_XXXX functions, so this patch moves all the related code
    into function init_registers_XXXX, so that the following patch can easily
    change function init_registers_XXXX to create target description
    dynamically, rather than using current pre-generated array.
    
    gdb:
    
    2017-09-05  Yao Qi  <yao.qi@linaro.org>
    
    	* regformats/regdat.sh: Adjust code order.

commit d6b687ac7a2bfd0c3962f45ea5e1a72310f4e07e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Sep 5 09:00:42 2017 +0200

    expprint: Fix format string warning
    
    My compiler (gcc 5.4.0, clang 3.8) gives this warning:
    
    /home/emaisin/src/binutils-gdb/gdb/expprint.c: In lambda function:
    /home/emaisin/src/binutils-gdb/gdb/expprint.c:1055:35: error: format not a string literal and no format arguments [-Werror=format-security]
          fprintf_filtered (stream, mod);
                                       ^
    
    Fix it by not using the passed string as the format string.
    
    gdb/ChangeLog:
    
    	* expprint.c (dump_subexp_body_standard): Use constant format
    	string in fprintf_filtered call.

commit 625ce09c1cfb557725310f602ee66ac1475d780e
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 19:53:50 2017 -0700

    Define an error function in the PPC simulator library.
    
    Previously this used the error function from GDB directly when linked
    against GDB instead of the error method in the host callbacks
    structure.  This was exposed via a link error when GDB was converted
    to C++.  The error function invokes the error callback similar to
    sim_io_error.
    
    Note that there are also error functions in sim/ppc/main.c and
    sim/ppc/misc.c.  The ppc libsim.a expects each consumer to provide
    several symbols used by the library including "error".  sim-calls.c
    provides these symbols when the library is linked into gdb.  The dgen,
    igen, tmp-filter, tmp-ld-decode, tmp-ld-cache, and tmp-ld-insn programs
    use the functions from misc.c.  psim uses the functions from main.c.
    
    sim/ppc/ChangeLog:
    
    	PR sim/20863
    	* sim_calls.c (error): New function.

commit a379bfd00effbbb0fb4df02dc686c2c110023cea
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 19:34:48 2017 -0700

    Enable support for x86 debug registers on NetBSD.
    
    NetBSD recently added PT_GETDBREGS and PT_SETDBREGS ptrace operations
    that match the existing ones supported by x86-bsd-nat.c.  NetBSD's
    headers do not provide the DBREG_DRX helper macro, so define a local
    version in x86-bsd-nat.c.  In addition, add the x86-nat.o and x86-dregs.o
    object files to the native NetBSD x86 build targets.
    
    gdb/ChangeLog:
    
    	* configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
    	NetBSD/i386.
    	* x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.

commit f7efc967ba45350b688e0f661a31eecc15d5e052
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 19:34:48 2017 -0700

    Make <sys/user.h> include in bsd-kvm.c conditional on HAVE_SYS_USER_H.
    
    NetBSD has recently removed <sys/user.h>.
    
    gdb/ChangeLog:
    
    	* bsd-kvm.c: Make <sys/user.h> conditional on HAVE_SYS_USER_H.

commit c49fbc6c79e0c479371e0ba7be0c8d1137016864
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 19:34:48 2017 -0700

    Define _KMEMUSER before including BSD kernel headers.
    
    Recent versions of NetBSD hide certain kernel structures needed by the
    KVM target from userland unless this macro is defined.
    
    gdb/ChangeLog:
    
    	* bsd-kvm.o: Define _KMEMUSER.
    	* configure.ac: Define _KMEMUSER when checking for "struct lwp".
    	* configure: Regenerate.

commit 26562e73d8eb20c9b8289911cee557de8e5272c3
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 19:31:33 2017 -0700

    Include "x86-xstate.h" for X86_XSTATE_* constants.
    
    gdb/ChangeLog:
    
    	* amd64-fbsd-nat.c: Add include of "x86-xstate.h".
    	* i386-fbsd-nat.c: Likewise.

commit 0097251b8a2fcee7f536807328ea2b73a2f7c41c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Sep 5 00:00:18 2017 +0000

    Automatic date update in version.in

commit 83eef883581525d04df3a8e53a82c01d0d12b56a
Author: Alexander Fedotov-B55613 <b55613@freescale.com>
Date:   Tue Sep 5 08:22:17 2017 +0930

    Missing relocation R_PPC_VLE_ADDR20 and add VLE flag to details in readelf
    
    include/
    	* elf/ppc.h (R_PPC_VLE_ADDR20): New relocation.
    bfd/
    	* elf32-ppc.c (ppc_elf_howto_raw): Add R_PPC_VLE_ADDR20.
    	(ppc_elf_check_relocs): Handle it.
    	(ppc_elf_vle_split20): New function.
    	(ppc_elf_relocate_section): Handle R_PPC_VLE_ADDR20.
    binutils/
    	* readelf.c (get_elf_section_flags): Add VLE.
    	(process_section_headers): Add VLE key to details.
    gas/
    	* config/tc-ppc.c (md_parse_option): Handle "mno-vle" flag.
    	(ppc_elf_section_letter): New function.
    	* config/tc-ppc.h (md_elf_section_letter): New.
    	* testsuite/gas/elf/section10.d: Adjust for VLE.

commit 31cf148787509fcf33bc6adb05bbf16bee48835d
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 15:58:38 2017 -0700

    Explicitly include <array> for std::array<>.
    
    gdb/ChangeLog:
    
    	* unittests/array-view-selftests.c: Add include of <array>.

commit 5b9f8a7c6e3873f97365569f50883a866b0a984a
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Sep 4 15:57:02 2017 -0700

    Catch up to recent changes to call_function_by_hand().
    
    gdb/ChangeLog:
    
    	* spu-tdep.c (flush_ea_cache): Add missing argument to
    	call_function_by_hand.

commit d69cf9b2076d63bad3842bc6406a679598851727
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:16 2017 +0100

    Document "no debug info debugging" improvements
    
    Here's the documentation bits for all the improvements done in
    previous commits.
    
    Note that the original "weak alias functions" paragraph ends up
    disappearing, because this patch, which I'm considering kind of part
    of this series, makes the alias case Just Work:
      https://sourceware.org/ml/gdb-patches/2017-07/msg00018.html
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* NEWS (Safer support for debugging with no debug info): New.
    
    gdb/doc/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.texinfo (Variables) <Program Variables>: Document inspecting
    	no-debug-info variables.
    	(Symbols) <Examining the Symbol Table>: Document inspecting
    	no-debug-info types.
    	(Calling) <Calling functions with no debug info>: New subsection,
    	documenting calling no-debug-info functions.
    	(Non-debug DLL Symbols) <Working with Minimal Symbols>: Update.

commit 3693fdb3c8ec14bd8ecb4ebb39e4384b330a2999
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:16 2017 +0100

    Make "p S::method() const::static_var" work too
    
    Trying to print a function local static variable of a const-qualified
    method still doesn't work after the previous fixes:
    
      (gdb) p 'S::method() const'::static_var
      $1 = {i1 = 1, i2 = 2, i3 = 3}
      (gdb) p S::method() const::static_var
      No symbol "static_var" in specified context.
    
    The reason is that the expression parser/evaluator loses the "const",
    and the above unquoted case is just like trying to print a variable of
    the non-const overload, if it exists, even.  As if the above unquoted
    case had been written as:
    
      (gdb) p S::method()::static_var
      No symbol "static_var" in specified context.
    
    We can see the problem without static vars in the picture.  With:
    
     struct S
     {
        void method ();
        void method () const;
     };
    
    Compare:
    
      (gdb) print 'S::method(void) const'
      $1 = {void (const S * const)} 0x400606 <S::method() const>
      (gdb) print S::method(void) const
      $2 = {void (S * const)} 0x4005d8 <S::method()>   # wrong method!
    
    That's what we need to fix.  If we fix that, the function local static
    case starts working.
    
    The grammar production for function/method types is this one:
    
      exp:       exp '(' parameter_typelist ')' const_or_volatile
    
    This results in a TYPE_INSTANCE expression evaluator operator.  For
    the example above, we get something like this ("set debug expression 1"):
    
    ...
                0  TYPE_INSTANCE         1 TypeInstance: Type @0x560fda958be0 (void)
                5    OP_SCOPE              Type @0x560fdaa544d8 (S) Field name: `method'
    ...
    
    While evaluating TYPE_INSTANCE, we end up in
    value_struct_elt_for_reference, trying to find the method named
    "method" that has the prototype recorded in TYPE_INSTANCE.  In this
    case, TYPE_INSTANCE says that we're looking for a method that has
    "(void)" as parameters (that's what "1 TypeInstance: Type
    @0x560fda958be0 (void)" above means.  The trouble is that nowhere in
    this mechanism do we communicate to value_struct_elt_for_reference
    that we're looking for the _const_ overload.
    value_struct_elt_for_reference only compared parameters, and the
    non-const "method()" overload has matching parameters, so it's
    considered the right match...
    
    Conveniently, the "const_or_volatile" production in the grammar
    already records "const" and "volatile" info in the type stack.  The
    type stack is not used in this code path, but we can borrow the
    information.  The patch converts the info in the type stack to an
    "instance flags" enum, and adds that as another element in
    TYPE_INSTANCE operators.  This type instance flags is then applied to
    the temporary type that is passed to value_struct_elt_for_reference
    for matching.
    
    The other side of the problem is that methods in the debug info aren't
    marked const/volatile, so with that in place, the matching never finds
    const/volatile-qualified methods.
    
    The problem is that in the DWARF, there's no indication at all whether
    a method is const/volatile qualified...  For example (c++filt applied
    to the linkage name for convenience):
    
       <2><d3>: Abbrev Number: 6 (DW_TAG_subprogram)
          <d4>   DW_AT_external    : 1
          <d4>   DW_AT_name        : (indirect string, offset: 0x3df): method
          <d8>   DW_AT_decl_file   : 1
          <d9>   DW_AT_decl_line   : 58
          <da>   DW_AT_linkage_name: (indirect string, offset: 0x5b2): S::method() const
          <de>   DW_AT_declaration : 1
          <de>   DW_AT_object_pointer: <0xe6>
          <e2>   DW_AT_sibling     : <0xec>
    
    I see the same with both GCC and Clang.  The patch works around this
    by extracting the cv qualification from the "const" and "volatile" in
    the demangled name.  This will need further tweaking for "&" and
    "const &" overloads, but we don't support them in the parser yet,
    anyway.
    
    The TYPE_CONST changes were necessary otherwise the comparisons in valops.c:
    
      if (TYPE_CONST (intype) != TYPE_FN_FIELD_CONST (f, j))
        continue;
    
    would fail, because when both TYPE_CONST() TYPE_FN_FIELD_CONST() were
    true, their values were different.
    
    BTW, I'm recording the const/volatile-ness of methods in the
    TYPE_FN_FIELD info because #1 - I'm not sure it's kosher to change the
    method's type directly (vs having to call make_cv_type to create a new
    type), and #2 it's what stabsread.c does:
    
    ...
    	    case 'A':		/* Normal functions.  */
    	      new_sublist->fn_field.is_const = 0;
    	      new_sublist->fn_field.is_volatile = 0;
    	      (*pp)++;
    	      break;
    	    case 'B':		/* `const' member functions.  */
    	      new_sublist->fn_field.is_const = 1;
    	      new_sublist->fn_field.is_volatile = 0;
    ...
    
    After all this, this finally all works:
    
      print S::method(void) const
      $1 = {void (const S * const)} 0x400606 <S::method() const>
      (gdb) p S::method() const::static_var
      $2 = {i1 = 1, i2 = 2, i3 = 3}
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* c-exp.y (function_method, function_method_void): Add current
    	instance flags to TYPE_INSTANCE.
    	* dwarf2read.c (check_modifier): New.
    	(compute_delayed_physnames): Assert that only C++ adds delayed
    	physnames.  Mark fn_fields as const/volatile depending on
    	physname.
    	* eval.c (make_params): New type_instance_flags parameter.  Use
    	it as the new type's instance flags.
    	(evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
    	flags element and pass it to make_params.
    	* expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
    	instance flags element.
    	(dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
    	* gdbtypes.h: Include "enum-flags.h".
    	(type_instance_flags): New enum-flags type.
    	(TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
    	(TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
    	* parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
    	(follow_type_instance_flags): New function.
    	(operator_check_standard) <TYPE_INSTANCE>: Adjust.
    	* parser-defs.h (follow_type_instance_flags): Declare.
    	* valops.c (value_struct_elt_for_reference): const/volatile must
    	match too.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/func-static.c (S::method const, S::method volatile)
    	(S::method volatile const): New methods.
    	(c_s, v_s, cv_s): New instances.
    	(main): Call method() on them.
    	* gdb.base/func-static.exp (syntax_re, cannot_resolve_re): New variables.
    	(cannot_resolve): New procedure.
    	(cxx_scopes_list): Test cv methods.  Add print-scope-quote and
    	print-quote-unquoted columns.
    	(do_test): Test printing each scope too.

commit e68cb8e00166d2f8a9e23c60f68bec04ef0a90f0
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:16 2017 +0100

    Handle "p 'S::method()::static_var'" (quoted) in symbol lookup
    
    While the previous commit made "p method()::static_var" (no
    single-quotes) Just Work, if users (or frontends) try wrapping the
    expression with quotes, they'll get:
    
      (gdb) p 'S::method()::static_var'
      'S::method()::static_var' has unknown type; cast it to its declared type
    
    even if we _do_ have debug info for that variable.  That's better than
    the bogus/confusing value what GDB would print before the
    stop-assuming-int patch:
    
      (gdb) p 'S::method()::static_var'
      $1 = 1
    
    but I think it'd still be nice to make this case Just Work too.
    
    In this case, due to the quoting, the C/C++ parser (c-exp.y)
    interprets the whole expression/string as a single symbol name, and we
    end up calling lookup_symbol on that name.  There's no debug symbol
    with that fully-qualified name, but since the compiler gives the
    static variable a mangled linkage name exactly like the above, it
    appears in the mininal symbols:
    
      $ nm -A local-static | c++filt | grep static_var
      local-static:0000000000601040 d S::method()::static_var
    
    ... and that's what GDB happens to find/print.  This only happens in
    C++, note, since for C the compiler uses different linkage names:
    
      local-static-c:0000000000601040 d static_var.1848
    
    So while (in C++, not C) function local static variables are given a
    mangled name that demangles to the same syntax that GDB
    documents/expects as the way to access function local statics, there's
    no global symbol in the debug info with that name at all.  The debug
    info for a static local variable for a non-inline function looks like
    this:
    
     <1><2a1>: Abbrev Number: 19 (DW_TAG_subprogram)
     ...
     <2><2f7>: Abbrev Number: 20 (DW_TAG_variable)
        <2f8>   DW_AT_name        : (indirect string, offset: 0x4e9): static_var
        <2fc>   DW_AT_decl_file   : 1
        <2fd>   DW_AT_decl_line   : 64
        <2fe>   DW_AT_type        : <0x25>
        <302>   DW_AT_location    : 9 byte block: 3 40 10 60 0 0 0 0 0      (DW_OP_addr: 601040)
    
    and for an inline function, it looks like this (linkage name run
    through c++filt for convenience):
    
     <2><21b>: Abbrev Number: 16 (DW_TAG_variable)
        <21c>   DW_AT_name        : (indirect string, offset: 0x21a): static_var
        <220>   DW_AT_decl_file   : 1
        <221>   DW_AT_decl_line   : 48
        <222>   DW_AT_linkage_name: (indirect string, offset: 0x200): S::inline_method()::static_var
        <226>   DW_AT_type        : <0x25>
        <22a>   DW_AT_external    : 1
        <22a>   DW_AT_location    : 9 byte block: 3 a0 10 60 0 0 0 0 0      (DW_OP_addr: 6010a0)
    
    (The inline case makes the variable external so that the linker can
    merge the different inlined copies.  It seems like GCC never outputs
    the linkage name for non-extern globals.)
    
    When we read the DWARF, we record the static_var variable as a regular
    variable of the containing function's block.  This makes stopping in
    the function and printing the variable as usual.  The variable just so
    happens to have a memory address as location.
    
    So one way to make "p 'S::method()::static_var'" work would be to
    record _two_ copies of the symbols for these variables.  One in the
    function's scope/block, with "static_var" as name, as we currently do,
    and another in the static or global blocks (depending on whether the
    symbol is external), with a fully-qualified name.  I wrote a prototype
    patch for that, and it works.  For the non-inline case above, since
    the debug info doesn't point to the linkage same, that patch built the
    physname of the static local variable as the concat of the physname of
    the containing function, plus "::", plus the variable's name.  We
    could make that approach work for C too, though it kind of feels
    awkward to record fake symbol names like that in C.
    
    The other approach I tried is to change the C++ symbol lookup routines
    instead.  This is the approach this commit takes.  We can already
    lookup up symbol in namespaces and classes, so this feels like a good
    fit, and was easy enough.  The advantage is that this doesn't require
    recording extra symbols.
    
    The test in gdb.cp/m-static.exp that exposed the need for this is
    removed, since the same functionality is now covered by
    gdb.cp/local-static.exp.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* cp-namespace.c (cp_search_static_and_baseclasses): Handle
    	function/method scopes; lookup the nested name as a function local
    	static variable.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/local-static.exp: Also test with
    	class::method::variable wholly quoted.
    	* gdb.cp/m-static.exp (class::method::variable): Remove test.

commit 858be34c5a03bb8973679ebf00d360182434dc00
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:15 2017 +0100

    Handle "p S::method()::static_var" in the C++ parser
    
    This commit makes "print S::method()::static_var" actually find the
    debug symbol for static_var.  Currently, you get:
    
      (gdb) print S::method()::static_var
      A syntax error in expression, near `'.
    
    Quoting the whole string would seemingly work before the previous
    patch that made GDB stop assuming int for no-debug-info variables:
    
      (gdb) p 'S::method()::static_var'
      $1 = 1
    
    ... except that's incorrect output, because:
    
      (gdb) ptype 'S::method()::static_var'
      type = <data variable, no debug info>
    
    The way to make it work correctly currently is by quoting the
    function/method part, like this:
    
      (gdb) print 'S::method()'::static_var
      $1 = {i1 = 1, i2 = 2, i3 = 3}
      (gdb) ptype 'S::method()'::static_var
      type = struct aggregate {
          int i1;
          int i2;
          int i3;
      }
    
    At least after the "stop assuming int" patch, this is what we
    now get:
    
      (gdb) p 'S::method()::static_var'
      'S::method()::static_var' has unknown type; cast it to its declared type
      (gdb) p (struct aggregate) 'S::method()::static_var'
      $1 = {i1 = 1, i2 = 2, i3 = 3}
    
    However, IMO, users shouldn't really have to care about any of this.
    GDB should Just Work, without quoting, IMO.
    
    So here's a patch that implements support for that in the C++ parser.
    With this patch, you now get:
    
      (gdb) p S::method()::S_M_s_var_aggregate
      $1 = {i1 = 1, i2 = 2, i3 = 3}
      (gdb) ptype S::method()::S_M_s_var_aggregate
      type = struct aggregate {
          int i1;
          int i2;
          int i3;
      }
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	(%type <voidval>): Add function_method.
    	* c-exp.y (exp): New production for calls with no arguments.
    	(function_method, function_method_void_or_typelist): New
    	productions.
    	(exp): New production for "method()::static_var".
    	* eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
    	* expprint.c (print_subexp_standard, dump_subexp_body_standard):
    	Handle OP_FUNC_STATIC_VAR.
    	* parse.c (operator_length_standard):
    	Handle OP_FUNC_STATIC_VAR.
    	* std-operator.def (OP_FUNC_STATIC_VAR): New.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/local-static.c: New.
    	* gdb.base/local-static.cc: New.
    	* gdb.base/local-static.exp:  New.

commit dd5901a6a5bba75f3dee49f9a27640eedad90afe
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:15 2017 +0100

    Eliminate UNOP_MEMVAL_TLS
    
    Since minsym references now go via OP_VAR_MSYM_VALUE, UNOP_MEMVAL_TLS
    is no longer used anywhere.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
    	handling.
    	* expprint.c (print_subexp_standard, dump_subexp_body_standard):
    	Ditto.
    	* parse.c (operator_length_standard, operator_check_standard):
    	Ditto.
    	* std-operator.def (UNOP_MEMVAL_TLS): Delete.

commit 46a4882b3c7d9ec981568b8b13a3c9c39c8f8e61
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:15 2017 +0100

    Stop assuming no-debug-info variables have type int
    
    An earlier commit made GDB no longer assume no-debug-info functions
    return int.  This commit gives the same treatment to variables.
    
    Currently, you can end misled by GDB over output like this:
    
      (gdb) p var
      $1 = -1
      (gdb) p /x var
      $2 = 0xffffffff
    
    until you realize that GDB is assuming that the variable is an "int",
    because:
    
      (gdb) ptype var
      type = <data variable, no debug info>
    
    You may try to fix it by casting, but that doesn't really help:
    
      (gdb) p /x (unsigned long long) var
      $3 = 0xffffffffffffffff            # incorrect
             ^^
    
    That's incorrect output, because the variable was defined like this:
    
      uint64_t var = 0x7fffffffffffffff;
                       ^^
    
    What happened is that with the cast, GDB did an int -> 'unsigned long
    long' conversion instead of reinterpreting the variable as the cast-to
    type.  To get at the variable properly you have to reinterpret the
    variable's address manually instead, with either:
    
      (gdb) p /x *(unsigned long long *) &var
      $4 = 0x7fffffffffffffff
      (gdb) p /x {unsigned long long} &var
      $5 = 0x7fffffffffffffff
    
    After this commit GDB does it for you.  This is what you'll get
    instead:
    
      (gdb) p var
      'var' has unknown type; cast it to its declared type
      (gdb) p /x (unsigned long long) var
      $1 = 0x7fffffffffffffff
    
    As in the functions patch, the "compile" machinery doesn't currently
    have the cast-to type handy, so it continues assuming no-debug
    variables have int type, though now at least it warns.
    
    The change to gdb.cp/m-static.exp deserves an explanation:
    
     - gdb_test "print 'gnu_obj_1::method()::sintvar'" "\\$\[0-9\]+ = 4" \
     + gdb_test "print (int) 'gnu_obj_1::method()::sintvar'" "\\$\[0-9\]+ = 4" \
    
    That's printing the "sintvar" function local static of the
    "gnu_obj_1::method()" method.
    
    The problem with that test is that that "'S::method()::static_var'"
    syntax doesn't really work in C++ as you'd expect.  The way to make it
    work correctly currently is to quote the method part, not the whole
    expression, like:
    
      (gdb) print 'gnu_obj_1::method()'::sintvar
    
    If you wrap the whole expression in quotes, like in m-static.exp, what
    really happens is that the parser considers the whole string as a
    symbol name, but there's no debug symbol with that name.  However,
    local statics have linkage and are given a mangled name that demangles
    to the same string as the full expression, so that's what GDB prints.
    After this commit, and without the cast, the print in m-static.exp
    would error out saying that the variable has unknown type:
    
      (gdb) p 'gnu_obj_1::method()::sintvar'
      'gnu_obj_1::method()::sintvar' has unknown type; cast it to its declared type
    
    TBC, if currently (even before this series) you try to print any
    function local static variable of type other than int, you'll get
    bogus results.  You can see that with m-static.cc as is, even.
    Printing the "svar" local, which is a boolean (1 byte) still prints as
    "int" (4 bytes):
    
      (gdb) p 'gnu_obj_1::method()::svar'
      $1 = 1
      (gdb) ptype 'gnu_obj_1::method()::svar'
      type = <data variable, no debug info>
    
    This probably prints some random bogus value on big endian machines.
    
    If 'svar' was of some aggregate type (etc.) we'd still print it as
    int, so the problem would have been more obvious...  After this
    commit, you'll get instead:
    
      (gdb) p 'gnu_obj_1::method()::svar'
      'gnu_obj_1::method()::svar' has unknown type; cast it to its declared type
    
    ... so at least GDB is no longer misleading.  Making GDB find the real
    local static debug symbol is the subject of the following patches.  In
    the end, it'll all "Just Work".
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* ax-gdb.c: Include "typeprint.h".
    	(gen_expr_for_cast): New function.
    	(gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
    	<OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
    	type is unknown.
    	* dwarf2read.c (new_symbol_full): Fallback to int instead of
    	nodebug_data_symbol.
    	* eval.c: Include "typeprint.h".
    	(evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
    	Error out if symbol has unknown type.
    	<UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
    	evaluate_subexp_for_cast.
    	(evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
    	OP_VAR_MSYM_VALUE.
    	(evaluate_subexp_for_cast): New function.
    	* gdbtypes.c (init_nodebug_var_type): New function.
    	(objfile_type): Use it to initialize types of variables with no
    	debug info.
    	* typeprint.c (error_unknown_type): New.
    	* typeprint.h (error_unknown_type): New declaration.
    	* compile/compile-c-types.c (convert_type_basic): Handle
    	TYPE_CODE_ERROR; warn and fallback to int for variables with
    	unknown type.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.asm/asm-source.exp: Add casts to int.
    	* gdb.base/nodebug.c (dataglobal8, dataglobal32_1, dataglobal32_2)
    	(dataglobal64_1, dataglobal64_2): New globals.
    	* gdb.base/nodebug.exp: Test different expressions involving the
    	new globals, with print, whatis and ptype.  Add casts to int.
    	* gdb.base/solib-display.exp: Add casts to int.
    	* gdb.compile/compile-ifunc.exp: Expect warning.  Add cast to int.
    	* gdb.cp/m-static.exp: Add cast to int.
    	* gdb.dwarf2/dw2-skip-prologue.exp: Add cast to int.
    	* gdb.threads/tls-nodebug.exp: Check that gdb errors out printing
    	tls variable with no debug info without a cast.  Test with a cast
    	to int too.
    	* gdb.trace/entry-values.exp: Add casts.

commit fe13dfecbf7d5a9ba3a5d9f52e33e0ddacb39bcc
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:14 2017 +0100

    evaluate_subexp_standard: Factor out OP_VAR_VALUE handling.
    
    A following patch will want to call the new evaluate_var_value
    function in another spot.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (evaluate_var_value): New function, factored out from ...
    	(evaluate_subexp_standard): ... here.

commit d008ee21562d9f823b3d081b9b60e86509a5e85a
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:14 2017 +0100

    evaluate_subexp_standard: Remove useless assignments
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
    	Remove useless assignments to 'op'.

commit 827d0c517e2000102ac7d457109baa63e085c435
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:14 2017 +0100

    evaluate_subexp_standard: Eliminate one goto
    
    A following patch will want to factor out a bit of
    evaluate_subexp_standard, and it'd be handy to reuse the code under the
    "nosideret:" label there too.  This commits moves it to a separate
    function as preparation for that.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (eval_skip_value): New function.
    	(evaluate_subexp_standard): Use it.

commit 2c5a2be1902b50e34411baa57ff0b747e8e20e8b
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:14 2017 +0100

    Make ptype/whatis print function name of functions with no debug info too
    
    The patch to make GDB stop assuming functions return int left GDB with
    an inconsistency.  While with normal expression evaluation the
    "unknown return type" error shows the name of the function that misses
    debug info:
    
      (gdb) p getenv ("PATH")
      'getenv' has unknown return type; cast the call to its declared return type
       ^^^^^^
    
    which is handy in more complicated expressions, "ptype" does not:
    
      (gdb) ptype getenv ("PATH")
      function has unknown return type; cast the call to its declared return type
      ^^^^^^^^
    
    This commit builds on the new OP_VAR_MSYM_VALUE to fix it, by making
    OP_FUNCALL extract the function name from the symbol stored in
    OP_VAR_VALUE/OP_VAR_MSYM_VALUE.  We now get the same error in "print"
    vs "ptype":
    
      (gdb) ptype getenv()
      'getenv' has unknown return type; cast the call to its declared return type
      (gdb) p getenv()
      'getenv' has unknown return type; cast the call to its declared return type
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
    	function name from symbol/minsym and pass it to
    	error_call_unknown_return_type.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/nodebug.exp: Test that ptype's error about functions
    	with unknown return type includes the function name too.

commit 74ea4be48e1247b8f7c50fd3578c468f2ff1ae25
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:13 2017 +0100

    Introduce OP_VAR_MSYM_VALUE
    
    The previous patch left GDB with an inconsistency.  While with normal
    expression evaluation the "unknown return type" error shows the name
    of the function that misses debug info:
    
      (gdb) p getenv ("PATH")
      'getenv' has unknown return type; cast the call to its declared return type
       ^^^^^^
    
    which can by handy in more complicated expressions, "ptype" does not:
    
      (gdb) ptype getenv ("PATH")
      function has unknown return type; cast the call to its declared return type
      ^^^^^^^^
    
    This commit is a step toward fixing it.
    
    The problem is that while evaluating the expression above, we have no
    reference to the minimal symbol where we could extract the name from.
    This is because the resulting expression tree has no reference to the
    minsym at all.  During parsing, the type and address of the minsym are
    extracted and an UNOP_MEMVAL / UNOP_MEMVAL_TLS operator is generated
    (see write_exp_elt_msym).  With "set debug expression", here's what
    you see:
    
                0  OP_FUNCALL            Number of args: 0
                3    UNOP_MEMVAL           Type @0x565334a51930 (<text variable, no debug info>)
                6      OP_LONG               Type @0x565334a51c60 (__CORE_ADDR), value 140737345035648 (0x7ffff7751d80)
    
    The "print" case finds the function name, because
    call_function_by_hand looks up the function by address again.
    However, for "ptype", we don't reach that code, because obviously we
    don't really call the function.
    
    Unlike minsym references, references to variables with debug info have
    a pointer to the variable's symbol in the expression tree, with
    OP_VAR_VALUE:
    
      (gdb) ptype main()
      ...
                0  OP_FUNCALL            Number of args: 0
                3    OP_VAR_VALUE          Block @0x0, symbol @0x559bbbd9b358 (main(int, char**))
      ...
    
    so I don't see why do minsyms need to be different.  So to prepare for
    fixing the missing function name issue, this commit adds a new
    OP_VAR_MSYM_VALUE operator that mimics OP_VAR_VALUE, except that it's
    for minsyms instead of debug symbols.  For infcalls, we now get
    expressions like these:
    
                0  OP_FUNCALL            Number of args: 0
                3    OP_VAR_MSYM_VALUE     Objfile @0x1e41bf0, msymbol @0x7fffe599b000 (getenv)
    
    In the following patch, we'll make OP_FUNCALL extract the function
    name from the symbol stored in OP_VAR_VALUE/OP_VAR_MSYM_VALUE.
    
    OP_VAR_MSYM_VALUE will be used more in a later patch in the series
    too.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
    	* ax-gdb.c (gen_msym_var_ref): New function.
    	(gen_expr): Handle OP_VAR_MSYM_VALUE.
    	* eval.c (evaluate_var_msym_value): New function.
    	* eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
    	<OP_FUNCALL>: Extract function name from symbol/minsym and pass it
    	to call_function_by_hand.
    	* expprint.c (print_subexp_standard, dump_subexp_body_standard):
    	Handle OP_VAR_MSYM_VALUE.
    	(union exp_element) <msymbol>: New field.
    	* minsyms.h (struct type): Forward declare.
    	(find_minsym_type_and_address): Declare.
    	* parse.c (write_exp_elt_msym): New function.
    	(write_exp_msymbol): Delete, refactored as ...
    	(find_minsym_type_and_address): ... this new function.
    	(write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
    	(operator_length_standard, operator_check_standard): Handle
    	OP_VAR_MSYM_VALUE.
    	* std-operator.def (OP_VAR_MSYM_VALUE): New.

commit 7022349d5c86bae74b49225515f42d2e221bd368
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:13 2017 +0100

    Stop assuming no-debug-info functions return int
    
    The fact that GDB defaults to assuming that functions return int, when
    it has no debug info for the function has been a recurring source of
    user confusion.  Recently this came up on the errno pretty printer
    discussions.  Shortly after, it came up again on IRC, with someone
    wondering why does getenv() in GDB return a negative int:
    
      (gdb) p getenv("PATH")
      $1 = -6185
    
    This question (with s/getenv/random-other-C-runtime-function) is a FAQ
    on IRC.
    
    The reason for the above is:
    
     (gdb) p getenv
     $2 = {<text variable, no debug info>} 0x7ffff7751d80 <getenv>
     (gdb) ptype getenv
     type = int ()
    
    ... which means that GDB truncated the 64-bit pointer that is actually
    returned from getent to 32-bit, and then sign-extended it:
    
     (gdb) p /x -6185
     $6 = 0xffffe7d7
    
    The workaround is to cast the function to the right type, like:
    
     (gdb) p ((char *(*) (const char *)) getenv) ("PATH")
     $3 = 0x7fffffffe7d7 "/usr/local/bin:/"...
    
    IMO, we should do better than this.
    
    I see the "assume-int" issue the same way I see printing bogus values
    for optimized-out variables instead of "<optimized out>" -- I'd much
    rather that the debugger tells me "I don't know" and tells me how to
    fix it than showing me bogus misleading results, making me go around
    tilting at windmills.
    
    If GDB prints a signed integer when you're expecting a pointer or
    aggregate, you at least have some sense that something is off, but
    consider the case of the function actually returning a 64-bit integer.
    For example, compile this without debug info:
    
     unsigned long long
     function ()
     {
       return 0x7fffffffffffffff;
     }
    
    Currently, with pristine GDB, you get:
    
     (gdb) p function ()
     $1 = -1                      # incorrect
     (gdb) p /x function ()
     $2 = 0xffffffff              # incorrect
    
    maybe after spending a few hours debugging you suspect something is
    wrong with that -1, and do:
    
     (gdb) ptype function
     type = int ()
    
    and maybe, just maybe, you realize that the function actually returns
    unsigned long long.  And you try to fix it with:
    
    (gdb) p /x (unsigned long long) function ()
     $3 = 0xffffffffffffffff      # incorrect
    
    ... which still produces the wrong result, because GDB simply applied
    int to unsigned long long conversion.  Meaning, it sign-extended the
    integer that it extracted from the return of the function, to 64-bits.
    
    and then maybe, after asking around on IRC, you realize you have to
    cast the function to a pointer of the right type, and call that.  It
    won't be easy, but after a few missteps, you'll get to it:
    
    .....  (gdb) p /x ((unsigned long long(*) ()) function) ()
     $666 = 0x7fffffffffffffff             # finally! :-)
    
    
    So to improve on the user experience, this patch does the following
    (interrelated) things:
    
     - makes no-debug-info functions no longer default to "int" as return
       type.  Instead, they're left with NULL/"<unknown return type>"
       return type.
    
        (gdb) ptype getenv
        type = <unknown return type> ()
    
     - makes calling a function with unknown return type an error.
    
        (gdb) p getenv ("PATH")
        'getenv' has unknown return type; cast the call to its declared return type
    
     - and then to make it easier to call the function, makes it possible
       to _only_ cast the return of the function to the right type,
       instead of having to cast the function to a function pointer:
    
        (gdb) p (char *) getenv ("PATH")                      # now Just Works
        $3 = 0x7fffffffe7d7 "/usr/local/bin:/"...
    
        (gdb) p ((char *(*) (const char *)) getenv) ("PATH")  # continues working
        $4 = 0x7fffffffe7d7 "/usr/local/bin:/"...
    
       I.e., it makes GDB default the function's return type to the type
       of the cast, and the function's parameters to the type of the
       arguments passed down.
    
    After this patch, here's what you'll get for the "unsigned long long"
    example above:
    
     (gdb) p function ()
     'function' has unknown return type; cast the call to its declared return type
     (gdb) p /x (unsigned long long) function ()
     $4 = 0x7fffffffffffffff     # correct!
    
    Note that while with "print" GDB shows the name of the function that
    has the problem:
    
      (gdb) p getenv ("PATH")
      'getenv' has unknown return type; cast the call to its declared return type
    
    which can by handy in more complicated expressions, "ptype" does not:
    
      (gdb) ptype getenv ("PATH")
      function has unknown return type; cast the call to its declared return type
    
    This will be fixed in the next patch.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
    	TYPE_GNU_IFUNC specially here.  Throw error if return type is
    	unknown.
    	* ada-typeprint.c (print_func_type): Handle functions with unknown
    	return type.
    	* c-typeprint.c (c_type_print_base): Handle functions and methods
    	with unknown return type.
    	* compile/compile-c-symbols.c (convert_symbol_bmsym)
    	<mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
    	* compile/compile-c-types.c: Include "objfiles.h".
    	(convert_func): For functions with unknown return type, warn and
    	default to int.
    	* compile/compile-object-run.c (compile_object_run): Adjust call
    	to call_function_by_hand_dummy.
    	* elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
    	call_function_by_hand.
    	* eval.c (evaluate_subexp_standard): Adjust calls to
    	call_function_by_hand.  Handle functions and methods with unknown
    	return type.  Pass expect_type to call_function_by_hand.
    	* f-typeprint.c (f_type_print_base): Handle functions with unknown
    	return type.
    	* gcore.c (call_target_sbrk): Adjust call to
    	call_function_by_hand.
    	* gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
    	return type instead of int.  Make nodebug_text_gnu_ifunc_symbol be
    	an integer address type instead of nodebug.
    	* guile/scm-value.c (gdbscm_value_call): Adjust call to
    	call_function_by_hand.
    	* infcall.c (error_call_unknown_return_type): New function.
    	(call_function_by_hand): New "default_return_type" parameter.
    	Pass it down.
    	(call_function_by_hand_dummy): New "default_return_type"
    	parameter.  Use it instead of defaulting to int.  If there's no
    	default and the return type is unknown, throw an error.  If
    	there's a default return type, and the called function has no
    	debug info, then assume the function is prototyped.
    	* infcall.h (call_function_by_hand, call_function_by_hand_dummy):
    	New "default_return_type" parameter.
    	(error_call_unknown_return_type): New declaration.
    	* linux-fork.c (call_lseek): Cast return type of lseek.
    	(inferior_call_waitpid, checkpoint_command): Adjust calls to
    	call_function_by_hand.
    	* linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
    	calls to call_function_by_hand.
    	* m2-typeprint.c (m2_procedure): Handle functions with unknown
    	return type.
    	* objc-lang.c (lookup_objc_class, lookup_child_selector)
    	(value_nsstring, print_object_command): Adjust calls to
    	call_function_by_hand.
    	* p-typeprint.c (pascal_type_print_varspec_prefix): Handle
    	functions with unknown return type.
    	(pascal_type_print_func_varspec_suffix): New function.
    	(pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
    	TYPE_CODE_METHOD>: Use it.
    	* python/py-value.c (valpy_call): Adjust call to
    	call_function_by_hand.
    	* rust-lang.c (rust_evaluate_funcall): Adjust call to
    	call_function_by_hand.
    	* valarith.c (value_x_binop, value_x_unop): Adjust calls to
    	call_function_by_hand.
    	* valops.c (value_allocate_space_in_inferior): Adjust call to
    	call_function_by_hand.
    	* typeprint.c (type_print_unknown_return_type): New function.
    	* typeprint.h (type_print_unknown_return_type): New declaration.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/break-main-file-remove-fail.exp (test_remove_bp): Cast
    	return type of munmap in infcall.
    	* gdb.base/break-probes.exp: Cast return type of foo in infcall.
    	* gdb.base/checkpoint.exp: Simplify using for loop.  Cast return
    	type of ftell in infcall.
    	* gdb.base/dprintf-detach.exp (dprintf_detach_test): Cast return
    	type of getpid in infcall.
    	* gdb.base/infcall-exec.exp: Cast return type of execlp in
    	infcall.
    	* gdb.base/info-os.exp: Cast return type of getpid in infcall.
    	Bail on failure to extract the pid.
    	* gdb.base/nodebug.c: #include <stdint.h>.
    	(multf, multf_noproto, mult, mult_noproto, add8, add8_noproto):
    	New functions.
    	* gdb.base/nodebug.exp (test_call_promotion): New procedure.
    	Change expected output of print/whatis/ptype with functions with
    	no debug info.  Test all supported languages.  Call
    	test_call_promotion.
    	* gdb.compile/compile.exp: Adjust expected output to expect
    	warning.
    	* gdb.threads/siginfo-threads.exp: Likewise.

commit 54990598c4c74b6af113baf801064d3b1837973f
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 20:21:13 2017 +0100

    Fix calling prototyped functions via function pointers
    
    Calling a prototyped function via a function pointer with the right
    prototype doesn't work correctly, if the called function requires
    argument coercion...  Like, e.g., with:
    
      float mult (float f1, float f2) { return f1 * f2; }
    
      (gdb) p mult (2, 3.5)
      $1 = 7
      (gdb) p ((float (*) (float, float)) mult) (2, 3.5)
      $2 = 0
    
    both calls should have returned the same, of course.  The problem is
    that GDB misses marking the type of the function pointer target as
    prototyped...
    
    Without the fix, the new test fails like this:
    
     (gdb) p ((int (*) (float, float)) t_float_values2)(3.14159,float_val2)
     $30 = 0
     (gdb) FAIL: gdb.base/callfuncs.exp: p ((int (*) (float, float)) t_float_values2)(3.14159,float_val2)
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdbtypes.c (lookup_function_type_with_arguments): Mark function
    	types with more than one parameter as prototyped.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/callfuncs.exp (do_function_calls): New parameter
    	"prototypes".  Test calling float functions via prototyped and
    	unprototyped function pointers.
    	(perform_all_tests): New parameter "prototypes".  Pass it down.
    	(top level): Pass down "prototypes" parameter to
    	perform_all_tests.

commit 34d16ea2a144cdac8a89050d9aab723fb675cb45
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 21:19:17 2017 +0200

    gdb.base/commands.exp: Test loop_break and loop_continue in nested loops
    
    This patch improves the loop_break and loop_continue tests to verify
    that they work as expected when multiple loops are nested (they affect
    the inner loop).
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/commands.exp (loop_break_test, loop_continue_test):
    	Test with nested loops.

commit 9a24775b97646827396073d0d7e510b9694331ab
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 18:23:22 2017 +0100

    Introduce gdb_disassembly_flags
    
    For some reason I ended up staring at some of the "int flags" in
    btrace-related code, and I got confused because I had no clue what the
    flags where supposed to indicate.
    
    Fix that by using enum_flags, so that:
      #1 - it's clear from the type what the flags are about, and
      #2 - the compiler can catch mismatching mistakes
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (print_disassembly, disassemble_current_function)
    	(disassemble_command): Use gdb_disassembly_flags instead of bare
    	int.
    	* disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
    	(dump_insns, do_mixed_source_and_assembly_deprecated)
    	(do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
    	Use gdb_disassembly_flags instead of bare int.
    	* disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
    	(DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
    	(DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
    	(DISASSEMBLY_SPECULATIVE): No longer macros.  Instead they're...
    	(enum gdb_disassembly_flag): ... values of this new enumeration.
    	(gdb_disassembly_flags): Define.
    	(gdb_disassembly)
    	(gdb_pretty_print_disassembler::pretty_print_insn): Use it.
    	* mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
    	gdb_disassembly_flags instead of bare int.
    	* record-btrace.c (btrace_insn_history)
    	(record_btrace_insn_history, record_btrace_insn_history_range)
    	(record_btrace_insn_history_from): Use gdb_disassembly_flags
    	instead of bare int.
    	* record.c (get_insn_history_modifiers, cmd_record_insn_history):
    	Use gdb_disassembly_flags instead of bare int.
    	* target-debug.h (target_debug_print_gdb_disassembly_flags):
    	Define.
    	* target-delegates.c: Regenerate.
    	* target.c (target_insn_history, target_insn_history_from)
    	(target_insn_history_range): Use gdb_disassembly_flags instead of
    	bare int.
    	* target.h: Include "disasm.h".
    	(struct target_ops) <to_insn_history, to_insn_history_from,
    	to_insn_history_range>: Use gdb_disassembly_flags instead of bare
    	int.
    	(target_insn_history, target_insn_history_from)
    	(target_insn_history_range): Use gdb_disassembly_flags instead of
    	bare int.

commit 9521ecda6835b338d61b1b06e1a91706711b1d0b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 19:15:59 2017 +0200

    Add tests for loop_break and loop_continue commands
    
    I grepped the testsuite for loop_break and loop_continue and didn't find
    anything, so I wrote some simple tests for those.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/commands.exp: Call the new procedures.
    	(loop_break_test, loop_continue_test): New procedures.

commit 80a65e9b8fbc93d4a7548ac17b8094ced23f66a7
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 19:13:08 2017 +0200

    Error out immediatly when using if command without args in command list
    
    When using "if" (or while) without args directly on gdb's command line,
    you get this:
    
      (gdb) if
      if/while commands require arguments
    
    When doing the same when entering a command list, you only get an error
    when the command is executed, when parse_exp_in_context_1 fails to
    evaluate the expression.
    
      (gdb) define foo
      Type commands for definition of "foo".
      End with a line saying just "end".
      >if
       >end
      >end
      (gdb) foo
      Argument required (expression to compute).
    
    I think it would make more sense to error out when inputting the command
    list directly:
    
      (gdb) define foo
      Type commands for definition of "foo".
      End with a line saying just "end".
      >if
      if/while commands require arguments.
    
    The only required change is to check whether args is an empty string in
    build_command_line.
    
    gdb/ChangeLog:
    
    	* cli/cli-script.c (build_command_line): For if/while commands,
    	check whether args is empty.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/commands.exp: Call new procedure.
    	(define_if_without_arg_test): New procedure.

commit 6b66338c70422d670637623cea8dc3b62e05e7de
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 19:09:12 2017 +0200

    Move command lines types/declarations to cli-script.h
    
    I think it would make more sense if the types and function declarations
    related to command lines were in cli-script.h rather than defs.h, since
    the related function definitions are in cli-script.c.
    
    I had to add a few includes here and there.  I also had to rename the
    "lines" parameter of command_lines_deleter::operator(), because ncurses
    has a "#define lines ..." that was interfering when cli-script.h is
    included by some TUI source files that also include ncurses header files.
    
    gdb/ChangeLog:
    
    	* cli/cli-script.h (enum misc_command_type): Move from defs.h.
    	(enum command_control_type): Likewise.
    	(struct command_line): Likewise.
    	(free_command_lines): Likewise.
    	(struct command_lines_deleter): Likewise.
    	(command_line_up): Likewise.
    	(read_command_lines): Likewise.
    	(read_command_lines_1): Likewise.
    	* defs.h (enum misc_command_type): Move to cli/cli-script.h.
    	(enum command_control_type): Likewise.
    	(struct command_line): Likewise.
    	(free_command_lines): Likewise.
    	(struct command_lines_deleter): Likewise.
    	(command_line_up): Likewise.
    	(read_command_lines): Likewise.
    	(read_command_lines_1): Likewise.
    	* breakpoint.h: Include cli/cli-script.h.
    	* extension-priv.h: Likewise.
    	* gdbcmd.h: Likewise.

commit 50a421ac3ad82886afb0916b112ddeac4f9f73dc
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 19:02:56 2017 +0200

    gdbserver Makefile: don't delete intermediary files
    
    If you "make" from scratch in gdbserver/, you'll notice that make
    deletes the files it considers as intermediary at the end:
    
      $ make clean && make
      ...
      rm i386-mmx-linux-generated.c x32-avx-avx512-linux-generated.c ...
    
    Then, if you type make again, make will rebuild these files and rebuild
    gdbserver.  To avoid this, we can add the .SECONDARY special target.  If
    it has no pre-requisites, all intermediary files will be kept.
    
    gdb/gdbserver/ChangeLog:
    
    	* Makefile.in (.SECONDARY): Define target.

commit 51abb421302bdd86946827727aebc878b5c756e3
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 17:10:13 2017 +0100

    Kill init_sal
    
    Instead, make symtab_and_line initialize its members itself.  Many
    symtab_and_line declarations are moved to where the object is
    initialized at the same time both for clarity and to avoid double
    initialization.  A few functions, like e.g., find_frame_sal are
    adjusted to return the sal using normal function return instead of an
    output parameter likewise to avoid having to default-construct a sal
    and then immediately have the object overwritten.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (is_known_support_routine): Move sal declaration to
    	where it is initialized.
    	* breakpoint.c (create_internal_breakpoint, init_catchpoint)
    	(parse_breakpoint_sals, decode_static_tracepoint_spec)
    	(clear_command, update_static_tracepoint): Remove init_sal
    	references.  Move declarations closer to initializations.
    	* cli/cli-cmds.c (list_command): Move sal declarations closer to
    	initializations.
    	* elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
    	references.  Move sal declarations closer to initializations.
    	* frame.c (find_frame_sal): Return a symtab_and_line via function
    	return instead of output parameter.  Remove init_sal references.
    	* frame.h (find_frame_sal): Return a symtab_and_line via function
    	return instead of output parameter.
    	* guile/scm-frame.c (gdbscm_frame_sal): Adjust.
    	* guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
    	instead of memset.
    	(gdbscm_find_pc_line): Remove init_sal reference.
    	* infcall.c (call_function_by_hand_dummy): Remove init_sal
    	references.  Move declarations closer to initializations.
    	* infcmd.c (set_step_frame): Update.  Move declarations closer to
    	initializations.
    	(finish_backward): Remove init_sal references.  Move declarations
    	closer to initializations.
    	* infrun.c (process_event_stop_test, handle_step_into_function)
    	(insert_hp_step_resume_breakpoint_at_frame)
    	(insert_step_resume_breakpoint_at_caller): Likewise.
    	* linespec.c (create_sals_line_offset, decode_digits_ordinary)
    	(symbol_to_sal): Likewise.
    	* probe.c (parse_probes_in_pspace): Remove init_sal reference.
    	* python/py-frame.c (frapy_find_sal): Move sal declaration closer
    	to its initialization.
    	* reverse.c (save_bookmark_command): Use new/delete.  Remove
    	init_sal references.  Move declarations closer to initializations.
    	* source.c (get_current_source_symtab_and_line): Remove brace
    	initialization.
    	(set_current_source_symtab_and_line): Now takes the sal by const
    	reference.  Remove brace initialization.
    	(line_info): Remove init_sal reference.
    	* source.h (set_current_source_symtab_and_line): Now takes a
    	symtab_and_line via const reference.
    	* stack.c (set_current_sal_from_frame): Adjust.
    	(print_frame_info): Adjust.
    	(get_last_displayed_sal): Return the sal via function return
    	instead of via output parameter.  Simplify.
    	(frame_info): Adjust.
    	* stack.h (get_last_displayed_sal): Return the sal via function
    	return instead of via output parameter.
    	* symtab.c (init_sal): Delete.
    	(find_pc_sect_line): Remove init_sal references.  Move
    	declarations closer to initializations.
    	(find_function_start_sal): Remove init_sal references.  Move
    	declarations closer to initializations.
    	* symtab.h (struct symtab_and_line): In-class initialize all
    	fields.
    	* tracepoint.c (set_traceframe_context)
    	(print_one_static_tracepoint_marker): Remove init_sal references.
    	Move declarations closer to initializations.
    	* tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
    	* tui/tui-stack.c (tui_show_frame_info): Adjust.  Move
    	declarations closer to initializations.
    	* tui/tui-winsource.c (tui_update_source_window_as_is): Remove
    	init_sal references.  Adjust.

commit 6c5b2ebeacc2538cf342cfd13c4c98ff018e6c9a
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 17:10:13 2017 +0100

    struct symtabs_and_lines -> std::vector<symtab_and_line>
    
    This replaces "struct symtabs_and_lines" with
    std::vector<symtab_and_line> in most cases.  This removes a number of
    cleanups.
    
    In some cases, the sals objects do not own the sals they point at.
    Instead they point at some sal that lives on the stack.  Typically
    something like this:
    
      struct symtab_and_line sal;
      struct symtabs_and_lines sals;
    
      // fill in sal
    
      sals.nelts = 1;
      sals.sals = &sal;
    
      // use sals
    
    Instead of switching those cases to std::vector too, such usages are
    replaced by gdb::array_view<symtab_and_line> instead.  This avoids
    introducing heap allocations.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* ax-gdb.c (agent_command_1): Use range-for.
    	* break-catch-throw.c (re_set_exception_catchpoint): Update.
    	* breakpoint.c: Include "common/array-view.h".
    	(init_breakpoint_sal, create_breakpoint_sal): Change sals
    	parameter from struct symtabs_and_lines to
    	array_view<symtab_and_line>.  Adjust.  Use range-for.  Update.
    	(breakpoint_sals_to_pc): Change sals parameter from struct
    	symtabs_and_lines to std::vector reference.
    	(check_fast_tracepoint_sals): Change sals parameter from struct
    	symtabs_and_lines to std::array_view.  Use range-for.
    	(decode_static_tracepoint_spec): Return a std::vector instead of
    	symtabs_and_lines.  Update.
    	(create_breakpoint): Update.
    	(break_range_command, until_break_command, clear_command): Update.
    	(base_breakpoint_decode_location, bkpt_decode_location)
    	(bkpt_probe_create_sals_from_location)
    	(bkpt_probe_decode_location, tracepoint_decode_location)
    	(tracepoint_probe_decode_location)
    	(strace_marker_create_sals_from_location): Return a std::vector
    	instead of symtabs_and_lines.
    	(strace_marker_create_breakpoints_sal): Update.
    	(strace_marker_decode_location): Return a std::vector instead of
    	symtabs_and_lines.  Update.
    	(update_breakpoint_locations): Change struct symtabs_and_lines
    	parameters to gdb::array_view.  Adjust.
    	(location_to_sals): Return a std::vector instead of
    	symtabs_and_lines.  Update.
    	(breakpoint_re_set_default): Use std::vector instead of struct
    	symtabs_and_lines.
    	(decode_location_default): Return a std::vector instead of
    	symtabs_and_lines.  Update.
    	* breakpoint.h: Include "common/array-view.h".
    	(struct breakpoint_ops) <decode_location>: Now returns a
    	std::vector instead of returning a symtabs_and_lines via output
    	parameter.
    	(update_breakpoint_locations): Change sals parameters to use
    	gdb::array_view.
    	* cli/cli-cmds.c (edit_command, list_command): Update to use
    	std::vector and gdb::array_view.
    	(ambiguous_line_spec): Adjust to use gdb::array_view and
    	range-for.
    	(compare_symtabs): Rename to ...
    	(cmp_symtabs): ... this.  Change parameters to symtab_and_line
    	const reference and adjust.
    	(filter_sals): Rewrite using std::vector and standard algorithms.
    	* elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
    	(jump_command): Update to use std::vector.
    	* linespec.c (struct linespec_state) <canonical_names>: Update
    	comment.
    	(add_sal_to_sals_basic): Delete.
    	(add_sal_to_sals, filter_results, convert_results_to_lsals)
    	(decode_line_2, create_sals_line_offset)
    	(convert_address_location_to_sals, convert_linespec_to_sals)
    	(convert_explicit_location_to_sals, parse_linespec)
    	(event_location_to_sals, decode_line_full, decode_line_1)
    	(decode_line_with_current_source)
    	(decode_line_with_last_displayed, decode_objc)
    	(decode_digits_list_mode, decode_digits_ordinary, minsym_found)
    	(linespec_result::~linespec_result): Adjust to use std::vector
    	instead of symtabs_and_lines.
    	* linespec.h (linespec_sals::sals): Now a std::vector.
    	(struct linespec_result): Use std::vector, bool, and in-class
    	initialization.
    	(decode_line_1, decode_line_with_current_source)
    	(decode_line_with_last_displayed): Return std::vector.
    	* macrocmd.c (info_macros_command): Use std::vector.
    	* mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
    	* probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
    	std::vector.
    	* probe.h (parse_probes): Return a std::vector.
    	* python/python.c (gdbpy_decode_line): Use std::vector and
    	gdb::array_view.
    	* source.c (select_source_symtab, line_info): Use std::vector.
    	* stack.c (func_command): Use std::vector.
    	* symtab.h (struct symtabs_and_lines): Delete.
    	* tracepoint.c (tfind_line_command, scope_info): Use std::vector.

commit 7c44b49cb63662b76c6301fdc8e022d7aca655bf
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 17:10:12 2017 +0100

    Introduce gdb::array_view
    
    An array_view is an abstraction that provides a non-owning view over a
    sequence of contiguous objects.
    
    A way to put it is that array_view is to std::vector (and std::array
    and built-in arrays with rank==1) like std::string_view is to
    std::string.
    
    The main intent of array_view is to use it as function input parameter
    type, making it possible to pass in any sequence of contiguous
    objects, irrespective of whether the objects live on the stack or heap
    and what actual container owns them.  Implicit construction from the
    element type is supported too, making it easy to call functions that
    expect an array of elements when you only have one element (usually on
    the stack).  For example:
    
     struct A { .... };
     void function (gdb::array_view<A> as);
    
     std::vector<A> std_vec = ...;
     std::array<A, N> std_array = ...;
     A array[] = {...};
     A elem;
    
     function (std_vec);
     function (std_array);
     function (array);
     function (elem);
    
    Views can be either mutable or const.  A const view is simply created
    by specifying a const T as array_view template parameter, in which
    case operator[] of non-const array_view objects ends up returning
    const references.  (Making the array_view itself const is analogous to
    making a pointer itself be const.  I.e., disables re-seating the
    view/pointer.)  Normally functions will pass around array_views by
    value.
    
    Uses of gdb::array_view (other than the ones in the unit tests) will
    be added in a follow up patch.
    
    gdb/ChangeLog
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
    	unittests/array-view-selftests.c.
    	(SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
    	* common/array-view.h: New file.
    	* unittests/array-view-selftests.c: New file.

commit e439fa140afdaedb28a97acaa2b0432b884d8a91
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 16:49:29 2017 +0100

    Clarify "list" output when specified lines are ambiguous
    
    Currently, with "list LINESPEC1,LINESPEC2", if one of the linespecs is
    ambiguous, i.e., if it expands to multiple locations, you get this
    seemingly odd output:
    
     (gdb) list foo,bar
     file: "file0.c", line number: 26
     file: "file1.c", line number: 29
    
    Since "foo" above expands to multiple locations, the specified range
    is indeterminate, and GDB is trying to be helpful by showing you what
    was ambiguous.  It looks confusing to me, though.  I think it'd be
    much more user friendly if GDB actually told you that, like this:
    
     (gdb) list foo,bar
     Specified first line 'foo' is ambiguous:
     file: "file0.c", line number: 26
     file: "file1.c", line number: 29
    
     (gdb) list bar,foo
     Specified last line 'foo' is ambiguous:
     file: "file0.c", line number: 26
     file: "file1.c", line number: 29
    
    Note, I'm using "first" and "last" in the output because that's what
    the manual uses:
    
     ~~~
     list first,last
    
         Print lines from first to last. [...]
     ~~~
    
    Tested on x86-64 GNU/Linux.
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (edit_command): Pass message to
    	ambiguous_line_spec.
    	(list_command): Pass message to ambiguous_line_spec.  Say
    	"first"/"last" instead of "start" and "end" to be consistent with
    	the manual.
    	(ambiguous_line_spec): Add 'format' and vararg parameters.  Use
    	them to print formatted message.
    
    gdb/testsuite/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/list-ambiguous.exp: New file.
    	* gdb.base/list-ambiguous0.c: New file.
    	* gdb.base/list-ambiguous1.c: New file.
    	* gdb.base/list.exp (test_list_range): Adjust expected output.

commit 7525b645dfaa302091591d0f87d9682ce988ed13
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Sep 4 16:01:17 2017 +0100

    Fix build breakage when libipt is available
    
    Fix build regression introduced by 0860c437cbe4 ("btrace: Store
    btrace_insn in an std::vector"):
    
      src/gdb/btrace.c: In function â??void ftrace_add_pt(btrace_thread_info*, pt_insn_decoder*, int*, std::vector<unsigned int>&)â??:
      src/gdb/btrace.c:1329:38: error: invalid initialization of reference of type â??const btrace_insn&â?? from expression of type â??btrace_insn*â??
          ftrace_update_insns (bfun, &btinsn);
    					^
      src/gdb/btrace.c:648:1: note: in passing argument 2 of â??void ftrace_update_insns(btrace_function*, const btrace_insn&)â??
       ftrace_update_insns (struct btrace_function *bfun, const btrace_insn &insn)
       ^
    
    gdb/ChangeLog:
    2017-09-04  Pedro Alves  <palves@redhat.com>
    
    	* btrace.c (ftrace_add_pt): Pass btrace_insn to
    	ftrace_update_insns by reference instead of pointer.

commit 6c869779dad0cf028bd787e6ebbc0780ee4afe13
Author: Anthony Green <green@moxielogic.com>
Date:   Mon Sep 4 10:00:37 2017 -0400

    Fix simulator

commit badc00202024619e1c868b8cf70fe6351fc028c3
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Sep 4 11:33:56 2017 +0100

    Let i386_target_description return tdesc_i386_mmx
    
    This patch remove the usage of tdesc_i386_mmx in i386-go32-tdep.c, and use
    i386_target_description to get it instead.
    
    gdb:
    
    2017-09-04  Yao Qi  <yao.qi@linaro.org>
    
    	* i386-go32-tdep.c: Include x86-xstate.h.
    	(i386_go32_init_abi): Call i386_target_description.
    	* i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
    	if xcr0 is X86_XSTATE_X87_MASK.
    	* i386-tdep.h (tdesc_i386): Remove the declaration.
    	(tdesc_i386_mmx): Likewise.

commit d78bdb54ac94e1c38dc4b8f0d50b5fd202890887
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Sep 4 11:33:56 2017 +0100

    Return X86_XSTATE_SSE_MASK instead of 0 in i386fbsd_core_read_xcr0
    
    i386fbsd_core_read_xcr0 reads the value of xcr0 from the corefile.  If
    it fails, returns 0.  This makes its caller {i386,amd64}_target_description
    has to handle this special value.  IMO, i386fbsd_core_read_xcr0 should
    return the default xcr0 in case of error.
    
    gdb:
    
    2017-09-04  Yao Qi  <yao.qi@linaro.org>
    
    	* i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
    	X86_XSTATE_SSE_MASK instead of 0.

commit ca1fa5eef2912262a0a33875e9a23f2e79a72328
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Sep 4 11:33:56 2017 +0100

    Use i386_target_description to get tdesc_i386
    
    GDB can call function i386_target_description to get the right target
    description rather than tdesc_i386
    
    gdb:
    
    2017-09-04  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-fbsd-nat.c (amd64fbsd_read_description): Call
    	i386_target_description.
    	* i386-fbsd-nat.c (i386fbsd_read_description): Call
    	i386_target_description.
    	* i386-tdep.c (i386_gdbarch_init): Likewise.

commit 2434b0199ddcd9419c55742552953b0a79d00ebc
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Sep 4 11:33:56 2017 +0100

    Use amd64_target_description to get tdesc_amd64
    
    This patch changes amd64-*-tdep.c files to use function
    amd64_target_description to get the right target description rather than
    use the variable tdesd_amd64.
    
    gdb:
    
    2017-09-04  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-darwin-tdep.c: Include "x86-xstate.h".
    	(x86_darwin_init_abi_64): Call amd64_target_description.
    	* amd64-dicos-tdep.c: Likewise.
    	* amd64-fbsd-nat.c: Likewise.
    	* amd64-fbsd-tdep.c: Likewise.
    	* amd64-nbsd-tdep.c: Likewise.
    	* amd64-obsd-tdep.c: Likewise.
    	* amd64-sol2-tdep.c: Likewise.
    	* amd64-windows-tdep.c: Likewise.
    	* amd64-tdep.h (tdesc_amd64): Remove the declaration.

commit 0860c437cbe4efd8752531d0464007f448fc8274
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Sep 4 10:46:36 2017 +0200

    btrace: Store btrace_insn in an std::vector
    
    Because it contains a non-POD type field (flags), the type btrace_insn
    should be new'ed/delete'd.  Replace the VEC (btrace_insn_s) in
    btrace_function with an std::vector.
    
    gdb/ChangeLog:
    
    	* btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
    	(btrace_function) <insn>: Change type to use std::vector.
    	* btrace.c (ftrace_debug, ftrace_call_num_insn,
    	ftrace_find_call, ftrace_new_gap, ftrace_update_function,
    	ftrace_update_insns, ftrace_compute_global_level_offset,
    	btrace_stitch_bts, btrace_clear, btrace_insn_get,
    	btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
    	change to std::vector.
    	(ftrace_update_insns): Adjust to change to std::vector, change
    	type of INSN parameter.
    	(btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
    	* record-btrace.c (btrace_call_history_insn_range,
    	btrace_compute_src_line_range,
    	record_btrace_frame_prev_register): Adjust to change to
    	std::vector.
    	* python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
    	to change to std::vector.

commit a826403eb6f0ad2fb8c88b45ea3cf5ba39cdaa75
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Sep 4 00:00:29 2017 +0000

    Automatic date update in version.in

commit 0638b7f90293ac01233dc6406e4c9d5da0ed9e24
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 14 00:18:06 2017 -0600

    Use std::string in reopen_exec_file
    
    This changes reopen_exec_file to use a std::string, removing a
    cleanup.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* corefile.c (reopen_exec_file): Use std::string.

commit 8f84fb0ee87e8f149523e13815c58e1b664d184f
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Aug 14 00:03:02 2017 -0600

    Use std::string and unique_xmalloc_ptr in compile/ code
    
    Change various things in the compile/ code to use std::string or
    unique_xmalloc_ptr as appropriate.  This allows the removal of some
    cleanups.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile.c (compile_register_name_mangled): Return
    	std::string.
    	* compile/compile-loc2c.c (pushf_register_address): Update.
    	(pushf_register): Update.
    	* compile/compile-c-types.c (convert_array): Update.
    	* compile/compile-c-symbols.c (generate_vla_size): Update.
    	(error_symbol_once): Use a gdb::unique_xmalloc_ptr.
    	(symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
    	(convert_one_symbol): Update.
    	(generate_c_for_for_one_variable): Update.
    	* compile/compile-c-support.c (c_get_range_decl_name): Return a
    	std::string.
    	(generate_register_struct): Update.
    	* compile/compile-internal.h (c_get_range_decl_name): Return a
    	std::string.
    	(compile_register_name_mangled): Return std::string.

commit 18e9961f02b326923553f34682f4dcca0f25702e
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 23:47:01 2017 -0600

    Return std::string from perror_string
    
    Change perror_string to return a std::string, removing a cleanup in
    the process.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (perror_string): Return a std::string.
    	(throw_perror_with_name, perror_warning_with_name): Update.

commit 453437863c82afc8ed5bfcb937a2e297957fc212
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 23:38:09 2017 -0600

    Use std::string and unique_xmalloc_ptr in demangle_command
    
    Change demangle_command to use std::string and unique_xmalloc_ptr,
    removing some cleanups.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* demangle.c (demangle_command): Use std::string,
    	unique_xmalloc_ptr.

commit b57af50345945f32e6615391ac62a4f589c0fada
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 14:45:17 2017 -0600

    Use std::string in do_set_command
    
    Change do_set_command to use std::string, removing a cleanup and some
    manual resizing code.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-setshow.c (do_set_command): Use std::string.

commit 6eecf35f97e1d37e49e385ba599797dd1c8afd1f
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 14:34:59 2017 -0600

    Use unique_xmalloc_ptr in cd_command
    
    Change cd_command to use unique_xmalloc_ptr, removing a cleanup.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.

commit 56496dd4d6519c26bb375a78588bf56b28b13512
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 11:04:37 2017 -0600

    Use std::string in mi_cmd_interpreter_exec
    
    Change mi_cmd_interpreter_exec to use std::string, removing a cleanup.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.

commit e91a1fa7d49482565b5f96a2ca9e51ce6327c4ae
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Aug 13 10:57:05 2017 -0600

    Use unique_xmalloc_ptr in env_execute_cli_command
    
    Change env_execute_cli_command to use unique_xmalloc_ptr, removing a
    cleanup.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* mi/mi-cmd-env.c (env_execute_cli_command): Use
    	gdb::unique_xmalloc_ptr.

commit 7ffd83d70f2792a8a538e8599959a6ed7f5b751d
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 11 14:48:17 2017 -0600

    Use std::string thread.c
    
    This changes a few spots in thread.c to use std::string, removing some
    cleanups.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* thread.c (print_thread_info_1): Use string_printf.
    	(thread_apply_command, thread_apply_all_command): Use
    	std::string.

commit 1ccbe9985f607b291bb6fc920beda60225f1bf83
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 5 16:23:18 2017 -0600

    Return std::string from memory_error_message
    
    This changes memory_error_message to return a std::string and fixes up
    the callers.  This removes some cleanups.
    
    ChangeLog
    2017-09-03  Tom Tromey  <tom@tromey.com>
    
    	* valprint.c (val_print_string): Update.
    	* gdbcore.h (memory_error_message): Return std::string.
    	* corefile.c (memory_error_message): Return std::string.
    	(memory_error): Update.
    	* breakpoint.c (insert_bp_location): Update.

commit de64ecc14f1bfd13a073c057413813289943d26a
Merge: f4300d1 0e30d99
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Sep 3 11:20:05 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit f4300d1910ae651fe687bdf134ffac7b397d2dff
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Sep 3 11:19:55 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit 0e30d991804de9dfd368653d6a88bf3766a27ffc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Sep 3 10:18:24 2017 -0700

    x86-64: Set tlsdesc_plt if GOT_TLS_GDESC_P is true
    
    We need to set tlsdesc_plt for x86-64 if GOT_TLS_GDESC_P is true when
    allocating dynamic relocations so that _bfd_x86_elf_size_dynamic_sections
    will generate TLSDESC_PLT and TLSDESC_GOT in x86-64 output.
    
    bfd/
    
    	PR ld/22071
    	* elfxx-x86.c (elf_x86_allocate_dynrelocs): Set tlsdesc_plt
    	for x86-64 if GOT_TLS_GDESC_P is true.
    
    ld/
    
    	PR ld/22071
    	* testsuite/ld-x86-64/pr22071.d: New file.
    	* testsuite/ld-x86-64/pr22071.s: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run pr22071.

commit 1cf58434bf9d90ea0669f97514c63dc1ccf38f7c
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Sep 3 22:04:09 2017 +0930

    PR22067, x86 check_relocs invalid read
    
    	PR 22067
    	* elfxx-x86.h (elf_x86_hash_table): Check is_elf_hash_table first.

commit d633abb905e247555d07be068179c199bf0f20b7
Merge: ed53c01 23fdd69
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Sep 3 04:41:19 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 23fdd69e42180578b3e15ba8f053fadde965bfe8
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Sep 3 10:23:31 2017 +0200

    Make target_waitstatus_to_string return an std::string
    
    A quite straightforward change.  It does "fix" leaks in record-btrace.c,
    although since this is only used in debug printing code, it has no real
    world impact.
    
    gdb/ChangeLog:
    
    	* target/waitstatus.h (target_waitstatus_to_string): Change
    	return type to std::string.
    	* target/waitstatus.c (target_waitstatus_to_string): Return
    	std::string.
    	* target.h (target_waitstatus_to_string): Remove declaration.
    	* infrun.c (resume, clear_proceed_status_thread,
    	print_target_wait_results, do_target_wait, save_waitstatus,
    	stop_all_threads): Adjust.
    	* record-btrace.c (record_btrace_wait): Adjust.
    	* target-debug.h
    	(target_debug_print_struct_target_waitstatus_p): Adjust.
    
    gdb/gdbserver/ChangeLog:
    
    	* linux-low.c (linux_wait_1): Adjust.
    	* server.c (queue_stop_reply_callback): Adjust.

commit f04bdfa7b261402bfa9dbdde58b2feb14becd8a3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 22:14:58 2017 -0700

    Initialize tls_get_addr for x86-64 in one place
    
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Initialize
    	tls_get_addr for x86-64 in one place.

commit d47a80260cd52e800ffea7eaea366c34a31e663c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 22:10:39 2017 -0700

    Add missing ChangeLog entries

commit 2ac3a7f5ce10dfdbda70a7d16414ba780677fe38
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 22:04:27 2017 -0700

    Add elf64-x86-64.lo together with elfxx-x86.lo for 64-bit BFD
    
    Since elfxx-x86.lo needs elf64-x86-64.lo with 64-bit BFD now, add
    elf64-x86-64.lo together with elfxx-x86.lo to bfd_backends for 64-bit
    BFD.
    
    	* configure.ac (bfd_backends): Add elf64-x86-64.lo together
    	with elfxx-x86.lo for 64-bit BFD.
    	* configure: Regenerated.

commit aed02419fb32cdf3153e81aa3474ef41248f34b0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Sep 3 00:00:30 2017 +0000

    Automatic date update in version.in

commit 5e2ac45d561dffec63af4c83a545b46db032c70c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 07:37:05 2017 -0700

    x86: Add _bfd_x86_elf_size_dynamic_sections
    
    elf_i386_size_dynamic_sections and elf_x86_64_size_dynamic_sections are
    very similar, except for the followings:
    
    1. elf_i386_size_dynamic_sections checks GOT_TLS_IE and GOT_TLS_IE_BOTH.
    elf_x86_64_size_dynamic_sections checks only GOT_TLS_IE.  Since
    GOT_TLS_IE_BOTH is never true for x86-64, it is OK to check GOT_TLS_IE
    for both i386 and x86-64.
    2, x86-64 sets tlsdesc_plt, but i386 doesn't.  We set tlsdesc_plt only
    if target_id == X86_64_ELF_DATA.
    3. x86-64 has
    
    	  if (s != htab->elf.srelplt)
    	    s->reloc_count = 0;
    
    and i386 has
    
    	  s->reloc_count = 0;
    
    i386 did have
    
    	  if (s != htab->srelplt)
    	    s->reloc_count = 0;
    
    in the original commit:
    
    commit 67a4f2b710581acc83afecff55424af285ecbc28
    Author: Alexandre Oliva <aoliva@redhat.com>
    Date:   Wed Jan 18 21:07:51 2006 +0000
    
    But it was removed by
    
    commit 5ae0bfb60a576344d7f701605346282c1144499e
    Author: Richard Sandiford <rdsandiford@googlemail.com>
    Date:   Tue Feb 28 07:16:12 2006 +0000
    
        bfd/
                * elf32-i386.c (elf_i386_link_hash_table): Add next_tls_desc_index.
                (elf_i386_link_hash_table_create): Initialize it.
                (elf_i386_compute_jump_table_size): Use it instead of
                srelplt->reloc_count.
                (allocate_dynrelocs): Likewise.
                (elf_i386_size_dynamic_sections): Likewise.
                (elf_i386_relocate_section): Likewise.
    
    A later commit:
    
    commit e1f987424b7b3f5ac63a2a6ae044a202a44b8ff8
    Author: H.J. Lu <hjl.tools@gmail.com>
    Date:   Fri Oct 21 15:13:37 2011 +0000
    
        Put IRELATIVE relocations after JUMP_SLOT.
    
        bfd/
    
        2011-10-21  H.J. Lu  <hongjiu.lu@intel.com>
    
                PR ld/13302
                * elf32-i386.c (elf_i386_link_hash_table): Add next_jump_slot_index
                and next_irelative_index.
                (elf_i386_link_hash_table_create): Initialize next_jump_slot_index
                and next_irelative_index.
                (elf_i386_allocate_dynrelocs): Increment reloc_count instead of
                next_tls_desc_index.
                (elf_i386_size_dynamic_sections): Set next_tls_desc_index and
                next_irelative_index from reloc_count.
                (elf_i386_finish_dynamic_symbol): Put R_386_IRELATIVE after
                R_386_JUMP_SLOT.
    
    changed it back to use reloc_count again. So it is correct to use
    
    	  if (s != htab->elf.srelplt)
    	    s->reloc_count = 0;
    
    for both i386 and x86-64 now.
    4. i386 and x86-64 use different DT_XXXs.  They are handled by adding
    them to elf_x86_link_hash_table.
    
    With these changes, we can share _bfd_x86_elf_size_dynamic_sections in
    elf32-i386.c and elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_convert_load): Renamed to ...
    	(_bfd_i386_elf_convert_load): This.  Remove static.
    	(elf_i386_size_dynamic_sections): Removed.
    	(elf_backend_size_dynamic_sections): Likewise.
    	* elf64-x86-64.c (elf_x86_64_convert_load): Renamed to ...
    	(_bfd_x86_64_elf_convert_load): This.  Remove static.
    	(elf_x86_64_size_dynamic_sections): Removed.
    	(elf_backend_size_dynamic_sections): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_allocate_dynrelocs): Renamed to ...
    	(elf_x86_allocate_dynrelocs): This.  Make it static.
    	(_bfd_x86_elf_allocate_local_dynrelocs): Renamed to ...
    	(elf_x86_allocate_local_dynreloc): This.  Make it static.
    	(elf_i386_is_reloc_section): New function.
    	(elf_x86_64_is_reloc_section): Likewise.
    	(_bfd_x86_elf_link_hash_table_create): Initialize convert_load,
    	is_reloc_section, dt_reloc, dt_reloc_sz and dt_reloc_ent.
    	Rearrange got_entry_size initialization.
    	(_bfd_x86_elf_size_dynamic_sections): New function.
    	* elfxx-x86.h (elf_x86_link_hash_table): Add convert_load,
    	is_reloc_section, dt_reloc, dt_reloc_sz and dt_reloc_ent.
    	(_bfd_i386_elf_convert_load): New.
    	(_bfd_x86_64_elf_convert_load): Likewise.
    	(_bfd_x86_elf_size_dynamic_sections): Likewise.
    	(elf_backend_size_dynamic_sections): Likewise.
    	(_bfd_x86_elf_allocate_dynrelocs): Removed.
    	(_bfd_x86_elf_allocate_local_dynrelocs): Likewise.

commit 2926eb2c326c625f54db61796fbe034b31f0958f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 13:05:49 2017 -0700

    x86: Rearrange fields and update comments
    
    	* elfxx-x86.h (elf_x86_link_hash_table): Rearrange fields and
    	update comments.

commit 92c10f5f61e8342eda76fb6927dcc1c885eda96a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 11:18:30 2017 -0700

    i386: Update sgotplt_jump_table_size setting
    
    elf_i386_size_dynamic_sections has
    
          htab->next_tls_desc_index = htab->elf.srelplt->reloc_count;
          htab->sgotplt_jump_table_size = htab->next_tls_desc_index * 4;
    
    This patch changes it to
    
          htab->sgotplt_jump_table_size
    	= elf_x86_compute_jump_table_size (htab)
    
    Since elf_x86_compute_jump_table_size is defined as
    
      ((htab)->elf.srelplt->reloc_count * (htab)->got_entry_size)
    
    there is no change in output.  It makes elf_i386_size_dynamic_sections
    the same as elf_x86_64_size_dynamic_sections.
    
    	* elf32-i386.c (elf_i386_size_dynamic_sections): Set
    	sgotplt_jump_table_size with elf_x86_compute_jump_table_size.

commit aa595247af472bb95bcd36c166335c851e3e752d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 11:10:51 2017 -0700

    x86: Define PLT_CIE_LENGTH and PLT_FDE_* in elfxx-x86.h
    
    Since PLT_CIE_LENGTH, PLT_FDE_LENGTH, PLT_FDE_START_OFFSET and
    PLT_FDE_LEN_OFFSET are identical in elf32-i386.c and elf64-x86-64.c,
    they can be defined in elfxx-x86.h.
    
    	* elf32-i386.c (PLT_CIE_LENGTH, PLT_FDE_LENGTH,
    	PLT_FDE_START_OFFSET, PLT_FDE_LEN_OFFSET): Moved to ...
    	* elfxx-x86.h (PLT_CIE_LENGTH, PLT_FDE_LENGTH,
    	PLT_FDE_START_OFFSET, PLT_FDE_LEN_OFFSET): Here.
    	* elf64-x86-64.c (PLT_CIE_LENGTH, PLT_FDE_LENGTH,
    	PLT_FDE_START_OFFSET, PLT_FDE_LEN_OFFSET): Removed.

commit b9ce864ca8dcd0e52e2b7c655603b181fa19cfbf
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 07:26:54 2017 -0700

    x86: Add _bfd_x86_elf_allocate_dynrelocs
    
    Share _bfd_x86_elf_allocate_dynrelocs in elf32-i386.c and elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_allocate_dynrelocs): Removed.
    	(elf_i386_allocate_local_dynrelocs): Likewise.
    	(elf_i386_size_dynamic_sections): Replace
    	elf_i386_allocate_dynrelocs/elf_i386_allocate_local_dynrelocs
    	with _bfd_x86_elf_allocate_dynrelocs and
    	_bfd_x86_elf_allocate_local_dynrelocs.
    	* elf64-x86-64.c (elf_x86_64_allocate_dynrelocs): Removed.
    	(elf_x86_64_allocate_local_dynrelocs): Likewise.
    	(elf_x86_64_size_dynamic_sections): Replace
    	elf_x86_64_allocate_dynrelocs/elf_x86_64_allocate_local_dynrelocs
    	with _bfd_x86_elf_allocate_dynrelocs and
    	_bfd_x86_elf_allocate_local_dynrelocs.
    	* elfxx-x86.c (_bfd_x86_elf_allocate_dynrelocs): New function.
    	(_bfd_x86_elf_allocate_local_dynrelocs): Likewise.
    	* elfxx-x86.h (_bfd_x86_elf_allocate_dynrelocs): New prototype.
    	(_bfd_x86_elf_allocate_local_dynrelocs): Likewise.

commit fe53b4a4c47df9c0bb2fa7f0de5a241f21cf352c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 07:23:46 2017 -0700

    x86: Add is_x86_elf
    
    Share is_x86_elf in elf32-i386.c and elf64-x86-64.c.
    
    	* elf32-i386.c (is_i386_elf): Removed.
    	(elf_i386_check_relocs): Replace is_i386_elf with is_x86_elf.
    	(elf_i386_size_dynamic_sections): Likewise.
    	(elf_i386_relocate_section): Likewise.
    	* elf64-x86-64.c (is_x86_64_elf): Removed.
    	(elf_x86_64_check_relocs): Replace is_x86_64_elf with
    	is_x86_elf.
    	(elf_x86_64_size_dynamic_sections): Likewise.
    	(elf_x86_64_relocate_section): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Initialize
    	target_id.
    	* elfxx-x86.h (elf_x86_link_hash_table): Add target_id.
    	(is_x86_elf): New.

commit 9ff114ca5d2c2753f1ac110f8586d0040c27a7a3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 07:16:33 2017 -0700

    x86: Add elf_x86_compute_jump_table_size
    
    Share elf_x86_compute_jump_table_size in elf32-i386.c and
    elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_compute_jump_table_size): Removed.
    	(elf_i386_allocate_dynrelocs): Replace
    	elf_i386_compute_jump_table_size with
    	elf_x86_compute_jump_table_size.
    	(elf_i386_size_dynamic_sections): Likewise.
    	* elf64-x86-64.c (elf_x86_64_compute_jump_table_size): Removed.
    	(elf_x86_64_allocate_dynrelocs): Replace
    	elf_x86_64_compute_jump_table_size with
    	elf_x86_compute_jump_table_size.
    	(elf_x86_64_size_dynamic_sections): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Initialize
    	got_entry_size.
    	* elfxx-x86.h (elf_x86_link_hash_table): Add got_entry_size.
    	(elf_x86_compute_jump_table_size): New.

commit 503294e755498eb6545ca72b338c5037facab7f7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 05:55:25 2017 -0700

    x86: Add sizeof_reloc to elf_x86_link_hash_table
    
    Initialize htab->sizeof_reloc once, instead of computing it every time.
    
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Initialize
    	sizeof_reloc.
    	(_bfd_x86_elf_adjust_dynamic_symbol): Use sizeof_reloc.
    	* elfxx-x86.h (elf_x86_link_hash_table): Add sizeof_reloc.

commit 9a742a902f48369144cdbf5333392f128c74ab7b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 05:05:30 2017 -0700

    i386: Check VxWorks with htab->is_vxworks
    
    	* elf32-i386.c (elf_i386_allocate_dynrelocs): Check VxWorks
    	with htab->is_vxworks.
    	(elf_i386_size_dynamic_sections): Likewise.
    	(elf_i386_relocate_section): Likewise.
    	(elf_i386_finish_dynamic_symbol): Likewise.
    	(elf_i386_finish_dynamic_sections): Likewise.

commit 6b9553e2a5d2ba0e43d0bdf382bbc6b5011032a1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Sep 2 04:52:00 2017 -0700

    x86: Move GOT_TLS_* in elf32-i386.c to elfxx-x86.h
    
    elf64-x86-64.c can use GOT_TLS_* definitions in elf32-i386.c with
    GOT_TLS_IE_POS, GOT_TLS_IE_NEG and GOT_TLS_IE_BOTH unused.
    
    	* elf32-i386.c (GOT_TLS_IE, GOT_TLS_IE_POS, GOT_TLS_IE_NEG,
    	GOT_TLS_IE_BOTH, GOT_TLS_GDESC, GOT_TLS_GD_BOTH_P,
    	GOT_TLS_GD_P, GOT_TLS_GDESC_P, GOT_TLS_GD_ANY_P): Moved to ...
    	* elfxx-x86.h (GOT_TLS_IE, GOT_TLS_IE_POS, GOT_TLS_IE_NEG,
    	GOT_TLS_IE_BOTH, GOT_TLS_GDESC, GOT_TLS_GD_BOTH_P,
    	GOT_TLS_GD_P, GOT_TLS_GDESC_P, GOT_TLS_GD_ANY_P): Here.
    	* elf64-x86-64.c (GOT_TLS_IE, GOT_TLS_GDESC, GOT_TLS_GD_BOTH_P,
    	GOT_TLS_GD_P, GOT_TLS_GDESC_P, GOT_TLS_GD_ANY_P): Removed.

commit 1fa4ec6ae707402c6b61cde33cfe4bdeafd53f82
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Sep 2 11:08:05 2017 +0930

    LTO rescan archives
    
    ld ought to be more clever about where it puts LTO recompiled objects.
    Ideally the recompiled objects ought to be ordered to the same place
    their IR objects were, and files extracted from archives on the second
    pass ought to go in the same place as they would if extracted on the
    first pass.  This patch addresses the archive problem.  Without this
    fix, objects extracted from archives might be placed after the crt
    files intended to go at the end of an executable or shared library,
    possibly causing exception handling failures.
    
    	* ldlang.h (lang_input_statement_type): Expand comments.
    	(LANG_FOR_EACH_INPUT_STATEMENT): Rewrite without casts.
    	* ldlang.c (lang_for_each_input_file): Likewise.
    	(load_symbols): Set usrdata for archives.
    	(find_rescan_insertion): New function.
    	(lang_process): Trim off and reinsert entries added to file chain
    	when rescanning archives for LTO.
    	* ldmain.c (add_archive_element): Set my_archive input_statement
    	next pointer to last element added.

commit ad71ce8de7dba823f5fc478e6d5eba03f1a2e822
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 18:53:26 2017 -0700

    x86-64: Check ELF_COMMON_DEF_P for common symbols
    
    bfd/
    
    	PR ld/22064
    	* elf64-x86-64.c (elf_x86_64_finish_dynamic_symbol): Check
    	ELF_COMMON_DEF_P for common symbols.
    
    ld/
    
    	PR ld/22064
    	* testsuite/ld-x86-64/pr22064a.S: New file.
    	* testsuite/ld-x86-64/pr22064b.c: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run PR ld/22064 test.

commit 96d01d93c4025cddeff197c98c7947e2b8f427bd
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Sep 2 11:00:02 2017 +0930

    -Og warning fixes
    
    Found when building with gcc 4.9.4 using -Og.
    
    bfd/
    	* elf-eh-frame.c (offset_adjust): Avoid false positive gcc warning.
    	* elflink.c (bfd_elf_size_dynsym_hash_dynstr): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
    ld/
    	* emultempl/msp430.em (eval_upper_either_sections): Make base_sec_name
    	a const char*.
    	(eval_lower_either_sections): Likewise.
    	(msp430_elf_after_allocation): Likewise, and don't needlessly concat
    	and free.  Warning fix.

commit 96fbe52eaafef0e7abffc3e4d25fd89ae8464c88
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Sep 2 00:00:25 2017 +0000

    Automatic date update in version.in

commit 4f501a245f67d0b43f245b09515c87bfeec983ec
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 14:51:58 2017 -0700

    x86: Add _bfd_x86_elf_gc_mark_hook
    
    Since R_X86_64_GNU_VTINHERIT == R_386_GNU_VTINHERIT and
    R_X86_64_GNU_VTENTRY == R_386_GNU_VTENTRY, we can share
    _bfd_x86_elf_gc_mark_hook in elf32-i386.c and elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_gc_mark_hook): Removed.
    	(elf_backend_gc_mark_hook): Likewise.
    	* elf64-x86-64.c (elf_x86_64_gc_mark_hook): Likewise.
    	(elf_backend_gc_mark_hook): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_gc_mark_hook): New function.
    	* elfxx-x86.h (_bfd_x86_elf_gc_mark_hook): New.
    	(elf_backend_gc_mark_hook): Likewise.

commit eeb2f20a764bee3a6a1edb9872467d044aaad848
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 13:03:40 2017 -0700

    x86: Add _bfd_x86_elf_adjust_dynamic_symbol
    
    Share _bfd_x86_elf_adjust_dynamic_symbol in elf32-i386.c and
    elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_adjust_dynamic_symbol): Removed.
    	(elf_backend_adjust_dynamic_symbol): Likewise.
    	* elf64-x86-64.c (elf_x86_64_adjust_dynamic_symbol): Likewise.
    	(elf_backend_adjust_dynamic_symbol): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_adjust_dynamic_symbol): New function.
    	(_bfd_x86_elf_link_setup_gnu_properties): Copy is_vxworks.
    	* elfxx-x86.h (elf_x86_link_hash_table): Add is_vxworks.
    	(_bfd_x86_elf_adjust_dynamic_symbol): New.
    	(elf_backend_adjust_dynamic_symbol): Likewise.

commit 18da07cd128d8d33bb6d01b2c59f12bd7f77324a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 13:01:23 2017 -0700

    Correct ChangeLog entry

commit c6295c2290d4dd89e588e26f6772c023ab154858
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 12:39:38 2017 -0700

    elfxx-x86.h: Fix a typo in comments
    
    	* elfxx-x86.h (elf_x86_plt_layout_table): Fix a typo in
    	comments.

commit 39946cc227a1bfbae6d6a2a968f4935d9f8b92a7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 12:09:03 2017 -0700

    x86: Add _bfd_x86_elf_mkobject
    
    Share _bfd_x86_elf_mkobject in elf32-i386.c and elf64-x86-64.c.
    
    	* elf32-i386.c (elf_i386_mkobject): Removed.
    	(bfd_elf32_mkobject): Likewise.
    	* elf64-x86-64.c (elf_x86_64_mkobject): Likewise.
    	(bfd_elf64_mkobject): Likewise.
    	(bfd_elf32_mkobject): Likewise.
    	* elfxx-x86.c (_bfd_x86_elf_mkobject): New function.
    	(_bfd_x86_elf_mkobject): New.
    	(bfd_elf64_mkobject): Likewise.
    	(bfd_elf32_mkobject): Likewise.

commit ed53c0150c0b251a897a5dd8958c589f4cd73791
Merge: 82a4977 a6798ba
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 08:02:02 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit a6798baba212170e427d2f9bd99af12f1078b162
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 08:00:36 2017 -0700

    x86: Add _bfd_x86_elf_link_setup_gnu_properties
    
    Extract the common parts of elf_i386_link_setup_gnu_properties and
    elf_x86_64_link_setup_gnu_properties into a new function.
    
    For x86-64, since PIC PLT layouts are the same as non-PIC PLT layouts,
    initialize pic_plt0_entry and pic_plt_entry fields in PLT layouts with
    the non-PIC PLT entries.
    
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Updated.
    	Call _bfd_x86_elf_link_setup_gnu_properties.
    	* elf64-x86-64.c (elf_x86_lazy_plt_layout): Initialize
    	pic_plt0_entry and pic_plt_entry fields with the non-PIC PLT
    	entries.
    	(elf_x86_64_non_lazy_plt): Likewise.
    	(elf_x86_64_lazy_bnd_plt): Likewise.
    	(elf_x86_64_non_lazy_bnd_plt): Likewise.
    	(elf_x86_64_lazy_ibt_plt): Likewise.
    	(elf_x32_lazy_ibt_plt): Likewise.
    	(elf_x86_64_non_lazy_ibt_plt): Likewise.
    	(elf_x32_non_lazy_ibt_plt): Likewise.
    	(elf_x86_64_nacl_plt): Likewise.
    	(elf_x86_64_link_setup_gnu_properties): Updated.  Call
    	_bfd_x86_elf_link_setup_gnu_properties.
    	* elfxx-x86.c: Include elf-vxworks.h".
    	(_bfd_x86_elf_link_setup_gnu_properties): New function.
    	* elfxx-x86.h (elf_x86_lazy_plt_layout): Remove "for i386 only"
    	comments for pic_plt0_entry and pic_plt_entry.
    	(elf_x86_non_lazy_plt_layout): Likewise.
    	(elf_x86_plt_layout_table): New.
    	(_bfd_x86_elf_link_setup_gnu_properties): Likewise.

commit 376dc015f275575e0aa7be9c46476db5506ff836
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 06:14:39 2017 -0700

    Import latest fixes to libiberty from GCC
    
    Fix warning for simple-object-elf.c.
    
    2017-09-01  Martin Liska  <mliska@suse.cz>
    
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_sections):
    	Remove duplicite declaration.

commit e10c9c620c3335731bb0052987affdc40942fd71
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Sep 1 06:11:54 2017 -0700

    x86: Correct unwind information for the second PLT
    
    For i386, generate unwind information for the second PLT.  For x32,
    correct alignment of .eh_frame section for the second PLT.
    
    bfd/
    
    	PR ld/22061
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Create
    	.eh_frame section for the second PLT.
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Correct
    	alignment of .eh_frame section for the second PLT.
    
    ld/
    
    	PR ld/22061
    	* testsuite/ld-i386/ibt-plt-1.d: Updated.
    	* testsuite/ld-i386/ibt-plt-2a.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-2c.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3a.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3c.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-2b.d: Pass --hash-style=sysv to ld
    	and dump unwind information.
    	* testsuite/ld-i386/ibt-plt-2d.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3b.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3d.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2b-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2b.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2d-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2d.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3b-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3b.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3d-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3d.d: Likewise.

commit 1c5c938ad860811644774ecea66e044110967cf2
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Fri Sep 1 11:43:51 2017 +0100

    Enable support for the AArch64 dot-prod instruction in the Cortex A55 and A75 cpus.
    
    	* config/tc-aarch64.c (aarch64_cpus): Enable DOTPROD for
    	cortex-a55 and cortx-a75.

commit 7e8b60085eb3e6f2c41bc0c00c0d759fa7f72780
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Sep 1 11:20:51 2017 +0100

    Prevent an address violation parsing corrupt DWARF information by fixing the test for an overlong debug line info structure.
    
    	PR 22059
    	* dwarf2.c (decode_line_info): Fix test for an overlong line info
    	structure.

commit f8ad2513754f5a53fecb407cf64fcb586836b60c
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Sep 1 10:52:53 2017 +0100

    Import latest fixes to libiberty from GCC.
    
    	PR lto/81968
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_section):
    	Keep names of removed global symbols.
    
    	* simple-object-xcoff.c (simple_object_xcoff_find_sections):
    	Improve .go_export csect handling.  Don't make assumptions
    	on containing section or number of auxiliary entries.
    
    	PR lto/81968
    	* simple-object-elf.c (simple_object_elf_copy_lto_debug_section):
    	Adjust field with for sh_type write, set SHF_EXCLUDE only for
    	removed sections.
    
    	PR lto/81925
    	* simple-object-elf.c (simple_object_elf_write_shdr): Adjust
    	type of sh_addralign and sh_entsize and properly write
    	sh_entsize as Elf_Addr.
    	(simple_object_elf_write_to_file): Read sh_entsize as Elf_Addr.
    
    	* simple-object-common.h (struct simple_object_functions): Add
    	copy_lto_debug_sections hook.
    	* simple-object.c: Include fcntl.h.
    	(handle_lto_debug_sections): New helper function.
    	(simple_object_copy_lto_debug_sections): New function copying
    	early LTO debug sections to regular debug sections in a new file.
    	(simple_object_start_write): Handle NULL segment_name.
    	* simple-object-coff.c (simple_object_coff_functions): Adjust
    	for not implemented copy_lto_debug_sections hook.
    	* simple-object-mach-o.c (simple_object_mach_o_functions): Likewise.
    	* simple-object-xcoff.c (simple_object_xcoff_functions): Likewise.
    	* simple-object-elf.c (SHT_NULL, SHT_SYMTAB, SHT_RELA, SHT_REL,
    	SHT_GROUP): Add various sectopn header types.
    	(SHF_EXCLUDE): Add flag.
    	(Elf32_External_Sym, Elf64_External_Sym): Add symbol struct.
    	(ELF_ST_BIND, ELF_ST_TYPE, ELF_ST_INFO): Add accessors.
    	(STT_OBJECT, STT_FUNC, STT_TLS, STT_GNU_IFUNC): Add Symbol types.
    	(STV_DEFAULT): Add symbol visibility.
    	(SHN_COMMON): Add special section index name.
    	(struct simple_object_elf_write): New.
    	(simple_object_elf_start_write): Adjust for new private data.
    	(simple_object_elf_write_shdr): Pass in values for all fields
    	we write.
    	(simple_object_elf_write_to_file): Adjust.  Copy from recorded
    	section headers if requested.
    	(simple_object_elf_release_write): Release private data.
    	(simple_object_elf_copy_lto_debug_sections): Copy and rename sections
    	as denoted by PFN and all their dependences, symbols and relocations
    	to the empty destination file.
    	(simple_object_elf_functions): Adjust for copy_lto_debug_sections hook.
    
    	* simple-object-xcoff.c (simple_object_xcoff_find_sections):
    	Search symbol table for .go_export symbol and apply pfn if found.

commit 2a143b99fc4a5094a9cf128f3184d8e6818c8229
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Sep 1 09:57:44 2017 +0100

    Fix buffer overrun when parsing an ELF attribute string that is not NUL terminated.
    
    	PR 22058
    	* elf-attrs.c (_bfd_elf_parse_attributes): Ensure that the
    	attribute buffer is NUL terminated.

commit 5c811d30d12b6f7c6c6f4ce6d03408d987154548
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Sep 1 06:13:40 2017 +0200

    PR gdb/22046: Fix T-stopped detach regression on old Linux kernels
    
    On <=RHEL6 hosts Fedora/RHEL GDB started to 'kill -STOP' all processes it
    detached.  Even those not originally T-stopped.  This is a Fedora-specific
    patch which is based on upstream GDB's PROC_STATE_STOPPED state.
    
    I believe (I did not verify) this patch did regress it:
    commit d617208bb06bd461b52ce041d89f7127e3044762
    Author: Pedro Alves <palves@redhat.com>
    Date:   Mon Jul 25 12:42:17 2016 +0100
        linux-procfs: Introduce enum proc_state
    
    As originally there was strstr() but now there is strcmp() and so the missing
    trailing '\n' no longer matches.
    
    The Bug was found by Michal Kolar.
    
    Reproducibility:
    $ gdb -p $PID
    (gdb) quit
    $ ...
    
    Actual results:
    ===
    RHEL6.9 x86_64 # scl enable devtoolset-7 bash
    RHEL6.9 x86_64 # which gdb
    /opt/rh/devtoolset-7/root/usr/bin/gdb
    RHEL6.9 x86_64 # ./testcase.sh
    24737 pts/0    S+     0:00 /bin/sleep 4
    24737 pts/0    T+     0:00 /bin/sleep 4
    RHEL6.9 x86_64 #
    ===
    
    Expected results:
    ===
    RHEL6.9 x86_64 # which gdb
    /usr/bin/gdb
    RHEL6.9 x86_64 # ./testcase.sh
    24708 pts/0    S+     0:00 /bin/sleep 4
    24708 pts/0    S+     0:00 /bin/sleep 4
    ./testcase.sh: line 20: kill: (24708) - No such process
    RHEL6.9 x86_64 #
    ===
    
    gdb/ChangeLog
    2017-09-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	PR gdb/22046
    	* nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
    	detection.

commit 1f0c13579f6833edc85b5399486edf95b4b9630e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Sep 1 00:00:25 2017 +0000

    Automatic date update in version.in

commit 0a2dde4a321d2f7bd2ded9a558b9ae92892de0e2
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Thu Jun 29 15:06:07 2017 -0400

    Implement the ability to set/unset environment variables to GDBserver when starting the inferior
    
    This patch implements the ability to set/unset environment variables
    on the remote target, mimicking what GDB already offers to the user.
    There are two features present here: user-set and user-unset
    environment variables.
    
    User-set environment variables are only the variables that are
    explicitly set by the user, using the 'set environment' command.  This
    means that variables that were already present in the environment when
    starting GDB/GDBserver are not transmitted/considered by this feature.
    
    User-unset environment variables are variables that are explicitly
    unset by the user, using the 'unset environment' command.
    
    The idea behind this patch is to store user-set and user-unset
    environment variables in two separate sets, both part of gdb_environ.
    Then, when extended_remote_create_inferior is preparing to start the
    inferior, it will iterate over the two sets and set/unset variables
    accordingly.  Three new packets are introduced:
    
    - QEnvironmentHexEncoded, which is used to set environment variables,
      and contains an hex-encoded string in the format "VAR=VALUE" (VALUE
      can be empty if the user set a variable with a null value, by doing
      'set environment VAR=').
    
    - QEnvironmentUnset, which is used to unset environment variables, and
      contains an hex-encoded string in the format "VAR".
    
    - QEnvironmentReset, which is always the first packet to be
      transmitted, and is used to reset the environment, i.e., discard any
      changes made by the user on previous runs.
    
    The QEnvironmentHexEncoded packet is inspired on LLDB's extensions to
    the RSP.  Details about it can be seen here:
    
      <https://raw.githubusercontent.com/llvm-mirror/lldb/master/docs/lldb-gdb-remote.txt>
    
    I decided not to implement the QEnvironment packet because it is
    considered deprecated by LLDB.  This packet, on LLDB, serves the same
    purpose of QEnvironmentHexEncoded, but sends the information using a
    plain text, non-hex-encoded string.
    
    The other two packets are new.
    
    This patch also includes updates to the documentation, testsuite, and
    unit tests, without introducing regressions.
    
    gdb/ChangeLog:
    2017-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* NEWS (Changes since GDB 8.0): Add entry mentioning new support
    	for setting/unsetting environment variables on the remote target.
    	(New remote packets): Add entries for QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset.
    	* common/environ.c (gdb_environ::operator=): Extend method to
    	handle m_user_set_env_list and m_user_unset_env_list.
    	(gdb_environ::clear): Likewise.
    	(match_var_in_string): Change type of first parameter from 'char
    	*' to 'const char *'.
    	(gdb_environ::set): Extend method to handle
    	m_user_set_env_list and m_user_unset_env_list.
    	(gdb_environ::unset): Likewise.
    	(gdb_environ::clear_user_set_env): New method.
    	(gdb_environ::user_set_envp): Likewise.
    	(gdb_environ::user_unset_envp): Likewise.
    	* common/environ.h (gdb_environ): Handle m_user_set_env_list and
    	m_user_unset_env_list on move constructor/assignment.
    	(unset): Add new default parameter 'update_unset_list = true'.
    	(clear_user_set_env): New method.
    	(user_set_envp): Likewise.
    	(user_unset_envp): Likewise.
    	(m_user_set_env_list): New std::set.
    	(m_user_unset_env_list): Likewise.
    	* common/rsp-low.c (hex2str): New function.
    	(bin2hex): New overload for bin2hex function.
    	* common/rsp-low.c (hex2str): New prototype.
    	(str2hex): New overload prototype.
    	* remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset.
    	(remote_protocol_features): Add QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset packets.
    	(send_environment_packet): New function.
    	(extended_remote_environment_support): Likewise.
    	(extended_remote_create_inferior): Call
    	extended_remote_environment_support.
    	(_initialize_remote): Add QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset packet configs.
    	* unittests/environ-selftests.c (gdb_selftest_env_var):
    	New variable.
    	(test_vector_initialization): New function.
    	(test_init_from_host_environ): Likewise.
    	(test_reinit_from_host_environ): Likewise.
    	(test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
    	Likewise.
    	(test_unset_set_empty_vector): Likewise.
    	(test_vector_clear): Likewise.
    	(test_std_move): Likewise.
    	(test_move_constructor):
    	(test_self_move): Likewise.
    	(test_set_unset_reset): Likewise.
    	(run_tests): Rewrite in terms of the functions above.
    
    gdb/gdbserver/ChangeLog:
    2017-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* server.c (handle_general_set): Handle QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset packets.
    	(handle_query): Inform remote that QEnvironmentHexEncoded,
    	QEnvironmentUnset and QEnvironmentReset are supported.
    
    gdb/doc/ChangeLog:
    2017-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.texinfo (set environment): Add @anchor.  Explain that
    	environment variables set by the user are sent to GDBserver.
    	(unset environment): Likewise, but for unsetting variables.
    	(Connecting) <Remote Packet>: Add "environment-hex-encoded",
    	"QEnvironmentHexEncoded", "environment-unset", "QEnvironmentUnset",
    	"environment-reset" and "QEnvironmentReset" to the table.
    	(Remote Protocol) <QEnvironmentHexEncoded, QEnvironmentUnset,
    	QEnvironmentReset>: New item, explaining the packet.
    
    gdb/testsuite/ChangeLog:
    2017-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	* gdb.base/share-env-with-gdbserver.c: New file.
    	* gdb.base/share-env-with-gdbserver.exp: Likewise.

commit e4f2723003859dc6b33ca0dadbc4a7659ebf1643
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 31 17:03:23 2017 +0100

    Fix buffer read overrun by ensuring that DWARF sections containing strings always end in a NUL byte.
    
    	PR 22047
    	* dwarf2.c (read_section): If necessary add a terminating NUL byte
    	to dwarf string sections.

commit b55f3386e45d8ba4af1a70f0684bc0089060d600
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 31 14:33:56 2017 +0100

    Add updated French translations for opcodes and gprof

commit d7de64088c7ce0d642c73feb66f408c601cffb0d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 31 03:53:44 2017 -0700

    Add a test for PR ld/22048
    
    	PR ld/22048
    	* testsuite/ld-x86-64/pr22048.d: New file.
    	* testsuite/ld-x86-64/pr22048a.s: Likewise.
    	* testsuite/ld-x86-64/pr22048b.s: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run pr22048.

commit 686335cd3c7d4eef6ce4e3e54ef0e75929b5e4fb
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 31 20:07:13 2017 +0930

    Regen SRC-POTFILES.in
    
    	* po/SRC-POTFILES.in: Regenerate.

commit 9866ffe25a0fe73f5153f2720650baf0dd9cc828
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 31 19:39:14 2017 +0930

    Remove .eh_frame zero terminators
    
    The machinery to do this was there, but not enabled if the terminator
    was the only thing in the section.
    
    bfd/
    	* elf-eh-frame.c (_bfd_elf_parse_eh_frame): Don't exit early
    	for a section containing just a terminator.  Allow multiple
    	terminators at end of section.
    	* elflink.c (bfd_elf_discard_info): Iterate over .eh_frame
    	sections when not adding alignment.  Assert on terminator in
    	the middle of FDEs.
    ld/
    	* testsuite/ld-elf/eh3.d: Update.
    	* testsuite/ld-elf/eh4.d: Update.

commit 654670a4f0928e3eddc6395d6804deb2e61a0614
Author: Weimin Pan <weimin.pan@oracle.com>
Date:   Fri Aug 25 19:33:25 2017 -0500

    Unbreak gdb build on 32-bit host with ADI support
    
    The problem of failing to build with arm-linux-gnueabihf-g++-4.8 was
    that type CORE_ADDR is of "unsigned long" on a 64-bit machine so it's
    OK to use %lx but is of type "unsigned long long" on a 32 bit system.
    
    Fixed the problem in three places - (1) use a temp variable of type
    CORE_ADDR as argument 3 when calling target_auxv_search() then assign
    its value to "blksize" and "nbits" in 2 calls; (2) redo
    adi_normalize_address() using masks and xor operators to calculate
    normalized address; (3) call paddress() to print CORE_ADDR in either
    printf_filtered() or error(). Thank you, Pedro, for all your
    suggestions.
    
    gdb/ChangeLog:
    2017-08-31  Weimin Pan  <weimin.pan@oracle.com>
    
    	* sparc64-tdep.c (adi_stat_t): Fix comment formatting.
    	(adi_available): Use a temp variable of type CORE_ADDR as argument
    	3 when calling target_auxv_search.
    	(adi_normalize_address): Use masks and xor operators to calculate
    	normalized address.
    	(adi_read_versions, adi_write_versions, adi_print_versions)
    	(do_examine, do_assign): Use paddress.

commit af471f828cc74d65b50a7531ba2c69522266cfe9
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 31 12:48:37 2017 +0930

    PR22048, Incorrect .eh_frame section in libc.so
    
    	PR 21441
    	PR 22048
    	* elflink.c (bfd_elf_discard_info): Don't pad embedded zero
    	terminators.

commit 3321e42bf2b5819b76ca36e8964fe7cf9a8ae9a2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 19:55:45 2017 -0700

    Add elf64.lo together with elfxx-x86.lo for 64-bit BFD
    
    Since elfxx-x86.lo needs elf64.lo with 64-bit BFD, add elf64.lo together
    with elfxx-x86.lo to bfd_backends for 64-bit BFD.
    
    	* configure.ac (bfd_backends): Add elf64.lo together with
    	elfxx-x86.lo for 64-bit BFD.
    	* configure: Regenerated.

commit 59e8523bf8f92db8371d3a10bd7e4d7fe03d417d
Author: James Bowman <jamesb@excamera.com>
Date:   Wed Aug 30 19:51:49 2017 -0700

    FT32: improve disassembly readability
    
    For opcode fields that are not addresses, display as
    integers instead of using print_address_func.
    
    opcodes/ChangeLog:
    
    2017-08-31  James Bowman  <james.bowman@ftdichip.com>
    
    	* ft32-dis.c (print_insn_ft32): Correct display of non-address
    	fields.

commit ef32532f22be7e98c25480449fbc7a80d1030e1e
Author: James Bowman <jamesb@excamera.com>
Date:   Wed Aug 30 19:44:58 2017 -0700

    FT32: Permit R_FT32_18 overflow
    
    The howto for R_FT32_18 was using complain_overflow_signed. But some
    valid address calculations exceed the range of this reloc.  Changing it
    to complain_overflow_dont allows them.
    
    bfd/ChangeLog:
    
    	* elf32-ft32.c (ft32_elf_howto_table): Use
    	complain_overflow_dont for R_FT32_18.

commit e234de6be5cc96286e0efb90e8d9fce51239e901
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 31 08:46:47 2017 +0930

    bfd_close_all_done calling _close_and_cleanup
    
    elf64_vms_close_and_cleanup calls bfd_get_size, which calls
    iovec->bstat.  cache_bstat ends up adding the bfd to the cache lru
    list, negating the bfd_cache_close call in bfd_close_all_done.  So
    there is a dangling pointer into the freed and then reused bfd.  Thus,
    bfd_cache_close must be called after _close_and_cleanup, or better,
    via iovec->bclose.
    
    	PR binutils/22032
    	* opncls.c (bfd_close_all_done): Don't call bfd_cache_close
    	before _close_and_cleanup.  Call iovec->bclose after.
    	(bfd_close): Remove code common to, and call, bfd_close_all_done.

commit e69f32654ac724c46c0f4f645c8a49189c7b43e4
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Aug 31 00:00:22 2017 +0000

    Automatic date update in version.in

commit 5dda32094f668a3e9738ea9b3aaea530d2bba7cb
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Aug 30 22:55:14 2017 +0100

    LD/testsuite: Also discard `.MIPS.options' in orphan tests
    
    Complement commit 5b5f4e6f8cd2 ("ld: Early detection of orphans we know
    will be discarded") and add `.MIPS.options' to the list of sections
    discarded with orphan tests, removing failures like:
    
    ./ld-new: error: unplaced orphan section `.MIPS.options' from `tmpdir/orphan-11.o'.
    FAIL: ld-elf/orphan-11
    
    and:
    
    ./ld-new: error: unplaced orphan section `.MIPS.options' from `tmpdir/orphan-12.o'.
    FAIL: ld-elf/orphan-12
    
    from n64 MIPS testing.
    
    	ld/
    	* testsuite/ld-elf/orphan-11.ld: Also discard `.MIPS.options'
    	sections.

commit 82a49772752ca0a207dfe042793eb46bde6d0478
Merge: ba54661 f493882
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 14:11:01 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit f493882dab762fb49ecb8685c18a85edfab5e6d3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 12:27:17 2017 -0700

    x86: Add _bfd_x86_elf_get_synthetic_symtab
    
    Move the common codes in elf_i386_get_synthetic_symtab and
    elf_x86_64_get_synthetic_symtab to _bfd_x86_elf_get_synthetic_symtab.
    
    	* elf32-i386.c (elf_i386_plt_type): Removed.
    	(elf_i386_plt): Likewise.
    	(elf_i386_get_synthetic_symtab): Updated.   Call
    	_bfd_x86_elf_get_synthetic_symtab.
    	* elf64-x86-64.c (elf_x86_64_plt_type): Removed.
    	(elf_x86_64_plt): Likewise.
    	(elf_x86_64_get_synthetic_symtab): Updated.  Call
    	_bfd_x86_elf_get_synthetic_symtab.
    	* elfxx-x86.c (elf_i386_get_plt_got_vma): New function.
    	(elf_x86_64_get_plt_got_vma): Likewise.
    	(elf_i386_valid_plt_reloc_p): Likewise.
    	(elf_x86_64_valid_plt_reloc_p): Likewise.
    	(_bfd_x86_elf_get_synthetic_symtab): Likewise.
    	* elfxx-x86.h (elf_x86_plt_type): New.
    	(elf_x86_plt): Likewise.
    	(_bfd_x86_elf_get_synthetic_symtab): Likewise.

commit 5b86dbf4549af98c4428da4764182e03f22c58ab
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 11:13:32 2017 -0700

    x86: Check target_id instead of elf_machine_code
    
    Since both elf32-i386.c and elf64-x86-64.c support targets with
    different ELF_MACHINE_CODEs, _bfd_x86_elf_link_hash_table_create
    should check target_id instead of elf_machine_code.
    
    	* elfxx-x86.c (_bfd_x86_elf_link_hash_table_create): Check
    	target_id instead of elf_machine_code.

commit ba54661f5f0ed899c0ba75d99c289e466490a6cd
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 09:56:43 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit dfa235bfd5fed1d13e414421c3db1322cc75e9b7
Merge: d92b954 765e526
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 09:13:11 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 765e526c75506a7d9644bc7c137ac1923fdb1369
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 09:10:08 2017 -0700

    x86: Add _bfd_x86_elf_link_hash_table_create
    
    Share _bfd_x86_elf_link_hash_table_create in elf32-i386.c and
    elf64-x86-64.c by:
    
    1. Replace elf_i386_lazy_plt_layout, elf_i386_non_lazy_plt_layout,
    elf_i386_plt_layout, elf_x86_64_lazy_plt_layout,
    elf_x86_64_non_lazy_plt_layout and elf_x86_64_plt_layout with
    elf_x86_lazy_plt_layout, elf_x86_non_lazy_plt_layout and
    elf_x86_plt_layout.
    2. Move plt, lazy_plt, non_lazy_plt, srelplt2 and next_tls_desc_index
    from elf_i386_link_hash_table to elf_x86_link_hash_table.
    3. Remove elf_i386_link_hash_table and elf_x86_64_link_hash_table.
    
    	* elf32-i386.c (ELF_DYNAMIC_INTERPRETER): Removed.
    	(elf_i386_lazy_plt_layout): Likewise.
    	(elf_i386_non_lazy_plt_layout): Likewise.
    	(elf_i386_plt_layout): Likewise.
    	(elf_i386_link_hash_table): Likewise.
    	(elf_i386_next_tls_desc_index): Likewise.
    	(elf_i386_srelplt2): Likewise.
    	(elf_i386_plt): Likewise.
    	(elf_i386_lazy_plt): Likewise.
    	(elf_i386_non_lazy_plt): Likewise.
    	(elf_i386_link_hash_table_create): Likewise.
    	(bfd_elf32_bfd_link_hash_table_create): Likewise.
    	(elf_i386_lazy_plt): Updated.
    	(elf_i386_non_lazy_plt): Likewise.
    	(elf_i386_lazy_ibt_plt): Likewise.
    	(elf_i386_non_lazy_ibt_plt): Likewise.
    	(elf_i386_allocate_dynrelocs): Likewise.
    	(elf_i386_size_dynamic_sections): Likewise.
    	(elf_i386_relocate_section): Likewise.
    	(elf_i386_finish_dynamic_symbol): Likewise.
    	(elf_i386_finish_dynamic_sections): Likewise.
    	(elf_i386_get_synthetic_symtab): Likewise.
    	(elf_i386_link_setup_gnu_properties): Likewise.
    	(elf_i386_nacl_plt): Likewise.
    	* elf64-x86-64.c (ABI_64_P): Removed.
    	(ELF64_DYNAMIC_INTERPRETER): Likewise.
    	(ELF32_DYNAMIC_INTERPRETER): Likewise.
    	(elf_x86_64_lazy_plt_layout): Likewise.
    	(elf_x86_64_non_lazy_plt_layout): Likewise.
    	(elf_x86_64_plt_layout): Likewise.
    	(elf_x86_64_link_hash_table): Likewise.
    	(elf_x86_64_plt): Likewise.
    	(elf_x86_64_lazy_plt): Likewise.
    	(elf_x86_64_non_lazy_plt): Likewise.
    	(elf_x86_64_link_hash_table_create): Likewise.
    	(bfd_elf64_bfd_link_hash_table_create): Likewise.
    	(bfd_elf32_bfd_link_hash_table_create): Likewise.
    	(elf_x86_64_lazy_plt): Updated.
    	(elf_x86_64_non_lazy_plt): Likewise.
    	(elf_x86_64_lazy_bnd_plt): Likewise.
    	(elf_x86_64_non_lazy_bnd_plt): Likewise.
    	(elf_x86_64_lazy_ibt_plt): Likewise.
    	(elf_x32_lazy_ibt_plt): Likewise.
    	(elf_x86_64_non_lazy_ibt_plt): Likewise.
    	(elf_x32_non_lazy_ibt_plt): Likewise.
    	(elf_x86_64_allocate_dynrelocs): Likewise.
    	(elf_x86_64_size_dynamic_sections): Likewise.
    	(elf_x86_64_relocate_section): Likewise.
    	(elf_x86_64_finish_dynamic_symbol): Likewise.
    	(elf_x86_64_finish_dynamic_sections): Likewise.
    	(elf_x86_64_get_synthetic_symtab): Likewise.
    	(elf_x86_64_link_setup_gnu_properties): Likewise.
    	(elf_x86_64_nacl_plt): Likewise.
    	* elfxx-x86.c: Include "objalloc.h", "elf/i386.h" and
    	"elf/x86-64.h".
    	(ELF32_DYNAMIC_INTERPRETER): New.
    	(ELF64_DYNAMIC_INTERPRETER): Likewise.
    	(ELFX32_DYNAMIC_INTERPRETER): Likewise.
    	(_bfd_x86_elf_link_hash_table_create): Likewise.
    	(_bfd_x86_elf_link_hash_table_free): Renamed to ...
    	(elf_x86_link_hash_table_free): This.  Make it static.
    	* elfxx-x86.h: Don't include "objalloc.h".
    	(ABI_64_P): New.
    	(elf_x86_lazy_plt_layout): Likewise.
    	(elf_x86_non_lazy_plt_layout): Likewise.
    	(elf_x86_plt_layout): Likewise.
    	(_bfd_x86_elf_link_hash_table_create): Likewise.
    	(bfd_elf64_bfd_link_hash_table_create): Likewise.
    	(bfd_elf32_bfd_link_hash_table_create): Likewise.
    	(elf_x86_link_hash_table): Add plt, lazy_plt, non_lazy_plt,
    	srelplt2 and next_tls_desc_index.
    	(_bfd_x86_elf_link_hash_table_free): Removed.

commit 70e65ca8e5d1fc984d58f6137c290e807fe772a5
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Aug 30 16:03:31 2017 +0100

    MIPS/BFD: Correct microMIPS cross-mode BAL to JALX relaxation
    
    Fix a bug in commit a6ebf6169a1b ("MIPS: Convert cross-mode BAL to
    JALX") and in BFD linker relaxation correct the microMIPS interpretation
    of the branch offset, which is supposed to be shifted by 1 bit, rather
    than 2 as in the regular MIPS case.
    
    	bfd/
    	* elfxx-mips.c (mips_elf_perform_relocation): Correct microMIPS
    	branch offset interpretation.
    
    	gas/
    	* testsuite/gas/mips/branch-addend-micromips.d: New test.
    	* testsuite/gas/mips/branch-addend-micromips-n32.d: New test.
    	* testsuite/gas/mips/branch-addend-micromips-n64.d: New test.
    	* testsuite/gas/mips/branch-addend-micromips.s: New test source.
    	* testsuite/gas/mips/mips.exp: Run the new tests.
    
    	ld/
    	* testsuite/ld-mips-elf/bal-jalx-addend-micromips.d: New test.
    	* testsuite/ld-mips-elf/bal-jalx-addend-micromips-n32.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-addend-micromips-n64.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-local-micromips.d: New test.
    	* testsuite/ld-mips-elf/bal-jalx-local-micromips-n32.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-local-micromips-n64.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-micromips.d: New test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-micromips-n32.d: New test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-micromips-n64.d: New test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips-n32.d: New
    	test.
    	* testsuite/ld-mips-elf/bal-jalx-pic-ignore-micromips-n64.d: New
    	test.
    	* testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.

commit 37b2d327512baf2f39020e44958fd1f11db46a91
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Aug 30 15:54:19 2017 +0100

    MIPS/GAS: Also respect `-mignore-branch-isa' with MIPS16 code
    
    Fix a bug in commit 8b10b0b3e100 ("MIPS: Add options to control branch
    ISA checks") and with the `-mignore-branch-isa' command-line option also
    lift a GAS check for invalid MIPS16 branches between ISA modes, which is
    made separately from regular MIPS and microMIPS checks.
    
    	gas/
    	* config/tc-mips.c (md_convert_frag): Respect
    	`mips_ignore_branch_isa'.
    	* testsuite/gas/mips/branch-local-5.d: New test.
    	* testsuite/gas/mips/branch-local-n32-5.d: New test.
    	* testsuite/gas/mips/branch-local-n64-5.d: New test.
    	* testsuite/gas/mips/branch-local-6.d: New test.
    	* testsuite/gas/mips/branch-local-n32-6.d: New test.
    	* testsuite/gas/mips/branch-local-n64-6.d: New test.
    	* testsuite/gas/mips/branch-local-7.d: New test.
    	* testsuite/gas/mips/branch-local-n32-7.d: New test.
    	* testsuite/gas/mips/branch-local-n64-7.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-5.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-n32-5.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-n64-5.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-6.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-n32-6.d: New test.
    	* testsuite/gas/mips/branch-local-ignore-n64-6.d: New test.
    	* testsuite/gas/mips/branch-local-5.l: New stderr output.
    	* testsuite/gas/mips/branch-local-6.l: New stderr output.
    	* testsuite/gas/mips/branch-local-5.s: New test source.
    	* testsuite/gas/mips/branch-local-6.s: New test source.
    	* testsuite/gas/mips/branch-local-7.s: New test source.
    	* testsuite/gas/mips/mips.exp: Run the new tests.

commit 7c0ed39626e3193adb70aeb98d3633787579d6ec
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 06:17:28 2017 -0700

    Call _close_and_cleanup in bfd_close_all_done
    
    	PR binutils/22032
    	* opncls.c (bfd_close_all_done): Call _close_and_cleanup.

commit 0f2425c4c8fdaa7822555bbb61468b46d4e4af20
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 05:29:22 2017 -0700

    Remove elf_x86_64_next_tls_desc_index/elf_x86_64_srelplt2
    
    They are unused.
    
    	* elf64-x86-64.c (elf_x86_64_next_tls_desc_index): Removed.
    	(elf_x86_64_srelplt2): Likewise.

commit 443701f5098e8c069d5858ca597bf7a8ba4a8006
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 05:28:10 2017 -0700

    Add missing ChangeLog entries

commit e491e58adce317f8ed46aa7a15dc563131996c50
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Aug 30 12:20:53 2017 +0100

    MIPS/GAS/testsuite: Deduplicate error lists of branch local tests
    
    Complement commit 7795a8f8bdde ("MIPS/GAS/testsuite: Convert branch
    local list tests to dump tests") and share identical error lists among
    branch local tests, removing duplicate copies.
    
    	gas/
    	* testsuite/gas/mips/branch-local-n32-2.d: Use `branch-local-2.l'
    	for `error-output'.
    	* testsuite/gas/mips/branch-local-n64-2.d: Likewise.
    	* testsuite/gas/mips/branch-local-n32-3.d: Use `branch-local-3.l'
    	for `error-output'.
    	* testsuite/gas/mips/branch-local-n64-3.d: Likewise.
    	* testsuite/gas/mips/branch-local-n32-2.l: Remove file.
    	* testsuite/gas/mips/branch-local-n64-2.l: Remove file.
    	* testsuite/gas/mips/branch-local-n32-3.l: Remove file.
    	* testsuite/gas/mips/branch-local-n64-3.l: Remove file.

commit 9a23f96e919ba91587d077b1d399246dde4002dd
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 30 20:35:35 2017 +0930

    PowerPC TPREL16_HA/LO reloc optimization
    
    In the TLS GD/LD to LE optimization, ld replaces a sequence like
    
     addi 3,2,x@got@tlsgd		R_PPC64_GOT_TLSGD16	x
     bl __tls_get_addr(x@tlsgd)	R_PPC64_TLSGD		x
    				R_PPC64_REL24		__tls_get_addr
     nop
    
    with
    
     addis 3,13,x@tprel@ha		R_PPC64_TPREL16_HA	x
     addi 3,3,x@tprel@l		R_PPC64_TPREL16_LO	x
     nop
    
    When the tprel offset is small, this can be further optimized to
    
     nop
     addi 3,13,x@tprel
     nop
    
    bfd/
    	* elf64-ppc.c (struct ppc_link_hash_table): Add do_tls_opt.
    	(ppc64_elf_tls_optimize): Set it.
    	(ppc64_elf_relocate_section): Nop addis on TPREL16_HA, and convert
    	insn on TPREL16_LO and TPREL16_LO_DS relocs to use r13 when
    	addis would add zero.
    	* elf32-ppc.c (struct ppc_elf_link_hash_table): Add do_tls_opt.
    	(ppc_elf_tls_optimize): Set it.
    	(ppc_elf_relocate_section): Nop addis on TPREL16_HA, and convert
    	insn on TPREL16_LO relocs to use r2 when addis would add zero.
    gold/
    	* powerpc.cc (Target_powerpc::Relocate::relocate): Nop addis on
    	TPREL16_HA, and convert insn on TPREL16_LO and TPREL16_LO_DS
    	relocs to use r2/r13 when addis would add zero.
    ld/
    	* testsuite/ld-powerpc/tls.s: Add calls with tls markers.
    	* testsuite/ld-powerpc/tls32.s: Likewise.
    	* testsuite/ld-powerpc/powerpc.exp: Run tls marker tests.
    	* testsuite/ld-powerpc/tls.d: Adjust for TPREL16_HA/LO optimization.
    	* testsuite/ld-powerpc/tlsexe.d: Likewise.
    	* testsuite/ld-powerpc/tlsexetoc.d: Likewise.
    	* testsuite/ld-powerpc/tlsld.d: Likewise.
    	* testsuite/ld-powerpc/tlsmark.d: Likewise.
    	* testsuite/ld-powerpc/tlsopt4.d: Likewise.
    	* testsuite/ld-powerpc/tlstoc.d: Likewise.

commit b9f04fe0dfe64bc6224e7bb96378607f17da7446
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 30 20:35:09 2017 +0930

    PowerPC64 __tls_get_addr sequence optimization
    
    There isn't a good reason for ld.bfd to behave differently from gold
    in the code generated by TLS GD/LD to LE optimization.
    
    bfd/
    	* elf64-ppc.c (ppc64_elf_relocate_section): When optimizing
    	__tls_get_addr call sequences to LE, don't move the addi down
    	to the nop.  Replace the bl with addi and leave the nop alone.
    ld/
    	* testsuite/ld-powerpc/tls.d: Update.
    	* testsuite/ld-powerpc/tlsexe.d: Update.
    	* testsuite/ld-powerpc/tlsexetoc.d: Update.
    	* testsuite/ld-powerpc/tlsld.d: Update.
    	* testsuite/ld-powerpc/tlsmark.d: Update.
    	* testsuite/ld-powerpc/tlsopt4.d: Update.
    	* testsuite/ld-powerpc/tlstoc.d: Update.

commit c7dffc390cf861b313001fd08049a5fd8d758d0d
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Wed Aug 30 02:27:14 2017 +0200

    testsuite/ld-cris various files: Run ld with --hash-style=sysv.
    
    	* testsuite/ld-cris/dso-pltdis1.d: Run ld with --hash-style=sysv.
    	* testsuite/ld-cris/dso-pltdis2.d,
    	testsuite/ld-cris/dso12-pltdis.d, testsuite/ld-cris/expdyn1.d,
    	testsuite/ld-cris/expdyn5.d, testsuite/ld-cris/expdyn6.d,
    	testsuite/ld-cris/expdyn7.d, testsuite/ld-cris/gotplt1.d,
    	testsuite/ld-cris/gotplt2.d, testsuite/ld-cris/gotplt3.d,
    	testsuite/ld-cris/hiddef1.d, testsuite/ld-cris/libdso-11.d,
    	testsuite/ld-cris/libdso-12.d, testsuite/ld-cris/libdso-12b.d,
    	testsuite/ld-cris/libdso-12c.d, testsuite/ld-cris/libdso-13.d,
    	testsuite/ld-cris/libdso-13b.d, testsuite/ld-cris/libdso-14.d,
    	testsuite/ld-cris/libdso-15.d, testsuite/ld-cris/libdso-15b.d,
    	testsuite/ld-cris/libdso-1b.d, testsuite/ld-cris/libdso-1c.d,
    	testsuite/ld-cris/libdso-1d.d, testsuite/ld-cris/libdso-4.d,
    	testsuite/ld-cris/pr16044.d, testsuite/ld-cris/pv32-1.d,
    	testsuite/ld-cris/tls-dso-dtpoffd2.d,
    	testsuite/ld-cris/tls-dso-dtpoffd4.d,
    	testsuite/ld-cris/tls-dso-tpoffgotcomm1.d,
    	testsuite/ld-cris/tls-dso-x1x2-1.d, testsuite/ld-cris/tls-gc-71.d,
    	testsuite/ld-cris/tls-ie-78.d, testsuite/ld-cris/tls-js1.d,
    	testsuite/ld-cris/tls-ldgdex-14.d,
    	testsuite/ld-cris/tls-ldgdex-15.d,
    	testsuite/ld-cris/tls-legdx-16.d,
    	testsuite/ld-cris/tls-legdx-17.d,
    	testsuite/ld-cris/tls-local-63.d,
    	testsuite/ld-cris/tls-local-64.d, testsuite/ld-cris/tls-ok-30.d,
    	testsuite/ld-cris/tls-ok-32.d, testsuite/ld-cris/tls-ok-34.d,
    	testsuite/ld-cris/tls-und-38.d, testsuite/ld-cris/tls-und-42.d,
    	testsuite/ld-cris/tls-und-46.d, testsuite/ld-cris/tls-und-50.d,
    	testsuite/ld-cris/weakref2.d, testsuite/ld-cris/weakref3.d,
    	testsuite/ld-cris/weakref4.d: Likewise.

commit 22e5c8027aef0cef99f7e215046e2f72eeda0347
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Aug 30 00:00:21 2017 +0000

    Automatic date update in version.in

commit d92b954dccde7f86eba4530449b1b011ec1a3725
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 16:00:18 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit 7755ddb77d227d1d5c1b211e989fafb17e26765d
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Aug 29 15:04:09 2017 -0700

    Look for FIR in the last FreeBSD/mips floating-point register.
    
    FreeBSD/mips kernels were recently changed to include the floating
    point implementation revision register in the floating point register
    set exported in process cores and via ptrace() (r318067).  This change
    will first ship in FreeBSD 12.0 when it is eventually released.  The
    space used to hold FIR was previously reserved in 'struct fpreg' as a
    zero-filled dummy for padding, so 'struct fpreg' has not changed in
    size.  Since FIR should be non-zero on all MIPS processors supported
    by FreeBSD, ignore a value of 0 from 'struct fpreg' and only report
    non-zero values as a valid FIR register.
    
    gdb/ChangeLog:
    
    	* mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
    	* mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
    	out of loop and add supply of FIR.
    	(mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
    	add collect of FIR.

commit 91f272733c34e002b1d64d5551644332b96d9d42
Merge: ae40e89 5f0f084
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 14:49:33 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 5f0f0847e23a57d4e95c2c639e803e6f51914efc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 14:44:40 2017 -0700

    x86: Re-indent elf32-i386.c/elf64-x86-64.c
    
    	* elf32-i386.c (elf_i386_pie_finish_undefweak_symbol):
    	Re-indent.
    	* elf64-x86-64.c (elf_x86_64_finish_local_dynamic_symbol):
    	Likewise.
    	(elf_x86_64_pie_finish_undefweak_symbol): Likewise.

commit ae40e89533b5bf297e5846526f597c7274a5c029
Merge: 32e5eaf 0afcef5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 13:44:54 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 0afcef5384c656b69706fed61d91f6d886c4c0f1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 28 06:23:25 2017 -0700

    Add elfxx-x86.h and elfxx-x86.c
    
    Move common codes in elf32-i386.c and elf64-x86-64.c to elfxx-x86.c.
    
    	* Makefile.am (BFD32_BACKENDS): Add elfxx-x86.lo.
    	(BFD64_BACKENDS): Likewise.
    	(BFD32_BACKENDS_CFILES): Add elfxx-x86.c.
    	(BFD64_BACKENDS_CFILES): Likewise.
    	* Makefile.in: Regenerated.
    	* configure.ac (bfd_backends): Add elfxx-x86.lo together with
    	elf32-i386.lo and elf64-x86-64.lo.
    	* configure: Regenerated.
    	* elf32-i386.c: Include "elfxx-x86.h" instead of "sysdep.h",
    	"bfd.h", "bfdlink.h", "libbfd.h", "elf-bfd.h", "bfd_stdint.h",
    	"objalloc.h" and "hashtab.h".
    	(ELIMINATE_COPY_RELOCS): Removed.
    	(UNDEFINED_WEAK_RESOLVED_TO_ZERO):Likewise.
    	(SYMBOL_NO_COPYRELOC): Likewise.
    	(elf_i386_link_hash_entry): Likewise.
    	(GOT_UNKNOWN): Likewise.
    	(GOT_NORMAL): Likewise.
    	(GOT_TLS_GD): Likewise.
    	(elf_i386_hash_entry): Likewise.
    	(elf_i386_obj_tdata): Likewise.
    	(elf_i386_tdata): Likewise.
    	(elf_i386_local_got_tls_type): Likewise.
    	(elf_i386_local_tlsdesc_gotent): Likewise.
    	(elf_i386_hash_table): Likewise.
    	(elf_i386_link_hash_newfunc): Likewise.
    	(elf_i386_local_htab_hash): Likewise.
    	(elf_i386_local_htab_eq): Likewise.
    	(elf_i386_get_local_sym_hash): Likewise.
    	(elf_i386_link_hash_table_free): Likewise.
    	(elf_i386_copy_indirect_symbol): Likewise.
    	(elf_i386_fixup_symbol): Likewise.
    	(elf_i386_readonly_dynrelocs): Likewise.
    	(elf_i386_always_size_sections): Likewise.
    	(elf_i386_set_tls_module_base): Likewise.
    	(elf_i386_dtpoff_base): Likewise.
    	(compare_relocs): Likewise.
    	(elf_i386_hash_symbol): Likewise.
    	(elf_i386_parse_gnu_properties): Likewise.
    	(elf_i386_merge_gnu_properties): Likewise.
    	(elf_i386_link_check_relocs): Likewise.
    	(elf_i386_merge_symbol_attribute): Likewise.
    	(bfd_elf32_bfd_link_check_relocs): Likewise.
    	(elf_backend_copy_indirect_symbol): Likewise.
    	(elf_backend_always_size_sections): Likewise.
    	(elf_backend_omit_section_dynsym): Likewise.
    	(elf_backend_hash_symbol): Likewise.
    	(elf_backend_fixup_symbol): Likewise.
    	(elf_backend_parse_gnu_properties): Likewise.
    	(elf_backend_merge_gnu_properties): Likewise.
    	(elf_backend_merge_symbol_attribute): Likewise.
    	(elf_i386_mkobject): Updated.
    	(elf_i386_link_hash_table_create): Likewise.
    	(elf_i386_check_tls_transition): Likewise.
    	(elf_i386_tls_transition): Likewise.
    	(elf_i386_convert_load_reloc): Likewise.
    	(elf_i386_check_relocs): Likewise.
    	(elf_i386_adjust_dynamic_symbol): Likewise.
    	(elf_i386_allocate_dynrelocs): Likewise.
    	(elf_i386_convert_load): Likewise.
    	(elf_i386_size_dynamic_sections): Likewise.
    	(elf_i386_relocate_section): Likewise.
    	(elf_i386_finish_dynamic_symbol ): Likewise.
    	(elf_i386_finish_dynamic_sections): Likewise.
    	(elf_i386_output_arch_local_syms): Likewise.
    	(elf_i386_get_synthetic_symtab): Likewise.
    	(elf_i386_link_setup_gnu_properties): Likewise.
    	(elf_i386_link_hash_table): Use elf_x86_link_hash_table, instead
    	of elf_link_hash_table, as base.
    	(elf_i386_next_tls_desc_index): New.
    	(elf_i386_srelplt2): Likewise.
    	(elf_i386_plt): Likewise.
    	(elf_i386_lazy_plt): Likewise.
    	(elf_i386_non_lazy_plt): Likewise.
    	* elf32-x86-64.c: Include "elfxx-x86.h" instead of "sysdep.h",
    	"bfd.h", "bfdlink.h", "libbfd.h", "elf-bfd.h", "bfd_stdint.h",
    	"objalloc.h" and "hashtab.h".
    	(ELIMINATE_COPY_RELOCS): Removed.
    	(UNDEFINED_WEAK_RESOLVED_TO_ZERO):Likewise.
    	(SYMBOL_NO_COPYRELOC): Likewise.
    	(elf_x86_64_link_hash_entry): Likewise.
    	(GOT_UNKNOWN): Likewise.
    	(GOT_NORMAL): Likewise.
    	(GOT_TLS_GD): Likewise.
    	(elf_x86_64_hash_entry): Likewise.
    	(elf_x86_64_obj_tdata): Likewise.
    	(elf_x86_64_tdata): Likewise.
    	(elf_x86_64_local_got_tls_type): Likewise.
    	(elf_x86_64_local_tlsdesc_gotent): Likewise.
    	(elf_x86_64_hash_table): Likewise.
    	(elf_x86_64_link_hash_newfunc): Likewise.
    	(elf_x86_64_local_htab_hash): Likewise.
    	(elf_x86_64_local_htab_eq): Likewise.
    	(elf_x86_64_get_local_sym_hash): Likewise.
    	(elf_x86_64_link_hash_table_free): Likewise.
    	(elf_x86_64_copy_indirect_symbol): Likewise.
    	(elf_x86_64_fixup_symbol): Likewise.
    	(elf_x86_64_readonly_dynrelocs): Likewise.
    	(elf_x86_64_always_size_sections): Likewise.
    	(elf_x86_64_set_tls_module_base): Likewise.
    	(elf_x86_64_dtpoff_base): Likewise.
    	(compare_relocs): Likewise.
    	(elf_x86_64_merge_symbol_attribute): Likewise.
    	(elf_x86_64_hash_symbol): Likewise.
    	(elf_x86_64_parse_gnu_properties): Likewise.
    	(elf_x86_64_merge_gnu_properties): Likewise.
    	(elf_x86_64_link_check_relocs): Likewise.
    	(elf_backend_copy_indirect_symbol): Likewise.
    	(elf_backend_always_size_sections): Likewise.
    	(bfd_elf64_bfd_link_check_relocs): Likewise.
    	(elf_backend_merge_symbol_attribute): Likewise.
    	(elf_backend_hash_symbol): Likewise.
    	(elf_backend_omit_section_dynsym): Likewise.
    	(elf_backend_fixup_symbol): Likewise.
    	(elf_backend_parse_gnu_properties): Likewise.
    	(elf_backend_merge_gnu_properties): Likewise.
    	(bfd_elf32_bfd_link_check_relocs): Likewise.
    	(elf_x86_64_mkobject): Updated.
    	(elf_x86_64_link_hash_table_create): Likewise.
    	(elf_x86_64_check_tls_transition): Likewise.
    	(elf_x86_64_tls_transition): Likewise.
    	(elf_x86_64_convert_load_reloc): Likewise.
    	(elf_x86_64_check_relocs): Likewise.
    	(elf_x86_64_adjust_dynamic_symbol): Likewise.
    	(elf_x86_64_allocate_dynrelocs): Likewise.
    	(elf_x86_64_convert_load): Likewise.
    	(elf_x86_64_size_dynamic_sections): Likewise.
    	(elf_x86_64_relocate_section): Likewise.
    	(elf_x86_64_finish_dynamic_symbol ): Likewise.
    	(elf_x86_64_finish_dynamic_sections): Likewise.
    	(elf_x86_64_output_arch_local_syms): Likewise.
    	(elf_x86_64_get_synthetic_symtab): Likewise.
    	(elf_x86_64_link_setup_gnu_properties): Likewise.
    	(elf_x86_64_link_hash_table): Use elf_x86_link_hash_table,
    	instead of elf_link_hash_table, as base.
    	(elf_x86_64_next_tls_desc_index): New.
    	(elf_x86_64_srelplt2): Likewise.
    	(elf_x86_64_plt): Likewise.
    	(elf_x86_64_lazy_plt): Likewise.
    	(elf_x86_64_non_lazy_plt): Likewise.
    	* elfxx-x86.c: New file.
    	* elfxx-x86.h: Likewise.

commit 823cb06774ad6a2aee0afcf6f011c3a134f25747
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 11:28:10 2017 -0700

    x86: Simplify bad return in get_synthetic_symtab
    
    	* elf32-i386.c (elf_i386_get_synthetic_symtab): Simplify bad
    	return.
    	* elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.

commit 37c0b6ee65941d54fa8064c21b39f97fdc318156
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 29 10:40:03 2017 -0700

    x86: Check valid PLT sections before checking dynamic relocations
    
    Update x86 get_synthetic_symtab to check valid PLT sections before
    checking dynamic relocations and free invalid PLT section contents.
    
    	* elf32-i386.c (elf_i386_get_synthetic_symtab): Check valid PLT
    	sections before checking dynamic relocations and free invalid
    	PLT section contents.
    	* elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.

commit 7ef3addbe195b6283d0baf59e081146dfb211c97
Author: Jozef Lawrynowicz <jozef.l@somniumtech.com>
Date:   Tue Aug 29 17:18:43 2017 +0100

    Improve MSP430 section placement.
    
    ld	* emultempl/msp430.em (change_output_section): New function.
    	(move_prefixed_section): New function.
    	(add_region_prefix): New function.
    	(msp430_elf_after_open): New function.
    	(gld${EMULATION_NAME}_add_options): Implement.
    	(gld${EMULATION_NAME}_list_options): Implement.
    	(gld${EMULATION_NAME}_handle_option): Implement.
    	* ld.texinfo: Document new options.
    	* testsuite/ld-msp430-elf/main-bss-lower.d: New.
    	* testsuite/ld-msp430-elf/main-bss-upper.d: New.
    	* testsuite/ld-msp430-elf/main-const-lower.d: New.
    	* testsuite/ld-msp430-elf/main-const-upper.d: New.
    	* testsuite/ld-msp430-elf/main-text-lower.d: New.
    	* testsuite/ld-msp430-elf/main-text-upper.d: New.
    	* testsuite/ld-msp430-elf/main-var-lower.d: New.
    	* testsuite/ld-msp430-elf/main-var-upper.d: New.
    	* testsuite/ld-msp430-elf/main-with-data-bss-unique-sec.s: New.
    	* testsuite/ld-msp430-elf/main-with-data-bss.s: New.
    	* testsuite/ld-msp430-elf/main-with-text-rodata-unique-sec.s: New.
    	* testsuite/ld-msp430-elf/main-with-text-rodata.s: New.
    	* testsuite/ld-msp430-elf/msp430-elf.exp: New.
    	* testsuite/ld-msp430-elf/msp430-no-lower.ld: New.
    	* testsuite/ld-msp430-elf/msp430.ld: New.
    	* emultempl/msp430.em (data_statement_size): New.
    	(eval_upper_either_sections): New.
    	(eval_lower_either_sections): New.
    	(intermediate_relax_sections): New.
    	(msp430_elf_after_allocation): New.
    	* emultempl/msp430.em (gld${EMULATION_NAME}_place_orphan): Always
    	place sections in the lower region.
    
    gas	* config/tc-msp430.c (md_parse_option): Define high data and high
    	bss symbols if -mdata-region is passed.
    	Define -mdata-region open.
    	* doc/c-msp430.texi: Document -mdata-region.
    	* testsuite/gas/msp430/high-data-bss-sym.d: New test.
    	* testsuite/gas/msp430/high-data-bss-sym.s: New.
    	* testsuite/gas/msp430/msp430.exp: Add -mdata-region tests.

commit 3819af136deb7ba6bc2058d7848cf80b33dbe51c
Author: Jozef Lawrynowicz <jozef.l@somniumtech.com>
Date:   Tue Aug 29 14:09:58 2017 +0100

    Fix simulation of MSP430's open system call.
    
    	* sim/msp430/msp430-sim.c (maybe_perform_syscall): Fix passing of
    	arguments for variadic syscall "open".

commit 34e0882b83aedc6fb9c7532c89afaf8e0043b7ce
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 29 15:55:33 2017 +0930

    [GOLD] PowerPC tls_get_addr_optimize
    
    This implements the special __tls_get_addr_opt call stub for powerpc
    gold that returns __thread variable addresses without actually making
    a call to __tls_get_addr in most cases.  Shared libraries that are
    loaded at program load time (ie. dlopen is not used) have a known
    layout for their __thread variables, and thus DTPMOD64/DPTREL64 pairs
    describing those variables can be set up by ld.so for the
    __tls_get_addr_opt call stub fast exit.
    Ref https://sourceware.org/ml/libc-alpha/2015-03/msg00626.html
    
    I really, really wish I'd used a differently versioned __tls_get_addr
    symbol than the base symbol to indicate glibc support for the
    optimized call, rather than having glibc export __tls_get_addr_opt.  A
    lot of the messing around here, flipping symbols from __tls_get_addr
    to __tls_get_addr_opt, is caused by that decision.  About the only
    benefit is that a user can see at a glance that their disassembled
    code is calling __tls_get_addr via the fancy call stub..  Anyway, we
    need references to __tls_get_addr to seem like they were to
    __tls_get_addr_opt, and in cases like the tsan interceptor, a
    definition of __tls_get_addr to seem like one of __tls_get_addr_opt
    as well.  That's the reason for Symbol::clear_in_reg and
    Symbol_table::clone, and why symbols are substituted in Scan::global
    and other places dealing with dynamic linking.
    
    elfcpp/
    	* elfcpp.h (DT_PPC_OPT): Define.
    	* powerpc.h (PPC_OPT_TLS): Define.
    gold/
    	* options.h (tls_get_addr_optimize): New option.
    	* symtab.h (Symbol::clear_in_reg, clone): New functions.
    	(Sized_symbol::clone): New function.
    	(Symbol_table::clone): New function.
    	* resolve.cc (Symbol::clone, Sized_symbol::clone): New functions.
    	* powerpc.cc (Target_powerpc::has_tls_get_addr_opt_,
    	tls_get_addr_, tls_get_addr_opt_): New vars.
    	(Target_powerpc::tls_get_addr_opt, tls_get_addr,
    	is_tls_get_addr_opt, replace_tls_get_addr,
    	set_has_tls_get_addr_opt, stk_linker): New functions.
    	(Target_powerpc::Track_tls::maybe_skip_tls_get_addr_call): Add
    	target param.  Update callers.  Compare symbols rather than names.
    	(Target_powerpc::do_define_standard_symbols): Init tls_get_addr_
    	and tls_get_addr_opt_.
    	(Target_powerpc::Branch_info::mark_pltcall): Translate tls_get_addr
    	sym to tls_get_addr_opt.
    	(Target_powerpc::Branch_info::make_stub): Likewise.
    	(Stub_table::define_stub_syms): Likewise.
    	(Target_powerpc::Scan::global): Likewise.
    	(Target_powerpc::Relocate::relocate): Likewise.
    	(add_3_12_2, add_3_12_13, bctrl, beqlr, cmpdi_11_0, cmpwi_11_0,
    	ld_11_1, ld_11_3, ld_12_3, lwz_11_3, lwz_12_3, mr_0_3, mr_3_0,
    	mtlr_11, std_11_1): New constants.
    	(Stub_table::eh_frame_added_): Delete.
    	(Stub_table::tls_get_addr_opt_bctrl_, plt_fde_len_, plt_fde_): New vars.
    	(Stub_table::init_plt_fde): New functions.
    	(Stub_table::add_eh_frame, replace_eh_frame): Move definition out
    	of line.  Init and use plt_fde_.
    	(Stub_table::plt_call_size): Return size for tls_get_addr stub.
    	Extract alignment code to..
    	(Stub_table::plt_call_align): ..this new function.  Adjust all callers.
    	(Stub_table::add_plt_call_entry): Set has_tls_get_addr_opt and
    	tls_get_addr_opt_bctrl, and align after that.
    	(Stub_table::do_write): Write out tls_get_addr stub.
    	(Target_powerpc::do_finalize_sections): Emit DT_PPC_OPT
    	PPC_OPT_TLS/PPC64_OPT_TLS bit.
    	(Target_powerpc::Relocate::relocate): Don't check for or modify
    	nop following bl for tls_get_addr stub.

commit 34ca2bd7ace5e208d46fea6e7a56a5376de0abfe
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 29 15:52:45 2017 +0930

    [GOLD] Reduce size of class Symbol
    
    On 64-bit targets there is a 32-bit hole in symbol->u_, and another
    due to symbol flags exceeding 32 bits.  By splitting the union,
    the total size of the class reduces by one 64-bit word.
    
    	* symtab.h (Symbol): Split u_ into u1_ and u2_.  Adjust accessors
    	to suit.  Move plt_offset_ before got_offsets_.
    	* symtab.cc (Symbol::init_fields): Adjust for union change.
    	(Symbol::init_base_output_data): Likewise.
    	(Symbol::init_base_output_segment): Likewise.
    	(Symbol::allocate_base_common): Likewise.
    	(Symbol::output_section): Likewise.
    	(Symbol::set_output_section): Likewise.
    	(Symbol::set_output_segment): Likewise.
    	* resolve.cc (Symbol::override_base): Likewise.
    	(Symbol::override_base_with_special): Likewise.

commit f2d394fce1f37a07148719c4bc919ca7b7a0b025
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Aug 29 00:01:09 2017 +0000

    Automatic date update in version.in

commit 972d8a18db78974f59e1a6b1dc02f7e5b7d226d2
Author: Han Shen <shenhan@google.com>
Date:   Mon Aug 28 16:36:45 2017 -0700

    2017-08-28  James Clarke <jrtc27@jrtc27.com>
    
    gold/ChangeLog:
    	PR gold/21868
    	* aarch64.cc (AArch64_relobj::try_fix_erratum_843419_optimized):
    	Add extra view offset argument to function.
    	(AArch64_relobj::fix_errata_and_relocate_erratum_stubs): Add
    	extra view offset set to the output offset when the view has
    	is_input_output_view set, since it has not already been
    	included. Pass this to try_fix_erratum_843419_optimized.

commit 0fb0a7677827aea3e7ca1fdb2dfd1ccbdf6c2f71
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 28 15:40:00 2017 -0700

    Remove unused _bfd_elf_ifunc_get_synthetic_symtab
    
    Since _bfd_elf_ifunc_get_synthetic_symtab is no longer called by x86
    get_synthetic_symtab, it is now unused.  This patch removes it.
    
    	* elf-bfd.h (_bfd_elf_ifunc_get_synthetic_symtab): Removed.
    	* elf-ifunc.c (_bfd_elf_ifunc_get_synthetic_symtab): Likewise.

commit 5e89eb3ab04a378133ff3da1ed23d4bd89a56b5e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Aug 28 23:39:18 2017 +0200

    gdb.base/commands.exp: Remove unused global references
    
    There are a few unused references to the gdb_prompt global.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/commands.exp (gdbvar_simple_if_test,
    	gdbvar_simple_if_test, gdbvar_complex_if_while_test,
    	progvar_simple_if_test, progvar_simple_while_test,
    	progvar_complex_if_while_test, user_defined_command_test,
    	user_defined_command_args_eval,
    	user_defined_command_args_stack_test,
    	user_defined_command_manyargs_test, bp_deleted_in_command_test,
    	temporary_breakpoint_commands,
    	gdb_test_no_prompt, redefine_hook_test,
    	redefine_backtrace_test): Remove "global gdb_prompt".

commit 3804a3431ae02bfedfa1347864444d9520161604
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Aug 28 23:09:04 2017 +0200

    Add missing PR number in ChangeLog
    
    This should have been included in the previous commit.

commit fd437cbc432d5421492a5b0e371750de104cce93
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Aug 28 23:05:04 2017 +0200

    define_command: Don't convert command name to lower case
    
    Commit
    
      Command names: make them case sensitive
      3d7b173c29900879c9a5958dd6029fd36666e57c
    
    made command name lookup case sensitive.  However, define_command, used
    when creating a user-defined command, converts the command name to
    lowercase, assuming that the command name lookup works in a case
    insensitive way.  This causes user-defined commands with capital letters
    in their name to only be callable with a lowercase version:
    
      (gdb) define Foo
      Type commands for definition of "Foo".
      End with a line saying just "end".
      >print 1
      >end
      (gdb) Foo
      Undefined command: "Foo".  Try "help".
      (gdb) foo
      $1 = 1
    
    This patch removes that conversion to lowercase, so that the user can
    call the command with the same name they provided.
    
    gdb/ChangeLog:
    
    	* cli/cli-script.c (define_command): Don't convert command name
    	to lower case.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.base/commands.exp (user_defined_command_case_sensitivity):
    	New proc, call it from toplevel.

commit 90efb6422939ca031804266fba669f77c22a274a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 28 11:25:58 2017 -0700

    x86: Check for valid PLT section size
    
    Update x86 get_synthetic_symtab to check for valid PLT section size
    before examining PLT section contents.
    
    	PR binutils/22018
    	* elf32-i386.c (elf_i386_get_synthetic_symtab): Check for valid
    	PLT section size.
    	* elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.

commit cefdd1cd64f3b67aba1b219547b8f895c22d48ed
Author: Igor Kudrin <ikudrin@accesssoftek.com>
Date:   Mon Aug 28 08:03:00 2017 -0700

    Fix bad offset calculation for R_AARCH64_TLSDESC_* relocs.
    
    If a custom linker script with an unexpected relative layout of .got
    and .got.plt sections was used, gold might produce a wrong offset
    when applying R_AARCH64_TLSDESC_* relocations.
    This patch fixes the issue by calculating "got_tlsdesc_offset"
    in a more direct way.
    
    gold/
    	* aarch64.cc (Target_aarch64::Relocate::relocate_tls):
    	Make got_tlsdesc_offset signed and fix its calculation.
    	* testsuite/Makefile.am (aarch64_tlsdesc): New test.
    	* testsuite/Makefile.in: Regenerate.
    	* testsuite/aarch64_tlsdesc.s: New test source file.
    	* testsuite/aarch64_tlsdesc.sh: New test script.
    	* testsuite/aarch64_tlsdesc.t: New test linker script.

commit 565ed01a4e0e3584f24580177822a5271b1c0c8b
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Aug 28 16:27:33 2017 +0930

    [GOLD] Symbol flag for PowerPC64 localentry:0 tracking
    
    This patch provides a flag for PowerPC64 ELFv2 use in class Symbol,
    and modifies Sized_target::resolve to return whether the symbol has
    been resolved.  If not, normal processing continues.  I use this for
    PowerPC64 ELFv2 to keep track of whether a symbol has any definition
    with non-zero localentry, in order to disable --plt-localentry for
    that symbol.
    
    	PR 21847
    	* powerpc.cc (Target_powerpc::is_elfv2_localentry0): Test
    	non_zero_localentry.
    	(Target_powerpc::resolve): New function.
    	(powerpc_info): Set has_resolve for 64-bit.
    	* target.h (Sized_target::resolve): Return bool.
    	* resolve.cc (Symbol_table::resolve): Continue with normal
    	processing when target resolve returns false.
    	* symtab.h (Symbol::non_zero_localentry, set_non_zero_localentry):
    	New accessors.
    	(Symbol::non_zero_localentry_): New flag bit.
    	* symtab.cc (Symbol::init_fields): Init non_zero_localentry_.

commit 41e52377486950e32a1bc121e4c42abc8561aee5
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Aug 28 00:00:46 2017 +0000

    Automatic date update in version.in

commit 32e5eaf1da2a04a63c32be996bc4b0dacf1c4704
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 27 07:27:36 2017 -0700

    Don't apply "Disallow copy relocation against protected data symbol"
    
    It has been checked into master branch.

commit 4f41728e8a2b575c82fb5389d2cc9a0ef24b6497
Merge: ff995cc 596dc58
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 27 07:26:31 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 596dc58f33e20bd2784459dc0931e92922465444
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 27 07:23:40 2017 -0700

    x86: Initialize def_protected
    
    	* elf32-i386.c (elf_i386_link_hash_newfunc): Initialize
    	def_protected.
    	* elf64-x86-64.c (elf_x86_64_link_hash_newfunc): Likewise.

commit a5b4ee9451dc9ffb6aa29376fc03943c53c6da0d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Aug 26 19:22:26 2017 -0700

    Disallow copy relocation against protected data symbol
    
    We shpouldn't generate copy relocation to resolve reference to protected
    data symbol defined in shared object with the NO_COPY_ON_PROTECTED
    property.  This patch adds a bit to elf_obj_tdata as well as
    elf_i386_link_hash_entry and elf_x86_64_link_hash_entry to track the bfd
    with the NO_COPY_ON_PROTECTED property as well as protected symbol
    defined in shared object.  extern_protected_data is set to FALSE if any
    input relocatable file contains the NO_COPY_ON_PROTECTED property.
    
    bfd/
    
    	PR ld/21997
    	* elf-bfd.h (elf_obj_tdata): Use ENUM_BITFIELD on object_id,
    	dyn_lib_class and has_gnu_symbols.  Change bad_symtab to bitfield.
    	Add a has_no_copy_on_protected bitfield.
    	(elf_has_no_copy_on_protected): New.
    	* elf-properties.c (_bfd_elf_parse_gnu_properties): Set
    	elf_has_no_copy_on_protected for GNU_PROPERTY_NO_COPY_ON_PROTECTED.
    	(elf_merge_gnu_property_list): Likewise.
    	(_bfd_elf_link_setup_gnu_properties): Set extern_protected_data
    	to FALSE for elf_has_no_copy_on_protected.
    	* elf32-i386.c (SYMBOL_NO_COPYRELOC): New.
    	(elf_i386_link_hash_entry): Add def_protected.
    	(elf_i386_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
    	when checking info->nocopyreloc.
    	(elf_i386_link_setup_gnu_properties): Don't set
    	extern_protected_data here.
    	(elf_i386_merge_symbol_attribute): New function.
    	(elf_backend_merge_symbol_attribute): New.
    	* elf64-x86-64.c (SYMBOL_NO_COPYRELOC): New.
    	(elf_x86_64_link_hash_entry): Add def_protected.
    	(elf_x86_64_need_pic): Report protected symbol for def_protected.
    	(elf_x86_64_adjust_dynamic_symbol): Also check SYMBOL_NO_COPYRELOC
    	when checking info->nocopyreloc.
    	(elf_x86_64_relocate_section): Also check for R_X86_64_PC32
    	relocation run-time overflow and unresolvable R_X86_64_32S
    	relocation against protected data symbol defined in shared object
    	with GNU_PROPERTY_NO_COPY_ON_PROTECTED.
    	(elf_x86_64_link_setup_gnu_properties): Don't set
    	extern_protected_data here.
    	(elf_x86_64_merge_symbol_attribute): New function.
    	(elf_backend_merge_symbol_attribute): New.
    
    ld/
    
    	PR ld/21997
    	* testsuite/ld-i386/i386.exp: Run PR ld/21997 tests.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-i386/pr21997-1a.S: New file.
    	* testsuite/ld-i386/pr21997-1b.c: Likewise.
    	* testsuite/ld-i386/pr21997-1c.S: Likewise.
    	* testsuite/ld-x86-64/pr21997-1a.S: Likewise.
    	* testsuite/ld-x86-64/pr21997-1a.err: Likewise.
    	* testsuite/ld-x86-64/pr21997-1b.c: Likewise.
    	* testsuite/ld-x86-64/pr21997-1b.err: Likewise.
    	* testsuite/ld-x86-64/pr21997-1c.c: Likewise.

commit aecbb010f9d74b574ba89a64f45cde2407e53dab
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Aug 27 00:00:52 2017 +0000

    Automatic date update in version.in

commit ff995cc6153ef8e44214c090a5f8a71c357d749b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Aug 26 16:10:51 2017 -0700

    Update binutils-x86-gpoff.patch for PR ld/21997 fix

commit 4d94f73fc6006d7d42ae8b8b2954de6daf0801ee
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Aug 26 16:03:15 2017 -0700

    Revert "Update binutils-secondary.patch for PR ld/21997 fix"
    
    This reverts commit 1800161516f9fa3f4f2fe3664e1070904c8c762b.

commit f54b68c8c1823c6674a6da6e0d7dbfe50bb3e911
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Aug 26 16:02:10 2017 -0700

    Move def_protected to x86 link_hash_entry

commit 8609ae21ac44dd1dec2ffb1f681b280493a9fb6f
Merge: e4cab84 7c8bbca
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Aug 26 16:01:20 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 7c8bbca5e670b5ea44b61ff30c5c7fcec47ee405
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Aug 26 20:26:13 2017 +0930

    PowerPC TPREL reloc handling
    
    Tidy how these are handled in PIEs.
    
    	* elf32-ppc.c (must_be_dyn_reloc): Use bfd_link_dll.  Comment.
    	(ppc_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
    	(ppc_elf_relocate_section): Comment fix.
    	* elf64-ppc.c (must_be_dyn_reloc): Use bfd_link_dll.  Comment.
    	(ppc64_elf_check_relocs): Only set DF_STATIC_TLS in shared libs.
    	Support dynamic relocs for TPREL16 when non-pic too.
    	(dec_dynrel_count): Adjust TPREL16 handling as per check_relocs.
    	(ppc64_elf_relocate_section): Support dynamic relocs for TPREL16
    	when non-pic too.

commit 988f6b3dc615173d6d78a76ac26c109b4582da74
Author: Joel Brobecker <brobecker@adacore.com>
Date:   Fri Aug 25 19:23:27 2017 -0400

    remove param "dispp" from ada-lang.c::ada_lookup_struct_elt_type
    
    The function is always called with DISPP set to NULL, so there is
    no need for this parameter anymore. This patch removes it, and
    eliminates some dead code associated to that.
    
    gdb/ChangeLog:
    
            * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
            Update all callers accordingly. Remove all code blocks handling
            the case where DISPP is not NULL.
    
    Tested on x86_64-linux, no regression.

commit 5fdda9d6a4c3520f4787d96c4ae293783fe6262a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 25 17:13:58 2017 -0700

    x86: Remove redundant "symbol" in comments
    
    	* elf32-i386.c (elf_i386_link_hash_entry): Remove redundant
    	"symbol" in comments.
    	* elf64-x86-64.c (elf_x86_64_link_hash_entry): Likewise.

commit 7d5b8b81d33e3cda028d814737015a7efa6b5035
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Aug 26 00:01:04 2017 +0000

    Automatic date update in version.in

commit 6afd337d1a1a789b71d77b157529c08250eb9093
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Aug 25 10:45:33 2017 +0200

    gdbserver: Rename some functions, thread -> inferior
    
    These functions apply to thread, and not inferiors (in the gdbserver
    sense, the abstraction for threads and processes, as in
    inferior_list).  Therefore, it would make more sense if these functions
    were named with "thread" rather than "inferior".
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.h (inferior_target_data): Rename to ...
    	(thread_target_data): ... this.
    	(inferior_regcache_data): Rename to ...
    	(thread_regcache_data): ... this.
    	(set_inferior_regcache_data): Rename to ...
    	(set_thread_regcache_data): ... this.
    	* inferiors.c (inferior_target_data): Rename to ...
    	(thread_target_data): ... this.
    	(inferior_regcache_data): Rename to ...
    	(thread_regcache_data): ... this.
    	(set_inferior_regcache_data): Rename to ...
    	(set_thread_regcache_data): ... this.
    	(free_one_thread): Update.
    	* linux-low.h (get_thread_lwp): Update.
    	* regcache.c (get_thread_regcache): Update.
    	(regcache_invalidate_thread): Update.
    	(free_register_cache_thread): Update.
    	* win32-i386-low.c (update_debug_registers_callback): Update.
    	(win32_get_current_dr): Update.
    	* win32-low.c (thread_rec): Update.
    	(delete_thread_info): Update.
    	(continue_one_thread): Update.
    	(suspend_one_thread): Update.

commit 1445030f313d9b251a6a27c8bdf52197520396e2
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Aug 25 11:41:06 2017 +0930

    PR21994, readelf looping on verdefs
    
    	PR 21994
    	* readelf.c (process_version_sections <SHT_GNU_verdef>): Check
    	vd_aux and vda_next for sanity.  Delete "end".  Correct overflow
    	checks.
    	(process_version_sections <SHT_GNU_verneed>): Correct overflow
    	check.  Don't report invalid vna_next on overflow.  Do report
    	invalid vna_next on size less than aux info.

commit 176047c9f2ec8ccb4e0b6bfade4f21cb25d986e9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 17:45:24 2017 -0700

    ld: Add "--" after regexp
    
    Add "--" after regexp to support dejagnu 1.4.4.
    
    	* testsuite/ld-elf/pr21903c.d: Remove '\' before --.
    	* testsuite/ld-elf/pr21903d.d: Likewise.
    	* testsuite/ld-elf/pr21903e.d: Likewise.
    	* testsuite/lib/ld-lib.exp (run_dump_test): Add "--" after
    	regexp.

commit a2d64ef20ba133be3bff20d45494a65dec6503be
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Aug 25 00:01:00 2017 +0000

    Automatic date update in version.in

commit a160cc4628aa125959dc65983d805500fc58512c
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Thu Aug 24 23:34:33 2017 +0200

    Remove unused function set_inferior_target_data
    
    The inferior (thread) target data is always set through add_thread.
    
    gdb/gdbserver/ChangeLog:
    
    	* inferiors.c (set_inferior_target_data): Remove.
    	* inferiors.h (set_inferior_target_data): Remove.

commit e4cab84bedf40506cda6207968894d09f1a883d5
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 09:43:54 2017 -0700

    Don't include <asm/prctl.h> in Linux/i386 tests

commit 1800161516f9fa3f4f2fe3664e1070904c8c762b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 09:29:36 2017 -0700

    Update binutils-secondary.patch for PR ld/21997 fix

commit 3ae5934b2ad77faa5899243c9b2aae12670388a1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 09:29:01 2017 -0700

    Apply Disallow copy relocation against protected data symbol

commit 81e9b8c7a4f1b4c5cd18c63de9d30a430e58be5f
Merge: 649556f 074f606
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 09:21:55 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 649556fed44ff3b1919cfb9075a2f596bc722493
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 09:17:10 2017 -0700

    Don't apply binutils-pr21964.patch
    
    Leave __start/__stop symbols as PROTECTED.  Since there are no
    dynamic relocations against them, it should be harmless.

commit 074f6066845cb564751d4fa604e5f591c8265b41
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 08:33:16 2017 -0700

    ld: Replace regexp with string match
    
    Replace regexp with string match to workaround dejagnu 1.4.4 which
    complains:
    
    ERROR: bad switch "-fPIE": must be -all, -about, -indices, -inline, -expanded, -line, -linestop, -lineanchor, -nocase, -start, or --
    
    	* testsuite/ld-i386/i386.exp (undefined_weak): Replace regexp
    	with string match.
    	* testsuite/ld-x86-64/x86-64.exp (undefined_weak): Likewise.

commit 28e6a46bcb00e9972540e4d12a98cc3f6fbb9d87
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 07:53:41 2017 -0700

    x86-64: Run pr22001-1b on x32
    
    Run pr22001-1b on x32 since R_X86_64_32S relocation can be turned into
    dynamic R_X86_64_32 relocation which won't overflow on x32.
    
    	* testsuite/ld-x86-64/x86-64.exp: Run pr22001-1b on x32.

commit 663c44ac4d4336e99c282705b1d289b365b273d3
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Aug 24 16:39:11 2017 +0200

    DWARF-5 Fix DW_FORM_implicit_const
    
    -gdwarf-4:
    ptype logical
    type = const char [2]
    (gdb) PASS: gdb.base/constvars.exp: ptype logical
    
    -gdwarf-5:
    ptype logical
    type = const char []
    (gdb) FAIL: gdb.base/constvars.exp: ptype logical
    
     <2><2fc>: Abbrev Number: 1 (DW_TAG_variable)
        <2fd>   DW_AT_name        : (indirect string, offset: 0x2eb): logical
        <301>   DW_AT_decl_file   : 1
    
       1      DW_TAG_variable    [no children]
        DW_AT_name         DW_FORM_strp
        DW_AT_decl_file    DW_FORM_implicit_const: 1
    
    During symbol reading, invalid attribute class or form for
    'DW_FORM_implicit_const' in '(null)'.
    
    gdb/ChangeLog
    2017-08-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	PR symtab/22003
    	* dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
    	(dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
    	(skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.

commit 7073b5b9edc9e06974bd733b7e4b3845d6d6f690
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 06:34:19 2017 -0700

    x86-64: Check relocations with -z nocopyreloc
    
    On x86-64, when -z nocopyreloc is used to build executable, relocations
    may overflow at run-time or may not be resolved without PIC.  This patch
    checks these conditions and issues an error with suggestion for -fPIC.
    
    bfd/
    
    	PR ld/22001
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Check for
    	R_X86_64_PC32 relocation run-time overflow and unresolvable
    	R_X86_64_32S relocation with -z nocopyreloc.
    
    ld/
    
    	PR ld/22001
    	* testsuite/ld-i386/i386.exp: Run -z nocopyreloc tests.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* ld/testsuite/ld-i386/pr22001-1a.c: New file.
    	* ld/testsuite/ld-i386/pr22001-1b.c: Likewise.
    	* ld/testsuite/ld-i386/pr22001-1c.S: Likewise.
    	* ld/testsuite/ld-x86-64/pr22001-1a.c: Likewise.
    	* ld/testsuite/ld-x86-64/pr22001-1a.err: Likewise.
    	* ld/testsuite/ld-x86-64/pr22001-1b.c: Likewise.
    	* ld/testsuite/ld-x86-64/pr22001-1b.err: Likewise.
    	* ld/testsuite/ld-x86-64/pr22001-1c.c: Likewise.

commit 5b5f4e6f8cd250e07ec98278f7223e57b3d3bb0c
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Thu Aug 17 11:29:04 2017 +0100

    ld: Early detection of orphans we know will be discarded
    
    When processing an orphan section we first call lang_place_orphans, this
    function handles a few sections for which the behaviour is known COMMON
    sections, or sections marked as SEC_EXCLUDE.
    
    Any orphans that are not handled in lang_place_orphans are passed on to
    ldlang_place_orphan, this is where we decide where to put the orphan,
    and then call lang_add_section to perform the actual orphan placement.
    
    We previously had a larger set of checks at the start of the function
    lang_add_section to discard some sections that we _knew_ should not be
    added into the output file, this was where .group sections (in a final
    link) and .debug* sections (with --strip-debug) were dropped.
    
    The problem with dropping these sections at the lang_add_section stage
    is that a user might also be using --orphan-handling=error to prevent
    orphans.  If they are then they should not be get errors about sections
    that we know will be discarded, and which are not mentioned in the
    linker script.
    
    The solution proposed in this patch is to move the "will this section be
    discarded" check into a separate function, and use this in
    lang_place_orphans to have the early discard phase discard sections that
    we know should not be included in the output file.
    
    ld/ChangeLog:
    
    	PR 21961
    	* ldlang.c (lang_discard_section_p): New function.
    	(lang_add_section): Checks moved out into new function, which is
    	now called.
    	(lang_place_orphans): Call lang_discard_section_p instead of
    	duplicating some of the checks from lang_add_section.
    	* testsuite/ld-elf/orphan-11.d: New file.
    	* testsuite/ld-elf/orphan-11.ld: New file.
    	* testsuite/ld-elf/orphan-11.s: New file.
    	* testsuite/ld-elf/orphan-12.d: New file.
    	* testsuite/ld-elf/orphan-12.s: New file.

commit 34bb2571d40e1ca323a1b60e0827a25047890faa
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 24 03:33:42 2017 -0700

    Revert commit aab921adcb656e4eefcc7d0f14241f3d7504400e
    
    	* elf32-i386.c (elf_i386_check_relocs): Revert the last change.
    	Undefined symbols may not have a type.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.

commit f1902523c9b7941775a2c64af89de0f111b8924c
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Thu Aug 24 10:26:52 2017 +0200

    DWARF-5: Fix -fdebug-types-section
    
    GDB was now accessing as signatured_type memory allocated only by size of
    dwarf2_per_cu_data.
    
    gdb/ChangeLog
    2017-08-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf2read.c (build_type_psymtabs_reader): New prototype.
    	(process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
    	(read_comp_units_from_section): New parameter abbrev_section, use
    	read_and_check_comp_unit_head, allocate signatured_type if needed.
    	(create_all_comp_units): Update read_comp_units_from_section caller.

commit 74081948353b117fcbe870fc3cc9ebe0f18fdcf8
Author: Alexander Fedotov <alfedotov@gmail.com>
Date:   Wed Aug 23 18:08:46 2017 +0300

    [PowerPC VLE] Add SPE2 and EFS2 instructions support
    
    include/
    	* opcode/ppc.h:
    	(spe2_opcodes, spe2_num_opcodes): New.
    	(PPC_OPCODE_SPE2): New define.
    	(PPC_OPCODE_EFS2): Likewise.
    	(SPE2_XOP): Likewise.
    	(SPE2_XOP_TO_SEG): Likewise.
    opcodes/
    	* ppc-dis.c (ppc_mopt): Add PPC_OPCODE_SPE2 and
    	PPC_OPCODE_EFS2 flag to "e200z4" entry.
    	New entries efs2 and spe2.
    	Add PPC_OPCODE_SPE2 and PPC_OPCODE_EFS2 flag to "vle" entry.
    	(SPE2_OPCD_SEGS): New macro.
    	(spe2_opcd_indices): New.
    	(disassemble_init_powerpc): Handle SPE2 opcodes.
    	(lookup_spe2): New function.
    	(print_insn_powerpc): call lookup_spe2.
    	* ppc-opc.c (insert_evuimm1_ex0): New function.
    	(extract_evuimm1_ex0): Likewise.
    	(insert_evuimm_lt8): Likewise.
    	(extract_evuimm_lt8): Likewise.
    	(insert_off_spe2): Likewise.
    	(extract_off_spe2): Likewise.
    	(insert_Ddd): Likewise.
    	(extract_Ddd): Likewise.
    	(DD): New operand.
    	(EVUIMM_LT8): Likewise.
    	(EVUIMM_LT16): Adjust.
    	(MMMM): New operand.
    	(EVUIMM_1): Likewise.
    	(EVUIMM_1_EX0): Likewise.
    	(EVUIMM_2): Adjust.
    	(NNN): New operand.
    	(VX_OFF_SPE2): Likewise.
    	(BBB): Likewise.
    	(DDD): Likewise.
    	(VX_MASK_DDD): New mask.
    	(HH): New operand.
    	(VX_RA_CONST): New macro.
    	(VX_RA_CONST_MASK): Likewise.
    	(VX_RB_CONST): Likewise.
    	(VX_RB_CONST_MASK): Likewise.
    	(VX_OFF_SPE2_MASK): Likewise.
    	(VX_SPE_CRFD): Likewise.
    	(VX_SPE_CRFD_MASK VX): Likewise.
    	(VX_SPE2_CLR): Likewise.
    	(VX_SPE2_CLR_MASK): Likewise.
    	(VX_SPE2_SPLATB): Likewise.
    	(VX_SPE2_SPLATB_MASK): Likewise.
    	(VX_SPE2_OCTET): Likewise.
    	(VX_SPE2_OCTET_MASK): Likewise.
    	(VX_SPE2_DDHH): Likewise.
    	(VX_SPE2_DDHH_MASK): Likewise.
    	(VX_SPE2_HH): Likewise.
    	(VX_SPE2_HH_MASK): Likewise.
    	(VX_SPE2_EVMAR): Likewise.
    	(VX_SPE2_EVMAR_MASK): Likewise.
    	(PPCSPE2): Likewise.
    	(PPCEFS2): Likewise.
    	(vle_opcodes): Add EFS2 and some missing SPE opcodes.
    	(powerpc_macros): Map old SPE instructions have new names
    	with the same opcodes. Add SPE2 instructions which just are
    	mapped to SPE2.
    	(spe2_opcodes): Add SPE2 opcodes.
    gas/
    	* config/tc-ppc.c:
    	(md_parse_option): Add mspe2 switch.
    	(md_show_usage): Document -mspe2.
    	(ppc_setup_opcodes): Handle spe2_opcodes.
    	* doc/as.texinfo: Document -mspe2.
    	* doc/c-ppc.texi: Likewise.
    	* testsuite/gas/ppc/efs.d: New file.
    	* testsuite/gas/ppc/efs.s: Likewise.
    	* testsuite/gas/ppc/efs2.d: Likewise.
    	* testsuite/gas/ppc/efs2.s: Likewise.
    	* testsuite/gas/ppc/ppc.exp: Run new tests.
    	* testsuite/gas/ppc/spe.d: New file.
    	* testsuite/gas/ppc/spe.s: Likewise.
    	* testsuite/gas/ppc/spe2-checks.d: Likewise.
    	* testsuite/gas/ppc/spe2-checks.l: Likewise.
    	* testsuite/gas/ppc/spe2-checks.s: Likewise.
    	* testsuite/gas/ppc/spe2.d: Likewise.
    	* testsuite/gas/ppc/spe2.s: Likewise.
    	* testsuite/gas/ppc/spe_ambiguous.d: Likewise.
    	* testsuite/gas/ppc/spe_ambiguous.s: Likewise.

commit 647d4de92e061a3a2be83740d7f1bf63e5669630
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 24 09:26:37 2017 +0930

    Test undefined symbols in shared libraries
    
    git commit 46434633f9 said
        Make undefined symbols in allocate_dynrelocs dynamic
    
        ..if they have dynamic relocs.  An undefined symbol in a PIC object
        that finds no definition ought to become dynamic in order to support
        --allow-shlib-undefined, but there is nothing in the generic ELF
        linker code to do this if the reference isn't via the GOT or PLT.  (An
        initialized function pointer is an example.)  So it falls to backend
        code to ensure the symbol is made dynamic.
    
    The above isn't true.  Undefined symbols are indeed made dynamic for
    shared libraries.  Undefined symbols are not automatically made
    dynamic in executables, and it was the PIE case that triggered an
    internal consistency assertion on powerpc64.  I guess I could have
    jumped the other way when fixing PR21988, and not created a dynamic
    reloc.  Either way, it doesn't matter a great deal.  We're going to
    get an error on strong undefined symbols in an executable anyway, and
    broken binaries if you try to use --unresolved-symbols=ignore-all to
    disable the error.
    
    	* testsuite/ld-undefined/fundef.s: New test.
    	* testsuite/ld-undefined/undefined.exp: Test that undefined
    	symbols in shared libraries are made dynamic.

commit f8d31560e1f64ea35a4e6b67c2834c5f89ffef20
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Aug 24 00:00:38 2017 +0000

    Automatic date update in version.in

commit 49263c56bbc622d5a42cfd37b4f5fb6863cd7d24
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 16:01:22 2017 -0700

    Update PR ld/21903 tests for dejagnu 1.4.4
    
    Add '\' before -- to workaround dejagnu 1.4.4 which complains:
    
    ERROR: bad switch "--no-define-common may not be used without -shared":...
    
    	* testsuite/ld-elf/pr21903c.d: Add '\' before --.
    	* testsuite/ld-elf/pr21903d.d: Likewise.
    	* testsuite/ld-elf/pr21903e.d: Likewise.

commit 87215ad1651ca3094d813eae06233fd7259b37e5
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Tue Aug 22 08:52:44 2017 -0400

    Fix PR remote/21852: Remote run without specifying a local binary crashes GDB
    
    There is an assertion that is triggering when we start GDB and
    instruct it to debug a remote inferior, but don't provide a local
    binary, like:
    
      ./gdb -nx -q --data-directory=data-directory -ex "tar ext :1234" \
        -ex "set remote exec-file /bin/ls" -ex r
    
    In this case, when calling exec_file_locate_attach to locate the
    inferior, GDB is incorrectly resetting the breakpoints without a
    thread/inferior even running, which causes an assertion to be
    triggered:
    
      binutils-gdb/gdb/thread.c:1609: internal-error: scoped_restore_current_thread::scoped_restore_current_thread(): Assertion `tp != NULL' failed.
      A problem internal to GDB has been detected,
      further debugging may prove unreliable.
      Quit this debugging session? (y or n)
    
    This happens because add_current_inferior_and_thread (on remote.c) is
    breaking an invariant: making inferior_ptid point to a non-existing
    thread and then calling common code, which in this case is
    breakpoint_re_set.  The fix is to make sure that inferior_ptid points
    to null_ptid if there is no thread present.
    
    A testcase is provided.  Regtested on buildbot.
    
    gdb/ChangeLog:
    2017-08-23  Pedro Alves  <palves@redhat.com>
    
    	PR remote/21852
    	* remote.c (add_current_inferior_and_thread): Set inferior_ptid
    	to null_ptid and switch to thread without reading the registers
    	after adding the inferior.
    
    gdb/testsuite/ChangeLog:
    2017-08-23  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR remote/21852
    	* gdb.server/normal.c: New file, copied from gdb.base.
    	* gdb.server/run-without-local-binary.exp: New file.

commit aab921adcb656e4eefcc7d0f14241f3d7504400e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 13:40:49 2017 -0700

    x86-64: Properly report output type when PIC is needed
    
    -fPIC may be needed to compile PIE or PDE objects, not just shared
    object.
    
    bfd/
    
    	* elf64-x86-64.c (elf_x86_64_need_pic): Add an argument for
    	bfd_link_info.  Report shared, PIE or PDE object based on
    	bfd_link_info.
    	(elf_x86_64_check_relocs): Update elf_x86_64_need_pic call.
    	(elf_x86_64_relocate_section): Likewise.
    
    ld/
    
    	* testsuite/ld-x86-64/pie2.d: Updated.
    	* testsuite/ld-x86-64/pr19719.d: Likewise.
    	* testsuite/ld-x86-64/pr19807-2a.d: Likewise.
    	* testsuite/ld-x86-64/pr19969.d: Likewise.

commit b1bb697ea1259c0977c38f1ec5f2239cbe669869
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 13:12:04 2017 -0700

    x86: Increment PLT count only for function symbols
    
    Since PLT entry is needed only for function symbols, increment PLT count
    only for function symbols.
    
    	* elf32-i386.c (elf_i386_check_relocs): Increment PLT count only
    	for function symbols.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.

commit 842bba4cf4460cc8a827b25727379b41191101e3
Merge: 1c12d34 73784fa
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 10:55:03 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 73784fa565bd66f1ac165816c03e5217b7d67bbc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 10:15:39 2017 -0700

    x86: Clear extern_protected_data for GNU_PROPERTY_NO_COPY_ON_PROTECTED
    
    When GNU_PROPERTY_NO_COPY_ON_PROTECTED is set, it indicates that there
    are no copy relocations against protected data symbols.  When linker
    sees GNU_PROPERTY_NO_COPY_ON_PROTECTED on any input relocatable file,
    it sets extern_protected_data to FALSE.
    
    bfd/
    
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): Set
    	extern_protected_data to FALSE if GNU_PROPERTY_NO_COPY_ON_PROTECTED
    	is set on any input relocatable file.
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.
    
    ld/
    
    	* testsuite/ld-i386/i386.exp: Run protected7.
    	* testsuite/ld-i386/protected7.d: New file.
    	* testsuite/ld-i386/protected7.s: Likewise.
    	* testsuite/ld-x86-64/protected8.d: Likewise.
    	* testsuite/ld-x86-64/protected8.s: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run protected8.

commit 6e41ddec97d402c6c150701da0f70d40bd6ed5ca
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Feb 21 13:32:56 2017 -0800

    compile: Add 'set compile-gcc'
    
    As discussed in
    	How to use compile & execute function in GDB
    	https://sourceware.org/ml/gdb/2015-04/msg00026.html
    
    GDB currently searches for compilers on /usr/bin/ARCH-OS-gcc and
    chooses a match from there.  However, it is not currently possible for
    the user to override which compiler to use.  This is what this patch
    implements.
    
    It is also a sync between GCC's and GDB's interfaces.
    
    gdb/ChangeLog
    2017-08-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* NEWS (Changes since GDB 7.9): Add set compile-gcc and show
    	compile-gcc.
    	* compile/compile.c (compile_gcc, show_compile_gcc): New.
    	(compile_to_object): Implement compile_gcc.
    	(_initialize_compile): Install "set compile-gcc".  Initialize
    	compile_gcc.
    
    gdb/doc/ChangeLog
    2017-08-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gdb.texinfo (Compiling and Injecting Code): Add to subsection
    	"Compiler search for the compile command" descriptions of set
    	compile-gcc and show compile-gcc.
    
    include/ChangeLog
    2017-08-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gcc-interface.h (enum gcc_base_api_version): Update comment for
    	GCC_FE_VERSION_1.
    	(struct gcc_base_vtable): Rename set_arguments to set_arguments_v0.
    	Add set_arguments, set_triplet_regexp and set_driver_filename.

commit e68c32d53e44ac0fe9f48637c0113da42b62644a
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Feb 21 13:32:55 2017 -0800

    compile: set debug compile: Display GCC driver filename
    
    As discussed in
    	How to use compile & execute function in GDB
    	https://sourceware.org/ml/gdb/2015-04/msg00026.html
    
    GDB currently searches for compilers on /usr/bin/ARCH-OS-gcc and
    chooses a match from there.  However, it is not currently possible for
    the user to display which compiler was selected.  Up until now, GDB's
    compiler interface was not up-to-date with GCC's one, which means that
    it wasn't possible to obtain this information.  This patch implements
    the mechanisms necessary for that.
    
    gdb/ChangeLog
    2017-08-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* compile/compile.c (compile_to_object): Conditionally call
    	set_verbose.  Conditionally call compile or compile_v0.
    
    include/ChangeLog
    2017-08-23  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* gcc-interface.h (enum gcc_base_api_version): Add
    	GCC_FE_VERSION_1.
    	(struct gcc_base_vtable): Rename compile to compile_v0.  Update
    	comment for compile.  New methods set_verbose and compile.

commit 1c12d3481fbc1791b105438df65c804a626efbf1
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 23 08:05:10 2017 -0700

    Update binutils-pr21964.patch against master branch

commit f6a36b0c9e537e4525f3b0687a4f76b4f77bf173
Author: James Clarke <jrtc27@jrtc27.com>
Date:   Wed Aug 23 05:46:45 2017 -0700

    gas: enable PC-relative diff relocations on sparc64
    
    gas/
    	* config/tc-sparc.c (tc_gen_reloc): Convert BFD_RELOC_8/16/32/64
    	into the corresponding BFD_RELOC_8/16/32/64_PCREL relocation
    	when requested.
    	* config/tc-sparc.h (DIFF_EXPR_OK): Define to enable PC-relative
    	diff relocations.
    	(TC_FORCE_RELOCATION_SUB_LOCAL): Define to ensure only supported
    	relocations are made PC-relative.
    	(CFI_DIFF_EXPR_OK): Define to 0 to force BFD_RELOC_32_PCREL to
    	be used directly, since otherwise BFD_RELOC_SPARC_UA32 will be
    	used for .eh_frame which cannot in general be converted to a
    	BFD_RELOC_32_PCREL due to alignment requirements.

commit b80c727008fc32d5271f3966be4e2a43badf8055
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 23 19:49:29 2017 +0930

    ppc-opc.c formatting
    
    	* ppc-opc.c: Formatting and comment fixes.  Move insert and
    	extract functions earlier, deleting forward declarations.
    	(insert_nbi, insert_raq, insert_rbx): Expand use of RT_MASK and
    	RA_MASK.

commit 452bf675ea772002aa86fb1d28f3474da70ee1de
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 23 15:42:12 2017 +0930

    PR21990, Integer overflow in process_version_sections
    
    This tidies some of the overflow checking when processing verneed
    and verdef sections.
    
    	PR 21990
    	* readelf.c (process_version_sections <SHT_GNU_verneed>): Check
    	for invalid vn_next field before adding to idx.  Use unsigned
    	long for index vars.  Move index checks.
    	<SHT_GNU_verdef>: Likewise for vd_next.

commit 58afddc6c7c5eaacdb68cdc3cacd0f76a3d01490
Author: Weimin Pan <weimin.pan@oracle.com>
Date:   Wed Aug 23 10:57:37 2017 +0200

    gdb: SPARC ADI support
    
    The M7 processor supports an Application Data Integrity (ADI) feature
    that detects invalid data accesses.  When software allocates data, it
    chooses a 4-bit version number, sets the version in the upper 4 bits
    of the 64-bit pointer to that data, and stores the 4-bit version in
    every cacheline of the object.  Hardware saves the latter in spare
    bits in the cache and memory hierarchy. On each load and store, the
    processor compares the upper 4 VA (virtual address) bits to the
    cacheline's version. If there is a mismatch, the processor generates a
    version mismatch trap which can be either precise or disrupting.  The
    trap is an error condition which the kernel delivers to the process as
    a SIGSEGV signal.
    
    The upper 4 bits of the VA represent a version and are not part of the
    true address.  The processor clears these bits and sign extends bit 59
    to generate the true address.
    
    Note that 32-bit applications cannot use ADI.
    
    This patch adds ADI support in gdb which allows the user to examine
    current version tags and assign new version tags in the program.  It
    also catches and reports precise or disrupting memory corruption
    traps.
    
    gdb/ChangeLog:
    2017-08-07  Weimin Pan  <weimin.pan@oracle.com>
    
    	* sparc64-tdep.h: (adi_normalize_address): New export.
    	* sparc-nat.h: (open_adi_tag_fd): New export.
    	* sparc64-linux-nat.c: (open_adi_tag_fd): New function.
    	* sparc64-linux-tdep.c:
    	(SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
    	(sparc64_linux_handle_segmentation_fault): New function.
    	(sparc64_linux_init_abi): Register
    	sparc64_linux_handle_segmentation_fault
    	* sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
    	(sparc64_addr_bits_remove): New function.
    	(sparc64_init_abi): Register sparc64_addr_bits_remove.
    	(MAX_PROC_NAME_SIZE): New macro.
    	(AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
    	(sparc64adilist): New variable.
    	(adi_proc_list): New variable.
    	(find_adi_info): New function.
    	(add_adi_info): New function.
    	(get_adi_info_proc): New function.
    	(get_adi_info): New function.
    	(info_adi_command): New function.
    	(read_maps_entry): New function.
    	(adi_available): New function.
    	(adi_normalize_address): New function.
    	(adi_align_address): New function.
    	(adi_convert_byte_count): New function.
    	(adi_tag_fd): New function.
    	(adi_is_addr_mapped): New function.
    	(adi_read_versions): New function.
    	(adi_write_versions): New function.
    	(adi_print_versions): New function.
    	(do_examine): New function.
    	(do_assign): New function.
    	(adi_examine_command): New function.
    	(adi_assign_command): New function.
    	(_initialize_sparc64_adi_tdep): New function.
    
    gdb/doc/ChangeLog:
    2017-08-07  Weimin Pan  <weimin.pan@oracle.com>
    
    	* gdb.texinfo (Architectures): Add new Sparc64 section to document
    	ADI support.
    	* NEWS: Add "adi examine" and "adi assign" commands.
    
    gdb/testsuite/ChangeLog:
    2017-08-07  Weimin Pan  <weimin.pan@oracle.com>
    
    	* gdb.arch/sparc64-adi.exp: New file.
    	* gdb.arch/sparc64-adi.c: New file.

commit 98973784dc4775dbce3470b0933d1cb13f8c5a87
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Aug 23 00:00:48 2017 +0000

    Automatic date update in version.in

commit 9d3420f5df5e14aa6ad43299d20b60652f0ed7cc
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 23 08:58:42 2017 +0930

    Remove pr19161 test hppa xfail
    
    	* testsuite/ld-gc/pr19161.d: Don't xfail hppa.

commit 46434633f9cee98afac1cf945ad00c9d4fdf5a4d
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 23 08:58:08 2017 +0930

    Make undefined symbols in allocate_dynrelocs dynamic
    
    ..if they have dynamic relocs.  An undefined symbol in a PIC object
    that finds no definition ought to become dynamic in order to support
    --allow-shlib-undefined, but there is nothing in the generic ELF
    linker code to do this if the reference isn't via the GOT or PLT.  (An
    initialized function pointer is an example.)  So it falls to backend
    code to ensure the symbol is made dynamic.
    
    	PR 21988
    	* elf64-ppc.c (ensure_undef_dynamic): Rename from
    	ensure_undefweak_dynamic.  Handle undefined too.
    	* elf32-ppc.c (ensure_undef_dynamic): Likewise.
    	* elf32-hppa.c (ensure_undef_dynamic): Likewise.
    	(allocate_dynrelocs): Discard undefined non-default visibility
    	relocs first.  Make undefined syms dynamic.  Tidy goto.

commit bb4b64b0dbe015a4b3fb3993273f8b9b0f8cb421
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 22 22:30:18 2017 +0930

    Assemble powerpc vle lsp tests with -a32
    
    -mvle isn't a valid 64-bit option.
    
    	* testsuite/gas/ppc/lsp-checks.d: Assemble with -a32.
    	* testsuite/gas/ppc/lsp.d: Likewise.

commit 11db943032396e1fee31440b0a331511dc0f4c00
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Tue Aug 22 22:09:55 2017 +0200

    Rename some command functions
    
    This patch renames a few functions implementing CLI commands to follow
    the style <command-name>_command, so that they are easier to search for.
    
    gdb/ChangeLog:
    
    	* breakpoint.c (breakpoints_info): Rename to ...
    	(info_breakpoints_command): ... this.
    	(watchpoints_info): Rename to ...
    	(info_watchpoints_command): ... this.
    	(tracepoints_info): Rename to ...
    	(info_tracepoints_command): ... this.
    	(_initialize_breakpoint): Adjust.
    	* dcache.c (dcache_info): Rename to ...
    	(info_display_command): ... this.
    	(_initialize_dcache): Adjust.
    	* frame.h (args_info): Rename to ...
    	(info_args_command): ... this.
    	(locals_info): Rename to ...
    	(info_locals_command): ... this.
    	* infcmd.c (nofp_registers_info): Rename to ...
    	(info_registers_command): ... this.
    	(float_info): Rename to ...
    	(info_float_command): ... this.
    	(program_info): Rename to ...
    	(info_program_command): ... this.
    	(all_registers_info): Rename to ...
    	(info_all_registers_command): ... this.
    	(vector_info): Rename to ...
    	(info_vector_command): ... this.
    	(float_info): Rename to ...
    	(info_float_command): ... this.
    	(_initialize_infcmd): Adjust.
    	* inferior.h (term_info): Rename to ...
    	(info_terminal_command): ... this.
    	* inflow.c (term_info): Rename to ...
    	(info_terminal_command): ... this.
    	(_initialize_inflow): Adjust.
    	* infrun.c (signals_info): Rename to ...
    	(info_signals_command): ... this.
    	(_initialize_infrun): Adjust.
    	* objc-lang.c (classes_info): Rename to ...
    	(info_classes_command): ... this.
    	(selectors_info): Rename to ...
    	(info_selectors_command): ... this.
    	(_initialize_objc_language): Adjust.
    	* printcmd.c (sym_info): Rename to ...
    	(info_symbol_command): ... this.
    	(address_info): Rename to ...
    	(info_address_command): ... this.
    	(display_info): Rename to ...
    	(info_display_command): ... this.
    	(_initialize_printcmd): Adjust.
    	* reverse.c (bookmarks_info): Rename to ...
    	(info_breakpoints_command): ... this.
    	(_initialize_reverse): Adjust.
    	* ser-go32.c (dos_info): Rename to ...
    	(info_serial_command): ... this.
    	(_initialize_ser_dos): Adjust.
    	* skip.c (skip_info): Rename to ...
    	(info_skip_command): ... this.
    	(_initialize_step_skip): Adjust.
    	* source.c (line_info): Rename to ...
    	(info_line_command): ... this.
    	(source_info): Rename to ...
    	(info_source_command)
    	* stack.c (frame_info): Rename to ...
    	(info_frame_command): ... this.
    	(locals_info): Rename to ...
    	(info_locals_command): ... this.
    	(args_info): Rename to ...
    	(info_args_command): ... this.
    	(_initialize_stack): Adjust.
    	* symtab.c (sources_info): Rename to ...
    	(info_sources_command): ... this.
    	(variables_info): Rename to ...
    	(info_variables_command): ... this.
    	(functions_info): Rename to ...
    	(info_functions_command): ... this.
    	(types_info): Rename to ...
    	(info_types_command): ... this.
    	(_initialize_symtab): Adjust.
    	* target.c (target_info): Rename to ...
    	(info_target_command): ... this.
    	(initialize_targets): Adjust.
    	* tracepoint.c (tvariables_info): Rename to ...
    	(info_tvariables_command): ... this.
    	(scope_info): Rename to ...
    	(info_scope_command): ... this.
    	(trace_dump_actions): Adjust.
    	(_initialize_tracepoint): Adjust.

commit 0e4b0361ad3a3208ad6480a23b898ab53a278666
Merge: 030e221 8dfb7cb
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 22 09:46:19 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 8dfb7cbf8401be97077f5919ac7473bdbfa8b692
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 22 09:41:21 2017 -0700

    Update PR ld/21964 tests
    
    	* testsuite/ld-elf/pr21964-1a.c (foo): Renamed to ...
    	(foo1): This.
    	* testsuite/ld-elf/pr21964-1b.c: Rewrite.
    	* testsuite/ld-elf/pr21964-1c.c: New file.
    	* testsuite/ld-elf/pr21964-2c.c: Likewise.
    	* testsuite/ld-elf/pr21964-2a.c (foo): Renamed to ...
    	(foo1): This.
    	* testsuite/ld-elf/pr21964-2b.c: Rewrite.
    	* testsuite/ld-elf/shared.exp: Update PR ld/21964 tests.

commit 67d888f5c801eeda240508c567775fc1d66ae178
Author: Palmer Dabbelt <palmer@dabbelt.com>
Date:   Tue Aug 1 14:13:05 2017 -0700

    RISC-V: Mark "c.nop" as an alias
    
    This fixes "-M noaliases" disassembly for "c.nop", which is an alias for
    "c.addi x0, 0".
    
    opcodes/ChangeLog
    
    2017-08-01  Palmer Dabbelt  <palmer@dabbelt.com>
    
            * riscv-opc.c (riscv_opcodes): Mark "c.nop" as an alias.

commit 5277199aeb328247d5d37ad6f34e4cf200fe42fa
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Aug 22 14:51:18 2017 +0100

    Add test for "List actual code around more than one location" change
    
    This adds a test for the "list" command change done in 0d999a6ef0f9
    ("List actual code around more than one location").
    
    gdb/ChangeLog:
    2017-08-22  Pedro Alves  <palves@redhat.com>
    
    	* gdb.cp/overload.exp (line_range_pattern): New procedure.
    	(top level): Add "list all overloads" tests.

commit b270e6f9e09814c82e198859f218b37118eaf098
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 19 22:26:20 2017 -0600

    Change install_breakpoint to take a std::unique_ptr
    
    This changes install_breakpoint to take a std::unique_ptr rvalue-ref
    argument.  This makes it clear that install_breakpoint takes ownership
    of the pointer, and prevents bugs like the one fixed by the previous
    patch.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.h (install_breakpoint): Update.
    	* breakpoint.c (add_solib_catchpoint): Update.
    	(install_breakpoint): Change argument to a std::unique_ptr.
    	(create_fork_vfork_event_catchpoint): Use std::unique_ptr.
    	(create_breakpoint_sal, create_breakpoint): Update.
    	(watch_command_1, catch_exec_command_1)
    	(strace_marker_create_breakpoints_sal): Use std::unique_ptr.
    	(add_to_breakpoint_chain): Change argument to a std::unique_ptr.
    	Return the breakpoint.
    	(set_raw_breakpoint_without_location, set_raw_breakpoint)
    	(new_single_step_breakpoint): Update.
    	* break-catch-throw.c (handle_gnu_v3_exceptions): Use
    	std::unique_ptr.
    	* break-catch-syscall.c (create_syscall_event_catchpoint): Use
    	std::unique_ptr.
    	* break-catch-sig.c (create_signal_catchpoint): Use
    	std::unique_ptr.
    	* ada-lang.c (create_ada_exception_catchpoint): Use
    	std::unique_ptr.

commit 36bd8eaaa0afe3ff8e8b1b1b9edc9686f5c159e6
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 19 22:15:30 2017 -0600

    Fix erroneous cleanup use in add_solib_catchpoint
    
    I happened to notice that add_solib_catchpoint allocated the new
    catchpoint with "new" but installed a cleanup using "xfree".  This
    patch fixes the bug by changing the function to use std::unique_ptr
    instead.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.

commit 56f37645249752378520a1c2430225c9cee09161
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 5 10:40:15 2017 -0600

    Change psymtab_search_name to return a unique_xmalloc_ptr
    
    This changes psymtab_search_name to return a unique_xmalloc_ptr and
    fixes up its one caller.  This allows the removal of some cleanups.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
    	(lookup_partial_symbol): Update.

commit 0b581c69fe7186d7d0ea1283c7ecf9839a8827cc
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 5 10:29:56 2017 -0600

    Change rewrite_source_path to return a unique_xmalloc_ptr
    
    This changes rewrite_source_path to return a unique_xmalloc_ptr and
    fixes up the callers.  This allows removing some cleanups.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
    	* source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
    	(find_and_open_source, symtab_to_fullname): Update.
    	* psymtab.c (psymtab_to_fullname): Update.

commit 14278e1fdbe045df184d6dd546ff6a1e9e3c3797
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Aug 3 16:53:22 2017 -0600

    Change gdb_realpath to return a unique_xmalloc_ptr
    
    This changes gdb_realpath to return a unique_xmalloc_ptr and fixes up
    the callers.  This allows removing some cleanups.  This change by
    itself caused xfullpath.exp to fail; and attempting to fix that ran
    into various problems (like .get() being optimized out); so this patch
    also rewrites xfullpath.exp to be a C++ selftest instead.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* exec.c (exec_file_attach): Update.
    	* linux-thread-db.c (try_thread_db_load): Update.
    	* guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
    	* utils.c (gdb_realpath): Change return type.
    	(gdb_realpath_keepfile): Update.
    	(gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
    	(_initialize_utils): Register the new self test.
    	* source.c (openp): Update.
    	(find_and_open_source): Update.
    	* nto-tdep.c (nto_find_and_open_solib): Update.
    	* main.c (set_gdb_data_directory): Update.
    	(captured_main_1): Update.
    	* dwarf2read.c (dwarf2_get_dwz_file): Update
    	(dw2_map_symbol_filenames): Update.
    	* auto-load.c (auto_load_safe_path_vec_update): Update.
    	(filename_is_in_auto_load_safe_path_vec): Change type of
    	"filename_realp".
    	(auto_load_objfile_script): Update.
    	(file_is_auto_load_safe): Update.  Use std::string.
    	* utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
    
    testsuite/ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* gdb.gdb/xfullpath.exp: Remove.

commit 4971c9a74b47103582834e46d0185390379e60b3
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Aug 3 16:34:56 2017 -0600

    Change gdb_realpath_keepfile to return a unique_xmalloc_ptr
    
    This changes gdb_realpath_keepfile to return a unique_xmalloc_ptr, and
    fixes up the callers.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (gdb_realpath_keepfile): Return a
    	gdb::unique_xmalloc_ptr.
    	* exec.c (exec_file_attach): Update.
    	* utils.h (gdb_realpath_keepfile): Return a
    	gdb::unique_xmalloc_ptr.

commit e3e41d588adbe26a6ca54338dd4915382d981a3e
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Aug 3 16:32:14 2017 -0600

    Change gdb_abspath to return a unique_xmalloc_ptr
    
    This changes gdb_abspath to return a unique_xmalloc_ptr, and fixes up
    the callers.  This allows the removal of a cleanup, and also puts
    ownership rules into the API, where they belong.
    
    ChangeLog
    2017-08-22  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile.c (compile_file_command): Use
    	gdb::unique_xmalloc_ptr, std::string.
    	* utils.c (gdb_abspath): Change return type.
    	* source.c (openp): Update.
    	* objfiles.c (allocate_objfile): Update.
    	* main.c (set_gdb_data_directory): Update.
    	* utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.

commit 0d999a6ef0f98b22430d70951408869864c979e0
Author: Zhouyi Zhou <zhouzhouyi@gmail.com>
Date:   Tue Aug 22 15:32:19 2017 +0100

    List actual code around more than one location
    
    With the following C++ code:
     int bar() { return 0;}
     int bar(int) { return 0; }
    
    GDB behaves as:
     (gdb) list bar
      file: "overload.cc", line number: 1
      file: "overload.cc", line number: 2
    
    It would be better for GDB to list the actual code around those two
    locations, not just print the location.  Like:
    
     (gdb) list bar
     file: "overload.cc", line number: 1
     1       int bar() { return 0;}
     2       int bar(int) { return 0; }
     file: "overload.cc", line number: 2
     1       int bar() { return 0;}
     2       int bar(int) { return 0; }
    
    That's what this this commit implements.
    
    Tested on x86-64 GNU/Linux.
    
    gdb/ChangeLog:
    2017-08-22  Zhouyi Zhou  <zhouzhouyi@gmail.com>
    
    	* cli-cmds.c (list_commands): List actual code around more than
    	one location.

commit 329d5e7e56f852dcf9956683be4345c165d277db
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Aug 21 09:35:25 2017 -0700

    Use an array type (lwpid_t[]) for the array of lwp IDs.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.

commit af3881e612908b6c0b1283c67d18312cd219ca13
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Aug 21 09:33:13 2017 -0700

    Correct earlier ChangeLog entry for fbsd_add_threads.

commit 487b6440dad57440939fab7afdd84a218b612796
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Aug 21 13:28:06 2017 +0930

    Make __start/__stop symbols protected visibility
    
    They can't be hidden visibility since apparently people use dlsym to
    look them up.
    
    bfd/
    	PR ld/21964
    	* elf-bfd.h (SYMBOLIC_BIND): Return TRUE for __start/__stop symbols.
    	* elflink.c (bfd_elf_define_start_stop): Rewrite.
    ld/
    	PR ld/21964
    	* testsuite/ld-elf/pr21562a.d: Update for changed start/stop symbols.
    	* testsuite/ld-elf/pr21562b.d: Likewise.
    	* testsuite/ld-elf/pr21562c.d: Likewise.
    	* testsuite/ld-elf/pr21562d.d: Likewise.
    	* testsuite/ld-elf/pr21562e.d: Likewise.
    	* testsuite/ld-elf/pr21562f.d: Likewise.
    	* testsuite/ld-elf/pr21562g.d: Likewise.
    	* testsuite/ld-elf/pr21562h.d: Likewise.
    	* testsuite/ld-elf/pr21562i.d: Likewise.
    	* testsuite/ld-elf/pr21562j.d: Likewise.
    	* testsuite/ld-elf/pr21562k.d: Likewise.
    	* testsuite/ld-elf/pr21562l.d: Likewise.
    	* testsuite/ld-elf/pr21562m.d: Likewise.
    	* testsuite/ld-elf/pr21562n.d: Likewise.
    	* testsuite/ld-elf/sizeofa.d: Likewise.
    	* testsuite/ld-elf/sizeofb.d: Likewise.
    	* testsuite/ld-elf/startofa.d: Likewise.
    	* testsuite/ld-elf/startofb.d: Likewise.
    	* testsuite/ld-gc/pr20022.d: Likewise.
    	* testsuite/ld-gc/start.d: Likewise.
    	* testsuite/ld-elf/pr21964-1a.c: New file.
    	* testsuite/ld-elf/pr21964-1b.c: New file.
    	* testsuite/ld-elf/pr21964-2a.c: New file.
    	* testsuite/ld-elf/pr21964-2b.c: New file.
    	* testsuite/ld-elf/shared.exp: Run PR ld/21964 tests.

commit e3c2f928b8f9afce6fdedaa1ddedfaa1d305aa9d
Author: Alexander Fedotov <alfedotov@gmail.com>
Date:   Mon Aug 21 15:45:59 2017 +0300

    [PowerPC VLE] Add LSP (Lightweight Signal Processing) instruction support
    
    include/
    	* opcode/ppc.h (PPC_OPCODE_LSP): New define.
    opcodes/
    	* ppc-opc.c (insert_evuimm2_ex0): New function.
    	(extract_evuimm2_ex0): Likewise.
    	(insert_evuimm4_ex0): Likewise.
    	(extract_evuimm4_ex0): Likewise.
    	(insert_evuimm8_ex0): Likewise.
    	(extract_evuimm8_ex0): Likewise.
    	(insert_evuimm_lt16): Likewise.
    	(extract_evuimm_lt16): Likewise.
    	(insert_rD_rS_even): Likewise.
    	(extract_rD_rS_even): Likewise.
    	(insert_off_lsp): Likewise.
    	(extract_off_lsp): Likewise.
    	(RD_EVEN): New operand.
    	(RS_EVEN): Likewise.
    	(RSQ): Adjust.
    	(EVUIMM_LT16): New operand.
    	(HTM_SI): Adjust.
    	(EVUIMM_2_EX0): New operand.
    	(EVUIMM_4): Adjust.
    	(EVUIMM_4_EX0): New operand.
    	(EVUIMM_8): Adjust.
    	(EVUIMM_8_EX0): New operand.
    	(WS): Adjust.
    	(VX_OFF): New operand.
    	(VX_LSP): New macro.
    	(VX_LSP_MASK): Likewise.
    	(VX_LSP_OFF_MASK): Likewise.
    	(PPC_OPCODE_LSP): Likewise.
    	(vle_opcodes): Add LSP opcodes.
    	* ppc-dis.c (ppc_mopt): Add PPC_OPCODE_LSP flag to "vle" entry.
    gas/
    	* testsuite/gas/ppc/lsp-checks.d,
    	* testsuite/gas/ppc/lsp-checks.l,
    	* testsuite/gas/ppc/lsp-checks.s: New test.
    	* testsuite/gas/ppc/lsp.d,
    	* testsuite/gas/ppc/lsp.s: New test.
    	* testsuite/gas/ppc/ppc.exp: Run new tests.

commit bf223d3e808e6fec9ee165d3d48beb74837796de
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Aug 21 11:34:32 2017 +0100

    Handle function aliases better (PR gdb/19487, errno printing)
    
    (Ref: https://sourceware.org/ml/gdb/2017-06/msg00048.html)
    
    This patch improves GDB support for function aliases defined with
    __attribute__ alias.  For example, in the test added by this commit,
    there is no reference to "func_alias" in the debug info at all, only
    to "func"'s definition:
    
     $ nm  ./testsuite/outputs/gdb.base/symbol-alias/symbol-alias  | grep " func"
     00000000004005ae t func
     00000000004005ae T func_alias
    
     $ readelf -w ./testsuite/outputs/gdb.base/symbol-alias/symbol-alias | grep func -B 1 -A 8
     <1><db>: Abbrev Number: 5 (DW_TAG_subprogram)
        <dc>   DW_AT_name        : (indirect string, offset: 0x111): func
        <e0>   DW_AT_decl_file   : 1
        <e1>   DW_AT_decl_line   : 27
        <e2>   DW_AT_prototyped  : 1
        <e2>   DW_AT_type        : <0xf8>
        <e6>   DW_AT_low_pc      : 0x4005ae
        <ee>   DW_AT_high_pc     : 0xb
        <f6>   DW_AT_frame_base  : 1 byte block: 9c         (DW_OP_call_frame_cfa)
        <f8>   DW_AT_GNU_all_call_sites: 1
    
    So all GDB knows about "func_alias" is from the minsym (elf symbol):
    
     (gdb) p func_alias
     $1 = {<text variable, no debug info>} 0x4005ae <func>
     (gdb) ptype func_alias
     type = int ()
    
     (gdb) p func
     $2 = {struct S *(void)} 0x4005ae <func>
     (gdb) ptype func
     type = struct S {
         int field1;
         int field2;
     } *(void)
    
    The result is that calling func_alias from the command line produces
    incorrect results.
    
    This is similar (though not exactly the same) to the glibc
    errno/__errno_location/__GI___errno_location situation.  On glibc,
    errno is defined like this:
    
      extern int *__errno_location (void);
      #define errno (*__errno_location ())
    
    with __GI___errno_location being an internal alias for
    __errno_location.  On my system's libc (F23), I do see debug info for
    __errno_location, in the form of name vs linkage name:
    
     <1><95a5>: Abbrev Number: 18 (DW_TAG_subprogram)
        <95a6>   DW_AT_external    : 1
        <95a6>   DW_AT_name        : (indirect string, offset: 0x2c26): __errno_location
        <95aa>   DW_AT_decl_file   : 1
        <95ab>   DW_AT_decl_line   : 24
        <95ac>   DW_AT_linkage_name: (indirect string, offset: 0x2c21): __GI___errno_location
        <95b0>   DW_AT_prototyped  : 1
        <95b0>   DW_AT_type        : <0x9206>
        <95b4>   DW_AT_low_pc      : 0x20f40
        <95bc>   DW_AT_high_pc     : 0x11
        <95c4>   DW_AT_frame_base  : 1 byte block: 9c       (DW_OP_call_frame_cfa)
        <95c6>   DW_AT_GNU_all_call_sites: 1
    
    however that doesn't matter in practice, because GDB doesn't record
    demangled names anyway, and so we end up with the exact same situation
    covered by the testcase.
    
    So the fix is to make the expression parser find a debug symbol for
    the same address as the just-found minsym, when a lookup by name
    didn't find a debug symbol by name.  We now get:
    
     (gdb) p func_alias
     $1 = {struct S *(void)} 0x4005ae <func>
     (gdb) p __errno_location
     $2 = {int *(void)} 0x7ffff6e92830 <__errno_location>
    
    I've made the test exercise variable aliases too, for completeness.
    Those already work correctly, because unlike for function aliases, GCC
    emits debug information for variable aliases.
    
    Tested on GNU/Linux.
    
    gdb/ChangeLog:
    2017-08-21  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/19487
    	* c-exp.y (variable production): Handle function aliases.
    	* minsyms.c (msymbol_is_text): New function.
    	* minsyms.h (msymbol_is_text): Declare.
    	* symtab.c (find_function_alias_target): New function.
    	* symtab.h (find_function_alias_target): Declare.
    
    gdb/testsuite/ChangeLog:
    2017-08-21  Pedro Alves  <palves@redhat.com>
    
    	PR gdb/19487
    	* gdb.base/symbol-alias.c: New.
    	* gdb.base/symbol-alias2.c: New.
    	* gdb.base/symbol-alias.exp: New.

commit c973d0aa4a2c737ab527ae44a617f1c357e07364
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Aug 21 11:34:32 2017 +0100

    Fix type casts losing typedefs and reimplement "whatis" typedef stripping
    
    (Ref: https://sourceware.org/ml/gdb/2017-06/msg00020.html)
    
    Assuming int_t is a typedef to int:
    
     typedef int int_t;
    
    gdb currently loses this expression's typedef:
    
     (gdb) p (int_t) 0
     $1 = 0
     (gdb) whatis $1
     type = int
    
    or:
    
     (gdb) whatis (int_t) 0
     type = int
    
    or, to get "whatis" out of the way:
    
     (gdb) maint print type (int_t) 0
     ...
     name 'int'
     code 0x8 (TYPE_CODE_INT)
     ...
    
    This prevents a type printer for "int_t" kicking in, with e.g.:
    
     (gdb) p (int_t) 0
    
    From the manual, we can see that that "whatis (int_t) 0" command
    invocation should have printed "type = int_t":
    
     If @var{arg} is a variable or an expression, @code{whatis} prints its
     literal type as it is used in the source code.  If the type was
     defined using a @code{typedef}, @code{whatis} will @emph{not} print
     the data type underlying the @code{typedef}.
     (...)
     If @var{arg} is a type name that was defined using @code{typedef},
     @code{whatis} @dfn{unrolls} only one level of that @code{typedef}.
    
    That one-level stripping is currently done here, in
    gdb/eval.c:evaluate_subexp_standard, handling OP_TYPE:
    
    ...
         else if (noside == EVAL_AVOID_SIDE_EFFECTS)
    	{
    	  struct type *type = exp->elts[pc + 1].type;
    
    	  /* If this is a typedef, then find its immediate target.  We
    	     use check_typedef to resolve stubs, but we ignore its
    	     result because we do not want to dig past all
    	     typedefs.  */
    	  check_typedef (type);
    	  if (TYPE_CODE (type) == TYPE_CODE_TYPEDEF)
    	    type = TYPE_TARGET_TYPE (type);
    	  return allocate_value (type);
    	}
    
    However, this stripping is reachable in both:
    
     #1 - (gdb) whatis (int_t)0     # ARG is an expression with a cast to
                                    # typedef type.
     #2 - (gdb) whatis int_t        # ARG is a type name.
    
    while only case #2 should strip the typedef.  Removing that code from
    evaluate_subexp_standard is part of the fix.  Instead, we make the
    "whatis" command implementation itself strip one level of typedefs
    when the command argument is a type name.
    
    We then run into another problem, also fixed by this commit:
    value_cast always drops any typedefs of the destination type.
    
    With all that fixed, "whatis (int_t) 0" now works as expected:
    
     (gdb) whatis int_t
     type = int
     (gdb) whatis (int_t)0
     type = int_t
    
    value_cast has many different exit/convertion paths, for handling many
    different kinds of casts/conversions, and most of them had to be
    tweaked to construct the value of the right "to" type.  The new tests
    try to exercise most of it, by trying castin of many different
    combinations of types.  With:
    
     $ make check TESTS="*/whatis-ptype*.exp */gnu_vector.exp */dfp-test.exp"
    
    ... due to combinatorial explosion, the testsuite results for the
    tests above alone grow like:
    
     - # of expected passes            246
     + # of expected passes            3811
    
    You'll note that the tests exposed one GCC buglet, filed here:
    
      Missing DW_AT_type in DW_TAG_typedef of "typedef of typedef of void"
      https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81267
    
    gdb/ChangeLog:
    2017-08-21  Pedro Alves  <palves@redhat.com>
    
    	* eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
    	typedefs.
    	* typeprint.c (whatis_exp): If handling "whatis", and expression
    	is OP_TYPE, strip one typedef level.  Otherwise don't strip
    	typedefs here.
    	* valops.c (value_cast): Save "to" type before resolving
    	stubs/typedefs.  Use that type as resulting value's type.
    
    gdb/testsuite/ChangeLog:
    2017-08-21  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/dfp-test.c
    	(d32_t, d64_t, d128_t, d32_t2, d64_t2, d128_t2, v_d32_t, v_d64_t)
    	(v_d128_t, v_d32_t2, v_d64_t2, v_d128_t2): New.
    	* gdb.base/dfp-test.exp: Add whatis/ptype/cast tests.
    	* gdb.base/gnu_vector.exp: Add whatis/ptype/cast tests.
    	* gdb.base/whatis-ptype-typedefs.c: New.
    	* gdb.base/whatis-ptype-typedefs.exp: New.
    	* gdb.python/py-prettyprint.c (int_type, int_type2): New typedefs.
    	(an_int, an_int_type, an_int_type2): New globals.
    	* gdb.python/py-prettyprint.exp (run_lang_tests): Add tests
    	involving typedefs and cast expressions.
    	* gdb.python/py-prettyprint.py (class pp_int_typedef): New.
    	(lookup_typedefs_function): New.
    	(typedefs_pretty_printers_dict): New.
    	(top level): Register lookup_typedefs_function in
    	gdb.pretty_printers.

commit 284d826d9f57e3ff47e41f61f3250c8d029baaa3
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Tue Jul 25 04:09:32 2017 +0200

    PR ld/20125, MMIX weak symbols
    
    Weak undefineds with PUSHJ relocs were "lost", causing internal
    inconsistencies and an abort.

commit 454c9bb956abd5451b6a46c96327c5ec0884eaed
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Aug 21 00:00:41 2017 +0000

    Automatic date update in version.in

commit 7f3d21db922ae120961f4e8e2cba7b8a919817c9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 20 06:25:52 2017 -0700

    Update testsuite/ld-x86-64/plt-main-bnd.dd
    
    2017-08-20  A. Wilcox  <awilfox@adelielinux.org>
    
    	PR ld/21976
    	* testsuite/ld-x86-64/plt-main-bnd.dd: Accept '_' in symbol
    	name.

commit 45aee2da6b48c72c55e40ed36fc089b7e29617b3
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Aug 20 00:00:47 2017 +0000

    Automatic date update in version.in

commit d7dec582d122314fd496c862e23e16bc7d52b2dd
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Aug 19 00:00:44 2017 +0000

    Automatic date update in version.in

commit 2989a3651d3f6ad8c7cffb225f77f4fca8868890
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Aug 15 23:36:09 2017 -0600

    Remove save_inferior_ptid
    
    This removes save_inferior_ptid, a cleanup function, in favor of
    scoped_restore.
    
    This also fixes a possible (it seems unlikely that it could happen in
    practice) memory leak -- save_inferior_ptid should have used
    make_cleanup_dtor, because it allocated memory.
    
    I tested this on the buildbot.  However, there are two caveats to
    this.  First, sometimes it seems I misread the results.  Second, I
    think this patch touches some platforms that can't be tested by the
    buildbot.  So, extra care seems warranted.
    
    ChangeLog
    2017-08-18  Tom Tromey  <tom@tromey.com>
    	    Pedro Alves  <palves@redhat.com>
    
    	* spu-multiarch.c (parse_spufs_run): Use scoped_restore.
    	* sol-thread.c (sol_thread_resume, sol_thread_wait)
    	(sol_thread_xfer_partial, rw_common): Use scoped_restore.
    	* procfs.c (procfs_do_thread_registers): Use scoped_restore.
    	* proc-service.c (ps_xfer_memory): Use scoped_restore.
    	* linux-tdep.c (linux_corefile_thread): Remove a cleanup.
    	(linux_get_siginfo_data): Add "thread" argument.  Use
    	scoped_restore.
    	* linux-nat.c (linux_child_follow_fork)
    	(check_stopped_by_watchpoint): Use scoped_restore.
    	* infrun.c (displaced_step_prepare_throw, write_memory_ptid)
    	(THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
    	(restore_inferior_ptid, save_inferior_ptid): Remove.
    	* btrace.c (btrace_fetch): Use scoped_restore.
    	* bsd-uthread.c (bsd_uthread_fetch_registers)
    	(bsd_uthread_store_registers): Use scoped_restore.
    	* breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
    	scoped_restore.
    	* aix-thread.c (aix_thread_resume, aix_thread_wait)
    	(aix_thread_xfer_partial): Use scoped_restore.
    	* inferior.h (save_inferior_ptid): Remove.

commit e60eb2880368b4e4752577c626ab0dadf0499cb5
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 18 09:30:12 2017 +0100

    [ARM] Mark USER_SPECIFIED_MACHINE_TYPE in disassemble_info.flags
    
    opcodes/arm-dis.c:print_insn may update disassemble_info.mach to
    bfd_mach_arm_unknown unless USER_SPECIFIED_MACHINE_TYPE is marked.
    When default_print_insn is called for the first time,
    disassemble_info.mach is correctly set in GDB, but arm-dis.c:print_insn
    sets it to bfd_mach_arm_unknown.  Then, when default_print_insn is
    called again (in a loop), it triggers the assert.
    
    The patch fixes the assert by marking USER_SPECIFIED_MACHINE_TYPE so that
    opcodes won't reset disassemble_info.mach.
    
    gdb:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	PR tdep/21818
    	* arm-tdep.c (gdb_print_insn_arm): Mark
    	USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.

commit 6d580b635f8963183540b816b20bb9c240154497
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 18 09:20:43 2017 +0100

    GDBserver self tests
    
    This patch uses GDB self test in GDBserver.  The self tests are run if
    GDBserver is started with option --selftest.
    
    gdb:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* NEWS: Mention GDBserver's new option "--selftest".
    	* Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
    	* selftest.c: Move it to common/selftest.c.
    	* selftest.h: Move it to common/selftest.h.
    	* selftest-arch.c (reset): New function.
    	(tests_with_arch): Call reset.
    
    gdb/gdbserver:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* Makefile.in (OBS): Add selftest.o.
    	* configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
    	* configure, config.in: Re-generated.
    	* server.c: Include common/sefltest.h.
    	(captured_main): Handle option --selftest.
    
    gdb/testsuite:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.server/unittest.exp: New.
    
    gdb/doc:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.texinfo (Server): Document "--selftest".

commit 86dcbf50fe5f59fbc35f38f02ab6c1803c29f383
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 18 09:20:43 2017 +0100

    Remove some GDB specific stuff from selftest.c
    
    The next patch moves selftest.c to common/selftest.c, so that GDBserver
    can use it as well.  However selftest.c uses something isn't "portable" on
    GDB and GDBserver.
    
    First, this patch removes QUIT.  I don't expect that we type ctrl-c during
    self/unit tests, and each test shouldn't take long time.  Secondly, I
    replace exception_fprintf and printf_filtered with debug_printf.  Verified
    that unit tests still catch fails.
    
    gdb:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* selftest.c (run_tests): Don't call QUIT.  Call debug_printf
    	instead of exception_fprintf and printf_filtered.

commit 7649770c8e52afe2696a70bb50ac3039c844d381
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 18 09:20:43 2017 +0100

    Put selftests api into selftests namespace
    
    This patch changes register_self_test to selftests::register_test,
    and run_self_tests to selftest::run_tests.
    
    gdb:
    
    2017-08-18  Yao Qi  <yao.qi@linaro.org>
    
    	* selftest.c (register_self_test): Rename it to
    	selftests::register_test.
    	(run_self_tests): selftest::run_tests.
    	* selftest.h: Update declarations.
    	* selftest-arch.c (register_self_test_foreach_arch): Rename it to
    	selftests::register_test_foreach_arch.
    	* selftest-arch.h: Update declaration.
    	* aarch64-tdep.c: Update.
    	* arm-tdep.c: Likewise.
    	* disasm-selftests.c: Likewise.
    	* dwarf2loc.c: Likewise.
    	* dwarf2-frame.c: Likewise.
    	* findvar.c: Likewise.
    	* gdbarch-selftests.c: Likewise.
    	* maint.c (maintenance_selftest): Likewise.
    	* regcache.c: Likewise.
    	* rust-exp.y: Likewise.
    	* selftest-arch.c: Likewise.
    	* unittests/environ-selftests.c: Likewise.
    	* unittests/function-view-selftests.c: Likewise.
    	* unittests/offset-type-selftests.c: Likewise.
    	* unittests/optional-selftests.c: Likewise.
    	* unittests/scoped_restore-selftests.c: Likewise.
    	* utils-selftests.c: Likewise.

commit de25939739ffe9a9ad7cec07a35bb2a1e430fe39
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Aug 18 08:45:12 2017 +0100

    Fix buffer overrun parsing a corrupt tekhex binary.
    
    	PR binutils/21962
    	* tekhex.c (getsym): Fix check for source pointer walking off the
    	end of the input buffer.

commit dd66b39984d2b8a24b97638d65eef5cfd7dcbc5a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Aug 18 00:00:54 2017 +0000

    Automatic date update in version.in

commit b0cba12e07cc17683b13c6275f58a6a829f96d06
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Aug 17 23:45:52 2017 +0100

    Plug source_command leak
    
    The heap-allocated 'old_source_verbose' local was accidentally left
    behind by commit 2ec845e75876 ("More uses of scoped_restore").
    
    Valgrind caught it, like:
    
     ==20123== 8 bytes in 1 blocks are definitely lost in loss record 4,609 of 13,785
     ==20123==    at 0x4C2A988: calloc (vg_replace_malloc.c:711)
     ==20123==    by 0x60A2F8: xcalloc (common-utils.c:84)
     ==20123==    by 0x4CDBE5: build_command_line(command_control_type, char const*) (cli-script.c:159)
     ==20123==    by 0x4CDC32: get_command_line(command_control_type, char const*) (cli-script.c:172)
     ==20123==    by 0x5230F1: python_command(char*, int) (python.c:421)
     ==20123==    by 0x4C61AD: do_cfunc(cmd_list_element*, char*, int) (cli-decode.c:106)
     ==20123==    by 0x4C911F: cmd_func(cmd_list_element*, char*, int) (cli-decode.c:1902)
     ==20123==    by 0x7CA79E: execute_command(char*, int) (top.c:650)
     ==20123==    by 0x695A0C: command_handler(char*) (event-top.c:590)
     ==20123==    by 0x7CA33F: read_command_file(_IO_FILE*) (top.c:461)
     ==20123==    by 0x4D0C3A: script_from_file(_IO_FILE*, char const*) (cli-script.c:1584)
     ==20123==    by 0x4C2727: source_script_from_stream(_IO_FILE*, char const*, char const*) (cli-cmds.c:589)
    
    gdb/ChangeLog:
    2017-08-17  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
    	local.

commit 4c8aa72d0eb714a91ca2e47b816d0b4a0cb27843
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Aug 17 22:53:53 2017 +0100

    Plug line_header leaks
    
    This plugs a couple leaks introduced by commit fff8551cf549
    ("dwarf2read.c: Some C++fycation, use std::vector, std::unique_ptr").
    
    The first problem is that nothing owns the temporary line_header that
    handle_DW_AT_stmt_list creates in some cases.  Before the commit
    mentioned above, the temporary line_header case used to have:
    
      make_cleanup (free_cu_line_header, cu);
    
    and that cleanup was assumed to be run by process_die, after
    handle_DW_AT_stmt_list returns and before child DIEs were processed.
    
    The second problem is found in setup_type_unit_groups: that also used
    to have a similar make_cleanup call, and ended up with a similar leak
    after the commit mentioned above.
    
    Fix both cases by recording in dwarf2_cu whether a line header is
    owned by the cu/die, and have process_die explicitly free the
    line_header if so, making use of a new RAII object that also replaces
    the reset_die_in_process cleanup, while at it.
    
    Thanks to Philippe Waroquiers for noticing the leak and pointing in
    the right direction.
    
    gdb/ChangeLog:
    2017-08-17  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
    	field.
    	(reset_die_in_process): Delete, replaced by ...
    	(process_die_scope): ... this new class.  Make it responsible for
    	freeing cu->line_header too.
    	(process_die): Use process_die_scope.
    	(handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
    	cu->line_header_die_owner.  Don't release the line header if it's
    	owned by the CU.
    	(setup_type_unit_groups): Make the CU/DIE own the line header.
    	Don't release the line header here.

commit 714da62f64ef5527a22a3e897f7e21f69e442ade
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 17 14:49:01 2017 +0100

    Add test of V2 GNU build attribute notes.
    
    	* testsuite/binutils-all/note-3-64.s: New test.  Checks assembly
    	and decoding of version2 GNU build attribute notes.
    	* testsuite/binutils-all/note-3-32.s: New test.  32-bit version of
    	the above test.
    	* testsuite/binutils-all/note-3-64.d: New test driver.
    	* testsuite/binutils-all/note-3-32.d: New test driver.
    	* testsuite/binutils-all/objcopy.exp: Run the new test.
    	* readelf.c (is_64bit_abs_reloc): Add R_SPARC_64.

commit 545bc2b377db80aa6edd0cf00cde6f963735f8d1
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Thu Aug 17 14:48:03 2017 +0100

    [AArch64] Skip IFUNC relocations in debug sections
    
    Skip IFUNC relocations in debug sections ignored by ld.so.
    Fixes the following ld test failures on aarch64:
    
    FAIL: Build libpr18808.so
    FAIL: Build libpr18808.so_2
    FAIL: Run pr18808
    
    aborting at bfd/elfnn-aarch64.c:4986 in elf64_aarch64_final_link_relocate.
    
    bfd/
    	PR ld/18808
    	* elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Skip IFUNC
    	relocations in debug sections, change abort to _bfd_error_handler.

commit 12601963cf4de26be1db45ee58ac3e282936aca5
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 17 12:13:28 2017 +0100

    Add new Brazilian Portuguese translation for the ld subdirectory.
    
    	* po/pt_BR.po: New Brazilian Portuguese translation.
    	* configure.ac (ALL_LINGUAS): Add pt_BR.
    	* configure: Regenerate.

commit ba7139188c75a9c620cadea59158c5ffcab28acf
Author: Alex Lindsay <alexlindsay239@gmail.com>
Date:   Thu Aug 17 11:53:53 2017 +0100

    Synthetic symbol leak in elf_read_minimal_symbols
    
    Detected this leak with valgrind memcheck:
    
    ==30840== 194 bytes in 1 blocks are definitely lost in loss record 9,138 of 10,922
    ==30840==    at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
    ==30840==    by 0x80DF82: bfd_malloc (libbfd.c:193)
    ==30840==    by 0x80E12D: bfd_zmalloc (libbfd.c:278)
    ==30840==    by 0x819E80: elf_x86_64_get_synthetic_symtab (elf64-x86-64.c:6835)
    ==30840==    by 0x4F7B01: elf_read_minimal_symbols(objfile*, int, elfinfo const*) (elfread.c:1124)
    ==30840==    by 0x4F7CE7: elf_symfile_read(objfile*, enum_flags<symfile_add_flag>) (elfread.c:1182)
    ==30840==    by 0x7557FC: read_symbols(objfile*, enum_flags<symfile_add_flag>) (symfile.c:861)
    ==30840==    by 0x755EE1: syms_from_objfile_1(objfile*, section_addr_info*, enum_flags<symfile_add_flag>) (symfile.c:1062)
    
    We perform a dynamic allocation in
    elf64-x86-64.c:elf_x86_64_get_synthetic_symtab
    
      s = *ret = (asymbol *) bfd_zmalloc (size);
    
    that appear to never get freed.
    
    gdb:
    
    2017-08-17  Alex Lindsay  <alexlindsay239@gmail.com>
    
    	* elfread.c (elf_read_minimal_symbols): xfree synthsyms.

commit 44d0fb3a0a47c00a296f52a045a47dd0f1ccb810
Author: Ruslan Kabatsayev <b7.10110111@gmail.com>
Date:   Thu Aug 17 08:44:37 2017 +0300

    Mention new TUI Single-Key mode shortcuts for nexti and stepi in NEWS
    
    gdb/ChangeLog:
    
    	* NEWS: Mention new shortcuts for nexti and stepi in TUI
    	Single-Key mode

commit 8c1d4b8799912076b2db1edb1ae65a5d62a11723
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Aug 17 00:01:00 2017 +0000

    Automatic date update in version.in

commit a5afdb1665ab0e030034d40f871b5cc17cda3969
Author: Ruslan Kabatsayev <b7.10110111@gmail.com>
Date:   Wed Aug 16 21:44:29 2017 +0300

    Add shortcuts for "nexti" and "stepi" commands in Single-Key mode
    
    Currently, "layout asm" is not so useful as "layout src" with Single-Key mode:
    you have to use multi-key commands like "ni" and "si" to do single-stepping.
    This patch adds, in addition to "next" and "step" commands, corresponding
    assembly-level ones - "nexti" and "stepi" - to Single-Key mode, with the
    shortcuts of "o" (from "step Over") and "i" (from "Step Into") respectively.
    
    gdb/ChangeLog:
    
    	* tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
    	mode command list.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (TUI Single Key Mode): Document the new shortcuts in
    	Single-Key mode.

commit 1a457753cfad05989574c671a221ffce2d5df703
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Aug 16 00:13:28 2017 +0000

    Automatic date update in version.in

commit 66c3b5f87cd9a12be6734587720bde4040819369
Author: Gustavo Romero <gromero@linux.vnet.ibm.com>
Date:   Mon Aug 14 10:48:04 2017 -0400

    Add new NT_PPC_* available since Linux 4.8
    
    Add new note types available since Linux 4.8 to elf/common.h and
    make the 'readelf' tool aware of it.
    
    include/
    	* elf/common.h (NT_PPC_TAR): New macro.
    	(NT_PPC_PPR): Likewise.
    	(NT_PPC_DSCR): Likewise.
    	(NT_PPC_EBB): Likewise.
    	(NT_PPC_PMU): Likewise.
    	(NT_PPC_TM_CGPR): Likewise.
    	(NT_PPC_TM_CFPR): Likewise.
    	(NT_PPC_TM_CVMX): Likewise.
    	(NT_PPC_TM_CVSX): Likewise.
    	(NT_PPC_TM_SPR): Likewise.
    	(NT_PPC_TM_CTAR): Likewise.
    	(NT_PPC_TM_CPPR): Likewise.
    	(NT_PPC_TM_CDSCR): Likewise.
    binutils/
    	* readelf.c (get_note_type): Handle PPC note types available
    	since Linux 4.8.

commit 47613aeb8a42e89e21e63e1dcedfa2cde6791e53
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Aug 16 06:32:28 2017 +0900

    Add myself as a write-after-approval GDB maintainer.
    
    gdb/ChangeLog:
    
    	* MAINTAINERS (Write After Approval): Add Stafford Horne.

commit 9c3cc99930a08934e16b630e92a0d285a434f228
Author: Stafford Horne <shorne@gmail.com>
Date:   Wed Aug 16 06:12:45 2017 +0900

    xtensa: Properly strdup string when building reggroup
    
    I noticed this while looking at the reggroup intializations.  It seems
    for xtensa the "cpN" reggroup->name is getting assigned to the same text
    pointer for each iteration of XTENSA_MAX_COPROCESSOR.
    
    Note, internally reggroup_new() does not do any xstrdup().
    
    gdb/ChangeLog:
    2017-08-15  Stafford Horne  <shorne@gmail.com>
    
    	* xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.

commit 206726fbfdd521fbb184daedb71b85030453bf0b
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Tue Aug 15 13:49:18 2017 -0400

    Fix PR gdb/21954: make 'unset environment' work again
    
    When I made commit 9a6c7d9c021cfeb290d76584db7a01e57e7c3d4e, which
    C++-fied gdb/common/environ.[ch], I mistakenly altered the behaviour
    of the 'unset environment' command.  This command, which should delete
    all environment variables, is now resetting the list of variables to
    the state they were when GDB was started.
    
    This commit fixes this regression, and also adds a test on
    gdb.base/environ.exp which really checks if 'unset environment'
    worked.
    
    gdb/ChangeLog:
    2017-08-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR gdb/21954
    	* infcmd.c (unset_environment_command): Use the 'clear' method on
    	the environment instead of resetting it.
    
    gdb/testsuite/ChangeLog:
    2017-08-15  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR gdb/21954
    	* gdb.base/environ.exp: Add test to check if 'unset environment'
    	works.

commit 0335ac6d12906bfb4b48410d8a7229c21c727cf2
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Tue Aug 15 08:04:23 2017 -0700

    Fix compile on big-endian platforms in siginfo_t converter.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
    	platforms.

commit 8975f864092f0a1ba561622ba137b305da4a362f
Author: Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
Date:   Tue Aug 15 13:58:01 2017 +0100

    [Patch AArch64] Turn lr, fp, ip0 and ip1 into proper aliases
    
    We got a report from the linux-arm-kernel folks about getting spurious
    warnings when building the kernel with binutils 2.29. See
    https://www.spinics.net/lists/arm-kernel/msg599929.html
    
    which boils down to this testcase.
    
    $> cat /tmp/tst.s
        lr .req x30
        /tmp/tst.s: Assembler messages:
        /tmp/tst.s:1: Warning: ignoring attempt to redefine built-in register 'lr'
    
    Instead let's treat this as a proper alias at startup time thus
    avoiding the problem and treating these as proper aliases
    rather than new registers. This means that attempts to redefine
    the alias with the same "name" will provoke no warning and attempts
    to redefine the alias to something else will provoke the above mentioned
    warning.
    
    Tested make check-gas and no regressions.
    
    Ok to apply to trunk (and backport to 2.29 branch)?
    
    Regards
    Ramana

commit 030e221591297b35bddfaefb4935b3a1fa1f49da
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 15 04:28:59 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit 36ffeca2c57efdd90bb8fa13af20aa28b6af51cb
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 15 04:21:38 2017 -0700

    Apply Bind __start/__stop symbols as symbolic in shared object

commit 18f844ee9d296f7d3857c9caf5d71be02cb694be
Merge: 7e7dffe bf0ec4c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 15 04:19:33 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit bf0ec4c2769236d9c471685409605f50b01479e5
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Aug 14 20:31:09 2017 +0200

    GDB testsuite: Suppress GCC's colored output
    
    Newer GCC versions yield colored diagnostic messages by default, which may
    be useful when executing GDB interactively from a terminal.  But when run
    from a GDB test case, the compiler output is written into gdb.log, where
    such escape sequences are usually more inhibiting than helpful to the
    evaluation of test results.  So this patch suppresses that.
    
    gdb/testsuite/ChangeLog:
    
    	* lib/gdb.exp (universal_compile_options): New caching proc.
    	(gdb_compile): Suppress GCC's coloring of messages.

commit d3abe1c8ef1ec9a90932b801138a144dcae95100
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Jul 11 06:44:36 2017 -0600

    Remove BITS_IN_BYTES define
    
    While working on the previous patch, I noticed that BITS_IN_BYTES can be
    replaced by HOST_CHAR_BIT, which is used more widely in gdb.
    
    ChangeLog
    2017-08-14  Tom Tromey  <tom@tromey.com>
    
    	* valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
    	(print_binary_chars): Likewise.
    	(BITS_IN_BYTES): Remove.

commit d6382fffde99214ce4aee99a208ddb703c647008
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Jul 11 06:40:40 2017 -0600

    Fix two regressions in scalar printing
    
    PR gdb/21675 points out a few regressions in scalar printing.
    
    One type of regression is due to not carrying over the old handling of
    floating point printing -- where a format like "/d" causes a floating
    point number to first be cast to a signed integer.  This patch restores
    this behavior.
    
    The other regression is a longstanding bug in print_octal_chars: one of
    the constants was wrong.  This patch fixes the constant and adds static
    asserts to help catch this sort of error.
    
    ChangeLog
    2017-08-14  Tom Tromey  <tom@tromey.com>
    
    	PR gdb/21675
    	* valprint.c (LOW_ZERO): Change value to 034.
    	(print_octal_chars): Add static_asserts for octal constants.
    	* printcmd.c (print_scalar_formatted): Add 'd' case.
    
    testsuite/ChangeLog
    2017-08-14  Tom Tromey  <tom@tromey.com>
    
    	PR gdb/21675:
    	* gdb.base/printcmds.exp (test_radices): New function.
    	* gdb.dwarf2/var-access.exp: Use p/u, not p/d.
    	* gdb.base/sizeof.exp (check_valueof): Use p/d.
    	* lib/gdb.exp (get_integer_valueof): Use p/d.

commit f978cb06dbfbd93dbd52bd39d992f8644b0c639e
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Aug 3 17:07:06 2017 -0600

    Fix memory leak in add_symbol_file_command
    
    I happened to notice that add_symbol_file_command leaks "sect_opts".
    This patch fixes the leak by changing sect_opts to be a std::vector.
    
    I had to change the logic in the loop a little bit.  Previously, it
    was incrementing section_index after completing an entry; but this
    changes it to push a new entry when the name is seen.
    
    I believe the argument parsing here is mildly incorrect, in that
    nothing checks whether the -s option actually had any arguments.
    Maybe gdb can crash if "-s NAME" is given without an argument.  I
    didn't try to fix this in this patch, but I do have another patch I
    can send later that fixes it up.
    
    Regression tested on the buildbot.
    
    ChangeLog
    2017-08-11  Tom Tromey  <tom@tromey.com>
    
    	* symfile.c (add_symbol_file_command): Use std::vector.

commit 2f5404b3581d125a96f14d92c4a7985e8156d1d6
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 11 10:14:16 2017 -0600

    Use std::move in a few places
    
    This patch adds std::move to few spots where it seems to be missing.
    
    Regression tested by the buildbot.
    
    ChangeLog
    2017-08-14  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
    	* break-catch-syscall.c (create_syscall_event_catchpoint): Use
    	std::move.
    	* break-catch-sig.c (create_signal_catchpoint): Use std::move.

commit 0c54f69295208331faab9bc5e995111a35672f9b
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Aug 14 12:09:36 2017 +0100

    Fix null pointer dereference when parsing a corrupt ELF binary.
    
    	PR 21957
    	* elf.c (setup_group): Check for an empty or very small group
    	section.
    	* po/bfd.pot: Regenerate.

commit d7f00f429aa525816cb3895462113326b6cb2fe2
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Aug 14 00:01:33 2017 +0000

    Automatic date update in version.in

commit 79a94a2ad1e6e2f227de07427481e4bb8be84504
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Aug 14 09:25:17 2017 +0930

    PR21441, Unnecessary padding of .eh_frame section
    
    Until all .eh_frame sections have been edited we don't know their
    sizes.  So it isn't possible to properly decide whether a non-empty
    .eh_frame section follows a given section until editing is complete.
    
    bfd/
    	PR 21441
    	* elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't add
    	alignment padding here.
    	* elflink.c (bfd_elf_discard_info): Add .eh_frame padding here
    	in a reverse pass over sections.
    ld/
    	PR 21441
    	* testsuite/ld-x86-64/pr21038a.d: Adjust.
    	* testsuite/ld-x86-64/pr21038a-now.d: Adjust.

commit 34c4758cc210e2ca042b0373938e57fd6844f89d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 13 05:41:37 2017 -0700

    ld: Restore linker scripts in PR ld/21884 tests
    
    OUTPUT_FORMAT in linker script of PR ld/21884 tests is needed to trigger
    PR ld/21884.  Restore linker scripts and add nacl versions of the same
    tests.
    
    	* testsuite/ld-i386/i386.exp: Run pr21884-nacl.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-i386/pr21884.d: Don't run on nacl targets.
    	* testsuite/ld-x86-64/pr21884.d: Likewise.
    	* testsuite/ld-i386/pr21884.t: Revert the last change.
    	* testsuite/ld-x86-64/pr21884.t: Likewise.
    	* testsuite/ld-i386/pr21884-nacl.d: New file.
    	* testsuite/ld-i386/pr21884-nacl.t: Likewise.
    	* testsuite/ld-x86-64/pr21884-nacl.d: Likewise.
    	* testsuite/ld-x86-64/pr21884-nacl.t: Likewise.

commit 6d545e31f520d42d921c6164ec592e8d7614d315
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Aug 13 09:34:04 2017 +0930

    Fix i686-nacl and x86_64-nacl pr21884 failures
    
    OUTPUT_FORMAT in the script results in "./ld-new: target elf32-i386
    not found" and similarly for the x86_64 test.
    
    	* testsuite/ld-i386/pr21884.t: Remove unneeded format, arch and entry.
    	* testsuite/ld-x86-64/pr21884.t: Likewise.

commit 9ba349b5449bca9678c1f0840074761d1d3c5261
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Aug 13 00:00:56 2017 +0000

    Automatic date update in version.in

commit ca145713f354ebd5e45ddf393ead46782d1f8b1e
Author: Sergio Durigan Junior <sergiodj@redhat.com>
Date:   Sat Aug 12 12:46:03 2017 -0400

    Fix typo on documentation ("show set startup-with-shell")
    
    The documentation was erroneously saying that there is a command named
    "show set startup-with-shell", while the correct version is "show
    startup-with-shell".  This commit fixes obvious mistake.
    
    gdb/doc/ChangeLog:
    2017-08-12  Sergio Durigan Junior  <sergiodj@redhat.com>
    
    	PR gdb/21925
    	* gdb.texinfo (Starting) <startup-with-shell>: Fix typo ("show
    	set...").

commit c2c2dd9f09130fcdfc6bee999705206644f1f17f
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Aug 12 10:33:00 2017 +0200

    testsuite: Exclude end-of-line characters from get_valueof result
    
    The get_valueof procedure allows tests to conveniently make gdb evaluate
    an expression an return the value as a string.  However, it includes an
    end-of-line character in its result.  I stumbled on this when trying to
    use that result as part of a regex further in a test.
    
    You can see this for example by adding a puts in
    gdb.dwarf2/implref-struct.exp:get_members:
    
        set members [get_valueof "" ${var} ""]
        puts "<$members>"
    
    The output is
    
        <{a = 0, b = 1, c = 2}
        >
    
    This is because the regex in get_valueof is too greedy, the captured
    portion matches anything up to the gdb_prompt, including the end of line
    characters.  This patch changes it to capture everything but end of line
    characters.
    
    The output of the puts becomes:
    
        <{a = 0, b = 1, c = 2}>
    
    I tested this by running gdb.dwarf2/implref-array.exp and
    gdb.dwarf2/implref-struct.exp, the two only current users of that
    procedure.
    
    gdb/testsuite/ChangeLog:
    
    	* lib/gdb.exp (get_valueof): Don't capture end-of-line
    	characters.

commit 483767a333faed7ac25783459c0c9b0be4800932
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Aug 12 16:27:29 2017 +0930

    Collision between NT_GNU_BUILD_ATTRIBUTE_OPEN and NT_PPC_VMX
    
    	* readelf.c (process_note): Qualify NT_GNU_BUILD_ATTRIBUTE notes
    	by name data.

commit 1a682d061c5afe8ffdf3a594730693fb7d447848
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Aug 12 00:00:57 2017 +0000

    Automatic date update in version.in

commit 7e7dffec482bba8fad3f963bfd0c9bfbb5873c74
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 09:53:01 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit f9b6ce7e87caacfe0623b662aaf2ff04257b54b3
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 09:47:38 2017 -0700

    Revert "Apply Also disallow global alias of common symbol"
    
    This reverts commit fa7bc1e3ba486c375edc0e6a285917c3544289fb.

commit 1d37126a0d6777f29e8ca092ee1b9c65c9eae3ed
Merge: 7fa7dd9 98c5dfc
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 09:47:18 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 98c5dfc99444094652c2f2259126f70e5cacf56f
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 09:32:44 2017 -0700

    x86: Allocate space for symbol names with symbol table
    
    When synthesizing symbols for PLT entries, allocate space for symbol
    names with @plt suffixes together with symbol table so that all memory
    is returned when symbol table is freed.
    
    	PR binutils/21943
    	* elf32-i386.c (elf_i386_get_synthetic_symtab): Allocate space
    	for @plt suffixes first.
    	* elf64-x86-64.c (elf_x86_64_get_synthetic_symtab): Likewise.

commit 93ab9c0de7ba4a477720622c7e772d76f646e3f5
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Aug 11 16:36:28 2017 +0100

    Add -z globalaudit linker command line option to set the DF_GLOBALAUDIT flag bit in the dynamic tags.
    
    	* emultempl/elf32.em (handle_option): Accept the -z globalaudit
    	command line option.
    	* lexsup.c (elf_static_list_options): Add -z globalaudit.
    	* ld.texinfo: Document the support for the new command line
    	option.
    	* NEWS: Mention the new feature.
    	* testsuite/ld-elf/audit.exp: Add a test of the -z globalaudit
    	command line option.
    	* testsuite/ld-elf/globalaudit.rd: New file: Expected output from
    	readelf.

commit 9593aade74f0da0c08a4ab55e4c59173b07b1f63
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 08:05:00 2017 -0700

    Add 2 more tests for PR ld/21884
    
    	PR ld/21884
    	* testsuite/ld-i386/i386.exp: Run pr21884.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-i386/pr21884.d: New file.
    	* testsuite/ld-i386/pr21884.t: Likewise.
    	* testsuite/ld-x86-64/pr21884.d: Likewise.
    	* testsuite/ld-x86-64/pr21884.t: Likewise.

commit 76db0a2e171d2c6780e0388840e3a10ffe7e9ee2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 11 07:41:51 2017 -0700

    Also disallow global alias of common symbol
    
    We can't create alias of common symbol.  Local alias of common symbol has
    been disallowed.  But global alias of common symbol is disallowed when the
    common symbol is seen first and silently dropped otherwise.  This patch
    disallows alias of common symbol in all cases.
    
    gas/
    
    	PR gas/21667
    	* read.c (pseudo_set): Update error message for alias of common
    	symbol.
    	* write.c (write_object_file): Disallow both local and global
    	aliases of common symbol.
    	* testsuite/gas/elf/common5a.d: New file.
    	* testsuite/gas/elf/common5a.l: Likewise.
    	* testsuite/gas/elf/common5a.s: Likewise.
    	* testsuite/gas/elf/common5b.d: Likewise.
    	* testsuite/gas/elf/common5b.l: Likewise.
    	* testsuite/gas/elf/common5b.s: Likewise.
    	* testsuite/gas/elf/common5c.d: Likewise.
    	* testsuite/gas/elf/common5c.s: Likewise.
    	* testsuite/gas/elf/common5d.d: Likewise.
    	* testsuite/gas/elf/common5d.s: Likewise.
    	* testsuite/gas/elf/elf.exp: Run common5a, common5b, common5c
    	and common5d.

commit de7985c3cca1358b21b49a9872455e2032f48ee3
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Aug 11 12:11:28 2017 +0100

    More gdb/skip.c C++ification
    
    - Make skiplist_entry a class with private data members.
    - Move all construction logic to the ctor.
    - Make skip_file_p etc be methods of skiplist_entry.
    - Use std::list for the skip entries chain.  Make the list own its
      elements.
    - Get rid of the ALL_SKIPLIST_ENTRIES/ALL_SKIPLIST_ENTRIES_SAFE
      macros, use range-for / iterators instead.
    - function_name_is_marked_for_skip 'function_sal' argument must be
      non-NULL, so make it a reference instead.
    
    All skiplist_entry invariants are now controlled by skiplist_entry
    methods/internals.  Some gdb_asserts disappear for being redundant.
    
    gdb/ChangeLog:
    2017-08-11  Pedro Alves  <palves@redhat.com>
    
    	* infrun.c (process_event_stop_test): Adjust
    	function_name_is_marked_for_skip call.
    	* skip.c: Include <list>.
    	(skiplist_entry): Make it a class with private fields, and
    	getters/setters.
    	(skiplist_entry_chain): Delete.
    	(skiplist_entries): New.
    	(skiplist_entry_count): Delete.
    	(highest_skiplist_entry_num): New.
    	(ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
    	(add_skiplist_entry): Delete.
    	(skiplist_entry::skiplist_entry): New.
    	(skiplist_entry::add_entry): New.
    	(skip_file_command, skip_function): Adjust.
    	(compile_skip_regexp): Delete.
    	(skip_command): Don't compile regexp here.  Adjust to use
    	skiplist_entry::add_entry.
    	(skip_info): Adjust to use range-for and getters.
    	(skip_enable_command, skip_disable_command): Adjust to use
    	range-for and setters.
    	(skip_delete_command): Adjust to use std::list.
    	(add_skiplist_entry): Delete.
    	(skip_file_p): Delete, refactored as ...
    	(skiplist_entry::do_skip_file_p): ... this new method.
    	(skip_gfile_p): Delete, refactored as ...
    	(skiplist_entry::do_gskip_file_p): ... this new method.
    	(skip_function_p, skip_rfunction_p): Delete, refactored as ...
    	(skiplist_entry::skip_function_p): ... this new method.
    	(function_name_is_marked_for_skip): Now returns bool, and takes
    	the function sal by const reference.  Adjust to use range-for and
    	skiplist_entry methods.
    	(_initialize_step_skip): Remove references to
    	skiplist_entry_chain, skiplist_entry_count.
    	* skip.h (function_name_is_marked_for_skip): Now returns bool, and
    	takes the function sal by const reference.

commit be7d3cd5f13196dd070978aa48c2832c351c25b6
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 11 09:30:02 2017 +0100

    Reset *THIS_CACHE in frame_unwind_try_unwinder in case of exception
    
    It is required that unwinder->sniffer should set *this_cache to NULL if
    the unwinder is not applicable or exception is thrown, so
    78ac5f831692f70b841044961069e50d4ba6a76f adds clear_pointer_cleanup to set
    *this_cache to NULL in case of exception in order to fix PR 14100.
    https://sourceware.org/ml/gdb-patches/2012-08/msg00075.html
    
    This patch removes that clear_pointer_cleanup, and catch all exception in
    the caller of unwinder->sniffer.  In case of exception, reset *this_case.
    
    gdb:
    
    2017-08-11  Yao Qi  <yao.qi@linaro.org>
    
    	* dwarf2-frame.c (clear_pointer_cleanup): Remove.
    	(dwarf2_frame_cache): Remove reset_cache_cleanup.
    	(dwarf2_frame_cache):
    	* frame-unwind.c (frame_unwind_try_unwinder): Catch
    	RETURN_MASK_ALL and set *this_case to NULL.
    	* frame-unwind.h: Update comments.

commit 1c90d9f022469629c255d44664b4452998168359
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 11 09:30:02 2017 +0100

    Class-fy dwarf2_frame_state_reg_info
    
    This patch adds dwarf2_frame_state_reg_info ctor, dtor, copy ctor,
    assignment operator, and move assignment.  This patch also adds unit test
    to execute_cfa_program to cover the changes.
    
    gdb:
    
    2017-08-11  Yao Qi  <yao.qi@linaro.org>
    
    	* dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
    	(dwarf2_frame_state_copy_regs): Remove.
    	(dwarf2_frame_state_free_regs): Remove.
    	(dwarf2_frame_state::~dwarf2_frame_state): Remove.
    	(dwarf2_restore_rule): Call method .alloc_regs instead of
    	dwarf2_frame_state_alloc_regs.
    	(execute_cfa_program): Likewise.  Call dwarf2_frame_state_reg_info
    	constructor.  Call std::move.
    	(dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
    	(dwarf2_frame_cache): Likewise.
    
    	[GDB_SELF_TEST]: Include selftest.h and
    	selftest-arch.h.
    	[GDB_SELF_TEST] (execute_cfa_program_test): New function.
    	(_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
    	execute_cfa_program_test.
    
    	* dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
    	copy ctor, assignment operator, move assignment.
    	<alloc_regs>: New method.
    	<swap>: New method.
    	(struct dwarf2_frame_state): Delete dtor.
    	(dwarf2_frame_state_alloc_regs): Remove declaration.
    	* sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
    	dwarf2_frame_state_alloc_regs, use .alloc_regs instead.

commit afe37d6be57a505e6abd01778474a2b73dff52c4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 11 09:30:02 2017 +0100

    Class-fy dwarf2_frame_state
    
    This patch adds ctor and dtor to dwarf2_frame_state, so that we can
    remove one cleanup "old_chain".
    
    gdb:
    
    2017-08-11  Yao Qi  <yao.qi@linaro.org>
    
    	* dwarf2-frame.c (dwarf2_frame_state_free): Remove.
    	(dwarf2_frame_state::dwarf2_frame_state): New.
    	(dwarf2_frame_state::~dwarf2_frame_state): New.
    	(dwarf2_fetch_cfa_info): Update.
    	(dwarf2_frame_cache): Remove old_chain.  Change 'fs' to an object
    	rather than a pointer.  Update code.
    	* dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
    	dtor.
    	<data_align, code_align, retaddr_column>: Change them to const.
    	<armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
    	to bool.

commit b348037fd8c0de5c39cc43970697c51048a8ec9c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 11 09:30:02 2017 +0100

    Move dwarf2_frame_state_reg.exp_len to union .loc
    
    dwarf2_frame_state_reg.exp_len is only used together with .loc.exp, so
    it makes more sense to exp_len to the union as well.
    
    gdb:
    
    2017-08-11  Yao Qi  <yao.qi@linaro.org>
    
    	* dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
    	<loc.exp>: New field.
    	* dwarf2-frame.c (execute_cfa_program): Update.
    	(dwarf2_frame_prev_register): Update.

commit 5af3691c758717e295ba4d03b800f3462a404056
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Aug 11 00:01:26 2017 +0000

    Automatic date update in version.in

commit 7fa7dd97c5c909662fd839ec3ee0c8bde54e2a17
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 10 13:13:20 2017 -0700

    Update binutils-secondary.patch for PR gas/21667 fix

commit fa7bc1e3ba486c375edc0e6a285917c3544289fb
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 10 13:04:45 2017 -0700

    Apply Also disallow global alias of common symbol

commit 4a902493b320d43baea688266a080df3cbf5e37b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 10 13:00:13 2017 -0700

    Update binutils-x86-gpoff.patch against master

commit 9e2ce078738085acc1ca5f4bf072b0a188aad46d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 10 12:53:59 2017 -0700

    Update binutils-secondary.patch against master

commit b3011b69101e131732098343554befcb8a588b8c
Merge: e8c140f e7c9de2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 10 12:44:12 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit e7c9de26788dee7a620ea9cdabd7466fb07639c4
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Aug 10 14:18:02 2017 +0100

    Allow gdb::unique_xmalloc_ptr<T[]>
    
    Currently, if you try to use the array version of
    gdb::unique_xmalloc_ptr (i.e., std::unique_ptr) in order to have
    access to operator[], like:
    
      gdb::unique_xmalloc_ptr<char[]> buf ((char *) xmalloc (10));
      return buf[0];
    
    then the build fails, like:
    
      /usr/include/c++/5.3.1/bits/unique_ptr.h: In instantiation of â??std::unique_ptr<_Tp [], _Dp>::~unique_ptr() [with _Tp = char; _Dp = gdb::xfree_deleter<char []>]â??:
      main.c:30:61:   required from here
      /usr/include/c++/5.3.1/bits/unique_ptr.h:484:17: error: no match for call to â??(std::unique_ptr<char [], gdb::xfree_deleter<char []> >::deleter_type {aka gdb::xfree_deleter<char []>}) (char*&)â??
          get_deleter()(__ptr);
    		   ^
      In file included from src/gdb/common/common-defs.h:92:0,
    		   from src/gdb/defs.h:28,
    		   from src/gdb/main.c:20:
      src/gdb/common/gdb_unique_ptr.h:34:8: note: candidate: void gdb::xfree_deleter<T>::operator()(T*) const [with T = char []]
         void operator() (T *ptr) const { xfree (ptr); }
    	  ^
      src/gdb/common/gdb_unique_ptr.h:34:8: note:   no known conversion for argument 1 from â??char*â?? to â??char (*)[]â??
      Makefile:1911: recipe for target 'main.o' failed
      make: *** [main.o] Error 1
    
    The problem is that we're missing an xfree_deleter specialization for
    arrays.
    
    gdb/ChangeLog:
    2017-08-10  Pedro Alves  <palves@redhat.com>
    
    	* common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.

commit ca6f2be7f6bc638fd4fad48def1fae4ae4d7906e
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 10 13:17:12 2017 +0100

    Add support for PE startup files that want to define their own constructor and desctructor sequencing.
    
    	* scripttempl/pep.sc: Enclose __CTOR_LIST__, ___CTOR_LIST__,
    	__DTOR_LIST__ and ___DTOR_LIST__ in PROVIDE statements so that
    	they can be overrridden by crt input files.
    	* scripttempl/pe.sc: Likewise.

commit 4c2da80c2bdff7761eb5b3d9c03ffa0c9958b6b9
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 10 11:51:42 2017 +0100

    Fix memory corruption when assembling an i386 darwin source file.
    
    	PR gas/21939
    	* config/obj-macho.c (obj_mach_o_set_indirect_symbols): Increase
    	size of indirect_syms array so that it is large enough to hold
    	every symbol if necessary.

commit 957e1fc1c5d0262e4b2f764cf031ad1458446498
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 10 09:37:36 2017 +0100

    Fix out of bounds memory access when trying to allocate space for a note of size -1.
    
    	PR 21933
    	* elf.c (elf_read_notes): Check for a note size of -1.

commit 3ecaa9fd728f6dd23de85efa0ceacf40da444c86
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Aug 10 00:01:40 2017 +0000

    Automatic date update in version.in

commit 7ed1dab994fa1c0cf49d10608b8e77271c9804b4
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 9 16:32:30 2017 -0700

    LD_CLASS: Check .libs/ld-new for linker first
    
    When --enable-shared is used, ./ld-new may be a shell script and the
    real linker is .libs/ld-new.  We should check .libs/ld-new first.
    
    	* testsuite/config/default.exp (LD_CLASS): Check .libs/ld-new
    	for linker first.

commit e8c6b620f70d8cced4a93d8857ad2a57f08a361a
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Aug 9 15:24:46 2017 -0700

    Replace home-grown linked-lists in FreeBSD's native target with STL lists.
    
    FreeBSD's native target uses linked-lists to keep track of pending fork
    events and fake vfork done events.  Replace the first list with std::list
    and the second with std::forward_list.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c (struct fbsd_fork_info): Remove.
    	(fbsd_pending_children): Use std::list.
    	(fbsd_remember_child): Likewise.
    	(fbsd_is_child_pending): Likewise.
    	(fbsd_pending_vfork_done): Use std::forward_list.
    	(fbsd_add_vfork_done): Likewise.
    	(fbsd_is_vfork_done_pending): Likewise.
    	(fbsd_next_vfork_done): Likewise.

commit e4a26669b914a1a1d519325b3bddf4bfe5078ea8
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Aug 9 15:24:46 2017 -0700

    Replace remaining cleanups in fbsd-nat.c.
    
    - Use a custom deleter with std::unique_ptr to free() memory returned
      by kinfo_getvmmap().
    - Use std::string with string_printf() to generate the pathname of the
      procfs 'map' file.
    - Use gdb::byte_vector to manage the dynamic buffer for
      TARGET_OBJECT_AUXV and the dynamically allocated array of LWP IDs.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
    	(fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
    	[!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
    	for `mapfilename'.
    	(fbsd_xfer_partial): Use gdb::byte_vector.
    	(fbsd_add_threads): Likewise.

commit 142311d325b962730f7d0247cc456f06e5c7b62b
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Aug 9 15:24:46 2017 -0700

    Fix compile in the !HAVE_KINFO_GETVMMAP case.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
    	"filestuff.h".
    	(fbsd_find_memory_regions): Fix `mapfile' initialization.

commit 978c05401b0f0ac7a94cca7db19b1dec0c5bd698
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 9 15:04:05 2017 -0700

    Run PR ld/17618 test only with 64-bit ELF linker
    
    PR ld/17618 test requires 64-bit linker to run.  Set LD_CLASS to "64bit"
    for 64-bit ELF linker and run PR ld/17618 test only if $LD_CLASS is
    "64bit".  More checks can be added to support 64-bit linkers in non-ELF
    format.
    
    	* testsuite/config/default.exp (LD_CLASS): New.  Set to "64bit"
    	for 64-bit ELF linker.
    	* testsuite/ld-x86-64/pr17618.d (#notarget): Removed.
    	* testsuite/ld-x86-64/x86-64.exp: Run pr17618 only for 64-bit
    	linker.

commit 0968fbae6b16ced72c356c14aaadfe366280a464
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Aug 9 22:16:14 2017 +0200

    doc: Fix copy-pasto in Z0 packet documentation
    
    The documentation for the cmd_list field of the Z0 packet refers to its
    content as a conditional expression, which seems like a copy-paste error
    from the cond_list field.
    
    gdb/doc/ChangeLog:
    
    	* gdb.texinfo (Packets): Fix Z0 cmd_list doc referring to
    	conditional expression.

commit 42fa2e0e1b7b135ab30f2f78074c3bfffa04d0cc
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 5 16:40:56 2017 -0600

    C++-ify skip.c
    
    I happened to notice that skiplist_entry, in skip.c, contains a
    gdb::optional<compiled_regex> -- but that this object's destructor is
    never run.  This can result in a memory leak.
    
    This patch fixes the bug by applying a bit more C++: changing this
    code to use new and delete, and std::unique_ptr; and removing cleanups
    in the process.
    
    Built and regression tested on x86-64 Fedora 25.
    
    ChangeLog
    2017-08-09  Tom Tromey  <tom@tromey.com>
    
    	* skip.c (skiplist_entry): New constructor.
    	(skiplist_entry::enabled, skiplist_entry::function_is_regexp)
    	(skiplist_entry::file_is_glob): Now bool.
    	(skiplist_entry::file, skiplist_entry::function): Now
    	std::string.
    	(make_skip_entry): Return a unique_ptr.  Use new.
    	(free_skiplist_entry, free_skiplist_entry_cleanup)
    	(make_free_skiplist_entry_cleanup): Remove.
    	(skip_command, skip_disable_command, add_skiplist_entry)
    	(skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
    	(skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
    	(function_name_is_marked_for_skip): Update.
    	(skip_delete_command): Update.  Use delete.

commit cc4a945a2687184c7cd4a0572e02965829517408
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Aug 9 17:52:54 2017 +0100

    [ARM] Don't warn on REG_SP when used in CRC32 instructions
    
    According to ARMv8-A architecture manual, REG_SP is allowed in CRC32
    instructions in Thumb mode.  It is REG_PC that will cause unpredictable
    behaviours on both ARM and Thumb.
    
    This patch removes the incorrect warning on Thumb mode.
    
    Meanwhile the disassembler is updated to use format "<bitfield>R" instead of
    "<bitfield>S".  "<bitfield>S" is not used elsewhere. so I have deleted related
    code from the disassembler.
    
    gas/
    	* config/tc-arm.c (do_crc32_1): Remove warning on REG_SP for thumb_mode.
    	* testsuite/gas/arm/crc32-armv8-a-bad.d: Update exepcted result.
    	* testsuite/gas/arm/crc32-armv8-r-bad.d: Likewise.
    	* testsuite/gas/arm/crc32-armv8-a.d: Likewise.
    	* testsuite/gas/arm/crc32-armv8-r.d: Likewise.
    	* testsuite/gas/arm/crc32-armv8-ar-bad.s: Update test case.
    	* testsuite/gas/arm/crc32-armv8-ar.s: Likewise.
    	* testsuite/gas/arm/crc32-bad.l: Update expected error message.
    
    opcode/
    	* arm-dis.c (thumb32_opcodes): Use format 'R' instead of 'S' for
    	register operands in CRC instructions.
    	(print_insn_thumb32): Remove "<bitfield>S" support.  Updated the
    	comments.

commit cd3af38d7b3e66117e7964b6fea45e57d47169ff
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Aug 9 17:43:00 2017 +0100

    [AArch64] Implement gdbarch_core_read_description
    
    Recommit with missing header files added.
    
    gdb/
    	* aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
    	(aarch64_linux_core_read_description): New function.
    	(aarch64_linux_init_abi): Register gdbarch_core_read_description.

commit 0f76ffafce1e93156094b393cd79489f4fd8de3f
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Aug 9 15:51:56 2017 +0100

    Revert "[AArch64] Implement gdbarch_core_read_description"
    
    This reverts commit b1a6c1cea365f80b90c0bca795c8d16fa0681560.

commit b1a6c1cea365f80b90c0bca795c8d16fa0681560
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Wed Aug 9 15:37:20 2017 +0100

    [AArch64] Implement gdbarch_core_read_description
    
    Currently, AArch64 only have one target description which is tdesc_aarch64.  So,
    we haven't implemented any target description detection mechanism for core file.
    
    This patch is an initial implementation of core_read_description method.  Future
    features can use this to return selected description.
    
    gdb/
    	* aarch64-linux-tdep.c (aarch64_linux_core_read_description): New
    	function.
    	(aarch64_linux_init_abi): Register gdbarch_core_read_description.

commit 29592bde87d250ea56e8431053918899d3d0c16b
Author: Pedro Alves <palves@redhat.com>
Date:   Wed Aug 9 15:04:32 2017 +0100

    Make cp_comp_to_string return a gdb::unique_xmalloc_ptr<char>
    
    To help avoid issues like the one fixed by e88e8651cf34 ("Fix memory
    leak in cp-support.c").
    
    gdb/ChangeLog:
    2017-08-09  Pedro Alves  <palves@redhat.com>
    
    	* cp-name-parser.y (cp_comp_to_string): Return a
    	gdb::unique_xmalloc_ptr<char>.
    	* cp-support.c (replace_typedefs_qualified_name)
    	(replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
    	(cp_canonicalize_string_full): Use op= instead of explicit
    	convertion.
    	(cp_class_name_from_physname, method_name_from_physname)
    	(cp_func_name, cp_remove_params): Adjust to use
    	gdb::unique_xmalloc_ptr<char>.
    	* cp-support.h (cp_comp_to_string): Return a
    	gdb::unique_xmalloc_ptr<char>.
    	* python/py-type.c (typy_lookup_type): Adjust to use
    	gdb::unique_xmalloc_ptr<char>.

commit b33404388e5bbd8a1fddfde73cd4593ae2b557e8
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 9 05:01:55 2017 -0700

    gdb: Fix build failure with GCC 7
    
    Fix:
    
    /export/gnu/import/git/sources/binutils-gdb/gdb/dwarf2read.c: In function â??const char* dwarf2_string_attr(die_info*, unsigned int, dwarf2_cu*)â??:
    /export/gnu/import/git/sources/binutils-gdb/gdb/dwarf2read.c:17626:39: error: enum constant in boolean context [-Werror=int-in-bool-context]
        || attr->form == DW_FORM_string || DW_FORM_GNU_str_index
    
    	* dwarf2read.c (dwarf2_string_attr): Fix a typo.

commit e88e8651cf3415ba440ee17eb1b22b7d2e8368be
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Aug 9 12:39:16 2017 +0100

    Fix memory leak in cp-support.c
    
    The return value of cp_comp_to_string was never freed, creating a
    sizable memory leak detectable with valgrind.
    
    ==21225== 8 bytes in 1 blocks are definitely lost in loss record 4,599 of 10,949^M
    ==21225==    at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)^M
    ==21225==    by 0x4C2FDEF: realloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)^M
    ==21225==    by 0x76CB31: d_growable_string_resize (cp-demangle.c:3963)^M
    ==21225==    by 0x76CB31: d_growable_string_init (cp-demangle.c:3942)^M
    ==21225==    by 0x76CB31: cplus_demangle_print (cp-demangle.c:4308)^M
    ==21225==    by 0x4C9535: cp_comp_to_string(demangle_component*, int) (cp-name-parser.y:1972)^M
    ==21225==    by 0x53E1D4: cp_canonicalize_string_full[abi:cxx11](char const*, char const* (*)(type*, void*), void*) (cp-support.c:530)^M
    ==21225==    by 0x53E360: cp_canonicalize_string_no_typedefs[abi:cxx11](char const*) (cp-support.c:548)^M
    ==21225==    by 0x5D51D2: find_linespec_symbols(linespec_state*, VEC_symtab_ptr*, char const*, VEC_symbolp**, VEC_bound_minimal_symbol_d**) (linespec.c:4030)^M
    ==21225==    by 0x5D6CF6: linespec_parse_basic (linespec.c:1907)
    
    ==21279== 32 bytes in 1 blocks are definitely lost in loss record 6,066 of 10,947^M
    ==21279==    at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)^M
    ==21279==    by 0x4C2FDEF: realloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)^M
    ==21279==    by 0x76CB31: d_growable_string_resize (cp-demangle.c:3963)^M
    ==21279==    by 0x76CB31: d_growable_string_init (cp-demangle.c:3942)^M
    ==21279==    by 0x76CB31: cplus_demangle_print (cp-demangle.c:4308)^M
    ==21279==    by 0x4C9535: cp_comp_to_string(demangle_component*, int) (cp-name-parser.y:1972)^M
    ==21279==    by 0x53EF14: cp_canonicalize_string[abi:cxx11](char const*) (cp-support.c:569)^M
    ==21279==    by 0x561B75: dwarf2_canonicalize_name(char const*, dwarf2_cu*, obstack*) [clone .isra.210] (dwarf2read.c:20159)
    
    This patch fixes the leak.  It is a regression by 2f408ecb.
    
    gdb:
    
    2017-08-09  Alex Lindsay  <alexlindsay239@gmail.com>
    	    Yao Qi  <yao.qi@linaro.org>
    
    	* cp-support.c (cp_canonicalize_string_full): Use
    	gdb::unique_xmalloc_ptr<char>.
    	(cp_canonicalize_string): Likewise.

commit f5a29eb0a6637abcafb1e54d53fae9bcaa6fbbd8
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Aug 9 12:27:24 2017 +0100

    Clean up x86 non-linux GDBserver target descriptions
    
    In GDBserver, only tdesc_i386 and tdesc_amd64 are used.  There is no point
    of generating these *.dat files (which are used to generate *.c files during
    GDBserver build.).
    
    gdb:
    
    2017-08-09  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (WHICH): Remove i386/ non-linux stuff.
    	* regformats/i386/amd64-avx-avx512.dat: Remove.
    	* regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
    	* regformats/i386/amd64-avx-mpx.dat:Remove.
    	* regformats/i386/amd64-avx.dat: Remove.
    	* regformats/i386/amd64-mpx.dat: Remove.
    	* regformats/i386/i386-avx-avx512.dat: Remove.
    	* regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
    	* regformats/i386/i386-avx-mpx.dat: Remove.
    	* regformats/i386/i386-mmx.dat: Remove.
    	* regformats/i386/i386-mpx.dat: Remove.
    
    gdb/gdbserver:
    
    2017-08-09  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_i386_regobj): Remove i386-avx.o,
    	i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
    	i386-avx-mpx.o and i386-mmx.o.
    	(srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
    	amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
    	(srv_i386_xmlfiles): Remove i386/i386-avx.xml,
    	i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
    	i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
    	(srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
    	i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
    	i386/amd64-avx-mpx.xml.

commit 57757c2f092ae7fb384e64df66c9921ac30957bb
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Aug 9 12:27:23 2017 +0100

    Remove x32 non-linux target descriptions
    
    x32 non-linux target descriptions are not used in GDB or GDBserver.  This
    patch removes them.
    
    gdb:
    
    2017-08-09  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-tdep.h (tdesc_x32): Remove the declaration.
    	* amd64-tdep.c: Don't include features/i386/x32*.c.
    	(_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
    	functions.
    	* features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
    	and i386/x32-avx-avx512.
    	(XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
    	and i386/x32.xml.
    	* features/i386/x32-avx-avx512.c: Removed.
    	* features/i386/x32-avx-avx512.xml: Removed.
    	* features/i386/x32-avx.c: Removed.
    	* features/i386/x32-avx.xml: Removed.
    	* features/i386/x32.c: Removed.
    	* features/i386/x32.xml: Removed.
    	* regformats/i386/x32-avx-avx512.dat: Removed.
    	* regformats/i386/x32-avx.dat: Removed.
    	* regformats/i386/x32.dat: Removed.
    
    gdb/gdbserver:
    
    2017-08-09  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
    	and x32-avx-avx512.o.
    	(srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
    	i386/x32-avx-avx512.xml.

commit 25d28c91b89d8f4a7e78b98b01e2c2382cea3e60
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 8 20:20:43 2017 -0700

    ld: Require GCC 5 or above for 3 x86 tests
    
    Require GCC 5 or above for 3 x86 tests which fail with GCC 4.9.3.
    
    	PR ld/21924
    	* testsuite/ld-i386/i386.exp: Require GCC 5 or above for
    	"weakundef1 with PIE" test.
    	* testsuite/ld-x86-64/tls.exp: Require GCC 5 or above for
    	"tlsdesc1" and "tlsdesc1 with PIE" tests.

commit 9165f4548be8612161fb90cfad9bd0cc6a752c90
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 8 20:01:28 2017 -0700

    ld: Add a ',' after -Wl,--rpath
    
    	* configure.ac (TESTBFDLIB): Add a ',' after -Wl,--rpath.
    	* configure: Regenerated.

commit a26c49b78ac3cac3ac812304bc06cf2beb1379aa
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Aug 9 00:00:58 2017 +0000

    Automatic date update in version.in

commit fe22cbc418b35ed6ea3252a204bd351f8c201e0b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 8 14:13:46 2017 -0700

    ld: Replace --rpath with -Wl,--rpath
    
    "--rpath ../bfd/.libs ../bfd/.libs/libbfd.so" isn't a valid compiler
    command-line option.  We should use -Wl,--rpath instead of --rpath.
    
    	PR ld/21923
    	* configure.ac (TESTBFDLIB): Replace --rpath with -Wl,--rpath
    	for --disable-static.
    	* configure: Regenerated.

commit 24d3e51bf0612c6cf5e9a824b982e7ed38e741c8
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Aug 8 13:20:02 2017 +0100

    Fix address violation problems when parsing corrupt ELF binaries.
    
    	PR 21916
    	* elf-attrs.c (_bfd_elf_parse_attributes): Complain about very
    	small section lengths.
    	* elf.c (_bfd_elf_setup_sections): Skip empty entries in the group
    	table.
    	(elfcore_grok_freebsd_prstatus): Add checks to make sure that
    	there is enough data present in the note.

commit 1fea592a7dc4c6639ad21321a2cf7b1f0bb55592
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Aug 8 11:59:32 2017 +0100

    Updated Serbian translation for gprof

commit cea7a285058bcba5a54d6493d6914c720f5c40a8
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Aug 8 11:57:22 2017 +0100

    Fix address violation bugs when writing beyond the end of a local string buffer.
    
    	PR 21909
    	* prdbg.c (pr_int_type): Increase size of local string buffer.
    	(pr_float_type): Likewise.
    	(pr_bool_type): Likewise.

commit 206c9c79ee24759c0e0af96e6722298b413f2716
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 8 14:05:33 2017 +0930

    PR21017, microblaze missing _GLOBAL_OFFSET_TABLE_ symbol
    
    	PR 21017
    	* elf32-microblaze.c (microblaze_elf_check_relocs): Don't bump
    	got.refcount for GOTOFF relocs, just create .got section.

commit 5d1ceb0b871a78601bbd4789ce137ff39c934a6f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Aug 8 00:00:54 2017 +0000

    Automatic date update in version.in

commit 2760f24c4942853eac7b921e4b8843d57a602654
Author: Romain Geissler <romain.geissler@gmail.com>
Date:   Tue Aug 8 07:25:39 2017 +0930

    Add configure flag to enable gnu hash style by default.
    
    ld/
    	* configure.ac: Add --enable-default-hash-style option.
    	* ldmain.c (main): Set link_info.emit_hash to DEFAULT_EMIT_SYSV_HASH.
    	Set link_info.emit_gnu_hash to DEFAULT_EMIT_GNU_HASH.
    	* configure: Regenerate.
    	* config.in: Regenerate.
    
    gold/
    	* configure.ac: Add --enable-default-hash-style option.
    	* options.h (hash_style): Use DEFAULT_HASH_STYLE as default value.
    	* configure: Regenerate.
    	* config.in: Regenerate.

commit 8f5e83fb735af978b99ea6e22574560bf667d1d6
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 8 07:15:29 2017 +0930

    More support for ld --hash-style in the ld testsuite
    
    These were discovered when running --hash-style=gnu as default, the
    previous batch being --hash-style=both.
    
    	* testsuite/ld-aarch64/ifunc-1-local.d: Run ld with --hash-style=sysv.
    	* testsuite/ld-aarch64/ifunc-2-local.d: Likewise.
    	* testsuite/ld-aarch64/ifunc-3a.d: Likewise.
    	* testsuite/ld-frv/fdpic-pie-1.d: Likewise.
    	* testsuite/ld-frv/fdpic-pie-2.d: Likewise.
    	* testsuite/ld-frv/fdpic-pie-7.d: Likewise.
    	* testsuite/ld-frv/fdpic-pie-8.d: Likewise.
    	* testsuite/ld-arm/arm-elf.exp: Add --hash-style=sysv to "Using
    	Thumb lib by another lib" test's ld options.
    	* testsuite/ld-elf/note-3.l: Match .gnu.hash.
    	* testsuite/ld-elf/note-3.t: Add .gnu.hash output section.

commit e8c140fef478676b213c32db766ecb1c06445bc9
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 4 10:43:32 2017 -0700

    Apply x86: Add R_X86_64_GPOFF/R_386_GPOFF relocation

commit 236f701cd53fa1b8be05a14e66bfc429656760d4
Merge: b4dfc24 7b00572
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 7 14:26:35 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 7b005726f910af908f0b5ba48b3466d119453b06
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Aug 7 18:25:59 2017 +0200

    Add missing PR mention in ChangeLog
    
    I noticed that the patch pushed previously had an open bug about it, so
    add a reference to it.

commit ba7b109b296feac8cf8cab74db5f824dfa631610
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Aug 7 17:02:04 2017 +0100

    PR breakpoints/21886: mem-break: Fix breakpoint insertion location
    
    Fix a commit cd6c3b4ffc4e ("New gdbarch methods breakpoint_kind_from_pc
    and sw_breakpoint_from_kind") regression and restore the use of
    `->placed_address' rather than `->reqstd_address' as the location for a
    memory breakpoint to be inserted at.  Previously
    `gdbarch_breakpoint_from_pc' was used that made that adjustment in
    `default_memory_insert_breakpoint' from the preinitialized value,
    however with the said commit that call is gone, so the passed
    `->placed_address' has to be used for the initialization.
    
    The regression manifests itself as the inability to debug any MIPS/Linux
    compressed ISA dynamic executable as GDB corrupts the dynamic loader
    with one of its implicit breakpoints, causing the program to crash, as
    seen for example with the `mips-linux-gnu' target, o32 ABI, MIPS16 code,
    and the gdb.base/advance.exp test case:
    
    (gdb) continue
    Continuing.
    
    Program received signal SIGBUS, Bus error.
    _dl_debug_initialize (ldbase=0, ns=0) at dl-debug.c:51
    51	    r = &_r_debug;
    (gdb) FAIL: gdb.base/advance.exp: Can't run to main
    
    	gdb/
    	PR breakpoints/21886
    	* mem-break.c (default_memory_insert_breakpoint): Use
    	`->placed_address' rather than `->reqstd_address' for the
    	breakpoint location.

commit b28b8b5e31903f59b00a4664b8204409e1e5bb91
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 7 08:07:26 2017 -0700

    Mark big and mach with ATTRIBUTE_UNUSED
    
    Fix build on x86:
    
    opcodes/disassemble.c: In function â??disassemblerâ??:
    opcodes/disassemble.c:113:52: error: unused parameter â??bigâ?? [-Werror=unused-parameter]
     disassembler (enum bfd_architecture a, bfd_boolean big, unsigned long mach,
                                                        ^~~
    opcodes/disassemble.c:113:71: error: unused parameter â??machâ?? [-Werror=unused-parameter]
     disassembler (enum bfd_architecture a, bfd_boolean big, unsigned long mach,
                                                                           ^~~~
    cc1: all warnings being treated as errors
    
    	* disassemble.c (disassembler): Mark big and mach with
    	ATTRIBUTE_UNUSED.

commit 2980ccad5958af178f80fd2a2a0fa781bf91b0aa
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Aug 7 08:02:12 2017 -0700

    Move common symbol check after bed->common_definition
    
    bfd/
    
    	* elflink.c (elf_link_add_object_symbols): Move common symbol
    	check after bed->common_definition.
    
    ld/
    
    	* testsuite/ld-elf/pr21903.s (start): Removed.
    	(_start): Likewise.
    	(__start): Likewise.
    	(main): Likewise.
    	(bar): New.

commit e347efc38b8b1eb6561248875c4bb2f9b074894b
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Aug 7 15:53:54 2017 +0100

    GDB/opcodes: Remove arch/mach/endian disassembler assertions
    
    Fix `set architecture' and `set endian' command disassembly regressions
    from commit 39503f82427e ("Delegate opcodes to select disassembler in
    GDB"), and commit 003ca0fd2286 ("Refactor disassembler selection"), as
    well as a MIPS compressed ISA disassembly target regression from commit
    6394c606997f ("Don't use print_insn_XXX in GDB"), which caused assertion
    failures to trigger.
    
    For example with the `mips-linux-gnu' target we get:
    
    $ cat main.c
    int
    main (void)
    {
      return 0;
    }
    $ gcc -mips32r2 -O2 main.c -o main
    $ gcc -mips16 -mips32r2 -O2 main.c -o main16
    $ gdb
    GNU gdb (GDB) 8.0.50.20170731-git
    [...]
    (gdb) file main
    Reading symbols from main...done.
    (gdb) show architecture
    The target architecture is set automatically (currently mips:isa32r2)
    (gdb) show endian
    The target endianness is set automatically (currently big endian)
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:	jr	ra
       0x00400504 <+4>:	move	v0,zero
    End of assembler dump.
    (gdb) set architecture mips:isa64r2
    The target architecture is assumed to be mips:isa64r2
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:
    .../gdb/arch-utils.c:979: internal-error: int default_print_insn(bfd_vma, disassemble_info*): Assertion `info->mach == bfd_get_mach (exec_bfd)' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n) n
    [...]
    Command aborted.
    (gdb) set architecture auto
    The target architecture is set automatically (currently mips:isa32r2)
    (gdb) set endian little
    The target is assumed to be little endian
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:
    .../gdb/arch-utils.c:978: internal-error: int default_print_insn(bfd_vma, disassemble_info*): Assertion `info->endian == (bfd_big_endian (exec_bfd) ? BFD_ENDIAN_BIG : BFD_ENDIAN_LITTLE)' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n) n
    [...]
    Command aborted.
    (gdb) set endian auto
    The target endianness is set automatically (currently big endian)
    (gdb) set architecture i386
    The target architecture is assumed to be i386
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:
    .../gdb/arch-utils.c:976: internal-error: int default_print_insn(bfd_vma, disassemble_info*): Assertion `info->arch == bfd_get_arch (exec_bfd)' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n) n
    [...]
    Command aborted.
    (gdb) set architecture auto
    The target architecture is set automatically (currently mips:isa32r2)
    (gdb) file main16
    Load new symbol table from "main16"? (y or n) y
    Reading symbols from main16...done.
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400501 <+0>:
    .../gdb/arch-utils.c:979: internal-error: int default_print_insn(bfd_vma, disassemble_info*): Assertion `info->mach == bfd_get_mach (exec_bfd)' failed.
    A problem internal to GDB has been detected,
    further debugging may prove unreliable.
    Quit this debugging session? (y or n) n
    Command aborted.
    (gdb)
    
    Remove the assertions then, restoring previous semantics:
    
    (gdb) file main
    Reading symbols from main...done.
    (gdb) set architecture mips:isa64r2
    The target architecture is assumed to be mips:isa64r2
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:	jr	ra
       0x00400504 <+4>:	move	v0,zero
    End of assembler dump.
    (gdb) set endian little
    The target is assumed to be little endian
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:	j	0x3800c
       0x00400504 <+4>:	addiu	s0,t0,0
    End of assembler dump.
    (gdb) set architecture i386
    The target architecture is assumed to be i386
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400500 <+0>:	add    %eax,%esp
       0x00400502 <+2>:	add    %cl,(%eax)
       0x00400504 <+4>:	add    %al,(%eax)
       0x00400506 <+6>:	adc    %ah,0x0
    End of assembler dump.
    (gdb) set architecture auto
    The target architecture is set automatically (currently mips:isa32r2)
    (gdb) set endian auto
    The target endianness is set automatically (currently big endian)
    (gdb) file main16
    Load new symbol table from "main16"? (y or n) y
    Reading symbols from main16...done.
    (gdb) disassemble main
    Dump of assembler code for function main:
       0x00400501 <+0>:	jr	ra
       0x00400503 <+2>:	li	v0,0
    End of assembler dump.
    (gdb)
    
    	gdb/
    	* arch-utils.c (default_print_insn): Remove arch/mach/endian
    	assertions.
    
    	opcodes/
    	* disassemble.c (disassembler): Remove arch/mach/endian
    	assertions.

commit 0dba2a6c09c4010dfb2eb5abdd991208374947c4
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Mon Aug 7 15:53:54 2017 +0100

    gdbarch: Use an anonymous union for target data in `gdbarch_info'
    
    As an update to commit ede5f15146ae ("gdbarch.h: Change
    gdbarch_info::tdep_info's type to void *") replace the definition of the
    `tdep_info' member in `struct gdbarch_info' with an anonymous union,
    comprising the original member, with its type reverted to `struct
    gdbarch_tdep_info *', a `tdesc_data' member of a `struct tdesc_arch_data
    *' type and an `id' member of an `int *' type.  Remove now unnecessary
    casts throughout use places then, making code easier to read an less
    prone to errors, which may happen with casting.
    
    	gdb/
    	* gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
    	a union of `tdep_info', `tdesc_data' and `id'.
    	* aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
    	rather than `info.tdep_info'.
    	* amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
    	* i386-linux-tdep.c (i386_linux_init_abi): Likewise.
    	* i386-tdep.c (i386_gdbarch_init): Likewise.
    	* mips-linux-tdep.c (mips_linux_init_abi): Likewise.
    	* mips-tdep.c (mips_gdbarch_init): Likewise.
    	* nds32-tdep.c (nds32_gdbarch_init): Likewise.
    	* rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
    	* ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
    	`info.tdep_info'.
    	(ppc_linux_init_abi): Use `info.tdesc_data' rather than
    	`info.tdep_info'.
    	* sparc-tdep.c (sparc32_gdbarch_init): Likewise.
    	* spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
    	`info.tdep_info'.
    	* spu-tdep.c (spu_gdbarch_init): Likewise.
    	* gdbarch.h: Regenerate.

commit 16eb6b2db49e6cf2fdca56efd37689fcc170cd37
Author: Leszek Swirski <leszeks@google.com>
Date:   Mon Aug 7 16:40:38 2017 +0200

    Fix dwarf2_string_attr for -gsplit-dwarf
    
    The dwarf2_string_attr did not allow DW_FORM_GNU_str_index as a form for
    string types. This manifested as null strings in the namespace_name
    lookup (replaced with "(anonymous namespace)") when debugging
    Fission-compiled code.
    
    gdb/ChangeLog:
    
    	* dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.

commit bab55c0522f47e692e367bfa341f4e19495cd8ad
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Aug 6 22:04:25 2017 +0930

    Support different ld --hash-style in the ld testsuite
    
    When ld is running with something other than --hash-style=sysv by
    default, numerous tests need tweaking.  Most of the changes just add
    --hash-style=sysv.  I didn't want to make --hash-style=sysv global as
    that means --hash-style=gnu isn't well tested.
    
    	* testsuite/ld-alpha/alpha.exp: Add --hash-style=sysv to various
    	test's ld options.
    	* testsuite/ld-arm/arm-elf.exp: Likewise.
    	* testsuite/ld-elf/elf.exp: Likewise.
    	* testsuite/ld-elf/readelf.exp: Likewise.
    	* testsuite/ld-elfvsb/elfvsb.exp: Likewise.
    	* testsuite/ld-i386/i386.exp: Likewise.
    	* testsuite/ld-ia64/ia64.exp: Likewise.
    	* testsuite/ld-m68k/m68k.exp: Likewise.
    	* testsuite/ld-metag/metag.exp: Likewise.
    	* testsuite/ld-powerpc/powerpc.exp: Likewise.
    	* testsuite/ld-s390/s390.exp: Likewise.
    	* testsuite/ld-sh/sh-vxworks.exp: Likewise.
    	* testsuite/ld-shared/shared.exp: Likewise.
    	* testsuite/ld-sparc/sparc.exp: Likewise.
    	* testsuite/ld-tic6x/tic6x.exp: Likewise.
    	* testsuite/ld-vax-elf/vax-elf.exp: Likewise.
    	* testsuite/ld-x86-64/mpx.exp: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Likewise.
    	* testsuite/ld-xtensa/xtensa.exp: Likewise.
    
    	* testsuite/ld-elf/comm-data2.ld: Add .gnu.hash output section.
    	* testsuite/ld-elf/pr20828-v.ld: Likewise.
    	* testsuite/ld-elf/pr20828.ld: Likewise.
    	* testsuite/ld-elf/pr21233.ld: Likewise.
    	* testsuite/ld-elf/pr21384.ld: Likewise.
    	* testsuite/ld-elf/provide-hidden-1.ld: Likewise.
    	* testsuite/ld-elf/provide-hidden-2.ld: Likewise.
    	* testsuite/ld-elf/provide-hidden-s.ld: Likewise.
    	* testsuite/ld-scripts/cross1.t: Likewise.
    
    	* testsuite/ld-elf/stab.d: Adjust allowed section indices.
    
    	* testsuite/ld-i386/pie1.d: Don't match addresses.
    	* testsuite/ld-i386/plt-pic2.dd: Likewise.
    	* testsuite/ld-i386/pr19636-1d.d: Likewise.
    	* testsuite/ld-i386/pr19636-2c.d: Likewise.
    	* testsuite/ld-powerpc/elfv2so.d: Likewise.
    	* testsuite/ld-powerpc/tlsopt5.d: Likewise.
    	* testsuite/ld-powerpc/tlsopt5.wf: Likewise.
    	* testsuite/ld-powerpc/tlsopt5_32.d: Likewise.
    
    	* testsuite/ld-i386/pr19636-2b.d: Don't match _start.
    
    	* testsuite/ld-powerpc/ambiguousv1.d: Relax symbol count, index
    	and address match.
    	* testsuite/ld-powerpc/ambiguousv1b.d: Likewise.
    	* testsuite/ld-powerpc/ambiguousv2.d: Likewise.
    	* testsuite/ld-powerpc/ambiguousv2b.d: Likewise.
    
    	* testsuite/ld-aarch64/gc-plt-relocs.d: Run ld with --hash-style=sysv.
    	* testsuite/ld-aarch64/ifunc-1.d: Likewise.
    	* testsuite/ld-aarch64/ifunc-2.d: Likewise.
    	* testsuite/ld-aarch64/ifunc-21.d: Likewise.
    	* testsuite/ld-aarch64/relasz.d: Likewise.
    	* testsuite/ld-aarch64/tls-small-ld.d: Likewise.
    	* testsuite/ld-aarch64/tls-tiny-ld.d: Likewise.
    	* testsuite/ld-arc/tls_gd-01.d: Likewise.
    	* testsuite/ld-cris/libdso-10.d: Likewise.
    	* testsuite/ld-cris/libdso-2.d: Likewise.
    	* testsuite/ld-cris/pic-gc-72.d: Likewise.
    	* testsuite/ld-cris/pic-gc-73.d: Likewise.
    	* testsuite/ld-cris/tls-gd-1.d: Likewise.
    	* testsuite/ld-cris/tls-gd-1h.d: Likewise.
    	* testsuite/ld-cris/tls-gd-2.d: Likewise.
    	* testsuite/ld-cris/tls-gd-2h.d: Likewise.
    	* testsuite/ld-cris/tls-ie-10.d: Likewise.
    	* testsuite/ld-cris/tls-ie-11.d: Likewise.
    	* testsuite/ld-cris/tls-ie-8.d: Likewise.
    	* testsuite/ld-cris/tls-ie-9.d: Likewise.
    	* testsuite/ld-cris/tls-ld-4.d: Likewise.
    	* testsuite/ld-cris/tls-ld-5.d: Likewise.
    	* testsuite/ld-cris/tls-ld-6.d: Likewise.
    	* testsuite/ld-cris/tls-ld-7.d: Likewise.
    	* testsuite/ld-cris/tls-ldgd-14.d: Likewise.
    	* testsuite/ld-cris/tls-ldgd-15.d: Likewise.
    	* testsuite/ld-cris/tls-ldgdx-14.d: Likewise.
    	* testsuite/ld-cris/tls-ldgdx-15.d: Likewise.
    	* testsuite/ld-cris/tls-local-54.d: Likewise.
    	* testsuite/ld-cris/tls-local-60.d: Likewise.
    	* testsuite/ld-cris/tls-local-61.d: Likewise.
    	* testsuite/ld-cris/weakhiddso.d: Likewise.
    	* testsuite/ld-elf/linkinfo1a.d: Likewise.
    	* testsuite/ld-elf/linkinfo1b.d: Likewise.
    	* testsuite/ld-elf/pr19617a.d: Likewise.
    	* testsuite/ld-elfvsb/hidden2.d: Likewise.
    	* testsuite/ld-frv/fdpic-pie-6.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-2.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-5.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-6.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-8.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-local-2.d: Likewise.
    	* testsuite/ld-frv/fdpic-shared-local-8.d: Likewise.
    	* testsuite/ld-frv/tls-dynamic-2.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-1.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-2a.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-2c.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3a.d: Likewise.
    	* testsuite/ld-i386/ibt-plt-3c.d: Likewise.
    	* testsuite/ld-i386/pr20830.d: Likewise.
    	* testsuite/ld-ia64/merge1.d: Likewise.
    	* testsuite/ld-ia64/merge2.d: Likewise.
    	* testsuite/ld-ia64/merge3.d: Likewise.
    	* testsuite/ld-ia64/merge4.d: Likewise.
    	* testsuite/ld-ia64/merge5.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-1-local-x86.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-1-x86.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-i386-now.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-local-i386-now.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-local-x86-64-now.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-local-x86-64.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-x86-64-now.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-2-x86-64.d: Likewise.
    	* testsuite/ld-ifunc/ifunc-3a-x86.d: Likewise.
    	* testsuite/ld-ifunc/pr17154-i386-now.d: Likewise.
    	* testsuite/ld-ifunc/pr17154-i386.d: Likewise.
    	* testsuite/ld-ifunc/pr17154-x86-64-now.d: Likewise.
    	* testsuite/ld-ifunc/pr17154-x86-64.d: Likewise.
    	* testsuite/ld-m68k/got-1.d: Likewise.
    	* testsuite/ld-m68k/got-multigot-12-13-14-34-35-ok.d: Likewise.
    	* testsuite/ld-m68k/got-multigot-14-ok.d: Likewise.
    	* testsuite/ld-m68k/got-multigot-15-er.d: Likewise.
    	* testsuite/ld-m68k/got-negative-12-13-14-34-ok.d: Likewise.
    	* testsuite/ld-m68k/got-negative-12-13-14-35-er.d: Likewise.
    	* testsuite/ld-m68k/got-negative-14-ok.d: Likewise.
    	* testsuite/ld-m68k/got-negative-15-er.d: Likewise.
    	* testsuite/ld-m68k/got-single-12-ok.d: Likewise.
    	* testsuite/ld-m68k/got-single-13-er.d: Likewise.
    	* testsuite/ld-m68k/got-xgot-12-13-14-15-34-35-ok.d: Likewise.
    	* testsuite/ld-m68k/got-xgot-15-ok.d: Likewise.
    	* testsuite/ld-m68k/tls-gd-1.d: Likewise.
    	* testsuite/ld-m68k/tls-gd-2.d: Likewise.
    	* testsuite/ld-m68k/tls-gd-ie-1.d: Likewise.
    	* testsuite/ld-m68k/tls-ie-1.d: Likewise.
    	* testsuite/ld-m68k/tls-ld-1.d: Likewise.
    	* testsuite/ld-m68k/tls-ld-2.d: Likewise.
    	* testsuite/ld-sh/shared-2.d: Likewise.
    	* testsuite/ld-sh/tlsbin-2.d: Likewise.
    	* testsuite/ld-sh/tlspic-2.d: Likewise.
    	* testsuite/ld-x86-64/bnd-branch-1-now.d: Likewise.
    	* testsuite/ld-x86-64/bnd-ifunc-1-now.d: Likewise.
    	* testsuite/ld-x86-64/bnd-ifunc-1.d: Likewise.
    	* testsuite/ld-x86-64/bnd-ifunc-2-now.d: Likewise.
    	* testsuite/ld-x86-64/bnd-ifunc-2.d: Likewise.
    	* testsuite/ld-x86-64/bnd-plt-1-now.d: Likewise.
    	* testsuite/ld-x86-64/bnd-plt-1.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-1-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-1.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2a-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2a.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2c-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-2c.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3a-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3a.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3c-x32.d: Likewise.
    	* testsuite/ld-x86-64/ibt-plt-3c.d: Likewise.
    	* testsuite/ld-x86-64/ilp32-4-nacl.d: Likewise.
    	* testsuite/ld-x86-64/ilp32-4.d: Likewise.
    	* testsuite/ld-x86-64/load1c-nacl.d: Likewise.
    	* testsuite/ld-x86-64/load1c.d: Likewise.
    	* testsuite/ld-x86-64/load1d-nacl.d: Likewise.
    	* testsuite/ld-x86-64/load1d.d: Likewise.
    	* testsuite/ld-x86-64/pie3-nacl.d: Likewise.
    	* testsuite/ld-x86-64/pie3.d: Likewise.
    	* testsuite/ld-x86-64/pr14207.d: Likewise.
    	* testsuite/ld-x86-64/pr19162.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2d-nacl.d: Likewise.
    	* testsuite/ld-x86-64/pr19636-2d.d: Likewise.
    	* testsuite/ld-x86-64/pr20253-1d.d: Likewise.
    	* testsuite/ld-x86-64/pr20253-1f.d: Likewise.
    	* testsuite/ld-x86-64/pr20253-1j.d: Likewise.
    	* testsuite/ld-x86-64/pr20253-1l.d: Likewise.
    	* testsuite/ld-x86-64/pr20830a-now.d: Likewise.
    	* testsuite/ld-x86-64/pr20830a.d: Likewise.
    	* testsuite/ld-x86-64/pr20830b-now.d: Likewise.
    	* testsuite/ld-x86-64/pr20830b.d: Likewise.
    	* testsuite/ld-x86-64/pr21038a-now.d: Likewise.
    	* testsuite/ld-x86-64/pr21038a.d: Likewise.
    	* testsuite/ld-x86-64/pr21038b-now.d: Likewise.
    	* testsuite/ld-x86-64/pr21038b.d: Likewise.
    	* testsuite/ld-x86-64/pr21038c-now.d: Likewise.
    	* testsuite/ld-x86-64/pr21038c.d: Likewise.

commit b3293efaf8ddef1eba52de14be47e3d33bbce35a
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Aug 7 18:02:49 2017 +0930

    PR21910, segfault in common symbol override test when hash-style=gnu
    
    	PR 21910
    	* elflink.c (bfd_elf_final_link): Don't segfault when sections
    	needed to define various dynamic tags have been discarded.

commit 74cbb09e74dda17fc79e2ce709116780a90310ef
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Aug 7 12:09:37 2017 +0200

    remote-sim.c: Fix arg variables conflicts
    
    The recent change introducing gdb_argv introduced some build failures in
    remote-sim.c.
    
      /home/emaisin/src/binutils-gdb/gdb/remote-sim.c: In function 'void gdbsim_load(target_ops*, const char*, int)':
      /home/emaisin/src/binutils-gdb/gdb/remote-sim.c:573:22: error: conflicting declaration 'gdb_argv argv'
         gdb_argv argv (args);
                            ^
      /home/emaisin/src/binutils-gdb/gdb/remote-sim.c:565:10: note: previous declaration as 'char** argv'
         char **argv;
                ^~~~
      /home/emaisin/src/binutils-gdb/gdb/remote-sim.c: In function 'void gdbsim_open(const char*, int)':
      /home/emaisin/src/binutils-gdb/gdb/remote-sim.c:730:25: error: declaration of 'gdb_argv args' shadows a parameter
         gdb_argv args (arg_buf);
    
    In gdbsim_load, the new gdb_argv object conflicts with old char **argv
    variable.  I think the old variable should be removed.
    
    In gdbsim_open, the new gdb_argv object conflicts with the args
    parameter.  This patch renames it to argv.
    
    Built-tested for a mips host.
    
    gdb/ChangeLog:
    
    	* remote-sim.c (gdbsim_load): Remove char **argv local variable.
    	(gdbsim_open): Rename gdb_argv args object to argv.

commit b7a18930e3925c4092bd975e95bc3603aa1418d9
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Aug 7 10:09:51 2017 +0100

    Do not choose a non-ELF format input file to hold the linker created GOT sections.
    
    	PR 21884
    	* elf32-i386.c (elf_i386_link_setup_gnu_properties): If the dynobj
    	has not been set then use the bfd returned by
    	_bfd_elf_link_setup_gnu_properties.  If that is null then search
    	through all the input bfds selecting the first normal, ELF format
    	one.
    	* elf64-x86-64.c (elf_x86_64_link_setup_gnu_properties): Likewise.

commit 2010d1a3f87927c3f41b3a2509dec13f4f72ef19
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Aug 7 00:01:03 2017 +0000

    Automatic date update in version.in

commit 1d4af308ae58f459a2bfc50de70832284f1d3d2a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 6 08:40:56 2017 -0700

    x86: Lookup __tls_get_addr or ___tls_get_addr once
    
    Instead of checking if a symbol is __tls_get_addr or ___tls_get_addr,
    we check if there is a reference to __tls_get_addr or ___tls_get_addr
    before starting relocation check.
    
    	* elf32-i386.c (elf_i386_link_hash_entry): Change tls_get_addr
    	to 1 bit.
    	(elf_i386_link_hash_newfunc): Initialize tls_get_addr to 0.
    	(elf_i386_check_tls_transition): Check tls_get_addr directly.
    	(elf_i386_convert_load_reloc): Update tls_get_addr check.
    	(elf_i386_link_check_relocs): New function.
    	(bfd_elf32_bfd_link_check_relocs): New.
    	* elf64-x86-64.c (elf_x86_64_link_hash_entry): Change tls_get_addr
    	to 1 bit.
    	(elf_x86_64_link_hash_newfunc): Initialize tls_get_addr to 0.
    	(elf_x86_64_check_tls_transition): Check tls_get_addr directly.
    	(elf_x86_64_convert_load_reloc): Update tls_get_addr check.
    	(elf_x86_64_link_check_relocs): New function.
    	(bfd_elf64_bfd_link_check_relocs): New.
    	(bfd_elf32_bfd_link_check_relocs): Likewise.

commit a4819f54c0006554179631189131080be859eefb
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sun Aug 6 08:18:53 2017 -0700

    Treat common symbol as undefined for --no-define-common
    
    When --no-define-common is used to build shared library, treat common
    symbol as undefined so that common symbols that are referenced from a
    shared library to be assigned addresses only in the main program.  This
    eliminates the unused duplicate space in the shared library, and also
    prevents any possible confusion over resolving to the wrong duplicate
    when there are many dynamic modules with specialized search paths for
    runtime symbol resolution.
    
    --no-define-common is only allowed when building a shared library.
    
    bfd/
    
    	PR ld/21903:
    	* elflink.c (elf_link_add_object_symbols): Treat common symbol
    	as undefined for --no-define-common.
    
    include/
    
    	PR ld/21903:
    	* bfdlink.h (bfd_link_info): Add inhibit_common_definition.
    
    ld/
    
    	PR ld/21903:
    	* ld.h (command_line): Remove inhibit_common_definition.
    	* ldgram.y: Replace command_line.inhibit_common_definition with
    	link_info.inhibit_common_definition.
    	* ldlang.c (lang_common): Likewise.
    	* lexsup.c (parse_args): Likewise.
    	* ldmain.c (main): Only allow --no-define-common with -shared.
    	* testsuite/ld-elf/pr21903.s: New file.
    	* testsuite/ld-elf/pr21903a.d: Likewise.
    	* testsuite/ld-elf/pr21903b.d: Likewise.
    	* testsuite/ld-elf/pr21903c.d: Likewise.
    	* testsuite/ld-elf/pr21903d.d: Likewise.
    	* testsuite/ld-elf/pr21903e.d: Likewise.

commit e2a084f2c152f6358ba926df22a313d3ef8d8509
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Aug 6 00:00:44 2017 +0000

    Automatic date update in version.in

commit ee0c32930c355b73172b2bef987e2a48ea909b12
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Jul 31 15:49:21 2017 -0600

    Use gdb::unique_xmalloc_ptr when calling tilde_expand
    
    This patch changes most sites calling tilde_expand to use
    gdb::unique_xmalloc_ptr, rather than a cleanup.  It also changes
    scan_expression_with_cleanup to return a unique pointer, because the
    patch was already touching code in that area.
    
    Regression tested on the buildbot.
    
    ChangeLog
    2017-08-05  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile-object-load.c (compile_object_load): Use
    	gdb::unique_xmalloc_ptr.
    	* cli/cli-dump.c (scan_filename): Rename from
    	scan_filename_with_cleanup.  Change return type.
    	(scan_expression): Rename from scan_expression_with_cleanup.
    	Change return type.
    	(dump_memory_to_file, dump_value_to_file, restore_command):
    	Use gdb::unique_xmalloc_ptr.  Update.
    	* cli/cli-cmds.c (find_and_open_script): Use
    	gdb::unique_xmalloc_ptr.
    	* tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
    	* symmisc.c (maintenance_print_symbols)
    	(maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
    	* symfile.c (symfile_bfd_open, generic_load)
    	(add_symbol_file_command, remove_symbol_file_command): Use
    	gdb::unique_xmalloc_ptr.
    	* source.c (openp): Use gdb::unique_xmalloc_ptr.
    	* psymtab.c (maintenance_print_psymbols): Use
    	gdb::unique_xmalloc_ptr.
    	* corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
    	* breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
    	* solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
    	(reload_shared_libraries_1): Likewise.

commit fdffd6f4118652bdfdff383943f13664af4b9a45
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Aug 5 15:38:32 2017 -0600

    Fix Rust test suite for 1.20 beta
    
    I ran the gdb.rust tests against Rust 1.20 (beta) and saw a few
    failures.  The failures all came because a particular item moved to a
    different module.  Since the particular choice of module name isn't
    important here, I simply widened the allowable results.
    
    Tested locally against rustc 1.19, 1.20, and 1.21.
    
    testsuite/ChangeLog
    2017-08-05  Tom Tromey  <tom@tromey.com>
    
    	* gdb.rust/simple.exp: Allow String to appear in a different
    	namespace.

commit 3232fabd2d0094d74bd942a1f2c5c284b0cd9260
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Aug 4 07:30:26 2017 -0600

    Remove cleanups from Rust parser
    
    This removes the few remaining cleanups in the Rust language code.
    The main difficulty here was that the earlier code allocated VEC heads
    on an obstack.  The new code instead introduces an object that
    allocates and maintains the storage for whatever vectors are needed
    during the parse.
    
    Regression tested on the buildbot.
    
    ChangeLog
    2017-08-05  Tom Tromey  <tom@tromey.com>
    
    	* rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
    	(rust_op_vector, rust_set_vector): New typedefs.
    	(current_parser): New global.
    	(work_obstack): Change to pointer type.  Update all users.
    	(rust_ast, pstate): Remove globals.
    	(struct rust_parser): New.
    	(%union) <params, field_inits>: Change type.
    	(start, tuple_expr, unit_expr, struct_expr_list, literal)
    	(field_expr, expr_list, maybe_expr_list, type_list): Update.
    	(ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
    	(convert_params_to_types, convert_params_to_expression): Change
    	type of "params".
    	(ast_string): Change type of "fields".
    	(rust_parse): Make a rust_parser.  Remove cleanups.
    	(rust_lex_tests): Make and install an auto_obstack.

commit 55ef6584ca8466e293e9f1b310c0bf44500c11b6
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Aug 5 23:28:21 2017 +0930

    Don't fail in elf32_hppa_set_gp
    
    The base bfd_link_hash_table works fine here, the only thing to watch
    out for is to only set elf_gp if the output is ELF.
    
    bfd/
    	* elf32-hppa.c (elf32_hppa_set_gp): Don't require an
    	hppa_link_hash_table.
    ld/
    	* testsuite/ld-unique/pr21529.d: Don't xfail hppa.

commit a66930b357fee4ae716bfc8816e78c0f9c024005
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Aug 5 00:00:19 2017 +0000

    Automatic date update in version.in

commit b4dfc244480951aa8e15aa79fa3e7691eb974914
Merge: f86c4d2 f02fd77
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 4 10:26:43 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit f02fd7745d003d65fd3b981618e07b874b721d79
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 4 16:02:51 2017 +0100

    Unbreak GDBserver build for x32
    
    When I verify my target description changes, I build GDB and GDBserver for
    x32, but it failed.
    
    /../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c
    ../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c: In function â??const target_desc* get_ipa_tdesc(int)â??:
    ../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:184:10: error: â??X86_TDESC_AVX512â?? was not declared in this scope
         case X86_TDESC_AVX512:
              ^
    ../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:185:14: error: â??tdesc_x32_avx512_linuxâ?? was not declared in this scope
           return tdesc_x32_avx512_linux;
                  ^
    ../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c: In function â??void initialize_low_tracepoint()â??:
    ../../../binutils-gdb/gdb/gdbserver/linux-amd64-ipa.c:282:36: error: â??init_registers_x32_avx512_linuxâ?? was not declared in this scope
       init_registers_x32_avx512_linux ();
                                        ^
    
    ipa_x32_linux_regobj use to be there, but removed by
    22049425ce40324139be82d9a6ec518c46b65815 by mistake.
    
    gdb/gdbserver:
    
    2017-08-04  Yao Qi  <yao.qi@linaro.org>
    
    	* configure.srv (ipa_x32_linux_regobj): New.
    	* linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
    	instead of X86_TDESC_AVX512.
    	(initialize_low_tracepoint): Call
    	init_registers_x32_avx_avx512_linux.

commit 91975afd35bb0c6c0fc5ce0794ec0ae8ebe2f805
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Aug 4 14:27:58 2017 +0100

    Add namespace std to nullptr_t
    
    This patch fixes the build failure for target i686-w64-mingw32,
    
    In file included from ../../binutils-gdb/gdb/defs.h:786:0,
                     from ../../binutils-gdb/gdb/gdb.c:19:
    ../../binutils-gdb/gdb/utils.h:188:20: error: â??nullptr_tâ?? has not been declared
       bool operator!= (nullptr_t)
                        ^
    ../../binutils-gdb/gdb/utils.h:193:20: error: â??nullptr_tâ?? has not been declared
       bool operator== (nullptr_t)
                        ^
    
    gdb:
    
    2017-08-04  Yao Qi  <yao.qi@linaro.org>
    
    	* utils.h (gdb_argv): Add namespace std for nullptr_t.

commit 9f06dab1e3acfb675669348a3ff331580d4eaf1e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Aug 4 05:39:56 2017 -0700

    Add a testcase for "ld -d"
    
    "ld -d" assigns space to common symbols even if a relocatable output
    file is specified (with '-r').
    
    	PR ld/21904
    	* testsuite/ld-elf/pr21904.d: New file.
    	* testsuite/ld-elf/pr21904.s: Likewise.

commit 223b97ba9d9d1aa61bf22058f637c779c7621e6f
Author: James Clarke <jrtc27@jrtc27.com>
Date:   Thu Aug 3 22:44:21 2017 -0700

    Add --no-relax option.
    
    gold/
    	* options.h (General_options): Set a non-NULL second help string
    	argument for relax to allow --no-relax.

commit a30d3a7990e73c54e0bab9933e48989376770162
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Aug 4 00:00:52 2017 +0000

    Automatic date update in version.in

commit 2331fa3af560ee880d50e28bf841e1bc05b0c3de
Author: Ruslan Kabatsayev <b7.10110111@gmail.com>
Date:   Thu Aug 3 09:11:45 2017 +0300

    Add myself as a write-after-approval GDB maintainer.

commit f86c4d2552e1f1cff450b00f6965f501017eed64
Merge: be09588 744e4fe
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Aug 3 08:37:19 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 744e4fe1db7099d91f71c50c83708cfef5d3d0c8
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Jul 23 15:52:59 2017 -0600

    Remove make_cleanup_freeargv and gdb_buildargv
    
    After the previous patches in this series, make_cleanup_freeargv and
    gdb_buildargv are now unused and can be removed.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
    	Remove.
    	* utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.

commit 1c034b67a03ed928eb3916034eb1e782a8188520
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 23:03:58 2017 -0600

    Use gdb_argv in Python
    
    This changes one spot in the Python code to use gdb_argv.  This
    removes the last cleanup from the Python layer.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* python/py-param.c (compute_enum_values): Use gdb_argv.

commit 773a1edcd1086fc76a91055bec67e2d14d76940d
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 23:02:30 2017 -0600

    Introduce gdb_argv, a class wrapper for buildargv
    
    This introduces gdb_argv, a class wrapping an "argv" pointer; that is,
    a pointer to a NULL-terminated array of char*, where both the array
    and each non-NULL element in the array are xmalloc'd.
    
    This patch then changes most users of gdb_buildargv to use gdb_argv
    instead.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.h (struct gdb_argv_deleter): New.
    	(gdb_argv): New class.
    	* utils.c (gdb_argv::reset): New method.
    	* tracepoint.c (delete_trace_variable_command): Use gdb_argv.
    	* tracefile.c (tsave_command): Use gdb_argv.
    	* top.c (new_ui_command): Use gdb_argv.
    	* symmisc.c (maintenance_print_symbols)
    	(maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
    	* symfile.c (symbol_file_command, generic_load)
    	(remove_symbol_file_command): Use gdb_argv.
    	* stack.c (backtrace_command): Use gdb_argv.
    	* source.c (add_path, show_substitute_path_command)
    	(unset_substitute_path_command, set_substitute_path_command):
    	Use gdb_argv.
    	* skip.c (skip_command): Use gdb_argv.  Use gdb_buildargv.
    	* ser-mingw.c (pipe_windows_open): Use gdb_argv.
    	* remote.c (extended_remote_run, remote_put_command)
    	(remote_get_command, remote_delete_command): Use gdb_argv.
    	* remote-sim.c (gdbsim_load, gdbsim_create_inferior)
    	(gdbsim_open): Use gdb_argv.
    	* python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
    	* psymtab.c (maintenance_print_psymbols): Use gdb_argv.
    	* procfs.c (procfs_info_proc): Use gdb_argv.
    	* interps.c (interpreter_exec_cmd): Use gdb_argv.
    	* infrun.c (handle_command): Use gdb_argv.
    	* inferior.c (add_inferior_command, clone_inferior_command):
    	Use gdb_argv.
    	* guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
    	* exec.c (exec_file_command): Use gdb_argv.
    	* cli/cli-cmds.c (alias_command): Use gdb_argv.
    	* compile/compile.c (build_argc_argv): Use gdb_argv.

commit 0d50bde32b92821c9f1f660d273e6c996d26dc9f
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 22:12:13 2017 -0600

    Remove a cleanup in Python
    
    This removes cleanups from gdbpy_decode_line, in favor of a use of
    unique_xmalloc_ptr.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.

commit 7f968c899f21643322dcfaf807ec7d7bee7c9974
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 22:10:41 2017 -0600

    Avoid some manual memory management in Python
    
    This changes a few places in the Python code to avoid manual memory
    management, in favor of letting std::string do the work.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* python/python.c (compute_python_string): Return std::string.
    	(gdbpy_eval_from_control_command): Update.
    	(do_start_initialization): Use std::string.
    	* python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
    	xstrprintf.
    	* python/py-breakpoint.c (local_setattro): Use string_printf, not
    	xstrprintf.

commit 3c9ebddd93ffb8b44b8cc69f3be9db08c861368e
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 21:17:58 2017 -0600

    Replace do_restore_instream_cleanup with scoped_restore
    
    This changes the users of do_restore_instream_cleanup to use a
    scoped_restore instead.  This patch is broken out because it warrants
    some additional attention: in particular it's unclear to me whether
    current_ui can change in the body of these functions -- but if it can,
    then the cleanup would have modified a different UI's instream member.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* top.h (do_restore_instream_cleanup): Remove.
    	* top.c (do_restore_instream_cleanup): Remove.
    	(read_command_file): Use scoped_restore.
    	* cli/cli-script.c (execute_user_command): Use scoped_restore.

commit b51b225eb9b03b627967108ee3de38ada5de219d
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 21:15:58 2017 -0600

    Use a scoped_restore for command_nest_depth
    
    This changes a couple of places to use a scoped_restore when
    manipulating command_nest_depth.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-script.c (execute_user_command)
    	(execute_control_command): Use scoped_restore.

commit ac991630ca57ba6a00d0d1358786164248d140fc
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 21:08:31 2017 -0600

    Remove user_call_depth
    
    This changes execute_user_command to remove user_call_depth, using the
    size of user_args_stack instead.  This avoids a cleanup.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-script.c (do_restore_user_call_depth): Remove.
    	(execute_user_command): Remove user_call_depth; use
    	user_args_stack's size instead.

commit 898e0c8e879394ce0fb8a08fe85929a29f3ce55b
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 30 21:04:51 2017 -0600

    Remove in_user_command
    
    While working on the next patch in this series, I found that the
    global in_user_command is not used.  This patch removes it.  (I didn't
    think to check Insight until submitting this series; and it's not very
    convenient to do so, so if someone has it checked out and could look
    at it, that would be nice.)
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* top.h (in_user_command): Remove.
    	* top.c (in_user_command): Remove.
    	* cli/cli-script.c (do_restore_user_call_depth)
    	(execute_user_command): Update.

commit 26fcd5d7572ea1bf0cc697158969749420900e0b
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Apr 28 23:34:32 2017 -0600

    Use containers to avoid cleanups
    
    This patch introduces the use of various containers -- std::vector,
    std::string, or gdb::byte_vector -- in several spots in gdb that were
    using xmalloc and a cleanup.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* valops.c (search_struct_method): Use gdb::byte_vector.
    	* valarith.c (value_concat): Use std::vector.
    	* target.c (memory_xfer_partial): Use gdb::byte_vector.
    	(simple_search_memory): Likewise.
    	* printcmd.c (find_string_backward): Use gdb::byte_vector.
    	* mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
    	* gcore.c (gcore_copy_callback): Use gdb::byte_vector.
    	* elfread.c (elf_rel_plt_read): Use std::string.
    	* cp-valprint.c (cp_print_value): Use gdb::byte_vector.
    	* cli/cli-dump.c (restore_section_callback): Use
    	gdb::byte_vector.

commit 7c218e6c9c88cb8120adf1a7a530cfdec23aaf81
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Apr 28 23:08:16 2017 -0600

    Use unique_xmalloc_ptr in jit.c
    
    This removes some cleanups from jit.c by using unique_xmalloc_ptr
    instead.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.

commit 31b68d4ad72ebb153e48e16c8d9edf3676a8af38
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Apr 28 22:59:24 2017 -0600

    Replace tui_restore_gdbout with scoped_restore
    
    This patch replaces tui_restore_gdbout (a cleaup function) with a use
    of scoped_restore.  This one is broken out into its own patch because
    it might slightly change the behavior of gdb: it saves and restores
    pagination_enabled, whereas the tui_restore_gdbout unconditionally set
    pagination_enabled to 1; and I think this warrants closer review.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* tui/tui-regs.c (tui_restore_gdbout): Remove.
    	(tui_register_format): Use scoped_restore.

commit 2ec845e758762030f2333c21fa532fc57fe3762f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 22:53:40 2017 -0600

    More uses of scoped_restore
    
    There were a few more places in gdb that could easily use
    scoped_restore, replacing some cleanups.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* reverse.c (exec_direction_default): Remove.
    	(exec_reverse_once): Use scoped_restore.
    	* remote.c (restore_remote_timeout): Remove.
    	(remote_flash_erase, remote_flash_write, remote_flash_done)
    	(readchar, remote_serial_write): Use scoped_restore.
    	* cli/cli-script.c (struct source_cleanup_lines_args)
    	(source_cleanup_lines): Remove.
    	(script_from_file): Use scoped_restore.
    	* cli/cli-cmds.c (source_verbose_cleanup): Remove.
    	(source_command): Use scoped_restore.

commit b3bc84537bc6de78e2bbd550ce9c57dd4b7e2ec6
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Apr 28 22:43:54 2017 -0600

    Remove make_cleanup_free_so
    
    make_cleanup_free_so is used in a single spot.  This patch introduces
    a unique pointer wrapper for struct so_list, and changes this spot to
    use it.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.h (make_cleanup_free_so): Remove.
    	* utils.c (do_free_so, make_cleanup_free_so): Remove.
    	* solist.h (struct so_deleter): New.
    	(so_list_up): New typedef.
    	* solib-svr4.c (svr4_read_so_list): Use so_list_up.

commit e3ad2841b1c75837a901618651fed23013643e3f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 22:41:30 2017 -0600

    Remove make_cleanup_restore_current_language
    
    This patch replaces make_cleanup_restore_current_language with an RAII
    class that saves the current language, and restores it when the object
    is destroyed.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.h (make_cleanup_restore_current_language): Remove.
    	* utils.c (do_restore_current_language)
    	(make_cleanup_restore_current_language): Remove.
    	* parse.c (parse_exp_in_context_1)
    	(parse_expression_with_language): Use
    	scoped_restore_current_language.
    	* mi/mi-main.c (mi_cmd_execute): Use
    	scoped_restore_current_language.
    	* language.h (scoped_restore_current_language): New class.

commit b80cf838447322778f04059a1f58b78ffbbeb597
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 22:12:50 2017 -0600

    Remove an unlink cleanup
    
    compile/compile.c had its own cleanup to unlink a file.  This patch
    replaces this cleanup with gdb::unlinker.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* compile/compile.c (cleanup_unlink_file): Remove.
    	(compile_to_object): Use gdb::unlinker.
    	(eval_compile_command): Likewise.

commit fad0444a57f4715c1afc9b0331014374e6faccb6
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 22:03:42 2017 -0600

    Remove make_cleanup_fclose
    
    After the preceding patches, make_cleanup_fclose is no longer used, so
    remove it.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* utils.h (make_cleanup_fclose): Remove.
    	* utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.

commit 6e7bc05c53fe65089f290757a72508356b491a6f
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 22:03:08 2017 -0600

    Change open_terminal_stream to return a gdb_file_up
    
    This changes open_terminal_stream to return a gdb_file_up, eliminating
    another use of make_cleanup_fclose.  Arguably perhaps new_ui should
    take ownership of the files using a move, but there is at least one
    spot where this isn't appropriate (or at least not currently done), so
    I elected to use a more minimal approach.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* top.c (open_terminal_stream): Return gdb_file_up.
    	(new_ui_command): Update.

commit 4a45905b825ef230a3fbf6bb7857339b39e5af16
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 21:56:14 2017 -0600

    Use gdb_file_up in source.c
    
    This changes some functions in source.c to use gdb_file_up.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* source.c (print_source_lines_base, forward_search_command)
    	(reverse_search_command): Use gdb_file_up.

commit 7cd06d6e89c9c17d358d8edf0b7faa9dd87edc3e
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 21:52:52 2017 -0600

    Use gdb_file_up in fbsd-nat.c
    
    This updates fbsd-nat.c to use gdb_file_up.  This removes a use of a
    cleanup, and helps remove make_cleanup_fclose in a later patch.
    
    I have no way to test this patch.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* fbsd-nat.c (fbsd_find_memory_regions): Update.

commit ed1669453be56d71351c77377acee097aefe83b1
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 21:49:55 2017 -0600

    Change return type of find_and_open_script
    
    This changes find_and_open_script to return a
    gdb::optional<open_script>, where open_script is a new type
    encapsulating the two return values.  The new type helps avoid
    cleanups in the callers.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* cli/cli-cmds.c (find_and_open_script): Change return type.
    	Remove "streamp" and "full_path" parameters.
    	(source_script_with_search): Update.
    	* auto-load.c (source_script_file): Update.
    	* cli/cli-cmds.h (find_and_open_script): Change type.
    	(open_script): New struct.

commit d419f42dd3f3635fc036413258ed530676998191
Author: Tom Tromey <tom@tromey.com>
Date:   Wed Apr 26 21:39:46 2017 -0600

    Introduce and use gdb_file_up
    
    This introduces gdb_file_up, a unique pointer holding a FILE*, and
    then changes some code in gdb to use it.  In particular
    gdb_fopen_cloexec now returns a gdb_file_up.  This allow removing some
    cleanups.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* xml-support.c (xml_fetch_content_from_file): Update.
    	* ui-file.c (stdio_file::open): Update.
    	* tracefile-tfile.c (tfile_start): Update.
    	* remote.c (remote_file_put, remote_file_get): Update.
    	* nat/linux-procfs.c (linux_proc_get_int)
    	(linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
    	* nat/linux-osdata.c (linux_common_core_of_thread): Update.
    	(command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
    	(print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
    	(linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
    	* nat/linux-btrace.c (linux_determine_kernel_start): Update.
    	* linux-nat.c (linux_proc_pending_signals): Update.
    	* dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
    	(file_closer): Remove.
    	* compile/compile.c (compile_to_object): Update.
    	* common/filestuff.h (struct gdb_file_deleter): New.
    	(gdb_file_up): New typedef.
    	(gdb_fopen_cloexec): Change return type.
    	* common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
    	* cli/cli-dump.c (fopen_with_cleanup): Remove.
    	(dump_binary_file, restore_binary_file): Update.
    	* auto-load.c (auto_load_objfile_script_1): Update.

commit 4a2b031d5452226cf7894f313b3aac603f7ec5fb
Author: Tom Tromey <tom@tromey.com>
Date:   Sun Apr 23 10:21:50 2017 -0600

    Introduce and use ui_out_emit_table
    
    This introduces ui_out_emit_table, similar to the other existing
    ui_out RAII classes, and then uses it in a number of places.  This
    replaces some cleanups.
    
    ChangeLog
    2017-08-03  Tom Tromey  <tom@tromey.com>
    
    	* tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
    	(info_static_tracepoint_markers_command): Likewise.
    	* solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
    	* skip.c (skip_info): Use ui_out_emit_table.
    	* progspace.c (print_program_space): Use ui_out_emit_table.
    	* osdata.c (info_osdata): Use ui_out_emit_table.
    	* mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
    	ui_out_emit_table.
    	* linux-thread-db.c (info_auto_load_libthread_db): Use
    	ui_out_emit_table.
    	* inferior.c (print_inferior): Use ui_out_emit_table.
    	* gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
    	* breakpoint.c (breakpoint_1): Use ui_out_emit_table.
    	* auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
    	* ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
    	* ui-out.h (class ui_out_emit_table): New.

commit fd9770d81fba7ad860e8bcfbc13c77f21041f1f3
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Aug 3 11:59:32 2017 +0100

    Add more targets to the list of architectures not supporting format changing during linking.  Fix seg-faults triggered when this is attempted.
    
    	PR ld/21884
    	* testsuite/ld-elf/pr21884.d: Add AVR, HPPA, IA64, M68HC1x and
    	SCORE to list of targets not supporting file format changes during
    	linking.
    	* testsuite/ld-unique/pr21529.d: Likewise.
    	* emultempl/avrelf.em (_before_allocation): Skip for non-ELF
    	output formats.
    	(avr_elf_create_output_section_statements): Fail if the output
    	format is not ELF.
    	(avr_finish): Do not access the ELF header in non-ELF format
    	output bfds.
    	* emultempl/m68hc1xelf.em (_before_allocation): Skip for non-ELF
    	output formats.
    	(m68hc11elf_create_output_section_statements): Fail if the putput
    	format is not ELF.
    	(m68hc11elf_after_allocation): Skip for non-ELF output formats.

commit 2e9246e077cdbbff0a56a810c5750cc895382ba3
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 3 14:01:34 2017 +0930

    ELF checks for orphan placement
    
    The loop checking for previous orphan placement should run even when
    the output is non-ELF.
    
    	PR ld/21884
    	* emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Revert
    	last change.  Rename iself to elfinput.  Expand comments.  Condition
    	ELF checks on having both input and output ELF files.  Extract..
    	(elf_orphan_compatible): ..this new function.

commit 5f66bad45bdf1c9a9806ed27e64b724d6ba50b16
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Aug 3 00:01:14 2017 +0000

    Automatic date update in version.in

commit a4f320fd1b535bb80dc9a3ba7c50ee0061ec0c6f
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Aug 2 16:40:16 2017 +0100

    MIPS: Factor out FPU type naming in `gdbarch' debug
    
    Replace chains of conditional expressions used in target-dependent MIPS
    `gdbarch' debug output to get a textual name of the FPU type with calls
    to a helper decoder function, improving code readability.  No functional
    change.
    
    	gdb/
    	* mips-tdep.c (mips_fpu_type_str): New function.
    	(mips_dump_tdep): Call it.

commit db99ecc08f5b66fbe9cb72e90352c7f77ec71a6e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 2 05:10:29 2017 -0700

    Check ELF section header only for ELF output
    
    When placing an orphan input section, check ELF section header only for
    ELF output.
    
    	PR ld/21884
    	* emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Check
    	ELF section header only for ELF output.
    	* testsuite/ld-elf/pr21884.d: New test.
    	* testsuite/ld-elf/pr21884.t: Likewise.
    	* testsuite/ld-elf/pr21884a.s: Likewise.
    	* testsuite/ld-elf/pr21884b.s: Likewise.

commit b8f4abd342cc54bc2b90c796a2aae93e6c3bda6b
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 2 05:08:41 2017 -0700

    Revert the last change to emultempl/elf32.em
    
    It will be replaced by a different fix.
    
    	* emultempl/elf32.em (_place_orphan): Revert the last change.

commit 70b0cf90bc6c071895b989666bcf3e6eca7b99ce
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Aug 2 12:12:37 2017 +0100

    Add support for creating archives of slim-LTO modules using MRi script commands.
    
    	PR 21702
    	* arsup.c (ar_addmod): Add plugin support for the MRI ADDMOD
    	command.

commit 73d5923e480944e2d66bde8c59f4dff298ec57e3
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Wed Aug 2 11:48:07 2017 +0100

    Fix assertion failure for xtensa linker.
    
    	* emultempl/xtensaelf.em (xtensa_wild_group_interleave_callback):
    	Only check for by_name sorting.

commit ddff3d84be42fa80c2c9aaa635f2b9269e74e4f9
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Aug 2 11:45:05 2017 +0100

    Fix seg-fault when trying to place non-ELF orphan sections.
    
    	PR 21884
    	* emultempl/elf32.em (_place_orphan): Skip non-ELF binaries when
    	looking for sections to merge.

commit d84ed528d4817b0ff854006b65a9f6ec75f0407a
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Wed Aug 2 10:38:09 2017 +0100

    Fix potential illegal memory access in Xtensa port.
    
    	* xtensa-isa.c (xtensa_isa_init): Don't update lookup table
    	entries for sysregs with negative indices.

commit 75800d2cd6a6cea6071dcf8f0c2ea871abeeaf99
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Aug 2 10:19:22 2017 +0100

    Fix gas and binutils testsuite failures for am33_2.0-linux target.
    
    gas	* testsuite/gas/all/gas.exp: Add am33 to the skip lists of tests
    	passed over by the mn10300 target.
    	* testsuite/gas/elf/elf.exp: Likewise.
    	* testsuite/gas/elf/dwarf2-11.d: Correct skip of am33 target.
    	* testsuite/gas/elf/dwarf2-12.d: Likewise.
    	* testsuite/gas/elf/dwarf2-13.d: Likewise.
    	* testsuite/gas/elf/dwarf2-14.d: Likewise.
    	* testsuite/gas/elf/dwarf2-15.d: Likewise.
    	* testsuite/gas/elf/dwarf2-16.d: Likewise.
    	* testsuite/gas/elf/dwarf2-17.d: Likewise.
    	* testsuite/gas/elf/dwarf2-18.d: Likewise.
    	* testsuite/gas/elf/dwarf2-5.d: Likewise.
    	* testsuite/gas/elf/dwarf2-6.d: Likewise.
    	* testsuite/gas/elf/dwarf2-7.d: Likewise.
    
    binutils * testsuite/binutils-all/objdump.exp (cpus_expected): Add am33-2.

commit 262cdac76d010307e601d1a7da49a0cc1a53be05
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Aug 2 15:18:56 2017 +0930

    Teach readelf about IA64 MSB relocs.
    
    	* readelf.c (is_32bit_abs_reloc): Add R_IA64_SECREL32MSB and
    	R_IA64_DIR32MSB.
    	(is_64bit_abs_reloc): Add R_IA64_DIR64MSB.
    	(is_64bit_pcrel_reloc): Add R_IA64_PCREL64MSB.

commit a5be90a4d95b535a67e4e249e733b208d36c1e56
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Aug 2 00:00:53 2017 +0000

    Automatic date update in version.in

commit a2f1f308535745e1e8b1896945cfe4ce0aae59e7
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Aug 1 19:32:25 2017 +0100

    MIPS: Consistently use MIPS_FPU_TYPE for `gdbarch' member
    
    Complement commit 74ed0bb4148e ("Replace current_gdbarch in *mips*"),
    <https://sourceware.org/ml/gdb-patches/2008-06/msg00490.html>, and
    consistently use the MIPS_FPU_TYPE macro to access the `->mips_fpu_type'
    target-dependent `gdbarch' member.  No functional change.
    
    	gdb/
    	* mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
    	`->mips_fpu_type'.

commit 1ef692ea23714876cc30b1a3ab3ef33a1369f17a
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Tue Aug 1 15:13:40 2017 +0200

    S/390: Fix claimfile failures
    
    This fixes a segfault when trying to access the local_plt field in the
    s390 specific elf data althoug the underlaying object is a generic elf
    object.
    
    This fixes the following testsuite failures:
    
    < FAIL: plugin claimfile replace symbol with source
    < FAIL: plugin claimfile resolve symbol with source
    < FAIL: plugin claimfile replace file with source
    < FAIL: plugin set symbol visibility with source
    < FAIL: plugin ignore lib with source
    < FAIL: plugin claimfile replace lib with source
    < FAIL: plugin 2 with source lib
    < FAIL: load plugin 2 with source
    < FAIL: plugin 3 with source lib
    < FAIL: load plugin 3 with source
    
    bfd/ChangeLog:
    
    2017-08-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf32-s390.c (elf_s390_finish_dynamic_sections): Skip if it
    	isn't the S/390 specific elf data.
    	* elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.

commit 4d36230d59903b92fbe2b53b31ed64a884860f0e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Aug 1 05:53:27 2017 -0700

    x86: Update segment register check in Intel syntax
    
    https://sourceware.org/ml/binutils/2009-04/msg00223.html
    
    introduced a new Intel syntax parser which accepts
    
    	mov	eax, fs:gs:[eax]
    
    It ignores anything between ':'s after fs and treats
    
    	mov	eax, DWORD PTR fs:foobar:16
    	mov	eax, DWORD PTR fs:foobar:barfoo:16
    	mov	eax, DWORD PTR fs:ds:16
    	mov	eax, DWORD PTR fs:ds:cs:16
    
    as
    
    	mov	eax, DWORD PTR fs:16
    
    This patch updates segment register check and only allows a single ':'.
    
    	PR gas/21874
    	* config/tc-i386-intel.c (i386_intel_operand): Update segment
    	register check.
    	* testsuite/gas/i386/intelok.s: Replace "fs:gs:[eax]" with
    	"fs:[eax]".
    	* testsuite/gas/i386/inval-seg.s: Add tests for invalid segment
    	register.
    	* testsuite/gas/i386/x86-64-inval-seg.s: Likewise.
    	* testsuite/gas/i386/inval-seg.l: Updated.
    	* testsuite/gas/i386/x86-64-inval-seg.l: Likewise.

commit 60c4393c5085dcae64c84a51590f8a98199f9221
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Aug 1 08:24:22 2017 +0100

    Updated Swedish translation for the binutils sub-directory.
    
    	* po/sv.po: Updated Swedish translation.

commit be897fb774abfb0a44b3b87fe77bccafa336e638
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Aug 1 14:08:53 2017 +0930

    [GOLD] PowerPC recreate eh_frame for stubs on each relax pass
    
    There is a very small but non-zero probability that a stub group
    contains stubs on one relax pass, but does not on the next.  In that
    case we would get an FDE covering a zero length address range.
    (Actually, it's even worse.  Alignment padding for stubs can mean the
    address for the non-existent stubs is past the end of the original
    section to which stubs are attached, and due to the way
    do_plt_fde_location calculates the length we can get a negative
    length.)  Fixing this properly requires removing the FDE.
    
    Also, I have been implementing the __tls_get_addr_opt support for
    gold, and that stub needs something other than the default FDE.  The
    necessary FDE will depend on the offset to the __tls_get_addr_opt
    stub, which of course can change during relaxation.  That means at the
    very least, rewriting the FDE on each pass, possibly changing the FDE
    size.  I think that is better done by completely recreating PLT
    eh_frame FDEs.
    
    	* ehframe.cc (Fde::operator==): New.
    	(Cie::remove_fde, Eh_frame::remove_ehframe_for_plt): New.
    	* ehframe.h (Fde::operator==): Declare.
    	(Cie::remove_fde, Eh_frame::remove_ehframe_for_plt): Likewise.
    	* layout.cc (Layout::remove_eh_frame_for_plt): New.
    	* layout.h (Layout::remove_eh_frame_for_plt): Declare.
    	* powerpc.cc (Target_powerpc::do_relax): Remove old eh_frame FDEs.
    	(Stub_table::add_eh_frame): Delete eh_frame_added_ condition.
    	Don't add eh_frame for empty stub section.
    	(Stub_table::remove_eh_frame): New.

commit 51b69c74c6464c59a5621d6f3d3967a576043fa8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Aug 1 00:00:54 2017 +0000

    Automatic date update in version.in

commit 2141b1100568d4b10d6f22e6cf1741f1816dc348
Author: Richard Henderson <rth@redhat.com>
Date:   Mon Jul 31 11:44:29 2017 -0700

    Update myself in MAINTAINERS

commit 2e957b16d45b8fe4396b16775f0b3fa77f71f0a0
Author: John David Anglin <danglin@gcc.gnu.org>
Date:   Mon Jul 31 12:51:25 2017 -0400

    Fix bb instructions with double-word condition on hppa.

commit 575934368531e7592a7576a39a4320d88007ce88
Author: Kuan-Lin Chen <rufus@andestech.com>
Date:   Mon Jul 31 15:33:48 2017 +0100

    Improve handling of ADD and SUB relocations on the RISCV target.
    
    	* elfxx-riscv.c (riscv_elf_add_sub_reloc): New function.
    	* (howto_table) [R_RISCV_ADD8]: Use riscv_elf_add_sub_reloc.
    	[R_RISCV_ADD16]: Likewise.
    	[R_RISCV_ADD32]: Likewise.
    	[R_RISCV_ADD64]: Likewise.
    	[R_RISCV_SUB6]: Likewise.
    	[R_RISCV_SUB8]: Likewise.
    	[R_RISCV_SUB16]: Likewise.
    	[R_RISCV_SUB32]: Likewise.
    	[R_RISCV_SUB64]: Likewise.

commit c48a4d983400ade9cfba0531905245eb454afe08
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 31 15:08:32 2017 +0100

    Fix compile time error when using ansidecl.h with an old version of GCC.
    
    	PR 21850
    	* ansidecl.h (OVERRIDE): Protect check of __cplusplus value with
    	#idef __cplusplus.

commit 7e5ed83b229681f57d807f79fbea3703c8121afa
Author: Xavier Roirand <roirand@adacore.com>
Date:   Mon Jul 31 14:36:24 2017 +0200

    Update ChangeLog (missed that in my previous commit)
    
    gdb/
            * ChangeLog: Add previous commit entry
    
    Change-Id: Ic4f07cca66126e73340f032f19a2d5029bf0d40a

commit aacb3b6dfc7a9162a049dada22f1079809188f02
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 31 19:53:49 2017 +0930

    [GOLD] PowerPC --no-tls-optimize
    
    This adds a --no-tls-optimize option for people who want to keep
    __tls_get_addr calls in an executable rather than optimizing such code
    sequences to IE/LE.
    
    Also tidy some formatting errors, rename a variable to better reflect
    its use, and tweak two functions that create pairs of GOT entries to
    first check whether the GOT entry already exists before potentially
    inserting the header via reserve(2).  Without the check it is possible
    to waste one GOT entry.
    
    	* options.h (no_tls_optimize): New powerpc option.
    	* powerpc.cc (Target_powerpc::abiversion, set_abiversion): Formatting.
    	(Target_powerpc::stk_toc): Formatting, fix comment.
    	(Target_powerpc::Track_tls::tls_get_addr_state): Rename from
    	tls_get_addr.
    	(Target_powerpc::optimize_tls_gd, optimize_tls_ld, optimize_tls_ie):
    	Return TLSOPT_NONE when !tls_optimize.
    	(Target_powerpc::add_global_pair_with_rel): Check
    	for existing reloc before reserving.
    	(Target_powerpc::add_local_tls_pair): Likewise.

commit 54387c7fe27848e41a51c1eccc6a24b3d6d3441f
Author: Marty Plummer <ntzrmtthihu777@gmail.com>
Date:   Mon Jul 31 10:31:18 2017 +0100

    Fix compiling zlib using x86_64-musl.
    
    	PR 21861
    	* winduni.c (codepages): Use cp1252 for codepage 0.

commit 791fb3d7a58b86e5f30229625dfd33659f33fd6e
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Jul 31 11:22:21 2017 +0200

    Fix documentation about rot agent expression bytecode
    
    The rot agent expression bytecode rotates the three items on the top of
    the stack.  It is not clear which way the rotation is.  However, the
    documentation currently shows this as the effect of the instructions:
    
       a b c => c b a
    
    which doesn't make sense, since the value b doesn't move.  The two
    valid possibilities I see are
    
      a b c => b c a
      a b c => c a b
    
    depending on which way you rotate.
    
    When looking at the gdbserver code, the top of the stack becomes the
    third item, and the next-to-top item becomes the top.  So the second
    form would be the right one, since in this notation the top of the stack
    is the rightmost element:
    
      a b c => c a b
    
    I adjusted the symbolic description and added a bit of text to make it
    more obvious.
    
    gdb/doc/ChangeLog:
    
    	* agentexpr.texi (rot): Fix symbolic description, improve
    	textual description.

commit 4bbd4ef219c5b4c7d437618ba8937af86dd1032e
Author: Xavier Roirand <roirand@adacore.com>
Date:   Fri Jun 9 11:36:36 2017 +0200

    darwin: handle recent version of dyld
    
    gdb/
            * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
    
    Change-Id: I45da25f46b3e452d44993b122a994c818d00020b

commit d44c746aedeb31aacd867edc2da30dedc1e63e15
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 31 10:18:46 2017 +0930

    PR 21847, PowerPC64 --plt-localentry again
    
    This makes ld warn about --plt-localentry if a version of glibc
    without the necessary ld.so checks is detected, and revises the
    documentation.
    
    bfd/
    	* elf64-ppc.c (ppc64_elf_tls_setup): Warn on --plt-localentry
    	without ld.so checks.
    gold/
    	* powerpc.cc (Target_powerpc::scan_relocs): Warn on --plt-localentry
    	without ld.so checks.
    ld/
    	* ld.texinfo (plt-localentry): Revise.

commit 93e0a1eab1c7963d77513aa503b129ea03cd6d39
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jul 31 00:00:25 2017 +0000

    Automatic date update in version.in

commit 10683b8d116a6b6c8063dd2e10263b3639816c6e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jul 30 00:00:45 2017 +0000

    Automatic date update in version.in

commit 8b5f1ed8777df405f3c7b87472b1506f5125aebe
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Jul 29 12:33:35 2017 +0930

    PR 21847, Don't default PowerPC64 to --plt-localentry
    
    The big comment in ppc64_elf_tls_setup says why.  I've also added some
    code to the bfd linker that catches the -lpthread -lc symbol
    differences and disable generation of optimized call stubs even when
    --plt-localentry is activated.  Gold doesn't yet have that.
    
    	PR 21847
    bfd/
    	* elf64-ppc.c (struct ppc_link_hash_entry): Add non_zero_localentry.
    	(ppc64_elf_merge_symbol): Set non_zero_localentry.
    	(is_elfv2_localentry0): Test non_zero_localentry.
    	(ppc64_elf_tls_setup): Default to --no-plt-localentry.
    gold/
    	* powerpc.cc (Target_powerpc::scan_relocs): Default to
    	--no-plt-localentry.
    ld/
    	* ld.texinfo (plt-localentry): Document.

commit ef080e7ed4a373037231e709bfa1a909f4eae0f9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jul 29 00:01:03 2017 +0000

    Automatic date update in version.in

commit 49ba15a23a9d3d8a109ce2fd5053822eee7f1fdf
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Jul 28 13:39:42 2017 -0700

    gold: Add put_ch_reserved to 64-bit Chdr_write
    
    The 64-bit ELF compression header has a reserved field.  It should be
    cleared to avoid random bits in it.
    
    elfcpp/
    
    	PR gold/21857
    	* elfcpp.h (Chdr_write): Add put_ch_reserved.
    	(Chdr_write<64, true>::put_ch_reserved): New.
    	(Chdr_write<64, false>::put_ch_reserved): Likewise.
    
    gold/
    
    	PR gold/21857
    	* compressed_output.cc (Output_compressed_section::set_final_data_size):
    	Call put_ch_reserved to clear the reserved field for 64-bit ELF.

commit 894dde0ba7eb0789fbc1009c9541ac6d68389968
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Fri Jul 28 18:34:34 2017 +0200

    Add missing changelog

commit 79c12faeea57e61364b6a7a3e411b096edce989c
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Fri Jul 28 17:59:25 2017 +0200

    S/390: Fix segfault when linking -shared -nostartfiles
    
    Regression-tested on s390x.
    
    bfd/ChangeLog:
    
    2017-07-28  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* elf32-s390.c (elf_s390_finish_dynamic_sections): Add NULL
    	pointer check for htab->elf.irelplt.
    	* elf64-s390.c (elf_s390_finish_dynamic_sections): Likewise.

commit 2b94abd48aef2d91bae1c35c8c10ebfb8757247d
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Fri Jul 28 13:01:10 2017 +0100

    Make some improvements to how SORT_* specifiers and EXCLUDE_FILE specifiers are handled in the linker script grammar.
    
    	* ldgram.y (ldgram_had_keep): Make static.
    	(ldgram_vers_current_lang): Likewise.
    	(filename_spec): New rule.
    	(input_section_spec_no_keep): Use filename_spec.
    	(wildcard_maybe_exclude): New rule.
    	(wildcard_spec): Rename to...
    	(section_name_spec): ...this.
    	(section_NAME_list): Rename to...
    	(section_name_list): ...this.
    	(section_name_spec): Simplifiy and use wildcard_maybe_exclude.
    	* ldlang.c (placed_commons): Delete.
    	(lang_add_wild): No longer set placed_commons.
    	(print_wild_statement): Use full names for SORT specifiers.
    	* testsuite/ld-scripts/align.exp: Run new tests.
    	* testsuite/ld-scripts/align3.d: New file.
    	* testsuite/ld-scripts/align3.t: New file.
    	* testsuite/ld-scripts/align4.d: New file.
    	* testsuite/ld-scripts/align4.t: New file.
    	* testsuite/ld-scripts/align5.d: New file.
    	* testsuite/ld-scripts/align5.t: New file.
    	* testsuite/ld-scripts/exclude-file-5.d: New file.
    	* testsuite/ld-scripts/exclude-file-5.map: New file.
    	* testsuite/ld-scripts/exclude-file-5.t: New file.
    	* testsuite/ld-scripts/exclude-file-6.d: New file.
    	* testsuite/ld-scripts/exclude-file-6.map: New file.
    	* testsuite/ld-scripts/exclude-file-6.t: New file.
    	* NEWS: Mention the changes.

commit a808670465869100d4178a572da8a1503d727f3b
Author: Andrew Waterman <andrew@sifive.com>
Date:   Fri Jul 28 10:02:57 2017 +0100

    Fix problems parsing RISCV architecture extenstions in the assembler.
    
    	* config/tc-riscv.c (riscv_set_arch): Handle the Q subset like
    	all other subsets.
    	Obviate use-after-free.

commit 242f30e67cbc2aba8314ba3bf702efb1aaceaad6
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jul 28 00:00:46 2017 +0000

    Automatic date update in version.in

commit 4c9dc8114942ec02e1adacf9aea6d65dc5849e9c
Author: Xavier Roirand <roirand@adacore.com>
Date:   Thu Jul 27 15:53:02 2017 +0200

    Add myself as a write-after-approval GDB maintainer.
    
    gdb/Changelog:
    
    2017-07-27  Xavier Roirand  <roirand@adacore.com>
    
            * MAINTAINERS (Write After Approval): Add Xavier Roirand.
    
    Change-Id: Iee1dae7597da8f2c8c3098c14649ff400a81a388

commit f726cc1cb69ab0e0303209d08effb10b99007080
Author: Georg-Johann Lay <gjl@gcc.gnu.org>
Date:   Thu Jul 27 14:17:14 2017 +0100

    Move AVR .promemx.* sections into higher memory.
    
    	PR ld/21849
    	* scripttempl/avr.sc: Split .progmemx.* from .progmem.* and locate
    	former at a higher address.

commit be095889ff89910d3d5dfa5adc0a954a139115f4
Merge: e29599e 8bdf0be
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jul 27 05:36:16 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 8bdf0be19d2777565a8b1c88347f65d6a4b8c5fc
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Jul 27 12:04:50 2017 +0100

    Fix address violation issues encountered when parsing corrupt binaries.
    
    	PR 21840
    	* mach-o.c (bfd_mach_o_read_symtab_strtab): Fail if the symtab
    	size is -1.
    	* nlmcode.h (nlm_swap_auxiliary_headers_in): Replace assertion
    	with error return.
    	* section.c (bfd_make_section_with_flags): Fail if the name or bfd
    	are NULL.
    	* vms-alpha.c (bfd_make_section_with_flags): Correct computation
    	of end pointer.
    	(evax_bfd_print_emh): Check for invalid string lengths.

commit 63d4980d60dd137996fa282ae1df2e3fcb4519ee
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jul 27 00:00:47 2017 +0000

    Automatic date update in version.in

commit 104f0515d038716599728f8e2b58aefe3fc188aa
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jul 26 10:39:20 2017 -0700

    Gold: Fix mips.cc for GCC 4.2
    
    GCC 4.2 fails to compile "(uint64_t) 0x800080008000" with
    
    error: integer constant is too large for â??longâ?? type
    
    This patch adds "llu" suffix to 0x800080008000 for GCC 4.2.
    
    	* mips.cc (Mips_relocate_functions): Add "llu" suffix to
    	0x800080008000.

commit 27d41eac62a6a1aa803dfcfba2be61431e7b3d13
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 14:55:31 2017 +0100

    Add "maint check xml-descriptions" to test builtin xml target descriptions
    
    Now, GDB is able to dynamically create i386-linux target descriptions
    from features, instead of using pre-generated target descriptions.  These
    pre-generated target descriptions are no longer used by GDB (note that
    they are still used by GDBserver).
    
    This patch add a new maint command "maint check xml-descriptions" to test
    dynamically generated tdesc are identical to these generated from xml files.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* cli/cli-cmds.c (maintenancechecklist): New variable.
    	* gdbcmd.h (maintenancechecklist): Declare it.
    	* i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
    	Call i386_linux_read_description with different masks.
    	* maint.c (maintenance_check_command): New function.
    	(_initialize_maint_cmds): Call add_prefix_cmd.
    	* target-descriptions.c (tdesc_reg): override operator != and ==.
    	(tdesc_type): Likewise.
    	(tdesc_feature): Likewise.
    	(target_desc): Likewise.
    	[GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
    	(maintenance_check_xml_descriptions): New function.
    	(_initialize_target_descriptions) Add command "xml-descriptions".
    	* target-descriptions.h (selftests::record_xml_tdesc): Declare.
    
    gdb/testsuite:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.gdb/unittest.exp: Invoke command
    	"maintenance check xml-descriptions".
    
    gdb/doc:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.texinfo (Maintenance Commands): Document command
    	"maint check xml-descriptions".

commit ea03d0d3c32b22aeddfeb139a4a515f7e5961347
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 14:39:54 2017 +0100

    Lazily and dynamically create i386-linux target descriptions
    
    Instead of using pre-generated target descriptions, this patch
    changes GDB to lazily and dynamically create target descriptions
    according to the target hardware capability (xcr0 in i386).
    This support any combination of target features.
    
    Some reg in target description has "regnum" attribute, so its register
    number is got from the attribute value instead from sequential allocation.
    
      <reg name="xmm0" bitsize="128" type="vec128" regnum="32"/>
    
    when target description is created, it should match the regnum, so this
    patch adds a new field m_next_regnum to track it, if attribute number is
    greater than the m_next_regnum, print the code to set register number
    explicitly.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
    	Include features/i386/32bit-*.c.
    	(i386_linux_read_description): Generate target description if it
    	doesn't exist.
    	(_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
    	functions.
    	* features/i386/32bit-linux.c: Re-generated.
    	* features/i386/32bit-sse.c: Likewise.
    	* target-descriptions.c (print_c_feature::visit): Print code to
    	set register number if needed.
    	(print_c_feature) <m_next_regnum>: New field.

commit 25aa13e522c595cbdbb3868f1daa434a17ba2ab2
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 14:24:08 2017 +0100

    Generate c for feature instead of tdesc
    
    This patch changes Makefile and command "maint print c-files" so
    that GDB can print c files for features instead target description.
    Previously, we feed GDB a target description xml file, which generate
    c files including multiple features.
    
    With this patch, in Makefile, we wrap each feature xml file, and
    create a temp target description which include only one feature.
    Then, adjust the target description printer for them, and print
    a c function for each given feature, so that we can use these
    c functions later to create target description in a flexible way.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* features/Makefile (CFILES): Rename with TDESC_CFILES.
    	(FEATURE_XMLFILES): New.
    	(FEATURE_CFILES): New.
    	New rules.
    	(clean-cfiles): Remove generated c files.
    	* features/i386/32bit-avx.c: Generated.
     	* features/i386/32bit-avx512.c: Generated.
     	* features/i386/32bit-core.c: Generated.
     	* features/i386/32bit-linux.c: Generated.
     	* features/i386/32bit-mpx.c: Generated.
     	* features/i386/32bit-pkeys.c: Generated.
     	* features/i386/32bit-sse.c: Generated.
     	* target-descriptions.c: Include algorithm.
    	(tdesc_element_visitor): Add method visit_end.
    	(print_c_tdesc): Implement visit_end.
    	(print_c_tdesc:: m_filename_after_features): Move it to
    	protected.
    	(print_c_feature): New class.
    	(maint_print_c_tdesc_cmd): Use print_c_feature if XML file
    	name starts with "i386/32bit-".

commit 6eb1e6a8c1c83d0fb5b06192d1ec218d3a358f23
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 12:56:54 2017 +0100

    Use visitor pattern for "maint print c-tdesc"
    
    Target description can be modeled as a tree, the target description
    is the root node, features are children nodes, registers and types are
    grand-children nodes.  So command "maint print c-tdesc" in effect
    traverse/visit each node, and print them in c.  This can be
    implemented by visitor pattern, this is the first reason.  Secondly,
    I want to this command prints c files in a different way for some
    specific xml files, but still print c files the same way for the rest
    of xml files.  Third, I even want to print xml files from target
    descriptions, so that GDBserver can use it to reply GDB's query
    qXfer:features:read:target.xml.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* target-descriptions.c (tdesc_element_visitor): New class.
    	(tdesc_element): New class.
    	(tdesc_reg): Inherit from tdesc_element.
    	(tdesc_reg::accept): New function.
    	(tdesc_type): Inherit from tdesc_element.
    	(tdesc_type::accept): New function.
    	(tdesc_feature): Inherit from tdesc_element.
    	(tdesc_feature::accept): New function.
    	(target_desc): Inherit from tdesc_element.
    	(target_desc::target_desc): New.
    	(target_desc::~target_desc): New.
    	(target_desc::accept): New.
    	(allocate_target_description): Use new.
    	(free_target_description): Use delete.
    	(print_c_tdesc): New class.
    	(maint_print_c_tdesc_cmd): Adjust.
    
    	* features/aarch64.c: Re-generated.
    	* features/arc-arcompact.c: Re-generated.
    	* features/arc-v2.c: Re-generated.
    	* features/arm/arm-with-iwmmxt.c: Re-generated.
    	* features/arm/arm-with-m.c: Re-generated.
    	* features/arm/arm-with-m-fpa-layout.c: Re-generated.
    	* features/arm/arm-with-m-vfp-d16.c: Re-generated.
    	* features/arm/arm-with-neon.c: Re-generated.
    	* features/arm/arm-with-vfpv2.c: Re-generated.
    	* features/arm/arm-with-vfpv3.c: Re-generated.
    	* features/i386/amd64-avx-avx512.c: Re-generated.
    	* features/i386/amd64-avx-avx512-linux.c: Re-generated.
    	* features/i386/amd64-avx.c: Re-generated.
    	* features/i386/amd64-avx-linux.c: Re-generated.
    	* features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
    	* features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
    	* features/i386/amd64-avx-mpx.c: Re-generated.
    	* features/i386/amd64-avx-mpx-linux.c: Re-generated.
    	* features/i386/amd64.c: Re-generated.
    	* features/i386/amd64-linux.c: Re-generated.
    	* features/i386/amd64-mpx.c: Re-generated.
    	* features/i386/amd64-mpx-linux.c: Re-generated.
    	* features/i386/i386-avx-avx512.c: Re-generated.
    	* features/i386/i386-avx-avx512-linux.c: Re-generated.
    	* features/i386/i386-avx.c: Re-generated.
    	* features/i386/i386-avx-linux.c: Re-generated.
    	* features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
    	* features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
    	* features/i386/i386-avx-mpx.c: Re-generated.
    	* features/i386/i386-avx-mpx-linux.c: Re-generated.
    	* features/i386/i386.c: Re-generated.
    	* features/i386/i386-linux.c: Re-generated.
    	* features/i386/i386-mmx.c: Re-generated.
    	* features/i386/i386-mmx-linux.c: Re-generated.
    	* features/i386/i386-mpx.c: Re-generated.
    	* features/i386/i386-mpx-linux.c: Re-generated.
    	* features/i386/x32-avx-avx512.c: Re-generated.
    	* features/i386/x32-avx-avx512-linux.c: Re-generated.
    	* features/i386/x32-avx.c: Re-generated.
    	* features/i386/x32-avx-linux.c: Re-generated.
    	* features/i386/x32.c: Re-generated.
    	* features/i386/x32-linux.c: Re-generated.
    	* features/microblaze.c: Re-generated.
    	* features/microblaze-with-stack-protect.c: Re-generated.
    	* features/mips64-dsp-linux.c: Re-generated.
    	* features/mips64-linux.c: Re-generated.
    	* features/mips-dsp-linux.c: Re-generated.
    	* features/mips-linux.c: Re-generated.
    	* features/nds32.c: Re-generated.
    	* features/nios2.c: Re-generated.
    	* features/nios2-linux.c: Re-generated.
    	* features/rs6000/powerpc-32.c: Re-generated.
    	* features/rs6000/powerpc-32l.c: Re-generated.
    	* features/rs6000/powerpc-403.c: Re-generated.
    	* features/rs6000/powerpc-403gc.c : Re-generated.
    	* features/rs6000/powerpc-405.c: Re-generated.
    	* features/rs6000/powerpc-505.c: Re-generated.
    	* features/rs6000/powerpc-601.c: Re-generated.
    	* features/rs6000/powerpc-602.c: Re-generated.
    	* features/rs6000/powerpc-603.c: Re-generated.
    	* features/rs6000/powerpc-604.c: Re-generated.
    	* features/rs6000/powerpc-64.c: Re-generated.
    	* features/rs6000/powerpc-64l.c: Re-generated.
    	* features/rs6000/powerpc-7400.c: Re-generated.
    	* features/rs6000/powerpc-750.c: Re-generated.
    	* features/rs6000/powerpc-860.c: Re-generated.
    	* features/rs6000/powerpc-altivec32.c: Re-generated.
    	* features/rs6000/powerpc-altivec32l.c: Re-generated.
    	* features/rs6000/powerpc-altivec64.c: Re-generated.
    	* features/rs6000/powerpc-altivec64l.c: Re-generated.
    	* features/rs6000/powerpc-cell32l.c: Re-generated.
    	* features/rs6000/powerpc-cell64l.c: Re-generated.
    	* features/rs6000/powerpc-e500.c: Re-generated.
    	* features/rs6000/powerpc-e500l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-32l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-64l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
    	* features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
    	* features/rs6000/powerpc-vsx32.c: Re-generated.
    	* features/rs6000/powerpc-vsx32l.c: Re-generated.
    	* features/rs6000/powerpc-vsx64.c: Re-generated.
    	* features/rs6000/powerpc-vsx64l.c: Re-generated.
    	* features/rs6000/rs6000.c: Re-generated.
    	* features/s390-linux32.c: Re-generated.
    	* features/s390-linux32v1.c: Re-generated.
    	* features/s390-linux32v2.c: Re-generated.
    	* features/s390-linux64.c: Re-generated.
    	* features/s390-linux64v1.c: Re-generated.
    	* features/s390-linux64v2.c: Re-generated.
    	* features/s390-te-linux64.c: Re-generated.
    	* features/s390-tevx-linux64.c: Re-generated.
    	* features/s390-vx-linux64.c: Re-generated.
    	* features/s390x-linux64.c: Re-generated.
    	* features/s390x-linux64v1.c: Re-generated.
    	* features/s390x-linux64v2.c: Re-generated.
    	* features/s390x-te-linux64.c: Re-generated.
    	* features/s390x-tevx-linux64.c: Re-generated.
    	* features/s390x-vx-linux64.c: Re-generated.
    	* features/sparc/sparc32-solaris.c: Re-generated.
    	* features/sparc/sparc64-solaris.c: Re-generated.
    	* features/tic6x-c62x.c: Re-generated.
    	* features/tic6x-c62x-linux.c: Re-generated.
    	* features/tic6x-c64x.c: Re-generated.
    	* features/tic6x-c64x-linux.c: Re-generated.
    	* features/tic6x-c64xp.c: Re-generated.
    	* features/tic6x-c64xp-linux.c: Re-generated.

commit 35b4818d03e8d63a926afb235a21c2cb64b14b23
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 12:36:42 2017 +0100

    Centralize i386 linux target descriptions
    
    This patch moves all the tdesc_i386*_linux target descriptions to a
    function i386_linux_read_description, which returns the right target
    description according to xcr0.  This also remove the duplication in
    getting target descriptions in corefile and native target.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* i386-linux-tdep.c (i386_linux_read_description): New function.
    	(i386_linux_core_read_description): Call
    	i386_linux_read_description.
    	* i386-linux-tdep.h (i386_linux_read_description): Declare.
    	(tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
    	(tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
    	(tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
    	(tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
    	* x86-linux-nat.c (x86_linux_read_description): Call
    	i386_linux_read_description.

commit 8e2141c6fba6daea1555e042da9de49ec8b1977d
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 12:03:47 2017 +0100

    Add optional argument to command "maint prints c-tdesc"
    
    Nowadays, we need two steps to print c files for xml target description,
    that is, 1) read xml target description in, update the current tdesc,
    2) visit the current tdesc, print the c file.  It is unnecessary to
    involve in current tdesc, and some validations in each gdbarch are
    performed unnecessarily, which will reject some target descriptions if
    they are missing some mandatory feature.
    
    This patch adds an optional argument to "maint print c-tdesc", which
    is an XML file target description, so that we can combine the two
    steps above into one step, and don't have to involve in global current
    tdesc.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* NEWS: Mention it.
    	* features/Makefile (%.c: %.xml): Pass the xml file name to
    	command "maint print c-tdesc".
    	* target-descriptions.c (maint_print_c_tdesc_cmd): Get file
    	name from 'arg'.
    
    gdb/doc:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.texinfo (Maintenance Commands): Document optional
    	argument of "maint print c-tdesc".

commit b468ff4cbf14744d512e464b4be9681d3e0302ad
Author: Yao Qi <yao.qi@linaro.org>
Date:   Wed Jul 26 10:37:17 2017 +0100

    Class-fy target_desc
    
    This patch adds ctor and dtor in target_desc.
    
    gdb:
    
    2017-07-26  Yao Qi  <yao.qi@linaro.org>
    
    	* target-descriptions.c (target_desc): Add ctor and dtor.  Do
    	in-class initialization.
    	(tdesc_create_feature): Call new instead of XCNEW.
    	(free_target_description): Ue delete.

commit 229d26fc9ebca61b8d899cf8fe4342a6cc9795ff
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Jul 26 10:55:35 2017 +0200

    Add enum for result of fast_tracepoint_collecting
    
    I got confused by the result value of fast_tracepoint_collecting, while
    it sounds like it would return true/false (whether the thread is
    collecting or not), it actually returns:
    
      0: not collecting
      1: in the jump pad, before the relocated instruction
      2: in the jump pad, at or after the relocated instruction
    
    To avoid confusion, I think it would be nice to make it return an enum.
    If you can help find a shorter but still relavant name, it would be
    awesome.  Otherwise, we'll go with that, fast_tpoint_collect_result,
    which is at least consistent with the existing
    fast_tpoint_collect_status.
    
    gdb/gdbserver/ChangeLog:
    
    	* tracepoint.h (enum class fast_tpoint_collect_result): New
    	enumeration.
    	(fast_tracepoint_collecting): Change return type to
    	fast_tpoint_collect_result.
    	* tracepoint.c (fast_tracepoint_collecting): Likewise.
    	* linux-low.h: Include tracepoint.h.
    	(struct lwp_info) <collecting_fast_tracepoint>: Change type to
    	fast_tpoint_collect_result.
    	* linux-low.c (handle_tracepoints): Adjust.
    	(linux_fast_tracepoint_collecting): Change return type to
    	fast_tpoint_collect_result.
    	(maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
    	linux_wait_1, stuck_in_jump_pad_callback,
    	lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
    	proceed_one_lwp): Adjust to type change.

commit 11f10936902160e9b1474fd0a06ea44a5a6445ee
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jul 26 00:00:31 2017 +0000

    Automatic date update in version.in

commit b9c0e1b40ee4e7eeb3e2850720bf30f28e2e17b1
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Sat Jul 15 08:30:40 2017 -0700

    Fix two NetBSD-specific typos in the configure.nat conversion.
    
    - Add the '-lkvm' library requirement for NetBSD/sparc64.
    - Fix spelling of 'nbsdelf' host.
    
    gdb/Changelog:
    
    	* configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.

commit a04b53379a18c66376b4130dc3b4936e6433a0e5
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Jul 25 15:25:38 2017 +0100

    Make amd64_x32_init_abi and amd64_init_abi argument constant
    
    gdb:
    
    2017-07-25  Yao Qi  <yao.qi@linaro.org>
    
    	* amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
    	constant.
    	(amd64_x32_init_abi): Likewise.
    	* amd64-tdep.h (amd64_init_abi): Update declaration.
    	(amd64_x32_init_abi): Likewise.

commit 133193b8aef9f74abce69ec84beca227dbd7f9a4
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 25 12:47:46 2017 +0100

    Fix thinko in previous change to elf32-msp430.c

commit 7cbc739c71fcd82fbfbf180ff636e3fbee4f30a1
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 25 12:12:16 2017 +0100

    Fix typos in error and option messages in OPCODES library.
    
    	PR 21739
    opcodes	* arc-opc.c (insert_rhv2): Use lower case first letter in error
    	message.
    	(insert_r0): Likewise.
    	(insert_r1): Likewise.
    	(insert_r2): Likewise.
    	(insert_r3): Likewise.
    	(insert_sp): Likewise.
    	(insert_gp): Likewise.
    	(insert_pcl): Likewise.
    	(insert_blink): Likewise.
    	(insert_ilink1): Likewise.
    	(insert_ilink2): Likewise.
    	(insert_ras): Likewise.
    	(insert_rbs): Likewise.
    	(insert_rcs): Likewise.
    	(insert_simm3s): Likewise.
    	(insert_rrange): Likewise.
    	(insert_r13el): Likewise.
    	(insert_fpel): Likewise.
    	(insert_blinkel): Likewise.
    	(insert_pclel): Likewise.
    	(insert_nps_bitop_size_2b): Likewise.
    	(insert_nps_imm_offset): Likewise.
    	(insert_nps_imm_entry): Likewise.
    	(insert_nps_size_16bit): Likewise.
    	(insert_nps_##NAME##_pos): Likewise.
    	(insert_nps_##NAME): Likewise.
    	(insert_nps_bitop_ins_ext): Likewise.
    	(insert_nps_##NAME): Likewise.
    	(insert_nps_min_hofs): Likewise.
    	(insert_nps_##NAME): Likewise.
    	(insert_nps_rbdouble_64): Likewise.
    	(insert_nps_misc_imm_offset): Likewise.
    	* riscv-dis.c (print_riscv_disassembler_options): Fix typo in
    	option description.
    
    gas	* testsuite/gas/arc/add_s-err.s: Update expected error message.

commit 46a62268b87bd5e8215636b695380bca9a9f3b63
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Jul 25 11:38:50 2017 +0100

    Catch exceptions thrown from gdbarch_skip_prologue
    
    PR 21555 is caused by the exception during the prologue analysis when re-set
    a breakpoint.
    
    (gdb) bt
     #0  memory_error_message (err=TARGET_XFER_E_IO, gdbarch=0x153db50, memaddr=93824992233232) at ../../binutils-gdb/gdb/corefile.c:192
     #1  0x00000000005718ed in memory_error (err=TARGET_XFER_E_IO, memaddr=memaddr@entry=93824992233232) at ../../binutils-gdb/gdb/corefile.c:220
     #2  0x00000000005719d6 in read_memory_object (object=object@entry=TARGET_OBJECT_CODE_MEMORY, memaddr=93824992233232, memaddr@entry=1, myaddr=myaddr@entry=0x7fffffffd0a0 "P\333S\001", len=len@entry=1) at ../../binutils-gdb/gdb/corefile.c:259
     #3  0x0000000000571c6e in read_code (len=1, myaddr=0x7fffffffd0a0 "P\333S\001", memaddr=<optimized out>) at ../../binutils-gdb/gdb/corefile.c:287
     #4  read_code_unsigned_integer (memaddr=memaddr@entry=93824992233232, len=len@entry=1, byte_order=byte_order@entry=BFD_ENDIAN_LITTLE)                          at ../../binutils-gdb/gdb/corefile.c:362
     #5  0x000000000041d4a0 in amd64_analyze_prologue (gdbarch=gdbarch@entry=0x153db50, pc=pc@entry=93824992233232, current_pc=current_pc@entry=18446744073709551615, cache=cache@entry=0x7fffffffd1e0) at ../../binutils-gdb/gdb/amd64-tdep.c:2310
     #6  0x000000000041e404 in amd64_skip_prologue (gdbarch=0x153db50, start_pc=93824992233232) at ../../binutils-gdb/gdb/amd64-tdep.c:2459
     #7  0x000000000067bfb0 in skip_prologue_sal (sal=sal@entry=0x7fffffffd4e0) at ../../binutils-gdb/gdb/symtab.c:3628
     #8  0x000000000067c4d8 in find_function_start_sal (sym=sym@entry=0x1549960, funfirstline=1) at ../../binutils-gdb/gdb/symtab.c:3501
     #9  0x000000000060999d in symbol_to_sal (result=result@entry=0x7fffffffd5f0, funfirstline=<optimized out>, sym=sym@entry=0x1549960) at ../../binutils-gdb/gdb/linespec.c:3860
    ....
     #16 0x000000000054b733 in location_to_sals (b=b@entry=0x15792d0, location=0x157c230, search_pspace=search_pspace@entry=0x1148120, found=found@entry=0x7fffffffdc64) at ../../binutils-gdb/gdb/breakpoint.c:14211
     #17 0x000000000054c1f5 in breakpoint_re_set_default (b=0x15792d0) at ../../binutils-gdb/gdb/breakpoint.c:14301
     #18 0x00000000005412a9 in breakpoint_re_set_one (bint=bint@entry=0x15792d0) at ../../binutils-gdb/gdb/breakpoint.c:14412
    
    This problem can be fixed by
    
     - either each prologue analyzer doesn't throw exception,
     - or catch the exception thrown from gdbarch_skip_prologue,
    
    I choose the latter because the former needs to fix *every* prologue
    analyzer to not throw exception.
    
    This error can be reproduced by changing reread.exp.  The test reread.exp
    has already test that breakpoint can be reset correctly after the
    executable is re-read.  This patch extends this test by compiling test c
    file with and without -fPIE.
    
    (gdb) run ^M
    The program being debugged has been started already.^M
    Start it from the beginning? (y or n) y^M
    x86_64/gdb/testsuite/outputs/gdb.base/reread/reread' has changed; re-reading symbols.
    Error in re-setting breakpoint 1: Cannot access memory at address 0x555555554790^M
    Error in re-setting breakpoint 2: Cannot access memory at address 0x555555554790^M
    Starting program: /scratch/yao/gdb/build-git/x86_64/gdb/testsuite/outputs/gdb.base/reread/reread ^M
    This is foo^M
    [Inferior 1 (process 27720) exited normally]^M
    (gdb) FAIL: gdb.base/reread.exp: opts= "-fPIE" "ldflags=-pie" : run to foo() second time (the program exited)
    
    This patch doesn't re-indent the code, to keep the patch simple.
    
    gdb:
    
    2017-07-25  Yao Qi  <yao.qi@linaro.org>
    
    	PR gdb/21555
    	* arch-utils.c (gdbarch_skip_prologue_noexcept): New function.
    	* arch-utils.h (gdbarch_skip_prologue_noexcept): Declare.
    	* infrun.c: Include arch-utils.h
    	(handle_step_into_function): Call gdbarch_skip_prologue_noexcept.
    	(handle_step_into_function_backward): Likewise.
    	* symtab.c (skip_prologue_sal): Likewise.
    
    gdb/testsuite:
    
    2017-07-25  Yao Qi  <yao.qi@linaro.org>
    
    	PR gdb/21555
    	* gdb.base/reread.exp: Wrap the whole test with two kinds of
    	compilation flags, with -fPIE and without -fPIE.

commit 02ad7fc29f824a9742f8386bcf5793b81ff798f5
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Jul 21 16:35:23 2017 +0100

    [ARM] Access FPSCR on vfpv2
    
    GDB can fetch or store FPSCR on vfpv3, which has 32 VFP registers, but
    fail to do so on vfpv2, which has 16 VFP registers.  GDB code is incorrect
    for vfpv2,
    
           else if (tdep->vfp_register_count > 0
     	       && regno >= ARM_D0_REGNUM
    	       && regno <= ARM_D0_REGNUM + tdep->vfp_register_count)
    
    while FPSCR register number is defined as ARM_D0_REGNUM + 32.
    
      ARM_D0_REGNUM,		/* VFP double-precision registers.  */
      ARM_D31_REGNUM = ARM_D0_REGNUM + 31,
      ARM_FPSCR_REGNUM,
    
    The code above uses "<=" rather than "<", in order to put FPSCR in the
    range, but it is only correct when tdep->vfp_register_count is 32.  On
    vpfv2, it is 16, and FPSCR is out of the range, so fetch_vfp_regs or
    store_vfp_regs are not called.
    
    gdb:
    
    2017-07-25  Yao Qi  <yao.qi@linaro.org>
    
    	PR tdep/21717
    	* arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
    	condition for FPSCR.
    	(arm_linux_store_inferior_registers): Likewise.

commit c26bb06769ba85818bcf61126c94c2d517182fd9
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 25 09:46:14 2017 +0100

    Updated French translation for the BFD library.

commit cfe7b9bd58c634bda974e291ce95030b1e42a690
Author: Benjamin Green <bengreen5mx@gmail.com>
Date:   Tue Jul 25 09:41:23 2017 +0100

    Add a linker branch optimization for the MSP430.
    
    	PR 21824
    	* elf32-msp430.c (msp430_elf_relax_section): Allow conversion of
    	16-bit absolute branches into 10-bit pc-relative branches on the
    	MSP430 as well as the MSP430X.

commit ec06425629516e11f3106d51fa85f49da147765f
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 25 09:39:13 2017 +0100

    oops - add changelog entry accidentally omitted from previous delta.

commit c6b78c965a96fb152fbd58926edccb5dee2707a5
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 25 09:35:36 2017 +0100

    Stop readelf from returning an error status if asked to dump an emoty section.
    
    	PR 21820
    	* readelf.c (dump_section_as_strings): Do not fail if the section
    	was empty.
    	(dump_section_as_bytes): Likewise.

commit d4aaa2a0744a28143f0b923802b6d1fa8db15887
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jul 25 13:52:32 2017 +0930

    __tls_get_addr_opt stub eh_frame info
    
    Since the __tls_get_addr_opt stub saves LR and makes a call, eh_frame
    info should be generated to describe how to unwind through the stub.
    
    The patch also changes the way the backend iterates over stubs, from
    looking at all sections in stub_bfd to which all dynamic sections are
    attached as well, to iterating over the group list, which gets just
    the stub sections.  Most binaries will have just one or two stub
    groups, so this is a little faster.
    
    bfd/
    	* elf64-ppc.c (struct map_stub): Add tls_get_addr_opt_bctrl.
    	(stub_eh_frame_size): New function.
    	(ppc_size_one_stub): Set group tls_get_addr_opt_bctrl.
    	(group_sections): Init group tls_get_addr_opt_bctrl.
    	(ppc64_elf_size_stubs): Update sizing and initialization of
    	.eh_frame.  Iteration over stubs via group list.
    	(ppc64_elf_build_stubs): Iterate over stubs via group list.
    	(ppc64_elf_finish_dynamic_sections): Update finalization of
    	.eh_frame.
    ld/
    	* testsuite/ld-powerpc/tlsopt5.s: Add cfi.
    	* testsuite/ld-powerpc/tlsopt5.d: Update.
    	* testsuite/ld-powerpc/tlsopt5.wf: New file.
    	* testsuite/ld-powerpc/powerpc.exp: Perform new tlsopt5 test.

commit aafd38357af0c9c225f56afcb93cc3a4da763ccd
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jul 25 00:01:08 2017 +0000

    Automatic date update in version.in

commit 031ed05dd2756557c3f5cda6690a9f3220918ffb
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Mon Jul 24 18:35:30 2017 +0200

    s390-vregs.exp: Fix Tcl error after non-zero-pad patch
    
    s390-vregs.exp yields a Tcl error:
    
      ERROR: can't read "i": no such variable
          while executing
      "expr $a_high * ($i + 1) * $a_high "
          (procedure "hex128" line 2)
          invoked from within
      "hex128 $a_high $a_low $b_high $b_low"
      ...
    
    This is a regression, caused by commit 30a254669b16b8 -- "Don't always
    zero pad in print_*_chars".  That patch introduced a new procedure
    "hex128" for formatting a 128-bit value as hex, but it accidentally moved
    the calculation of the 128-bit value into that new procedure as well
    instead of leaving it in the original context.  This is fixed.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.arch/s390-vregs.exp: Calculate parameters to hex128 in the
    	calling context.
    	(hex128): Drop erroneous calculation of parameters.

commit 7684e58062af4886aceb05ecd83a956bfcd14aaf
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Mon Jul 24 11:26:58 2017 +0100

    [AArch64] Fix the bit pattern order in the comments in auto-generated file
    
    The bit pattern comment in "aarch64_opcode_lookup_1" is reversed.
    
    This patch fixed this.
    
    opcode/
    	* aarch64-gen.c (print_decision_tree_1): Reverse the index of PATTERN to
    	correct the print.
    	* aarch64-dis-2.c: Regenerated.

commit 8a2df5e2df374289e00ecd8f099eb46d76ef982e
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 24 14:04:04 2017 +0100

    Fix another memory access error triggered by attempting to parse a corrupt binary.
    
    	PR 21813
    	(alpha_vms_object_p): Check for a truncated record.

commit ca4cf9b9c622a5695e01f7f5815a7382a31fcf51
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 24 13:49:22 2017 +0100

    Fix address violation errors parsing corrupt binary files.
    
    	PR 21813
    binutils* rddbg.c (read_symbol_stabs_debugging_info): Check for an empty
    	string whilst concatenating symbol names.
    
    bfd	* mach-o.c (bfd_mach_o_canonicalize_relocs): Pass the base address
    	of the relocs to the canonicalize_one_reloc routine.
    	* mach-o.h (struct bfd_mach_o_backend_data): Update the prototype
    	for the _bfd_mach_o_canonicalize_one_reloc field.
    	* mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add
    	res_base parameter.  Use to check for corrupt pair relocs.
    	* mach-o-aarch64.c (bfd_mach_o_arm64_canonicalize_one_reloc):
    	Likewise.
    	* mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc):
    	Likewise.
    	* mach-o-x86-64.c (bfd_mach_o_x86_64_canonicalize_one_reloc):
    	Likewise.
    
    	* vms-alpha.c (_bfd_vms_slurp_eihd): Make sure that there is
    	enough data in the record before attempting to parse it.
    	(_bfd_vms_slurp_eeom): Likewise.
    
    	(_bfd_vms_slurp_egsd): Check for an invalid section index.
    	(image_set_ptr): Likewise.
    	(alpha_vms_slurp_relocs): Likewise.

commit e8d84ca1b46f899b0b140fdd146fc7b14515267b
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 24 11:32:57 2017 +0100

    Stop the generation of mapping symbols in the debug sections of ARM and AArch64 binaries.
    
    	PR 21809
    	* config/tc-aarch64.c (aarch64_init_frag): Do not set a mapping
    	state for frags in debug sections.
    	* config/tc-arm.c (arm_init_frag): Likewise.

commit 47aeb64c10ec9c9f06d2d2f4451f417d63b023e1
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 24 11:27:33 2017 +0100

    Improve "unrecognized relocation" error messages to add the suggestion that the linker might be out of date.
    
    	PR 21803
    	* reloc.c (_bfd_unrecognized_reloc): New function.  Reports
    	an unrecognized reloc and sets the bfd_error value.
    	* libbfd.h: Regenerate.
    	* elf32-arm.c (elf32_arm_final_link_relocate): Use the new
    	function.
    	* elf32-i386.c (elf_i386_relocate_section): Likewise.
    	* elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_relocate_section): Likewise.
    	* elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.

commit 645b28002711eba22e8a4df3733a01206ab7d36d
Author: claziss <claziss@synopsys.com>
Date:   Mon Jul 24 10:10:21 2017 +0200

    [ARC] Fix big-endian ld tests errors.
    
    A set of small patches that are fixing big-endian observed errors.
    
    ld/
    2017-07-24  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* testsuite/ld-arc/jli-overflow.d: Force testing for little
    	endian.
    	* testsuite/ld-arc/tls_gd-01.d: Fix string to match bigendian
    	systems.
    	* testsuite/ld-arc/tls_ie-01.d: Fix test for bigendian systems.

commit 8ca02f6a216eec3ada5936f189947c424d83d766
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jul 24 00:00:58 2017 +0000

    Automatic date update in version.in

commit 723dfee7b84099118e849c90e4e95dc275cb9d97
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Mon Jul 24 00:53:34 2017 +0200

    * dwarf2dbg.c (dwarf2dbg_final_check): Rename local variable exp from expr.
    
    Trying to build (for mmix-knuth-mmixware but I don't think that
    matters) yields the following (repeatable on e.g. CompileFarm gcc20
    sporting gcc-4.7.2 as default):
    
    gcc -DHAVE_CONFIG_H -I. -I/home/hp/binutils/src/gas  -I. -I/home/hp/binutils/src/gas -I../bfd -I/home/hp/binutils/src/gas/config -I/home/hp/binutils/src/gas/../include -I/home/hp/binutils/src/gas/.. -I/home/hp/binutils/src/gas/../bfd -DLOCALEDIR="\"/usr/local/share/locale\""  -W -Wall -Wstrict-prototypes -Wmissing-prototypes -Wshadow -Werror -Wwrite-strings -I/home/hp/binutils/src/gas/../zlib -g -O2 -MT dwarf2dbg.o -MD -MP -MF .deps/dwarf2dbg.Tpo -c -o dwarf2dbg.o /home/hp/binutils/src/gas/dwarf2dbg.c
    cc1: warnings being treated as errors
    /home/hp/binutils/src/gas/dwarf2dbg.c: In function 'dwarf2dbg_final_check':
    /home/hp/binutils/src/gas/dwarf2dbg.c:2246: error: declaration of 'expr' shadows a global declaration
    /home/hp/binutils/src/gas/expr.h:180: error: shadowed declaration is here
    make[4]: *** [dwarf2dbg.o] Error 1
    
    IIRC this is a false namespace clash and the warning is not observable
    with a new-enough gcc.  Committed as obvious.
    
    brgds, H-P
    PS. Idea: -Wcompiler; warn about constructs problematic with e.g. old gcc. 1/2 ;-)

commit 15a3a14fdd725c049d6b2aadbaf66c9be5ed36a8
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Jul 23 20:03:40 2017 +0930

    Correct eh_frame info for __glink_PLTresolve
    
    My PPC64_OPT_LOCALENTRY patch of June 1, git commit f378ab099d, and
    the later gold change, git commit 7ee7ff7015, added an insn in
    __glink_PLTresolve which needs a corresponding adjustment in the
    eh_frame info for asynchronous exceptions to unwind correctly.
    
    It would have been OK for both ABIs to use +5 for the advance before
    restore of LR, since we can put the DW_CFA_restore_extended on any
    insn after the actual restore and before the r12/r0 copy is clobbered,
    but it's slightly better to delay as much as possible.  There are
    then more addresses where fewer CFA program insns are executed.
    
    bfd/
    	* elf64-ppc.c (ppc64_elf_size_stubs): Correct advance to
    	restore of LR.
    gold/
    	* powerpc.cc (glink_eh_frame_fde_64v2): Correct advance to
    	restore of LR.
    	(glink_eh_frame_fde_64v1): Advance to restore of LR at latest
    	possible insn.

commit 5c2c0020fbe7110e6780ec1ee85ff11833779f8c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jul 23 00:00:36 2017 +0000

    Automatic date update in version.in

commit b6f48cb022118f838357c07d32d122e9434c0209
Author: Tom Tromey <tom@tromey.com>
Date:   Tue Jul 18 18:23:32 2017 -0600

    Use std::vector in struct catch_syscall_inferior_data
    
    This changes struct catch_syscall_inferior_data to use a std::vector
    rather than a VEC.  It also changes it to be allocated with new and
    destroyed with delete.
    
    ChangeLog
    2017-07-22  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-syscall.c (struct catch_syscall_inferior_data)
    	<syscalls_counts>: Now a std::vector.
    	(get_catch_syscall_inferior_data): Use "new".
    	(catch_syscall_inferior_data_cleanup): Use "delete".
    	(insert_catch_syscall, remove_catch_syscall)
    	(clear_syscall_counts): Update.

commit e12c9b7a0cda47a87b8203ee9906fd12f68e3666
Author: Tom Tromey <tom@tromey.com>
Date:   Mon Jul 17 16:58:22 2017 -0600

    Use std::vector in syscall_catchpoint
    
    This changes syscall_catchpoint to use a std::vector rather than a VEC
    for "syscalls_to_be_caught".  This simplifies the code a bit.
    
    ChangeLog
    2017-07-22  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-syscall.c (syscall_catchpoint)
    	<syscalls_to_be_caught>: Now a std::vector<int>
    	(~syscall_catchpoint): Remove.
    	(insert_catch_syscall, remove_catch_syscall)
    	(breakpoint_hit_catch_syscall, print_one_catch_syscall)
    	(print_mention_catch_syscall, print_recreate_catch_syscall):
    	Update.
    	(create_syscall_event_catchpoint): Change type of "filter"
    	parameter.
    	(catch_syscall_split_args): Return a std::vector.
    	(catch_syscall_command_1, catching_syscall_number_1): Update.

commit 4fa8aeac1972ed07261919ce652c886160d8cf2f
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Jun 3 08:06:36 2017 -0600

    C++-ify break-catch-throw
    
    This changes exception_catchpoint's "exception_rx' member to be a
    std::string, and updating the users.
    
    ChangeLog
    2017-07-22  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-throw.c (struct exception_catchpoint)
    	<exception_rx>: Now a std::string.
    	(~exception_catchpoint): Remove.
    	(print_one_detail_exception_catchpoint): Update.
    	(handle_gnu_v3_exceptions): Change type of except_rx.
    	(extract_exception_regexp): Return a std::string.
    	(catch_exception_command_1): Update.

commit f746a1544499acc20aa28dcdbcd2ea6df5548889
Author: Tom Tromey <tom@tromey.com>
Date:   Sat Jun 3 07:53:26 2017 -0600

    C++-ify break-catch-sig
    
    This changes signal_catchpoint to be more of a C++ class, using
    std::vector and updating the users.
    
    ChangeLog
    2017-07-22  Tom Tromey  <tom@tromey.com>
    
    	* break-catch-sig.c (gdb_signal_type): Remove typedef.
    	(struct signal_catchpoint) <signals_to_be_caught>: Now a
    	std::vector.
    	<catch_all>: Now a bool.
    	(~signal_catchpoint): Remove.
    	(signal_catchpoint_insert_location)
    	(signal_catchpoint_remove_location)
    	(signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
    	(signal_catchpoint_print_mention)
    	(signal_catchpoint_print_recreate)
    	(signal_catchpoint_explains_signal): Update.
    	(create_signal_catchpoint): Change type of "filter" and
    	"catch_all".
    	(catch_signal_split_args): Return a std::vector.  Change type of
    	"catch_all".
    	(catch_signal_command): Update.

commit dbdda973f31f275e514c311362a98b5f0f3480b8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jul 22 00:00:45 2017 +0000

    Automatic date update in version.in

commit dcd27ddf875d6b913f1ddb0573c22b0931e36061
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sat Jul 22 00:01:03 2017 +0200

    gdb.python/py-unwind: Disable stack protection
    
    [I made some typo fixes but forgot to amend my commit before sending the patch,
     hence this v2.]
    
    I see the following failure on Ubuntu 16.04's gcc 5.4.0:
    
    Running /home/emaisin/src/binutils-gdb/gdb/testsuite/gdb.python/py-unwind.exp ...
    FAIL: gdb.python/py-unwind.exp: continue to breakpoint: break backtrace-broken
    FAIL: gdb.python/py-unwind.exp: Backtrace restored by unwinder (pattern 1)
    
    The problem is that the test expects a very particular stack layout.
    When stack protection is enabled, it adds a canary value which looks
    like an additional local variable.  This makes the test complain about
    a bad stack layout and fail.
    
    The simple solution is to disable stack protection for that test using
    -fno-stack-protector.  I checked older compilers (gcc 4.4, clang 3.5)
    and they support that flag, so I don't think it's necessary to probe for
    whether the compiler supports it.
    
    Maybe a better solution would be to change the test to make it cope with
    different stack layouts (perhaps it could save addresses of stuff in
    some global variables which GDB/the unwinder would read).  I'll go with
    the simple solution for now though.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.python/py-unwind.exp: Disable stack protection when
    	building test file.

commit 82c780662512c53c3a2c7f1e1f66474ea6bc04bd
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Jul 21 16:01:34 2017 +0100

    Updated French translation for the binutils subdirectory.
    
    	* po/fr.po: Updated French translation.

commit 13bace4ab963a56102d8646cb16a8ec505536107
Author: Nick Clifton <nickc@redhat.com>
Date:   Fri Jul 21 15:56:54 2017 +0100

    Fix typo in warning message.
    
    	PR 21810
    	* dwarf.c (display_gdb_index): Fix typo in warning message.

commit b57e815ca1e75b7897caa99c2d351f11a543c4fe
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Jul 21 11:42:21 2017 +0100

    Remove unused variables in dwarf parser.
    
    	* dwarf.c (last_pointer_size, warned_about_missing_comp_units):
    	Remove.
    	(load_debug_info): Remove assignments to those two variables.

commit ba8826a82a29a19b78c18ce4f44fe313de279af7
Author: Alexandre Oliva <aoliva@redhat.com>
Date:   Fri Jul 21 10:09:06 2017 +0100

    This patch introduces support for specifing views in .loc directives, so that the compiler can use the assembler to generate line number information and have the assembler determine view numbers to multiple views at the same program counter.
    
    binutils* dwarf.c (struct State_Machine_Registers): Add view field.
    	(reset_state_machine): Reset view.
    	(process_extended_line_op): Reset view when appropriate.
    	(display_debug_lines_raw): Increment or reset view when appropriate.
    	Print nonzero views.  Support print view resets, disabled by default.
    	(display_debug_lines_decoded): Likewise.  Disambiguate op_code tests,
    	enabling printing of end_sequence.
    	* testsuite/binutils-all/dw2-1.W: Add nonzero views.
    	* testsuite/binutils-all/dw2-3.W: Likewise.
    	* testsuite/binutils-all/dw2-3gabi.W: Likewise.
    	* testsuite/binutils-all/dw5.W: Add end sequence lines.
    	* testsuite/binutils-all/i386/compressed-1a.d: Add nonzero views.
    	* testsuite/binutils-all/libdw2-compressedgabi.out: Likewise.
    	* testsuite/binutils-all/objdump.W: Likewise.
    	* testsuite/binutils-all/objdump.WL: Add end sequence lines.
    	* testsuite/binutils-all/x86-64/compressed-1a.d: Add nonzero views.
    
    gas	* doc/as.texinfo (.loc): Document view support.
    	* dwarf2dbg.c (unused): Check offset of next in struct line_entry.
    	(current): Initialize view.
    	(force_reset_view, view_assert_failed): New variables.
    	(reverse_line_entry_list): New function.
    	(set_or_check_view): Likewise.
    	(dwarf2_gen_line_info_1): Call it.
    	(dwarf2_where): Set view to NULL.
    	(dwarf2_emit_insn): Return early when called before first file.
    	(dwarf2_directive_loc): Add view support.  Emit insn
    	immediately when view option is given.
    	(process_entries): Avoid set_address to reset view when a known
    	address change already implies the view reset.
    	(dwarf2dbg_final_check): New function.
    	* dwarf2dbg.h (struct dwarf2_line_info): Add view.
    	(dwarf2dbg_final_check): Declare.
    	* read.c (s_leb128): Parse expression as deferred.
    	* testsuite/gas/all/gas.exp: Run sleb128-9.
    	* testsuite/gas/all/sleb128-9.d: New.
    	* testsuite/gas/all/sleb128-9.l: New.
    	* testsuite/gas/all/sleb128-9.s: New.
    	* testsuite/gas/elf/dwarf2-1.d: Add nonzero views.
    	* testsuite/gas/elf/dwarf2-2.d: Likewise.
    	* testsuite/gas/elf/dwarf2-5.d: New.
    	* testsuite/gas/elf/dwarf2-5.s: New.
    	* testsuite/gas/elf/dwarf2-6.d: New.
    	* testsuite/gas/elf/dwarf2-6.s: New.
    	* testsuite/gas/elf/dwarf2-7.d: New.
    	* testsuite/gas/elf/dwarf2-7.s: New.
    	* testsuite/gas/elf/dwarf2-8.d: New.
    	* testsuite/gas/elf/dwarf2-8.l: New.
    	* testsuite/gas/elf/dwarf2-8.s: New.
    	* testsuite/gas/elf/dwarf2-9.d: New.
    	* testsuite/gas/elf/dwarf2-9.l: New.
    	* testsuite/gas/elf/dwarf2-9.s: New.
    	* testsuite/gas/elf/dwarf2-10.d: New.
    	* testsuite/gas/elf/dwarf2-10.l: New.
    	* testsuite/gas/elf/dwarf2-10.s: New.
    	* testsuite/gas/elf/dwarf2-11.d: New.
    	* testsuite/gas/elf/dwarf2-11.s: New.
    	* testsuite/gas/elf/dwarf2-12.d: New.
    	* testsuite/gas/elf/dwarf2-12.s: New.
    	* testsuite/gas/elf/dwarf2-13.d: New.
    	* testsuite/gas/elf/dwarf2-13.s: New.
    	* testsuite/gas/elf/dwarf2-14.d: New.
    	* testsuite/gas/elf/dwarf2-14.s: New.
    	* testsuite/gas/elf/dwarf2-15.d: New.
    	* testsuite/gas/elf/dwarf2-15.s: New.
    	* testsuite/gas/elf/dwarf2-16.d: New.
    	* testsuite/gas/elf/dwarf2-16.s: New.
    	* testsuite/gas/elf/dwarf2-17.d: New.
    	* testsuite/gas/elf/dwarf2-17.s: New.
    	* testsuite/gas/elf/dwarf2-18.d: New.
    	* testsuite/gas/elf/dwarf2-18.s: New.
    	* testsuite/gas/elf/elf.exp: Run dwarf2-5..18 tests.
    	* testsuite/gas/i386/dw2-compress-1.d: Add nonzero views.
    	* testsuite/gas/i386/dw2-compressed-1.d: Likewise.
    	* testsuite/gas/i386/ilp32/lns/lns-duplicate.d: Likewise.
    	* testsuite/gas/lns/lns-big-delta.d: Likewise.
    	* testsuite/gas/lns/lns-duplicate.d: Likewise.
    	* testsuite/gas/mips/loc-swap-2.d: Likewise.
    	* testsuite/gas/mips/loc-swap-3.d: Likewise.
    	* testsuite/gas/mips/loc-swap.d: Likewise.
    	* testsuite/gas/mips/micromips@loc-swap-2.d: Likewise.
    	* testsuite/gas/mips/micromips@loc-swap.d: Likewise.
    	* testsuite/gas/mips/mips16@loc-swap-2.d: Likewise.
    	* testsuite/gas/mips/mips16@loc-swap.d: Likewise.
    	* testsuite/gas/mips/mips16e@loc-swap.d: Likewise.
    	* write.c (write_object_file): Check pending view asserts.
    	(cvt_frag_to_fill): Complain about undefined leb128 operand.

commit 47826cdbec2548cd1d25acf4cfaf908ae88f3325
Author: Andreas Krebbel <krebbel@linux.vnet.ibm.com>
Date:   Fri Jul 21 10:54:06 2017 +0200

    S/390: Support z14 as CPU name.
    
    With IBM z14 officially announced I can add z14 as CPU name.
    
    No regressions with that patch on s390x.
    
    gas/ChangeLog:
    
    2017-07-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* config/tc-s390.c (s390_parse_cpu): Add z14 as alternate CPU
    	name.
    	* doc/as.texinfo: Add z14 to CPU string list.
    	* doc/c-s390.texi: Likewise.
    
    opcodes/ChangeLog:
    
    2017-07-21  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
    
    	* s390-mkopc.c (main): Enable z14 as CPU string in the opcode
    	table.

commit 33d69f87279fd33a951eafd025b4d188bc71d97c
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jul 21 00:00:33 2017 +0000

    Automatic date update in version.in

commit 47e77640be31fc1a4eb3718f594ed5fd0faff065
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 18:28:01 2017 +0100

    Make language_def O(1)
    
    Profiling GDB with the rest of series applied, I saw calls to
    language_def showing up high in some runs.  The problem is that
    language_def is O(N) currently, since walk the languages vector each
    time to find the matching language_defn.
    
    IMO, the add_language mechanism is pointless, because "enum language"
    implies the core of GDB needs to know about all languages anyway.  So
    simply make the languages vector array be an array where each
    element's index is the corresponding enum language enumerator.  Note
    that "local_language_defn" is gone along the way.  It's just a copy of
    "auto", so the new code simply maps one to the other.  One fewer place
    to update when we need to change the language vector...
    
    Also, a while ago the output of "set language" was made out of order
    as side effect of some other change.  While I was at it, I made them
    sorted again.
    
    gdb/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_language_defn): Make extern.
    	(_initialize_ada_language): Remove add_language call.
    	* c-lang.c (c_language_defn, cplus_language_defn)
    	(asm_language_defn, minimal_language_defn): Make extern.
    	(_initialize_c_language): Delete.
    	* completer.c (compare_cstrings): Delete, moved to utils.h.
    	* d-lang.c (d_language_defn): Make extern.
    	(_initialize_d_language): Remove add_language calls.
    	* defs.h (enum language): Add comment.
    	* f-lang.c (f_language_defn): Make extern.
    	(_initialize_f_language): Remove add_language call.
    	* go-lang.c (go_language_defn): Make extern.
    	(_initialize_go_language): Remove add_language call.
    	* language.c: Include <algorithm>.
    	(languages): Redefine as const array.
    	(languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
    	(set_language_command): Handle "local".  Use for-range loop.
    	(set_language): Remove loop.
    	(language_enum): Rewrite.
    	(language_def, language_str): Remove loops.
    	(add_language): Delete.
    	(add_set_language_command): New, based on add_languages.
    	(skip_language_trampoline): Adjust.
    	(local_language_defn): Delete.
    	(language_gdbarch_post_init): Adjust.
    	(_initialize_language): Remove add_language calls.  Call
    	add_set_language_command.
    	* language.h (add_language): Delete.
    	(auto_language_defn)
    	(unknown_language_defn, minimal_language_defn, ada_language_defn)
    	(asm_language_defn, c_language_defn, cplus_language_defn)
    	(d_language_defn, f_language_defn, go_language_defn)
    	(m2_language_defn, objc_language_defn, opencl_language_defn)
    	(pascal_language_defn, rust_language_defn): Declare.
    	* m2-lang.c (m2_language_defn): Make extern.
    	(_initialize_m2_language): Remove add_language call.
    	* objc-lang.c (objc_language_defn): Make extern.
    	(_initialize_objc_language): Remove add_language call.
    	* opencl-lang.c (opencl_language_defn): Make extern.
    	(_initialize_opencl_language): Remove add_language call.
    	* p-lang.c (pascal_language_defn): Make extern.
    	(_initialize_pascal_language): Delete.
    	* rust-lang.c (rust_language_defn): Make extern.
    	(_initialize_rust_language): Delete.
    	* utils.h (compare_cstrings): New static inline function.
    
    gdb/testsuite/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/default.exp (set language): Adjust expected output.

commit edb0c9cb22e5be90a76b8698b45e9eaee596f315
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 18:12:19 2017 +0100

    get_int_var_value
    
    I noticed that get_int_var_value's parameters could use some
    constification.  And then realized that client code would become
    simpler by changing the interface to return the success/failure
    indication as actual return value, as it allows getting rid of the
    local "boolean" variable.
    
    gdb/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_to_fixed_type_1): Adjust.
    	(get_var_value): Constify parameters.
    	(get_int_var_value): Change prototype.
    	(to_fixed_range_type): Adjust.
    	* ada-lang.h (get_int_var_value): Change prototype.

commit a778f165ad24111597fa48beb4a62359501e0076
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 18:06:13 2017 +0100

    Use SYMBOL_MATCHES_SEARCH_NAME some more
    
    gdb/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (dw2_lookup_symbol): Use
    	SYMBOL_MATCHES_SEARCH_NAME.
    	* psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.

commit 42edd901a220d9d963d2121d7014b81d43c1ac66
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 18:04:46 2017 +0100

    Eliminate block_iter_name_*
    
    This patch gets rid of block_iter_name_* as being unnecessary.  It's
    the same as calling block_iter_match_*, and passing strcmp_iw as
    comparison routine.
    
    (A later patch will get rid of those new explicit strcmp_iw calls.)
    
    gdb/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* block.c (block_iter_name_step, block_iter_name_first)
    	(block_iter_name_next): Delete.
    	(block_lookup_symbol_primary): Adjust to use
    	dict_iter_match_first/dict_iter_match_next.
    	* block.h (block_iter_name_first, block_iter_name_next): Delete
    	declarations.
    	(ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
    	dict_iter_match_first/dict_iter_match_next.

commit cf3252992378872212eeaaca090fe3b1491bcd3f
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 17:58:17 2017 +0100

    Fix cp_find_first_component_aux bug
    
    Valgrind catches an out-of-bounds read here:
    
     $ gdb ./testsuite/outputs/gdb.cp/method2/method2
     (gdb) start
     [...]
     Temporary breakpoint 1, main (argc=1, argv=0x7fffffffd958) at src/gdb/testsuite/gdb.cp/method2.cc:26
     26        return 0;
     (gdb) b A::operator
     ==26907== Invalid read of size 1
     ==26907==    at 0x75C0AE: cp_find_first_component_aux(char const*, int) (cp-support.c:951)
     ==26907==    by 0x75C084: cp_find_first_component(char const*) (cp-support.c:925)
     ==26907==    by 0x75C3DA: cp_entire_prefix_len(char const*) (cp-support.c:1089)
     ==26907==    by 0x758B16: cp_lookup_symbol_in_namespace(char const*, char const*, block const*, domain_enum_tag, int) (cp-namespace.c:314)
     ==26907==    by 0x75972A: lookup_namespace_scope(language_defn const*, char const*, block const*, domain_enum_tag, char const*, int) (cp-namespace.c:739)
     ==26907==    by 0x7597CB: cp_lookup_symbol_nonlocal(language_defn const*, char const*, block const*, domain_enum_tag) (cp-namespace.c:768)
     ==26907==    by 0x8C1137: lookup_symbol_aux(char const*, block const*, domain_enum_tag, language, field_of_this_result*) (symtab.c:2016)
     ==26907==    by 0x8C098A: lookup_symbol_in_language(char const*, block const*, domain_enum_tag, language, field_of_this_result*) (symtab.c:1824)
     ==26907==    by 0x8C0A04: lookup_symbol(char const*, block const*, domain_enum_tag, field_of_this_result*) (symtab.c:1836)
     ==26907==    by 0x82CBE1: find_label_symbols(linespec_state*, VEC_symbolp*, VEC_symbolp**, char const*) (linespec.c:3390)
     ==26907==    by 0x828FB5: linespec_parse_basic(ls_parser*) (linespec.c:1620)
     ==26907==    by 0x82A78F: parse_linespec(ls_parser*, char const*) (linespec.c:2307)
     ==26907==  Address 0x910f97c is 0 bytes after a block of size 12 alloc'd
     ==26907==    at 0x4C28BF6: malloc (vg_replace_malloc.c:299)
     ==26907==    by 0x74E737: xmalloc (common-utils.c:43)
     ==26907==    by 0x74EAF4: savestring(char const*, unsigned long) (common-utils.c:179)
     ==26907==    by 0x826CEF: copy_token_string(ls_token) (linespec.c:488)
     ==26907==    by 0x828EF6: linespec_parse_basic(ls_parser*) (linespec.c:1599)
     ==26907==    by 0x82A78F: parse_linespec(ls_parser*, char const*) (linespec.c:2307)
     ==26907==    by 0x82AE27: event_location_to_sals(ls_parser*, event_location const*) (linespec.c:2469)
     ==26907==    by 0x82B1CE: decode_line_full(event_location const*, int, program_space*, symtab*, int, linespec_result*, char const*, char const*) (linespec.c:2557)
     ==26907==    by 0x720C8A: parse_breakpoint_sals(event_location const*, linespec_result*) (breakpoint.c:9550)
     ==26907==    by 0x72A2F7: create_sals_from_location_default(event_location const*, linespec_result*, bptype) (breakpoint.c:14484)
     ==26907==    by 0x727F86: bkpt_create_sals_from_location(event_location const*, linespec_result*, bptype) (breakpoint.c:13219)
     ==26907==    by 0x72146D: create_breakpoint(gdbarch*, event_location const*, char*, int, char*, int, int, bptype, int, auto_boolean, breakpoint_ops const*, int, int, int, unsigned int) (breakpoint.c:9759)
    
    Tests exercising this will be added further down the series.
    
    gdb/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* cp-support.c (cp_find_first_component_aux): Add missing case for
    	end of string.

commit 62d2a18a2e4bdb3c278ecda54c8317f179375d28
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 20 17:52:03 2017 +0100

    Make gdb.base/dmsym.exp independent of "set language ada"
    
    This test is using "set language ada" expecting that to cause GDB to
    do Ada symbol name matching.  That won't work when GDB uses the
    symbol's language to decide which symbol matching algorithm to use,
    because the test's symbols are C symbols.
    
    So generalize the test a bit to not rely on Ada name matching rules.
    
    Confirmed that by undoing the original fix the test was written for,
    the test still fails.
    
    gdb/testsuite/ChangeLog:
    2017-07-20  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/dmsym.c (pck__foo__bar__minsym): Rename to ...
    	(test_minsym): ... this, and make static.
    	(get_pck__foo__bar__minsym): Rename to ...
    	(get_test_minsym): ... this.
    	* gdb.base/dmsym.exp (): Remove "set language ada" call.  Adjust
    	symbol names and comments.
    	* gdb.base/dmsym_main.c (get_pck__foo__bar__minsym): Rename to ...
    	(get_test_minsym): ... this.
    	(pck__foo__bar__minsym__2): Rename to ...
    	(test_minsym): ... this.
    	(main): Adjust.

commit 2d2dbad0605c85bb75662d2f219b1b886d5ab4cb
Author: Nick Clifton <nickc@redhat.com>
Date:   Thu Jul 20 11:47:16 2017 +0100

    Update the German translation for the opcodes library.
    
    	* po/de.po: Updated German translation.

commit 8e8f892f7033096576777216f37f922364bfe24e
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jul 20 00:00:34 2017 +0000

    Automatic date update in version.in

commit 2018ef80ae7ebbe410aed0e30367fca27e3eb2d8
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Thu Jul 20 00:39:57 2017 +0100

    PR ld/16656: Add missing annotation to the relevant ChangeLog entries
    
    Add PR ld/16656 annotation to ChangeLog entries for commit 9a0f1d5099fa
    ("LD/testsuite: Conditionalize the placement of `.dynamic' in
    GNU_RELRO") and commit ("LD/testsuite: Conditionalize the placement of
    `.got' in GNU_RELRO").

commit f2e6a8430e72d58e70aaaaefbb32dc3953d5cf33
Author: Szabolcs Nagy <szabolcs.nagy@arm.com>
Date:   Tue Jul 4 15:43:59 2017 +0100

    [AArch64] Fix PR18841 ifunc relocation ordering
    
    In order to get the ifunc relocs properly sorted the correct class
    needs to be returned.  The code mimics what has been done for x86.
    
    Fixes
    FAIL: Run pr18841 with libpr18841c.so
    
    bfd/
    	PR ld/18841
    	* elfnn-aarch64.c (elfNN_aarch64_reloc_type_class): Return
    	reloc_class_ifunc for ifunc symbols.

commit 6c4e7b6bfbc4679f695106de2817ecf02b27c8be
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jul 19 16:14:02 2017 +0100

    Extend previous fix to coff-rs6000.c to coff64-rs6000.c
    
    	PR 21786
    	* coff64-rs6000.c (_bfd_strntol): New function.
    	(_bfd_strntoll): New function.
    	(GET_VALUE_IN_FIELD): New macro.
    	(xcoff64_slurp_armap): Use new macros.

commit 909e4e716c4d77e33357bbe9bc902bfaf2e1af24
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jul 19 14:49:12 2017 +0100

    Fix use-after-free error when parsing a corrupt nested archive.
    
    	PR 21787
    	* archive.c (bfd_generic_archive_p): If the bfd does not have the
    	correct magic bytes at the start, set the error to wrong format
    	and clear the format selector before returning NULL.

commit 62a5222fdab2acdc129b7c7d3713e7f349e26029
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Wed Jul 19 13:11:59 2017 +0100

    LD/testsuite: Add 2**4 section alignment FILL script statement test
    
    Complement commit ffe54b3798db ("Pad sections according to current
    script FILL.") and add a FILL script statement test for targets that
    impose the minimum alignment of more than 2**2 for the `.text' section.
    These targets include IA-64 targets, MIPS targets other than bare-metal
    ELF and VxWorks, TILE-Gx targets, TILEPro targets and X86-64 PE targets.
    
    Use the `notarget' tag for configuration triplets that are incompatible
    with the new test, but are supported by the existing FILL test, and
    `xfail' for ones that have issues due to section alignment or padding
    with both tests.  Make a complementary change to the existing FILL test,
    removing the following test issues:
    
    arm-epoc-pe  -FAIL: ld-scripts/fill
    mips-elf  -XPASS: ld-scripts/fill
    mips-img-elf  -XPASS: ld-scripts/fill
    mips-mti-elf  -XPASS: ld-scripts/fill
    mips-sde-elf  -XPASS: ld-scripts/fill
    mips-vxworks  -XPASS: ld-scripts/fill
    mipsel-elf  -XPASS: ld-scripts/fill
    mipsel-img-elf  -XPASS: ld-scripts/fill
    mipsel-mti-elf  -XPASS: ld-scripts/fill
    mipsel-vxworks  -XPASS: ld-scripts/fill
    mipsisa32-elf  -XPASS: ld-scripts/fill
    mipsisa32el-elf  -XPASS: ld-scripts/fill
    mipsisa64-elf  -XPASS: ld-scripts/fill
    mipsisa64el-elf  -XPASS: ld-scripts/fill
    tilegx-linux  -FAIL: ld-scripts/fill
    tilepro-elf  -FAIL: ld-scripts/fill
    tx39-elf  -XPASS: ld-scripts/fill
    
    	ld/
    	* testsuite/ld-scripts/fill.d: Adjust `xfail' entries.  Add
    	`notarget' entries.  Update comments.
    	* testsuite/ld-scripts/fill16.d: New test.
    	* testsuite/ld-scripts/fill16_0.s: New test source.
    	* testsuite/ld-scripts/fill16_1.s: New test source.
    	* testsuite/ld-scripts/fill16_2.s: New test source.
    	* testsuite/ld-scripts/data.exp: Run the new test.

commit 29866fa186ee3ebda5242221607dba360b2e541e
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jul 19 11:07:43 2017 +0100

    Fix address violation when attempting to read a corrupt field in a COFF archive header structure.
    
    	PR 21786
    	* coff-rs6000.c (_bfd_strntol): New function.
    	(_bfd_strntoll): New function.
    	(GET_VALUE_IN_FIELD): New macro.
    	(EQ_VALUE_IN_FIELD): new macro.
    	(_bfd_xcoff_slurp_armap): Use new macros.
    	(_bfd_xcoff_archive_p): Likewise.
    	(_bfd_xcoff_read_ar_hdr): Likewise.
    	(_bfd_xcoff_openr_next_archived_file): Likewise.
    	(_bfd_xcoff_stat_arch_elt): Likewise.

commit 70b448ba7c521d6e0881f38aaf20d330fe510716
Author: claziss <claziss@synopsys.com>
Date:   Wed Jul 19 09:56:55 2017 +0200

    [ARC] Add SecureShield AUX registers
    
    Update auxiliary registers with SecureShield ones.
    
    opcodes/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* arc-regs.h (sec_stat): New aux register.
    	(aux_kernel_sp): Likewise.
    	(aux_sec_u_sp): Likewise.
    	(aux_sec_k_sp): Likewise.
    	(sec_vecbase_build): Likewise.
    	(nsc_table_top): Likewise.
    	(nsc_table_base): Likewise.
    	(ersec_stat): Likewise.
    	(aux_sec_except): Likewise.

commit 7179e0e6b2e0ed7b220af8836a88ef308faf5898
Author: Claudiu Zissulescu <claziss@synopsys.com>
Date:   Wed Jul 19 09:56:55 2017 +0200

    [ARC] Add SJLI instruction.
    
    include/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* opcode/arc.h (SJLI): Add.
    
    opcode/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* arc-opc.c (extract_uimm12_20): New function.
    	(UIMM12_20): New operand.
    	(SIMM3_5_S): Adjust.
    	* arc-tbl.h (sjli): Add new instruction.

commit 684d5a10b1332e2a1b03a1d6e7a899ef87b3ea16
Author: John Eric Martin <John.Martin@emmicro-us.com>
Date:   Wed Jul 19 09:56:55 2017 +0200

    [ARC] Add JLI support.
    
    The following relocation types were added to GCC/binutils:
    
    ARC_JLI_SECTOFF is a relocation type in Metaware that is now used by
    GCC as well to adjust the index of function calls to functions with
    attribute jli_call_always.
    
    bfd/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    	    John Eric Martin  <John.Martin@emmicro-us.com>
    
    	* bfd-in2.h: Regenerate.
    	* libbfd.h: Regenerate.
    	* elf32-arc.c (JLI): Define.
    	* reloc.c: Add JLI relocations.
    
    gas/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    
    	* testsuite/gas/arc/jli-1.d: New file.
    	* testsuite/gas/arc/jli-1.s: Likewise.
    	* testsuite/gas/arc/taux.d: Update for jli_base.
    
    include/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    	    John Eric Martin  <John.Martin@emmicro-us.com>
    
    	* elf/arc-reloc.def: Add JLI relocs howto.
    	* opcode/arc-func.h (replace_jli): New function.
    
    ld/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    	    John Eric Martin  <John.Martin@emmicro-us.com>
    
    	* emulparams/arcelf.sh (JLI_START_TABLE): Define.
    	* scripttempl/elfarc.sc: Handle jlitab section.
    	* scripttempl/elfarcv2.sc: Likewise.
    	* testsuite/ld-arc/arc.exp: Add JLI test.
    	* testsuite/ld-arc/jli-script.ld: New file.
    	* testsuite/ld-arc/jli-simple.dd: Likewise.
    	* testsuite/ld-arc/jli-simple.rd: Likewise.
    	* testsuite/ld-arc/jli-simple.s: Likewise.
    	* testsuite/ld/testsuite/ld-arc/jli-overflow.s: Likewise.
    	* testsuite/ld/testsuite/ld-arc/jli-overflow.d: Likewise.
    	* testsuite/ld/testsuite/ld-arc/jli-overflow.err: Likewise.
    
    opcode/
    2017-07-19  Claudiu Zissulescu  <claziss@synopsys.com>
    	    John Eric Martin  <John.Martin@emmicro-us.com>
    
    	* arc-opc.c (UIMM10_6_S_JLIOFF): Define.
    	(UIMM3_23): Adjust accordingly.
    	* arc-regs.h: Add/correct jli_base register.
    	* arc-tbl.h (jli_s): Likewise.

commit e4943f2c7569a829eb6129f10f7c5401a96aaa08
Author: Tristan Gingold <tgingold@free.fr>
Date:   Wed Jul 19 09:55:12 2017 +0200

    Remove datasize measurements based on sbrk()
    
    binutils/
    	* nm.c (show_stats): Remove variable.
    	(long_options): Remove --stats option.
    	(main): Remove handling of --stats.
    
    ld/
    	* ldmain.c (main): Remove display of data size.
    
    gas/
    	* as.c (start_sbrk): Remove.
    	(main): Remove assignment.
    	(dump_statistics): Remove display of data size.

commit 804a4093182a4bdbc30abfd3081a3f58c3bd2329
Author: Tristan Gingold <tgingold@free.fr>
Date:   Wed Jul 19 08:05:30 2017 +0200

    Fix gas crash on missing seh_endproc.
    
    gas/
    	* testsuite/gas/pe/seh-x64-err-2.s: New test.
    	* testsuite/gas/pe/seh-x64-err-2.l: New stderr output.
    	* testsuite/gas/pe/pe.exp: Add test.
    	* config/obj-coff-seh.c (obj_coff_seh_do_final): Don't try to end
    	seh part.

commit 801f648cfc26f588aee8fc37ddc4ac959f331bd0
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jul 19 00:00:59 2017 +0000

    Automatic date update in version.in

commit 927960f053ec6e361236964c3780d2acd5de4084
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jul 18 17:20:30 2017 +0100

    LD/testsuite: Conditionalize the placement of `.got' in GNU_RELRO
    
    Complement commit d345186d0535 ("Check if GNU_RELRO segment is is
    generated") and exclude the presence of a `.got' section from implying
    the creation of a GNU_RELRO segment for targets which place the section
    along with small data, and therefore as it stands cannot have the
    section assigned to GNU_RELRO.  This is because we currently only
    support a single GNU_RELRO segment and we place it at the beginning of
    regular data which is then separated from small data by read-write data.
    
    Currently the list of such targets consists of Alpha, Linux HPPA, NetBSD
    HPPA, OpenBSD HPPA, Meta, MIPS, Nios II, OpenRISC 1000, RISC-V, SH and
    X86-64, as determined by examining default linker scripts produced in a
    `--enable-targets=all' build for those that have DATA_SEGMENT_RELRO_END
    set and `.got' placed beyond.  These targets do not set NO_SMALL_DATA or
    DATA_GOT in their respective files in ld/emulparams/*, hovever checking
    for the absence of these settings on its own is not very feasible due to
    the structure of these files and the lack of support for GNU_RELRO by
    some targets in the first place.
    
    Add a separate control for `.got.plt' which does get placed in GNU_RELRO
    on MIPS targets even though `.got' does not.
    
    	ld/
    	* testsuite/ld-elf/binutils.exp (binutils_test): Make the
    	expectation for `.got' in GNU_RELRO segment target-specific.
    	Handle `.got.plt' separately.

commit 9a0f1d5099fa375299115afaa1ef3acbddc47f51
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Tue Jul 18 17:20:30 2017 +0100

    LD/testsuite: Conditionalize the placement of `.dynamic' in GNU_RELRO
    
    Complement commit d345186d0535 ("Check if GNU_RELRO segment is is
    generated") and exclude the presence of a `.dynamic' section from
    implying the creation of a GNU_RELRO segment for targets which place the
    section in the (read-only) text segment, and therefore cannot have the
    section assigned to GNU_RELRO and neither it would make sense.
    
    Currently the list of such targets consists of 64-bit HPPA and
    non-VxWorks MIPS targets, as determined by looking for TEXT_DYNAMIC
    being set across ld/emulparams/* and then verified by examining default
    linker scripts produced in a `--enable-targets=all' build.
    
    	ld/
    	* testsuite/ld-elf/binutils.exp (binutils_test): Make the
    	expectation for `.dynamic' in GNU_RELRO segment target-specific.

commit de194d8575765da6c7905d09b8675c59fad035e9
Author: Yuri Chornovian <yurchor@ukr.net>
Date:   Tue Jul 18 16:58:14 2017 +0100

    Fix spelling typos.

commit c5ed057625f886b14d9def3fa7488fd8bbbf7dd3
Author: David Blaikie <dblaikie@gmail.com>
Date:   Tue Jul 18 16:06:17 2017 +0100

    Fix Fission (broken by my previous patch)
    
    Turns out somewhere along the refactoring of the multiple-CU support
    for Fission I broke the patch before submitting it (& seems to have
    broken Fission support generally).
    
    Syncing back to the point at which the patch was committed, the
    previous test results on my machine are:
    
     expected passes: 36137
     unexpected failures: 416
    
    with the previous (broken) patch committed:
    
     expected passes: 36131
     unexpected failures: 429
    
    With this one line patch applied on top of the broken commit:
    
     expected passes: 36144
     unexpected failures: 416
    
    (& all other result counts remained the same in all 3 cases)
    
    gdb/ChangeLog:
    2017-07-18  David Blaikie  <dblaikie@gmail.com>
    
    	* dwarf2read.c (create_cus_hash_table): Re-add lost initialization
    	of dwo_cu's dwo_file.

commit e4e21d9ed14c74304bc060a9d892c0edfc4c8ab4
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 18 15:46:13 2017 +0100

    Fix runtime failure triggered by a corrupt ecoff input file.
    
    	PR binutils/21781
    	* coffcode.h (handle_COMDAT): Replace abort with an error message
    	and return.

commit e29599e65a947b1a4bf051187f3025521b4e0d32
Merge: 400e542 27841e7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Jul 18 07:34:06 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 27841e762c975f6b1ffa0adbffc22405241262df
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Jul 18 12:57:19 2017 +0100

    Remove one line comment
    
    This patch is going to remove a line comment, which was added in this
    commit,
    
    commit 55fea07
    Author: Jim Kingdon <jkingdon@engr.sgi.com>
    Date:   Tue Sep 14 01:08:22 1993 +0000
    
            * remote.c: Define remote_debug to 0 and #if 0 baud_rate.  Temporary
            hack so this file compiles again.
    
            * remote-utils.c (gr_multi_scan): Cast return value from alloca.
            (gr_multi_scan): #if 0 never-reached return(-1).
    
    and at that moment, remote_prepare_to_store does updates some global
    state,
    
    static void
    remote_prepare_to_store ()
    {
      /* Make sure the entire registers array is valid.  */
      read_register_bytes (0, (char *)NULL, REGISTER_BYTES);
    }
    
    However, now, remote_prepare_to_store doesn't do that at all, and
    rsa->sizeof_g_packet is updated in init_remote_state, so the line of
    comment is out of date, and this patch removes it.
    
    gdb:
    
    2017-07-18  Yao Qi  <yao.qi@linaro.org>
    
    	* remote.c (store_registers_using_G): Remove one line comment.

commit cfb7e58b483faa7ca4a3a8bb0030ed3e990b2c5c
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Jul 18 12:46:14 2017 +0100

    Simplify regcache_cpy and remove regcache::cpy_no_passthrough
    
    Nowadays, regcache_cpy is used where src is read-only and dst is not
    read-only, so the regcache_cpy can be simplified to handle this case only.
    As a result, regcache::cpy_no_passthrough, which is about two read-only
    regcache copy, is no longer used, remove it as well.
    
    gdb:
    
    2017-07-18  Yao Qi  <yao.qi@linaro.org>
    
    	* regcache.c (regcache_cpy): Simplify it.
    	(regcache::cpy_no_passthrough): Remove it.
    	* regcache.h (cpy_no_passthrough): Remove it.
    	(regcache_dup, regcache_cpy): Update comments.

commit c646b4e87f4b3445f83d48fa7d85999dd702c50f
Author: Yao Qi <yao.qi@linaro.org>
Date:   Tue Jul 18 12:39:22 2017 +0100

    Improve doc about "maint print c-tdesc"
    
    In my patch extending command "maint print c-tdesc"
    (https://sourceware.org/ml/gdb-patches/2017-06/msg00286.html), Eli
    raised some questions on the existing doc to this command.  It is not
    very clear, so this patch improves it.  Eli approved it.
    
    gdb/doc:
    
    2017-07-18  Yao Qi  <yao.qi@linaro.org>
    
    	* gdb.texinfo (Maintenance Commands): Improve the doc to
    	command "maint print c-tdesc".

commit b6a577132682c291255f91a6bb56a3817048e905
Author: Nick Clifton <nickc@redhat.com>
Date:   Tue Jul 18 12:18:01 2017 +0100

    Import updated Ukranian and Swedish translations.
    
    gas	* po/uk.po: Updated Ukranian translation.
    
    binutils* po/sv.po: Updated Swedish translation.

commit 386535dd91432b784f6a46f8a92c6a599ba30174
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jul 18 11:38:17 2017 +0100

    Fix GDB builds that include the simulator
    
    The completer rewrite series missed adjusting target sim to the new
    completion_tracker interface.
    
    src/gdb/remote-sim.c: In function â??void _initialize_remote_sim()â??:
    src/gdb/remote-sim.c:1350:46: error: invalid conversion from â??VEC_char_ptr* (*)(cmd_list_element*, const char*, const char*)â?? to â??void (*)(cmd_list_element*, completion_tracker&, const char*, const char*)â?? [-fpermissive]
       set_cmd_completer (c, sim_command_completer);
                                                  ^
    
    This commit fixes it, and also takes care to be exception safe (the
    previous code would leak if growing the VEC throws).
    
    Tested manually with a --target=arm-none-eabi build.
    
    gdb/ChangeLog:
    2017-07-18  Pedro Alves  <palves@redhat.com>
    
    	* remote-sim.c (sim_command_completer): Adjust to work with a
    	completion_tracker instead of a VEC.

commit 0a79bef4f206d89214c48454a4302d6b6f8f68c0
Author: Hans-Peter Nilsson <hp@bitrange.com>
Date:   Tue Jul 18 12:14:38 2017 +0200

    * dwarf.c (display_debug_names): Initialize hash_prev.
    
    gcc-4.3.0 warns that it may be used uninitialized.  It takes a look
    and a half at the code to understand that it's false.

commit 25bda061bfe001db0b10a99e289293cadad5a0c9
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jul 18 00:00:50 2017 +0000

    Automatic date update in version.in

commit 89d249d2f26884b5e62301541aa9ab43bcaecb67
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jul 17 12:42:32 2017 -0700

    i386: Add tests for PIE with undefined weak symbol
    
    	* testsuite/ld-i386/i386.exp: Run pie1 and pie1-nacl.
    	* testsuite/ld-i386/pie1-nacl.d: New file.
    	* testsuite/ld-i386/pie1.d: Likewise.
    	* testsuite/ld-i386/pie1.s: Likewise.

commit 8e85f840e1870b17dce6a5bdb330c5bcd85a022a
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jul 17 12:40:57 2017 -0700

    Add missing ChangeLog entries for PR ld/21782 fix

commit c45ec17c07d8aa4554b0b2ca67a5f4dc2c87acc4
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 20:08:02 2017 +0100

    A smarter linespec completer
    
    Continuing the theme of the explicit locations patch, this patch gets
    rid of the need for quoting function names in linespec TAB completion.
    To recap, when you have overloads in your program, and you want to set
    a breakpoint in one of them:
    
     void function(int);  // set breakpoint here.
     void function(long);
    
     (gdb) b function(i[TAB]
     <all the symbols in the program that start with "i" are uselessly shown...>
    
    This patch gets rid of the need for quoting by switching the linespec
    completer to use the custom completion word point mechanism added in
    the previous explicit location patch (extending it as needed), to
    correctly determine the right completion word point.  In the case
    above, we want the completer to figure out that it's completing a
    function name that starts with "function(i", and it now does.
    
    We also want the completer to know when it's potentially completing a
    source file name, for:
    
    (gdb) break source.[TAB] -> source.c:
    (gdb) break source.c:  # Type line number or function name now
    
    And we want it to know to complete label names, which it doesn't today:
    
    (gdb) break function:lab[TAB]
    
    etc., etc.
    
    So what we want is for completion to grok the input string as closely
    to how the linespec parser groks it.
    
    With that in mind, the solution suggests itself - make the linespec
    completer use the same parsing code as normal linespec parsing.
    
    That's what the patch does.  The old completer is replaced by one that
    reuses the actual linespec parser as much as possible.  This (ideally)
    eliminate differences between what completion understands and actually
    setting breakpoints understands by design.
    
    The completer now offers sensible completion candidates depending on
    which component of the linespec is being completed, source filename,
    function, line number, expression, and (a new addition), labels.  For
    example, when completing the function part, we now show the full name
    of the method as completion candidates, instead of showing whatever
    comes after what readline considered the word break character:
    
     (gdb) break klass::method[TAB]
     klass:method1(int)
     klass:method2()
    
    If input is past the function, then we now offer keyword condidates:
    
      (gdb) b function(int) [TAB]
      if      task    thread
    
    If input is past a keyword, we offer expression completion, which is
    different from linespec completion:
    
      (gdb) b main if 1 + glo[TAB]
      global
    
    (e.g., completes on types, struct data fields, etc.)
    
    As mentioned, this teaches the linespec completer about completing
    label symbols too:
    
      (gdb) b source.c:function:lab[TAB]
    
    A nice convenience is that when completion uniquely matches a source
    name, gdb adds the ":" automatically for you:
    
      (gdb) b filenam[TAB]
      (gdb) b filename.c:  # ':' auto-added, cursor right after it.
    
    It's the little details.  :-)
    
    I worked on this patch in parallel with writing the (big) testcase
    added closer to the end of the series, which exercises many many
    tricky cases around quoting and whitespace insertion placement.  In
    general, I think it now all Just Works.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* completer.c (complete_source_filenames): New function.
    	(complete_address_and_linespec_locations): New function.
    	(location_completer): Use complete_address_and_linespec_locations.
    	(completion_tracker::build_completion_result): Honor the tracker's
    	request to suppress append.
    	* completer.h (completion_tracker::suppress_append_ws)
    	(completion_tracker::set_suppress_append_ws): New methods.
    	(completion_tracker::m_suppress_append_ws): New field.
    	(complete_source_filenames): New declaration.
    	* linespec.c (linespec_complete_what): New.
    	(struct ls_parser) <complete_what, completion_word,
    	completion_quote_char, completion_quote_end, completion_tracker>:
    	New fields.
    	(string_find_incomplete_keyword_at_end): New.
    	(linespec_lexer_lex_string): Record quote char.  If in completion
    	mode, don't throw.
    	(linespec_lexer_consume_token): Advance the completion word point.
    	(linespec_lexer_peek_token): Save/restore completion info.
    	(save_stream_and_consume_token): New.
    	(set_completion_after_number): New.
    	(linespec_parse_basic): Set what to complete next depending on
    	token.  Handle function and label completions specially.
    	(parse_linespec): Disable objc shortcut in completion mode.  Set
    	what to complete next depending on token type.  Skip keyword if in
    	completion mode.
    	(complete_linespec_component, linespec_complete): New.
    	* linespec.h (linespec_complete): Declare.
    
    gdb/testsuite/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* gdb.base/completion.exp: Adjust expected output.
    	* gdb.linespec/ls-errs.exp: Don't send tab characters, now that
    	the completer works.

commit be966d4207ff8df6572a23b911e5a69a2ab9370f
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 20:28:12 2017 +0100

    Linespec lexing and C++ operators
    
    There's some lexing code in linespec that isn't handling C++ operators
    correctly.  It's the usual confusion with operator< / operator<<, in
    code that wants to skip past template parameters.
    
    The linespec_lexer_lex_string change is necessary otherwise we get
    this (with current master):
    
     (gdb) break 'operator<'
     unmatched quote
    
    The need for the find_toplevel_char change was exposed by the use of
    that function in the explicit location completer.  Without the fix,
    that completer is not able to "see" past operator< symbols, without
    quoting, like:
    
     (gdb) b -function operator<(int, int) -labe[TAB]    # nothing happens
    
    gdb incorrectly thinks "-labe" is part of the "unclosed" template
    parameter list started with "<".
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* linespec.c (linespec_lexer_lex_string, find_toplevel_char):
    	Handle 'operator<' / 'operator<<'.

commit a245927022bc4351fafd9e6275e217021ec93e08
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 20:24:41 2017 +0100

    Explicit locations -label completer
    
    We're missing a completer for
    
      (gdb) break -function func -label [TAB]
    
    This patch adds one.  Tests will be added later in the series.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* completer.c (collect_explicit_location_matches): Handle
    	MATCH_LABEL.
    	(convert_explicit_location_to_linespec): New, factored out from
    	...
    	(convert_explicit_location_to_sals): ... this.
    	(complete_label): New.
    	(linespec_complete_label, find_label_symbols_in_block): New.
    	(find_label_symbols): Add completion_mode parameter and adjust to
    	call find_label_symbols_in_block.
    	* linespec.h (linespec_complete_label): Declare.

commit c6756f62e04846d68c24ee922ddb0377d4bd17f2
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 20:21:33 2017 +0100

    Rewrite/enhance explicit locations completer, parse left->right
    
    One of the most annoying (to me) things about GDB's completion is when
    you have overloads in your program, and you want to set a breakpoint
    in one of them:
    
     void function(int);  // set breakpoint here.
     void function(long);
    
     (gdb) b -f func[TAB]
     (gdb) b -f function(       # ok, gdb completed as much as possible.
     (gdb) b -f function([TAB]  # show me the overloads, please.
     <_all_ symbols in the program are shown...>
    
    E.g., when debugging GDB, that'd be:
    
     (gdb) b -f function([TAB]
     (anonymous namespace)::get_global()::global  pt_insn_get_offset@plt                       scm_new_port_table_entry
     asprintf                                     pt_pkt_alloc_decoder                         scm_new_port_table_entry@plt
     asprintf@plt                                 pt_pkt_alloc_decoder@plt                     scm_out_of_range
     bt_ctf_get_char_array                        pt_pkt_sync_forward                          scm_out_of_range@plt
     bt_ctf_get_char_array@plt                    pt_pkt_sync_forward@plt                      scm_putc
     bt_ctf_get_uint64                            pwrite                                       scm_putc@plt
     bt_ctf_get_uint64@plt                        pwrite@plt                                   scm_reverse_x
     bt_ctf_iter_read_event                       PyErr_Restore                                scm_reverse_x@plt
     bt_ctf_iter_read_event@plt                   PyErr_Restore@plt                            scm_set_port_filename_x
     <snip...>
    
    Now that's a load of completely useless completions.
    
    The reason GDB offers those is that the completer relies on readline
    figuring out the completion word point in the input line based on the
    language's word break characters, which include "(".  So readline
    tells the completer to complete on "", the string that is after '('.
    Likewise, if you type "function(i[TAB]" to try to complete to "int",
    you're out of luck.  GDB shows you all the symbols in the program that
    start with "i"...  This makes sense for the expression completer, as
    what you'd want to type is e.g., a global variable, say:
    
    (gdb) print function(i[TAB]
    
    but, it makes no sense when specifying a function name for a
    breakpoint location.
    
    To get around that limitation, users need to quote the function name,
    like:
    
     (gdb) b -f 'function([TAB]
     function(int)      function(long)
     (gdb) b 'function(i[TAB]
     (gdb) b 'function(int)' # now completes correctly!
    
    Note that the quoting is only necessary for completion.  Creating the
    breakpoint does not require the quoting:
    
     (gdb) b -f function(int) [RET]
     Breakpoint 1 at ....
    
    This patch removes this limitation.
    
    (
    Actually, it's a necessary patch, though not sufficient.  That'll
    start working correctly by the end of the series.  With this patch, if try it,
    you'll see:
    
     (gdb) b -f function(i[TAB]
     (gdb) b -f function
    
    i.e., gdb strips everything after the "(".  That's caused by some code
    in symtab.c that'll be eliminated further down the series.  These
    patches are all unfortunately interrelated, which is also the reason
    new tests only appear much later in the series.
    But let's ignore that reality for the remainder of the description.
    )
    
    So... this patch gets rid of the need for quoting.
    
    It does that by adding a way for a completer to control the exact
    completion word point that readline should start the completion
    request for, instead of letting readline try to figure it out using
    the current language's word break chars array, and often failing.
    
    In the case above, we want the completer to figure out that it's
    completing a function name that starts with "function(i".  It now
    does.
    
    It took me a while to figure out a way to ask readline to "use this
    exact word point", and for a while I feared that it'd be impossible
    with current readline (and having to rely on master readline for core
    functionality is something I'd like to avoid very much).  Eventually,
    after several different attempts, I came up with what is described in
    the comment above gdb_custom_word_point_brkchars in the patch.
    
    With this patch, the handle_brkchars phase of the explicit location
    completer advances the expected word point as it parses the input line
    left to right, until it figures out exactly what we're completing,
    instead of expecting readline to break the string using the word break
    characters, and then having the completer heuristically fix up a bad
    decision by parsing the input string backwards.  This allows correctly
    knowning that we're completing a symbol name after -function, complete
    functions without quoting, etc.
    
    Later, we'll make use of this same mechanims to implement a proper
    linespec completer that avoids need for quoting too.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (ada_collect_symbol_completion_matches): Add
    	complete_symbol_mode parameter.
    	* cli/cli-cmds.c (complete_command): Get the completion result out
    	of the handle_brkchars tracker if used a custom word point.
    	* completer.c: Include "linespec.h".
    	(enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
    	(advance_to_expression_complete_word_point): New.
    	(completion_tracker::completes_to_completion_word): New.
    	(complete_files_symbols): Pass down
    	complete_symbol_mode::EXPRESSION.
    	(explicit_options, probe_options): New.
    	(collect_explicit_location_matches): Complete on the
    	explictit_loc->foo instead of word.  Use
    	linespec_complete_function.  Handle MATCH_LINE.  Handle offering
    	keyword and options completions.
    	(backup_text_ptr): Delete.
    	(skip_keyword): New.
    	(complete_explicit_location): Remove 'word' parameter.  Add
    	language, quoted_arg_start and quoted_arg_end parameters.
    	Rewrite, parsing left to right.
    	(location_completer): Rewrite.
    	(location_completer_handle_brkchars): New function.
    	(symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
    	(enum complete_line_internal_reason): Adjust comments.
    	(completion_tracker::discard_completions): New.
    	(completer_handle_brkchars_func_for_completer): Handle
    	location_completer.
    	(gdb_custom_word_point_brkchars)
    	(gdb_org_rl_basic_quote_characters): New.
    	(gdb_completion_word_break_characters_throw)
    	(completion_find_completion_word): Handle trackers that use a
    	custom word point.
    	(completion_tracker::advance_custom_word_point_by): New.
    	(completion_tracker::build_completion_result): Don't rely on
    	readline appending the quote char.
    	(gdb_rl_attempted_completion_function_throw): Handle trackers that
    	use a custom word point.
    	(gdb_rl_attempted_completion_function): Restore
    	rl_basic_quote_characters.
    	* completer.h (class completion_tracker): Extend intro comment.
    	(completion_tracker::set_quote_char)
    	(completion_tracker::quote_char)
    	(completion_tracker::set_use_custom_word_point)
    	(completion_tracker::use_custom_word_point)
    	(completion_tracker::custom_word_point)
    	(completion_tracker::set_custom_word_point)
    	(completion_tracker::advance_custom_word_point_by)
    	(completion_tracker::completes_to_completion_word)
    	(completion_tracker::discard_completions): New methods.
    	(completion_tracker::m_quote_char)
    	(completion_tracker::m_use_custom_word_point)
    	(completion_tracker::m_custom_word_point): New fields.
    	(advance_to_expression_complete_word_point): Declare.
    	* f-lang.c (f_collect_symbol_completion_matches): Add
    	complete_symbol_mode parameter.
    	* language.h (struct language_defn)
    	<la_collect_symbol_completion_matches>: Add complete_symbol_mode
    	parameter.
    	* linespec.c (linespec_keywords): Add NULL terminator.  Make extern.
    	(linespec_complete_function): New function.
    	(linespec_lexer_lex_keyword): Adjust.
    	* linespec.h (linespec_keywords, linespec_complete_function): New
    	declarations.
    	* location.c (find_end_quote): New function.
    	(explicit_location_lex_one): Add explicit_completion_info
    	parameter.  Save quoting info.  Don't throw if being called for
    	completion.  Don't handle Ada operators here.
    	(is_cp_operator, skip_op_false_positives, first_of)
    	(explicit_location_lex_one_function): New function.
    	(string_to_explicit_location): Replace 'dont_throw' parameter with
    	an explicit_completion_info pointer parameter.  Handle it.  Don't
    	use explicit_location_lex_one to lex function names.  Use
    	explicit_location_lex_one_function instead.
    	* location.h (struct explicit_completion_info): New.
    	(string_to_explicit_location): Replace 'dont_throw' parameter with
    	an explicit_completion_info pointer parameter.
    	* symtab.c (default_collect_symbol_completion_matches_break_on):
    	Add complete_symbol_mode parameter.  Handle LINESPEC mode.
    	(default_collect_symbol_completion_matches)
    	(collect_symbol_completion_matches): Add complete_symbol_mode
    	parameter.
    	(collect_symbol_completion_matches_type): Pass down
    	complete_symbol_mode::EXPRESSION.
    	(collect_file_symbol_completion_matches): Add complete_symbol_mode
    	parameter.  Handle LINESPEC mode.
    	* symtab.h (complete_symbol_mode): New.
    	(default_collect_symbol_completion_matches_break_on)
    	(default_collect_symbol_completion_matches)
    	(collect_symbol_completion_matches)
    	(collect_file_symbol_completion_matches): Add complete_symbol_mode
    	parameter.
    
    gdb/testsuite/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* gdb.linespec/ls-errs.exp (do_test): Adjust expected output.

commit c5bb8910e80c6cd80c63541f86471c18375c8198
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jul 17 12:17:59 2017 -0700

    x86-64: Limit PIC check to shared library build
    
    When building an executable, undefined symbols are error and undefined
    weak symbols are resolved to zero.  We only need to check PIC for
    building a shared library.
    
    bfd/
    
    	PR ld/21782
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Limit PIC check
    	to shared library.
    
    ld/
    
    	PR ld/21782
    	* testsuite/ld-x86-64/pie3-nacl.d: New file.
    	* testsuite/ld-x86-64/pie3.d: Likewise.
    	* testsuite/ld-x86-64/pie3.s: Likewise.
    	* testsuite/ld-x86-64/x86-64.exp: Run pie3 and pie3-nacl.

commit 1d550c828c00978860de9ba35b9ab5b182b968bc
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 20:08:48 2017 +0100

    Introduce strncmp_iw
    
    The explicit locations completer patch will need a strncmp_iw
    function, that to strcmp_iw like strncmp is to strcmp.  This patch
    implements it.
    
    (Unit tests added a bit further down in this series will exercise
    this.)
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* utils.c (enum class strncmp_iw_mode): New.
    	(strcmp_iw): Rename to ...
    	(strncmp_iw_with_mode): ... this.  Add string2_len and mode
    	parameters.  Handle them.
    	(strncmp_iw): New.
    	(strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
    	* utils.h (strncmp_iw): Declare.
    	(strcmp_iw): Move describing comments here.

commit dd57c19c1abd19c71538631cd9e5b0f70eff5a5c
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Mon Jul 17 10:40:18 2017 -0700

    Re-indent elf_x86_64_relocate_section
    
    	* elf64-x86-64.c (elf_x86_64_relocate_section): Re-indent.

commit 8090b426b57bd9ebfa4c593ba3e6f939b2911739
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 15:51:55 2017 +0100

    Introduce CP_OPERATOR_STR/CP_OPERATOR_LEN and use throughout
    
    Move LENGTH_OF_OPERATOR from cp-support.c to cp-support.h so we can
    use it elsewhere.  Since there's already
    CP_ANONYMOUS_NAMESPACE_STR/CP_ANONYMOUS_NAMESPACE_LEN there, follow
    the same naming pattern for the new symbols.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
    	CP_OPERATOR_STR.
    	* c-typeprint.c (is_type_conversion_operator): Use
    	CP_OPERATOR_STR.
    	* cp-support.c (LENGTH_OF_OPERATOR): Delete.
    	(cp_find_first_component_aux): Use CP_OPERATOR_STR and
    	CP_OPERATOR_LEN.
    	* cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
    	* gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
    	* gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
    	* linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
    	CP_OPERATOR_STR.
    	* location.c: Include "cp-support.h".
    	(explicit_location_lex_one): Use CP_OPERATOR_LEN and
    	CP_OPERATOR_STR.
    	* symtab.c (operator_chars): Use CP_OPERATOR_STR and
    	CP_OPERATOR_LEN.

commit 6a2c1b8790e58ce0688507b5b1f8369aa621a665
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 15:30:59 2017 +0100

    "complete" command and completion word break characters
    
    The linespec/locations/completer testcase added later in the series
    tests every completion with both TAB completion and the "complete"
    command.  This exposed problems in the "complete" command, around
    determining the completion word point.
    
    First, the complete command has a too-simple approximation of what
    readline's TAB-completion code does to find the completion word point.
    Unfortunately, readline doesn't expose the functionality it uses
    internally, so to fix this this patch copies over the relevant code,
    and adjusts it a bit to better fit the use cases we need it for.
    (Specifically, our version avoids relying on the
    rl_word_break_characters, etc. globals, and instead takes those as
    arguments.)
    
    A following patch will want to use this function for TAB-completion
    too, but the "complete" command was a good excuse to split this to a
    separate patch.
    
    Then, notice how the complete_command does not call into the completer
    for the command being completed to determine the right set of word
    break characters.  It always uses the default set.  That is fixed by
    having the "complete" command call into complete_line_internal for a
    full handle_brkchars phase, just TAB-completion.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-cmds.c (complete_command): Use a completion tracker
    	along with completion_find_completion_word for handle_brkchars
    	phase.
    	* completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
    	(RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
    	(struct gdb_rl_completion_word_info): New.
    	(gdb_rl_find_completion_word): New.
    	(completion_find_completion_word): New.
    	* completer.h (completion_find_completion_word): Declare.

commit eb3ff9a55175dcdac8328b558d54951a14d719b1
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 14:45:59 2017 +0100

    Introduce class completion_tracker & rewrite completion<->readline interaction
    
    This patch reworks the whole completion machinery, and prepares it
    for later enhancements.
    
    Adds a new "completion_tracker" class that is meant to hold everything
    about the state of the current completion operation.
    
    This class now has the responsibility of tracking the list of
    completion matches, and checking whether the max completions limit has
    been reached.  You can look at this as this patch starting out by
    C++fying the existing "completion_tracker" in symtab.c (it's just an
    htab_t typedef currently), moving it to completer.h/c, and then making
    it a class/generalizing/enhancing it.
    
    Unlike with the current tracking, completion_tracker now checks
    whether the limit has been reached on each completion match list
    insertion.  This both simplifies the max-completions handling code
    (maybe_add_completion_enum is gone, for example), and is a
    prerequisite for follow up patches.
    
    The current completion_tracker is only used for symbol completions,
    and the symbol code gets at the current instance via globals.  This
    patch cleans that up by adding a completion_tracker reference to the
    signature of the completion functions, and passing the tracker around
    everywhere necessary.
    
    Then, the patch changes how the completion match list is handed over
    to readline.  Currently, we're using the rl_completion_entry_function
    readline entry point, and the patch switches to
    rl_attempted_completion_function.  A following patch will want to let
    GDB itself decide the common completion prefix between all matches
    (what readline calls the "lowest common denominator"), instead of
    having readline compute it, and that's not possible with the
    rl_completion_entry_function entry point.  Also,
    rl_attempted_completion_function lets GDB hand over the match list to
    readline as an array in one go instead of passing down matches one by
    one, so from that angle it's a nicer entry point anyway.
    
    Lastly, the patch catches exceptions around the readline entry points,
    because we can't let C++ exceptions cross readline.  We handle that in
    the readline input entry point, but the completion entry point isn't
    guarded, so GDB can abort if completion throws.  E.g., in current
    master:
    
     (gdb) b -function "fun<tab>
     terminate called after throwing an instance of 'gdb_exception_RETURN_MASK_ERROR'
     Aborted (core dumped)
    
    This patch fixes that.  This will be exercised in the new tests added
    later on in the series.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* ada-lang.c (symbol_completion_match): Adjust comments.
    	(symbol_completion_add): Replace vector parameter with
    	completion_tracker parameter.  Use it.
    	(ada_make_symbol_completion_list): Rename to...
    	(ada_collect_symbol_completion_matches): ... this.  Add
    	completion_tracker parameter and use it.
    	(ada_language_defn): Adjust.
    	* break-catch-syscall.c (catch_syscall_completer): Adjust
    	prototype and work with completion_tracker instead of VEC.
    	* breakpoint.c (condition_completer): Adjust prototype and work
    	with completion_tracker instead of VEC.
    	* c-lang.c (c_language_defn, cplus_language_defn)
    	(asm_language_defn, minimal_language_defn): Adjust to renames.
    	* cli/cli-cmds.c (complete_command): Rework using
    	completion_tracker.  Catch exceptions when completing.
    	* cli/cli-decode.c (integer_unlimited_completer)
    	(complete_on_cmdlist, complete_on_enum): Adjust prototype and work
    	with completion_tracker instead of VEC.
    	* command.h (struct completion_tracker): Forward declare.
    	(completer_ftype, completer_handle_brkchars_ftype): Change
    	types.
    	(complete_on_cmdlist, complete_on_enum): Adjust.
    	* completer.c: Include <algorithm>.
    	(struct gdb_completer_state): New.
    	(current_completion): New global.
    	(readline_line_completion_function): Delete.
    	(noop_completer, filename_completer)
    	(filename_completer_handle_brkchars, complete_files_symbols)
    	(linespec_location_completer): Adjust to work with a
    	completion_tracker instead of a VEC.
    	(string_or_empty): New.
    	(collect_explicit_location_matches): Adjust to work with a
    	completion_tracker instead of a VEC.
    	(explicit_location_completer): Rename to ...
    	(complete_explicit_location): ... this and adjust to work with a
    	completion_tracker instead of a VEC.
    	(location_completer): Adjust to work with a completion_tracker
    	instead of a VEC.
    	(add_struct_fields): Adjust to work with a completion_list instead
    	of VEC.
    	(expression_completer): Rename to ...
    	(complete_expression): ... this and adjust to work with a
    	completion_tracker instead of a VEC.  Use complete_files_symbols.
    	(expression_completer): Reimplement on top of complete_expression.
    	(symbol_completer): Adjust to work with a completion_tracker
    	instead of a VEC.
    	(enum complete_line_internal_reason): Add describing comments.
    	(complete_line_internal_normal_command): Adjust to work with a
    	completion_tracker instead of a VEC.
    	(complete_line_internal): Rename to ...
    	(complete_line_internal_1): ... this and adjust to work with a
    	completion_tracker instead of a VEC.  Assert TEXT is NULL in the
    	handle_brkchars phase.
    	(new_completion_tracker): Delete.
    	(complete_line_internal): Reimplement as TRY/CATCH wrapper around
    	complete_line_internal_1.
    	(free_completion_tracker): Delete.
    	(INITIAL_COMPLETION_HTAB_SIZE): New.
    	(completion_tracker::completion_tracker)
    	(completion_tracker::~completion_tracker): New.
    	(maybe_add_completion): Delete.
    	(completion_tracker::maybe_add_completion)
    	(completion_tracker::add_completion)
    	(completion_tracker::add_completions): New.
    	(throw_max_completions_reached_error): Delete.
    	(complete_line): Adjust to work with a completion_tracker instead
    	of a VEC.  Don't create a completion_tracker_t or check for max
    	completions here.
    	(command_completer, command_completer_handle_brkchars)
    	(signal_completer, reg_or_group_completer_1)
    	(reg_or_group_completer, default_completer_handle_brkchars):
    	Adjust to work with a completion_tracker.
    	(gdb_completion_word_break_characters_throw): New.
    	(gdb_completion_word_break_characters): Reimplement.
    	(line_completion_function): Delete.
    	(completion_tracker::recompute_lowest_common_denominator)
    	(expand_preserving_ws)
    	(completion_tracker::build_completion_result)
    	(completion_result::completion_result)
    	(completion_result::completion_result)
    	(completion_result::~completion_result)
    	(completion_result::completion_result)
    	(completion_result::release_match_list, compare_cstrings)
    	(completion_result::sort_match_list)
    	(completion_result::reset_match_list)
    	(gdb_rl_attempted_completion_function_throw)
    	(gdb_rl_attempted_completion_function): New.
    	* completer.h (completion_list, struct completion_result)
    	(class completion_tracker): New.
    	(complete_line): Add completion_tracker parameter.
    	(readline_line_completion_function): Delete.
    	(gdb_rl_attempted_completion_function): New.
    	(noop_completer, filename_completer, expression_completer)
    	(location_completer, symbol_completer, command_completer)
    	(signal_completer, reg_or_group_completer): Update prototypes.
    	(completion_tracker_t, new_completion_tracker)
    	(make_cleanup_free_completion_tracker): Delete.
    	(enum maybe_add_completion_enum): Delete.
    	(maybe_add_completion): Delete.
    	(throw_max_completions_reached_error): Delete.
    	* corefile.c (complete_set_gnutarget): Adjust to work with a
    	completion_tracker instead of a VEC.
    	* cp-abi.c (cp_abi_completer): Adjust to work with a
    	completion_tracker instead of a VEC.
    	* d-lang.c (d_language_defn): Adjust.
    	* disasm.c (disassembler_options_completer): Adjust to work with a
    	completion_tracker instead of a VEC.
    	* f-lang.c (f_make_symbol_completion_list): Rename to ...
    	(f_collect_symbol_completion_matches): ... this.  Adjust to work
    	with a completion_tracker instead of a VEC.
    	(f_language_defn): Adjust.
    	* go-lang.c (go_language_defn): Adjust.
    	* guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
    	Adjust to work with a completion_tracker instead of a VEC.
    	* infrun.c (handle_completer): Likewise.
    	* interps.c (interpreter_completer): Likewise.
    	* interps.h (interpreter_completer): Likewise.
    	* language.c (unknown_language_defn, auto_language_defn)
    	(local_language_defn): Adjust.
    	* language.h (language_defn::la_make_symbol_completion_list):
    	Rename to ...
    	(language_defn::la_collect_symbol_completion_matches): ... this
    	and adjust to work with a completion_tracker instead of a VEC.
    	* m2-lang.c (m2_language_defn): Adjust.
    	* objc-lang.c (objc_language_defn): Adjust.
    	* opencl-lang.c (opencl_language_defn): Adjust.
    	* p-lang.c (pascal_language_defn): Adjust.
    	* python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
    	(cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
    	with a completion_tracker.
    	* rust-lang.c (rust_language_defn): Adjust.
    	* symtab.c (free_completion_list, do_free_completion_list)
    	(return_val, completion_tracker): Delete.
    	(completion_list_add_name, completion_list_add_symbol)
    	(completion_list_add_msymbol, completion_list_objc_symbol)
    	(completion_list_add_fields, add_symtab_completions): Add
    	completion_tracker parameter and use it.
    	(default_make_symbol_completion_list_break_on_1): Rename to...
    	(default_collect_symbol_completion_matches_break_on): ... this.
    	Add completion_tracker parameter and use it instead of allocating
    	a completion tracker here.
    	(default_make_symbol_completion_list_break_on): Delete old
    	implementation.
    	(default_make_symbol_completion_list): Delete.
    	(default_collect_symbol_completion_matches): New.
    	(make_symbol_completion_list): Delete.
    	(collect_symbol_completion_matches): New.
    	(make_symbol_completion_type): Rename to ...
    	(collect_symbol_completion_matches_type): ... this.  Add
    	completion_tracker parameter and use it instead of VEC.
    	(make_file_symbol_completion_list_1): Rename to...
    	(collect_file_symbol_completion_matches): ... this.  Add
    	completion_tracker parameter and use it instead of VEC.
    	(make_file_symbol_completion_list): Delete.
    	(add_filename_to_list): Use completion_list instead of a VEC.
    	(add_partial_filename_data::list): Now a completion_list.
    	(make_source_files_completion_list): Work with a completion_list
    	instead of a VEC.
    	* symtab.h: Include "completer.h".
    	(default_make_symbol_completion_list_break_on)
    	(default_make_symbol_completion_list, make_symbol_completion_list)
    	(make_symbol_completion_type, make_file_symbol_completion_list)
    	(make_source_files_completion_list): Delete.
    	(default_collect_symbol_completion_matches_break_on)
    	(default_collect_symbol_completion_matches)
    	(collect_symbol_completion_matches)
    	(collect_symbol_completion_matches_type)
    	(collect_file_symbol_completion_matches)
    	(make_source_files_completion_list): New.
    	* top.c (init_main): Don't install a rl_completion_entry_function
    	hook.  Install a rl_attempted_completion_function hook instead.
    	* tui/tui-layout.c (layout_completer): Adjust to work with a
    	completion_tracker.
    	* tui/tui-regs.c (tui_reggroup_completer):
    	* tui/tui-win.c (window_name_completer, focus_completer)
    	(winheight_completer): Adjust to work with a completion_tracker.
    	* value.c: Include "completer.h".
    	(complete_internalvar): Adjust to work with a completion_tracker.
    	* value.h (complete_internalvar): Likewise.

commit 6e1dbf8cda1c66256179d0b15c96bc97ea5cf7b3
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 12:05:03 2017 +0100

    Clean up "completer_handle_brkchars" callback handling
    
    This patch cleans up "completer_handle_brkchars" callback handling:
    
    - Renames the function typedef to better match its intent:
      completer_ftype_void ->  completer_handle_brkchars_ftype
    
    - Factors out common code in complete_line_internal handling the
      "handle_brkchars" callback to a separate function.
    
    - Centralizes all the "completer method" to "handle_brkchars method"
      mapping in a single function.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
    	renames.
    	* cli/cli-decode.h (struct cmd_list_element) <completer>: Move
    	comments to completer_ftype's declaration.
    	<completer_handle_brkchars>: Change type to
    	completer_handle_brkchars_ftype.
    	* command.h (completer_ftype): Add describing comment and give
    	names to parameters.
    	(completer_ftype_void): Rename to ...
    	(completer_handle_brkchars_ftype) ... this.  Add describing comment.
    	(set_cmd_completer_handle_brkchars): Adjust.
    	* completer.c (filename_completer_handle_brkchars): New function.
    	(complete_line_internal_normal_command): New function, factored
    	out from ...
    	(complete_line_internal): ... here.
    	(command_completer_handle_brkchars)
    	(default_completer_handle_brkchars)
    	(completer_handle_brkchars_func_for_completer): New functions.
    	* completer.h (set_gdb_completion_word_break_characters): Delete
    	declaration.
    	(completer_handle_brkchars_func_for_completer): New declaration.
    	* python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
    	completer_handle_brkchars_func_for_completer.

commit 78b13106edcd14d87b4cc0b7f8dce8db8c2be489
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 11:55:42 2017 +0100

    Rename make_symbol_completion_list_fn -> symbol_completer
    
    "make_symbol_completion_list_fn" is odly named when you look at a list
    of "standard" completers, like the Python/Guile completer lists
    adjusted by this patch.  Rename / move it to completers.h/c, for
    consistency.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* completer.c (symbol_completer): New function, based on
    	make_symbol_completion_list_fn.
    	* completer.h (symbol_completer): New declaration.
    	* guile/scm-cmd.c (cmdscm_completers): Adjust.
    	* python/py-cmd.c (completers): Adjust.
    	* symtab.c (make_symbol_completion_list_fn): Delete.
    	* symtab.h (make_symbol_completion_list_fn): Delete.
    	* cli/cli-decode.c (add_cmd): Adjust.

commit bbf2f4dfaec5cf2e21b0935300b4921f0b5a8eb7
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 11:28:33 2017 +0100

    Fix TAB-completion + .gdb_index slowness (generalize filename_seen_cache)
    
    Tab completion when debugging a program binary that uses GDB index is
    surprisingly much slower than when GDB uses psymtabs instead.  Around
    1.5x/3x slower.  That's surprising, because the whole point of GDB
    index is to speed things up...
    
    For example, with:
    
     set pagination off
     set $count = 0
     while $count < 400
       complete b string_prin         # matches gdb's string_printf
       printf "count = %d\n", $count
       set $count = $count + 1
     end
    
     $ time ./gdb --batch -q  ./gdb-with-index -ex "source script.cmd"
     real    0m11.042s
     user    0m10.920s
     sys     0m0.042s
    
     $ time ./gdb --batch -q  ./gdb-without-index -ex "source script.cmd"
     real    0m4.635s
     user    0m4.590s
     sys     0m0.037s
    
    Same but with:
     -   complete b string_prin
     +   complete b zzzzzz
    to exercise the no-matches worst case, master currently gets you
    something like:
    
     with index           without index
     real    0m11.971s    0m8.413s
     user    0m11.912s    0m8.355s
     sys     0m0.035s     0m0.035s
    
    Running gdb under perf shows 80% spent inside
    maybe_add_partial_symtab_filename, and 20% spent in the lbasename
    inside that.
    
    The problem that tab completion walks over all compunit symtabs, and
    for each, walks the contained file symtabs.  And there a huge number
    of file symtabs (each included system header, etc.) that appear in
    each compunit symtab's file symtab list.  As in, when debugging GDB, I
    have 367381 symtabs iterated, when of those only 5371 filenames are
    unique...
    
    This was a regression from the earlier (nice) split of symtabs in
    compunit symtabs + file symtabs.
    
    The fix here is to add a cache of unique filenames per objfile so that
    the walk / uniquing is only done once.  There's already a abstraction
    for this in symtab.c; this patch moves that code out to a separate
    file and C++ifies it bit.
    
    This makes the worst-case scenario above consistently drop to ~2.5s
    (1.5s for the "string_prin" hit case), making it over 3.3x times
    faster than psymtabs in this use case (7x in the "string_prin" hit
    case).
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
    	* dwarf2read.c: Include "filename-seen-cache.h".
    	* dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
    	(dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
    	* filename-seen-cache.c: New file.
    	* filename-seen-cache.h: New file.
    	* symtab.c: Include "filename-seen-cache.h".
    	(struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
    	(create_filename_seen_cache, clear_filename_seen_cache)
    	(delete_filename_seen_cache, filename_seen): Delete, parts moved
    	to filename-seen-cache.h/filename-seen-cache.c.
    	(output_source_filename, sources_info)
    	(maybe_add_partial_symtab_filename)
    	(make_source_files_completion_list): Adjust to use
    	filename_seen_cache.

commit 330cdd98910dbd34e969f60d48688fb81c2b374a
Author: Pedro Alves <palves@redhat.com>
Date:   Mon Jul 17 11:31:20 2017 +0100

    C++ify dwarf2_per_objfile
    
    This makes dwarf2_per_objfile a class with cdtors.
    
    A following patch will add a non-trivial field to struct
    dwarf2_per_objfile, making dwarf2_per_objfile itself non-trivial.
    Since dwarf2_per_objfile is allocated in an obstack, we need to run
    its cdtors manually.
    
    Tested on x86-64 GNU/Linux.
    
    gdb/ChangeLog:
    2017-07-17  Pedro Alves  <palves@redhat.com>
    
    	* dwarf2read.c (dwarf2_per_objfile): In-class initialize all
    	fields.
    	(dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
    	dwarf2_debug_sections*)): New.
    	(dwarf2_per_objfile::dwarf2_per_objfile(const
    	dwarf2_per_objfile&)): Declare as deleted.
    	(dwarf2_per_objfile::operator=): Declare as deleted.
    	(dwarf2_per_objfile::dwarf2_per_objfile)
    	(dwarf2_per_objfile::~dwarf2_per_objfile)
    	(dwarf2_per_objfile::free_cached_comp_units): New.
    	(dwarf2_has_info): dwarf2_per_objfile initialization code moved to
    	ctor.  Call dwarf2_per_objfile's ctor manually.
    	(dwarf2_locate_sections): Deleted/refactored as ...
    	(dwarf2_per_objfile::locate_sections): ... this new method.
    	(free_cached_comp_units): Defer to
    	dwarf2_per_objfile::free_cached_comp_units.
    	(dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.

commit 2a925816fc3848f1d48c4783df3dd54116907a57
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 17 10:51:45 2017 +0100

    Correct previous fix for an absence of input files on the ar command line, so that a complaint is not issued in MRI mode.
    
    	PR 21433
    	* ar.c (main): Skip check for no files on the command line when
    	running in MRI mode.

commit f27dadca0ad18d5a0ba032c3d3f6a60ea55d887b
Author: Georg-Johann Lay <avr@gjlay.de>
Date:   Mon Jul 17 10:23:10 2017 +0100

    Update assembler documentation on some AVR cores.
    
    	PR 21472
    	* config/tc-avr.c (mcu_types): Add entries for: attiny212,
    	attiny214, attiny412, attiny414, attiny814, attiny1614,
    	attiny1616, attiny1617, attiny3214, attiny3216, attiny3217.
    	(md_show_usage): Adjust doc for "avrxmega3".
    	* doc/c-avr.texi (AVR options) [-mmcu=]: Adjust doc for avrxmega3.
    	Add MCUs: attiny212, attiny214, attiny412, attiny414, attiny416,
    	attiny417, attiny814, attiny816, attiny817, attiny1614,
    	attiny1616, attiny1617, attiny3214, attiny3216, attiny3217.

commit caa74962b638d9d468e77dca3e410b061af9aa43
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jul 17 00:00:58 2017 +0000

    Automatic date update in version.in

commit 676ee2b5fa6ae41342a9fcd2b7ca18693fa0535b
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Jul 16 11:50:52 2017 +0930

    __tls_get_addr_opt GOT entries
    
    My 2017-01-24 patch (commit f0158f44) wrongly applied an optimization
    of GOT entries for the __tls_get_addr_opt stub, to shared libraries.
    
    When the TLS segment layout is known, as it is for the executable and
    shared libraries loaded at initial program start, powerpc supports a
    __tls_get_addr optimization.  On the first call to __tls_get_addr for
    a given __tls_index GOT entry, the DTPMOD word is set to zero and the
    DTPREL word to the thread pointer offset to the thread variable.  This
    allows the __tls_get_addr_opt stub to return that value immediately
    without making a call into glibc for any subsequent __tls_get_addr
    calls using that __tls_index GOT entry.
    
    That's all fine, but I thought I'd be clever and when the thread
    variable is local, set up the GOT entry as if __tls_get_addr had
    already been called.  Which is good only for the executable, since ld
    cannot know the TLS layout for shared libraries.
    
    Of course, if this only applies to executables there isn't much point
    to the optimization.  Normally, GD and LD code in an executable will
    be converted to IE or LE, losing the __tls_get_addr call.  So the only
    time it will trigger is with --no-tls-optimize.  Thus, revert all
    support.
    
    	* elf64-ppc.c (ppc64_elf_relocate_section): Don't optimize
    	__tls_index GOT entries when using __tls_get_addr_opt stub.
    	* elf32-ppc.c (ppc_elf_relocate_section): Likewise.

commit 046c08c44b786410bc743963578ce90b5c21e468
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jul 16 00:00:55 2017 +0000

    Automatic date update in version.in

commit 5bd68487223b73dd5f929878654f0e3e2c66c89c
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Wed Jun 14 19:52:32 2017 +0100

    gdb: Make some test names unique
    
    Make sure all of the tests have unique names in
    gdb.mi/mi-vla-fortran.exp.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.mi/mi-vla-fortran.exp: Make test names unique.

commit 71d01ca93b880d4fef93f52062c674ed62768e45
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jul 15 00:00:42 2017 +0000

    Automatic date update in version.in

commit 8880f2a9cb5151ce1c2714a75d123ba0f63668ac
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Jul 14 08:10:39 2017 -0600

    Handle sizeof(type) in Rust
    
    PR rust/21764 notes that "sizeof" does not work correctly for all types
    in Rust.  The bug turns out to be an error in the conversion of the AST
    to gdb expressions.  This patch fixes the bug and also avoids generating
    incorrect expressions in another case.
    
    Tested on the buildbot.  I'm checking this in.
    
    2017-07-14  Tom Tromey  <tom@tromey.com>
    
    	PR rust/21764:
    	* rust-exp.y (convert_ast_to_expression): Add "want_type"
    	parameter.
    	<UNOP_SIZEOF>: Split into separate case.
    	<UNOP_VAR_VALUE>: Handle want_type.  Add error case.
    
    2017-07-14  Tom Tromey  <tom@tromey.com>
    
    	PR rust/21764:
    	* gdb.rust/simple.exp: Add tests.

commit 65547233e04b32e087f74f8f5e9d3ffb6fe2c198
Author: Tom Tromey <tom@tromey.com>
Date:   Thu Jul 13 15:03:27 2017 -0600

    Make gdb.lookup_typename work for Rust types
    
    PR rust/21763 points out that gdb.lookup_typename does not work properly
    for (some) Rust types.  I tracked this down to a missing case in
    symbol_matches_domain.
    
    Tested by the buildbot.
    
    2017-07-14  Tom Tromey  <tom@tromey.com>
    
    	PR rust/21763:
    	* symtab.c (symbol_matches_domain): Add language_rust to special
    	case.
    	* rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
    	treat LOC_TYPEDEF symbols as variables.
    
    2017-07-14  Tom Tromey  <tom@tromey.com>
    
    	* gdb.rust/simple.exp: Add regression test for PR rust/21763.

commit 8f14146e1317b7b416ce298fad1a4f3d1ccbeb2b
Author: Pedro Alves <palves@redhat.com>
Date:   Fri Jul 14 16:50:35 2017 +0100

    Fix gdb.base/completion.exp with --target_board=dwarf4-gdb-index
    
    This is the same patch as posted at
    <https://sourceware.org/ml/gdb-patches/2017-02/msg00644.html>, with
    the test at
    <https://sourceware.org/ml/gdb-patches/2017-02/msg00687.html> squashed
    in.
    
    This patch fixes:
    
     -FAIL: gdb.base/completion.exp: tab complete break break.c:ma (timeout)
     -FAIL: gdb.base/completion.exp: complete break break.c:ma
     +PASS: gdb.base/completion.exp: tab complete break break.c:ma
     +PASS: gdb.base/completion.exp: delete breakpoint for tab complete break break.c:ma
     +PASS: gdb.base/completion.exp: complete break break.c:ma
    
    When run with --target_board=dwarf4-gdb-index.
    
    The issue here is that make_file_symbol_completion_list_1, used when
    completing a symbol restricted to a given source file, uses
    lookup_symtab to look up the symtab with the given name, and search
    for matching symbols inside.  This assumes that there's only one
    symtab for the given source file.  This is an incorrect assumption
    with (for example) -fdebug-types-section, where we'll have an extra
    extra symtab containing the types.  lookup_symtab finds that symtab,
    and inside that symtab there are no functions...
    
    gdb/ChangeLog:
    2017-07-14  Pedro Alves  <palves@redhat.com>
    
    	* symtab.c (make_file_symbol_completion_list_1): Iterate over
    	symtabs matching all symtabs with SRCFILE as file name instead of
    	only considering the first hit, with lookup_symtab.
    
    gdb/testsuite/ChangeLog:
    2017-07-14  Pedro Alves  <palves@redhat.com>
    
    	* gdb.linespec/base/one/thefile.cc (z1): New function.
    	* gdb.linespec/base/two/thefile.cc (z2): New function.
    	* gdb.linespec/linespec.exp: Add tests.

commit 0f6329bd7fcc8952aed5a386617d12529771415d
Author: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com>
Date:   Fri Jul 14 13:26:27 2017 +0530

    binutils/objdump: Fix disassemble for huge elf sections
    
    When elf section size is beyond unsigned int max value, objdump fails
    to disassemble from that section. Ex on PowerPC,
    
      $ objdump -h /proc/kcore
        Idx  Name   Size       VMA
          4  load2  100000000  c000000000000000
    
    Here, size of load2 section is 0x100000000. Also note that, 0xc00....
    address range is kernel space for PowerPC. Now let's try to disassemble
    do_sys_open() using /proc/kcore.
    
      $ cat /proc/kallsyms | grep -A1 -w do_sys_open
        c00000000036c000 T do_sys_open
        c00000000036c2d0 T SyS_open
    
    Before patch:
    
      $ objdump -d --start-address=0xc00000000036c000 --stop-address=0xc00000000036c2d0 /proc/kcore
        /proc/kcore:    file format elf64-powerpcle
    
        Disassembly of section load2:
    
        c00000000036c000 <load2+0x36c000>:
        c00000000036c000:    Address 0xc00000000036c000 is out of bounds.
    
    Fix this by changing type of 'buffer_length' from unsigned int to
    size_t. After patch:
    
      $ objdump -d --start-address=0xc00000000036c000 --stop-address=0xc00000000036c2d0 /proc/kcore
        /proc/kcore:    file format elf64-powerpcle
    
        Disassembly of section load2:
    
        c00000000036c000 <load2+0x36c000>:
        c00000000036c000: fc 00 4c 3c     addis   r2,r12,252
        c00000000036c004: 00 53 42 38     addi    r2,r2,21248
        c00000000036c008: a6 02 08 7c     mflr    r0
    
    include/
    	* dis-asm.h (struct disassemble_info): Change type of buffer_length
    	field to size_t.
    opcodes/
    	* dis-buf.c (buffer_read_memory): Change type of end_addr_offset,
    	max_addr_offset and octets variables to size_t.

commit 86038de0d810f8639d22573921d2589a99829b36
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 14 18:37:26 2017 +0930

    ppc32 tlsopt tests
    
    These all were odd in that they used r13 as the GOT pointer.  That
    didn't matter for the purpose of testing, but would never occur in
    practice.  Also, the tlsopt5 tests could have their global dynamic
    sequences optimized to initial exec, so link with -shared.
    
    	* testsuite/ld-powerpc/powerpc.exp: Add -shared to tlsop5 tests.
    	* testsuite/ld-powerpc/tlsopt5.d: Adjust.
    	* testsuite/ld-powerpc/tlsopt1_32.s: Use r30 as GOT pointer.
    	* testsuite/ld-powerpc/tlsopt2_32.s: Likewise.
    	* testsuite/ld-powerpc/tlsopt3_32.s: Likewise.
    	* testsuite/ld-powerpc/tlsopt4_32.s: Likewise.
    	* testsuite/ld-powerpc/tlsopt5_32.s: Rewrite.
    	* testsuite/ld-powerpc/tlsopt1_32.d: Adjust.
    	* testsuite/ld-powerpc/tlsopt2_32.d: Adjust.
    	* testsuite/ld-powerpc/tlsopt3_32.d: Adjust.
    	* testsuite/ld-powerpc/tlsopt5_32.d: Adjust.

commit 211b0bed95b3f6b177a541ec52302b8febd6b49c
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Fri Jul 14 11:53:08 2017 +0100

    PR ld/21529: Use a linker script to limit output with the test case
    
    Complement commit d9409498813c ("Add a testcase for PR ld/21529") and
    use a linker script to prevent an inter-segment gap arranged by the
    default linker script associated with some targets such as `rx-elf':
    
    $ ld -e main -o tmpdir/dump-elf tmpdir/pr21529.o
    $ readelf -l tmpdir/dump-elf
    Elf file type is EXEC (Executable file)
    Entry point 0x10000004
    There are 2 program headers, starting at offset 52
    
    Program Headers:
      Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
      LOAD           0x001000 0x10000000 0x10000000 0x00008 0x00008 R E 0x1000
      LOAD           0x001ffc 0xbffffffc 0xbffffffc 0x00004 0x00004 RW  0x1000
    
     Section to Segment mapping:
      Segment Sections...
       00     .text
       01     .stack
    $
    
    and converted to padding with the use of the binary BFD for output from
    producing unreasonably large files.
    
    	ld/
    	* testsuite/ld-unique/pr21529.ld: New test linker script.
    	* testsuite/ld-unique/pr21529.d: Use it.

commit 2347965cd99810f5ff6f638880e4eb498a8ffa82
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Jul 14 12:47:40 2017 +0200

    ax-gdb: Remove more unused arguments
    
    gdb/ChangeLog:
    
    	* ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
    	operator_name parameters.
    	(gen_expr): Update function call.

commit 40f4af2873b0631bc5f1d4ded2070abe2de2217c
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Jul 14 12:47:40 2017 +0200

    ax-gdb: Remove unnecessary gdbarch parameters
    
    In multiple places, we pass the gdbarch as an argument to some
    functions, even though it's available in the agent_expr structure also
    passed to the same functions.  Remove these arguments and replace their
    usage with accesses to agent_expr::gdbarch.
    
    gdb/ChangeLog:
    
    	* dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
    	parameter.
    	* symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
    	Likewise.
    	* dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
    	parameter, use agent_expr::gdbarch instead, update function
    	calls.
    	(locexpr_tracepoint_var_ref): Likewise.
    	(loclist_tracepoint_var_ref): Likewise.
    	* ax-gdb.c (gen_trace_static_fields): Likewise.
    	(gen_traced_pop): Likewise.
    	(gen_frame_args_address): Likewise.
    	(gen_frame_locals_address): Likewise.
    	(gen_var_ref): Likewise.
    	(gen_struct_ref_recursive): Likewise.
    	(gen_static_field): Likewise.
    	(gen_maybe_namespace_elt): Likewise.
    	(gen_expr): Likewise.
    	(gen_trace_for_var): Likewise.
    	(gen_trace_for_expr): Likewise.
    	(gen_trace_for_return_address): Likewise.

commit 053f805718fb3a77169afebba83cc665e9509e7b
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Jul 14 12:47:39 2017 +0200

    ax-gdb: Remove two unused agent_expr *ax parameters
    
    gdb/ChangeLog:
    
    	* ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
    	parameter.
    	(gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.

commit 6661ad487334212e043ab584030f533da358ecf2
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri Jul 14 12:47:39 2017 +0200

    ax-gdb: Use ax->gdbarch instead of exp->gdbarch, remove unused parameters
    
    In many ax generation functions, the "expression *exp" parameter is only
    used to access the gdbarch.  The same value can be found in the
    "agent_expr *ax" parameter, which needs to be passed in any case.  By
    using ax->gdbarch instead of exp->gdbarch, we can avoid passing exp in
    many of these functions.
    
    gdb/ChangeLog:
    
    	* ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
    	from ax, update calls.
    	(gen_usual_arithmetic): Likewise.
    	(gen_integral_promotions): Likewise.
    	(gen_bitfield_ref): Likewise.
    	(gen_primitive_field): Likewise.
    	(gen_struct_ref_recursive): Likewise.
    	(gen_struct_ref): Likewise.
    	(gen_maybe_namespace_elt): Likewise.
    	(gen_struct_elt_for_reference): Likewise.
    	(gen_namespace_elt): Likewise.
    	(gen_aggregate_elt_ref): Likewise.
    	(gen_expr): Get gdbarch from ax, update calls.
    	(gen_expr_binop_rest): Likewise.

commit ee77ed019f9993ed50613a687bd2a19241c98aeb
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jul 14 00:00:47 2017 +0000

    Automatic date update in version.in

commit e58ff055fa744a16d8e854d2fda9cebce164b600
Author: Jim Wilson <jim.wilson@linaro.org>
Date:   Thu Jul 13 14:40:22 2017 -0700

    Add RDMA support for falkot/qdf24xx.
    
    	gas/
    	* config/tc-arch64.c (aarch64_cpus): Add AARCH64_FEATURE_RDMA to
    	falkor and qdf24xx entries.

commit b4365d025e0b5c025658c7ffc4108502d56030f9
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Thu Jul 13 20:55:11 2017 +0100

    gdb: Fix more parameter passing to mi_create_breakpoint
    
    In the test gdb.mi/mi-vla-fortran.exp the parameters passed to
    mi_create_breakpoint are passed in the wrong order.  By good luck the
    tests still passes, however the wrong test name is used.  All fixed in
    this commit.
    
    A previous commit fixed most of these, but I missed this last one.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.mi/mi-vla-fortran.exp: Correct even more parameter passing
    	to mi_create_breakpoint.

commit c55a47e7237ebac17df73183d214d90400a49455
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 13 20:56:42 2017 +0100

    Fix x86-64 GNU/Linux crashes
    
    Ref: https://sourceware.org/ml/gdb-patches/2017-07/msg00162.html
    
    Debugging x86-64 GNU/Linux programs currently crashes GDB in
    tdesc_use_registers during gdbarch initialization:
    
      Program received signal SIGSEGV, Segmentation fault.
      0x0000000001093eaf in htab_remove_elt_with_hash (htab=0x2ef9fa0, element=0x26af960, hash=557151073) at src/libiberty/hashtab.c:728
      728       if (*slot == HTAB_EMPTY_ENTRY)
      (top-gdb) p slot
      $1 = (void **) 0x0
      (top-gdb) bt
      #0  0x0000000001093eaf in htab_remove_elt_with_hash (htab=0x2ef9fa0, element=0x26af960, hash=557151073) at src/libiberty/hashtab.c:728
      #1  0x0000000001093e79 in htab_remove_elt (htab=0x2ef9fa0, element=0x26af960) at src/libiberty/hashtab.c:714
      #2  0x00000000009121b0 in tdesc_use_registers (gdbarch=0x3001240, target_desc=0x2659cb0, early_data=0x2881cb0)
          at src/gdb/target-descriptions.c:1328
      #3  0x000000000047c93e in i386_gdbarch_init (info=..., arches=0x0) at src/gdb/i386-tdep.c:8634
      #4  0x0000000000818d5f in gdbarch_find_by_info (info=...) at src/gdb/gdbarch.c:5394
      #5  0x00000000007198a8 in set_gdbarch_from_file (abfd=0x2f48250) at src/gdb/arch-utils.c:618
      #6  0x00000000007f21cb in exec_file_attach (filename=0x7fffffffddb0 "/home/pedro/gdb/tests/threads", from_tty=1) at src/gdb/exec.c:380
      #7  0x0000000000865c18 in catch_command_errors_const (command=0x7f1d83 <exec_file_attach(char const*, int)>, arg=0x7fffffffddb0 "/home/pedro/gdb/tests/threads",
          from_tty=1) at src/gdb/main.c:403
      #8  0x00000000008669cf in captured_main_1 (context=0x7fffffffd860) at src/gdb/main.c:1035
      #9  0x0000000000866de2 in captured_main (data=0x7fffffffd860) at src/gdb/main.c:1142
      #10 0x0000000000866e24 in gdb_main (args=0x7fffffffd860) at src/gdb/main.c:1160
      #11 0x000000000041312d in main (argc=3, argv=0x7fffffffd968) at src/gdb/gdb.c:32
    
    The direct cause of the crash is that we tried to remove an element
    from the hash which supposedly exists, but does not.  (htab_remove_elt
    shouldn't really crash in this case, but that's secondary.)
    
    The real problem is that early_data passed to tdesc_use_registers
    includes regs from a target description that is not the target_desc,
    which violates its assumptions.  The registers in question are the
    fs_base/gs_base registers, added by amd64_init_abi:
    
          tdesc_numbered_register (feature, tdesc_data_segments,
    		       AMD64_FSBASE_REGNUM, "fs_base");
          tdesc_numbered_register (feature, tdesc_data_segments,
    		       AMD64_GSBASE_REGNUM, "gs_base");
    
    and that happens because amd64_linux_init_abi uses amd64_init_abi as
    helper, but they don't coordinate on which fallback tdesc to use.
    
    amd64_init_abi does:
    
      if (! tdesc_has_registers (tdesc))
        tdesc = tdesc_amd64;
    
    and then adds the fs_base/gs_base registers of the "tdesc_amd64" tdesc
    to the tdesc_arch_data.
    
    After amd64_init_abi returns, amd64_linux_init_abi does:
    
      if (! tdesc_has_registers (tdesc))
        tdesc = tdesc_amd64_linux;
      tdep->tdesc = tdesc;
    
    and we end up tdesc_amd64_linux installed in tdep->tdesc.
    
    The fix is to make sure that amd64_linux_init_abi and amd64_init_abi
    agree on default tdesc, by adding a "default tdesc" parameter to
    amd64_init_abi, instead of having amd64_init_abi hardcode a default.
    With this, amd64_init_abi creates the fs_base/gs_base registers using
    the tdesc_amd64_linux tdesc.
    
    Tested on x86-64 GNU/Linux, -m64.  I don't have an x32 setup handy.
    
    Thanks to John Baldwin, Yao Qi and Simon Marchi for the investigation.
    
    gdb/ChangeLog:
    2017-07-13  Pedro Alves  <palves@redhat.com>
    
    	* amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
    	as default tdesc.
    	* amd64-dicos-tdep.c (amd64_dicos_init_abi):
    	* amd64-fbsd-tdep.c (amd64fbsd_init_abi):
    	* amd64-linux-tdep.c (amd64_linux_init_abi): Pass
    	tdesc_amd64_linux as default tdesc.  Get final tdesc from the
    	tdep.
    	(amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
    	Get final tdesc from the tdep.
    	* amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
    	default tdesc.
    	* amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
    	* amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
    	* amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
    	Use it as default tdesc.
    	(amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
    	down to amd_init_abi.  No longer handle fallback tdesc here.
    	* amd64-tdep.h (tdesc_x32): Declare.
    	(amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
    	parameter.
    	* amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
    	as default tdesc.

commit 5d2cbaa526279a02cb1b70e29246099f0b8287d0
Author: Andrew Burgess <andrew.burgess@embecosm.com>
Date:   Wed Jun 14 19:47:52 2017 +0100

    gdb: Fix parameter passing to mi_create_breakpoint
    
    In the test gdb.mi/mi-vla-fortran.exp the parameters passed to
    mi_create_breakpoint are passed in the wrong order.  By good luck the
    tests still passes, however the wrong test name is used.  All fixed in
    this commit.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.mi/mi-vla-fortran.exp: Correct parameter passing to
    	mi_create_breakpoint.

commit 55efceabc6149e96134c10676adb2b1e79e0ae13
Author: Andreas Arnez <arnez@linux.vnet.ibm.com>
Date:   Thu Jul 13 20:17:03 2017 +0200

    S390: Add record/replay support for arch12 instructions
    
    Support record/replay of the z/Architecture instructions that were
    introduced with arch12.
    
    gdb/ChangeLog:
    
    	* s390-linux-tdep.c (s390_process_record): Add support for
    	instructions new in arch12.

commit a502b0bbb8f3fb7dca4f2a12aa04afa28173f0c2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jul 13 08:10:57 2017 -0700

    Always delete $testarchive first
    
    Always delete $testarchive first so that it exists only when it is
    supported,
    
    	* testsuite/binutils-all/objdump.exp: Always delete $testarchive
    	first.

commit 400e54229ef511fa1522c331863d63b5b4b80f9e
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jul 13 07:41:54 2017 -0700

    Update lto and none-lto input support for ld -r

commit bbe7ef6699236cf94d0f4e597bdce99158905edc
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jul 13 00:00:50 2017 +0000

    Automatic date update in version.in

commit b7d7d4598c7c7fff209a1055cbbd829a0a68d7e4
Author: Cary Coutant <ccoutant@gmail.com>
Date:   Wed Jul 12 07:24:37 2017 -0700

    Add missing gold/ChangeLog entry.

commit 429d795d5074db648fe07dfd811c1c150b78066e
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Jul 12 22:19:58 2017 +0930

    Update PO files
    
    bfd/
    	* po/es.po: Update from translationproject.org/latest/bfd/.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/ja.po: Likewise.
    	* po/ro.po: Likewise.
    	* po/ru.po: Likewise.
    	* po/sr.po: Likewise.
    	* po/sv.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/vi.po: Likewise.
    	* po/zh_CN.po: Likewise.
    	* po/hr.po: New file from translationproject.org.
    	* configure.ac (ALL_LINGUAS): Add hr.  Sort.
    	* configure: Regenerate.
    
    binutils/
    	* po/bg.po: Update from translationproject.org/latest/binutils/.
    	* po/ca.po: Likewise.
    	* po/da.po: Likewise.
    	* po/es.po: Likewise.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/hr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/it.po: Likewise.
    	* po/ja.po: Likewise.
    	* po/ro.po: Likewise.
    	* po/ru.po: Likewise.
    	* po/sk.po: Likewise.
    	* po/sr.po: Likewise.
    	* po/sv.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/vi.po: Likewise.
    	* po/zh_CN.po: Likewise.
    	* po/zh_TW.po: Likewise.
    
    gas/
    	* po/es.po: Update from translationproject.org/latest/gas/.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/ja.po: Likewise.
    	* po/ru.po: Likewise.
    	* po/sv.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/zh_CN.po: Likewise.
    
    gold/
    	* po/es.po: Update from translationproject.org/latest/gold/.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/it.po: Likewise.
    	* po/vi.po: Likewise.
    	* po/zh_CN.po: Likewise.
    	* po/ja.po: New file from translationproject.org.
    	* po/sv.po: Likewise.
    	* po/uk.po: Likewise.
    
    gprof/
    	* po/bg.po: Update from translationproject.org/latest/gprof/.
    	* po/da.po: Likewise.
    	* po/de.po: Likewise.
    	* po/eo.po: Likewise.
    	* po/es.po: Likewise.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/ga.po: Likewise.
    	* po/hu.po: Likewise.
    	* po/id.po: Likewise.
    	* po/it.po: Likewise.
    	* po/ja.po: Likewise.
    	* po/ms.po: Likewise.
    	* po/nl.po: Likewise.
    	* po/pt_BR.po: Likewise.
    	* po/ro.po: Likewise.
    	* po/ru.po: Likewise.
    	* po/sr.po: Likewise.
    	* po/sv.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/vi.po: Likewise.
    
    ld/
    	* po/bg.po: Update from translationproject.org/latest/ld/.
    	* po/da.po: Likewise.
    	* po/es.po: Likewise.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/it.po: Likewise.
    	* po/ja.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/vi.po: Likewise.
    	* po/zh_CN.po: Likewise.
    	* po/zh_TW.po: Likewise.
    	* po/de.po: New file from translationproject.org.
    	* po/ru.po: Likewise.
    	* configure.ac (ALL_LINGUAS): Add de, ru.  Sort.
    	* configure: Regenerate.
    
    opcodes/
    	* po/da.po: Update from translationproject.org/latest/opcodes/.
    	* po/de.po: Likewise.
    	* po/es.po: Likewise.
    	* po/fi.po: Likewise.
    	* po/fr.po: Likewise.
    	* po/id.po: Likewise.
    	* po/it.po: Likewise.
    	* po/nl.po: Likewise.
    	* po/pt_BR.po: Likewise.
    	* po/ro.po: Likewise.
    	* po/sv.po: Likewise.
    	* po/tr.po: Likewise.
    	* po/uk.po: Likewise.
    	* po/vi.po: Likewise.
    	* po/zh_CN.po: Likewise.

commit 0bae9e9ec550c940e263b37f577bf11b2dabf934
Author: Nick Clifton <nickc@redhat.com>
Date:   Wed Jul 12 12:17:02 2017 +0100

    Fix compile time warnings building the binutils with gcc 7.1.1.
    
    bfd	* elf32-xtensa.c (elf_xtensa_get_plt_section): Increase length of
    	plt_name buffer.
    	(elf_xtensa_get_gotplt_section): Increase length of got_name
    	buffer.
    	* mach-o-arm.c (bfd_mach_o_arm_canonicalize_one_reloc): Add a
    	default return of FALSE.
    	* mach-o-i386.c (bfd_mach_o_i386_canonicalize_one_reloc): Add a
    	default return of FALSE.
    
    binutils * dwarf.c (dwarf_vmatoa_1): Do not pass a NULL string pointer to
    	sprintf.
    	* srconv.c (walk_tree_type): Initialise the spare field of the
    	IT_dty structure.
    
    gas	* config/tc-pru.c (md_assemble): Add continue statement after
    	handling 'E' operand character.
    	* config/tc-v850.c (md_assemble): Initialise the 'insn' variable.

commit 2fe40b6792e98dfe27e4521b2b33fe0f335ea1f0
Author: Alan Modra <amodra@gmail.com>
Date:   Wed Jul 12 19:22:30 2017 +0930

    rs6000 testsuite update
    
    	* testsuite/ld-scripts/align.exp: Exclude powerpc*-*-aix*.
    	* testsuite/ld-scripts/assign-loc.d: Likewise.
    	* testsuite/ld-scripts/defined3.d: Likewise.
    	* testsuite/ld-scripts/defined4.d: Likewise.
    	* testsuite/ld-scripts/defined5.d: Likewise.
    	* testsuite/ld-scripts/expr2.d: Likewise.
    	* testsuite/ld-scripts/provide.exp: Likewise.
    	* testsuite/ld-scripts/sane1.d: Likewise.
    	* testsuite/ld-scripts/size.exp: Likewise.
    	* testsuite/ld-scripts/defined2.d: Don't xfail rs6000-*-aix*.

commit d42c267e9b129279994dc623c0bdd698a2b67286
Author: Alan Modra <amodra@gmail.com>
Date:   Sun Jul 9 23:11:32 2017 +0930

    bfd_error_handler bfd_vma and bfd_size_type args
    
    This patch uses the new %L _bfd_error_handler support for printing
    bfd_vma arguments, and fixes a many other format and/or argument
    errors in error messages.
    
    bfd/
    	* binary.c (binary_set_section_contents): Don't print filepos in
    	error message.
    	(coff_write_object_contents): Cast size_t for error message.
    	(coff_slurp_line_table): Don't use bfd_vma symndx.
    	(coff_slurp_reloc_table): Remove unneeded cast.
    	* dwarf2.c (read_section): Cast bfd_int64_t to long long for
    	error message.
    	(find_abstract_instance_name): Likewise.
    	* elf32-arm.c (arm_type_of_stub): Correct error arg order.
    	(bfd_elf32_arm_stm32l4xx_erratum_scan): Don't cast error arg.
    	(elf32_arm_check_relocs): Make r_symndx an int.
    	* elf32-cris.c (cris_elf_check_relocs): Delete extraneous %s in
    	format string.
    	* elf32-metag.c (elf_metag_relocate_section): Delete extra error
    	message arg.
    	* elf32-nds32.c (nds32_elf_ex9_build_hash_table): Rewrite bogus
    	error message.
    	* elf32-i386.c (elf_i386_check_relocs): Make r_symndx an int.
    	* elf32-s390.c (elf_s390_check_relocs): Likewise.
    	* elf32-tic6x.c (elf32_tic6x_check_relocs): Likewise.
    	* elf32-tilepro.c (tilepro_elf_check_relocs): Likewise.
    	* elf32-xtensa.c (elf_xtensa_check_relocs): Likewise.
    	* elf64-s390.c (elf_s390_check_relocs): Likewise.
    	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_check_relocs): Likewise.
    	* elfnn-riscv.c (riscv_elf_check_relocs): Likewise.
    	* elfxx-sparc.c (_bfd_sparc_elf_check_relocs): Likewise.
    	* elfxx-tilegx.c (tilegx_elf_check_relocs): Likewise.
    	* elf64-mmix.c (_bfd_mmix_after_linker_allocation): Cast size_t args
    	and use %lu for error message.
    	* elflink.c (elf_link_adjust_relocs): Delete extra error message arg.
    	* mmo.c (mmo_scan): Make stab_loc a file_ptr.  Cast expression for
    	error message.
    
    	* elf32-arm.c (elf32_arm_tls_relax): Correct format string and args
    	in error message.
    	(elf32_arm_final_link_relocate): Likewise.
    	* coff-arm.c (bfd_arm_process_before_allocation): Likewise.
    	* coffcode.h (styp_to_sec_flags): Likewise.
    	* cofflink.c (_bfd_coff_write_global_sym): Likewise.
    	* ecoff.c (_bfd_ecoff_slurp_symbol_table): Likewise.
    	* elf32-arc.c (arc_elf_merge_private_bfd_data): Likewise.
    	* elf32-bfin.c (bfinfdpic_check_relocs): Likewise.
    	(elf32_bfin_merge_private_bfd_data): Likewise.
    	* elf32-cris.c (cris_elf_relocate_section): Likewise.
    	* elf32-frv.c (frv_elf_merge_private_bfd_data): Likewise.
    	* elf32-i370.c (i370_elf_merge_private_bfd_data): Likewise.
    	(i370_elf_relocate_section): Likewise.
    	* elf32-iq2000.c (iq2000_elf_merge_private_bfd_data): Likewise.
    	* elf32-m32c.c (m32c_elf_merge_private_bfd_data): Likewise.
    	* elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Likewise.
    	* elf32-mcore.c (mcore_elf_relocate_section): Likewise.
    	* elf32-mep.c (mep_elf_merge_private_bfd_data): Likewise.
    	* elf32-mt.c (mt_elf_merge_private_bfd_data): Likewise.
    	* elf64-sparc.c (elf64_sparc_merge_private_bfd_data): Likewise.
    	* elfxx-mips.c (mips_elf_merge_obj_e_flags): Likewise.
    	(_bfd_mips_elf_merge_private_bfd_data): Likewise.
    	* ieee.c (ieee_write_id, read_id): Likewise.
    	* mach-o.c (bfd_mach_o_write_contents): Likewise.
    	(bfd_mach_o_layout_commands, bfd_mach_o_read_section_32): Likewise.
    	(bfd_mach_o_read_section_64, bfd_mach_o_read_symtab_symbol): Likewise.
    	(bfd_mach_o_read_command, bfd_mach_o_header_p): Likewise.
    	* peXXigen.c (_bfd_XXi_swap_aouthdr_in): Likewise.
    	* stabs.c (_bfd_link_section_stabs): Likewise.
    
    	* coff-arm.c (coff_arm_relocate_section): Use L modifier in error
    	format.
    	* coff-mcore.c (coff_mcore_relocate_section): Likewise.
    	* coff-ppc.c (coff_ppc_relocate_section): Likewise.
    	* coff-rs6000.c (xcoff_reloc_type_toc): Likewise.
    	* coff-sh.c (sh_relax_section): Likewise.
    	(sh_relax_delete_bytes, sh_swap_insns): Likewise.
    	* coff-tic80.c (coff_tic80_relocate_section): Likewise.
    	* coffcode.h (coff_slurp_reloc_table): Likewise.
    	* coffgen.c (_bfd_coff_get_external_symbols): Likewise.
    	(_bfd_coff_read_string_table): Likewise.
    	* cofflink.c (_bfd_coff_generic_relocate_section): Likewise.
    	* compress.c (bfd_get_full_section_contents): Likewise.
    	* dwarf2.c (read_formatted_entries, decode_line_info): Likewise.
    	* elf-m10300.c (mn10300_elf_relocate_section): Likewise.
    	* elf.c (bfd_elf_string_from_elf_section): Likewise.
    	* elf32-arc.c (arc_special_overflow_checks): Likewise.
    	* elf32-arm.c (elf32_arm_tls_relax): Likewise.
    	(elf32_arm_final_link_relocate, elf32_arm_relocate_section): Likewise.
    	(elf32_arm_write_section): Likewise.
    	* elf32-bfin.c (bfin_relocate_section): Likewise.
    	(bfinfdpic_relocate_section): Likewise.
    	* elf32-hppa.c (hppa_build_one_stub): Likewise.
    	(final_link_relocate, elf32_hppa_relocate_section): Likewise.
    	* elf32-i386.c (elf_i386_tls_transition): Likewise.
    	(elf_i386_relocate_section): Likewise.
    	* elf32-ip2k.c (ip2k_final_link_relocate): Likewise.
    	* elf32-lm32.c (lm32_elf_finish_dynamic_sections): Likewise.
    	* elf32-m32r.c (m32r_elf_relocate_section): Likewise.
    	* elf32-m68k.c (elf_m68k_relocate_section): Likewise.
    	* elf32-metag.c (elf_metag_relocate_section): Likewise.
    	* elf32-nds32.c (unrecognized_reloc_msg): Likewise.
    	(nds32_elf_relax_longcall1, nds32_elf_relax_longcall2): Likewise.
    	(nds32_elf_relax_longcall3, nds32_elf_relax_longjump1): Likewise.
    	(nds32_elf_relax_longjump2, nds32_elf_relax_longjump3): Likewise.
    	(nds32_elf_relax_longcall4, nds32_elf_relax_longcall5): Likewise.
    	(nds32_elf_relax_longcall6, nds32_elf_relax_longjump4): Likewise.
    	(nds32_elf_relax_longjump5, nds32_elf_relax_longjump6): Likewise.
    	(nds32_elf_relax_longjump7, nds32_elf_relax_loadstore): Likewise.
    	(nds32_elf_relax_ptr, nds32_elf_ex9_build_hash_table): Likewise.
    	* elf32-nios2.c (nios2_elf32_relocate_section): Likewise.
    	* elf32-rx.c (UNSAFE_FOR_PID): Likewise.
    	* elf32-s390.c (invalid_tls_insn, elf_s390_relocate_section): Likewise.
    	* elf32-score.c (s3_bfd_score_elf_check_relocs): Likewise.
    	* elf32-score7.c (s7_bfd_score_elf_check_relocs): Likewise.
    	* elf32-sh.c (sh_elf_relax_section): Likewise.
    	(sh_elf_relax_delete_bytes, sh_elf_swap_insns): Likewise.
    	(sh_elf_relocate_section): Likewise.
    	* elf32-sh64.c (shmedia_prepare_reloc): Likewise.
    	* elf32-spu.c (spu_elf_relocate_section): Likewise.
    	* elf32-tic6x.c (elf32_tic6x_relocate_section): Likewise.
    	* elf32-tilepro.c (tilepro_elf_relocate_section): Likewise.
    	* elf32-v850.c (v850_elf_relax_section): Likewise.
    	* elf32-vax.c (elf_vax_check_relocs): Likewise.
    	(elf_vax_relocate_section): Likewise.
    	* elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
    	(extend_ebb_bounds_forward, extend_ebb_bounds_backward): Likewise.
    	(compute_text_actions, compute_ebb_proposed_actions): Likewise.
    	(do_fix_for_relocatable_link): Likewise.
    	* elf64-alpha.c (elf64_alpha_relax_got_load): Likewise.
    	(elf64_alpha_relax_with_lituse): Likewise.
    	* elf64-hppa.c (elf64_hppa_finish_dynamic_symbol): Likewise.
    	(elf_hppa_final_link_relocate): Likewise.
    	* elf64-ia64-vms.c (elf64_ia64_relax_section): Likewise.
    	(elf64_ia64_choose_gp, elf64_ia64_relocate_section): Likewise.
    	(elf64_vms_link_add_object_symbols): Likewise.
    	* elf64-mmix.c (mmix_elf_perform_relocation): Likewise.
    	(mmix_final_link_relocate): Likewise.
    	* elf64-s390.c (invalid_tls_insn): Likewise.
    	(elf_s390_relocate_section): Likewise.
    	* elf64-sh64.c (sh_elf64_relocate_section): Likewise.
    	* elf64-x86-64.c (elf_x86_64_tls_transition): Likewise.
    	(elf_x86_64_relocate_section): Likewise.
    	* elfcode.h (elf_slurp_symbol_table): Likewise.
    	* elfcore.h (elf_core_file_p): Likewise.
    	* elflink.c (elf_link_read_relocs_from_section): Likewise.
    	* elfnn-aarch64.c (elfNN_aarch64_final_link_relocate): Likewise.
    	(elfNN_aarch64_relocate_section): Likewise.
    	* elfnn-ia64.c (elfNN_ia64_relax_section): Likewise.
    	(elfNN_ia64_choose_gp, elfNN_ia64_relocate_section): Likewise.
    	* elfnn-riscv.c (riscv_elf_relocate_section): Likewise.
    	* elfxx-mips.c (_bfd_mips_elf_check_relocs): Likewise.
    	(_bfd_mips_elf_relocate_section): Likewise.
    	(_bfd_mips_elf_finish_dynamic_symbol, mips_finish_exec_plt): Likewise.
    	* elfxx-sparc.c (_bfd_sparc_elf_relocate_section): Likewise.
    	* elfxx-tilegx.c (tilegx_elf_relocate_section): Likewise.
    	* ieee.c (ieee_slurp_external_symbols): Likewise.
    	* ihex.c (ihex_write_object_content): Likewise.
    	* mach-o.c (bfd_mach_o_build_exec_seg_command): Likewise.
    	* merge.c (_bfd_merged_section_offset): Likewise.
    	* mmo.c (mmo_write_loc_chunk): Likewise.
    	(mmo_write_object_contents): Likewise.
    	* peXXigen.c (_bfd_XX_bfd_copy_private_bfd_data_common): Likewise.
    	* stabs.c (_bfd_link_section_stabs): Likewise.
    	* xcofflink.c (xcoff_link_add_symbols, xcoff_find_tc0): Likewise.
    ld/
    	* testsuite/ld-arc/nps-1b.err: Update.
    	* testsuite/ld-x86-64/ilp32-11.d: Update.

commit bd6a8c1905edff5e8fbfc94272240574ac9af231
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jul 12 00:00:47 2017 +0000

    Automatic date update in version.in

commit df2f63a6a0fc19c54e58aab8afe262baf3cb1a3c
Author: Han Shen <shenhan@google.com>
Date:   Mon Jul 10 15:23:05 2017 -0700

    Fixing for PR gold/21491 - Errata workaround can produce broken images.
    
    The problem is caused by the fact that gold is relocating the stubs
    for an entire output section when it processes the relocations for a
    particular input section that happened to be designated as the stub
    table "owner". The Relocate_task for that input section may or may not
    run before the Relocate_task for another input section that contains
    the code that needs the erratum fix, but doesn't "own" the stub
    table. If it runs before (or might even race with) that other task, it
    ends up with a copy of the unrelocated original instruction.
    
    In other words - when calling fix_errata() from
    do_relocate_sections(), gold is going through the list of errata stubs
    that are associated only with that object. This routine updates the
    stored original instruction and replaces it in the output view with a
    branch to the stub. Later, as gold is going through the object file's
    input sections, it then checks for stub tables "owned" by each input
    section, and writes out all the stubs from that stub table, regardless
    of what object file each stub is associated with.
    
    Fixed by relocating the erratum stub only after the corresponding
    errata spot is fixed. That is to have fix_errata() call
    Stub_table::relocate_erratum_stub() for each stub.
    
    gold/ChangeLog
    2017-07-06  Han Shen  <shenhan@google.com>
    
    	PR gold/21491
    
    	* aarch64.cc (Erratum_stub::invalidate_erratum_stub): New method.
    	(Erratum_stub::is_invalidated_erratum_stub): New method.
    	(Stub_table::relocate_reloc_stub): Renamed from "relocate_stub".
    	(Stub_table::relocate_reloc_stubs): Renamed from "relocate_stubs".
    	(Stub_table::relocate_erratum_stub): New method.
    	(AArch64_relobj::fix_errata_and_relocate_erratum_stubs): Renamed from
    	"fix_errata".
    	(Target_aarch64::relocate_reloc_stub): Renamed from "relocate_stub".

commit 0aa37b654c0f31e446ab47826f0bcbec15d0112f
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Jun 26 18:18:19 2017 -0700

    Support the fs_base and gs_base registers on FreeBSD/amd64 native processes.
    
    Use ptrace operations to fetch and store the fs_base and gs_base registers
    for FreeBSD/amd64 processes.  Note that FreeBSD does not currently store the
    value of these registers in core dumps, so these registers are only
    available when inspecting a running process.
    
    gdb/ChangeLog:
    
    	* amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
    	PT_GETFSBASE and PT_GETGSBASE.
    	(amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
    	PT_SETGSBASE.

commit 48aeef91c248291dd03583798904612426b1f40a
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Mon Jun 26 18:14:43 2017 -0700

    Include the fs_base and gs_base registers in amd64 target descriptions.
    
    This permits these registers to be used with non-Linux targets.
    
    gdb/ChangeLog:
    
    	* features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
    	(amd64-avx-mpx.dat, amd64-avx-avx512.dat)
    	(amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
    	those rules.
    	* features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
            * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
    	* features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
    	* features/i386/amd64-avx.xml: Add 64bit-segments.xml.
    	* features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
    	* features/i386/amd64.xml: Add 64bit-segments.xml.
    	* features/i386/amd64-avx-avx512.c: Regenerated.
    	* features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
    	* features/i386/amd64-avx-mpx.c: Regenerated.
    	* features/i386/amd64-avx.c: Regenerated.
    	* features/i386/amd64-mpx.c: Regenerated.
    	* features/i386/amd64.c: Regenerated.
    	* regformats/i386/amd64-avx-avx512.dat: Regenerated.
    	* regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
    	* regformats/i386/amd64-avx-mpx.dat: Regenerated.
    	* regformats/i386/amd64-avx.dat: Regenerated.
    	* regformats/i386/amd64-mpx.dat: Regenerated.
    	* regformats/i386/amd64.dat: Regenerated.

commit b384299be24752d4d01017e239dc87def9cf07f7
Merge: 54e2cdd 61a0857
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Jul 11 08:44:47 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 61a0857c0fb512ce6a2ba4315a37fcce744f6045
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Jul 11 08:37:48 2017 -0700

    Support single digit GCC version
    
    On Fedora 26, "g++ -dumpversion" displays "7", instead of "7.1.1".
    Update selective.exp to support single digit GCC version.  Also
    remove duplicated [4-9] version check.
    
    	* testsuite/ld-selective/selective.exp: Support single digit
    	GCC version.

commit 04ac15ab07e6360320a1c8fab82d25340c22a21f
Author: Andreas Schwab <schwab@suse.de>
Date:   Tue Jul 11 17:36:35 2017 +0200

    Add missing newlines in readelf -n output
    
    	* readelf.c (process_note): Print newline after description data
    	in narrow mode.
    	(print_core_note): Print newline if nothing was printed in wide
    	mode.

commit e3fbc3da1342714b4943300a5a590b73f00acf08
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jul 11 22:38:54 2017 +0930

    ppc32 use of %x in einfo format, typo fix
    
    	* elf32-ppc.c (ppc_elf_relocate_section): Fix typo.

commit 54e2cdd49baced82c06b128128fde5381cecc3d0
Merge: a948ad9 70391b2
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Jul 11 04:12:12 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit a948ad92a2096c570fe25295c1e4cf1143f972e7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Jul 11 04:12:00 2017 -0700

    Revert "Apply x86-64: Treat ___tls_get_addr like __tls_get_addr"
    
    This reverts commit 2c60360a42becaa219f6593bd697ac3124e3dc27.

commit 70391b29cfc701f99b21b76100dc69531bf9eeec
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Tue Jul 11 11:11:09 2017 +0100

    [AArch64] Use "#pass" instead of "#..." to filter multiple lines
    
    ld/
    	* testsuite/ld-aarch64/dt_textrel.d: Use "#pass" instead of ".*" to
    	filter out remaining lines.

commit 2c4d9cbe519e4050d067069e2d8910c42dab0157
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jul 11 19:18:47 2017 +0930

    ppc32 use of %x in einfo format
    
    einfo doesn't support %x.
    
    	* elf32-ppc.c (ppc_elf_relocate_section): Emit "unexpected
    	instruction" error using _bfd_error_handler, not einfo.

commit 4162bb66c684478bfd0f6f0e121c25b6830d8191
Author: Alan Modra <amodra@gmail.com>
Date:   Tue Jul 11 19:13:08 2017 +0930

    Mark generated cgen files read-only
    
    	* cgen.sh: Mark generated files read-only.
    	* epiphany-asm.c: Regenerate.
    	* epiphany-desc.c: Regenerate.
    	* epiphany-desc.h: Regenerate.
    	* epiphany-dis.c: Regenerate.
    	* epiphany-ibld.c: Regenerate.
    	* epiphany-opc.c: Regenerate.
    	* epiphany-opc.h: Regenerate.
    	* fr30-asm.c: Regenerate.
    	* fr30-desc.c: Regenerate.
    	* fr30-desc.h: Regenerate.
    	* fr30-dis.c: Regenerate.
    	* fr30-ibld.c: Regenerate.
    	* fr30-opc.c: Regenerate.
    	* fr30-opc.h: Regenerate.
    	* frv-asm.c: Regenerate.
    	* frv-desc.c: Regenerate.
    	* frv-desc.h: Regenerate.
    	* frv-dis.c: Regenerate.
    	* frv-ibld.c: Regenerate.
    	* frv-opc.c: Regenerate.
    	* frv-opc.h: Regenerate.
    	* ip2k-asm.c: Regenerate.
    	* ip2k-desc.c: Regenerate.
    	* ip2k-desc.h: Regenerate.
    	* ip2k-dis.c: Regenerate.
    	* ip2k-ibld.c: Regenerate.
    	* ip2k-opc.c: Regenerate.
    	* ip2k-opc.h: Regenerate.
    	* iq2000-asm.c: Regenerate.
    	* iq2000-desc.c: Regenerate.
    	* iq2000-desc.h: Regenerate.
    	* iq2000-dis.c: Regenerate.
    	* iq2000-ibld.c: Regenerate.
    	* iq2000-opc.c: Regenerate.
    	* iq2000-opc.h: Regenerate.
    	* lm32-asm.c: Regenerate.
    	* lm32-desc.c: Regenerate.
    	* lm32-desc.h: Regenerate.
    	* lm32-dis.c: Regenerate.
    	* lm32-ibld.c: Regenerate.
    	* lm32-opc.c: Regenerate.
    	* lm32-opc.h: Regenerate.
    	* lm32-opinst.c: Regenerate.
    	* m32c-asm.c: Regenerate.
    	* m32c-desc.c: Regenerate.
    	* m32c-desc.h: Regenerate.
    	* m32c-dis.c: Regenerate.
    	* m32c-ibld.c: Regenerate.
    	* m32c-opc.c: Regenerate.
    	* m32c-opc.h: Regenerate.
    	* m32r-asm.c: Regenerate.
    	* m32r-desc.c: Regenerate.
    	* m32r-desc.h: Regenerate.
    	* m32r-dis.c: Regenerate.
    	* m32r-ibld.c: Regenerate.
    	* m32r-opc.c: Regenerate.
    	* m32r-opc.h: Regenerate.
    	* m32r-opinst.c: Regenerate.
    	* mep-asm.c: Regenerate.
    	* mep-desc.c: Regenerate.
    	* mep-desc.h: Regenerate.
    	* mep-dis.c: Regenerate.
    	* mep-ibld.c: Regenerate.
    	* mep-opc.c: Regenerate.
    	* mep-opc.h: Regenerate.
    	* mt-asm.c: Regenerate.
    	* mt-desc.c: Regenerate.
    	* mt-desc.h: Regenerate.
    	* mt-dis.c: Regenerate.
    	* mt-ibld.c: Regenerate.
    	* mt-opc.c: Regenerate.
    	* mt-opc.h: Regenerate.
    	* or1k-asm.c: Regenerate.
    	* or1k-desc.c: Regenerate.
    	* or1k-desc.h: Regenerate.
    	* or1k-dis.c: Regenerate.
    	* or1k-ibld.c: Regenerate.
    	* or1k-opc.c: Regenerate.
    	* or1k-opc.h: Regenerate.
    	* or1k-opinst.c: Regenerate.
    	* xc16x-asm.c: Regenerate.
    	* xc16x-desc.c: Regenerate.
    	* xc16x-desc.h: Regenerate.
    	* xc16x-dis.c: Regenerate.
    	* xc16x-ibld.c: Regenerate.
    	* xc16x-opc.c: Regenerate.
    	* xc16x-opc.h: Regenerate.
    	* xstormy16-asm.c: Regenerate.
    	* xstormy16-desc.c: Regenerate.
    	* xstormy16-desc.h: Regenerate.
    	* xstormy16-dis.c: Regenerate.
    	* xstormy16-ibld.c: Regenerate.
    	* xstormy16-opc.c: Regenerate.
    	* xstormy16-opc.h: Regenerate.

commit 11cb57160f4053e9dce292b461c035dcc563fdb7
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date:   Tue Jul 11 09:51:03 2017 +0200

    Sync dlang demangling tests from upstream libiberty testsuite.
    
    Rationale behind the change instead of adding a `.init$' postfix being
    that "initializer for symbol" is much more informative when inspecting D
    runtime type information in gdb, which is the only place where you would
    encounter references to this compiler-generated symbol.
    
    gdb/testsuite/ChangeLog:
    
    	* gdb.dlang/demangle.exp: Update for demangling changes.

commit 36cebdda8069aa04272e8fe6b5ec751a4ed55c68
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jul 11 00:00:41 2017 +0000

    Automatic date update in version.in

commit 6dc8d7579d1857460a4d0575660ade2e0462b08d
Author: Anton Kolesov <Anton.Kolesov@synopsys.com>
Date:   Mon Jul 10 20:48:30 2017 +0300

    Add missing ChangeLog etries
    
    This adds the missing ChangeLog entries for my previous patch
    
    3d99e81 Import setenv and unsetenv from gnulib

commit adce5b398df497da54e67772233be1b4849666ed
Author: Nick Clifton <nickc@redhat.com>
Date:   Mon Jul 10 13:18:05 2017 +0100

    Fix compile time warning about duplicate case values for powerpc-aix target.
    
    	* coffcode.h (coff_slurp_symbol_table): Do not include an entry
    	for C_AIX_WEAKEXT if it has the same value as C_WEAKEXT.

commit 77c501bcea87d4606367ddd87affddf9aed1aa57
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Jul 10 12:00:35 2017 +0100

    Re-generate i386/amd64-avx-avx512-linux.c and i386/amd64-avx-mpx-avx512-pku-linux.c
    
    gdb:
    
    2017-07-10  Yao Qi  <yao.qi@linaro.org>
    
    	* features/i386/amd64-avx-avx512-linux.c: Re-generated.
    	* features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.

commit 2e1e43e14021573158dfd170f8e67e02a4c6b4b4
Author: Yao Qi <yao.qi@linaro.org>
Date:   Mon Jul 10 11:53:44 2017 +0100

    Re-indent the code
    
    gdb/gdbserver:
    
    2017-07-10  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-x86-low.c (x86_linux_read_description): Re-indent the code.

commit 3d99e817a90b2a37860d527f2fb5643e7b861e7d
Author: Anton Kolesov <Anton.Kolesov@synopsys.com>
Date:   Mon Jul 3 19:17:29 2017 +0300

    Import setenv and unsetenv from gnulib
    
    This patch supersedes
    https://sourceware.org/ml/gdb-patches/2017-07/msg00009.html
    
    ---
    
    Patch [1] broke a build on MinGW hosts, because MinGW doesn't provide POSIX
    functions setenv () and unsetenv ().  This can be fixed by using
    implementations from gnulib.
    
    [1] https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=9a6c7d9c0
    
    gdb/ChangeLog
    yyyy-mm-dd  Anton Kolesov  <Anton.Kolesov@synopsys.com>
    
    	* gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
    	unsetenv.
    	* gnulib/aclocal.m4: Regenerate.
    	* gnulib/config.in: Regenerate.
    	* gnulib/configure: Regenerate.
    	* gnulib/import/Makefile.am: Regenerate.
    	* gnulib/import/Makefile.in: Regenerate.
    	* gnulib/import/m4/gnulib-cache.m4: Regenerate.
    	* gnulib/import/m4/gnulib-comp.m4: Regenerate.
    	* gnulib/import/m4/environ.m4: New file.
    	* gnulib/import/m4/setenv.m4: New file.
    	* gnulib/import/setenv.c: New file.
    	* gnulib/import/unsetenv.c: New file.

commit a074796714dcf281f5305540e3c5293d94f653f8
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jul 10 00:00:41 2017 +0000

    Automatic date update in version.in

commit 14357de15f6594468950d17dbaac8da0ab05063c
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sun Jul 9 20:52:18 2017 +0200

    DWARF-5: Fix error message typo.
    
    binutils/
    2017-07-09  Rafael Fontenelle <rafaelff@gnome.org>
    
    	* dwarf.c (display_formatted_table): Fix error message typo.

commit 266934d1ad029100f4073f9e351f8685ea175b83
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Sun Jul 9 20:25:38 2017 +0200

    compile-loc2c: Fix uninitialized variable error
    
    Compiling with clang gives this warning/error:
    
      /home/emaisin/src/binutils-gdb/gdb/compile/compile-loc2c.c:731:6: error: variable 'uoffset' is uninitialized when used here [-Werror,-Wuninitialized]
                  uoffset += dwarf2_per_cu_text_offset (per_cu);
                  ^~~~~~~
      /home/emaisin/src/binutils-gdb/gdb/compile/compile-loc2c.c:669:23: note: initialize the variable 'uoffset' to silence this warning
            uint64_t uoffset, reg;
                            ^
                             = 0
    
    I am really not sure if what this patch does is good, but it is my best
    guess.  DW_OP_addr means that there's an constant address provided by
    the DWARF bytecode that should be pushed on the stack.  That address is
    considered skipped by the "op_ptr += addr_size", but it is never read.
    uoffset is indeed read just after, without having been assigned first.
    
    So I think the intent is to read the address, it was just omitted.
    
    gdb/ChangeLog:
    
    	* compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
    	address when op is DW_OP_addr.

commit 0327869232a2f447474306a4d88214324d8abd40
Author: Tom Tromey <tom@tromey.com>
Date:   Sun May 28 08:06:54 2017 -0600

    Fix size check in dwarf2_evaluate_loc_desc_full
    
    This Rust bug report:
    
    https://github.com/rust-lang/rust/issues/41970
    
    noted an error from gdb.  What is happening here (for me, the original
    report had a different error) is that a pieced DWARF expression is not
    writing to every byte in the resulting value.  GDB errors in this
    case.  However, it seems to me that it is always valid to write fewer
    bytes; the issue comes from writing too many -- that is, the test is
    reversed.  The test was also checking the sub-object, but this also
    seems incorrect, as it's expected for the expression to write the
    entirety of the enclosing object.  So, this patch reverses the test
    and applies it to the outer type, not the subobject type.
    
    Regtested on the buildbot.
    
    gdb/ChangeLog
    2017-07-09  Tom Tromey  <tom@tromey.com>
    
    	* dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
    	check and apply to outer type.
    
    gdb/testsuite/ChangeLog
    2017-07-09  Tom Tromey  <tom@tromey.com>
    
    	* gdb.dwarf2/shortpiece.exp: New file.

commit f4db828807aa2ad2279b6afa582c64bb5e3153d5
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jul 9 00:00:41 2017 +0000

    Automatic date update in version.in

commit 12c1f20d6fba9dce0011f3ad11a7de60f7df4a7f
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jul 8 00:00:40 2017 +0000

    Automatic date update in version.in

commit 4b654465bfc3034c969d2d942c14b2cedfd3e3b6
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 12:50:56 2017 -0700

    Read signal information from FreeBSD core dumps.
    
    FreeBSD recently added a new ELF core note which dumps the entire LWP
    info structure (the same structure returned by the ptrace PT_LWPINFO
    operation) for each thread.  The plan is for this note to eventually
    supplant the older "thrmisc" ELF core note as it contains more
    information and it permits new information to be exported via both
    ptrace() and core dumps using the same structure.
    
    For signal information, the implementation is similar to the native
    implementation for FreeBSD processes.  The PL_FLAG_SI flag must be
    checked to determine if the embedded siginfo_t structure is valid, and
    if so it is transferred into the caller's buffer.
    
    gdb/ChangeLog:
    
    	* fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
    	(LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
    	(SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
    	(fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.

commit e6f3b9c3194c0d89efffd6e5b59471950f979e5a
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 12:47:14 2017 -0700

    Create pseudo sections for FreeBSD NT_PTLWPINFO core notes.
    
    bfd/ChangeLog:
    
    	* elf.c (elfcore_grok_freebsd_note): Handle NT_FREEBSD_PTLWPINFO.

commit 0b9305edf1d0b15913643b132dad02d4ca4fbb43
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 11:41:41 2017 -0700

    Recognize the recently-added FreeBSD core dump note for LWP info.
    
    This core dump note contains the same information returned by the
    ptrace PT_LWPINFO operation for each LWP belonging to a process.
    
    binutils/ChangeLog:
    
    	* readelf.c (get_freebsd_elfcore_note_type): Handle
    	NT_FREEBSD_PTLWPINFO.
    
    include/ChangeLog:
    
    	* elf/common.h (NT_FREEBSD_PTLWPINFO): Define.

commit 2af9fc4432bbda5ebd805bf5b56d81cd80d0cbf5
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 11:21:10 2017 -0700

    Use the thread_section_name helper class in fbsd_core_thread_name.
    
    gdb/ChangeLog:
    
    	* fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.

commit 382b69bbb7a4fec5213d2382fe70a68d7a46b3e7
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 11:11:20 2017 -0700

    Add a new gdbarch method to fetch signal information from core files.
    
    Previously the core_xfer_partial method used core_get_siginfo to handle
    TARGET_OBJECT_SIGNAL_INFO requests.  However, core_get_siginfo looked for
    Linux-specific sections in the core file.  To support fetching siginfo
    from cores on other systems, add a new gdbarch method (`core_xfer_siginfo`)
    and move the body of the existing core_get_siginfo into a
    linux_core_xfer_siginfo implementation of this method in linux-tdep.c.
    
    gdb/ChangeLog:
    
    	* corelow.c (get_core_siginfo): Remove.
    	(core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
    	instead of get_core_siginfo.
    	* gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
    	* gdbarch.h: Re-generate.
    	* gdbarch.c: Re-generate.
    	* linux-tdep.c (linux_core_xfer_siginfo): New.
    	(linux_init_abi): Install gdbarch "core_xfer_siginfo" method.

commit 6e5eab33abe09041b29e0ce484f684ad0ffe80a5
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 10:41:57 2017 -0700

    Move the thread_section_name class to gdbcore.h.
    
    This allows it to be used outside of corelow.c.

commit 929edea98d27cf9d72305c1584ee77627da7fa96
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 09:53:06 2017 -0700

    Fetch signal information for native FreeBSD processes.
    
    Use the `pl_siginfo' field in the `struct ptrace_lwpinfo' object returned
    by the PT_LWPINFO ptrace() request to supply the current contents of
    $_siginfo for each thread.  Note that FreeBSD does not supply a way to
    modify the signal information for a thread, so $_siginfo is read-only for
    FreeBSD.
    
    To handle 32-bit processes on a 64-bit host, define types for 32-bit
    compatible siginfo_t and convert the 64-bit siginfo_t to the 32-bit
    equivalent when supplying information for a 32-bit process.
    
    gdb/ChangeLog:
    
    	* fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
    	(struct siginfo32): New.
    	[PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
    	(fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
    	via ptrace(PT_LWPINFO).

commit 762c974a09746bda8a5d64ed3ee887adeae742b9
Author: John Baldwin <jhb@FreeBSD.org>
Date:   Wed Jun 28 08:14:06 2017 -0700

    Implement the "get_siginfo_type" gdbarch method for FreeBSD architectures.
    
    As with Linux architectures, cache the created type in the gdbarch when it
    is first created.  Currently FreeBSD uses an identical siginfo type on
    all architectures, so there is no support for architecture-specific fields.
    
    gdb/ChangeLog:
    
    	* fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
    	(init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
    	(fbsd_get_siginfo_type): New.
    	(fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
    	(_initialize_fbsd_tdep): New.

commit e54cb31aa33a124f746ff40c134e20e6d2bc6c34
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Fri Jul 7 17:58:03 2017 +0100

    MIPS/LD: Fix a segfault from ELF `e_flags' access with non-ELF output BFD
    
    Fix a commit 861fb55ab50a ("Defer allocation of R_MIPS_REL32 GOT
    slots"), <https://sourceware.org/ml/binutils/2008-08/msg00096.html>,
    regression and a more recent:
    
    FAIL: ld-unique/pr21529
    
    new LD test case failure, observed with all the relevant MIPS targets
    whenever the linker is invoked with one or more ELF inputs and the
    output format set to `binary'.
    
    The culprit is a segmentation fault caused in `mips_before_allocation'
    by a null pointer dereference, where an attempt is made to access the
    ELF file header's `e_flags' member, for the purpose of determining
    whether to produce a PLT and copy relocations, without first checking
    that the output BFD is ELF.  The `e_flags' member is stored in BFD's
    private data pointed to by `tdep', which in the case of the `binary' BFD
    is null, causing the segmentation fault.  With other non-ELF BFDs such
    as SREC `tdep' is not null and consequently no crash may happen and in
    that case random data will be interpreted as it was `e_flags'.
    
    Disable the access to `e_flags' then and all the associated checks and
    consequently never produce a PLT and copy relocations if output is not a
    MIPS ELF BFD, matching `_bfd_mips_elf_merge_private_bfd_data' that does
    not process `e_flags' in that case either and therefore does not let us
    decide here anyway if all the input objects included in the link are
    suitable for use with a PLT and copy relocations.
    
    	ld/
    	* emultempl/mipself.em (mips_before_allocation): Avoid ELF
    	processing if not MIPS ELF.
    	* testsuite/ld-mips-elf/binary.d: New test.
    	* testsuite/ld-mips-elf/binary.ld: New test linker script.
    	* testsuite/ld-mips-elf/binary.s: New test source.
    	* testsuite/ld-mips-elf/mips-elf.exp: Run the new test.

commit c620a2b5471b9158e9e0da176e098ce3f4335b1f
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 7 23:49:42 2017 +0930

    Make ppc476 testcases more robust
    
    	* testsuite/ld-powerpc/ppc476-shared.lnk: Align .bss.
    	* testsuite/ld-powerpc/ppc476-shared.d: Adjust.
    	* testsuite/ld-powerpc/ppc476-shared2.d: Adjust.

commit 7639175c9add472d9271318996547a57acbcc062
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 7 12:14:53 2017 +0930

    Move print_insn_XXX to an opcodes internal header, again
    
    88c1242dc0a changed some generated files rather than the source.
    
    	* cgen-dis.in: Include disassemble.h, not dis-asm.h.
    	* m32c-dis.c: Regenerate.
    	* mep-dis.c: Regenerate.

commit 532cc31305f46a979ddc4f98866b67e4d3a9d45c
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 7 10:31:27 2017 +0930

    Add some missing xcoff support
    
    	* coffcode.h (coff_slurp_symbol_table): Handle C_AIX_WEAKEXT.

commit aff6079bc770cb97f29f0bf15467f8c04bd1383c
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 7 10:30:53 2017 +0930

    Apply ld/Makefile.in patch to the correct file
    
    Makefile.in is generated.
    
    	* Makefile.am (eelf64_s390.c): Depend on emultempl/s390.em.

commit 1cf9552bf1c77df8850de01d48e1057a27415314
Author: Alan Modra <amodra@gmail.com>
Date:   Fri Jul 7 10:19:08 2017 +0930

    Another _doprnt fix for %L handling
    
    	* bfd.c (_doprnt): Replace "L" with "ll" when printing bfd_vma
    	as long long.  Move code replacing "ll" with "I64", and simplify.

commit 9691e722c654054cbf2a6992097c730b8cc50435
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Fri Jul 7 00:00:35 2017 +0000

    Automatic date update in version.in

commit 33c5cd75874c36374c0966c59feeaf6f17512499
Author: David Blaikie <dblaikie@gmail.com>
Date:   Thu Jul 6 11:17:52 2017 -0700

    Fission support for multiple CUs per DWO file
    
    In some cases a compiler may produce a single object file (& thus single
    DWO file) representing multiple source files. The most common example of
    this is in whole program optimization (such as LLVM's LTO). Fission may
    still be a beneficial feature to use here - to avoid the need to
    read/link the debug info with system libraries and the like.
    
    This change adds basic support for multiple CUs in a single DWO file to
    support LLVM's output in this situation.
    
    There is still outstanding work to design and implement a solution for
    cross-CU references (usually using DW_FORM_ref_addr) in this scenario.
    For now LLVM works around this by duplicating DIEs rather than making
    cross-CU references in DWO files. This degrades debugger
    behavior/quality especially for file-local entities.
    
    2017-07-06  David Blaikie  <dblaikie@gmail.com>
    
    	* dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
    	a singular dwo_unit*) to support multiple CUs in the same way that
    	multiple TUs are supported.
    	(create_cus_hash_table): Replace create_dwo_cu with a function for
    	parsing multiple CUs from a DWO file.
    	(open_and_init_dwo_file): Use create_cus_hash_table rather than
    	create_dwo_cu.
    	(lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
    	htab_find, rather than comparing the signature to a singleton CU in
    	the dwo_file.
    
    2017-07-06  David Blaikie  <dblaikie@gmail.com>
    
    	* gdb.dwarf2/fission-multi-cu.S: Test containing multiple CUs in a DWO,
    	built from fissiont-multi-cu{1,2}.c.
    	* gdb.dwarf2/fission-multi-cu.exp: Test similar to fission-base.exp,
    	except putting 'main' and 'func' in separate CUs in the same DWO file.
    	* gdb.dwarf2/fission-multi-cu1.c: First CU for the multi-CU-single-DWO
    	test.
    	* gdb.dwarf2/fission-multi-cu2.c: Second CU in the multi-CU-single-DWO
    	test.

commit a0b7b105236d5bc65e8d3a35f1b4f34bcc5e3705
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Thu Jul 6 06:52:13 2017 -0700

    Convert 'L' to 'l' when setting wide_width to 1
    
    When setting wide_width to 1, convert 'L' to 'l'.  Otherwise, %Lx/%Lu/%Ld
    will be passed to fprintf which will treat the argument as long long.
    
    	* bfd.c (_doprnt): Convert 'L' to 'l' when setting wide_width
    	to 1.

commit 4b617f5235fb680563571cecfdb03e3b3493444b
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Thu Jul 6 00:00:56 2017 +0000

    Automatic date update in version.in

commit 8455d26243aef72f7b827ec0d8367b6b7816de07
Author: Pedro Alves <palves@redhat.com>
Date:   Thu Jul 6 00:19:24 2017 +0100

    Fix Python unwinder frames regression
    
    The gdb.python/py-unwind.exp test is crashing GDB / leaving core dumps
    in the test dir, even though it all passes cleanly.  The crash is not
    visible in gdb.sum/gdb.log because it happens as side effect of the
    "quit" command, while flushing the frame cache.
    
    The problem is simply a typo in a 'for' loop's condition, introduced
    by a recent change [4fa847d78edd ("Remove MAX_REGISTER_SIZE from
    py-unwind.c")], resulting in infinite loop / double-free.
    
    The new test exposes the crash, like:
    
     Running src/gdb/testsuite/gdb.python/py-unwind.exp ...
     ERROR: Process no longer exists
    
    gdb/ChangeLog:
    2017-07-06  Pedro Alves  <palves@redhat.com>
    
    	* python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
    
    gdb/testsuite/ChangeLog:
    2017-07-06  Pedro Alves  <palves@redhat.com>
    
    	* gdb.python/py-unwind.exp: Test flushregs.

commit 0487c3bd0d70d89cdb7e82d7c822c2d4fb1540e4
Merge: 2c60360 1d827a7
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jul 5 09:11:59 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 1d827a720c9659cc8d54059ccc3efae24b875c03
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jul 5 09:04:51 2017 -0700

    Fix build with GCC 4.2
    
    Fix GCC 4.2 warnings like:
    
    cc1: warnings being treated as errors
    binutils-gdb/bfd/dwarf2.c:1844: warning: declaration of â??timeâ?? shadows a global declaration
    /usr/include/time.h:187: warning: shadowed declaration is here
    binutils-gdb/bfd/dwarf2.c: In function â??line_info_add_file_nameâ??:
    binutils-gdb/bfd/dwarf2.c:1854: warning: declaration of â??timeâ?? shadows a global declaration
    /usr/include/time.h:187: warning: shadowed declaration is here
    
    bfd/
    
    	* dwarf2.c (line_info_add_include_dir_stub): Replace time with
    	xtime.
    	(line_info_add_file_name): Likewise.
    	(decode_line_info): Likewise.
    
    binutils/
    
    	* dwarf.c (display_debug_names): Replace index with xindex.

commit 2c60360a42becaa219f6593bd697ac3124e3dc27
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jul 5 08:52:21 2017 -0700

    Apply x86-64: Treat ___tls_get_addr like __tls_get_addr

commit 02e72ea10d3e35ee7dca3e48859a0b8c4c8a4371
Merge: 813f376 15a7695
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Jul 5 08:47:27 2017 -0700

    Merge remote-tracking branch 'origin/master' into users/hjl/linux/master

commit 15a7695fdce108548169ca265cc440b049d63951
Author: James Greenhalgh <james.greenhalgh@arm.com>
Date:   Wed Jul 5 12:04:37 2017 +0100

    [ARM] Add support for Cortex-A55 and Cortex-A75.
    
    This patch adds support for the ARM Cortex-A55 and
    Cortex-A75 processors.
    
    The ARM Cortex-A55 and Cortex-A75 procsessors implement the ARMv8-A
    architecture, with support for the ARMv8.1-A and ARMv8.2-A extensions,
    including support for the 16-bit floating point extensions.
    
    The 16-bit floating-point extensions are optional, and we haven't defined
    an option mapping straight to them thus far, so this patch first needs to
    add one of those in include/opcode/arm.h, then we can simply add the CPU names
    as usual in config/tc-arm.c .
    
    Tested on arm-none-eabi.
    
    2017-07-05  James Greenhalgh  <james.greenhalgh@arm.com>
    
    	* config/tc-arm.c (arm_cpus): Add Cortex-A55 and Cortex-A75.
    	* doc/c-arm.texi (-mcpu): Document Cortex-A55 and Cortex-A75.

commit e4bdd679556e4e4ba71bcd066cc98ee7c2f4fca2
Author: Borislav Petkov <bp@suse.de>
Date:   Wed Jul 5 11:27:49 2017 +0200

    X86: Disassemble primary opcode map's group 2 ModRM.reg == 6 aliases correctly
    
    The instructions are not documented in the Intel SDM but are documented
    in the AMD APM as an alias to the group 2, ModRM.reg == 4 variant.
    
    Both AMD and Intel CPUs execute the C[0-1] and D[0-3] instructions as
    expected, i.e., like the /4 aliases:
    
      #include <stdio.h>
    
      int main(void)
      {
              int a = 2;
    
              printf ("a before: %d\n", a);
    
              asm volatile(".byte 0xd0,0xf0"          /* SHL %al */
                           : "+a" (a));
    
              printf("a after : %d\n", a);
    
              return 0;
      }
    
      $ ./a.out
      a before: 2
      a after : 4

commit 60c96dbf02fcdb30942b9db7a138afcfc2b7220e
Author: Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
Date:   Wed Jul 5 10:21:07 2017 +0100

    Fixup changelog entries for previous commit
    
    40c7d50720e04c3d1ef1695a8097f735bafbe54f

commit 033ea118c0f5b33bd4d9af541e5c503119aad37a
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Wed Jul 5 00:00:31 2017 +0000

    Automatic date update in version.in

commit 4da3eb35ef0545aac35dbd09070e5bf925f947d3
Author: Pedro Alves <palves@redhat.com>
Date:   Tue Jul 4 18:40:26 2017 +0100

    Garbage collect TYPE_STATIC and several TYPE_FN_FIELD_x
    
    Nothing uses these.  Most of the TYPE_FN_FIELD_ ones were probably
    used by the gcj support.
    
    gdb/ChangeLog:
    2017-07-04  Pedro Alves  <palves@redhat.com>
    
    	* gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
    	* gdbtypes.h (TYPE_STATIC): Delete.
    	(struct fn_field) <is_public, is_abstract, is_static, is_final,
    	is_synchronized, is_native>: Delete.
    	<dummy>: Bump.
    	(TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
    	(TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
    	(TYPE_FN_FIELD_ABSTRACT): Delete.

commit 40c7d50720e04c3d1ef1695a8097f735bafbe54f
Author: Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
Date:   Tue Jul 4 16:18:47 2017 +0100

    [Patch ARM] Support MVFR2 VFP Coprocessor register for ARMv8-A
    
    This patch adds support mvfr2 control registers for armv8-a as
    this was missed from the original port to armv8-a (documented
    at G6.2.109 in (Issue B.a) of the ARM-ARM. This was discovered
    by an internal user of the GNU toolchain.
    
    I'd like to backport this to the binutils 2.28 and binutils 2.29
    release branch if possible (with suitable testing and basically
    checking removing the armv8-r parts).
    
    Tristan - are you ok with the backports ?
    
    Applied to trunk.
    
    regards Ramana
    
    2017-07-04  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
    
            * gas/config/tc-arm.c (arm_regs): Add MVFR2.
            (do_vmrs): Constraint for MVFR2 and armv8.
            (do_vmsr): Likewise.
            * gas/testsuite/gas/arm/armv8-a+fp.d: Update.
            * gas/testsuite/gas/arm/armv8-ar+fp.s: Likewise.
            * gas/testsuite/gas/arm/armv8-r+fp.d: Likewise.
            * gas/testsuite/gas/arm/vfp-bad.s: Likewise.
            * gas/testsuite/gas/arm/vfp-bad.l: Likewise.
            * opcodes/arm-dis.c: Support MVFR2 in disassembly
            with vmrs and vmsr.

commit 0d702cfe5d9195f2ba8d110120374a8da6d20c73
Author: Tristan Gingold <gingold@adacore.com>
Date:   Tue Jul 4 11:15:33 2017 +0200

    Regenerate configure.
    
    bfd/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* version.m4: Bump version to 2.29.51
    	* configure: Regenerate.
    
    binutils/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* configure: Regenerate.
    
    gas/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* configure: Regenerate.
    
    gprof/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* configure: Regenerate.
    
    ld/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* configure: Regenerate.
    
    opcodes/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* configure: Regenerate.

commit 55a09eb6df557934bcb7e96d8ab4e9e7ca0670be
Author: Tristan Gingold <gingold@adacore.com>
Date:   Tue Jul 4 11:06:02 2017 +0200

    Add markers.
    
    binutils/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* NEWS: Add marker for 2.29.
    
    gas/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* NEWS: Add marker for 2.29.
    
    ld/
    2017-07-04  Tristan Gingold  <gingold@adacore.com>
    
    	* NEWS: Add marker for 2.29.

commit 564e46b795ea9ef95ec662f01139a97717de1603
Author: Jiong Wang <jiong.wang@arm.com>
Date:   Mon Jul 3 17:15:26 2017 +0100

    [AArch64] Remove useless and incorrect assertion
    
    The outer caller elf_link_output_extsym in elflink.c is a traverse function on
    all external symbol, and it will only call *finish_dynamic_symbol if some
    conditions is meet.  It is executed conditionally.
    
    If the condition to trigger that assertion is satisified, it then won't satify
    the outer check in finish_dynamic_symbol, so *finish_dynamic_symbol won't be
    called that the assertion is expected to be dead code.
    
    If elf_link_output_extsym is a traverse function that unconditionally called
    on external symbols decided to be exported, then an assertion to make sure these
    symbols are in sane status might make sense.
    
    bfd/
            * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_symbol): Remove the
            sanity check at the head of this function.

commit 0041f7df741692954ebc112c69e5326afb0115ba
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Tue Jul 4 10:09:27 2017 +0200

    [binutils patch] DWARF-5: Extend bfd/dwarf2.c parse_comp_unit()
    
    bfd/
    2017-07-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf2.c (struct dwarf2_debug): Add fields dwarf_line_str_buffer and
    	dwarf_line_str_size.
    	(struct attr_abbrev): Add field implicit_const.
    	(dwarf_debug_sections): Add .debug_line_str.
    	(enum dwarf_debug_section_enum): Add debug_line_str and debug_max.
    	(dwarf_debug_section_assert): Add static assertion.
    	(read_indirect_line_string): New.
    	(read_abbrevs): Support DW_FORM_implicit_const.
    	(is_str_attr): Support DW_FORM_line_strp.
    	(read_attribute_value): Support DW_FORM_line_strp and
    	DW_FORM_implicit_const.
    	(read_attribute): Support DW_FORM_implicit_const.
    	(line_info_add_include_dir, line_info_add_include_dir_stub):
    	(line_info_add_file_name, read_formatted_entries): New.
    	(decode_line_info, parse_comp_unit): Support DWARF 5.
    	(_bfd_dwarf2_cleanup_debug_info): Free dwarf_line_str_buffer.

commit 568fc4f4f857d1a06d06ef5d74f8deaa0c8ae182
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Tue Jul 4 00:00:43 2017 +0000

    Automatic date update in version.in

commit d8cd8c1f482018acd16cab1f1f2a081786a04c6f
Author: Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
Date:   Mon Jul 3 20:06:35 2017 +0200

    bfd: partial revert commit EC1ACAB (prevent all but undef weak symbols to become dynamic in sparc).
    
    bfd/ChangeLog:
    
    2017-07-03  Egeyar Bagcioglu  <egeyar.bagcioglu@oracle.com>
    
            * elfxx-sparc.c (_bfd_sparc_elf_finish_dynamic_symbol): Remove the
            abort statement that was put for symbols that are not dynamic.

commit 15e6ed8cbf65f0b7cc7e384d78a56802d8d0244b
Author: Tristan Gingold <tgingold@free.fr>
Date:   Mon Jul 3 17:02:01 2017 +0200

    Regenerate pot files.

commit 19871f45ddfa7681f8f7585e73409f4fe5b51258
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 22:00:32 2017 +0930

    strings: remove section/file size check
    
    This reverts most of 06803313754, 2005-07-05 Dmitry V. Levin change
    adding a check that section size doesn't exceed file size.  As we've
    seen recently with mmo tests, decoded section size can easily exceed
    file size with formats that encode section data.
    
    I've also changed "strings" to use bfd_malloc_and_get_section, so that
    "strings" won't die on a malloc failure.  I think it's better to
    continue on looking at other sections after failing to dump a section
    with fuzzed size.
    
    The testcases at https://bugzilla.altlinux.org/show_bug.cgi?id=5871
    on a 32-bit host now produce
    $ strings -d --target=a.out-i386 /tmp/bfdkiller.dat
    strings: error: /tmp/bfdkiller.dat(.text) is too large (0xffffffff bytes)
    strings: /tmp/bfdkiller.dat: Reading section .text failed: Memory exhausted
    strings: /tmp/bfdkiller.dat: Reading section .data failed: File truncated
    org.ec
    $ strings -d --target=a.out-i386 /tmp/eclipse-state
    strings: /tmp/eclipse-state: Reading section .text failed: File truncated
    org.eclipse.osgi
    System Bundle
    [snip]
    
    	* strings.c (filename_and_size_t): Delete.
    	(strings_a_section): Don't check section size against file size.
    	Use bdf_malloc_and_get_section.  Report an error on failures.
    	Replace arg param with filename and got_a_section param.
    	(got_a_section): Move to..
    	(strings_object_file): ..an auto var here.  Iterate over sections
    	rather than calling bfd_map_over_sections.  Adjust strings_a_section
    	call.

commit 76cfced5addbd827652688a13f9cfa02afce51a5
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:59:45 2017 +0930

    Support %Lx, %Lu, %Ld in _bfd_error_handler format
    
    One way to print 64-bit bfd_vma or bfd_size_type values on 32-bit
    hosts is to cast the value to long long and use the 'll' modifier in
    printf format strings.  However, that's awkward because we also
    support the Microsoft C library printf that uses 'I64' as a modifier
    instead, and having variants of translated strings would not endear us
    to the translation project.  So, rewrite the 'll' modifier in
    _doprint for Microsoft.  Even with that capability it's not so nice
    for 32-bit code to need casts to long long, so this patch makes 'L' a
    modifier for bfd_vma rather than an alias for 'll'.
    
    I've then used the new 'L' modifier to fix selected format strings.
    
    	* bfd.c (_doprnt): Rewrite "ll" and "L" modifiers to "I64" for
    	__MSVCRT__.  Support "L" modifier for bfd_vma.  Formatting.
    	* elf.c (setup_group): Use "Lx" to print sh_size.
    	(_bfd_elf_setup_sections): Remove unnecessary cast and print
    	unknown section type in hex.
    	(copy_special_section_fields): Style fix.
    	(bfd_section_from_shdr): Correct format for sh_link.  Use a
    	common error message for all the variants of unrecognized
    	section types.
    	(assign_file_positions_for_load_sections): Use "Lx" for lma
    	adjust error message.
    	(assign_file_positions_for_non_load_sections): Formatting.
    	(rewrite_elf_program_header): Formatting.  Use "Lx" for
    	bfd_vma values in error messages.
    	* elfcode.h (elf_slurp_reloc_table_from_section): Cast
    	ELF_R_SYM value to type expected by format.
    	* elflink.c (elf_link_read_relocs_from_section): Use "Lx"
    	in error messages.
    	(elf_link_add_object_symbols): Use "Lu" for symbol sizes.
    	(elf_link_input_bfd): Use "Lx" for r_info.
    	(bfd_elf_gc_record_vtinherit): Use "Lx" for offset.

commit ce9116fdbfba8926a7bc25613d39bc3b2ed942fc
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:59:30 2017 +0930

    BFD long long cleanup
    
    long long isn't supposed to be used without a configure test, to
    support ancient compilers.  Probably not terribly important nowadays.
    
    	* bfd.c (bfd_scan_vma): Don't use long long unless HAVE_LONG_LONG.
    	* coff-rs6000.c (FMT20): Handle hosts with 64-bit long and
    	Microsoft C library variant of long long format specifier.
    	(PRINT20): Cast value to bfd_uint64_t not long long.
    	* coffcode.h (coff_print_aux): Use BFD_VMA_FMT.
    	* coff-x86_64.c (coff_amd64_reloc): Use bfd_uint64_t rather than
    	long long.  Don't cast to bfd_vma.
    	* elf32-score.c (score3_bfd_getl48): Likewise.
    	* vms-alpha.c (_bfd_vms_slurp_eisd): Likewise.

commit cd9af601e60240bb38dc58ce7e69abd5f2972ec7
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:56:29 2017 +0930

    Miscellaneous format string fixes
    
    	* elf.c (_bfd_elf_print_private_bfd_data): Use BFD_VMA_FMT to
    	print d_tag.
    	(bfd_elf_print_symbol): Don't cast symbol->flags.
    	(_bfd_elf_symbol_from_bfd_symbol): Likewise.
    	* elf32-ppc.c (ppc_elf_begin_write_processing): Correct
    	_bfd_error_handler argument order.
    	(ppc_elf_merge_private_bfd_data): Don't cast flags.

commit 33c734b2f860f77badb1e25d16e144e9db77d1bf
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:55:57 2017 +0930

    Missing config for bfd.c:_doprnt
    
    This function uses HAVE_LONG_LONG and HAVE_LONG_DOUBLE
    
    	* configure.ac: Invoke AC_CHECK_TYPES for long long.  Invoke
    	AC_TYPE_LONG_DOUBLE.
    	* configure: Regenerate.
    	* config.in: Regenerate.

commit 8d219acda1f7bc5f7adcecf479c9017196cf2c70
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:55:21 2017 +0930

    Disable symver test on hppa64-hpux
    
    The syntax for common symbols is different on that target.
    
    	* testsuite/gas/elf/symver.d: Don't run on hppa64-hpux.

commit c8cf1feee1bcb793d919b14853355a7ba09ab836
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 21:46:59 2017 +0930

    [GOLD] undef after using DW_IDX and friends
    
    	* dwarf.h (DW_FIRST_IDX, DW_IDX, DW_IDX_DUP, DW_END_IDX): Undef
    	after using.

commit 7e70564caed5f56b4937ef3f5a51ae2159cabef4
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Jul 3 19:30:24 2017 +0930

    Repair include/dwarf2.def breakage
    
    	* dwarf.h (DW_FIRST_IDX, DW_IDX, DW_IDX_DUP, DW_END_IDX): Define.

commit 5bfd255c414e89f23342f38975d09b18f2c1b2b7
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Mon Jul 3 13:59:00 2017 +0200

    buffer.h: Fix spelling mistakes
    
    gdb/ChangeLog:
    
    	* buffer.h (buffer_finish): Fix spelling mistakes.

commit 2040444f336594dd2dabb35388b6fa97785754ab
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Mon Jul 3 00:00:39 2017 +0000

    Automatic date update in version.in

commit 613643582c4f6145063fe1522d57bd01fe7bba02
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sun Jul 2 22:15:05 2017 +0200

    DWARF-5: readelf: .debug_names
    
    Display DWARF-5 .debug_names (standardized .gdb_index).
    
    binutils/ChangeLog
    2017-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf.c: Include assert.h.
    	(MAX, MIN, get_IDX_name, display_debug_names): New.
    	(debug_displays): Add .debug_names.
    	* dwarf.h: (enum dwarf_section_display_enum): Add debug_names.
    	* readelf.c (process_section_headers): Add ".debug_names".

commit de837d77bca30483e8e926044fa497e3d49f7972
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Sun Jul 2 22:09:52 2017 +0200

    Import include/+libiberty/ r249883 from upstream GCC.
    
    include/ChangeLog
    2017-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarf2.def (DW_IDX_compile_unit, DW_IDX_type_unit, DW_IDX_die_offset)
    	(DW_IDX_parent, DW_IDX_type_hash, DW_IDX_lo_user, DW_IDX_hi_user)
    	(DW_IDX_GNU_internal, DW_IDX_GNU_external): New.
    	* dwarf2.h (DW_IDX, DW_IDX_DUP, DW_FIRST_IDX, DW_END_IDX): New.
    	(enum dwarf_name_index_attribute): Remove.
    	(get_DW_IDX_name): New declaration.
    
    libiberty/ChangeLog
    2017-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
    
    	* dwarfnames.c (DW_FIRST_IDX, DW_END_IDX, DW_IDX, DW_IDX_DUP): New.

commit c6eb149dfacbd7a5fc22d7cf7fa8df6bf1d6a637
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sun Jul 2 00:00:47 2017 +0000

    Automatic date update in version.in

commit bae7501e87ab614115d9d3213b4dd18d96e604db
Author: Alan Modra <amodra@gmail.com>
Date:   Sat Jul 1 21:58:10 2017 +0930

    Use bfd_malloc_and_get_section
    
    It's nicer than xmalloc followed by bfd_get_section_contents, since
    xmalloc exits on failure and needs a check that its size_t arg doesn't
    lose high bits when converted from bfd_size_type.
    
    	PR binutils/21665
    	* objdump.c (strtab): Make var a bfd_byte*.
    	(disassemble_section): Don't limit malloc size.  Instead, use
    	bfd_malloc_and_get_section.
    	(read_section_stabs): Use bfd_malloc_and_get_section.  Return
    	bfd_byte*.
    	(find_stabs_section): Remove now unnecessary cast.
    	* objcopy.c (copy_object): Use bfd_malloc_and_get_section.  Free
    	contents on error return.
    	* nlmconv.c (copy_sections): Use bfd_malloc_and_get_section.

commit 25c5412713badef8cf779186174200ecd880b329
Author: Eli Zaretskii <eliz@gnu.org>
Date:   Sat Jul 1 18:45:57 2017 +0300

    Setup .dir-locals.el to use C-style comments by default
    
    gdb/ChangeLog:
    2017-07-01  Eli Zaretskii  <eliz@gnu.org>
    
    	* .dir-locals.el: Automatically switch to C-style comments in
    	versions of Emacs that support the feature.

commit 3c465ea0ffd372bfc7f07eccef4c0b1bd22efc71
Author: GDB Administrator <gdbadmin@sourceware.org>
Date:   Sat Jul 1 00:00:41 2017 +0000

    Automatic date update in version.in

commit 834a65aadfda9755d8bd6ec76ba8b3a6d20a1beb
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Sat Jul 1 00:42:19 2017 +0100

    MIPS/GAS: Use a switch on relaxation type in microMIPS fixup creation
    
    Use a switch on the relaxation type rather than a chain of conditionals
    in microMIPS fixup creation, improving source code structure and aiding
    the compiler with code generation.
    
    	gas/
    	* config/tc-mips.c (md_convert_frag): Use a switch on the
    	microMIPS relaxation type rather than a chain of conditionals.

commit bbd27b7684baf424bdaa7f0a1d39a2cd5b0d6134
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Sat Jul 1 00:42:19 2017 +0100

    MIPS/GAS: Use frag symbol/offset directly in fixup creation
    
    There is no need to use a helper expression in the creation of fixups
    made from a frag's symbol and offset, because a simple `symbol+offset'
    expression can be handled directly, with the use of a `fix_new' rather
    than a `fix_new_exp' call.  Rewrite `md_convert_frag' using `fix_new'
    then and remove all the unneeded helper expressions, simplifying code.
    
    	gas/
    	* config/tc-mips.c (md_convert_frag): Rewrite `fix_new_exp'
    	calls in terms of `fix_new'.

commit 9f00292e69635d48623372c7a3e390dc5d159a8f
Author: Maciej W. Rozycki <macro@imgtec.com>
Date:   Sat Jul 1 00:42:19 2017 +0100

    MIPS/GAS: Use non-zero frag offset directly in PIC branch relaxation
    
    Use frag symbols with a non-zero offset directly in `fix_new_exp' calls
    made in PIC branch relaxation.  There is no need here to make a helper
    symbol to hold the result of a `symbol+offset' calculation requested as
    only branches to local symbols are relaxed and in this case the LO16
    part of the PIC address load sequence will have the offset accounted for
    in calculation against the local GOT entry retrieved as the GOT16 high
    part.  Consequently actual code produed is identical whether a helper
    symbol is used or the original `symbol+offset' expression used directly.
    Verify that this is indeed the case with GAS and LD tests.
    
    	gas/
    	* config/tc-mips.c (md_convert_frag): Don't make a helper
    	expression symbol for `fix_new_exp' called with a non-zero
    	offset.
    	* testsuite/gas/mips/relax-offset.d: New test.
    	* testsuite/gas/mips/mips1@relax-offset.d: New test.
    	* testsuite/gas/mips/r3000@relax-offset.d: New test.
    	* testsuite/gas/mips/r3900@relax-offset.d: New test.
    	* testsuite/gas/mips/micromips@relax-offset.d: New test.
    	* testsuite/gas/mips/relax-offset.l: New stderr output.
    	* testsuite/gas/mips/relax-offset.s: New test source.
    	* testsuite/gas/mips/mips.exp: Run the new tests.
    
    	ld/
    	* testsuite/ld-mips-elf/relax-offset.dd: New test.
    	* testsuite/ld-mips-elf/relax-offset.gd: New test.
    	* testsuite/ld-mips-elf/relax-offset-umips.dd: New test.
    	* testsuite/ld-mips-elf/relax-offset-umips.gd: New test.
    	* testsuite/ld-mips-elf/relax-offset.ld: New test linker script.
    	* testsuite/ld-mips-elf/mips-elf.exp: Run the new tests.
    	(prune_warnings): New temporary procedure.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]