[PATCH] D110422: [AIX] Enable PGO without LTO

Jinsong Ji via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 24 10:07:34 PDT 2021


jsji added inline comments.


================
Comment at: llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp:869
+  // symbol, so we can not ensure the correctness of the relative CounterPtr, so
+  // we have to use private linkage for counter and data symbols.
+  if (TT.isOSBinFormatXCOFF()) {
----------------
jsji wrote:
> MaskRay wrote:
> > Then you can just keep the existing weak symbols.
> > 
> > The weak symbols will not be selected due to linker semantics.
> Not sure what you meant? 
To be clear, keeping the weak linkage is causing issues in our test, and we investigate the problem , together with AIX binder owner, and it is the limitation in binder support that we can't ensure the relocation getting resolved to the intended weak symbol. So this is what we can do right now for enabling PGO.

We may be able to lift it this limitation later if binder get updated and do what we want, but this is limitation for now.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D110422



More information about the llvm-commits mailing list