diff options
author | Chris Lattner <sabre@nondot.org> | 2006-01-13 19:18:11 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-01-13 19:18:11 +0000 |
commit | e24f79a03262dd734fb74229c30c7bd5c9b353f0 (patch) | |
tree | 1193aa09237af629b10ba97f0d6808dc6491a130 /llvm/lib/Transforms | |
parent | 19e6a08d7892dc6668356a42c941d30c42d5ba9d (diff) | |
download | bcm5719-llvm-e24f79a03262dd734fb74229c30c7bd5c9b353f0.tar.gz bcm5719-llvm-e24f79a03262dd734fb74229c30c7bd5c9b353f0.zip |
Use ClonedCodeInfo to avoid another walk over the inlined code, this this
time in common C cases.
llvm-svn: 25285
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r-- | llvm/lib/Transforms/Utils/InlineFunction.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/InlineFunction.cpp b/llvm/lib/Transforms/Utils/InlineFunction.cpp index f7b4ab894a3..1b08694ac36 100644 --- a/llvm/lib/Transforms/Utils/InlineFunction.cpp +++ b/llvm/lib/Transforms/Utils/InlineFunction.cpp @@ -215,8 +215,10 @@ bool llvm::InlineFunction(CallSite CS) { } } - // If we are inlining tail call instruction through an invoke or - if (MustClearTailCallFlags) { + // If we are inlining tail call instruction through a call site that isn't + // marked 'tail', we must remove the tail marker for any calls in the inlined + // code. + if (MustClearTailCallFlags && InlinedFunctionInfo.ContainsCalls) { for (Function::iterator BB = FirstNewBlock, E = Caller->end(); BB != E; ++BB) for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E; ++I) |