This is an archive of the discontinued LLVM Phabricator instance.

[mlir][AffineToStandard] Make LowerAffine pass Op-agnostic.
ClosedPublic

Authored by mravishankar on Jul 25 2020, 2:18 PM.

Details

Summary

The LowerAffine psas was a FunctionPass only for legacy
reasons. Making this Op-agnostic allows it to be used from command
line when affine expressions are within operations other than
std.func.

Diff Detail

Event Timeline

mravishankar created this revision.Jul 25 2020, 2:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 25 2020, 2:18 PM
bondhugula requested changes to this revision.Jul 26 2020, 12:40 AM

Thanks @mravishankar - could you please add a test case (a trivial one should suffice)?

This revision now requires changes to proceed.Jul 26 2020, 12:40 AM

Adding test case

Added a test case.

bondhugula accepted this revision.Jul 26 2020, 8:32 PM
bondhugula added inline comments.
mlir/include/mlir/Conversion/Passes.td
23

This comment is outdated. loop -> SCF.

mlir/test/Conversion/AffineToStandard/lower-affine-gpu.mlir
15

Nit: indent load please.

This revision is now accepted and ready to land.Jul 26 2020, 8:32 PM

Addressing comments and rebase

mravishankar marked 2 inline comments as done.Jul 26 2020, 11:28 PM
ftynse accepted this revision.Jul 27 2020, 3:49 AM
bondhugula accepted this revision.Jul 27 2020, 7:18 AM
This revision was automatically updated to reflect the committed changes.