diff options
author | Chris Lattner <sabre@nondot.org> | 2008-11-21 16:42:48 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-11-21 16:42:48 +0000 |
commit | 824b958e6fb1236e92e4d07f3acf18fca107cdc0 (patch) | |
tree | f91d265e59851bb2409eb6784c8a83b1d18b8267 /lib/Transforms/Utils/InlineFunction.cpp | |
parent | dc770929cb2f97397970e2942b746839fc387992 (diff) | |
download | external_llvm-824b958e6fb1236e92e4d07f3acf18fca107cdc0.zip external_llvm-824b958e6fb1236e92e4d07f3acf18fca107cdc0.tar.gz external_llvm-824b958e6fb1236e92e4d07f3acf18fca107cdc0.tar.bz2 |
reapply Sanjiv's patch to genericize memcpy/memset/memmove to take an
arbitrary integer width for the count.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@59823 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/InlineFunction.cpp')
-rw-r--r-- | lib/Transforms/Utils/InlineFunction.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Transforms/Utils/InlineFunction.cpp b/lib/Transforms/Utils/InlineFunction.cpp index 26b4de5..49131e8 100644 --- a/lib/Transforms/Utils/InlineFunction.cpp +++ b/lib/Transforms/Utils/InlineFunction.cpp @@ -257,8 +257,10 @@ bool llvm::InlineFunction(CallSite CS, CallGraph *CG, const TargetData *TD) { Value *NewAlloca = new AllocaInst(AggTy, 0, Align, I->getName(), Caller->begin()->begin()); // Emit a memcpy. + const Type *Tys[] = { Type::Int64Ty }; Function *MemCpyFn = Intrinsic::getDeclaration(Caller->getParent(), - Intrinsic::memcpy_i64); + Intrinsic::memcpy, + Tys, 1); Value *DestCast = new BitCastInst(NewAlloca, VoidPtrTy, "tmp", TheCall); Value *SrcCast = new BitCastInst(*AI, VoidPtrTy, "tmp", TheCall); |