This is an archive of the discontinued LLVM Phabricator instance.

[mlir][Linalg] NFC - Reorganize options nesting.
ClosedPublic

Authored by nicolasvasilache on Oct 22 2021, 2:20 PM.

Details

Summary

This removes duplication and makes nesting more clear.
It also reduces the amount of changes necessary for exposing future options.

Diff Detail

Event Timeline

nicolasvasilache requested review of this revision.Oct 22 2021, 2:20 PM

Looks like a nice improvement!

mlir/include/mlir/Dialect/Linalg/Transforms/Transforms.h
882

What about naming this enableVectorTransferPartialRewrite(bool val = true)?
The enable verb and the default value makes it nice to read at call sites I think:

.enableVectorTransferPartialRewrite()
.enableVectorContractLowering()
.enableVectorToSCFConversion();

Also since this class is also about VectorLowering options, could these be shortened?

.enableTransferPartialRewrite()
.enableContraction()
.enableSCFConversion();

Address review.

nicolasvasilache marked an inline comment as done.Oct 23 2021, 5:25 AM
This revision was not accepted when it landed; it landed in state Needs Review.Oct 23 2021, 6:07 AM
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
nicolasvasilache reopened this revision.Oct 23 2021, 6:47 AM

Didn't mean to push yet, reopening.

Create a vectorLowering transform, applied on-demand.

springerm accepted this revision.Oct 24 2021, 11:07 PM
This revision is now accepted and ready to land.Oct 24 2021, 11:07 PM
This revision was landed with ongoing or failed builds.Oct 24 2021, 11:25 PM
This revision was automatically updated to reflect the committed changes.