[llvm-commits] [llvm] r135758 - /llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
Jay Foad
jay.foad at gmail.com
Fri Jul 22 00:54:01 PDT 2011
Author: foad
Date: Fri Jul 22 02:54:01 2011
New Revision: 135758
URL: http://llvm.org/viewvc/llvm-project?rev=135758&view=rev
Log:
Fix an MSVC warning, caused by a case I missed when converting
ConstantExpr::getGetElementPtr to use ArrayRef.
Modified:
llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
Modified: llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp?rev=135758&r1=135757&r2=135758&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp (original)
+++ llvm/trunk/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp Fri Jul 22 02:54:01 2011
@@ -113,7 +113,7 @@
Value *Idxs[2];
Idxs[0] = Constant::getNullValue(Type::getInt32Ty(LI.getContext()));
Idxs[1] = Idxs[0];
- CastOp = ConstantExpr::getGetElementPtr(CSrc, Idxs, 2);
+ CastOp = ConstantExpr::getGetElementPtr(CSrc, Idxs);
SrcTy = cast<PointerType>(CastOp->getType());
SrcPTy = SrcTy->getElementType();
}
More information about the llvm-commits
mailing list