diff options
author | Chris Lattner <sabre@nondot.org> | 2004-02-08 21:44:31 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-02-08 21:44:31 +0000 |
commit | fae8ab3088e339af403014983165abeebc202740 (patch) | |
tree | 1892cd47e93d7ea36a7f6b8051375654c9b6741f /llvm/lib/Transforms | |
parent | 35630adf54118c97f9bcc5c025eeb69df3ff7a39 (diff) | |
download | bcm5719-llvm-fae8ab3088e339af403014983165abeebc202740.tar.gz bcm5719-llvm-fae8ab3088e339af403014983165abeebc202740.zip |
rename the "exceptional" destination of an invoke instruction to the 'unwind' dest
llvm-svn: 11202
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r-- | llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/Transforms/IPO/LowerSetJmp.cpp | 4 | ||||
-rw-r--r-- | llvm/lib/Transforms/IPO/PruneEH.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 4 | ||||
-rw-r--r-- | llvm/lib/Transforms/Scalar/LowerInvoke.cpp | 4 | ||||
-rw-r--r-- | llvm/lib/Transforms/Utils/InlineFunction.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/Transforms/Utils/SimplifyCFG.cpp | 2 |
7 files changed, 10 insertions, 10 deletions
diff --git a/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp b/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp index 27757614cec..19b61907beb 100644 --- a/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp +++ b/llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp @@ -424,7 +424,7 @@ void DAE::RemoveDeadArgumentsFromFunction(Function *F) { Instruction *New; if (InvokeInst *II = dyn_cast<InvokeInst>(Call)) { - New = new InvokeInst(NF, II->getNormalDest(), II->getExceptionalDest(), + New = new InvokeInst(NF, II->getNormalDest(), II->getUnwindDest(), Args, "", Call); } else { New = new CallInst(NF, Args, "", Call); diff --git a/llvm/lib/Transforms/IPO/LowerSetJmp.cpp b/llvm/lib/Transforms/IPO/LowerSetJmp.cpp index a2146f47de7..f79ab0dbf7d 100644 --- a/llvm/lib/Transforms/IPO/LowerSetJmp.cpp +++ b/llvm/lib/Transforms/IPO/LowerSetJmp.cpp @@ -489,7 +489,7 @@ void LowerSetJmp::visitInvokeInst(InvokeInst& II) if (!DFSBlocks.count(BB)) return; BasicBlock* NormalBB = II.getNormalDest(); - BasicBlock* ExceptBB = II.getExceptionalDest(); + BasicBlock* ExceptBB = II.getUnwindDest(); Function* Func = BB->getParent(); BasicBlock* NewExceptBB = new BasicBlock("InvokeExcept", Func); @@ -503,7 +503,7 @@ void LowerSetJmp::visitInvokeInst(InvokeInst& II) new BranchInst(PrelimBBMap[Func], ExceptBB, IsLJExcept, NewExceptBB); - II.setExceptionalDest(NewExceptBB); + II.setUnwindDest(NewExceptBB); ++InvokesTransformed; } diff --git a/llvm/lib/Transforms/IPO/PruneEH.cpp b/llvm/lib/Transforms/IPO/PruneEH.cpp index 7c0a73e19be..7c4fc221c96 100644 --- a/llvm/lib/Transforms/IPO/PruneEH.cpp +++ b/llvm/lib/Transforms/IPO/PruneEH.cpp @@ -113,7 +113,7 @@ bool PruneEH::runOnSCC(const std::vector<CallGraphNode *> &SCC) { // Anything that used the value produced by the invoke instruction // now uses the value produced by the call instruction. II->replaceAllUsesWith(Call); - II->getExceptionalDest()->removePredecessor(II->getParent()); + II->getUnwindDest()->removePredecessor(II->getParent()); // Insert a branch to the normal destination right before the // invoke. diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 8a089555b8d..85d580b8ce5 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -1839,7 +1839,7 @@ bool InstCombiner::transformConstExprCastCall(CallSite CS) { UI != E; ++UI) if (PHINode *PN = dyn_cast<PHINode>(*UI)) if (PN->getParent() == II->getNormalDest() || - PN->getParent() == II->getExceptionalDest()) + PN->getParent() == II->getUnwindDest()) return false; } @@ -1904,7 +1904,7 @@ bool InstCombiner::transformConstExprCastCall(CallSite CS) { Instruction *NC; if (InvokeInst *II = dyn_cast<InvokeInst>(Caller)) { - NC = new InvokeInst(Callee, II->getNormalDest(), II->getExceptionalDest(), + NC = new InvokeInst(Callee, II->getNormalDest(), II->getUnwindDest(), Args, Caller->getName(), Caller); } else { NC = new CallInst(Callee, Args, Caller->getName(), Caller); diff --git a/llvm/lib/Transforms/Scalar/LowerInvoke.cpp b/llvm/lib/Transforms/Scalar/LowerInvoke.cpp index bd9c8bcc3e3..83294653ef3 100644 --- a/llvm/lib/Transforms/Scalar/LowerInvoke.cpp +++ b/llvm/lib/Transforms/Scalar/LowerInvoke.cpp @@ -169,7 +169,7 @@ bool LowerInvoke::insertCheapEHSupport(Function &F) { new BranchInst(II->getNormalDest(), II); // Remove any PHI node entries from the exception destination. - II->getExceptionalDest()->removePredecessor(BB); + II->getUnwindDest()->removePredecessor(BB); // Remove the invoke instruction now. BB->getInstList().erase(II); @@ -256,7 +256,7 @@ bool LowerInvoke::insertExpensiveEHSupport(Function &F) { new StoreInst(OldEntry, JBListHead, InsertLoc); // Now we change the invoke into a branch instruction. - new BranchInst(II->getNormalDest(), II->getExceptionalDest(), IsNormal, II); + new BranchInst(II->getNormalDest(), II->getUnwindDest(), IsNormal, II); // Remove the InvokeInst now. BB->getInstList().erase(II); diff --git a/llvm/lib/Transforms/Utils/InlineFunction.cpp b/llvm/lib/Transforms/Utils/InlineFunction.cpp index 8edf9d071b1..3c886596983 100644 --- a/llvm/lib/Transforms/Utils/InlineFunction.cpp +++ b/llvm/lib/Transforms/Utils/InlineFunction.cpp @@ -106,7 +106,7 @@ bool llvm::InlineFunction(CallSite CS) { // any inlined 'unwind' instructions into branches to the invoke exception // destination, and call instructions into invoke instructions. if (InvokeInst *II = dyn_cast<InvokeInst>(TheCall)) { - BasicBlock *InvokeDest = II->getExceptionalDest(); + BasicBlock *InvokeDest = II->getUnwindDest(); std::vector<Value*> InvokeDestPHIValues; // If there are PHI nodes in the exceptional destination block, we need to diff --git a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp index b827123e609..8aec92a9f4d 100644 --- a/llvm/lib/Transforms/Utils/SimplifyCFG.cpp +++ b/llvm/lib/Transforms/Utils/SimplifyCFG.cpp @@ -115,7 +115,7 @@ bool llvm::SimplifyCFG(BasicBlock *BB) { while (!Preds.empty()) { BasicBlock *Pred = Preds.back(); if (InvokeInst *II = dyn_cast<InvokeInst>(Pred->getTerminator())) - if (II->getExceptionalDest() == BB) { + if (II->getUnwindDest() == BB) { // Insert a new branch instruction before the invoke, because this // is now a fall through... BranchInst *BI = new BranchInst(II->getNormalDest(), II); |