From 97dae4d361b96e10ff450c0dccab48d2bccb5685 Mon Sep 17 00:00:00 2001 From: Cameron Zwarich Date: Thu, 10 Feb 2011 23:53:14 +0000 Subject: If we can't avoid running loop-simplify twice for now, at least avoid running iv-users twice. llvm-svn: 125318 --- llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp') diff --git a/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp b/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp index 01dcfaf0652..ac4aea2e404 100644 --- a/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp +++ b/llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp @@ -3824,6 +3824,9 @@ void LoopStrengthReduce::getAnalysisUsage(AnalysisUsage &AU) const { AU.addPreserved(); AU.addRequired(); AU.addPreserved(); + // Requiring LoopSimplify a second time here prevents IVUsers from running + // twice, since LoopSimplify was invalidated by running ScalarEvolution. + AU.addRequiredID(LoopSimplifyID); AU.addRequired(); AU.addPreserved(); } -- cgit v1.2.3