Skip to content

Commit

Permalink
[fix] Improve CallSplitter
Browse files Browse the repository at this point in the history
  • Loading branch information
misonijnik committed Nov 11, 2022
1 parent 72b0bb9 commit 964412c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Module/CallSplitter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ bool CallSplitter::runOnFunction(Function &F) {
if (callInst != firstInst) {
fbb = fbb->splitBasicBlock(callInst);
}
if (afterCallInst->isTerminator() && !isa<InvokeInst>(afterCallInst) &&
!isa<ReturnInst>(afterCallInst)) {
if (isa<BranchInst>(afterCallInst) &&
cast<BranchInst>(afterCallInst)->isUnconditional()) {
break;
}
fbb = fbb->splitBasicBlock(afterCallInst);
Expand Down

0 comments on commit 964412c

Please sign in to comment.