Skip to content
Snippets Groups Projects
  1. Apr 07, 2016
    • Joseph Myers's avatar
      Fix DT_MIPS_RLD_MAP_REL tag for n64 target and 32-bit host. · d929cfd5
      Joseph Myers authored
      Cherry-picked from upstream: d5cff5df74b18e1e5ed94de8f4c9adee3ffd95c6
      
      For the case of MIPS n64 target and 32-bit host, the computation of
      the DT_MIPS_RLD_MAP_REL tag involves sdyn->output_section->vma +
      sdyn->output_offset (64-bit) being added to b (32-bit host pointer),
      so losing the high part and resulting in an incorrect
      DT_MIPS_RLD_MAP_REL tag, and all dynamically linked glibc tests
      failing for n64.  This patch fixes this (spot-tested with glibc tests;
      however, I don't have a self-contained testcase for this bug).
      
      * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections)
      <DT_MIPS_RLD_MAP_REL>: Add target address to host address
      difference, not to host pointer.
      
      Change-Id: If4984d632723a36a3d6c739a96706b5636f975bc
      
      Conflicts:
      	binutils-2.25/bfd/ChangeLog
      4 tags
      d929cfd5
    • Matthew Fortune's avatar
      Add support for DT_MIPS_RLD_MAP_REL. · a696d1d3
      Matthew Fortune authored
      This tag makes it possible to access the debug map when debugging position
      independent executables.
      
      bfd/
      
      * elfxx-mips.c (_bfd_mips_elf_create_dynamic_sections): Use executable
      instead of !shared to indicate an application vs shared library.
      (_bfd_mips_elf_size_dynamic_sections): Likewise.
      (_bfd_mips_elf_finish_dynamic_sections): Handle DT_MIPS_RLD_MAP_REL.
      (_bfd_mips_elf_get_target_dtag): Likewise.
      
      binutils/
      
      * readelf.c (get_mips_dynamic_type): Handle DT_MIPS_RLD_MAP_REL.
      
      include/
      
      * elf/mips.h (DT_MIPS_RLD_MAP_REL): New macro.
      
      ld/testsuite/
      
      * ld-mips-elf/pic-and-nonpic-3b.ad: Adjust for extra dynamic tag.
      * ld-mips-elf/pic-and-nonpic-4b.ad: Likewise.
      * ld-mips-elf/pic-and-nonpic-5b.ad: Likewise.
      * ld-mips-elf/pic-and-nonpic-6-n32.ad: Likewise.
      * ld-mips-elf/pic-and-nonpic-6-n64.ad: Likewise.
      * ld-mips-elf/pic-and-nonpic-6-o32.ad: Likewise.
      * ld-mips-elf/tlsdyn-o32-1.d: Likewise.
      * ld-mips-elf/tlsdyn-o32-1.got: Likewise.
      * ld-mips-elf/tlsdyn-o32-2.d: Likewise.
      * ld-mips-elf/tlsdyn-o32-2.got: Likewise.
      * ld-mips-elf/tlsdyn-o32-3.d: Likewise.
      * ld-mips-elf/tlsdyn-o32-3.got: Likewise.
      * ld-mips-elf/tlsdyn-o32.d: Likewise.
      * ld-mips-elf/tlsdyn-o32.got: Likewise.
      * ld-mips-elf/pie-n32.d: New file.
      * ld-mips-elf/pie-n64.d: Likewise.
      * ld-mips-elf/pie-o32.d: Likewise.
      * ld-mips-elf/pie.s: Likewise.
      * ld-mips-elf/mips-elf.exp: Add new tests.
      
      Change-Id: I9fa38c2876a39c29ae3718bae0ade55c677f96fd
      a696d1d3
    • Nikola Veljkovic's avatar
      Revert "Add support for the new tag DT_MIPS_RLD_MAP2." · 42704eb7
      Nikola Veljkovic authored
      This reverts commit 51d71fd2.
      42704eb7
    • Nikola Veljkovic's avatar
      Revert "Fix DT_MIPS_RLD_MAP_REL tag for n64 target and 32-bit host." · 405fb1a9
      Nikola Veljkovic authored
      This reverts commit 7e80b87f.
      
      Conflicts:
      	binutils-2.25/bfd/ChangeLog
      
      Change-Id: I1c0e3d5e9483001db6a4ffe807d6246c2f3ca126
      405fb1a9
  2. Apr 02, 2016
    • Yunlian Jiang's avatar
      Backport upstream CL to fix x86_32 clang segfaults. · 78eb6804
      Yunlian Jiang authored
      Upstream patch being backported:
      
      commit 84d543b7ed93bf6511cdf45791f4f0b717dfb718
      Author: Sriraman Tallam <tmsriram@google.com>
      Date:   Fri Feb 5 15:07:45 2016 -0800
      
          2016-02-05  Sriraman Tallam  <tmsriram@google.com>
      
              * icf.cc (get_rel_addend): New function.
              (get_section_contents):  Move merge section addend computation to a
              new function.  Ignore negative values for SHT_REL and SHT_RELA addends.
              Fix bug to not read past the length of the section.
      
          Fix bug related to addend computation for MERGE sections.
      
      Tested via cbuildbot for ChromeOS and build on Android mnc-dr-release
      for hammerhead
      2 tags
      78eb6804
  3. Mar 11, 2016
    • Han Shen's avatar
      Backport upstream CL to fix x86_64 clang test-stlport segfaults. · 06660738
      Han Shen authored
      Upstream patch being backported:
      
        commit fc5a9bd57cbb974b8fc3aeb9a15d644cd9103451
        Author: Cary Coutant <ccoutant@gmail.com>
        Date:   Fri Feb 26 07:50:15 2016 -0800
      
            Discard FDEs for zero-length address ranges.
      
            2016-02-26  Egor Kochetov  <egor.kochetov@intel.com>
            	    Cary Coutant  <ccoutant@gmail.com>
      
            gold/
            	PR gold/19735
            	* ehframe.h (Cie::fde_encoding): New method.
            	* ehframe.cc (Eh_frame::read_fde): Discard FDEs for zero-length
            	address ranges.
      
      TESTED=only tested building with 'build.py'
      BUG=26085687
      
      Change-Id: I52e90fba86b113a557dd4d29d36ecb4c512f3f7a
      06660738
  4. Feb 17, 2016
    • Rahul Chaudhry's avatar
      Silence "Erratum 843419 found and fixed" info messages from gold. · 48ba8648
      Rahul Chaudhry authored
      BUG: 26536732
      
      Tested by building binutils on ubuntu, and using the newly built gold
      to link volantis binaries. The info messages are gone.
      
      This patch is backported from upstream -
      
          commit e3dbf58233db3ad72f1ba624dc7f13ffd2728f25
          Author: Han Shen <shenhan@google.com>
          Date:   Thu Feb 11 09:47:49 2016 -0800
      
              Remove info message for every erratum 843419 found and fixed.
      
              2016-02-11 Rahul Chaudhry  <rahulchaudhry@google.com>
      
                  * aarch64.cc (Target_aarch64::scan_erratum_843419_span):
                  Remove info message for every erratum 843419 found and fixed.
      
      Change-Id: I9792795096c919b006e98fdfdb01b448e597d605
  5. Feb 06, 2016
    • Han Shen's avatar
      Backport upstream patch to fix linker internal error. · 54643518
      Han Shen authored
      The error happens while linking a huge arm32 binary (for example, a
      debuggable chrome browser on arm) - the plt jump offset overflows. This
      fixes the problem by introducing another level of indirection.
      
      By default this does not affect anything. However in case of plt jump
      offset overflow, instead of triggering an internal error, the linker
      generates a proper message and suggests add "--long-plt" to the linker
      command.
      
      Tested via linking debug chrome browser for arm32.
      Also tested by build.py on android.
      
      The upstream patch -
      
      	commit ce3e49806d505721e0875e704de0b6fcba7660ed
      	Author: Peter Collingbourne <pcc@google.com>
      	Date:   Thu Dec 17 16:50:35 2015 -0800
      
      	Implement --long-plt flag (ARM only).
      
      	gold/
      	    PR gold/18780
      	    * arm.cc (Target_arm::do_make_data_plt): Choose PLT generator
      	    based
      	    on value of --long-plt flag.
      	    (Output_data_plt_arm_standard::do_get_plt_entry_size): Moved to
      	    Output_data_plt_arm_short.
      	    (Output_data_plt_arm_standard::do_fill_plt_entry): Likewise.
      	    (Output_data_plt_arm_standard::plt_entry): Likewise.
      	    (Output_data_plt_arm_standard::do_fill_first_plt_entry): Fix
      	    variable reference.
      	    (Output_data_plt_arm_short): New class.
      	    (Output_data_plt_arm_short::do_fill_plt_entry): Error out on too
      	    large
      	    PLT offsets instead of asserting.
      	    (Output_data_plt_arm_long): New class.
      	    * options.h (General_options): Define --long-plt flag.
      
      Change-Id: Ia61126a09f2213d1ca5c3635ec9e5b36a63f6cf3
      54643518
  6. Jan 21, 2016
    • Han Shen's avatar
      Backport trunk patch wrt wrong stub generated for aarch64 large DSOs. · c327c9c1
      Han Shen authored
      Tested by build.py for linux aarch64 toolchains.
      
      The upstream patch is:
      
      commit 9a472eda40ba686e45bf4922455518ffa3c887e1
      Author: Han Shen <shenhan@google.com>
      Date:   Fri Jan 15 09:31:23 2016 -0800
      
          [gold][aarch64] PR gold/19472 - DSOs need pc-relative stubs.
      
          The stub generated during relaxation uses absolute addressing mode
          for
          shared libraries, which is not correct. Use pc-relative addressing
          instead.
      
          gold/ChangeLog:
      
          2016-01-15 Han Shen	 <shenhan@google.com>
      
      	PR gold/19472 - DSOs need pc-relative stubs.
      
      	* aarch64.cc (Reloc_stub::stub_type_for_reloc): Return
      	PC-relative stub type for DSOs and pie executables.
      
      Change-Id: Id0022975cf93600117ff5bf300b9d736d6ad1f80
      120 tags
      c327c9c1
  7. Jan 15, 2016
    • Han Shen's avatar
      Backport trunk patch for not applying dynamic relocs. · 6579e31a
      Han Shen authored
      Note, there is a small change from the origin patch - while in the
      upstream patch, the option --no-apply-dynamic is default off, it is on
      by default in this CL.
      
      This should not bring any changes to android or chromeos, because the
      relocation value this CL changes is not used by chromeos, and is not
      used by android either (after the fix in bionic months ago).
      
      The backported patch is -
      
        commit 0eccf19f96d6218dd7c2f8d13f0546c2b942cc08
        Author: Cary Coutant <ccoutant@gmail.com>
        Date:   Thu Nov 5 12:24:14 2015 -0800
      
            Add aarch64-specific --no-apply-dynamic-relocs option.
      
            With --no-apply-dynamic-relocs on aarch64 targets, gold will not
            apply
            link-time values for absolute relocations that become dynamic
            relocations.
            This provides a workaround for broken Android dynamic linkers that
            use
            the link-time value as an extra addend to the relocation.
      
            gold/
                PR gold/19163
                * aarch64.cc (Target_aarch64::Relocate::relocate): Don't apply
                certain relocations if --no-apply-dynamic-relocs is set.
                * options.h (--apply-dynamic-relocs): New aarch64-specific
                option.
      
      Tested - build whole toolchain and built android N9 image.
      
      Change-Id: Ida524bbee2a83574cd9e78ffdad9270787327c78
      6579e31a
  8. Jan 13, 2016
    • Han Shen's avatar
      Remove internal link in warning messages. · a95c2e5c
      Han Shen authored
      The go/unsafe-pie link should not appear in any warning messages,
      replace it with a little bit detail.
      
      Tested by building locally on ubuntu.
      
      Change-Id: I3e590108ec2c6c8917475b5d78cdabbfcf2833f7
      3 tags
      a95c2e5c
  9. Dec 18, 2015
  10. Nov 21, 2015
    • Han Shen's avatar
    • Han Shen's avatar
      Fix darwin build failures (because of compilation warnings). · adb604a3
      Han Shen authored
      "%ld" is the printf specifier for "long int", which is 64-bit on 64-bit
      machines, and 32-bit on 32-bit hosts. While uint64_t is always 64 bits,
      so replace it with macro "PRIu64".
      
      Tested:
        ./build.py --host "linux" --toolchain aarch64-linux-android
        ./build.py --host "linux" --toolchain arm-linux-androideabi
        ./build.py --host "linux" --toolchain mipsel-linux-android
        ./build.py --host "windows" --toolchain arm-linux-androideabi
      
      Change-Id: I9f0b322ed14e6feb7a110bfebcff963cf94d7703
      adb604a3
    • Han Shen's avatar
      Cherry pick upstream patch for aarch64 unsupported reloc. · c536bde9
      Han Shen authored
      Bug entry here - https://b.corp.google.com/u/0/issues/25642296
      
      Tested: ./build.py --host "linux" --toolchain aarch64-linux-android
      
      Upstream patch here -
      
      commit 4d2f5d5824be99326c2c3e459c298e338856d8c8
      Author: Han Shen <shenhan@google.com>
      Date:   Tue Oct 27 15:17:54 2015 -0700
      
          Patch for PR gold/19042 - unsupported reloc 311/312.
      
          gold/
      
              * aarch64.cc (Target_aarch64::Scan::local): Add support for
              reloc 311/312.
      
      Change-Id: If784460c1ebdfb2be1ebdf1486db5eb03c5240a5
      c536bde9
  11. Nov 20, 2015
  12. Nov 06, 2015
    • Lee Campbell's avatar
      Plumb --pic-veneer option for gold. · 932d71b8
      Lee Campbell authored
      Cherry-pick of upstream commit cdb061674c044636465e52a8c989b9011f2ec8ac
      
      gold/ChangeLog:
              * arm.cc (Reloc_stub::stub_type_for_reloc): Plumb to stub generation.
              * options.h (General_options): Add --pic-veneer option.
      
      BUG: 25512672
      932d71b8
  13. Nov 04, 2015
    • Nick Clifton's avatar
      Fix Mac OS X build failures (wcsncasecmp unsat) · 0a79d97a
      Nick Clifton authored
      Cherry-pick of upstream commit 31593e1b96c792abba3c5268d6423975aefa56b2
      
       2015-02-24  Nick Clifton  <nickc@redhat.com>
      
      	* configure.ac (AC_CHECK_HEADERS): Add wctype.h.
      	* configure: Regenerate.
      	* config.in: Regenerate.
      	* peXXigen.c: Include wctype.h if HAVE_WCTYPE_H is defined.
      	(u16_mbtowc): Use wint_t types if HAVE_WCTYPE_H is defined.
      	(rsrc_cmp): Use towlower instead of wcsncasecmp if HAVE_WCTYPE_H
      	is defined.
      
      Bug: 25427405
      Change-Id: I06e99d906226ce9c88ff1c568ae7a4d84df7f332
      0a79d97a
  14. Oct 16, 2015
    • Than McIntosh's avatar
      Fix gold build error at -O0. · b51d5d61
      Than McIntosh authored
      Cherrypick of upstream commit 5d7908e0880030628536a0266968a15922574735
      
        Author: Cary Coutant <ccoutant@gmail.com>
        Date:   Thu Jun 11 13:19:38 2015 -0700
      
          Fix gold build error at -O0.
      
          In aarch64.cc, Erratum_stub::STUB_ADDR_ALIGN and Reloc_stub::STUB_ADDR_ALIGN
          are declared as static const int, and initialized in the class body. These
          values are referenced from outside the class body, and with no optimization,
          the references go unresolved.
      
          gold/
              * aarch64.cc (Erratum_stub::STUB_ADDR_ALIGN): Move initialization
              outside class body.
              (Reloc_stub::STUB_ADDR_ALIGN): Likewise.
      
      Change-Id: I6c0726e624be076e0d0565652a56da5ef761d88a
      b51d5d61
  15. Sep 29, 2015
    • Han Shen's avatar
      Use "gold_info" instead of "gold_warning" for erratum fix. · 21947aa2
      Han Shen authored
      gold/ChangeLog:
      
      	* aarch64.cc (Target_aarch64::scan_erratum_843419_span): Use 'gold_info'.
      	(Target_aarch64::scan_erratum_835769_span): USe 'gold_info'.
      
      (cherry picked from commit 73854cdd438dc8858290231ebcb682377d71fec2)
      21947aa2
    • Han Shen's avatar
      Drop 'missing mapping symbols' warning for arm and aarch64. · 1c1d236d
      Han Shen authored
      The psABI (AAELF) says this about mapping symbols:
      
          4.6.5.1 Section-relative mapping symbols
      
          Mapping symbols defined in a section define a sequence of
          half-open address intervals that cover the address range of the
          section. Each interval starts at the address defined by the
          mapping symbol, and continues up to, but not including, the
          address defined by the next (in address order) mapping symbol or
          the end of the section. A section must have a mapping symbol
          defined at the beginning of the section; however, if the section
          contains only data then the mapping symbol may be omitted.
      
      That makes it pretty clear that, in the absence of a mapping symbol,
      the entire section can be treated as data.
      
      gold/ChangeLog:
      	* aarch64.cc (AArch64_relobj::scan_errata): Drop missing symbol warning.
      	* arm.cc (Arm_relobj::scan_section_for_cortex_a8_erratum): Drop missing
      	symbol warning.
      
      (cherry picked from commit 61163dfaaedb90d78e11c1d79ad1e469daf3da47)
      1c1d236d
  16. Aug 16, 2015
  17. Jul 31, 2015
    • Andrew Hsieh's avatar
      Remove duplicated option fix_cortex_a53_835769 · ef83eb2b
      Andrew Hsieh authored
      This was added before ld.gold scans for erratum 835769, but
      GCC has been hard-wired to pass "--fix-cortex-a53-835769"
      to linker (ld.bfd is default for AArch64 for now) unconditionally
      in Android platform.
      
      Change-Id: I39bacdc2a52d09afdc0993c17b46ac438d1fa246
      ef83eb2b
  18. Jul 30, 2015
    • Han Shen's avatar
      Make gold aarch64 accept long form of mapping symbols. · 0040352e
      Han Shen authored
      2015-07-07  Han Shen  <shenhan@google.com>
      
      gold/ChangeLog:
      	2015-07-06 Han Shen  <shenhan@google.com>
      	* aarch64.cc (AArch64_relobj::do_count_local_symbols): Make legal
      	of mapping symbols.
      
      Change-Id: If62f577eeb704d8c7b0b2f525e91b3cb311001ca
      (cherry picked from commit b91deca94e36b9f18156909e4c615fe7af8e3ae8)
      0040352e
    • Han Shen's avatar
      Patch for gold internal error while fixing erratum 843419. · ec8f12bc
      Han Shen authored
      The crash reason is that the insn to be moved to stub may be a
      relocation spot, so instead of placing the origin insn (that is insn
      before-relocation) to the stub, I have to place the relocated one.
      Note the relocation involved is non-pc-relative, so it is safe to move
      the relocated insn.
      
      gold/ChangeLog:
      2015-06-29  Han Shen  <shenhan@google.com>
      
          * AArch64.cc (Erratum_stub::Insn_utilities): New typedef.
          (Erratum_stub::update_erratum_insn): New method.
          (Stub_table::relocate_stubs): Modified to place relocated insn.
          (AArch64_relobj::fix_errata): Modified gold_assert.
      
      Change-Id: I9d90ac6e569bbbab086f877c7446dc6f9ea96247
      (cherry picked from commit 56b06706ebe6bb3decc674b788b6f5b243b8610d)
      ec8f12bc
    • Han Shen's avatar
      [gold][aarch64] Fix erratum 835769. · 3f3b4a87
      Han Shen authored
      gold/ChangeLog:
      
      	* aarch64.cc (AArch64_insn_utilities::BYTES_PER_INSN): Move
      	defintion outside class definition.
      	(AArch64_insn_utilities::AARCH64_ZR): New static constant.
      	(AArch64_insn_utilities::aarch64_op31): New member.
      	(AArch64_insn_utilities::aarch64_ra): New member.
      	(AArch64_insn_utilities::aarch64_mac): New member.
      	(AArch64_insn_utilities::aarch64_mlxl): New member.
      	(ST_E_835769): New global enum member.
      	(Stub_table::relocate_stubs): Add 835769 handler.
      	(Stub_template_repertoire::Stub_template_repertoire): Install new
      	stub type.
      	(AArch64_relobj::scan_errata): This func is renamed from
      	scan_erratum_843419.
      	(AArch64_relobj::do_count_local_symbols): Add 835769 handler.
      	(AArch64_relobj::do_relocate_sections): Add 835769 handler.
      	(AArch64_relobj::scan_sections_for_stubs): Add 835769 handler.
      	(Target_aarch64::scan_erratum_835769_span): New method.
      	(Target_aarch64::create_erratum_stub): New method.
      	(Target_aarch64::is_erratum_835769_sequence): New method.
      	(Target_aarch64::scan_erratum_843419_sequence): Move part of the
      	code into create_erratum_stub.
      	* options.h (fix_cortex_a53_835769): New option.
      
      Change-Id: Ia355fad38de61f82b9a42c601129fbbe2730ba27
      (cherry picked from commit 2f0c79aa61e82cbc5da4b9ab399362b2cdd8ea2e)
      3f3b4a87
    • Han Shen's avatar
      Patch for erratum-843419 (2 of 2 - fix erratum occurrences). · d3279854
      Han Shen authored
      Now fixing for 843419 is fully functional.
      
      The first part of the erratum fix CL is here -
      https://sourceware.org/ml/binutils/2015-04/msg00229.html
      
      gold/ChangeLog
      2015-06-10  Han Shen  <shenhan@google.com>
      
          * aarch64.cc(global enum): New constants representing stub types.
          (Stub_template): New POD struct.
          (Stub_template_repertoire): New class.
          (Stub_base): New class.
          (Erratum_stub): New class.
          (Reloc_stub): Refactored to be a subclass of Stub_base.
          (Reloc_stub::Stub_type): Removed.
          (Reloc_stub::offset): Moved to Stub_base.
          (Reloc_stub::set_offset): Moved to Stub_base.
          (Reloc_stub::destination_address): Moved to Stub_base.
          (Reloc_stub::set_destination_address): Moved to Stub_base.
          (Reloc_stub::reset_destination_address): Moved to Stub_base.
          (Reloc_stub::stub_type): Renamed and moved to Stub_base.
          (Reloc_stub::stub_size): Renamed and moved to Stub_base.
          (Reloc_stub::stub_insns): Renamed and moved to Stub_base.
          (Reloc_stub::write): Moved to Stub_base.
          (Reloc_stub::invalid_offset): Moved to Stub_base.
          (Reloc_stub::invalid_address): Moved to Stub_base.
          (Reloc_stub::stub_type_): Renamed and moved to Stub_base.
          (Reloc_stub::stub_insns_): Moved to Stub_base.
          (Reloc_stub::offset_): Moved to Stub_base.
          (Reloc_stub::destination_address_): Moved to Stub_base.
          (Stub_table::The_aarch64_relobj): New typedef.
          (Stub_table::The_erratum_stub): New typedef.
          (Stub_table::The_erratum_stub_less): New typedef.
          (Stub_table::The_erratum_stub_set): New typedef.
          (Stub_table::The_erratum_stub_set_iter): New typedef.
          (Stub_table::empty): Added emptiness testing for erratum stubs.
          (Stub_table::add_erratum_stub): New method to add an erratum stub.
          (Stub_table::find_erratum_stub): New method.
          (Stub_table::find_erratum_stubs_for_input_section): New method.
          (Stub_table::erratum_stub_address): New method.
          (Stub_table::update_date_size_changed_p): Modified to handle erratum stubs.
          (Stub_table::do_addralign): Modified to handle erratum stubs.
          (Stub_table::erratum_stubs_): New member.
          (Stub_table::erratum_stub_size_): New member.
          (Stub_table::relocate_stubs): Modified to handle erratum stubs.
          (Stub_table::do_write): Modified to handle erratum stubs.
          (AArch64_relobj::The_erratum_stub): New typedef.
          (AArch64_relobj::Erratum_stub_set_iter): New typedef.
          (AArch64_relobj::fix_errata): New method.
          (Target_aarch64::The_reloc_stub_type): Removed.
          (Target_aarch64::The_erratum_stub): New typede.
          (AArch64_relocate_functions::construct_b): New method.
      
      Change-Id: I37ccc9fbefd5559dae700637e119a2a885cf3eb9
      (cherry picked from commit a48d0c12f893a922692492829f04189d9f216172)
      d3279854
  19. Jul 27, 2015
    • Joseph Myers's avatar
      Fix DT_MIPS_RLD_MAP_REL tag for n64 target and 32-bit host. · 7e80b87f
      Joseph Myers authored
      Cherry-picked from upstream: d5cff5df74b18e1e5ed94de8f4c9adee3ffd95c6
      
      For the case of MIPS n64 target and 32-bit host, the computation of
      the DT_MIPS_RLD_MAP_REL tag involves sdyn->output_section->vma +
      sdyn->output_offset (64-bit) being added to b (32-bit host pointer),
      so losing the high part and resulting in an incorrect
      DT_MIPS_RLD_MAP_REL tag, and all dynamically linked glibc tests
      failing for n64.  This patch fixes this (spot-tested with glibc tests;
      however, I don't have a self-contained testcase for this bug).
      
      * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_sections)
      <DT_MIPS_RLD_MAP_REL>: Add target address to host address
      difference, not to host pointer.
      
      Change-Id: If4984d632723a36a3d6c739a96706b5636f975bc
      7e80b87f
  20. Jul 15, 2015
  21. Jul 08, 2015
  22. Jun 23, 2015
  23. Jun 18, 2015
  24. Jun 17, 2015
  25. May 06, 2015
    • Andrew Hsieh's avatar
      Fix darwin build · c39479f4
      Andrew Hsieh authored
      1. In Drawin PTHREAD_ONCE_INIT is {0x30B1BCBA, {0}} and the GCC < 4.4
         doesn't support ended initializer list
      2. wcsncasecmp doesn't exist in MacSDK10.6.x
      
      Change-Id: I69204a72f853f5263dffedc448379d75ed4eca2e
      c39479f4
  26. May 05, 2015
  27. Apr 28, 2015
    • Han Shen's avatar
      Rename '--fix-cortex-a53' to '--fix-cortex-a53-843419'. · 29e2f846
      Han Shen authored
      Keep gold consistent with bfd erratum-fixing option names, so as to
      ease life in Makefile/scripts.
      
      gold/
      
      	* options.h (--fix-cortex-a53-843419): Rename option.
      	* aarch64.cc (AArch64_relobj::do_count_local_symbols): Use renamed
      	option.
      	(AArch64_relobj::scan_sections_for_stubs): Use renamed option.
      
      Change-Id: I8941fb38ef34fa5eb297e83725d87fdee994fc3a
      29e2f846
    • Han Shen's avatar
      The first patch to address cortex-a53 erratum-843419. · f2bbcbc8
      Han Shen authored
      It implemented scanning the binary and reporting occurrences to users
      when '--fix-cortex-a53' is turned on. With this, gold users will be
      able to see if or not there are such erratum occurrences in the output
      binary. Also included in the CL is reading/recording mapping symbols,
      which is needed during scan.
      
      gold/ChangeLog:
          * aarch64.cc (AArch64_insn_utilities): New utility class.
          (AArch64_relobj::Mapping_symbol_position): New struct.
          (AArch64_relobj::Mapping_symbol_info): New typedef.
          (AArch64_relobj::do_count_local_symbols): New function overriding
          parent's implementation.
          (AArch64_relobj::mapping_symbol_info_): New member
          (AArch64_relobj::scan_erratum_843419): New method.
          (Target_aarch64::scan_erratum_843419_span): New method.
          (Target_aarch64::is_erratum_843419_sequence): New method.
          * options.h (fix_cortex_a53): New option.
      
      Change-Id: I4fe7a2b8858cda358ac28eede42cd5a2f49c2238
      f2bbcbc8
  28. Apr 22, 2015
Loading