[llvm] r196147 - InlineFunction.cpp: Remove a return value that is always false
Mark Seaborn
mseaborn at chromium.org
Mon Dec 2 12:50:59 PST 2013
Author: mseaborn
Date: Mon Dec 2 14:50:59 2013
New Revision: 196147
URL: http://llvm.org/viewvc/llvm-project?rev=196147&view=rev
Log:
InlineFunction.cpp: Remove a return value that is always false
Remove some associated dead code.
This cleanup is associated with PR17872.
Modified:
llvm/trunk/lib/Transforms/Utils/InlineFunction.cpp
Modified: llvm/trunk/lib/Transforms/Utils/InlineFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Utils/InlineFunction.cpp?rev=196147&r1=196146&r2=196147&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Utils/InlineFunction.cpp (original)
+++ llvm/trunk/lib/Transforms/Utils/InlineFunction.cpp Mon Dec 2 14:50:59 2013
@@ -172,9 +172,7 @@ void InvokeInliningInfo::forwardResume(R
/// invokes. This function analyze BB to see if there are any calls, and if so,
/// it rewrites them to be invokes that jump to InvokeDest and fills in the PHI
/// nodes in that block with the values specified in InvokeDestPHIValues.
-///
-/// Returns true to indicate that the next block should be skipped.
-static bool HandleCallsInBlockInlinedThroughInvoke(BasicBlock *BB,
+static void HandleCallsInBlockInlinedThroughInvoke(BasicBlock *BB,
InvokeInliningInfo &Invoke) {
LandingPadInst *LPI = Invoke.getLandingPadInst();
@@ -223,10 +221,8 @@ static bool HandleCallsInBlockInlinedThr
// Update any PHI nodes in the exceptional block to indicate that there is
// now a new entry in them.
Invoke.addIncomingPHIValuesFor(BB);
- return false;
+ return;
}
-
- return false;
}
/// HandleInlinedInvoke - If we inlined an invoke site, we need to convert calls
@@ -254,11 +250,7 @@ static void HandleInlinedInvoke(InvokeIn
for (Function::iterator BB = FirstNewBlock, E = Caller->end(); BB != E; ++BB){
if (InlinedCodeInfo.ContainsCalls)
- if (HandleCallsInBlockInlinedThroughInvoke(BB, Invoke)) {
- // Honor a request to skip the next block.
- ++BB;
- continue;
- }
+ HandleCallsInBlockInlinedThroughInvoke(BB, Invoke);
// Forward any resumes that are remaining here.
if (ResumeInst *RI = dyn_cast<ResumeInst>(BB->getTerminator()))
More information about the llvm-commits
mailing list