[llvm] [AMDGPU] Use AMDGPUMnemonicAlias in DS_Real_gfx13 (NFC) (PR #217912)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 21 11:14:35 PDT 2026


llvmorg-github-actions[bot] wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-backend-amdgpu

Author: Ketan Roy (MrRoy09)

<details>
<summary>Changes</summary>

Emit an AMDGPUMnemonicAlias in DS_Real_gfx13 so it carries the
PredicateControl fields.

NFC: 46 gfx13 aliases gain the PredicateControl fields at their
defaults; Predicates is unchanged on all of them.


---
Full diff: https://github.com/llvm/llvm-project/pull/217912.diff


1 Files Affected:

- (modified) llvm/lib/Target/AMDGPU/DSInstructions.td (+9-7) 


``````````diff
diff --git a/llvm/lib/Target/AMDGPU/DSInstructions.td b/llvm/lib/Target/AMDGPU/DSInstructions.td
index 90713dfc1de7b..107aa263ac4e3 100644
--- a/llvm/lib/Target/AMDGPU/DSInstructions.td
+++ b/llvm/lib/Target/AMDGPU/DSInstructions.td
@@ -1444,13 +1444,15 @@ multiclass DS_Real_gfx12<bits<8> op,
 multiclass DS_Real_gfx13<bits<8> op,
                          DS_Pseudo ps = !cast<DS_Pseudo>(NAME),
                          string name = !tolower(NAME)> {
-  let AssemblerPredicate = isGFX13Only, DecoderNamespace = "GFX13" in
-    def _gfx13 :
-      Base_DS_Real_gfx6_gfx7_gfx10_gfx11_gfx12_gfx13<op, ps,
-                                                     SIEncodingFamily.GFX13,
-                                                     name, /*hasGDS=*/false>;
-  if !ne(ps.Mnemonic, name) then
-    def : MnemonicAlias<ps.Mnemonic, name>, Requires<[isGFX13Only]>;
+  let AssemblerPredicate = isGFX13Only in {
+    let DecoderNamespace = "GFX13" in
+      def _gfx13 :
+        Base_DS_Real_gfx6_gfx7_gfx10_gfx11_gfx12_gfx13<op, ps,
+                                                       SIEncodingFamily.GFX13,
+                                                       name, /*hasGDS=*/false>;
+    if !ne(ps.Mnemonic, name) then
+      def : AMDGPUMnemonicAlias<ps.Mnemonic, name>;
+  } // End AssemblerPredicate
 }
 
 // Helper to avoid repeating the pseudo-name if we only need to set

``````````

</details>


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


More information about the llvm-commits mailing list