projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
05eb958
)
Fix Bug: test/Regression/Transforms/InstCombine/2002-09-08-PointerShiftBug.ll
author
Chris Lattner
<sabre@nondot.org>
Sun, 8 Sep 2002 21:39:07 +0000
(21:39 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Sun, 8 Sep 2002 21:39:07 +0000
(21:39 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@3626
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Scalar/InstructionCombining.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Scalar/InstructionCombining.cpp
b/lib/Transforms/Scalar/InstructionCombining.cpp
index 785eb709aa4cb94b88433cd7e09eb7bc408b3d91..748969ab3b715310cf2f2ac2ba8458dc228c913b 100644
(file)
--- a/
lib/Transforms/Scalar/InstructionCombining.cpp
+++ b/
lib/Transforms/Scalar/InstructionCombining.cpp
@@
-492,6
+492,7
@@
Instruction *InstCombiner::visitShiftInst(Instruction &I) {
if (ConstantUInt *CUI = dyn_cast<ConstantUInt>(Op1)) {
unsigned TypeBits = Op0->getType()->getPrimitiveSize()*8;
if (CUI->getValue() >= TypeBits &&
+ TypeBits && // FIXME: Handle pointer operands here. This should go away
!(Op0->getType()->isSigned() && I.getOpcode() == Instruction::Shr))
return ReplaceInstUsesWith(I, Constant::getNullValue(Op0->getType()));
}