[all-commits] [llvm/llvm-project] 7b615a: [mlir][linalg] Rewrite `linalg.conv_2d_nhwc_hwcf` ...
Lei Zhang via All-commits
all-commits at lists.llvm.org
Tue Nov 2 07:01:02 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 7b615a87dc559e24ef377313e00fe339b96c893e
https://github.com/llvm/llvm-project/commit/7b615a87dc559e24ef377313e00fe339b96c893e
Author: Lei Zhang <antiagainst at google.com>
Date: 2021-11-02 (Tue, 02 Nov 2021)
Changed paths:
M mlir/include/mlir/Dialect/Linalg/Transforms/Transforms.h
M mlir/lib/Dialect/Linalg/Transforms/Transforms.cpp
A mlir/test/Dialect/Linalg/decompose-convolution.mlir
M mlir/test/lib/Dialect/Linalg/TestLinalgTransforms.cpp
Log Message:
-----------
[mlir][linalg] Rewrite `linalg.conv_2d_nhwc_hwcf` into 1-D
We'd like to take a progressive approach towards Fconvolution op
CodeGen, by 1) tiling it to fit compute hierarchy first, and then
2) tiling along window dimensions with size 1 to reduce the problem
to be matmul-like. After that, we can 3) downscale high-D convolution
ops to low-D by removing the size-1 window dimensions. The final
step would be 4) vectorizing the low-D convolution op directly.
We have patterns for 1), 2), and 4). This commit adds a pattern for
3) for `linalg.conv_2d_nhwc_hwcf` ops as a starter. Supporting other
high-D convolution ops should be similar and mechanical.
Reviewed By: nicolasvasilache
Differential Revision: https://reviews.llvm.org/D112928
More information about the All-commits
mailing list