[llvm-commits] [llvm] r82357 - /llvm/trunk/lib/VMCore/ConstantFold.cpp
Nick Lewycky
nicholas at mxc.ca
Sat Sep 19 20:48:48 PDT 2009
Author: nicholas
Date: Sat Sep 19 22:48:46 2009
New Revision: 82357
URL: http://llvm.org/viewvc/llvm-project?rev=82357&view=rev
Log:
Remove dead store by taking a guess at what Chris meant. I wasn't able to
design a testcase that would tickle this behaviour.
Modified:
llvm/trunk/lib/VMCore/ConstantFold.cpp
Modified: llvm/trunk/lib/VMCore/ConstantFold.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/ConstantFold.cpp?rev=82357&r1=82356&r2=82357&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/ConstantFold.cpp (original)
+++ llvm/trunk/lib/VMCore/ConstantFold.cpp Sat Sep 19 22:48:46 2009
@@ -1241,12 +1241,11 @@
// null pointer, do the comparison with the pre-casted value.
if (V2->isNullValue() &&
(isa<PointerType>(CE1->getType()) || CE1->getType()->isInteger())) {
- bool sgnd = isSigned;
if (CE1->getOpcode() == Instruction::ZExt) isSigned = false;
if (CE1->getOpcode() == Instruction::SExt) isSigned = true;
return evaluateICmpRelation(Context, CE1Op0,
Constant::getNullValue(CE1Op0->getType()),
- sgnd);
+ isSigned);
}
break;
More information about the llvm-commits
mailing list