[PATCH] D26146: [ThinLTO] Prevent exporting of locals used/defined in module level asm

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 8 09:38:28 PST 2016


tejohnson added inline comments.


================
Comment at: lib/Analysis/ModuleSummaryAnalysis.cpp:256
+  }
+
   for (auto *V : LocalsUsed) {
----------------
tejohnson wrote:
> mehdi_amini wrote:
> > To be more clear with the above, this is the snippet I asked about why is it done here and not above around line 212.
> Because as I noted in the comment added around the earlier handling, only the llvm.used set locals may be referenced by functions that make inline asm calls, and must be marked explicitly by the user via attribute((used)), which end up in llvm.used only. We only need to collect the llvm.compiler.used here to mark those as NoRename.
> only the llvm.used set locals may be referenced by functions that make inline asm calls

That should be "only the llvm.used set locals may be referenced from within inline asm calls, and need to be handled by the inline-asm-calling functions above."


https://reviews.llvm.org/D26146





More information about the llvm-commits mailing list