[Mlir-commits] [mlir] [MLIR][Linalg] Introduce SpecializeOp (PR #70326)

Nicolas Vasilache llvmlistbot at llvm.org
Tue Oct 31 00:33:50 PDT 2023


================
@@ -390,6 +390,43 @@ def GeneralizeOp : Op<Transform_Dialect, "structured.generalize",
   }];
 }
 
+//===----------------------------------------------------------------------===//
+// SpecializeOp
+//===----------------------------------------------------------------------===//
+
+def SpecializeOp : Op<Transform_Dialect, "structured.specialize",
+    [FunctionalStyleTransformOpTrait, MemoryEffectsOpInterface,
+     TransformOpInterface, TransformEachOpTrait,
+     ReportTrackingListenerFailuresOpTrait]> {
+  let description = [{
+    Transforms a generic operation into the equivalent named form.
+
+    #### Return modes
+
+    This operation ignores non-Linalg ops and drops them in the return. If all
+    the operations referred to by the `target` handle specialize, the transform
+    succeeds; otherwise, the operation produces a silenceable failure.  The return
+    handle points to only the subset of successfully produced equivalent named
+    operations, which can be empty or contain the original ops if they were already
+    in named form.  Only linalg.copy specialization is available, but more will
----------------
nicolasvasilache wrote:

Can we rephrase the last sentence in a new paragraph with an itemized list that we can expand in the future?
```
The supported specializations to named Linalg operations are:
  - linalg.copy of any rank
```

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


More information about the Mlir-commits mailing list