From af4ad851604a7e3cae52acffd3d9281094e1178a Mon Sep 17 00:00:00 2001 From: Duncan Sands Date: Fri, 19 Nov 2010 08:33:20 +0000 Subject: [PATCH] Simplify, no functionality change. llvm-svn: 119797 --- llvm/include/llvm/Analysis/LoopInfo.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/llvm/include/llvm/Analysis/LoopInfo.h b/llvm/include/llvm/Analysis/LoopInfo.h index 482c0fcbde8f..62d8d173cb02 100644 --- a/llvm/include/llvm/Analysis/LoopInfo.h +++ b/llvm/include/llvm/Analysis/LoopInfo.h @@ -1035,9 +1035,7 @@ public: // If the replacing instruction is defined in the same loop as the original // instruction, or in a loop that contains it as an inner loop, then using // it as a replacement will not break LCSSA form. - Loop *FromLoop = getLoopFor(From->getParent()); - if (ToLoop->contains(FromLoop)) return true; - return false; + return ToLoop->contains(getLoopFor(From->getParent())); } };