[llvm] [AMDGPU] Do not fold COPY with implicit operands (PR #136003)

Carl Ritson via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 17 23:17:54 PDT 2025


================
@@ -0,0 +1,36 @@
+# RUN: llc -mtriple=amdgcn -mcpu=gfx900 -run-pass=si-fold-operands -o - %s | FileCheck %s
+
+---
+liveins:
+name:            do_not_fold_copy_with_implicit_exec
+tracksRegLiveness: true
+body:             |
+  ; CHECK: bb.0:
+  ; CHECK: bb.1:
+  ; CHECK: %[[A:[0-9]*]]:sreg_32 = S_ADD_I32
+  ; CHECK: COPY %[[A]]
+  ; CHECKL SI_LOOP
----------------
perlfu wrote:

I think it is preferable to autogenerate this, so we can see if/when ISA changes in future.
(We may want to re-enable this fold in future with some kind of EXEC analysis.)

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


More information about the llvm-commits mailing list