[PATCH] D97521: [lld/mac] Add some support for dynamic lookup symbols, and implement -U

Jez Ng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 26 10:35:15 PST 2021


int3 added inline comments.


================
Comment at: lld/MachO/SyntheticSections.cpp:268-278
+
+  // XXX named constant for -2
+  int32_t ordinal = dysym->isDynamicLookup() ? -2 : dysym->getFile()->ordinal;
+
+  if (lastBinding.ordinal != ordinal) {
+    if (ordinal < 0) {
+      assert(ordinal == -2);
----------------
you should pull and rebase past {D95913}


================
Comment at: lld/MachO/SyntheticSections.cpp:269
+
+  // XXX named constant for -2
+  int32_t ordinal = dysym->isDynamicLookup() ? -2 : dysym->getFile()->ordinal;
----------------
that would be BIND_SPECIAL_DYLIB_FLAT_LOOKUP


================
Comment at: lld/test/MachO/U_dynamic_lookup.s:1
+# REQUIRES: x86
+# RUN: rm -rf %t
----------------
nit: use hyphens instead of underscores in test file names


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D97521/new/

https://reviews.llvm.org/D97521



More information about the llvm-commits mailing list