Skip to content

Commit 8a598f1

Browse files
authored
[NFC] Simplify checks using isDebugOrPseudoInstr API (#145127)
Merge the two checks using the existing API, NFC.
1 parent 11571a0 commit 8a598f1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

llvm/lib/CodeGen/MachineSink.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1209,7 +1209,7 @@ MachineSinking::getBBRegisterPressure(const MachineBasicBlock &MBB,
12091209
MIE = MBB.instr_begin();
12101210
MII != MIE; --MII) {
12111211
const MachineInstr &MI = *std::prev(MII);
1212-
if (MI.isDebugInstr() || MI.isPseudoProbe())
1212+
if (MI.isDebugOrPseudoInstr())
12131213
continue;
12141214
RegisterOperands RegOpers;
12151215
RegOpers.collect(MI, *TRI, *MRI, false, false);

llvm/lib/CodeGen/RegisterPressure.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -858,7 +858,7 @@ void RegPressureTracker::recedeSkipDebugValues() {
858858

859859
void RegPressureTracker::recede(SmallVectorImpl<VRegMaskOrUnit> *LiveUses) {
860860
recedeSkipDebugValues();
861-
if (CurrPos->isDebugInstr() || CurrPos->isPseudoProbe()) {
861+
if (CurrPos->isDebugOrPseudoInstr()) {
862862
// It's possible to only have debug_value and pseudo probe instructions and
863863
// hit the start of the block.
864864
assert(CurrPos == MBB->begin());

0 commit comments

Comments
 (0)