aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Transforms/IPO/GlobalOpt.cpp
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2009-07-28 18:32:17 +0000
committerOwen Anderson <resistor@mac.com>2009-07-28 18:32:17 +0000
commit1fd7096407d5e598ed3366a1141548e71273f1c5 (patch)
tree1d75f632724874d39fcab0f961b588afe4dbadbd /lib/Transforms/IPO/GlobalOpt.cpp
parent8e7c38e17b4c3eef8c079004f01329b7bd2bb24a (diff)
downloadexternal_llvm-1fd7096407d5e598ed3366a1141548e71273f1c5.tar.gz
external_llvm-1fd7096407d5e598ed3366a1141548e71273f1c5.tar.bz2
external_llvm-1fd7096407d5e598ed3366a1141548e71273f1c5.zip
Change ConstantArray to 2.5 API.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77347 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/IPO/GlobalOpt.cpp')
-rw-r--r--lib/Transforms/IPO/GlobalOpt.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Transforms/IPO/GlobalOpt.cpp b/lib/Transforms/IPO/GlobalOpt.cpp
index 2989e2827f..bf01812bd7 100644
--- a/lib/Transforms/IPO/GlobalOpt.cpp
+++ b/lib/Transforms/IPO/GlobalOpt.cpp
@@ -1968,7 +1968,7 @@ static GlobalVariable *InstallGlobalCtors(GlobalVariable *GCL,
// Create the array initializer.
const Type *StructTy =
cast<ArrayType>(GCL->getType()->getElementType())->getElementType();
- Constant *CA = Context.getConstantArray(ArrayType::get(StructTy,
+ Constant *CA = ConstantArray::get(ArrayType::get(StructTy,
CAList.size()), CAList);
// If we didn't change the number of elements, don't create a new GV.
@@ -2094,7 +2094,7 @@ static Constant *EvaluateStoreInto(Constant *Init, Constant *Val,
assert(CI->getZExtValue() < ATy->getNumElements());
Elts[CI->getZExtValue()] =
EvaluateStoreInto(Elts[CI->getZExtValue()], Val, Addr, OpNo+1, Context);
- return Context.getConstantArray(ATy, Elts);
+ return ConstantArray::get(ATy, Elts);
}
}