StructurizeCFG: Remove obsolete fix for loop backedge detection
authorTom Stellard <thomas.stellard@amd.com>
Wed, 4 Feb 2015 20:49:47 +0000 (20:49 +0000)
committerTom Stellard <thomas.stellard@amd.com>
Wed, 4 Feb 2015 20:49:47 +0000 (20:49 +0000)
This is no longer needed now that we are using a reverse post-order
traversal.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228187 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Scalar/StructurizeCFG.cpp

index 4f5fce8d3e87cd0ba4656af31431b3e053333e94..aaf6f9a0a73b4e3f525640f579d05885a0c855af 100644 (file)
@@ -360,7 +360,7 @@ void StructurizeCFG::analyzeLoops(RegionNode *N) {
     for (unsigned i = 0, e = Term->getNumSuccessors(); i != e; ++i) {
       BasicBlock *Succ = Term->getSuccessor(i);
 
-      if (Visited.count(Succ) && LI->isLoopHeader(Succ) ) {
+      if (Visited.count(Succ)) {
         Loops[Succ] = BB;
       }
     }