[llvm] [MachineCombiner] Don't count debug instructions in block size (PR #225765)

Mikael Holmen via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 5 23:46:21 PDT 2026


================
@@ -632,7 +632,7 @@ bool MachineCombinerImpl::combineInstructions(MachineBasicBlock *MBB) {
       if (DoRegPressureReduce &&
           getCombinerObjective(P) ==
               CombinerObjective::MustReduceRegisterPressure) {
-        if (MBB->size() > inc_threshold) {
+        if (MBB->sizeWithoutDebugLargerThan(inc_threshold)) {
----------------
mikaelholmen wrote:

Now I updated so I pre-commit the testcases in one commit and then apply the fix in a separate commit.

https://github.com/llvm/llvm-project/pull/225765


More information about the llvm-commits mailing list