[all-commits] [llvm/llvm-project] b6d1a3: [mlir][sparse] refine heuristic for iteration grap...

Aart Bik via All-commits all-commits at lists.llvm.org
Fri Sep 3 08:37:31 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b6d1a31c1b88227b38b3dad7b4430fa42516e82c
      https://github.com/llvm/llvm-project/commit/b6d1a31c1b88227b38b3dad7b4430fa42516e82c
  Author: Aart Bik <ajcbik at google.com>
  Date:   2021-09-03 (Fri, 03 Sep 2021)

  Changed paths:
    M mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
    M mlir/test/Dialect/SparseTensor/sparse_2d.mlir

  Log Message:
  -----------
  [mlir][sparse] refine heuristic for iteration graph topsort

The sparse index order must always be satisfied, but this
may give a choice in topsorts for several cases. We broke
ties in favor of any dense index order, since this gives
good locality. However, breaking ties in favor of pushing
unrelated indices into sparse iteration spaces gives better
asymptotic complexity. This revision improves the heuristic.

Note that in the long run, we are really interested in using
ML for ML to find the best loop ordering as a replacement for
such heuristics.

Reviewed By: bixia

Differential Revision: https://reviews.llvm.org/D109100




More information about the All-commits mailing list