[llvm-commits] [llvm] r63787 - in /llvm/branches/release_25: lib/Transforms/Utils/InlineFunction.cpp test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll
Tanya Lattner
tonic at nondot.org
Wed Feb 4 14:54:57 PST 2009
Author: tbrethou
Date: Wed Feb 4 16:54:57 2009
New Revision: 63787
URL: http://llvm.org/viewvc/llvm-project?rev=63787&view=rev
Log:
Merge from mainline.
Revert r63600.
Removed:
llvm/branches/release_25/test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll
Modified:
llvm/branches/release_25/lib/Transforms/Utils/InlineFunction.cpp
Modified: llvm/branches/release_25/lib/Transforms/Utils/InlineFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_25/lib/Transforms/Utils/InlineFunction.cpp?rev=63787&r1=63786&r2=63787&view=diff
==============================================================================
--- llvm/branches/release_25/lib/Transforms/Utils/InlineFunction.cpp (original)
+++ llvm/branches/release_25/lib/Transforms/Utils/InlineFunction.cpp Wed Feb 4 16:54:57 2009
@@ -41,8 +41,7 @@
/// block of the inlined code (the last block is the end of the function),
/// and InlineCodeInfo is information about the code that got inlined.
static void HandleInlinedInvoke(InvokeInst *II, BasicBlock *FirstNewBlock,
- ClonedCodeInfo &InlinedCodeInfo,
- CallGraph *CG) {
+ ClonedCodeInfo &InlinedCodeInfo) {
BasicBlock *InvokeDest = II->getUnwindDest();
std::vector<Value*> InvokeDestPHIValues;
@@ -94,10 +93,6 @@
// Make sure that anything using the call now uses the invoke!
CI->replaceAllUsesWith(II);
- // Update the callgraph.
- if (CG)
- (*CG)[Caller]->replaceCallSite(CI, II);
-
// Delete the unconditional branch inserted by splitBasicBlock
BB->getInstList().pop_back();
Split->getInstList().pop_front(); // Delete the original call
@@ -438,7 +433,7 @@
// any inlined 'unwind' instructions into branches to the invoke exception
// destination, and call instructions into invoke instructions.
if (InvokeInst *II = dyn_cast<InvokeInst>(TheCall))
- HandleInlinedInvoke(II, FirstNewBlock, InlinedFunctionInfo, CG);
+ HandleInlinedInvoke(II, FirstNewBlock, InlinedFunctionInfo);
// If we cloned in _exactly one_ basic block, and if that block ends in a
// return instruction, we splice the body of the inlined callee directly into
Removed: llvm/branches/release_25/test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_25/test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll?rev=63786&view=auto
==============================================================================
--- llvm/branches/release_25/test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll (original)
+++ llvm/branches/release_25/test/Transforms/Inline/2009-02-02-InvokeUpdateCG.ll (removed)
@@ -1,32 +0,0 @@
-; RUN: llvm-as < %s | opt -inline -prune-eh
-; PR3367
-
-define void @f2() {
- invoke void @f6()
- to label %ok1 unwind label %lpad1
-
-ok1:
- ret void
-
-lpad1:
- invoke void @f4()
- to label %ok2 unwind label %lpad2
-
-ok2:
- call void @f8()
- unreachable
-
-lpad2:
- unreachable
-}
-
-declare void @f3()
-
-define void @f4() {
- call void @f3()
- ret void
-}
-
-declare void @f6() nounwind
-
-declare void @f8()
More information about the llvm-commits
mailing list