[PATCH] D16727: [Profiling] Write out sparse indexed profiles

David Li via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 29 13:41:33 PST 2016


davidxl added inline comments.

================
Comment at: lib/ProfileData/InstrProfWriter.cpp:298
@@ -281,2 +297,3 @@
   for (const auto &I : FunctionData)
-    Symtab.addFuncName(I.getKey());
+    if (shouldEncodeData(I.getValue()))
+      Symtab.addFuncName(I.getKey());
----------------
This guard is not right -- the function may be referenced by an indirect call target from another emitted function. In fact since text format is mainly used for debugging, I don't see much point honoring sparse flag here.


http://reviews.llvm.org/D16727





More information about the llvm-commits mailing list