Introduce pass to convert parallel affine.for op into 1-D affine.parallel op. Run using --affine-parallelize. Removes test-detect-parallel: pass for checking parallel affine.for ops.
Signed-off-by: Yash Jain <yash.jain@polymagelabs.com>
Paths
| Differential D83193
[MLIR] Parallelize affine.for op to 1-D affine.parallel op ClosedPublic Authored by yash on Jul 6 2020, 1:33 AM.
Details Summary Introduce pass to convert parallel affine.for op into 1-D affine.parallel op. Run using --affine-parallelize. Removes test-detect-parallel: pass for checking parallel affine.for ops. Signed-off-by: Yash Jain <yash.jain@polymagelabs.com>
Diff Detail
Event TimelineComment Actions This was reverted earlier due to a build failure. https://reviews.llvm.org/rGfbc06b228012 bondhugula added inline comments.
This revision now requires changes to proceed.Jul 9 2020, 8:14 AM Comment Actions The build failure says your patch couldn't be applied. Please rebase on current tip and update. This revision is now accepted and ready to land.Jul 11 2020, 9:02 AM Closed by commit rG102828249c8e: [MLIR] Parallelize affine.for op to 1-D affine.parallel op (authored by yash, committed by bondhugula). · Explain WhyJul 11 2020, 9:06 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 275600 mlir/include/mlir/Dialect/Affine/Passes.h
mlir/include/mlir/Dialect/Affine/Passes.td
mlir/include/mlir/Dialect/Affine/Utils.h
mlir/lib/Dialect/Affine/Transforms/AffineParallelize.cpp
mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt
mlir/lib/Dialect/Affine/Utils/Utils.cpp
mlir/test/Dialect/Affine/parallelism-detection.mlir
mlir/test/Dialect/Affine/parallelize.mlir
mlir/test/lib/Dialect/Affine/CMakeLists.txt
mlir/test/lib/Dialect/Affine/TestParallelismDetection.cpp
mlir/tools/mlir-opt/mlir-opt.cpp
|
You can't have the declaration in Utils.h (part of AffineUtils) and have the definition in AffineParallelize.cpp (part of AffineTransforms). Those who need it and depend on AffineUtils are going to get a link error. If you expose it from Utils.h, the definition has to move to Affine/Utils.cpp.