blockfreq: Skip irreducible backedges inside functions
[oota-llvm.git] / lib / Analysis / BlockFrequencyInfoImpl.cpp
index b5532fcea1d058e63c8d8f519f606935b9d566d8..29a4117c1300d028725326bfa8d45e9a37b06ebd 100644 (file)
@@ -687,7 +687,7 @@ void BlockFrequencyInfoImplBase::addToDist(Distribution &Dist,
     return;
   }
 
-  if (!LoopHead.isValid() && Resolved < Pred) {
+  if (Resolved < Pred) {
     // Irreducible backedge.  Skip this edge in the distribution.
     DEBUG(debugSuccessor("skipped ", Resolved));
     return;