Skip to content

Commit 676c495

Browse files
authored
[Attributor][FIX] Register right new created BB. (#84929)
CBBB will keep same after the first iteration so registerManifestAddedBasicBlock would always register the same basic block later. Co-authored-by: laichunfeng <[email protected]>
1 parent 06c06e1 commit 676c495

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/Transforms/IPO/AttributorAttributes.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12371,7 +12371,7 @@ struct AAIndirectCallInfoCallSite : public AAIndirectCallInfo {
1237112371
SplitBlockAndInsertIfThen(LastCmp, IP, /* Unreachable */ false);
1237212372
BasicBlock *CBBB = CB->getParent();
1237312373
A.registerManifestAddedBasicBlock(*ThenTI->getParent());
12374-
A.registerManifestAddedBasicBlock(*CBBB);
12374+
A.registerManifestAddedBasicBlock(*IP->getParent());
1237512375
auto *SplitTI = cast<BranchInst>(LastCmp->getNextNode());
1237612376
BasicBlock *ElseBB;
1237712377
if (&*IP == CB) {

0 commit comments

Comments
 (0)