[cfe-commits] r85373 - /cfe/trunk/lib/CodeGen/CGExpr.cpp
Chris Lattner
sabre at nondot.org
Tue Oct 27 22:12:08 PDT 2009
Author: lattner
Date: Wed Oct 28 00:12:07 2009
New Revision: 85373
URL: http://llvm.org/viewvc/llvm-project?rev=85373&view=rev
Log:
adjust for a pending LLVM change.
Modified:
cfe/trunk/lib/CodeGen/CGExpr.cpp
Modified: cfe/trunk/lib/CodeGen/CGExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGExpr.cpp?rev=85373&r1=85372&r2=85373&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CGExpr.cpp (original)
+++ cfe/trunk/lib/CodeGen/CGExpr.cpp Wed Oct 28 00:12:07 2009
@@ -1088,12 +1088,12 @@
llvm::Constant *BaseElts = Base.getExtVectorElts();
llvm::SmallVector<llvm::Constant *, 4> CElts;
+ const llvm::Type *Int32Ty = llvm::Type::getInt32Ty(VMContext);
for (unsigned i = 0, e = Indices.size(); i != e; ++i) {
if (isa<llvm::ConstantAggregateZero>(BaseElts))
- CElts.push_back(llvm::ConstantInt::get(
- llvm::Type::getInt32Ty(VMContext), 0));
+ CElts.push_back(llvm::ConstantInt::get(Int32Ty, 0));
else
- CElts.push_back(BaseElts->getOperand(Indices[i]));
+ CElts.push_back(cast<llvm::Constant>(BaseElts->getOperand(Indices[i])));
}
llvm::Constant *CV = llvm::ConstantVector::get(&CElts[0], CElts.size());
return LValue::MakeExtVectorElt(Base.getExtVectorAddr(), CV,
More information about the cfe-commits
mailing list