This is an archive of the discontinued LLVM Phabricator instance.

[mlir][linalg] add conv_2d_nhwc_fhwc named op
ClosedPublic

Authored by christopherbate on Jun 3 2022, 12:48 PM.

Details

Summary

This operation should be supported as a named op because
when the operands are viewed as having canonical layouts
with decreasing strides, then the "reduction" dimensions
of the filter (h, w, and c) are contiguous relative to each
output channel. When lowered to a matrix multiplication,
this layout is the simplest to deal with, and thus future
transforms/vectorizations of conv2d may find using this
named op convenient.

Diff Detail

Event Timeline

christopherbate requested review of this revision.Jun 3 2022, 12:48 PM

Added tests for unknown and static shape cases.

This revision is now accepted and ready to land.Jun 6 2022, 10:02 AM
This revision was automatically updated to reflect the committed changes.