Skip to content

Commit 72e7829

Browse files
committed
[mi-sched] Update comment and add break.
1 parent cefbd38 commit 72e7829

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

llvm/lib/CodeGen/MachineScheduler.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3281,14 +3281,16 @@ void GenericScheduler::initPolicy(MachineBasicBlock::iterator Begin,
32813281

32823282
// Avoid setting up the register pressure tracker for small regions to save
32833283
// compile time. As a rough heuristic, only track pressure when the number of
3284-
// schedulable instructions exceeds half the integer register file.
3284+
// schedulable instructions exceeds half the allocatable integer register file
3285+
// that is the largest legal integer regiser type.
32853286
RegionPolicy.ShouldTrackPressure = true;
32863287
for (unsigned VT = MVT::i64; VT > (unsigned)MVT::i1; --VT) {
32873288
MVT::SimpleValueType LegalIntVT = (MVT::SimpleValueType)VT;
32883289
if (TLI->isTypeLegal(LegalIntVT)) {
32893290
unsigned NIntRegs = Context->RegClassInfo->getNumAllocatableRegs(
32903291
TLI->getRegClassFor(LegalIntVT));
32913292
RegionPolicy.ShouldTrackPressure = NumRegionInstrs > (NIntRegs / 2);
3293+
break;
32923294
}
32933295
}
32943296

0 commit comments

Comments
 (0)