[mlir][vector] Separate high-D insert/extract strided slice rewrite
authorLei Zhang <antiagainst@google.com>
Tue, 5 Apr 2022 18:17:22 +0000 (14:17 -0400)
committerLei Zhang <antiagainst@google.com>
Tue, 5 Apr 2022 19:00:50 +0000 (15:00 -0400)
commit59d3a9e0877b2b12fc98eea0f9bbbc93f3c7a094
treeca36b4b682194641e2b6c0ea2f9029b550899ea0
parent93977f37e67eae26d9bc88e5c3970c11d8861dfc
[mlir][vector] Separate high-D insert/extract strided slice rewrite

Right now `populateVectorInsertExtractStridedSliceTransforms` contains
two categories of patterns, one for decomposing high-D insert/extract
strided slices, the other for lowering them to shuffle ops.
They are at different levels---the former is in the middle, while
the latter is a step of final lowering. Split them to give users
more control of which pattern to pick.

This means break down the previous `VectorExtractStridedSliceOpRewritePattern`,
which is doing two things together.

Also renamed those patterns to be clearer.

Reviewed By: ThomasRaoux

Differential Revision: https://reviews.llvm.org/D123137
mlir/include/mlir/Dialect/Vector/Transforms/VectorRewritePatterns.h
mlir/lib/Dialect/Vector/Transforms/VectorInsertExtractStridedSliceRewritePatterns.cpp