summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils/InlineFunction.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-09-22 23:30:59 +0000
committerChris Lattner <sabre@nondot.org>2003-09-22 23:30:59 +0000
commit50ac360a3496c2199e068a78bd629d78ba01832e (patch)
tree8976bf35442d4f30732cd1a729d9f0cad390b84d /llvm/lib/Transforms/Utils/InlineFunction.cpp
parentd6002b8e15e87610169e8c3988a3b0e6fa5d3850 (diff)
downloadbcm5719-llvm-50ac360a3496c2199e068a78bd629d78ba01832e.tar.gz
bcm5719-llvm-50ac360a3496c2199e068a78bd629d78ba01832e.zip
Fix bugs in the last change
llvm-svn: 8667
Diffstat (limited to 'llvm/lib/Transforms/Utils/InlineFunction.cpp')
-rw-r--r--llvm/lib/Transforms/Utils/InlineFunction.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Utils/InlineFunction.cpp b/llvm/lib/Transforms/Utils/InlineFunction.cpp
index 8f69c1ee161..22377b759c8 100644
--- a/llvm/lib/Transforms/Utils/InlineFunction.cpp
+++ b/llvm/lib/Transforms/Utils/InlineFunction.cpp
@@ -68,7 +68,7 @@ bool InlineFunction(CallSite CS) {
for (BasicBlock::iterator I = InvokeDest->begin();
PHINode *PN = dyn_cast<PHINode>(I); ++I) {
// Save the value to use for this edge...
- InvokeDestPHIValues.push_back(PN->getIncomingValueForBlock(OrigBB));
+ InvokeDestPHIValues.push_back(PN->getIncomingValueForBlock(AfterCallBB));
}
// Remove (unlink) the InvokeInst from the function...
@@ -252,7 +252,7 @@ bool InlineFunction(CallSite CS) {
// PHI node) now.
for (BasicBlock::iterator I = InvokeDest->begin();
PHINode *PN = dyn_cast<PHINode>(I); ++I)
- PN->removeIncomingValue(OrigBB);
+ PN->removeIncomingValue(AfterCallBB);
}
// Now that the function is correct, make it a little bit nicer. In
// particular, move the basic blocks inserted from the end of the function
OpenPOWER on IntegriCloud