From: Sanjay Patel Date: Thu, 12 Mar 2015 16:29:58 +0000 (+0000) Subject: make an array of constants explicitly const X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=320572f37885b19df5403c50d66702fa7ef6d5ed;p=oota-llvm.git make an array of constants explicitly const Suggested by Craig Topper in D8184. This goes with r232047. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232056 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/IR/AutoUpgrade.cpp b/lib/IR/AutoUpgrade.cpp index fab6915a7a7..04852dfaf98 100644 --- a/lib/IR/AutoUpgrade.cpp +++ b/lib/IR/AutoUpgrade.cpp @@ -568,7 +568,7 @@ void llvm::UpgradeIntrinsicCall(CallInst *CI, Function *NewFn) { CI->getArgOperand(0), PointerType::getUnqual(VectorType::get(Type::getInt64Ty(C), 2))); Value *Load = Builder.CreateLoad(Op); - int Idxs[4] = { 0, 1, 0, 1 }; + const int Idxs[4] = { 0, 1, 0, 1 }; Rep = Builder.CreateShuffleVector(Load, UndefValue::get(Load->getType()), Idxs); } else if (Name == "llvm.x86.sse2.psll.dq") {