[PATCH] D43077: [ThinLTO] Import external globals

Eugene Leviant via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 12 07:17:56 PST 2018


evgeny777 added inline comments.


================
Comment at: lib/Transforms/IPO/FunctionImport.cpp:257
+    for (auto &RefSummary : VI.getSummaryList())
+      if (RefSummary->getSummaryKind() == GlobalValueSummary::GlobalVarKind &&
+          !RefSummary->modulePath().empty() &&
----------------
tejohnson wrote:
> Add a comment about why we are limiting to only variable refs with external linkage and no other refs.
I think we can use `!GlobalValue::isInterposableLinkage(RefSummary->linkage())` here just like we use for functions. I'll check


https://reviews.llvm.org/D43077





More information about the llvm-commits mailing list