[all-commits] [llvm/llvm-project] ddf93a: [mlir][linalg] NFC: Move makeTiledShapes into Util...
Lei Zhang via All-commits
all-commits at lists.llvm.org
Wed Mar 24 15:19:45 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: ddf93abf49f7b753e8554fa47a4aaf811f40210a
https://github.com/llvm/llvm-project/commit/ddf93abf49f7b753e8554fa47a4aaf811f40210a
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/include/mlir/Dialect/Linalg/Utils/Utils.h
M mlir/lib/Dialect/Linalg/Transforms/Tiling.cpp
M mlir/lib/Dialect/Linalg/Utils/Utils.cpp
Log Message:
-----------
[mlir][linalg] NFC: Move makeTiledShapes into Utils.{h|cpp}
This is a preparation step to reuse makeTiledShapes in tensor
fusion. Along the way, did some lightweight cleanups.
Differential Revision: https://reviews.llvm.org/D99013
Commit: e58597ee1c7dfe4fd2fdf6f5f0230f22b849c9be
https://github.com/llvm/llvm-project/commit/e58597ee1c7dfe4fd2fdf6f5f0230f22b849c9be
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/lib/Dialect/Linalg/Transforms/Fusion.cpp
M mlir/lib/Dialect/Linalg/Utils/Utils.cpp
M mlir/test/Dialect/Linalg/fusion-pattern.mlir
M mlir/test/Dialect/Linalg/fusion-sequence.mlir
M mlir/test/Dialect/Linalg/fusion-tensor-pattern.mlir
M mlir/test/Dialect/Linalg/fusion.mlir
M mlir/test/Dialect/Linalg/tile-and-fuse-tensors.mlir
M mlir/test/lib/Transforms/TestLinalgFusionTransforms.cpp
Log Message:
-----------
[mlir][linalg] Fuse producers with non-permutation indexing maps
Until now Linalg fusion only allow fusing producers whose operands
are all permutation indexing maps. It's easier to deduce the
subtensor/subview but it is an unnecessary constraint, as in tiling
we have more advanced logic to deduce the subranges even when the
operand is not of permutation indexing maps, e.g., the input operand
for convolution ops.
This patch uses the logic on tiling side to deduce subranges for
fusion. This enables fusing convolution with its consumer ops
when possible.
Along the way, we are now generating proper affine.min ops to guard
against size boundaries, if we cannot be certain they won't be
out of bounds.
Differential Revision: https://reviews.llvm.org/D99014
Commit: 23fd26608ca899f13445908e6afd61d88f6aea9c
https://github.com/llvm/llvm-project/commit/23fd26608ca899f13445908e6afd61d88f6aea9c
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/lib/Dialect/Affine/IR/AffineOps.cpp
M mlir/test/Dialect/Affine/canonicalize.mlir
Log Message:
-----------
[mlir][affine] Deduplicate affine min/max op expressions
If there are multiple identical expressions in an affine
min/max op's map, we can just keep one.
Differential Revision: https://reviews.llvm.org/D99015
Commit: f66120a3575a19d2b9b47b584698d5d950f63589
https://github.com/llvm/llvm-project/commit/f66120a3575a19d2b9b47b584698d5d950f63589
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/lib/Dialect/Affine/IR/AffineOps.cpp
M mlir/test/Dialect/Affine/canonicalize.mlir
M mlir/test/Dialect/Linalg/fusion-pattern.mlir
M mlir/test/Dialect/Linalg/fusion-sequence.mlir
M mlir/test/Dialect/Linalg/fusion-tensor-pattern.mlir
M mlir/test/Dialect/Linalg/fusion.mlir
M mlir/test/Dialect/Linalg/tile-and-fuse-tensors.mlir
Log Message:
-----------
[mlir][affine] Add canonicalization to merge affine min/max ops
This identifies a pattern where the producer affine min/max op
is bound to a dimension/symbol that is used as a standalone
expression in the consumer affine op's map. In that case the
producer affine min/max op can be merged into its consumer.
For example, a pattern like the following:
```
%0 = affine.min affine_map<()[s0] -> (s0 + 16, s0 * 8)> ()[%sym1]
%1 = affine.min affine_map<(d0)[s0] -> (s0 + 4, d0)> (%0)[%sym2]
```
Can be turned into:
```
%1 = affine.min affine_map<
()[s0, s1] -> (s0 + 4, s1 + 16, s1 * 8)> ()[%sym2, %sym1]
```
Differential Revision: https://reviews.llvm.org/D99016
Commit: 7f28d27cb614c47e6cf68f5deae729270d13cb08
https://github.com/llvm/llvm-project/commit/7f28d27cb614c47e6cf68f5deae729270d13cb08
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/include/mlir/Dialect/Linalg/Passes.h
M mlir/include/mlir/Dialect/Linalg/Passes.td
M mlir/lib/Dialect/Linalg/Transforms/FusionOnTensors.cpp
M mlir/test/Dialect/Linalg/reshape_fusion.mlir
Log Message:
-----------
[mlir][linalg] Allow controlling folding unit dim reshapes
This commit exposes an option to the pattern
FoldWithProducerReshapeOpByExpansion to allow
folding unit dim reshapes. This gives callers
more fine-grained controls.
Differential Revision: https://reviews.llvm.org/D99114
Commit: c241e1c2f55334c56b30c10d3e6a6c520c4e783f
https://github.com/llvm/llvm-project/commit/c241e1c2f55334c56b30c10d3e6a6c520c4e783f
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/lib/Dialect/Linalg/Transforms/DropUnitDims.cpp
M mlir/test/Dialect/Linalg/drop-unit-extent-dims.mlir
Log Message:
-----------
[mlir][linalg] Support dropping unit dimensions for init tensors
init tensor operands also has indexing map and generally follow
the same constraints we expect for non-init-tensor operands.
Differential Revision: https://reviews.llvm.org/D99115
Commit: 19435d3863e512c62962dd872f5cbf630eaeab73
https://github.com/llvm/llvm-project/commit/19435d3863e512c62962dd872f5cbf630eaeab73
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-03-24 (Wed, 24 Mar 2021)
Changed paths:
M mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp
M mlir/test/Dialect/Linalg/canonicalize.mlir
M mlir/test/Dialect/Linalg/drop-unit-extent-dims.mlir
Log Message:
-----------
[mlir][linalg] Fold fill -> tensor_reshape chain
For such op chains, we can create new linalg.fill ops
with the result type of the linalg.tensor_reshape op.
Differential Revision: https://reviews.llvm.org/D99116
Compare: https://github.com/llvm/llvm-project/compare/158026301b48...19435d3863e5
More information about the All-commits
mailing list