[llvm] [AMDGPU][True16][CodeGen] true16 codegen for bswap (PR #122849)

Brox Chen via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 14 09:47:29 PST 2025


================
@@ -3039,6 +3041,19 @@ def : GCNPat <
   (i32 (zext (bswap i16:$a))),
   (V_PERM_B32_e64  (i32 0), VSrc_b32:$a, (S_MOV_B32 (i32 0x0c0c0001)))
 >;
+}
+
+let True16Predicate = UseRealTrue16Insts in {
----------------
broxigarchen wrote:

Hi Matt. Yes UseRealTrue16Insts implies GFX11Plus

These patterns are also guarded by https://github.com/llvm/llvm-project/blob/98da375b60e2abd033b552854956a5beb9974fca/llvm/lib/Target/AMDGPU/SIInstructions.td#L3008. 

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


More information about the llvm-commits mailing list