[Mlir-commits] [mlir] [mlir][vector] Document dimension kinds in `vector.contract` (NFC) (PR #230458)
Federico Bruzzone
llvmlistbot at llvm.org
Fri Oct 9 04:32:04 PDT 2026
https://github.com/FedericoBruzzone created https://github.com/llvm/llvm-project/pull/230458
Add a table to the vector.contract description summarizing _batch_, _free_, _contracting_, and _single-operand reduction_ dimensions.
Related to #230155.
>From 71a3e5ccecaaa2900687e5bba7a87443d1b6cfcf Mon Sep 17 00:00:00 2001
From: Federico Bruzzone <federico.bruzzone.i at gmail.com>
Date: Fri, 9 Oct 2026 13:28:03 +0200
Subject: [PATCH] [mlir][vector] Document dimension kinds in `vector.contract`
Signed-off-by: Federico Bruzzone <federico.bruzzone.i at gmail.com>
---
mlir/include/mlir/Dialect/Vector/IR/VectorOps.td | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/mlir/include/mlir/Dialect/Vector/IR/VectorOps.td b/mlir/include/mlir/Dialect/Vector/IR/VectorOps.td
index 3309e8a546a5e4..468d04c5891ef2 100644
--- a/mlir/include/mlir/Dialect/Vector/IR/VectorOps.td
+++ b/mlir/include/mlir/Dialect/Vector/IR/VectorOps.td
@@ -100,6 +100,16 @@ def Vector_ContractionOp :
are unrelated to each other and do not co-iterate, which
should be expressed in their indexing maps.
+ Depending on its iterator type and on the operands it indexes, a dimension
+ is one of the following kinds:
+
+ | Iterator type | In output | In lhs and rhs | Kind |
+ | ------------- | --------- | -------------- | -------------------------- |
+ | "parallel" | yes | both | batch |
+ | "parallel" | yes | one of them | free |
+ | "reduction" | no | both | contracting |
+ | "reduction" | no | one of them | reduction on one operand |
+
An indexing map attribute list must be specified with an entry for lhs, rhs
and acc arguments. An indexing map attribute specifies a mapping from each
iterator in the iterator type list, to each dimension of an N-D vector.
More information about the Mlir-commits
mailing list