This is an archive of the discontinued LLVM Phabricator instance.

[mlir][vector] Fold cancelling vector.shape_cast(vector.broadcast)
ClosedPublic

Authored by antiagainst on Apr 20 2022, 8:40 AM.

Details

Summary

vector.broadcast can inject all size one dimensions. If it's
followed by a vector.shape_cast to the original type, we can
cancel the op pair, like cancelling consecutive shape_cast ops.

Diff Detail

Event Timeline

antiagainst created this revision.Apr 20 2022, 8:40 AM
Herald added a project: Restricted Project. · View Herald Transcript
antiagainst requested review of this revision.Apr 20 2022, 8:40 AM
mravishankar accepted this revision.Apr 21 2022, 12:47 PM
This revision is now accepted and ready to land.Apr 21 2022, 12:47 PM