This is an archive of the discontinued LLVM Phabricator instance.

[mlir] add interchange, pad and scalarize to structured transform dialect
ClosedPublic

Authored by ftynse on May 25 2022, 6:13 AM.

Details

Summary

Add ops to the structured transform extension of the transform dialect that
perform interchange, padding and scalarization on structured ops. Along with
tiling that is already defined, this provides a minimal set of transformations
necessary to build vectorizable code for a single structured op.

Define two helper traits: one that implements TransformOpInterface by applying
a function to each payload op independently and another that provides a simple
"functional-style" producer/consumer list of memory effects for the transform
ops.

Diff Detail

Event Timeline

ftynse created this revision.May 25 2022, 6:13 AM
ftynse requested review of this revision.May 25 2022, 6:13 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 25 2022, 6:13 AM
nicolasvasilache accepted this revision.May 30 2022, 1:43 AM
nicolasvasilache added inline comments.
mlir/test/Dialect/Linalg/transform-op-scalarize.mlir
7

You may want to add a comment here that the op is first tiled by 10, this creates a ? that gets turned into a loop to get to 1, as it is not immediately obvious what the test tests scalarization.

This revision is now accepted and ready to land.May 30 2022, 1:43 AM
ftynse marked an inline comment as done.May 30 2022, 2:42 AM