[llvm-commits] [llvm] r51482 - /llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp
Matthijs Kooijman
matthijs at stdin.nl
Fri May 23 09:17:48 PDT 2008
Author: matthijs
Date: Fri May 23 11:17:48 2008
New Revision: 51482
URL: http://llvm.org/viewvc/llvm-project?rev=51482&view=rev
Log:
Replace some weird usage of UserOp1 introduced in r49492 by a plain if.
Modified:
llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp
Modified: llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp?rev=51482&r1=51481&r2=51482&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp (original)
+++ llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp Fri May 23 11:17:48 2008
@@ -1096,7 +1096,9 @@
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.
More information about the llvm-commits
mailing list