diff options
Diffstat (limited to 'llvm/lib/Transforms/Scalar/IndVarSimplify.cpp')
-rw-r--r-- | llvm/lib/Transforms/Scalar/IndVarSimplify.cpp | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp b/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp index 2ba3109354b..600589c904c 100644 --- a/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp +++ b/llvm/lib/Transforms/Scalar/IndVarSimplify.cpp @@ -621,16 +621,6 @@ void IndVarSimplify::RewriteLoopExitValues(Loop *L, SCEVExpander &Rewriter) { PN->eraseFromParent(); } } - - // If we were unable to completely replace the PHI node, clone the PHI and - // delete the original one. This purges the original phi. - if (!LCSSASafePhiForRAUW) { - PHINode *NewPN = cast<PHINode>(PN->clone()); - NewPN->takeName(PN); - NewPN->insertBefore(PN); - PN->replaceAllUsesWith(NewPN); - PN->eraseFromParent(); - } } } |