From 3ddbc242fb75acea7df2d8525810b5449a31d6d7 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Tue, 8 Sep 2009 15:45:00 +0000 Subject: Re-apply r80926, with fixes: keep the domtree informed of new blocks that get created during loop unswitching, and fix SplitBlockPredecessors' LCSSA updating code to create new PHIs instead of trying to just move existing ones. Also, optimize Loop::verifyLoop, since it gets called a lot. Use searches on a sorted list of blocks instead of calling the "contains" function, as is done in other places in the Loop class, since "contains" does a linear search. Also, don't call verifyLoop from LoopSimplify or LCSSA, as the PassManager is already calling verifyLoop as part of LoopInfo's verifyAnalysis. llvm-svn: 81221 --- llvm/lib/Transforms/Scalar/LICM.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'llvm/lib/Transforms/Scalar/LICM.cpp') diff --git a/llvm/lib/Transforms/Scalar/LICM.cpp b/llvm/lib/Transforms/Scalar/LICM.cpp index 15bb9c70dfe..1c298785da8 100644 --- a/llvm/lib/Transforms/Scalar/LICM.cpp +++ b/llvm/lib/Transforms/Scalar/LICM.cpp @@ -91,6 +91,7 @@ namespace { AU.addRequired(); AU.addPreserved(); AU.addPreserved(); + AU.addPreservedID(LoopSimplifyID); } bool doFinalization() { -- cgit v1.2.3