summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorMatthijs Kooijman <matthijs@stdin.nl>2008-05-23 16:17:48 +0000
committerMatthijs Kooijman <matthijs@stdin.nl>2008-05-23 16:17:48 +0000
commitf52b23c0eb6c7f3df6e2e80c0b49d3b4a86cb444 (patch)
tree2905f20d782c6fb63013798176b8279e72831b81 /llvm/lib/Transforms
parente7d45b1e49eefcedc64dc389790dd8ad3e33aca7 (diff)
downloadbcm5719-llvm-f52b23c0eb6c7f3df6e2e80c0b49d3b4a86cb444.tar.gz
bcm5719-llvm-f52b23c0eb6c7f3df6e2e80c0b49d3b4a86cb444.zip
Replace some weird usage of UserOp1 introduced in r49492 by a plain if.
llvm-svn: 51482
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Scalar/InstructionCombining.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
index d7f5ccf7884..2d300dc68ff 100644
--- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
+++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp
@@ -1096,7 +1096,9 @@ void InstCombiner::ComputeMaskedBits(Value *V, const APInt &Mask,
Value *L = P->getIncomingValue(i);
Value *R = P->getIncomingValue(!i);
User *LU = dyn_cast<User>(L);
- unsigned Opcode = LU ? getOpcode(LU) : (unsigned)Instruction::UserOp1;
+ if (!LU)
+ continue;
+ unsigned Opcode = getOpcode(LU);
// Check for operations that have the property that if
// both their operands have low zero bits, the result
// will have low zero bits.
OpenPOWER on IntegriCloud