This is an archive of the discontinued LLVM Phabricator instance.

[mlir][sparse] proper in-place SDDMM with spy function
ClosedPublic

Authored by aartbik on Jun 14 2023, 3:20 PM.

Details

Summary

This specific operation matches the cuSPARSE SDDMM semantics exactly.

Diff Detail

Event Timeline

aartbik created this revision.Jun 14 2023, 3:20 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 14 2023, 3:20 PM
aartbik requested review of this revision.Jun 14 2023, 3:20 PM
Peiming added inline comments.Jun 14 2023, 3:24 PM
mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
1158

You can have a InsertionGuard here so that you do not need to restore the insertion point outside the function

aartbik updated this revision to Diff 531558.Jun 14 2023, 3:41 PM

used guard instead of save/restore

aartbik marked an inline comment as done.Jun 14 2023, 3:44 PM
aartbik added inline comments.
mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
1158

Used the guard. Note that I still use it outside, so we only save/restore it once. If you prefer I can move it here, but it feels that we will do it too often then

Peiming accepted this revision.Jun 14 2023, 5:01 PM
This revision is now accepted and ready to land.Jun 14 2023, 5:01 PM
aartbik updated this revision to Diff 531880.Jun 15 2023, 12:45 PM
aartbik marked an inline comment as done.

rebased with main

This revision was landed with ongoing or failed builds.Jun 15 2023, 1:59 PM
This revision was automatically updated to reflect the committed changes.