[PATCH] D13218: Mark BB as annotated if its weight is > 0

Diego Novillo via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 30 04:47:34 PDT 2015


dnovillo added a comment.

Patch looks fine.  Just a couple of final questions.


================
Comment at: include/llvm/ProfileData/SampleProf.h:221
@@ -220,3 +216,1 @@
-    if (Num == 0)
-      Num = 1;
     BodySamples[LineLocation(LineOffset, Discriminator)].addSamples(Num);
----------------
Sadly, I don't think there is a test case for this check I had added.  With your new changes, we can now distinguish 0 from missing sample all the time, right?

================
Comment at: lib/Transforms/IPO/SampleProfile.cpp:505
@@ -504,3 @@
-    PDT->getDescendants(BB1, DominatedBBs);
-    findEquivalencesFor(BB1, DominatedBBs, DT.get());
-
----------------
Not sure why we don't process blocks post-dominated by BB1 anymore?


http://reviews.llvm.org/D13218





More information about the llvm-commits mailing list