This is an archive of the discontinued LLVM Phabricator instance.

[linalg] When removing noop linalg.generics, check that inserting a cast is valid
ClosedPublic

Authored by bkramer on Mar 28 2022, 5:15 AM.

Details

Summary

linalg.generic can also take scalars instead of tensors, which
tensor.cast doesn't support. We don't have an easy way to cast between
scalars and tensors so just keep the linalg.generic in those cases.

Diff Detail

Event Timeline

bkramer created this revision.Mar 28 2022, 5:15 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 28 2022, 5:15 AM
bkramer requested review of this revision.Mar 28 2022, 5:15 AM
mravishankar accepted this revision.Mar 29 2022, 12:38 PM
This revision is now accepted and ready to land.Mar 29 2022, 12:38 PM