[PATCH] D25345: [ThinLTO] Handle empty summaries during internalization

Mehdi AMINI via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 7 13:39:46 PDT 2016


mehdi_amini added a comment.

The model I have in mind with the thin-link is that we operate on the combined index which represent all the files we're processing accurately. The linker provides us with the external references (among other informations).

As I mentioned to you in person the other day, this model is broken by modules with empty summaries: some of the combined index transformations may be wrong (miscompile) because of that.

We need to rework a bit the model for these modules...



================
Comment at: lib/Transforms/IPO/FunctionImport.cpp:554
+  // being able to rename local references). If we don't bail out here
+  // then we would get an assert below in the MustPreserveGV callback.
+  if (DefinedGlobals.empty())
----------------
Can you get there with an empty module? (As a module that does not define any IR Global?)


https://reviews.llvm.org/D25345





More information about the llvm-commits mailing list