File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed
mlir/include/mlir/Dialect/XeGPU/IR Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -330,4 +330,25 @@ def XeGPU_LayoutAttr : XeGPUAttr<"Layout", "layout"> {
330330 let genVerifyDecl = 1;
331331}
332332
333+
334+ def XeGPU_SliceAttr : XeGPUAttr<"Slice", "slice"> {
335+ let summary = [{Describes the data distribution and sharing among subgroups or work-items.}];
336+
337+ let description = [{
338+ Like LayoutAttr, SliceAttr describes data distribution among subgroups or work-items.
339+ However, whereas LayoutAttr requires the data to have the same rank as the attribute,
340+ SliceAttr permits the data to have a lower rank. In this case, compute units in the
341+ specified dimensions share the data, provided that the remaining ranks match the data
342+ rank. SliceAttr is commonly used by operations such as vector.multi_reduction and
343+ vector.broadcast.
344+ }];
345+
346+ let parameters = (ins
347+ "Attribute": $parent,
348+ "DenseI64ArrayAttr": $dims
349+ );
350+
351+ let assemblyFormat = "`<` $parent `,` `dim` `=` $dims `>`";
352+ }
353+
333354#endif // MLIR_DIALECT_XEGPU_IR_XEGPUATTRS_TD
You can’t perform that action at this time.
0 commit comments