[llvm] r350062 - [NFC] Reuse variables instead of re-calling getParent
Max Kazantsev via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 24 23:20:07 PST 2018
Author: mkazantsev
Date: Mon Dec 24 23:20:06 2018
New Revision: 350062
URL: http://llvm.org/viewvc/llvm-project?rev=350062&view=rev
Log:
[NFC] Reuse variables instead of re-calling getParent
Modified:
llvm/trunk/lib/Transforms/Scalar/GuardWidening.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/GuardWidening.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/GuardWidening.cpp?rev=350062&r1=350061&r2=350062&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/GuardWidening.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/GuardWidening.cpp Mon Dec 24 23:20:06 2018
@@ -472,8 +472,7 @@ GuardWideningImpl::WideningScore GuardWi
return false;
// TODO: diamond, triangle cases
if (!PDT) return true;
- return !PDT->dominates(DominatedGuard->getParent(),
- DominatingGuard->getParent());
+ return !PDT->dominates(DominatedBlock, DominatingBlock);
};
return MaybeHoistingOutOfIf() ? WS_IllegalOrNegative : WS_Neutral;
More information about the llvm-commits
mailing list