[llvm] [AMDGPU] Fix a crash by skipping DBG instrs at start of sched region (PR #131167)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 13 18:06:07 PDT 2025


================
@@ -0,0 +1,30 @@
+# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py UTC_ARGS: --version 5
+# RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx942 -verify-machineinstrs -run-pass=machine-scheduler -o - %s | FileCheck %s
+
+# Verify we maintain live-ins even if the first instruction in sched region is
+# DBG_.
+
+---
+name:            sched
+tracksRegLiveness: true
+registers:
+- { id: 1, class: sgpr_32, preferred-register: '', flags: [  ] }
+- { id: 2, class: sgpr_32, preferred-register: '', flags: [  ] }
----------------
arsenm wrote:

```suggestion
```

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


More information about the llvm-commits mailing list