[PATCH] D26045: [cfi] Fix weak functions handling.

Evgeniy Stepanov via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 27 15:53:24 PDT 2016


eugenis added inline comments.


================
Comment at: lib/Transforms/IPO/LowerTypeTests.cpp:764
+  for (auto *U : F->users())
+    if (auto *GV = dyn_cast<GlobalVariable>(U))
+      GlobalVarUses.push_back(GV);
----------------
pcc wrote:
> What if the use is an element of an aggregate that initializes a GlobalVariable?
Good point. There are also other expressions that are sometimes (always?) allowed in a global initializers, like (char*)f + 42.



Repository:
  rL LLVM

https://reviews.llvm.org/D26045





More information about the llvm-commits mailing list