[llvm-branch-commits] [llvm-branch] r100796 - /llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp

Gabor Greif ggreif at gmail.com
Thu Apr 8 11:31:51 PDT 2010


Author: ggreif
Date: Thu Apr  8 13:31:51 2010
New Revision: 100796

URL: http://llvm.org/viewvc/llvm-project?rev=100796&view=rev
Log:
shift inlineasm operand

Modified:
    llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp

Modified: llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp?rev=100796&r1=100795&r2=100796&view=diff
==============================================================================
--- llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp (original)
+++ llvm/branches/ggreif/CallInst-operands/lib/Target/X86/X86ISelLowering.cpp Thu Apr  8 13:31:51 2010
@@ -9907,7 +9907,7 @@
 
   // Verify this is a simple bswap.
   if (CI->getNumOperands() != 2 ||
-      CI->getType() != CI->getOperand(1)->getType() ||
+      CI->getType() != CI->getOperand(0)->getType() ||
       !CI->getType()->isIntegerTy())
     return false;
 
@@ -9920,7 +9920,7 @@
   Module *M = CI->getParent()->getParent()->getParent();
   Constant *Int = Intrinsic::getDeclaration(M, Intrinsic::bswap, Tys, 1);
 
-  Value *Op = CI->getOperand(1);
+  Value *Op = CI->getOperand(0);
   Op = CallInst::Create(Int, Op, CI->getName(), CI);
 
   CI->replaceAllUsesWith(Op);





More information about the llvm-branch-commits mailing list