Page MenuHomePhabricator

[mlir][tosa] Add tosa.concat to subtensor inserts lowering
ClosedPublic

Authored by rsuderman on Mar 17 2021, 1:43 PM.

Details

Summary

Includes lowering for tosa.concat with indice computation with subtensor insert
operations. Includes tests along two different indices.

Diff Detail

Event Timeline

rsuderman created this revision.Mar 17 2021, 1:43 PM
rsuderman requested review of this revision.Mar 17 2021, 1:43 PM
antiagainst accepted this revision.Mar 18 2021, 2:52 PM
antiagainst added inline comments.
mlir/lib/Conversion/TosaToLinalg/TosaToLinalg.cpp
667

Can use getType() (instead of getResult().getType()) directly to get the result type.

670

expected static ranked tensor type ...

681

We typically do sizes.reserve(rank) first before pushing its values in one by one.

This revision is now accepted and ready to land.Mar 18 2021, 2:52 PM
rsuderman updated this revision to Diff 331708.Mar 18 2021, 3:41 PM

antiagainst@ comments

rsuderman updated this revision to Diff 331709.Mar 18 2021, 3:42 PM
rsuderman marked 2 inline comments as done.

Typo

rsuderman marked an inline comment as done.Mar 18 2021, 3:43 PM
rsuderman added inline comments.
mlir/lib/Conversion/TosaToLinalg/TosaToLinalg.cpp
670

In this case we need static shape (not just static rank). And static shape implies static rank by default.

rsuderman updated this revision to Diff 331715.Mar 18 2021, 3:58 PM

Synced to head, included fixes for missing dialect.

This revision was landed with ongoing or failed builds.Mar 18 2021, 4:00 PM
This revision was automatically updated to reflect the committed changes.