summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2011-09-28 03:47:11 +0000
committerBill Wendling <isanbard@gmail.com>2011-09-28 03:47:11 +0000
commiteef108d5608c50742450a36ed6149e040b14a988 (patch)
treef9c7a4b6750c16651b9fd6cd5af7a2cee13af800 /lib
parent6ef94175d1bbab95f195770bb3c559b3ab38c4e5 (diff)
downloadllvm-eef108d5608c50742450a36ed6149e040b14a988.tar.gz
llvm-eef108d5608c50742450a36ed6149e040b14a988.tar.bz2
llvm-eef108d5608c50742450a36ed6149e040b14a988.tar.xz
Bitcast the alloca to an i8* to match the intrinsic's signature.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140677 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/SjLjEHPrepare.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/CodeGen/SjLjEHPrepare.cpp b/lib/CodeGen/SjLjEHPrepare.cpp
index 9749a7e119..c9be9b3a5d 100644
--- a/lib/CodeGen/SjLjEHPrepare.cpp
+++ b/lib/CodeGen/SjLjEHPrepare.cpp
@@ -725,7 +725,10 @@ void SjLjEHPass::setupFunctionContext(Function &F,
// where to look for it.
CallInst::Create(Intrinsic::getDeclaration(F.getParent(),
Intrinsic::eh_sjlj_functioncontext),
- FuncCtx, "", EntryBB->getTerminator());
+ CastInst::Create(Instruction::BitCast, FuncCtx,
+ Type::getInt8PtrTy(F.getContext()), "",
+ EntryBB->getTerminator()),
+ "", EntryBB->getTerminator());
// Fill in the function context structure.
Value *Idxs[2];