[llvm-commits] [llvm] r125464 - /llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp
Chris Lattner
sabre at nondot.org
Sun Feb 13 10:30:09 PST 2011
Author: lattner
Date: Sun Feb 13 12:30:09 2011
New Revision: 125464
URL: http://llvm.org/viewvc/llvm-project?rev=125464&view=rev
Log:
remove a now-unneccesary cast.
Modified:
llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp
Modified: llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp?rev=125464&r1=125463&r2=125464&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp (original)
+++ llvm/trunk/lib/Transforms/InstCombine/InstCombineCompares.cpp Sun Feb 13 12:30:09 2011
@@ -1003,7 +1003,7 @@
// Otherwise, check to see if the bits shifted out are known to be zero.
// If so, we can compare against the unshifted value:
// (X & 4) >> 1 == 2 --> (X & 4) == 4.
- if (Shr->hasOneUse() && cast<BinaryOperator>(Shr)->isExact())
+ if (Shr->hasOneUse() && Shr->isExact())
return new ICmpInst(ICI.getPredicate(), Shr->getOperand(0), ShiftedCmpRHS);
if (Shr->hasOneUse()) {
More information about the llvm-commits
mailing list