[Mlir-commits] [mlir] [mlir][AMDGPU] Add PermlaneOp (PR #154345)

Jakub Kuderski llvmlistbot at llvm.org
Thu Aug 21 07:10:17 PDT 2025


================
@@ -656,6 +656,60 @@ def AMDGPU_SwizzleBitModeOp : AMDGPU_Op<"swizzle_bitmode",
   }];
 }
 
+def AMDGPU_PermlanePerm : I32EnumAttr<"PermlanePerm",
+    "The possible permutations for a permlane operation",
+    [
+      I32EnumAttrCase<"swap_16",  0>,
+      I32EnumAttrCase<"swap_32",  1>,
+    ]> {
+  let genSpecializedAttr = 0;
+  let cppNamespace = "::mlir::amdgpu";
+}
+
+def AMDGPU_PermlanePermAttr : EnumAttr<AMDGPU_Dialect, AMDGPU_PermlanePerm,
+  "permlane_perm">;
+
+def AMDGPU_PermlaneOp : AMDGPU_Op<"permlane", [Pure, AllTypesMatch<["result", "src"]>]> {
+  let summary = "AMDGPU permlane op";
+  let description = [{
+    High-level wrapper on `rocdl.permlane.*` variants for permutations
+     on rows of lanes in a subgroup.
----------------
kuhar wrote:

```suggestion
    High-level wrapper on `rocdl.permlane.*` variants for permutations
    on rows of lanes in a subgroup.
```

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


More information about the Mlir-commits mailing list