From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 48353 invoked by alias); 23 Nov 2016 22:20:33 -0000 Mailing-List: contact archer-commits-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: Received: (qmail 48061 invoked by uid 9674); 23 Nov 2016 22:20:33 -0000 Date: Wed, 23 Nov 2016 22:20:00 -0000 Message-ID: <20161123222032.47721.qmail@sourceware.org> From: jkratoch@sourceware.org To: archer-commits@sourceware.org Subject: [SCM] users/jkratoch/dwarf5gcc: Merge remote-tracking branch 'gdb/master' into dwarf5gcc X-Git-Refname: refs/heads/users/jkratoch/dwarf5gcc X-Git-Reftype: branch X-Git-Oldrev: 76a29a45db928e68e1faf83d9c7008cc29543e65 X-Git-Newrev: c7a53c67f07d742348e5d79e0f44c6a1c35b0b1f X-SW-Source: 2016-q4/txt/msg00028.txt.bz2 List-Id: The branch, users/jkratoch/dwarf5gcc has been updated via c7a53c67f07d742348e5d79e0f44c6a1c35b0b1f (commit) via dcb07cfa156a8e9f768c7f2b5d32f27b6dfe939f (commit) via 7836e407c65761b003bfbcb7ce89947736330a15 (commit) via 8629c02c0db6ff3f7444397567a57dd36a3eed41 (commit) via 03b62bbbce3dc5f15131d9e78f77d035cd1cffb3 (commit) via b593ecca856860a8b38deb808493bba4beef3aee (commit) via 1a9ccd70f9a75dc6b48d340059f28ef3550c107b (commit) via 128e85e3ab36b8e30f6612fb50de3cbb4ede6824 (commit) via 073808edb771952247c6fe634b863986b7627150 (commit) via 64f52338e924cce3a205527136e145da660a4686 (commit) via ce558b89b15a18fd67fdc02a4d410a6d92d2ba63 (commit) via 3ae0486cdce5d2ed4c922c598a3258fcbd9c8f29 (commit) via 9986ba08876f86f7d36d230afc11b60a34287da8 (commit) via 4eefa7bcf286b879f61b9e1ec1c97230f5345104 (commit) via 400b2f29938dab7d9c4f46c9d1b0dc23dab0518b (commit) via 358a971863e93cbafa9e864b4db4d5448b960304 (commit) via ca3cbe5cd7715d1559d55f8e71be1dd7340f13b1 (commit) via 96fe45624e51f1bb747e36cf8bdaab216f31c5ec (commit) via f5ea389ac78ccd7c426a93f43e6117dad9ce0878 (commit) via b2260160f8cde8de118914ddeaf797bea42e65ce (commit) via fb090cfa157e35fac1c10c062fd005e38b894ea4 (commit) via 41e26ad32d17ee35f79f629654811f5e8656cab8 (commit) via ad76968956f30bed6d120e0dfd247034e0855fea (commit) via cd76b525eda02c30c4412698a2ff309b975d417a (commit) via 3889f4909e0db5f5ca8ca043ef9825f0ad971fd6 (commit) via a8f341826d63a5c216c41e10bf1e4e6c3db3ce65 (commit) via 7113a196bac7f1134bcdd79ad3e6badcb5d77f95 (commit) via 5b6e2eee087cf206d5c2bf1f9523217aaf5938aa (commit) via 7ab2d0874025af6ee858b32c576f2461c0a1df3d (commit) via 0187a92f57b516f7171e70bec46701cfdaa6c6bd (commit) via 9fd15b2e80452f03edb3fb36c2b4c36d05f4ef4e (commit) via 6884417a0ff3555b192d4aceeacc5e7232cad207 (commit) via c4b943d7aed5edbfc31aa1e9dc9e7bcf108d76a0 (commit) via 08dc996fedde9143cda25720961684087b133640 (commit) via 95f0d0d2338f8eba18d2b3c8cbe15b1d584b885c (commit) via c5acd8159633cfde315b01431099e1ce5b23dcf7 (commit) via 3063babf7c559f04203ad7fdfcd8fc12a302ee7a (commit) via c13b08dbbcf752480a7621aa1f89bc5440c74c25 (commit) via d0de53e251ce60057d91536a4c71740b047be040 (commit) via b32e1756d9932eebcca5f276290841a859ef2d6d (commit) via b6ddcd85e3c0ae1f12af60efd6d1b97ac4bfa771 (commit) via 3fff9862d5229def9318912c2de64a03dab74532 (commit) via 5689c9424b33aac68c4762ce0bda09ca7e3affe0 (commit) via 2d7f2507d4d26430da7e32e8fc75f045f634fced (commit) via 081f6b931dbc4a1f27ac003e2f75a389444ce9e9 (commit) from 76a29a45db928e68e1faf83d9c7008cc29543e65 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit c7a53c67f07d742348e5d79e0f44c6a1c35b0b1f Merge: 76a29a4 dcb07cf Author: Jan Kratochvil Date: Wed Nov 23 22:35:48 2016 +0100 Merge remote-tracking branch 'gdb/master' into dwarf5gcc commit dcb07cfa156a8e9f768c7f2b5d32f27b6dfe939f Author: Pedro Alves Date: Wed Nov 23 15:36:26 2016 +0000 gdb: Use C++11 std::chrono This patch fixes a few problems with GDB's time handling. #1 - It avoids problems with gnulib's C++ namespace support On MinGW, the struct timeval that should be passed to gnulib's gettimeofday replacement is incompatible with libiberty's timeval_sub/timeval_add. That's because gnulib also replaces "struct timeval" with its own definition, while libiberty expects the system's. E.g., in code like this: gettimeofday (&prompt_ended, NULL); timeval_sub (&prompt_delta, &prompt_ended, &prompt_started); timeval_add (&prompt_for_continue_wait_time, &prompt_for_continue_wait_time, &prompt_delta); That's currently handled in gdb by not using gnulib's gettimeofday at all (see common/gdb_sys_time.h), but that #undef hack won't work with if/when we enable gnulib's C++ namespace support, because that mode adds compile time warnings for uses of ::gettimeofday, which are hard errors with -Werror. #2 - But there's an elephant in the room: gettimeofday is not monotonic... We're using it to: a) check how long functions take, for performance analysis b) compute when in the future to fire events in the event-loop c) print debug timestamps But that's exactly what gettimeofday is NOT meant for. Straight from the man page: ~~~ The time returned by gettimeofday() is affected by discontinuous jumps in the system time (e.g., if the system administrator manually changes the system time). If you need a monotonically increasing clock, see clock_gettime(2). ~~~ std::chrono (part of the C++11 standard library) has a monotonic clock exactly for such purposes (std::chrono::steady_clock). This commit switches to use that instead of gettimeofday, fixing all the issues mentioned above. gdb/ChangeLog: 2016-11-23 Pedro Alves * Makefile.in (SFILES): Add common/run-time-clock.c. (HFILES_NO_SRCDIR): Add common/run-time-clock.h. (COMMON_OBS): Add run-time-clock.o. * common/run-time-clock.c, common/run-time-clock.h: New files. * defs.h (struct timeval, print_transfer_performance): Delete declarations. * event-loop.c (struct gdb_timer) : Now a std::chrono::steady_clock::time_point. (create_timer): use std::chrono::steady_clock instead of gettimeofday. Use new instead of malloc. (delete_timer): Use delete instead of xfree. (duration_cast_timeval): New. (update_wait_timeout): Use std::chrono::steady_clock instead of gettimeofday. * maint.c: Include instead of "gdb_sys_time.h", and "timeval-utils.h". (scoped_command_stats::~scoped_command_stats) (scoped_command_stats::scoped_command_stats): Use std::chrono::steady_clock instead of gettimeofday. Use user_cpu_time_clock instead of get_run_time. * maint.h: Include "run-time-clock.h" and . (scoped_command_stats): : Now a user_cpu_time_clock::time_point. : Now a std::chrono::steady_clock::time_point. * mi/mi-main.c: Include "run-time-clock.h" and instead of "gdb_sys_time.h" and . (rusage): Delete. (mi_execute_command): Use new instead of XNEW. (mi_load_progress): Use std::chrono::steady_clock instead of gettimeofday. (timestamp): Rewrite in terms of std::chrono::steady_clock, user_cpu_time_clock and system_cpu_time_clock. (timeval_diff): Delete. (print_diff): Adjust to use std::chrono::steady_clock, user_cpu_time_clock and system_cpu_time_clock. * mi/mi-parse.h: Include "run-time-clock.h" and instead of "gdb_sys_time.h". (struct mi_timestamp): Change fields types to std::chrono::steady_clock::time_point, user_cpu_time_clock::time and system_cpu_time_clock::time_point, instead of struct timeval. * symfile.c: Include instead of and "gdb_sys_time.h". (struct time_range): New. (generic_load): Use std::chrono::steady_clock instead of gettimeofday. (print_transfer_performance): Replace timeval parameters with a std::chrono::steady_clock::duration parameter. Adjust. * utils.c: Include instead of "timeval-utils.h", "gdb_sys_time.h", and . (prompt_for_continue_wait_time): Now a std::chrono::steady_clock::duration. (defaulted_query, prompt_for_continue): Use std::chrono::steady_clock instead of gettimeofday/timeval_sub/timeval_add. (reset_prompt_for_continue_wait_time): Use std::chrono::steady_clock::duration instead of struct timeval. (get_prompt_for_continue_wait_time): Return a std::chrono::steady_clock::duration instead of struct timeval. (vfprintf_unfiltered): Use std::chrono::steady_clock instead of gettimeofday. Use std::string. Use '.' instead of ':'. * utils.h: Include . (get_prompt_for_continue_wait_time): Return a std::chrono::steady_clock::duration instead of struct timeval. gdb/gdbserver/ChangeLog: 2016-11-23 Pedro Alves * debug.c: Include instead of "gdb_sys_time.h". (debug_vprintf): Use std::chrono::steady_clock instead of gettimeofday. Use '.' instead of ':'. * tracepoint.c: Include instead of "gdb_sys_time.h". (get_timestamp): Use std::chrono::steady_clock instead of gettimeofday. commit 7836e407c65761b003bfbcb7ce89947736330a15 Author: Nick Clifton Date: Wed Nov 23 14:57:51 2016 +0000 Adjust linker test for arm-vxworks in wake of patch for PR 20815. commit 8629c02c0db6ff3f7444397567a57dd36a3eed41 Author: Simon Marchi Date: Tue Nov 22 16:14:25 2016 -0500 Minor formatting fixups in Makefiles Mostly some whitespace changes to make things a bit more consistent. gdb/ChangeLog: * Makefile.in: Fix whitespace formatting. gdb/gdbserver/ChangeLog: * Makefile.in: Fix whitespace formatting. commit 03b62bbbce3dc5f15131d9e78f77d035cd1cffb3 Author: Simon Marchi Date: Tue Nov 22 16:14:24 2016 -0500 Normalize names of some source files Most tdep/nat files are named: --tdep.c --nat.c A few files do not respect this scheme. This patch renames them so that they are consistent with the rest of the files. It builds fine with --enable-targets=all, but that doesn't test the nat files. I can only hope that my grep skill is good enough. gdb/ChangeLog: * Makefile.in (ALL_64_TARGET_OBS, ALL_TARGET_OBS, HFILES_NO_SRCDIR, ALLDEPFILES): Rename files. * alphabsd-nat.c: Rename to ... * alpha-bsd-nat.c: ... this, adjust include. * alphabsd-tdep.c: Rename to ... * alpha-bsd-tdep.c: ... this, adjust include. * alphabsd-tdep.h: Rename to ... * alpha-bsd-tdep.h: ... this, adjust include barrier and comment. * alphafbsd-tdep.c: Rename to ... * alpha-fbsd-tdep.c: ... this. * alphanbsd-tdep.c: Rename to ... * alpha-nbsd-tdep.c: ... this, adjust include. * alphaobsd-tdep.c: Rename to ... * alpha-obsd-tdep.c: ... this, adjust include. * amd64bsd-nat.c: Rename to ... * amd64-bsd-nat.c: ... this, adjust include. * amd64fbsd-nat.c: Rename to ... * amd64-fbsd-nat.c: ... this, adjust include. * amd64fbsd-tdep.c: Rename to ... * amd64-fbsd-tdep.c: ... this, adjust include. * amd64nbsd-nat.c: Rename to ... * amd64-nbsd-nat.c: ... this. * amd64nbsd-tdep.c: Rename to ... * amd64-nbsd-tdep.c: ... this. * amd64obsd-nat.c: Rename to ... * amd64-obsd-nat.c: ... this. * amd64obsd-tdep.c: Rename to ... * amd64-obsd-tdep.c: ... this. * amd64-tdep.h: Update comments. * armbsd-tdep.c: Rename to ... * arm-bsd-tdep.c: ... this. * armnbsd-nat.c: Rename to ... * arm-nbsd-nat.c: ... this. * armnbsd-tdep.c: Rename to ... * arm-nbsd-tdep.c: ... this. * armobsd-tdep.c: Rename to ... * arm-obsd-tdep.c: ... this. * arm-tdep.h: Update comments. * hppabsd-tdep.c: Rename to ... * hppa-bsd-tdep.c: ... this, adjust include. * hppabsd-tdep.h: Rename to ... * hppa-bsd-tdep.h: ... this, adjust include barrier and comment. * hppanbsd-nat.c: Rename to ... * hppa-nbsd-nat.c: ... this. * hppanbsd-tdep.c: Rename to ... * hppa-nbsd-tdep.c: ... this, adjust include. * hppaobsd-nat.c: Rename to ... * hppa-obsd-nat.c: ... this. * hppaobsd-tdep.c: Rename to ... * hppa-obsd-tdep.c: ... this, adjust include. * i386bsd-nat.c: Rename to ... * i386-bsd-nat.c: ... this, adjust include. * i386bsd-nat.h: Rename to ... * i386-bsd-nat.h: ... this, adjust include barrier and comment. * i386bsd-tdep.c: Rename to ... * i386-bsd-tdep.c: ... this. * i386fbsd-nat.c: Rename to ... * i386-fbsd-nat.c: ... this, adjust include. * i386fbsd-tdep.c: Rename to ... * i386-fbsd-tdep.c: ... this, adjust include. * i386fbsd-tdep.h: Rename to ... * i386-fbsd-tdep.h: ... this, adjust include barrier and comment. * i386gnu-nat.c: Rename to ... * i386-gnu-nat.c: ... this. * i386gnu-tdep.c: Rename to ... * i386-gnu-tdep.c: ... this. * i386nbsd-nat.c: Rename to ... * i386-nbsd-nat.c: ... this, adjust include. * i386nbsd-tdep.c: Rename to ... * i386-nbsd-tdep.c: ... this. * i386obsd-nat.c: Rename to ... * i386-obsd-nat.c: ... this, adjust include. * i386obsd-tdep.c: Rename to ... * i386-obsd-tdep.c: ... this. * i386v4-nat.c: Rename to ... * i386-v4-nat.c: ... this. * i386-tdep.h: Update comments. * m68k-tdep.h: Update comments. * m68kbsd-nat.c: Rename to ... * m68k-bsd-nat.c: ... this. * m68kbsd-tdep.c: Rename to ... * m68k-bsd-tdep.c: ... this. * m68klinux-nat.c: Rename to ... * m68k-linux-nat.c: ... this. * m68klinux-tdep.c: Rename to ... * m68k-linux-tdep.c: ... this. * m88kbsd-nat.c: Rename to ... * m88k-bsd-nat.c: ... this. * mipsnbsd-nat.c: Rename to ... * mips-nbsd-nat.c: ... this, adjust include. * mipsnbsd-tdep.c: Rename to ... * mips-nbsd-tdep.c: ... this, adjust include. * mipsnbsd-tdep.h: Rename to ... * mips-nbsd-tdep.h: ... this, adjust include barrier and comment. * mips64obsd-nat.c: Rename to ... * mips64-obsd-nat.c: ... this. * mips64obsd-tdep.c: Rename to ... * mips64-obsd-tdep.c: ... this. * ppcfbsd-nat.c: Rename to ... * ppc-fbsd-nat.c: ... this, adjust include. * ppcfbsd-tdep.c: Rename to ... * ppc-fbsd-tdep.c: ... this, adjust include. * ppcfbsd-tdep.h: Rename to ... * ppc-fbsd-tdep.h: ... this, adjust include barrier and comment. * ppcnbsd-nat.c: Rename to ... * ppc-nbsd-nat.c: ... this, adjust include. * ppcnbsd-tdep.c: Rename to ... * ppc-nbsd-tdep.c: ... this, adjust include. * ppcnbsd-tdep.h: Rename to ... * ppc-nbsd-tdep.h: ... this, adjust include barrier and comment. * ppcobsd-nat.c: Rename to ... * ppc-obsd-nat.c: ... this, adjust include. * ppcobsd-tdep.c: Rename to ... * ppc-obsd-tdep.c: ... this, adjust include. * ppcobsd-tdep.h: Rename to ... * ppc-obsd-tdep.h: ... this, adjust include barrier and comment. * shnbsd-nat.c: Rename to ... * sh-nbsd-nat.c: ... this. * shnbsd-tdep.c: Rename to ... * sh-nbsd-tdep.c: ... this. * sparcnbsd-nat.c: Rename to ... * sparc-nbsd-nat.c: ... this. * sparcnbsd-tdep.c: Rename to ... * sparc-nbsd-tdep.c: ... this. * sparcobsd-tdep.c: Rename to ... * sparc-obsd-tdep.c: ... this. * sparc64fbsd-nat.c: Rename to ... * sparc64-fbsd-nat.c: ... this. * sparc64fbsd-tdep.c: Rename to ... * sparc64-fbsd-tdep.c: ... this. * sparc64nbsd-nat.c: Rename to ... * sparc64-nbsd-nat.c: ... this. * sparc64nbsd-tdep.c: Rename to ... * sparc64-nbsd-tdep.c: ... this. * sparc64obsd-nat.c: Rename to ... * sparc64-obsd-nat.c: ... this. * sparc64obsd-tdep.c: Rename to ... * sparc64-obsd-tdep.c: ... this. * sparc64-tdep.h: Update comments. * vaxbsd-nat.c: Rename to ... * vax-bsd-nat.c: ... this. * vaxnbsd-tdep.c: Rename to ... * vax-nbsd-tdep.c: ... this. * vaxobsd-tdep.c: Rename to ... * vax-obsd-tdep.c: ... this. * x86bsd-nat.h: Rename to ... * x86-bsd-nat.h: ... this, adjust include barrier and comment. * x86bsd-nat.c: Rename to ... * x86-bsd-nat.c: ... this, adjust include. * configure.tgt: Update renamed files. * config/alpha/fbsd.mh: Update renamed files. * config/alpha/nbsd.mh: Update renamed files. * config/arm/nbsdelf.mh: Update renamed files. * config/djgpp/fnchange.lst: Update renamed files. * config/i386/fbsd.mh: Update renamed files. * config/i386/fbsd64.mh: Update renamed files. * config/i386/i386gnu.mh: Update renamed files. * config/i386/i386sol2.mh: Update renamed files. * config/i386/nbsd64.mh: Update renamed files. * config/i386/nbsdelf.mh: Update renamed files. * config/i386/obsd.mh: Update renamed files. * config/i386/obsd64.mh: Update renamed files. * config/i386/sol2-64.mh: Update renamed files. * config/m68k/linux.mh: Update renamed files. * config/m68k/nbsdelf.mh: Update renamed files. * config/m68k/obsd.mh: Update renamed files. * config/m88k/obsd.mh: Update renamed files. * config/mips/nbsd.mh: Update renamed files. * config/mips/obsd64.mh: Update renamed files. * config/pa/nbsd.mh: Update renamed files. * config/pa/obsd.mh: Update renamed files. * config/powerpc/fbsd.mh: Update renamed files. * config/powerpc/nbsd.mh: Update renamed files. * config/powerpc/obsd.mh: Update renamed files. * config/sh/nbsd.mh: Update renamed files. * config/sparc/fbsd.mh: Update renamed files. * config/sparc/nbsd64.mh: Update renamed files. * config/sparc/nbsdelf.mh: Update renamed files. * config/sparc/obsd64.mh: Update renamed files. * config/vax/nbsdelf.mh: Update renamed files. * config/vax/obsd.mh: Update renamed files. commit b593ecca856860a8b38deb808493bba4beef3aee Author: Simon Marchi Date: Tue Nov 22 16:14:22 2016 -0500 Makefiles: Flatten and sort file lists I find the big file lists in the Makefiles a bit ugly and not very practical. Since there are multiple filenames on each line (as much as fits in 80 columns), it's not easy to add, remove or change a name in the middle. As a result, we have a mix of long and short lines in no particular order (ALL_TARGET_OBS is a good example). I therefore suggest flattening the lists (one name per line) and keeping them in alphabetical order. The diffs will be much clearer and merge conflicts will be easier to resolve. A nice (IMO) side-effect I observed is that the files are compiled alphabetically by make, so it gives a rough idea of the progress of the build. I added a comment in gdb/Makefile.in to mention to keep the file lists ordered, and gave the general guidelines on what order to respect. I added a comment in other Makefiles which refers to gdb/Makefile.in, to avoid duplication. Running the patch through the buildbot found that gdb.base/default.exp started to fail. The languages in the error message shown when typing "set language" have changed order. We could probably improve gdb so that it prints them in a stable order, regardless of the order of the object list passed to the linked, but just fixing the test is easier for now. New in v2: - Change ordering style, directories go at the end. - Cleanup gdbserver's and data-directory's Makefile as well. - Add comments at top of Makefiles about the ordering. - Remove wrong trailing backslahes. - Fix test gdb.base/default.exp. gdb/ChangeLog: * Makefile.in: Add comment about file lists ordering. (SUBDIR_CLI_OBS, SUBDIR_CLI_SRCS, SUBDIR_MI_OBS, SUBDIR_MI_SRCS, SUBDIR_TUI_OBS, SUBDIR_TUI_SRCS, SUBDIR_GCC_COMPILE_OBS, SUBDIR_GCC_COMPILE_SRCS, SUBDIR_GUILE_OBS, SUBDIR_GUILE_SRCS, SUBDIR_PYTHON_OBS, SUBDIR_PYTHON_SRCS, SUBDIR_GDBTK_OBS, SUBDIR_GDBTK_SRCS, XMLFILES, REMOTE_OBS, ALL_64_TARGET_OBS, ALL_TARGET_OBS, SFILES, HFILES_NO_SRCDIR, HFILES_WITH_SRCDIR, COMMON_OBS, YYFILES, YYOBJ, generated_files, ALLDEPFILES): Flatten list and order alphabetically. * data-directory/Makefile.in: Add comment about file lists ordering. (GEN_SYSCALLS_FILES, PYTHON_FILE_LIST): Flatten list and order alphabetically. gdb/gdbserver/ChangeLog: * Makefile.in (SFILES, OBS): Flatten list and order alphabetically. gdb/testsuite/ChangeLog: * gdb.base/default.exp: Fix output of "set language". commit 1a9ccd70f9a75dc6b48d340059f28ef3550c107b Author: Nick Clifton Date: Wed Nov 23 11:10:39 2016 +0000 Fix the linker so that it will not silently generate ELF binaries with invalid program headers. Fix readelf to report such invalid binaries. PR ld/20815 bfd * elf.c (elf_modify_segment_map): Allow empty LOAD segments if they contain the program headers. (_bfd_elf_map_sections_to_segments): If the linker created the PHDR segment then always attempt to include it in a LOAD segment. (assign_file_positions_for_non_load_sections): Allow LOAD segments to overlap PHDR segments. (phdr_sorter): New function. Sorts program headers. (assign_file_positions_except_relocs): Sort the program headers before writing them out. Issue an error if the PHDR segment is not covered by a LOAD segment, unless the backend allows it. * elf-bfd.h (struct elf_backend_data): Add elf_backend_allow_non_load_phdr. * elfxx-target.h (elf_backend_allow_non_load_phdr): Provide default definition that returns FALSE. (elfNN_bed): Initialise the elf_backend_allow_non_load_phdr field. * elf64-hppa.c (elf64_hppa_allow_non_load_phdr): New function. Returns TRUE. (elf_backend_allow_non_load_phdr): Define. * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Do not place the interpreter string into the .interp section if the nointerp flag is set in the link info structure. * elf32-arc.c (elf_arc_size_dynamic_sections): Likewise. * elf32-score7.c (score_elf_final_link_relocate): Allow for the _gp symbol not being part of the output. binutils* readelf.c (process_program_headers): Check PT_LOAD and PT_PHDR segments for validity. ld * ld.texinfo: Note that PT_TLS can be used as a segment type. * testsuite/ld-discard/discard.ld: Add space for program headers. * testsuite/ld-elf/flags1.ld: Likewise. * testsuite/ld-elf/maxpage3.t: Likewise. * testsuite/ld-elf/noload-1.t: Likewise. * testsuite/ld-elf/orphan.ld: Likewise. * testsuite/ld-elf/overlay.t: Likewise. * testsuite/ld-elf/pr14052.t: Likewise. * testsuite/ld-elf/pr19539.t: Likewise. * testsuite/ld-elf/provide-hidden-1.ld: Likewise. * testsuite/ld-elf/provide-hidden-s.ld: Likewise. * testsuite/ld-elf/weak-dyn-1.ld: Likewise. * testsuite/ld-i386/pr19539.t: Likewise. * testsuite/ld-scripts/defined.t: Likewise. * testsuite/ld-scripts/defined6.t: Likewise. * testsuite/ld-scripts/dynamic-sections.t: Likewise. * testsuite/ld-scripts/empty-aligned.t: Likewise. * testsuite/ld-scripts/provide-2.t: Likewise. * testsuite/ld-scripts/provide-4.t: Likewise. * testsuite/ld-vax-elf/plt-local.ld: Likewise. * testsuite/ld-x86-64/pr19539.t: Likewise. * testsuite/ld-elf/ehdr_start-missing.d: Do not initialise the dynamic linker. * testsuite/ld-elf/ehdr_start-weak.d: Likewise. * testsuite/ld-elf/elf.exp (pr14170, pr17068): Likewise. * testsuite/ld-elf/loadaddr1.d: Update expected readelf output. * testsuite/ld-elf/noload-2.d: Likewise. * testsuite/ld-powerpc/vxworks2.sd: Likewise. * testsuite/ld-scripts/phdrs3a.d: Likewise. * testsuite/ld-scripts/size-2.d: Likewise. * testsuite/ld-elf/group.ld: Add program headers. * testsuite/ld-elf/overlay.d: Skip for SPU. * testsuite/ld-elf/flags1.d: Skip for RX. * testsuite/ld-elf/pr19162.d: Skip for HPPA64. * testsuite/ld-elf/pr19539.d: Skip for ALPHA. * testsuite/ld-scripts/empty-orphan.t: Update program headers. * testsuite/ld-scripts/size-2.t: Likewise. commit 128e85e3ab36b8e30f6612fb50de3cbb4ede6824 Author: Jose E. Marchesi Date: Wed Nov 23 03:04:17 2016 -0800 gas: run the hwcaps-bump tests with 64-bit sparc objects only. gas/ChangeLog: 2016-11-23 Jose E. Marchesi * testsuite/gas/sparc/sparc.exp (gas_64_check): Make sure the hwcaps-bump test is run with 64-bit objects. commit 073808edb771952247c6fe634b863986b7627150 Author: Kuan-Lin Chen Date: Wed Nov 23 13:18:59 2016 +0800 RISCV/GAS Add missing break in md_apply_fix. gdb/ChangeLog: * config/tc-riscv.c: Add missing break. commit 64f52338e924cce3a205527136e145da660a4686 Author: Alan Modra Date: Wed Nov 23 15:07:17 2016 +1030 elf_backend_dtrel_excludes_plt Now that all targets creating .rel.plt/.rela.plt use the ELF hash table shortcut srelplt, the generic ELF code can set up DT_RELSZ/ DT_RELASZ and DT_REL/DT_RELA for targets that don't want PLT relocs included in those tags. * elf-bfd.h (struct elf_backend_data): Add dtrel_excludes_plt. * elfxx-target.h (elf_backend_dtrel_excludes_plt): Define. (elfNN_bed): Init new field. * elflink.c (bfd_elf_final_link): Add and use htab variable. Handle dtrel_excludes_plt. * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-arc.c (elf_arc_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-arm.c (elf32_arm_finish_dynamic_sections): Delete code subtracting off plt relocs from DT_RELSZ, DT_RELASZ. (elf_backend_dtrel_excludes_plt): Define. * elf32-cr16.c (_bfd_cr16_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-cris.c (elf_cris_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Delete DT_RELASZ and DT_RELA code. (elf_backend_dtrel_excludes_plt): Define. * elf32-i386.c (elf_i386_finish_dynamic_sections): Delete DT_RELSZ and DT_REL code. (elf_backend_dtrel_excludes_plt): Define. * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-m32r.c (m32r_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-m68k.c (elf_m68k_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-metag.c (elf_metag_finish_dynamic_sections): Delete DT_RELASZ and DT_RELA code. (elf_backend_dtrel_excludes_plt): Define. * elf32-microblaze.c (microblaze_elf_finish_dynamic_sections): Delete DT_RELASZ and DT_RELA code. Use ELF htab shortcuts for other dynamic sections. (elf_backend_dtrel_excludes_plt): Define. * elf32-mips.c (elf_backend_dtrel_excludes_plt): Define. * elf32-nds32.c (nds32_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-or1k.c (or1k_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-sh.c (sh_elf_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-sparc.c (elf_backend_dtrel_excludes_plt): Define. * elf32-vax.c (elf_vax_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Delete DT_RELASZ and DT_RELA code. (elf_backend_dtrel_excludes_plt): Define. * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elfnn-ia64.c (elfNN_ia64_finish_dynamic_sections): Delete DT_RELASZ code. (elf_backend_dtrel_excludes_plt): Define. * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Delete DT_RELASZ code. * elfxx-sparc.c (sparc_finish_dyn): Delete DT_RELASZ code. commit ce558b89b15a18fd67fdc02a4d410a6d92d2ba63 Author: Alan Modra Date: Wed Nov 23 15:06:34 2016 +1030 Delete duplicate target short-cuts to dynamic sections We'd like to have the elf_link_hash_table srelplt field rather than some private target field used to save short-cuts to a PLT relocation section. This save a little space but mainly is so that the generic ELF code can access the field. Ditto for other dynamic sections. * elf-m10300.c (mn10300_elf_check_relocs): Use elf htab shortcuts to dynamic sections. (mn10300_elf_final_link_relocate): Likewise. (_bfd_mn10300_elf_adjust_dynamic_symbol): Likewise. (_bfd_mn10300_elf_size_dynamic_sections): Likewise. (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise. (_bfd_mn10300_elf_finish_dynamic_sections): Likewise. * elf32-bfin.c (bfin_check_relocs): Likewise. (bfin_relocate_section): Likewise. (bfin_gc_sweep_hook): Likewise. (struct bfinfdpic_elf_link_hash_table): Delete sgot, sgotrel, splt and spltrel. (bfinfdpic_got_section, bfinfdpic_gotrel_section, bfinfdpic_plt_section, bfinfdpic_pltrel_section): Define using elf shortcut sections. (_bfin_create_got_section): Use elf htab shortcuts to dyn sections. Delete dead code. (bfin_finish_dynamic_symbol): Use elf htab shortcuts to dyn sections. (bfin_size_dynamic_sections): Likewise. * elf32-cr16.c (_bfd_cr16_elf_create_got_section): Likewise. (cr16_elf_check_relocs): Likewise. (cr16_elf_final_link_relocate): Likewise. (_bfd_cr16_elf_create_dynamic_sections): Likewise. (_bfd_cr16_elf_adjust_dynamic_symbol): Likewise. (_bfd_cr16_elf_size_dynamic_sections): Likewise. (_bfd_cr16_elf_finish_dynamic_symbol): Likewise. (_bfd_cr16_elf_finish_dynamic_sections): Likewise. * elf32-cris.c (cris_elf_relocate_section): Likewise. (elf_cris_finish_dynamic_symbol): Likewise. (elf_cris_finish_dynamic_sections): Likewise. (cris_elf_gc_sweep_hook): Likewise. (elf_cris_adjust_gotplt_to_got): Likewise. (elf_cris_adjust_dynamic_symbol): Likewise. (cris_elf_check_relocs): Likewise. Delete dead code. (elf_cris_size_dynamic_sections): Use elf htab shortcuts to dynamic sections. (elf_cris_discard_excess_program_dynamics): Likewise. * elf32-frv.c (struct frvfdpic_elf_link_hash_table): Delete sgot, sgotrel, splt and spltrel. (frvfdpic_got_section, frvfdpic_gotrel_section, frvfdpic_plt_section, frvfdpic_pltrel_section): Define using elf shortcut sections. (_frv_create_got_section): Likewise. * elf32-hppa.c (struct elf32_hppa_link_hash_table): Delete sgot, srelgot, splt and srelplt. (hppa_build_one_stub): Use elf htab shortcuts to dynamic sections. (elf32_hppa_create_dynamic_sections): Likewise. (elf32_hppa_check_relocs): Likewise. (allocate_plt_static): Likewise. (allocate_dynrelocs): Likewise. (elf32_hppa_size_dynamic_sections): Likewise. (elf32_hppa_relocate_section): Likewise. (elf32_hppa_finish_dynamic_symbol): Likewise. (elf32_hppa_finish_dynamic_sections): Likewise. * elf32-i370.c (i370_elf_finish_dynamic_sections): Likewise. * elf32-lm32.c (struct elf_lm32_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. (lm32fdpic_got_section, lm32fdpic_gotrel_section): Define using elf shortcut sections. (create_got_section): Delete. Use _bfd_elf_create_got_section instead. (lm32_elf_relocate_section): Use elf htab shortcuts to dyn sections. (lm32_elf_check_relocs): Likewise. (lm32_elf_finish_dynamic_sections): Likewise. (lm32_elf_finish_dynamic_symbol): Likewise. (allocate_dynrelocs): Likewise. (lm32_elf_size_dynamic_sections): Likewise. (lm32_elf_create_dynamic_sections): Likewise. * elf32-m32c.c (m32c_elf_relocate_section): Likewise. (m32c_elf_check_relocs): Likewise. (m32c_elf_finish_dynamic_sections): Likewise. (m32c_elf_always_size_sections): Likewise. * elf32-m32r.c (struct elf_m32r_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. (create_got_section): Delete. Use _bfd_elf_create_got_section instead. (m32r_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic sections. (allocate_dynrelocs): Likewise. (m32r_elf_size_dynamic_sections): Likewise. (m32r_elf_relocate_section): Likewise. (m32r_elf_finish_dynamic_symbol): Likewise. (m32r_elf_finish_dynamic_sections): Likewise. (m32r_elf_check_relocs): Likewise. * elf32-m68k.c (elf_m68k_partition_multi_got): Likewise. (elf_m68k_check_relocs): Likewise. (elf_m68k_adjust_dynamic_symbol): Likewise. (elf_m68k_size_dynamic_sections): Likewise. (elf_m68k_relocate_section): Likewise. (elf_m68k_finish_dynamic_symbol): Likewise. (elf_m68k_finish_dynamic_sections): Likewise. * elf32-metag.c (struct elf_metag_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. (elf_metag_relocate_section): Use elf htab shortcuts to dynamic sections. (elf_metag_create_dynamic_sections): Likewise. Allocate got header here in .got. (elf_metag_check_relocs): Use elf htab shortcuts to dynamic sections. (allocate_dynrelocs): Likewise. (elf_metag_size_dynamic_sections): Likewise. (elf_metag_finish_dynamic_symbol): Likewise. (elf_metag_finish_dynamic_sections): Likewise. (elf_metag_size_stubs): Likewise. (elf_backend_got_header_size): Don't define. (elf_backend_want_got_plt): Define. * elf32-microblaze.c (struct elf32_mb_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelpl. (microblaze_elf_relocate_section): Use elf htab shortcuts to dynamic sections. (create_got_section): Delete. Use _bfd_elf_create_got_section instead. (microblaze_elf_check_relocs): Use elf htab shortcuts to dyn sections. (microblaze_elf_create_dynamic_sections): Likewise. (allocate_dynrelocs): Likewise. (microblaze_elf_size_dynamic_sections): Likewise. (microblaze_elf_finish_dynamic_symbol): Likewise. (microblaze_elf_finish_dynamic_sections): Likewise. * elf32-nds32.c (nds32_elf_link_hash_table_create): Don't NULL already zero fields. (create_got_section): Delete. Use _bfd_elf_create_got_section instead. (nds32_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic sections. (allocate_dynrelocs): Likewise. (nds32_elf_size_dynamic_sections): Likewise. (nds32_elf_relocate_section): Likewise. (nds32_elf_finish_dynamic_symbol): Likewise. (nds32_elf_finish_dynamic_sections): Likewise. (nds32_elf_check_relocs): Likewise. (calculate_plt_memory_address): Likewise. (calculate_got_memory_address): Likewise. * elf32-nds32.h (struct elf_nds32_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. * elf32-or1k.c (struct elf_or1k_link_hash_table): Likewise. (or1k_elf_relocate_section): Use elf htab shortcuts to dyn sections. (create_got_section): Delete. Use _bfd_elf_create_got_section instead. (or1k_elf_check_relocs): Use elf htab shortcuts to dynamic sections. (or1k_elf_finish_dynamic_sections): Likewise. (or1k_elf_finish_dynamic_symbol): Likewise. (allocate_dynrelocs): Likewise. (or1k_elf_size_dynamic_sections): Likewise. (or1k_elf_create_dynamic_sections): Likewise. * elf32-ppc.c (struct ppc_elf_link_hash_table): Delete got, relgot, plt, relplt, iplt, reliplt and sgotplt. (ppc_elf_create_got): Use elf htab shortcuts to dynamic sections. (ppc_elf_create_glink): Likewise. (ppc_elf_create_dynamic_sections): Likewise. (ppc_elf_check_relocs): Likewise. (ppc_elf_select_plt_layout): Likewise. (ppc_elf_tls_setup): Likewise. (allocate_got): Likewise. (allocate_dynrelocs): Likewise. (ppc_elf_size_dynamic_sections): Likewise. (ppc_elf_relax_section): Likewise. (ppc_elf_relocate_section): Likewise. (ppc_elf_finish_dynamic_symbol): Likewise. (ppc_elf_reloc_type_class): Likewise. (ppc_elf_finish_dynamic_sections): Likewise. * elf32-rl78.c (rl78_elf_relocate_section): Likewise. (rl78_elf_check_relocs): Likewise. (rl78_elf_finish_dynamic_sections): Likewise. (rl78_elf_always_size_sections): Likewise. * elf32-s390.c (create_got_section): Delete. (elf_s390_create_dynamic_sections): Use _bfd_elf_create_got_section. (elf_s390_check_relocs): Likewise. * elf32-score.c (score_elf_create_got_section): Set elf shortcuts. (s3_bfd_score_elf_finish_dynamic_sections): Use elf shortcuts. * elf32-score7.c (score_elf_create_got_section): As above. (s7_bfd_score_elf_finish_dynamic_sections): As above. * elf32-sh.c (struct elf_sh_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. (create_got_section): Don't set them. (sh_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic sections. (allocate_dynrelocs): Likewise. (sh_elf_size_dynamic_sections): Likewise. (sh_elf_add_rofixup): Likewise. (sh_elf_relocate_section): Likewise. (sh_elf_check_relocs): Likewise. (sh_elf_finish_dynamic_symbol): Likewise. (sh_elf_finish_dynamic_sections): Likewise. * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise. * elf32-tilepro.c (tilepro_elf_create_got_section): Likewise. * elf32-vax.c (elf_vax_check_relocs): Likewise. (elf_vax_adjust_dynamic_symbol): Likewise. (elf_vax_always_size_sections): Likewise. (elf_vax_instantiate_got_entries): Likewise. (elf_vax_relocate_section): Likewise. (elf_vax_finish_dynamic_symbol): Likewise. (elf_vax_finish_dynamic_sections): Likewise. * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise. (xstormy16_elf_always_size_sections): Likewise. (xstormy16_elf_relocate_section): Likewise. (xstormy16_elf_finish_dynamic_sections): Likewise. * elf32-xtensa.c (struct elf_xtensa_link_hash_table): Delete sgot, sgotplt, srelgot, splt and srelplt. (elf_xtensa_create_dynamic_sections): Use elf htab shortcuts to dynamic sections. (elf_xtensa_allocate_dynrelocs): Likewise. (elf_xtensa_allocate_local_got_size): Likewise. (elf_xtensa_size_dynamic_sections): Likewise. (elf_xtensa_relocate_section): Likewise. (elf_xtensa_finish_dynamic_sections): Likewise. (shrink_dynamic_reloc_sections): Likewise. (elf_xtensa_get_plt_section): Likewise. (elf_xtensa_get_gotplt_section): Likewise. (xtensa_callback_required_dependence): Likewise. * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Set elf htab shortcuts to dynamic sections. (elf64_alpha_adjust_dynamic_symbol): Use elf htab shortcuts to dynamic sections. (elf64_alpha_size_plt_section): Likewise. (elf64_alpha_size_rela_got_1): Likewise. (elf64_alpha_size_rela_got_section): Likewise. (elf64_alpha_relocate_section): Likewise. (elf64_alpha_finish_dynamic_symbol): Likewise. (elf64_alpha_finish_dynamic_sections): Likewise. * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise. * elf64-s390.c (create_got_section): Delete. (elf_s390_create_dynamic_sections): Use _bfd_elf_create_got_section. (elf_s390_check_relocs): Likewise. * elf64-sh64.c (sh_elf64_relocate_section): Use elf htab shortcuts to dynamic sections. (sh_elf64_check_relocs): Likewise. (sh64_elf64_adjust_dynamic_symbol): Likewise. (sh64_elf64_size_dynamic_sections): Likewise. (sh64_elf64_finish_dynamic_symbol): Likewise. (sh64_elf64_finish_dynamic_sections): Likewise. * elflink.c (_bfd_elf_create_got_section): Likewise. * elfnn-aarch64.c (aarch64_elf_create_got_section): Likewise. * elfnn-ia64.c (elfNN_ia64_size_dynamic_sections): Likewise. (elfNN_ia64_finish_dynamic_sections): Likewise. * elfnn-riscv.c (riscv_elf_create_got_section): Likewise. * elfxx-mips.c (struct mips_elf_link_hash_table): Delete srellt, sgotplt, splt and sgot. (mips_elf_initialize_tls_slots): Use elf htab shortcuts to dynamic sections. (mips_elf_gotplt_index): Likewise. (mips_elf_primary_global_got_index): Likewise. (mips_elf_global_got_index): Likewise. (mips_elf_got_offset_from_index): Likewise. (mips_elf_create_local_got_entry): Likewise. (mips_elf_create_got_section): Likewise. (mips_elf_calculate_relocation): Likewise. (_bfd_mips_elf_create_dynamic_sections): Likewise. (_bfd_mips_elf_adjust_dynamic_symbol): Likewise. (mips_elf_lay_out_got): Likewise. (mips_elf_set_plt_sym_value): Likewise. (_bfd_mips_elf_size_dynamic_sections): Likewise. (_bfd_mips_elf_finish_dynamic_symbol): Likewise. (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise. (mips_finish_exec_plt): Likewise. (mips_vxworks_finish_exec_plt): Likewise. (mips_vxworks_finish_shared_plt): Likewise. (_bfd_mips_elf_finish_dynamic_sections): Likewise. * elfxx-sparc.c (sparc_finish_dyn): Likewise. * elfxx-tilegx.c (tilegx_elf_create_got_section): Likewise. commit 3ae0486cdce5d2ed4c922c598a3258fcbd9c8f29 Author: Alan Modra Date: Wed Nov 23 15:04:24 2016 +1030 Regen POTFILES.in bfd/ * po/BLD-POTFILES.in: Regenerate. * po/SRC-POTFILES.in: Regenerate. gas/ * po/POTFILES.in: Regenerate. commit 9986ba08876f86f7d36d230afc11b60a34287da8 Author: Pedro Alves Date: Thu Nov 17 23:15:34 2016 +0000 gdbserver: Use warning for warnings gdb/gdbserver/ChangeLog: 2016-11-23 Pedro Alves * event-loop.c (handle_file_event): Use warning. * linux-low.c (linux_resume_one_lwp_throw): Use warning. * mem-break.c (add_breakpoint_condition, add_breakpoint_commands): Use warning. commit 4eefa7bcf286b879f61b9e1ec1c97230f5345104 Author: Pedro Alves Date: Fri Nov 18 00:07:10 2016 +0000 gdbserver: Use debug_printf for debug output gdb/gdbserver/ChangeLog: 2016-11-23 Pedro Alves * linux-low.c (check_zombie_leaders): Use debug_printf for debug output. * notif.c (handle_notif_ack, notif_event_enque): Likewise. * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use debug_printf and debug_flush for debug output. * server.c (handle_general_set): Likewise. * thread-db.c (try_thread_db_load): Use debug_printf for debug output. commit 400b2f29938dab7d9c4f46c9d1b0dc23dab0518b Author: GDB Administrator Date: Wed Nov 23 00:00:36 2016 +0000 Automatic date update in version.in commit 358a971863e93cbafa9e864b4db4d5448b960304 Author: Cary Coutant Date: Tue Nov 22 15:44:56 2016 -0800 Print the default for all binary options; clean up --help output. gold/ PR gold/20346 * options.cc (One_option::print): Print "(default)" when appropriate. * options.h: Clean up and re-sort options. (One_option::is_default): New data member. (One_option::One_option): Add is_default parameter; adjust all calls. (DEFINE_var): Add is_default__ parameter; adjust all calls. (DEFINE_bool): Set is_default based on default_value__. (DEFINE_bool_ignore): New macro. (--no-eh-frame-hdr): New option. (--enable-new-dtags): Remove mention of DT_FLAGS. commit ca3cbe5cd7715d1559d55f8e71be1dd7340f13b1 Author: Ambrogino Modigliani Date: Tue Nov 22 16:05:00 2016 +0000 Fix spelling mistakes in comments in shell scripts gdb/ChangeLog: 2016-11-22 Ambrogino Modigliani * contrib/expect-read1.sh: Fix spelling in comments. * gdb_buildall.sh: Fix spelling in comments. * gdb_mbuild.sh: Fix spelling in comments. commit 96fe45624e51f1bb747e36cf8bdaab216f31c5ec Author: Ambrogino Modigliani Date: Tue Nov 22 15:43:03 2016 +0000 Fix spelling mistakes in comments in configure scripts All changes are limited to comments, and no run-time behavior is affected. bfd/ChangeLog: 2016-11-22 Ambrogino Modigliani * warning.m4: Fix spelling in comments. * configure.ac: Fix spelling in comments. * configure: Regenerate. binutils/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. gdb/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure.ac: Fix spelling in comments. * configure: Regenerate. gas/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. gold/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. gprof/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. ld/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. opcodes/ChangeLog: 2016-11-22 Ambrogino Modigliani * configure: Regenerate. commit f5ea389ac78ccd7c426a93f43e6117dad9ce0878 Author: Yao Qi Date: Tue Nov 22 14:05:06 2016 +0000 Change gdbarch software_single_step frame_info to regcache This patch changes gdbarch method software_single_step's parameter from "struct frame_info *" to "struct regcache *, IOW, software_single_step starts to use current regcache rather than current frame for software single. gdb: 2016-11-22 Yao Qi * gdbarch.sh (software_single_step): Change parameter from frame_info to regcache. * gdbarch.c, gdbarch.h: Regenerated. * aarch64-tdep.c (aarch64_software_single_step): Change parameter from frame_info to regcache. Don't call get_current_regcache. * alpha-tdep.c (alpha_deal_with_atomic_sequence): Likewise. (alpha_software_single_step): Likewise. * alpha-tdep.h (alpha_software_single_step): Update declaration. * arm-linux-tdep.c (arm_linux_software_single_step): Likewise. * arm-tdep.c (arm_software_single_step): Likewise. * arm-tdep.h (arm_software_single_step): Likewise. * breakpoint.c (insert_single_step_breakpoint): Pass regcache to gdbarch_software_single_step. * cris-tdep.c (cris_software_single_step): Change parameter from frame_info to regcache. Don't call get_current_regcache. * mips-tdep.c (mips_software_single_step): Likewise. * mips-tdep.h (mips_software_single_step): Update declaration. * moxie-tdep.c (moxie_software_single_step): Likewise. * nios2-tdep.c (nios2_software_single_step): Likewise. * ppc-tdep.h (ppc_deal_with_atomic_sequence): Update declaration. * rs6000-aix-tdep.c (rs6000_software_single_step): Likewise. * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Likewise. * s390-linux-tdep.c (s390_software_single_step): Likewise. * sparc-tdep.c (sparc_software_single_step): Likewise. * spu-tdep.c (spu_software_single_step): Likewise. * tic6x-tdep.c (tic6x_software_single_step): Likewise. commit b2260160f8cde8de118914ddeaf797bea42e65ce Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: spu gdb: 2016-11-22 Yao Qi * spu-tdep.c (spu_software_single_step): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. commit fb090cfa157e35fac1c10c062fd005e38b894ea4 Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: tic6x gdb: 2016-11-22 Yao Qi * tic6x-tdep.c (tic6x_condition_true): Replace frame with regcache. Call regcache_raw_get_signed instead of get_frame_register_signed. (tic6x_get_next_pc): Likewise. Caller updated. commit 41e26ad32d17ee35f79f629654811f5e8656cab8 Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: rs6000 gdb: 2016-11-22 Yao Qi * rs6000-aix-tdep.c (branch_dest): Replace parameter frame with regcache. Call get_regcache_arch instead of get_frame_arch. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. (rs6000_software_single_step): Likewise. * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. commit ad76968956f30bed6d120e0dfd247034e0855fea Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: s390 gdb: 2016-11-22 Yao Qi * s390-linux-tdep.c (s390_software_single_step): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. commit cd76b525eda02c30c4412698a2ff309b975d417a Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: sparc gdb: 2016-11-22 Yao Qi * sparc-tdep.c (sparc_analyze_control_transfer): Replace parameter frame with regcache. Call get_current_frame. (sparc_software_single_step): Call get_regcache_arch instead of get_frame_arch. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. commit 3889f4909e0db5f5ca8ca043ef9825f0ad971fd6 Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: nios2 gdb: 2016-11-22 Yao Qi * nios2-tdep.c (nios2_get_next_pc): Replace parameter frame with regcache. Call regcache_raw_get_signed instead of get_frame_register_unsigned. (nios2_software_single_step): Call get_regcache_arch instead of get_frame_arch. commit a8f341826d63a5c216c41e10bf1e4e6c3db3ce65 Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: moxie gdb: 2016-11-22 Yao Qi * moxie-tdep.c (moxie_software_single_step): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. commit 7113a196bac7f1134bcdd79ad3e6badcb5d77f95 Author: Yao Qi Date: Tue Nov 22 14:05:05 2016 +0000 gdbarch software_single_step frame_info to regcache: mips gdb: 2016-11-22 Yao Qi * mips-tdep.c (mips32_bc1_pc): Replace parameter frame with regcache. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. (mips32_next_pc): Likewise. (micromips_bc1_pc): Likewise. (micromips_next_pc): Likewise. (extended_mips16_next_pc): Likewise. (mips16_next_pc): Likewise. (mips_next_pc): Likewise. (mips_software_single_step): Call get_regcache_arch instead of get_frame_arch. commit 5b6e2eee087cf206d5c2bf1f9523217aaf5938aa Author: Yao Qi Date: Tue Nov 22 14:05:04 2016 +0000 gdbarch software_single_step frame_info to regcache: cris gdb: 2016-11-22 Yao Qi * cris-tdep.c (find_step_target): Replace parameter frame with regcache. Call get_regcache_arch instead of get_frame_arch. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. (cris_software_single_step): Call get_regcache_arch instead of get_frame_arch. commit 7ab2d0874025af6ee858b32c576f2461c0a1df3d Author: Yao Qi Date: Tue Nov 22 14:05:04 2016 +0000 gdbarch software_single_step frame_info to regcache: alpha gdb: 2016-11-22 Yao Qi * alpha-tdep.c (alpha_deal_with_atomic_sequence): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. (alpha_next_pc): Replace parameter frame with regcache. Call regcache_raw_get_unsigned instead of get_frame_register_unsigned. commit 0187a92f57b516f7171e70bec46701cfdaa6c6bd Author: Yao Qi Date: Tue Nov 22 14:05:04 2016 +0000 gdbarch software_single_step frame_info to regcache: aarch64 Use regcache in software_single_step. gdb: 2016-11-22 Yao Qi * aarch64-tdep.c (aarch64_software_single_step): Call get_regcache_arch instead of get_frame_arch. Call regcache_read_pc instead of get_frame_pc. commit 9fd15b2e80452f03edb3fb36c2b4c36d05f4ef4e Author: Yao Qi Date: Tue Nov 22 14:05:04 2016 +0000 New regcache_raw_get_signed This patch adds a new regcache api regcache_raw_get_signed. gdb: 2016-11-22 Yao Qi * regcache.c (regcache_raw_get_signed): New function. * regcache.h (regcache_raw_get_signed): Declare. commit 6884417a0ff3555b192d4aceeacc5e7232cad207 Author: Jose E. Marchesi Date: Tue Nov 22 04:40:37 2016 -0800 gas,opcodes: fix hardware capabilities bumping in the sparc assembler. When the assembler finds an instruction which is part of a higher opcode architecture it bumps the current opcode architecture. For example: $ echo "mwait" | as -bump {standard input}: Assembler messages: {standard input}:1: Warning: architecture bumped from "v6" to "v9m" on "mwait" However, when two instructions pertaining to the same opcode architecture but associated to different SPARC hardware capabilities are found in the input stream, and no GAS architecture is specified in the command line, the assembler bangs: $ echo "mwait; wr %g0,%g1,%mcdper" | as -bump {standard input}: Assembler messages: {standard input}:1: Warning: architecture bumped from "v6" to "v9m" on "mwait" {standard input}:1: Error: Hardware capability "sparc5" not enabled for "wr". ... and it should'nt, as WRMCDPER pertains to the same architecture level than MWAIT. This patch fixes this by extending the definition of sparc opcode architectures to contain a set of hardware capabilities and making the assembler to take these capabilities into account when updating the set of allowed hwcaps when an architecture bump is triggered by some instruction. This way, hwcaps associated to architecture levels are maintained in opcodes, while the assembler keeps the flexibiity of defining GAS architectures including additional hwcaps (like -Asparcfmaf or the v8plus* variants). A test covering this failure case is included. gas/ChangeLog: 2016-11-22 Jose E. Marchesi * config/tc-sparc.c: Move HWS_* and HWS2_* definitions to opcodes/sparc-opc.c. (sparc_arch): Clarify the new role of the hwcap_allowed and hwcap2_allowed fields. (sparc_arch_table): Remove HWS_* and HWS2_* instances from hwcap_allowed and hwcap2_allowed respectively. (md_parse_option): Include the opcode arch hwcaps when processing -A. (sparc_ip): Use the current opcode arch hwcaps to update hwcap_allowed, as well of the hwcaps of the instruction triggering the bump. * testsuite/gas/sparc/hwcaps-bump.s: New file. * testsuite/gas/sparc/hwcaps-bump.l: Likewise. * testsuite/gas/sparc/sparc.exp (gas_64_check): Run tests in hwcaps-bump. include/ChangeLog: 2016-11-22 Jose E. Marchesi * opcode/sparc.h (sparc_opcode_arch): New fields hwcaps and hwcaps2. opcodes/ChangeLog: 2016-11-22 Jose E. Marchesi * sparc-opc.c (HWS_V8): Definition moved from gas/config/tc-sparc.c. (HWS_V9): Likewise. (HWS_VA): Likewise. (HWS_VB): Likewise. (HWS_VC): Likewise. (HWS_VD): Likewise. (HWS_VE): Likewise. (HWS_VV): Likewise. (HWS_VM): Likewise. (HWS2_VM): Likewise. (sparc_opcode_archs): Initialize hwcaps and hwcaps2 fields of existing entries. commit c4b943d7aed5edbfc31aa1e9dc9e7bcf108d76a0 Author: Claudiu Zissulescu Date: Wed Nov 9 15:30:35 2016 +0100 [ARC] Fix printing 'b' mnemonics. gas/ 2016-11-22 Claudiu Zissulescu * testsuite/gas/arc/b.d: Update test result. opcode/ 2016-11-22 Claudiu Zissulescu * arc-tbl.h: Reorder conditional flags with delay flags for 'b' instructions. commit 08dc996fedde9143cda25720961684087b133640 Author: Alan Modra Date: Tue Nov 22 18:45:29 2016 +1030 PR20744, Incorrect PowerPC VLE relocs VLE 16A and 16D relocs were functionally swapped. PR 20744 include/ * opcode/ppc.h: Define VLE insns using 16A and 16D relocs. bfd/ * elf32-ppc.h (struct ppc_elf_params): Add vle_reloc_fixup field. * elf32-ppc.c: Include opcode/ppc.h. (ppc_elf_howto_raw): Correct dst_mask for R_PPC_VLE_LO16A, R_PPC_VLE_LO16D, R_PPC_VLE_HI16A, R_PPC_VLE_HI16D, R_PPC_VLE_HA16A, R_PPC_VLE_HA16D, R_PPC_VLE_SDAREL_LO16A, R_PPC_VLE_SDAREL_LO16D, R_PPC_VLE_SDAREL_HI16A, R_PPC_VLE_SDAREL_HI16D, R_PPC_VLE_SDAREL_HA16A, and R_PPC_VLE_SDAREL_HA16D relocs. (ppc_elf_link_hash_table_create): Update default_params init. (ppc_elf_vle_split16): Correct shift and mask. Add params. Report or fix insn/reloc mismatches. (ppc_elf_relocate_section): Pass input_section, offset and fixup to ppc_elf_vle_split16. binutils/ * NEWS: Mention PowerPC VLE relocation error. gas/ * config/tc-ppc.c: Delete VLE insn defines. (md_assemble): Swap use_a_reloc and use_d_reloc. * testsuite/gas/ppc/vle-reloc.d: Update. ld/ * emultempl/ppc32elf.em (params): Update initializer. Handle --vle-reloc-fixup command line arg. commit 95f0d0d2338f8eba18d2b3c8cbe15b1d584b885c Author: Alan Modra Date: Tue Nov 22 16:27:12 2016 +1030 Use input_bfd in relocate_section It makes just a little more sense to use input_bfd when retrieving insns for relocation, since the relocations match the endianness of the input bfd. * elf32-ppc.c (ppc64_elf_relocate_section): Calculate d_offset for input_bfd. Replace occurrences of output_bfd as bfd_get_32 and bfd_put_32 param with input_bfd. * elf32-ppc.c (ppc_elf_relocate_section): Likewise. Also ppc_elf_vle_split16 param. (ppc_elf_vle_split16): Rename output_bfd param to input_bfd. commit c5acd8159633cfde315b01431099e1ce5b23dcf7 Author: Yao Qi Date: Tue Nov 22 08:53:34 2016 +0000 Use VALUE_NEXT_FRAME_ID in value_from_component We renamed VALUE_FRAME_ID to VALUE_NEXT_FRAME_ID recently, https://sourceware.org/ml/gdb-patches/2016-11/msg00018.html and we should use VALUE_NEXT_FRAME_ID in value_from_component too. gdb: 2016-11-22 Yao Qi * value.c (value_from_component): Use VALUE_NEXT_FRAME_ID instead of VALUE_FROM_ID. commit 3063babf7c559f04203ad7fdfcd8fc12a302ee7a Author: GDB Administrator Date: Tue Nov 22 00:00:15 2016 +0000 Automatic date update in version.in commit c13b08dbbcf752480a7621aa1f89bc5440c74c25 Author: Cary Coutant Date: Mon Nov 21 14:05:40 2016 -0800 Fix bug where -u option with empty archive results in internal error. gold/ PR gold/20693 * gold.cc (queue_middle_tasks): Force valid target earlier. commit d0de53e251ce60057d91536a4c71740b047be040 Author: Simon Marchi Date: Mon Nov 21 16:05:57 2016 -0500 Add missing POSTCOMPILE step to mi/ file generation rules A little oversight from my part, it caused the Makefile not to track the dependencies from mi/*.c files. gdb/ChangeLog: * Makefile.in (%o: $(srcdir)/mi/%.c): Add missing POSTCOMPILE step. commit b32e1756d9932eebcca5f276290841a859ef2d6d Author: Igor Kudrin Date: Mon Nov 21 09:59:37 2016 -0800 Add --build-id=uuid support for MinGW32. 2016-11-21 Igor Kudrin gold/ * layout.cc: Include windows.h and rpcdce.h (for MinGW32). (Layout::create_build_id): Generate uuid using UuidCreate(). commit b6ddcd85e3c0ae1f12af60efd6d1b97ac4bfa771 Author: Maciej W. Rozycki Date: Mon Nov 21 15:59:42 2016 +0000 BFD/DWARF2: Correct an `index' global shadowing error Fix a commit 089e3718bd8d ("Greatly improve the speed if looking up DWARF line number information.") build regression: cc1: warnings being treated as errors .../bfd/dwarf2.c: In function 'build_line_info_table': .../bfd/dwarf2.c:1614: warning: declaration of 'index' shadows a global declaration /usr/include/string.h:304: warning: shadowed declaration is here .../bfd/dwarf2.c: In function 'build_lookup_funcinfo_table': .../bfd/dwarf2.c:2262: warning: declaration of 'index' shadows a global declaration /usr/include/string.h:304: warning: shadowed declaration is here make[4]: *** [dwarf2.lo] Error 1 in a way following commit 91d6fa6a035c ("Add -Wshadow to the gcc command line options used when compiling the binutils."). bfd/ * dwarf2.c (build_line_info_table): Rename `index' local variable to `line_index'. (build_lookup_funcinfo_table): Rename `index' local variable to `func_index'. commit 3fff9862d5229def9318912c2de64a03dab74532 Author: Yao Qi Date: Mon Nov 21 14:15:06 2016 +0000 Create subobject value in pretty printer Nowadays, we create a value of subobject in pretty printer with 'address' being used, value = value_from_contents_and_address (type, valaddr + embedded_offset, address + embedded_offset); set_value_component_location (value, val); /* set_value_component_location resets the address, so we may need to set it again. */ if (VALUE_LVAL (value) != lval_internalvar && VALUE_LVAL (value) != lval_internalvar_component && VALUE_LVAL (value) != lval_computed) set_value_address (value, address + embedded_offset); value_from_contents_and_address creates a value from memory, but the value we are pretty-printing may not from memory at all. Instead of using value_from_contents_and_address, we create a value of subobject with the same location as object's but different offset. We avoid using address in this way. As a result, parameter 'address' in apply_val_pretty_printer is no longer needed, we can remove it in next step. We've already had the location of the 'whole' value, so it is safe to assume we can create a value of 'component' or 'suboject' value at the same location but with different offset. gdb: 2016-11-21 Yao Qi * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Don't call value_from_contents_and_address and set_value_address. Call value_from_component. * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Likewise. * value.c (value_from_component): New function. * value.h (value_from_component): Likewise. * valarith.c (value_subscripted_rvalue): Call value_from_component. commit 5689c9424b33aac68c4762ce0bda09ca7e3affe0 Author: Renlin Li Date: Mon Nov 21 12:06:04 2016 +0000 [GAS][ARM][PR20827]Fix gas error for two register form instruction (pre-UAL syntax). gas/ 2016-11-21 Renlin Li PR gas/20827 * config/tc-arm.c (encode_arm_shift): Don't assert for operands not presented. * testsuite/gas/arm/add-shift-two.d: New. * testsuite/gas/arm/add-shift-two.s: New. commit 2d7f2507d4d26430da7e32e8fc75f045f634fced Author: Alan Modra Date: Mon Nov 21 20:18:41 2016 +1030 Use ACX_PROG_CMP_IGNORE_INITIAL in gas * configure.ac: Invoke ACX_PROG_CMP_IGNORE_INITIAL. * Makefile.am (comparison): Rewrite using do_compare. * configure: Regenerate. * Makefile.in: Regenerate. * doc/Makefile.in: Regenerate. commit 081f6b931dbc4a1f27ac003e2f75a389444ce9e9 Author: GDB Administrator Date: Mon Nov 21 00:00:33 2016 +0000 Automatic date update in version.in ----------------------------------------------------------------------- Summary of changes: bfd/ChangeLog | 416 ++++++ bfd/configure | 4 +- bfd/configure.ac | 2 +- bfd/dwarf2.c | 20 +- bfd/elf-bfd.h | 9 + bfd/elf-m10300.c | 66 +- bfd/elf.c | 125 ++- bfd/elf32-arc.c | 10 +- bfd/elf32-arm.c | 29 +- bfd/elf32-bfin.c | 88 +- bfd/elf32-cr16.c | 80 +- bfd/elf32-cris.c | 147 +-- bfd/elf32-frv.c | 31 +- bfd/elf32-hppa.c | 194 ++-- bfd/elf32-i370.c | 44 +- bfd/elf32-i386.c | 26 +- bfd/elf32-lm32.c | 128 +-- bfd/elf32-m32c.c | 37 +- bfd/elf32-m32r.c | 114 +-- bfd/elf32-m68k.c | 130 +-- bfd/elf32-metag.c | 204 ++-- bfd/elf32-microblaze.c | 282 ++--- bfd/elf32-mips.c | 2 + bfd/elf32-nds32.c | 136 +-- bfd/elf32-nds32.h | 5 - bfd/elf32-nios2.c | 15 +- bfd/elf32-or1k.c | 138 +-- bfd/elf32-ppc.c | 503 ++++---- bfd/elf32-ppc.h | 3 + bfd/elf32-rl78.c | 36 +- bfd/elf32-s390.c | 27 +- bfd/elf32-score.c | 7 +- bfd/elf32-score7.c | 16 +- bfd/elf32-sh.c | 161 +-- bfd/elf32-sparc.c | 2 + bfd/elf32-tic6x.c | 6 +- bfd/elf32-tilepro.c | 3 +- bfd/elf32-vax.c | 105 +-- bfd/elf32-xstormy16.c | 40 +- bfd/elf32-xtensa.c | 93 +- bfd/elf64-alpha.c | 51 +- bfd/elf64-hppa.c | 34 +- bfd/elf64-ppc.c | 86 +- bfd/elf64-s390.c | 30 +- bfd/elf64-sh64.c | 116 +-- bfd/elf64-x86-64.c | 16 +- bfd/elfcode.h | 4 +- bfd/elflink.c | 75 +- bfd/elfnn-aarch64.c | 19 +- bfd/elfnn-ia64.c | 19 +- bfd/elfnn-riscv.c | 3 +- bfd/elfxx-mips.c | 184 ++-- bfd/elfxx-sparc.c | 53 +- bfd/elfxx-target.h | 10 + bfd/elfxx-tilegx.c | 3 +- bfd/po/BLD-POTFILES.in | 2 + bfd/po/SRC-POTFILES.in | 2 + bfd/version.h | 2 +- bfd/warning.m4 | 2 +- binutils/ChangeLog | 15 + binutils/NEWS | 15 +- binutils/configure | 2 +- binutils/readelf.c | 41 +- gas/ChangeLog | 62 + gas/Makefile.am | 18 +- gas/Makefile.in | 19 +- gas/config/tc-arm.c | 7 +- gas/config/tc-ppc.c | 20 +- gas/config/tc-riscv.c | 1 + gas/config/tc-sparc.c | 112 +- gas/configure | 37 +- gas/configure.ac | 1 + gas/doc/Makefile.in | 1 + gas/po/POTFILES.in | 2 + gas/testsuite/gas/arc/b.d | 4 +- gas/testsuite/gas/arm/add-shift-two.d | 11 + gas/testsuite/gas/arm/add-shift-two.s | 5 + gas/testsuite/gas/ppc/vle-reloc.d | 146 +- gas/testsuite/gas/sparc/hwcaps-bump.l | 2 + gas/testsuite/gas/sparc/hwcaps-bump.s | 5 + gas/testsuite/gas/sparc/sparc.exp | 1 + gdb/ChangeLog | 428 ++++++ gdb/Makefile.in | 1640 +++++++++++++++++------ gdb/aarch64-tdep.c | 6 +- gdb/{alphabsd-nat.c => alpha-bsd-nat.c} | 2 +- gdb/{alphabsd-tdep.c => alpha-bsd-tdep.c} | 2 +- gdb/{alphabsd-tdep.h => alpha-bsd-tdep.h} | 8 +- gdb/{alphafbsd-tdep.c => alpha-fbsd-tdep.c} | 0 gdb/{alphanbsd-tdep.c => alpha-nbsd-tdep.c} | 2 +- gdb/{alphaobsd-tdep.c => alpha-obsd-tdep.c} | 2 +- gdb/alpha-tdep.c | 22 +- gdb/alpha-tdep.h | 2 +- gdb/{amd64bsd-nat.c => amd64-bsd-nat.c} | 2 +- gdb/{amd64fbsd-nat.c => amd64-fbsd-nat.c} | 4 +- gdb/{amd64fbsd-tdep.c => amd64-fbsd-tdep.c} | 2 +- gdb/{amd64nbsd-nat.c => amd64-nbsd-nat.c} | 0 gdb/{amd64nbsd-tdep.c => amd64-nbsd-tdep.c} | 0 gdb/{amd64obsd-nat.c => amd64-obsd-nat.c} | 0 gdb/{amd64obsd-tdep.c => amd64-obsd-tdep.c} | 0 gdb/amd64-tdep.h | 6 +- gdb/{armbsd-tdep.c => arm-bsd-tdep.c} | 0 gdb/arm-linux-tdep.c | 3 +- gdb/{armnbsd-nat.c => arm-nbsd-nat.c} | 0 gdb/{armnbsd-tdep.c => arm-nbsd-tdep.c} | 0 gdb/{armobsd-tdep.c => arm-obsd-tdep.c} | 0 gdb/arm-tdep.c | 3 +- gdb/arm-tdep.h | 4 +- gdb/breakpoint.c | 5 +- gdb/common/run-time-clock.c | 58 + gdb/common/run-time-clock.h | 75 + gdb/config/alpha/fbsd.mh | 2 +- gdb/config/alpha/nbsd.mh | 2 +- gdb/config/arm/nbsdelf.mh | 2 +- gdb/config/djgpp/fnchange.lst | 96 +- gdb/config/i386/fbsd.mh | 4 +- gdb/config/i386/fbsd64.mh | 4 +- gdb/config/i386/i386gnu.mh | 2 +- gdb/config/i386/i386sol2.mh | 2 +- gdb/config/i386/nbsd64.mh | 2 +- gdb/config/i386/nbsdelf.mh | 2 +- gdb/config/i386/obsd.mh | 2 +- gdb/config/i386/obsd64.mh | 2 +- gdb/config/i386/sol2-64.mh | 2 +- gdb/config/m68k/linux.mh | 2 +- gdb/config/m68k/nbsdelf.mh | 2 +- gdb/config/m68k/obsd.mh | 2 +- gdb/config/m88k/obsd.mh | 2 +- gdb/config/mips/nbsd.mh | 2 +- gdb/config/mips/obsd64.mh | 2 +- gdb/config/pa/nbsd.mh | 2 +- gdb/config/pa/obsd.mh | 2 +- gdb/config/powerpc/fbsd.mh | 2 +- gdb/config/powerpc/nbsd.mh | 2 +- gdb/config/powerpc/obsd.mh | 2 +- gdb/config/sh/nbsd.mh | 2 +- gdb/config/sparc/fbsd.mh | 2 +- gdb/config/sparc/nbsd64.mh | 2 +- gdb/config/sparc/nbsdelf.mh | 2 +- gdb/config/sparc/obsd64.mh | 2 +- gdb/config/vax/nbsdelf.mh | 2 +- gdb/config/vax/obsd.mh | 2 +- gdb/configure | 2 +- gdb/configure.ac | 2 +- gdb/configure.tgt | 80 +- gdb/contrib/expect-read1.sh | 2 +- gdb/cris-tdep.c | 14 +- gdb/data-directory/Makefile.in | 39 +- gdb/defs.h | 14 - gdb/event-loop.c | 94 +- gdb/gdb_buildall.sh | 2 +- gdb/gdb_mbuild.sh | 4 +- gdb/gdbarch.c | 4 +- gdb/gdbarch.h | 4 +- gdb/gdbarch.sh | 2 +- gdb/gdbserver/ChangeLog | 36 + gdb/gdbserver/Makefile.in | 170 ++- gdb/gdbserver/debug.c | 16 +- gdb/gdbserver/event-loop.c | 2 +- gdb/gdbserver/linux-low.c | 13 +- gdb/gdbserver/mem-break.c | 6 +- gdb/gdbserver/notif.c | 8 +- gdb/gdbserver/remote-utils.c | 32 +- gdb/gdbserver/server.c | 17 +- gdb/gdbserver/thread-db.c | 3 +- gdb/gdbserver/tracepoint.c | 10 +- gdb/guile/scm-pretty-print.c | 11 +- gdb/{hppabsd-tdep.c => hppa-bsd-tdep.c} | 2 +- gdb/{hppabsd-tdep.h => hppa-bsd-tdep.h} | 6 +- gdb/{hppanbsd-nat.c => hppa-nbsd-nat.c} | 0 gdb/{hppanbsd-tdep.c => hppa-nbsd-tdep.c} | 2 +- gdb/{hppaobsd-nat.c => hppa-obsd-nat.c} | 0 gdb/{hppaobsd-tdep.c => hppa-obsd-tdep.c} | 2 +- gdb/{i386bsd-nat.c => i386-bsd-nat.c} | 6 +- gdb/{i386bsd-nat.h => i386-bsd-nat.h} | 6 +- gdb/{i386bsd-tdep.c => i386-bsd-tdep.c} | 0 gdb/{i386fbsd-nat.c => i386-fbsd-nat.c} | 4 +- gdb/{i386fbsd-tdep.c => i386-fbsd-tdep.c} | 2 +- gdb/{i386fbsd-tdep.h => i386-fbsd-tdep.h} | 6 +- gdb/{i386gnu-nat.c => i386-gnu-nat.c} | 0 gdb/{i386gnu-tdep.c => i386-gnu-tdep.c} | 0 gdb/{i386nbsd-nat.c => i386-nbsd-nat.c} | 2 +- gdb/{i386nbsd-tdep.c => i386-nbsd-tdep.c} | 0 gdb/{i386obsd-nat.c => i386-obsd-nat.c} | 2 +- gdb/{i386obsd-tdep.c => i386-obsd-tdep.c} | 0 gdb/i386-tdep.h | 2 +- gdb/{i386v4-nat.c => i386-v4-nat.c} | 0 gdb/{m68kbsd-nat.c => m68k-bsd-nat.c} | 0 gdb/{m68kbsd-tdep.c => m68k-bsd-tdep.c} | 0 gdb/{m68klinux-nat.c => m68k-linux-nat.c} | 0 gdb/{m68klinux-tdep.c => m68k-linux-tdep.c} | 0 gdb/m68k-tdep.h | 2 +- gdb/{m88kbsd-nat.c => m88k-bsd-nat.c} | 0 gdb/maint.c | 31 +- gdb/maint.h | 7 +- gdb/mi/mi-main.c | 73 +- gdb/mi/mi-parse.h | 12 +- gdb/{mipsnbsd-nat.c => mips-nbsd-nat.c} | 2 +- gdb/{mipsnbsd-tdep.c => mips-nbsd-tdep.c} | 2 +- gdb/{mipsnbsd-tdep.h => mips-nbsd-tdep.h} | 6 +- gdb/mips-tdep.c | 141 +- gdb/mips-tdep.h | 2 +- gdb/{mips64obsd-nat.c => mips64-obsd-nat.c} | 0 gdb/{mips64obsd-tdep.c => mips64-obsd-tdep.c} | 0 gdb/moxie-tdep.c | 7 +- gdb/nios2-tdep.c | 26 +- gdb/{ppcfbsd-nat.c => ppc-fbsd-nat.c} | 2 +- gdb/{ppcfbsd-tdep.c => ppc-fbsd-tdep.c} | 2 +- gdb/{ppcfbsd-tdep.h => ppc-fbsd-tdep.h} | 8 +- gdb/{ppcnbsd-nat.c => ppc-nbsd-nat.c} | 2 +- gdb/{ppcnbsd-tdep.c => ppc-nbsd-tdep.c} | 2 +- gdb/{ppcnbsd-tdep.h => ppc-nbsd-tdep.h} | 6 +- gdb/{ppcobsd-nat.c => ppc-obsd-nat.c} | 2 +- gdb/{ppcobsd-tdep.c => ppc-obsd-tdep.c} | 2 +- gdb/{ppcobsd-tdep.h => ppc-obsd-tdep.h} | 6 +- gdb/ppc-tdep.h | 2 +- gdb/python/py-prettyprint.c | 11 +- gdb/regcache.c | 13 + gdb/regcache.h | 6 + gdb/rs6000-aix-tdep.c | 35 +- gdb/rs6000-tdep.c | 7 +- gdb/s390-linux-tdep.c | 7 +- gdb/{shnbsd-nat.c => sh-nbsd-nat.c} | 0 gdb/{shnbsd-tdep.c => sh-nbsd-tdep.c} | 0 gdb/{sparcnbsd-nat.c => sparc-nbsd-nat.c} | 0 gdb/{sparcnbsd-tdep.c => sparc-nbsd-tdep.c} | 0 gdb/{sparcobsd-tdep.c => sparc-obsd-tdep.c} | 0 gdb/sparc-tdep.c | 18 +- gdb/{sparc64fbsd-nat.c => sparc64-fbsd-nat.c} | 0 gdb/{sparc64fbsd-tdep.c => sparc64-fbsd-tdep.c} | 0 gdb/{sparc64nbsd-nat.c => sparc64-nbsd-nat.c} | 0 gdb/{sparc64nbsd-tdep.c => sparc64-nbsd-tdep.c} | 0 gdb/{sparc64obsd-nat.c => sparc64-obsd-nat.c} | 0 gdb/{sparc64obsd-tdep.c => sparc64-obsd-tdep.c} | 0 gdb/sparc64-tdep.h | 4 +- gdb/spu-tdep.c | 10 +- gdb/symfile.c | 39 +- gdb/testsuite/ChangeLog | 4 + gdb/testsuite/gdb.base/default.exp | 2 +- gdb/tic6x-tdep.c | 24 +- gdb/utils.c | 58 +- gdb/utils.h | 3 +- gdb/valarith.c | 17 +- gdb/value.c | 25 + gdb/value.h | 2 + gdb/{vaxbsd-nat.c => vax-bsd-nat.c} | 0 gdb/{vaxnbsd-tdep.c => vax-nbsd-tdep.c} | 0 gdb/{vaxobsd-tdep.c => vax-obsd-tdep.c} | 0 gdb/{x86bsd-nat.c => x86-bsd-nat.c} | 2 +- gdb/{x86bsd-nat.h => x86-bsd-nat.h} | 6 +- gold/ChangeLog | 27 + gold/configure | 2 +- gold/gold.cc | 16 +- gold/layout.cc | 25 + gold/options.cc | 8 +- gold/options.h | 522 +++++--- gprof/ChangeLog | 4 + gprof/configure | 2 +- include/ChangeLog | 10 + include/opcode/ppc.h | 17 + include/opcode/sparc.h | 4 + ld/ChangeLog | 53 + ld/configure | 2 +- ld/emultempl/ppc32elf.em | 11 +- ld/ld.texinfo | 3 + ld/testsuite/ld-arm/vxworks2.sd | 2 +- ld/testsuite/ld-discard/discard.ld | 1 + ld/testsuite/ld-elf/ehdr_start-missing.d | 2 +- ld/testsuite/ld-elf/ehdr_start-weak.d | 2 +- ld/testsuite/ld-elf/elf.exp | 4 +- ld/testsuite/ld-elf/flags1.d | 1 + ld/testsuite/ld-elf/flags1.ld | 1 + ld/testsuite/ld-elf/group.ld | 8 +- ld/testsuite/ld-elf/loadaddr1.d | 2 +- ld/testsuite/ld-elf/maxpage3.t | 1 + ld/testsuite/ld-elf/noload-1.t | 1 + ld/testsuite/ld-elf/noload-2.d | 2 +- ld/testsuite/ld-elf/orphan.ld | 1 + ld/testsuite/ld-elf/overlay.d | 2 + ld/testsuite/ld-elf/overlay.t | 3 +- ld/testsuite/ld-elf/pr14052.t | 1 + ld/testsuite/ld-elf/pr19162.d | 2 +- ld/testsuite/ld-elf/pr19539.d | 2 +- ld/testsuite/ld-elf/pr19539.t | 5 + ld/testsuite/ld-elf/provide-hidden-1.ld | 1 + ld/testsuite/ld-elf/provide-hidden-s.ld | 1 + ld/testsuite/ld-elf/weak-dyn-1.ld | 1 + ld/testsuite/ld-i386/pr19539.t | 5 + ld/testsuite/ld-powerpc/vxworks2.sd | 2 +- ld/testsuite/ld-scripts/defined.t | 1 + ld/testsuite/ld-scripts/defined6.t | 1 + ld/testsuite/ld-scripts/dynamic-sections.t | 1 + ld/testsuite/ld-scripts/empty-aligned.t | 1 + ld/testsuite/ld-scripts/empty-orphan.t | 6 +- ld/testsuite/ld-scripts/phdrs3a.d | 2 +- ld/testsuite/ld-scripts/provide-2.t | 1 + ld/testsuite/ld-scripts/provide-4.t | 1 + ld/testsuite/ld-scripts/size-2.d | 4 +- ld/testsuite/ld-scripts/size-2.t | 4 +- ld/testsuite/ld-vax-elf/plt-local.ld | 2 +- ld/testsuite/ld-x86-64/pr19539.t | 5 + opcodes/ChangeLog | 25 + opcodes/arc-tbl.h | 2 +- opcodes/configure | 2 +- opcodes/sparc-opc.c | 49 +- 304 files changed, 5399 insertions(+), 3892 deletions(-) create mode 100644 gas/testsuite/gas/arm/add-shift-two.d create mode 100644 gas/testsuite/gas/arm/add-shift-two.s create mode 100644 gas/testsuite/gas/sparc/hwcaps-bump.l create mode 100644 gas/testsuite/gas/sparc/hwcaps-bump.s rename gdb/{alphabsd-nat.c => alpha-bsd-nat.c} (99%) rename gdb/{alphabsd-tdep.c => alpha-bsd-tdep.c} (98%) rename gdb/{alphabsd-tdep.h => alpha-bsd-tdep.h} (91%) rename gdb/{alphafbsd-tdep.c => alpha-fbsd-tdep.c} (100%) rename gdb/{alphanbsd-tdep.c => alpha-nbsd-tdep.c} (99%) rename gdb/{alphaobsd-tdep.c => alpha-obsd-tdep.c} (99%) rename gdb/{amd64bsd-nat.c => amd64-bsd-nat.c} (99%) rename gdb/{amd64fbsd-nat.c => amd64-fbsd-nat.c} (98%) rename gdb/{amd64fbsd-tdep.c => amd64-fbsd-tdep.c} (99%) rename gdb/{amd64nbsd-nat.c => amd64-nbsd-nat.c} (100%) rename gdb/{amd64nbsd-tdep.c => amd64-nbsd-tdep.c} (100%) rename gdb/{amd64obsd-nat.c => amd64-obsd-nat.c} (100%) rename gdb/{amd64obsd-tdep.c => amd64-obsd-tdep.c} (100%) rename gdb/{armbsd-tdep.c => arm-bsd-tdep.c} (100%) rename gdb/{armnbsd-nat.c => arm-nbsd-nat.c} (100%) rename gdb/{armnbsd-tdep.c => arm-nbsd-tdep.c} (100%) rename gdb/{armobsd-tdep.c => arm-obsd-tdep.c} (100%) create mode 100644 gdb/common/run-time-clock.c create mode 100644 gdb/common/run-time-clock.h mode change 100644 => 100755 gdb/contrib/expect-read1.sh rename gdb/{hppabsd-tdep.c => hppa-bsd-tdep.c} (99%) rename gdb/{hppabsd-tdep.h => hppa-bsd-tdep.h} (91%) rename gdb/{hppanbsd-nat.c => hppa-nbsd-nat.c} (100%) rename gdb/{hppanbsd-tdep.c => hppa-nbsd-tdep.c} (99%) rename gdb/{hppaobsd-nat.c => hppa-obsd-nat.c} (100%) rename gdb/{hppaobsd-tdep.c => hppa-obsd-tdep.c} (99%) rename gdb/{i386bsd-nat.c => i386-bsd-nat.c} (98%) rename gdb/{i386bsd-nat.h => i386-bsd-nat.h} (92%) rename gdb/{i386bsd-tdep.c => i386-bsd-tdep.c} (100%) rename gdb/{i386fbsd-nat.c => i386-fbsd-nat.c} (99%) rename gdb/{i386fbsd-tdep.c => i386-fbsd-tdep.c} (99%) rename gdb/{i386fbsd-tdep.h => i386-fbsd-tdep.h} (93%) rename gdb/{i386gnu-nat.c => i386-gnu-nat.c} (100%) rename gdb/{i386gnu-tdep.c => i386-gnu-tdep.c} (100%) rename gdb/{i386nbsd-nat.c => i386-nbsd-nat.c} (99%) rename gdb/{i386nbsd-tdep.c => i386-nbsd-tdep.c} (100%) rename gdb/{i386obsd-nat.c => i386-obsd-nat.c} (99%) rename gdb/{i386obsd-tdep.c => i386-obsd-tdep.c} (100%) rename gdb/{i386v4-nat.c => i386-v4-nat.c} (100%) rename gdb/{m68kbsd-nat.c => m68k-bsd-nat.c} (100%) rename gdb/{m68kbsd-tdep.c => m68k-bsd-tdep.c} (100%) rename gdb/{m68klinux-nat.c => m68k-linux-nat.c} (100%) rename gdb/{m68klinux-tdep.c => m68k-linux-tdep.c} (100%) rename gdb/{m88kbsd-nat.c => m88k-bsd-nat.c} (100%) rename gdb/{mipsnbsd-nat.c => mips-nbsd-nat.c} (99%) rename gdb/{mipsnbsd-tdep.c => mips-nbsd-tdep.c} (99%) rename gdb/{mipsnbsd-tdep.h => mips-nbsd-tdep.h} (93%) rename gdb/{mips64obsd-nat.c => mips64-obsd-nat.c} (100%) rename gdb/{mips64obsd-tdep.c => mips64-obsd-tdep.c} (100%) rename gdb/{ppcfbsd-nat.c => ppc-fbsd-nat.c} (99%) rename gdb/{ppcfbsd-tdep.c => ppc-fbsd-tdep.c} (99%) rename gdb/{ppcfbsd-tdep.h => ppc-fbsd-tdep.h} (89%) rename gdb/{ppcnbsd-nat.c => ppc-nbsd-nat.c} (99%) rename gdb/{ppcnbsd-tdep.c => ppc-nbsd-tdep.c} (99%) rename gdb/{ppcnbsd-tdep.h => ppc-nbsd-tdep.h} (93%) rename gdb/{ppcobsd-nat.c => ppc-obsd-nat.c} (99%) rename gdb/{ppcobsd-tdep.c => ppc-obsd-tdep.c} (99%) rename gdb/{ppcobsd-tdep.h => ppc-obsd-tdep.h} (95%) rename gdb/{shnbsd-nat.c => sh-nbsd-nat.c} (100%) rename gdb/{shnbsd-tdep.c => sh-nbsd-tdep.c} (100%) rename gdb/{sparcnbsd-nat.c => sparc-nbsd-nat.c} (100%) rename gdb/{sparcnbsd-tdep.c => sparc-nbsd-tdep.c} (100%) rename gdb/{sparcobsd-tdep.c => sparc-obsd-tdep.c} (100%) rename gdb/{sparc64fbsd-nat.c => sparc64-fbsd-nat.c} (100%) rename gdb/{sparc64fbsd-tdep.c => sparc64-fbsd-tdep.c} (100%) rename gdb/{sparc64nbsd-nat.c => sparc64-nbsd-nat.c} (100%) rename gdb/{sparc64nbsd-tdep.c => sparc64-nbsd-tdep.c} (100%) rename gdb/{sparc64obsd-nat.c => sparc64-obsd-nat.c} (100%) rename gdb/{sparc64obsd-tdep.c => sparc64-obsd-tdep.c} (100%) rename gdb/{vaxbsd-nat.c => vax-bsd-nat.c} (100%) rename gdb/{vaxnbsd-tdep.c => vax-nbsd-tdep.c} (100%) rename gdb/{vaxobsd-tdep.c => vax-obsd-tdep.c} (100%) rename gdb/{x86bsd-nat.c => x86-bsd-nat.c} (99%) rename gdb/{x86bsd-nat.h => x86-bsd-nat.h} (93%) First 500 lines of diff: diff --git a/bfd/ChangeLog b/bfd/ChangeLog index f28351d..346ff29 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,419 @@ +2016-11-23 Nick Clifton + + PR ld/20815 + * elf.c (elf_modify_segment_map): Allow empty LOAD segments if + they contain the program headers. + (_bfd_elf_map_sections_to_segments): If the linker created the + PHDR segment then always attempt to include it in a LOAD segment. + (assign_file_positions_for_non_load_sections): Allow LOAD segments + to overlap PHDR segments. + (phdr_sorter): New function. Sorts program headers. + (assign_file_positions_except_relocs): Sort the program headers + before writing them out. Issue an error if the PHDR segment is + not covered by a LOAD segment, unless the backend allows it. + * elf-bfd.h (struct elf_backend_data): Add + elf_backend_allow_non_load_phdr. + * elfxx-target.h (elf_backend_allow_non_load_phdr): Provide + default definition that returns FALSE. + (elfNN_bed): Initialise the elf_backend_allow_non_load_phdr + field. + * elf64-hppa.c (elf64_hppa_allow_non_load_phdr): New function. + Returns TRUE. + (elf_backend_allow_non_load_phdr): Define. + * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Do not + place the interpreter string into the .interp section if the + nointerp flag is set in the link info structure. + * elf32-arc.c (elf_arc_size_dynamic_sections): Likewise. + * elf32-score7.c (score_elf_final_link_relocate): Allow for the + _gp symbol not being part of the output. + +2016-11-23 Alan Modra + + * elf-bfd.h (struct elf_backend_data): Add dtrel_excludes_plt. + * elfxx-target.h (elf_backend_dtrel_excludes_plt): Define. + (elfNN_bed): Init new field. + * elflink.c (bfd_elf_final_link): Add and use htab variable. Handle + dtrel_excludes_plt. + * elf-m10300.c (_bfd_mn10300_elf_finish_dynamic_sections): Delete + DT_RELASZ code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-arc.c (elf_arc_finish_dynamic_sections): Delete DT_RELASZ code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-arm.c (elf32_arm_finish_dynamic_sections): Delete code + subtracting off plt relocs from DT_RELSZ, DT_RELASZ. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-cr16.c (_bfd_cr16_elf_finish_dynamic_sections): Delete + DT_RELASZ code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-cris.c (elf_cris_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Delete DT_RELASZ + and DT_RELA code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-i386.c (elf_i386_finish_dynamic_sections): Delete DT_RELSZ + and DT_REL code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-lm32.c (lm32_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-m32r.c (m32r_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-m68k.c (elf_m68k_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-metag.c (elf_metag_finish_dynamic_sections): Delete DT_RELASZ + and DT_RELA code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-microblaze.c (microblaze_elf_finish_dynamic_sections): Delete + DT_RELASZ and DT_RELA code. Use ELF htab shortcuts for other + dynamic sections. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-mips.c (elf_backend_dtrel_excludes_plt): Define. + * elf32-nds32.c (nds32_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-nios2.c (nios2_elf32_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-or1k.c (or1k_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-ppc.c (ppc_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-sh.c (sh_elf_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-sparc.c (elf_backend_dtrel_excludes_plt): Define. + * elf32-vax.c (elf_vax_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf32-xtensa.c (elf_xtensa_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Delete DT_RELASZ + and DT_RELA code. + (elf_backend_dtrel_excludes_plt): Define. + * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elf64-x86-64.c (elf_x86_64_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elfnn-aarch64.c (elfNN_aarch64_finish_dynamic_sections): Delete + DT_RELASZ code. + (elf_backend_dtrel_excludes_plt): Define. + * elfnn-ia64.c (elfNN_ia64_finish_dynamic_sections): Delete DT_RELASZ + code. + (elf_backend_dtrel_excludes_plt): Define. + * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections): Delete + DT_RELASZ code. + * elfxx-sparc.c (sparc_finish_dyn): Delete DT_RELASZ code. + +2016-11-23 Alan Modra + + * elf-m10300.c (mn10300_elf_check_relocs): Use elf htab shortcuts + to dynamic sections. + (mn10300_elf_final_link_relocate): Likewise. + (_bfd_mn10300_elf_adjust_dynamic_symbol): Likewise. + (_bfd_mn10300_elf_size_dynamic_sections): Likewise. + (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise. + (_bfd_mn10300_elf_finish_dynamic_sections): Likewise. + * elf32-bfin.c (bfin_check_relocs): Likewise. + (bfin_relocate_section): Likewise. + (bfin_gc_sweep_hook): Likewise. + (struct bfinfdpic_elf_link_hash_table): Delete sgot, sgotrel, splt + and spltrel. + (bfinfdpic_got_section, bfinfdpic_gotrel_section, + bfinfdpic_plt_section, bfinfdpic_pltrel_section): Define using elf + shortcut sections. + (_bfin_create_got_section): Use elf htab shortcuts to dyn sections. + Delete dead code. + (bfin_finish_dynamic_symbol): Use elf htab shortcuts to dyn sections. + (bfin_size_dynamic_sections): Likewise. + * elf32-cr16.c (_bfd_cr16_elf_create_got_section): Likewise. + (cr16_elf_check_relocs): Likewise. + (cr16_elf_final_link_relocate): Likewise. + (_bfd_cr16_elf_create_dynamic_sections): Likewise. + (_bfd_cr16_elf_adjust_dynamic_symbol): Likewise. + (_bfd_cr16_elf_size_dynamic_sections): Likewise. + (_bfd_cr16_elf_finish_dynamic_symbol): Likewise. + (_bfd_cr16_elf_finish_dynamic_sections): Likewise. + * elf32-cris.c (cris_elf_relocate_section): Likewise. + (elf_cris_finish_dynamic_symbol): Likewise. + (elf_cris_finish_dynamic_sections): Likewise. + (cris_elf_gc_sweep_hook): Likewise. + (elf_cris_adjust_gotplt_to_got): Likewise. + (elf_cris_adjust_dynamic_symbol): Likewise. + (cris_elf_check_relocs): Likewise. Delete dead code. + (elf_cris_size_dynamic_sections): Use elf htab shortcuts to dynamic + sections. + (elf_cris_discard_excess_program_dynamics): Likewise. + * elf32-frv.c (struct frvfdpic_elf_link_hash_table): Delete sgot, + sgotrel, splt and spltrel. + (frvfdpic_got_section, frvfdpic_gotrel_section, + frvfdpic_plt_section, frvfdpic_pltrel_section): Define using elf + shortcut sections. + (_frv_create_got_section): Likewise. + * elf32-hppa.c (struct elf32_hppa_link_hash_table): Delete sgot, + srelgot, splt and srelplt. + (hppa_build_one_stub): Use elf htab shortcuts to dynamic sections. + (elf32_hppa_create_dynamic_sections): Likewise. + (elf32_hppa_check_relocs): Likewise. + (allocate_plt_static): Likewise. + (allocate_dynrelocs): Likewise. + (elf32_hppa_size_dynamic_sections): Likewise. + (elf32_hppa_relocate_section): Likewise. + (elf32_hppa_finish_dynamic_symbol): Likewise. + (elf32_hppa_finish_dynamic_sections): Likewise. + * elf32-i370.c (i370_elf_finish_dynamic_sections): Likewise. + * elf32-lm32.c (struct elf_lm32_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + (lm32fdpic_got_section, lm32fdpic_gotrel_section): Define using elf + shortcut sections. + (create_got_section): Delete. Use _bfd_elf_create_got_section instead. + (lm32_elf_relocate_section): Use elf htab shortcuts to dyn sections. + (lm32_elf_check_relocs): Likewise. + (lm32_elf_finish_dynamic_sections): Likewise. + (lm32_elf_finish_dynamic_symbol): Likewise. + (allocate_dynrelocs): Likewise. + (lm32_elf_size_dynamic_sections): Likewise. + (lm32_elf_create_dynamic_sections): Likewise. + * elf32-m32c.c (m32c_elf_relocate_section): Likewise. + (m32c_elf_check_relocs): Likewise. + (m32c_elf_finish_dynamic_sections): Likewise. + (m32c_elf_always_size_sections): Likewise. + * elf32-m32r.c (struct elf_m32r_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + (create_got_section): Delete. Use _bfd_elf_create_got_section instead. + (m32r_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic + sections. + (allocate_dynrelocs): Likewise. + (m32r_elf_size_dynamic_sections): Likewise. + (m32r_elf_relocate_section): Likewise. + (m32r_elf_finish_dynamic_symbol): Likewise. + (m32r_elf_finish_dynamic_sections): Likewise. + (m32r_elf_check_relocs): Likewise. + * elf32-m68k.c (elf_m68k_partition_multi_got): Likewise. + (elf_m68k_check_relocs): Likewise. + (elf_m68k_adjust_dynamic_symbol): Likewise. + (elf_m68k_size_dynamic_sections): Likewise. + (elf_m68k_relocate_section): Likewise. + (elf_m68k_finish_dynamic_symbol): Likewise. + (elf_m68k_finish_dynamic_sections): Likewise. + * elf32-metag.c (struct elf_metag_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + (elf_metag_relocate_section): Use elf htab shortcuts to dynamic + sections. + (elf_metag_create_dynamic_sections): Likewise. Allocate got header + here in .got. + (elf_metag_check_relocs): Use elf htab shortcuts to dynamic sections. + (allocate_dynrelocs): Likewise. + (elf_metag_size_dynamic_sections): Likewise. + (elf_metag_finish_dynamic_symbol): Likewise. + (elf_metag_finish_dynamic_sections): Likewise. + (elf_metag_size_stubs): Likewise. + (elf_backend_got_header_size): Don't define. + (elf_backend_want_got_plt): Define. + * elf32-microblaze.c (struct elf32_mb_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelpl. + (microblaze_elf_relocate_section): Use elf htab shortcuts to dynamic + sections. + (create_got_section): Delete. Use _bfd_elf_create_got_section instead. + (microblaze_elf_check_relocs): Use elf htab shortcuts to dyn sections. + (microblaze_elf_create_dynamic_sections): Likewise. + (allocate_dynrelocs): Likewise. + (microblaze_elf_size_dynamic_sections): Likewise. + (microblaze_elf_finish_dynamic_symbol): Likewise. + (microblaze_elf_finish_dynamic_sections): Likewise. + * elf32-nds32.c (nds32_elf_link_hash_table_create): Don't NULL + already zero fields. + (create_got_section): Delete. Use _bfd_elf_create_got_section instead. + (nds32_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic + sections. + (allocate_dynrelocs): Likewise. + (nds32_elf_size_dynamic_sections): Likewise. + (nds32_elf_relocate_section): Likewise. + (nds32_elf_finish_dynamic_symbol): Likewise. + (nds32_elf_finish_dynamic_sections): Likewise. + (nds32_elf_check_relocs): Likewise. + (calculate_plt_memory_address): Likewise. + (calculate_got_memory_address): Likewise. + * elf32-nds32.h (struct elf_nds32_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + * elf32-or1k.c (struct elf_or1k_link_hash_table): Likewise. + (or1k_elf_relocate_section): Use elf htab shortcuts to dyn sections. + (create_got_section): Delete. Use _bfd_elf_create_got_section instead. + (or1k_elf_check_relocs): Use elf htab shortcuts to dynamic sections. + (or1k_elf_finish_dynamic_sections): Likewise. + (or1k_elf_finish_dynamic_symbol): Likewise. + (allocate_dynrelocs): Likewise. + (or1k_elf_size_dynamic_sections): Likewise. + (or1k_elf_create_dynamic_sections): Likewise. + * elf32-ppc.c (struct ppc_elf_link_hash_table): Delete got, relgot, + plt, relplt, iplt, reliplt and sgotplt. + (ppc_elf_create_got): Use elf htab shortcuts to dynamic sections. + (ppc_elf_create_glink): Likewise. + (ppc_elf_create_dynamic_sections): Likewise. + (ppc_elf_check_relocs): Likewise. + (ppc_elf_select_plt_layout): Likewise. + (ppc_elf_tls_setup): Likewise. + (allocate_got): Likewise. + (allocate_dynrelocs): Likewise. + (ppc_elf_size_dynamic_sections): Likewise. + (ppc_elf_relax_section): Likewise. + (ppc_elf_relocate_section): Likewise. + (ppc_elf_finish_dynamic_symbol): Likewise. + (ppc_elf_reloc_type_class): Likewise. + (ppc_elf_finish_dynamic_sections): Likewise. + * elf32-rl78.c (rl78_elf_relocate_section): Likewise. + (rl78_elf_check_relocs): Likewise. + (rl78_elf_finish_dynamic_sections): Likewise. + (rl78_elf_always_size_sections): Likewise. + * elf32-s390.c (create_got_section): Delete. + (elf_s390_create_dynamic_sections): Use _bfd_elf_create_got_section. + (elf_s390_check_relocs): Likewise. + * elf32-score.c (score_elf_create_got_section): Set elf shortcuts. + (s3_bfd_score_elf_finish_dynamic_sections): Use elf shortcuts. + * elf32-score7.c (score_elf_create_got_section): As above. + (s7_bfd_score_elf_finish_dynamic_sections): As above. + * elf32-sh.c (struct elf_sh_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + (create_got_section): Don't set them. + (sh_elf_create_dynamic_sections): Use elf htab shortcuts to dynamic + sections. + (allocate_dynrelocs): Likewise. + (sh_elf_size_dynamic_sections): Likewise. + (sh_elf_add_rofixup): Likewise. + (sh_elf_relocate_section): Likewise. + (sh_elf_check_relocs): Likewise. + (sh_elf_finish_dynamic_symbol): Likewise. + (sh_elf_finish_dynamic_sections): Likewise. + * elf32-tic6x.c (elf32_tic6x_finish_dynamic_symbol): Likewise. + * elf32-tilepro.c (tilepro_elf_create_got_section): Likewise. + * elf32-vax.c (elf_vax_check_relocs): Likewise. + (elf_vax_adjust_dynamic_symbol): Likewise. + (elf_vax_always_size_sections): Likewise. + (elf_vax_instantiate_got_entries): Likewise. + (elf_vax_relocate_section): Likewise. + (elf_vax_finish_dynamic_symbol): Likewise. + (elf_vax_finish_dynamic_sections): Likewise. + * elf32-xstormy16.c (xstormy16_elf_check_relocs): Likewise. + (xstormy16_elf_always_size_sections): Likewise. + (xstormy16_elf_relocate_section): Likewise. + (xstormy16_elf_finish_dynamic_sections): Likewise. + * elf32-xtensa.c (struct elf_xtensa_link_hash_table): Delete sgot, + sgotplt, srelgot, splt and srelplt. + (elf_xtensa_create_dynamic_sections): Use elf htab shortcuts to + dynamic sections. + (elf_xtensa_allocate_dynrelocs): Likewise. + (elf_xtensa_allocate_local_got_size): Likewise. + (elf_xtensa_size_dynamic_sections): Likewise. + (elf_xtensa_relocate_section): Likewise. + (elf_xtensa_finish_dynamic_sections): Likewise. + (shrink_dynamic_reloc_sections): Likewise. + (elf_xtensa_get_plt_section): Likewise. + (elf_xtensa_get_gotplt_section): Likewise. + (xtensa_callback_required_dependence): Likewise. + * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Set elf htab + shortcuts to dynamic sections. + (elf64_alpha_adjust_dynamic_symbol): Use elf htab shortcuts to + dynamic sections. + (elf64_alpha_size_plt_section): Likewise. + (elf64_alpha_size_rela_got_1): Likewise. + (elf64_alpha_size_rela_got_section): Likewise. + (elf64_alpha_relocate_section): Likewise. + (elf64_alpha_finish_dynamic_symbol): Likewise. + (elf64_alpha_finish_dynamic_sections): Likewise. + * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise. + * elf64-s390.c (create_got_section): Delete. + (elf_s390_create_dynamic_sections): Use _bfd_elf_create_got_section. + (elf_s390_check_relocs): Likewise. + * elf64-sh64.c (sh_elf64_relocate_section): Use elf htab shortcuts to + dynamic sections. + (sh_elf64_check_relocs): Likewise. + (sh64_elf64_adjust_dynamic_symbol): Likewise. + (sh64_elf64_size_dynamic_sections): Likewise. + (sh64_elf64_finish_dynamic_symbol): Likewise. + (sh64_elf64_finish_dynamic_sections): Likewise. + * elflink.c (_bfd_elf_create_got_section): Likewise. + * elfnn-aarch64.c (aarch64_elf_create_got_section): Likewise. + * elfnn-ia64.c (elfNN_ia64_size_dynamic_sections): Likewise. + (elfNN_ia64_finish_dynamic_sections): Likewise. + * elfnn-riscv.c (riscv_elf_create_got_section): Likewise. + * elfxx-mips.c (struct mips_elf_link_hash_table): Delete srellt, + sgotplt, splt and sgot. + (mips_elf_initialize_tls_slots): Use elf htab shortcuts to dynamic + sections. + (mips_elf_gotplt_index): Likewise. + (mips_elf_primary_global_got_index): Likewise. + (mips_elf_global_got_index): Likewise. + (mips_elf_got_offset_from_index): Likewise. + (mips_elf_create_local_got_entry): Likewise. + (mips_elf_create_got_section): Likewise. + (mips_elf_calculate_relocation): Likewise. + (_bfd_mips_elf_create_dynamic_sections): Likewise. + (_bfd_mips_elf_adjust_dynamic_symbol): Likewise. + (mips_elf_lay_out_got): Likewise. + (mips_elf_set_plt_sym_value): Likewise. + (_bfd_mips_elf_size_dynamic_sections): Likewise. + (_bfd_mips_elf_finish_dynamic_symbol): Likewise. + (_bfd_mips_vxworks_finish_dynamic_symbol): Likewise. + (mips_finish_exec_plt): Likewise. + (mips_vxworks_finish_exec_plt): Likewise. + (mips_vxworks_finish_shared_plt): Likewise. + (_bfd_mips_elf_finish_dynamic_sections): Likewise. + * elfxx-sparc.c (sparc_finish_dyn): Likewise. + * elfxx-tilegx.c (tilegx_elf_create_got_section): Likewise. + +2016-11-23 Alan Modra + + * po/BLD-POTFILES.in: Regenerate. + * po/SRC-POTFILES.in: Regenerate. + +2016-11-22 Ambrogino Modigliani + + * warning.m4: Fix spelling in comments. + * configure.ac: Fix spelling in comments. + * configure: Regenerate. + +2016-11-22 Alan Modra + + PR 20744 + * elf32-ppc.h (struct ppc_elf_params): Add vle_reloc_fixup field. + * elf32-ppc.c: Include opcode/ppc.h. + (ppc_elf_howto_raw): Correct dst_mask for R_PPC_VLE_LO16A, + R_PPC_VLE_LO16D, R_PPC_VLE_HI16A, R_PPC_VLE_HI16D, R_PPC_VLE_HA16A, + R_PPC_VLE_HA16D, R_PPC_VLE_SDAREL_LO16A, R_PPC_VLE_SDAREL_LO16D, + R_PPC_VLE_SDAREL_HI16A, R_PPC_VLE_SDAREL_HI16D, + R_PPC_VLE_SDAREL_HA16A, and R_PPC_VLE_SDAREL_HA16D relocs. + (ppc_elf_link_hash_table_create): Update default_params init. + (ppc_elf_vle_split16): Correct shift and mask. Add params. + Report or fix insn/reloc mismatches. + (ppc_elf_relocate_section): Pass input_section, offset and fixup + to ppc_elf_vle_split16. + +2016-11-22 Alan Modra + + * elf32-ppc.c (ppc64_elf_relocate_section): Calculate d_offset for + input_bfd. Replace occurrences of output_bfd as bfd_get_32 and + bfd_put_32 param with input_bfd. + * elf32-ppc.c (ppc_elf_relocate_section): Likewise. Also + ppc_elf_vle_split16 param. + (ppc_elf_vle_split16): Rename output_bfd param to input_bfd. + +2016-11-21 Maciej W. Rozycki + + * dwarf2.c (build_line_info_table): Rename `index' local + variable to `line_index'. + (build_lookup_funcinfo_table): Rename `index' local variable to + `func_index'. + 2016-11-19 Jose E. Marchesi * elfxx-sparc.c (_bfd_sparc_elf_size_dynamic_sections): Do not diff --git a/bfd/configure b/bfd/configure index 68db12f..ab239fe 100755 --- a/bfd/configure +++ b/bfd/configure @@ -12291,7 +12291,7 @@ fi rm -f conftest* -# Verify CC_FOR_BUILD to be compatible with waring flags +# Verify CC_FOR_BUILD to be compatible with warning flags # Add -Wshadow if the compiler is a sufficiently recent version of GCC. cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -15805,7 +15805,7 @@ fi -# Determine the host dependant file_ptr a.k.a. off_t type. In order +# Determine the host dependent file_ptr a.k.a. off_t type. In order # prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and # fseeko, long. This assumes that sizeof off_t is .ge. sizeof long. # Hopefully a reasonable assumption since fseeko et.al. should be diff --git a/bfd/configure.ac b/bfd/configure.ac index 6f11d29..3254dae 100644 --- a/bfd/configure.ac +++ b/bfd/configure.ac @@ -1156,7 +1156,7 @@ fi AC_SUBST(supports_plugins) AC_SUBST(lt_cv_dlopen_libs) -# Determine the host dependant file_ptr a.k.a. off_t type. In order +# Determine the host dependent file_ptr a.k.a. off_t type. In order # prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and # fseeko, long. This assumes that sizeof off_t is .ge. sizeof long. # Hopefully a reasonable assumption since fseeko et.al. should be diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c index 287ba0f..e2c8dee 100644 --- a/bfd/dwarf2.c +++ b/bfd/dwarf2.c @@ -1611,7 +1611,7 @@ build_line_info_table (struct line_info_table * table, struct line_info** line_info_lookup; struct line_info* each_line; unsigned int num_lines; - unsigned int index; + unsigned int line_index; if (seq->line_info_lookup != NULL) return TRUE; @@ -1634,11 +1634,11 @@ build_line_info_table (struct line_info_table * table, return FALSE; /* Create the line information lookup table. */ - index = num_lines; + line_index = num_lines; for (each_line = seq->last_line; each_line; each_line = each_line->prev_line) - line_info_lookup[--index] = each_line; + line_info_lookup[--line_index] = each_line; - BFD_ASSERT (index == 0); + BFD_ASSERT (line_index == 0); seq->num_lines = num_lines; seq->line_info_lookup = line_info_lookup; @@ -2259,7 +2259,7 @@ build_lookup_funcinfo_table (struct comp_unit * unit) unsigned int number_of_functions = unit->number_of_functions; struct funcinfo *each; struct lookup_funcinfo *entry; - size_t index; + size_t func_index; struct arange *range; bfd_vma low_addr, high_addr; @@ -2273,10 +2273,10 @@ build_lookup_funcinfo_table (struct comp_unit * unit) return FALSE; /* Populate the function info lookup table. */ hooks/post-receive -- Repository for Project Archer.