diff options
Diffstat (limited to 'llvm/lib/Transforms/Scalar/SCCP.cpp')
-rw-r--r-- | llvm/lib/Transforms/Scalar/SCCP.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/Transforms/Scalar/SCCP.cpp b/llvm/lib/Transforms/Scalar/SCCP.cpp index c625b0f3362..4d3a708fa20 100644 --- a/llvm/lib/Transforms/Scalar/SCCP.cpp +++ b/llvm/lib/Transforms/Scalar/SCCP.cpp @@ -539,9 +539,9 @@ void SCCPSolver::getFeasibleSuccessors(TerminatorInst &TI, return; } - // Unwinding instructions successors are always executable. - if (TI.isExceptional()) { - Succs.assign(TI.getNumSuccessors(), true); + if (isa<InvokeInst>(TI)) { + // Invoke instructions successors are always executable. + Succs[0] = Succs[1] = true; return; } @@ -605,8 +605,8 @@ bool SCCPSolver::isEdgeFeasible(BasicBlock *From, BasicBlock *To) { return BI->getSuccessor(CI->isZero()) == To; } - // Unwinding instructions successors are always executable. - if (TI->isExceptional()) + // Invoke instructions successors are always executable. + if (isa<InvokeInst>(TI)) return true; if (SwitchInst *SI = dyn_cast<SwitchInst>(TI)) { |