Back out Owen's 6/9 changes. They broke MultiSource/Benchmarks/Prolangs-C/bison (and perhaps others).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28747 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Analysis/LoopInfo.cpp b/lib/Analysis/LoopInfo.cpp
index eed2cd6..c7ce58e 100644
--- a/lib/Analysis/LoopInfo.cpp
+++ b/lib/Analysis/LoopInfo.cpp
@@ -479,22 +479,6 @@
   return 0;
 }
 
-/// isLCSSAForm - Return true if the Loop is in LCSSA form
-bool Loop::isLCSSAForm() const {  
-  for (Loop::block_iterator BB = block_begin(), E = block_end();
-       BB != E; ++BB) {
-    for (BasicBlock::iterator I = (*BB)->begin(), E = (*BB)->end(); I != E; ++I)
-      for (Value::use_iterator UI = I->use_begin(), E = I->use_end(); UI != E;
-           ++UI) {
-        BasicBlock *UserBB = cast<Instruction>(*UI)->getParent();
-        if (!isa<PHINode>(*UI) && !contains(UserBB)) {
-          return false;
-        }
-      }
-  }
-  
-  return true;
-}
 
 //===-------------------------------------------------------------------===//
 // APIs for updating loop information after changing the CFG
diff --git a/lib/Transforms/Scalar/LoopUnswitch.cpp b/lib/Transforms/Scalar/LoopUnswitch.cpp
index ab736c1..c583eea 100644
--- a/lib/Transforms/Scalar/LoopUnswitch.cpp
+++ b/lib/Transforms/Scalar/LoopUnswitch.cpp
@@ -73,8 +73,6 @@
       AU.addPreservedID(LoopSimplifyID);
       AU.addRequired<LoopInfo>();
       AU.addPreserved<LoopInfo>();
-      AU.addRequiredID(LCSSAID);
-      AU.addPreservedID(LCSSAID);
     }
 
   private:
@@ -201,8 +199,6 @@
       }
   }
     
-  assert(L->isLCSSAForm());
-  
   return Changed;
 }
 
diff --git a/lib/Transforms/Utils/LCSSA.cpp b/lib/Transforms/Utils/LCSSA.cpp
index ecbf180..e1af50e 100644
--- a/lib/Transforms/Utils/LCSSA.cpp
+++ b/lib/Transforms/Utils/LCSSA.cpp
@@ -98,7 +98,7 @@
   for (LoopInfo::iterator I = LI->begin(), E = LI->end(); I != E; ++I) {
     changed |= visitSubloop(*I);
   }
-  
+      
   return changed;
 }
 
@@ -132,8 +132,6 @@
     processInstruction(*I, exitBlocks);
   }
   
-  assert(L->isLCSSAForm());
-  
   return true;
 }