From 4a0ceb1e6d619020cdee5453b4e4f06145ceff2c Mon Sep 17 00:00:00 2001 From: Owen Anderson Date: Fri, 9 Jun 2006 18:40:32 +0000 Subject: [PATCH] Add LCSSA as a requirement for LoopUnswitch, and assert that LoopUnswitch preserves LCSSA. llvm-svn: 28739 --- lib/Transforms/Scalar/LoopUnswitch.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/Transforms/Scalar/LoopUnswitch.cpp b/lib/Transforms/Scalar/LoopUnswitch.cpp index c583eea14d6..ab736c1de87 100644 --- a/lib/Transforms/Scalar/LoopUnswitch.cpp +++ b/lib/Transforms/Scalar/LoopUnswitch.cpp @@ -73,6 +73,8 @@ namespace { AU.addPreservedID(LoopSimplifyID); AU.addRequired(); AU.addPreserved(); + AU.addRequiredID(LCSSAID); + AU.addPreservedID(LCSSAID); } private: @@ -199,6 +201,8 @@ bool LoopUnswitch::visitLoop(Loop *L) { } } + assert(L->isLCSSAForm()); + return Changed; }