[PATCH] D153839: [XCOFF] Force recording a relocation for weak symbol label.

ChenZheng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 2 19:14:59 PDT 2023


shchenz added inline comments.


================
Comment at: llvm/lib/Target/PowerPC/MCTargetDesc/PPCAsmBackend.cpp:182
             return true;
-        }
+        } else if (const auto *S = dyn_cast<MCSymbolXCOFF>(&A->getSymbol())) {
+          return !Target.isAbsolute() && S->isExternal() &&
----------------
This seems not equal to what we handle for Linux(where we have local entry). On Linux, for non weak functions, they also need a force relocation for usage like compiling a shared library. I've asked help internally.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D153839



More information about the llvm-commits mailing list