[mlir][vector] Support N-D vector in InsertMap/ExtractMap op
authorThomas Raoux <thomasraoux@google.com>
Fri, 13 Nov 2020 20:16:47 +0000 (12:16 -0800)
committerThomas Raoux <thomasraoux@google.com>
Fri, 13 Nov 2020 20:40:17 +0000 (12:40 -0800)
commit6ad31c0f4a6192e216ac9137dc093a8268ae11b1
tree645b9e4ab6c95479649256b43e12bd8a2e6e8acc
parent938f1b858104956e1e2d298bbf774a54554e4a9f
[mlir][vector] Support N-D vector in InsertMap/ExtractMap op

Support multi-dimension vector for InsertMap/ExtractMap op and update the
transformations. Currently the relation between IDs and dimension is implicitly
deduced from the types. We can then calculate an AffineMap based on it. In the
future the AffineMap could be part of the operation itself.

Differential Revision: https://reviews.llvm.org/D90995
mlir/include/mlir/Dialect/Vector/VectorOps.td
mlir/include/mlir/Dialect/Vector/VectorTransforms.h
mlir/lib/Dialect/Vector/VectorOps.cpp
mlir/lib/Dialect/Vector/VectorTransforms.cpp
mlir/test/Dialect/Vector/invalid.mlir
mlir/test/Dialect/Vector/ops.mlir
mlir/test/Dialect/Vector/vector-distribution.mlir
mlir/test/lib/Transforms/TestVectorTransforms.cpp