Skip to content
  1. Jul 08, 2016
    • Peter Smith's avatar
      Revert R274836 Add Thunk support framework for ARM and Mips · eeb82744
      Peter Smith authored
      This seems to be causing a buildbot failure on lld-x86_64-freebsd. Will
      reproduce locally and fix. 
      
      llvm-svn: 274841
      eeb82744
    • Peter Smith's avatar
      Add Thunk support framework for ARM and Mips · de01b98a
      Peter Smith authored
          
          Generalise the Mips LA25 Thunk code and implement ARM and Thumb
          interworking Thunks.
          
          - Introduce a new module Thunks.cpp to store the Target Specific Thunk
            implementations.
          - DefinedRegular and Shared have a ThunkData field to record Thunk.
          - A Target can have more than one type of Thunk.
          - Support PC-relative calls to Thunks.
          - Support Thunks to PLT entries.
          - Existing Mips LA25 Thunk code integrated.
          - Support for ARMv7A interworking Thunks.
          
          Limitations:
          - Only one Thunk per SymbolBody, this is sufficient for all currently
            implemented Thunks.
          - ARM thunks assume presence of V6T2 MOVT and MOVW instructions.
      
          Differential revision: http://reviews.llvm.org/D21891
      
      llvm-svn: 274836
      de01b98a
    • George Rimar's avatar
      [ELF] - Do not error out when version declaration not found when building executable. · c61bcd80
      George Rimar authored
        When building executable usually version script is absent.
      Before this patch error was shown in the case when
      symbol name contained version and there was no script to match it.
        Instead of error out patch allows
      to create new version declaration in this case and use it.
      gnu linkers do the same.
      
      That is PR28359.
      
      Differential revision: http://reviews.llvm.org/D21890
      
      llvm-svn: 274828
      c61bcd80
    • Rui Ueyama's avatar
      Test --demangle feature. · f731d0af
      Rui Ueyama authored
      Previously, it was not tested because the test was written in
      a way that it passed on a platform that does not support
      abi::__cxa_demangle. Now we restrict this test to Unix (by adding
      "REQUIRES: shell") and assume that it always demangle symbols.
      Thanks to Davide to find out the issue.
      
      llvm-svn: 274808
      f731d0af
    • Davide Italiano's avatar
      [ELF] Ignore --demangle. We already demangle symbols by default. · 3f36781d
      Davide Italiano authored
      llvm-svn: 274806
      3f36781d
    • Rui Ueyama's avatar
      Move demangle() from Symbols.cpp to Strings.cpp. · f4d9338d
      Rui Ueyama authored
      Symbols.cpp contains functions to handle ELF symbols.
      demangle() function is essentially a function to work on a
      string rather than on an ELF symbol. So Strings.cpp is a
      better place to put that function.
      
      This change also make demangle to demangle symbols unconditionally.
      Previously, it demangled symbols only when Config->Demangle is true.
      
      llvm-svn: 274804
      f4d9338d
    • Rafael Espindola's avatar
      -Bsymbolic should not make symbols more preemptable. · 580d7a1b
      Rafael Espindola authored
      But it was doing that for protected undefined symbols.
      
      llvm-svn: 274803
      580d7a1b
  2. Jul 07, 2016
    • Rafael Espindola's avatar
      Fix formating. NFC. · 64c32d6f
      Rafael Espindola authored
      llvm-svn: 274757
      64c32d6f
    • Rafael Espindola's avatar
      Use "using namespace llvm" like the rest of ELF lld. · d10f0b1e
      Rafael Espindola authored
      llvm-svn: 274755
      d10f0b1e
    • Rafael Espindola's avatar
      This now works on unix too. · 4225342e
      Rafael Espindola authored
      With this there are no unsupported tests on linux in test/ELF :-)
      
      llvm-svn: 274752
      4225342e
    • George Rimar's avatar
      [ELF] - Fixed incorrect logic of version assignments when mixing wildcards with values matching. · f73a2581
      George Rimar authored
      Previously we had incorrect logic here. Imagine we would have the next script:
      
      LIBSAMPLE_1.0
      {
        global:
         a_2;
       local:
        *;
      };
      
      LIBSAMPLE_2.0
      {
        global:
         a*;
      };
      According to previous logic it would assign version 1 to a_2 and then
      would try to reassign it to version 2 because of applying wildcard a*.
      And show a warning about that.
      
      Generally Ian Lance Tailor wrote about next rules that should be applied:
      (http://www.airs.com/blog/archives/300)
      
      Here are the current rules for gold:
      
      "If there is an exact match for the mangled name, we use it. If there is more than one exact match, we give a warning, and we use the first tag in the script which matches. If a symbol has an exact match as both global and local for the same version tag, we give an error.
      Otherwise, we look for an extern C++ or an extern Java exact match. If we find an exact match, we use it. If there is more than one exact match, we give a warning, and we use the first tag in the script which matches. If a symbol has an exact match as both global and local for the same version tag, we give an error.
      Otherwise, we look through the wildcard patterns, ignoring “*” patterns. We look through the version tags in reverse order. For each version tag, we look through the global patterns and then the local patterns. We use the first match we find (i.e., the last matching version tag in the file).
      Otherwise, we use the “*” pattern if there is one. We give a warning if there are multiple “*” patterns."
      
      Patch makes wildcard matching to be in revered order and to follow after the regular naming matching.
      
      Differential revision: http://reviews.llvm.org/D21894
      
      llvm-svn: 274739
      f73a2581
    • Rui Ueyama's avatar
      Correctly define "zlib" feature. · 287956f7
      Rui Ueyama authored
      We have "REQUIRES: zlib" in our test, but zlib was not defined,
      so the test did not run on any platform.
      
      llvm-svn: 274730
      287956f7
    • Rui Ueyama's avatar
      Fix endianness issue. · 1d12ac1d
      Rui Ueyama authored
      Previously, ch_size was read in host byte order, so if a host and
      a target are different in byte order, we would produce a corrupted
      output.
      
      llvm-svn: 274729
      1d12ac1d
    • Rui Ueyama's avatar
      Fix formatting. · 523744dd
      Rui Ueyama authored
      llvm-svn: 274724
      523744dd
    • Rui Ueyama's avatar
      Do not call warning() from ELFOptTable::parse(). · 0f282a59
      Rui Ueyama authored
      warning() depends on Config->FatalWarnings, so we don't want to call
      that function before we initialize that member.
      
      llvm-svn: 274723
      0f282a59
    • Rui Ueyama's avatar
      Fix indentation. · a027d339
      Rui Ueyama authored
      llvm-svn: 274719
      a027d339
  3. Jul 06, 2016
  4. Jul 04, 2016
  5. Jul 02, 2016
  6. Jul 01, 2016
  7. Jun 30, 2016
  8. Jun 29, 2016
    • Kevin Enderby's avatar
      Matching change for lld for the llvm change of Archive::create() from... · b9e053cf
      Kevin Enderby authored
      Matching change for lld for the llvm change of Archive::create() from ErrorOr<...> to Expected<...> in r274160.
      
      llvm-svn: 274161
      b9e053cf
    • Davide Italiano's avatar
      [ELF] More self-explanatory error message when e_machine can't be inferred. · e3fa8f64
      Davide Italiano authored
      Thanks to Sean Silva for the suggestion!
      
      llvm-svn: 274134
      e3fa8f64
    • George Rimar's avatar
      [ELF] - Added support for --unresolved-symbols option. · e86dcd0c
      George Rimar authored
      Option has next description (http://linux.die.net/man/1/ld):
      "--unresolved-symbols=method
      Determine how to handle unresolved symbols. There are four possible values for method
      according to documentation:
      
      ignore-all: Do not report any unresolved symbols.
      report-all: Report all unresolved symbols. This is the default.
      ignore-in-object-files: Report unresolved symbols that are contained in shared libraries, but ignore them if they come from regular object files.
      ignore-in-shared-libs: Report unresolved symbols that come from regular object files, but ignore them if they come from shared libraries."
      
      Since report-all is default and we traditionally do not report about undefined symbols in lld,
      report-all does not report about undefines from DSO. 
      ignore-in-object-files also does not do that. Handling of that option differs from what gnu linkers do.
      
      Option works in next way in lld:
      ignore-all: Do not report any unresolved symbols.
      report-all: Report all unresolved symbols except symbols from DSOs. This is the default.
      ignore-in-object-files: The same as ignore-all.
      gnore-in-shared-libs: The same as report-all.
      
      This is PR24524.
      
      Differential revision: http://reviews.llvm.org/D21794
      
      llvm-svn: 274123
      e86dcd0c
Loading