[all-commits] [llvm/llvm-project] 10e28a: [lld/mac] Use normal Undefined machinery for dyld_...

Nico Weber via All-commits all-commits at lists.llvm.org
Sun Jul 11 09:49:55 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 10e28a748493270e31821acc0f7f0e1a9a9b0735
      https://github.com/llvm/llvm-project/commit/10e28a748493270e31821acc0f7f0e1a9a9b0735
  Author: Nico Weber <thakis at chromium.org>
  Date:   2021-07-11 (Sun, 11 Jul 2021)

  Changed paths:
    M lld/MachO/SyntheticSections.cpp
    A lld/test/MachO/dyld-stub-binder.s

  Log Message:
  -----------
  [lld/mac] Use normal Undefined machinery for dyld_stub_binder lookup

This is for aesthetic reasons, I'm not aware of anything that needs
this in practice. It does have a few effects:

- `-undefined dynamic_lookup` now has an effect for dyld_stub_binder.
  This matches ld64.

- `-U dyld_stub_binder` now works like you'd expect (it doesn't work in ld64).

- The error message for a missing dyld_stub_binder symbol now looks like
  other undefined reference symbols, it changes from

      symbol dyld_stub_binder not found (normally in libSystem.dylib). Needed to perform lazy binding.

  to

      error: undefined symbol: dyld_stub_binder
      >>> referenced by lazy binding (normally in libSystem.dylib)

Also add test coverage for that error message.

But in practice, this should have no interesting effects since everything links
in dyld_stub_binder via libSystem anyways.

Differential Revision: https://reviews.llvm.org/D105781




More information about the All-commits mailing list