This is an archive of the discontinued LLVM Phabricator instance.

[mlir][sparse] fix SSA chain issue in dense2sparse conversion.
ClosedPublic

Authored by Peiming on Nov 8 2022, 5:42 PM.

Diff Detail

Event Timeline

Peiming created this revision.Nov 8 2022, 5:42 PM
Herald added a project: Restricted Project. · View Herald Transcript
Peiming requested review of this revision.Nov 8 2022, 5:42 PM
aartbik added inline comments.Nov 8 2022, 5:45 PM
mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorRewriting.cpp
539–544

remove?

548

this too?

wrengr added inline comments.Nov 8 2022, 5:51 PM
mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorRewriting.cpp
539–544

Any reason why this commented code is kept here? It doesn't seem relevant to the ForeachOp...

544–545

Personally I'd rather inline the definition of t into its use-site, rather than introducing a variable for it. (Though git-clang-format might do something awful with reformatting the code.) But it's your call

548–553

ditto

Peiming updated this revision to Diff 474131.Nov 8 2022, 5:51 PM

rebase+code clean up.

Peiming marked 4 inline comments as done.Nov 8 2022, 5:59 PM
aartbik accepted this revision.Nov 8 2022, 6:00 PM
This revision is now accepted and ready to land.Nov 8 2022, 6:00 PM
Peiming updated this revision to Diff 474133.Nov 8 2022, 6:01 PM

address comment from Wren.

Peiming marked an inline comment as done.Nov 8 2022, 6:02 PM
Peiming added inline comments.
mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorRewriting.cpp
544–545

Inlined, seems nicer.

Peiming marked an inline comment as done.Nov 8 2022, 6:02 PM
This revision was landed with ongoing or failed builds.Nov 8 2022, 6:03 PM
This revision was automatically updated to reflect the committed changes.