[Mlir-commits] [mlir] [mlir][Vector] Update v.contract -> v.outerproduct tests (NFC) (PR #70449)

Andrzej WarzyƄski llvmlistbot at llvm.org
Fri Oct 27 07:25:58 PDT 2023


================
@@ -141,48 +92,66 @@ func.func @matmul(%arg0: vector<2x4xf32>,
 //
 //      CHECK: return %[[c3]] : vector<2x[3]xf32>
 func.func @matmul_scalable(%arg0: vector<2x4xf32>,
-                          %arg1: vector<4x[3]xf32>,
-                          %arg2: vector<2x[3]xf32>) -> vector<2x[3]xf32> {
-  %0 = vector.contract #matmat_trait %arg0, %arg1, %arg2
+                           %arg1: vector<4x[3]xf32>,
+                           %arg2: vector<2x[3]xf32>) -> vector<2x[3]xf32> {
+  %0 = vector.contract #matmat_trait_0 %arg0, %arg1, %arg2
     : vector<2x4xf32>, vector<4x[3]xf32> into vector<2x[3]xf32>
   return %0 : vector<2x[3]xf32>
 }
 
-// CHECK-LABEL: func @matmul_0
----------------
banach-space wrote:

Almost, so:
* `@masked_extract_contract4` -> `@masked_matmul` (for consistency),
* `@matmul_0` duplicates `@matmul`, so is deleted (the latter has more complete `CHECK` lines). The dimensions are a bit different, but it's the indexing maps that matter here, so I'm not concerned.

I could've done much better job documenting this in the summary, sorry. Also, only after a few iterations the duplication becomes apparent.

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


More information about the Mlir-commits mailing list