This is an archive of the discontinued LLVM Phabricator instance.

[MLIR] Update linalg.conv lowering to use affine load in the absence of padding
ClosedPublic

Authored by bondhugula on Jun 4 2020, 12:47 PM.

Details

Summary

Update linalg to affine lowering for convop to use affine load for input
whenever there is no padding. It had always been using std.loads because
max in index functions (needed for non-zero padding if not materializing
zeros) couldn't be represented by affine loads in the non-zero padding cases.

In the future, the non-zero padding case could also be made to use
affine - either by materializing or using affine.execute_region. The
latter approach will not impact scf/std output obtained after lowering
out affine.

Diff Detail

Event Timeline

bondhugula created this revision.Jun 4 2020, 12:47 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 4 2020, 12:47 PM
bondhugula edited the summary of this revision. (Show Details)Jun 4 2020, 12:55 PM
nicolasvasilache accepted this revision.Jun 4 2020, 1:20 PM

Thanks Uday!

This revision is now accepted and ready to land.Jun 4 2020, 1:20 PM
bondhugula updated this revision to Diff 268654.Jun 4 2020, 8:51 PM

Minor update comment.

This revision was automatically updated to reflect the committed changes.