Add a pattern to do ad hoc lowering of vector.reduction to a sequence of warp shuffles. This allow distributing reduction on a warp for GPU targets.
Also add an execution test for warp reduction.
co-authored with @springerm
Paths
| Differential D127176
[mlir][vector] Add pattern to distribute vector reduction to GPU shuffles ClosedPublic Authored by ThomasRaoux on Jun 6 2022, 7:40 PM.
Details Summary Add a pattern to do ad hoc lowering of vector.reduction to a sequence of warp shuffles. This allow distributing reduction on a warp for GPU targets. co-authored with @springerm
Diff Detail Event TimelineThomasRaoux added a parent revision: D127167: [mlir][vector] Add patterns to propagate vector distribution.Jun 6 2022, 7:40 PM
ThomasRaoux added inline comments.
This revision is now accepted and ready to land.Jun 9 2022, 2:55 AM Closed by commit rG087aba4f0f96: [mlir][vector] Add pattern to distribute vector reduction to GPU shuffles (authored by ThomasRaoux). · Explain WhyJun 13 2022, 10:54 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 434819 mlir/include/mlir/Dialect/Vector/Transforms/VectorDistribution.h
mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt
mlir/lib/Dialect/Vector/Transforms/VectorDistribute.cpp
mlir/test/Dialect/Vector/vector-warp-distribute.mlir
mlir/test/Integration/Dialect/Vector/GPU/CUDA/test-reduction-distribute.mlir
mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
|
Seems like a layering violation?