[Mlir-commits] [mlir] [mlir][ArmSME] Add initial SME vector legalization pass (PR #79152)

Andrzej WarzyƄski llvmlistbot at llvm.org
Fri Jan 26 01:21:33 PST 2024


================
@@ -122,4 +122,23 @@ def TileAllocation
   let dependentDialects = ["func::FuncDialect"];
 }
 
+def VectorLegalization
+  : Pass<"arm-sme-vector-legalization", "mlir::ModuleOp"> {
+  let summary = "Legalize vectors for ArmSME";
+  let description = [{
+    This pass legalizes vector operations so that they can be lowered to ArmSME.
+    This includes decomposing operations that operate on vector types larger
+    than a single SME tile (e.g. `vector<[8]x[8]xf32>`) into multiple SME
----------------
banach-space wrote:

Right - but are there any limitations? I know that there are -  those are effectively enforced by `isMultipleOfSMETileVectorType`, right? It would be good add a few more comments here, e.g.:
* "legal" in this context means something that matches SMEs virtual tiles as available in hardware
* "input" type must be a multiple of these tiles (so definitely 2d and scalable in both dimensions)

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


More information about the Mlir-commits mailing list