[all-commits] [llvm/llvm-project] e057f2: [mlir][sparse] auto-insertion of conversion to res...
Aart Bik via All-commits
all-commits at lists.llvm.org
Wed Jun 29 18:28:35 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: e057f25dee59e61b870595156656f90d015b859f
https://github.com/llvm/llvm-project/commit/e057f25dee59e61b870595156656f90d015b859f
Author: Aart Bik <ajcbik at google.com>
Date: 2022-06-29 (Wed, 29 Jun 2022)
Changed paths:
M mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
A mlir/test/Dialect/SparseTensor/sparse_transpose.mlir
M mlir/test/Integration/Dialect/SparseTensor/CPU/sparse_transpose.mlir
Log Message:
-----------
[mlir][sparse] auto-insertion of conversion to resolve cycles
When the iteration graph is cyclic (even after several attempts using less and less constraints), the current sparse compiler bails out, and no rewriting hapens. However, this revision adds some new logic where the sparse compiler tries to find a single input sparse tensor that breaks the cycle, and then adds a proper sparse conversion operation. This way, more incoming kernels can be handled!
Note, the resulting code is not optimal (although it keeps more or less proper "sparse" complexity), and more improvements should be added (especially when the kernel directly yields without computation, such as the transpose example). However, handling is better than not handling ;-)
Reviewed By: bixia
Differential Revision: https://reviews.llvm.org/D128847
More information about the All-commits
mailing list