File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -1132,11 +1132,13 @@ MachineBlockPlacement::getBestTrellisSuccessor(
11321132 for (auto *Succ : ViableSuccs) {
11331133 for (MachineBasicBlock *SuccPred : Succ->predecessors ()) {
11341134 // Skip any placed predecessors that are not BB
1135- if (SuccPred != BB)
1136- if ((BlockFilter && !BlockFilter->count (SuccPred)) ||
1137- BlockToChain[SuccPred] == &Chain ||
1138- BlockToChain[SuccPred] == BlockToChain[Succ])
1135+ if (SuccPred != BB) {
1136+ if (BlockFilter && !BlockFilter->count (SuccPred))
11391137 continue ;
1138+ const BlockChain *SuccPredChain = BlockToChain[SuccPred];
1139+ if (SuccPredChain == &Chain || SuccPredChain == BlockToChain[Succ])
1140+ continue ;
1141+ }
11401142 BlockFrequency EdgeFreq = MBFI->getBlockFreq (SuccPred) *
11411143 MBPI->getEdgeProbability (SuccPred, Succ);
11421144 Edges[SuccIndex].push_back ({EdgeFreq, SuccPred, Succ});
You can’t perform that action at this time.
0 commit comments