[llvm-branch-commits] [llvm-branch] r101435 - /llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp

Gabor Greif ggreif at gmail.com
Thu Apr 15 18:29:47 PDT 2010


Author: ggreif
Date: Thu Apr 15 20:29:47 2010
New Revision: 101435

URL: http://llvm.org/viewvc/llvm-project?rev=101435&view=rev
Log:
pull rev. from trunk

Modified:
    llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp   (contents, props changed)

Modified: llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp?rev=101435&r1=101434&r2=101435&view=diff
==============================================================================
--- llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp (original)
+++ llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp Thu Apr 15 20:29:47 2010
@@ -559,7 +559,7 @@
   // Lower all uses of llvm.objectsize.*
   IntrinsicInst *II = dyn_cast<IntrinsicInst>(CI);
   if (II && II->getIntrinsicID() == Intrinsic::objectsize) {
-    bool Min = (cast<ConstantInt>(II->getOperand(2))->getZExtValue() == 1);
+    bool Min = (cast<ConstantInt>(II->getOperand(1))->getZExtValue() == 1);
     const Type *ReturnTy = CI->getType();
     Constant *RetVal = ConstantInt::get(ReturnTy, Min ? 0 : -1ULL);    
     CI->replaceAllUsesWith(RetVal);

Propchange: llvm/branches/ggreif/CallInst-operands/lib/Transforms/Scalar/CodeGenPrepare.cpp
------------------------------------------------------------------------------
    svn:mergeinfo = /llvm/trunk/lib/Transforms/Scalar/CodeGenPrepare.cpp:101423





More information about the llvm-branch-commits mailing list