summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-04-15 21:38:06 +0000
committerChris Lattner <sabre@nondot.org>2007-04-15 21:38:06 +0000
commit343c88cdb93ffdc3dc44473cb632b2447fa6517f (patch)
tree44a8849927b72e85723063a6be2b12ffbaa2529e /llvm/lib/Transforms/Utils
parentd3fd9ecb2d3a1eeb1f7268afa115c483806ed576 (diff)
downloadbcm5719-llvm-343c88cdb93ffdc3dc44473cb632b2447fa6517f.tar.gz
bcm5719-llvm-343c88cdb93ffdc3dc44473cb632b2447fa6517f.zip
Fix PR1335 and Transforms/Inline/2007-04-15-InlineEH.ll
llvm-svn: 36090
Diffstat (limited to 'llvm/lib/Transforms/Utils')
-rw-r--r--llvm/lib/Transforms/Utils/InlineFunction.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/Utils/InlineFunction.cpp b/llvm/lib/Transforms/Utils/InlineFunction.cpp
index a1a638b0c2c..9735a2fcda4 100644
--- a/llvm/lib/Transforms/Utils/InlineFunction.cpp
+++ b/llvm/lib/Transforms/Utils/InlineFunction.cpp
@@ -69,10 +69,11 @@ static void HandleInlinedInvoke(InvokeInst *II, BasicBlock *FirstNewBlock,
if (!isa<CallInst>(I)) continue;
CallInst *CI = cast<CallInst>(I);
- // If this is an intrinsic function call, don't convert it to an
- // invoke.
- if (CI->getCalledFunction() &&
- CI->getCalledFunction()->getIntrinsicID())
+ // If this is an intrinsic function call or an inline asm, don't
+ // convert it to an invoke.
+ if ((CI->getCalledFunction() &&
+ CI->getCalledFunction()->getIntrinsicID()) ||
+ isa<InlineAsm>(CI->getCalledValue()))
continue;
// Convert this function call into an invoke instruction.
OpenPOWER on IntegriCloud