This is an archive of the discontinued LLVM Phabricator instance.

[mlir][bufferization][transform][python] Add enums to bindings & mixins.
ClosedPublic

Authored by ingomueller-net on Jul 31 2023, 3:30 AM.

Details

Summary

This patch uses the new enum binding generation to add the enums of the
dialect to the Python bindings and uses them in the mix-in class where
it was still missing (namely, the LayoutMapOption for the
function_boundary_type_conversion of the OneShotBufferizeOp.

The patch also piggy-backs a few smaller clean-ups:

  • Order the keyword-only arguments alphabetically.
  • Add the keyword-only arguments to an overload where they were left out by accident.
  • Change some of the attribute values used in the tests to non-default values such that they show up in the output IR and check for that output.

Diff Detail

Event Timeline

Herald added a project: Restricted Project. · View Herald TranscriptJul 31 2023, 3:30 AM
ingomueller-net requested review of this revision.Jul 31 2023, 3:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 31 2023, 3:30 AM
ftynse accepted this revision.Jul 31 2023, 9:04 AM
ftynse added inline comments.
utils/bazel/llvm-project-overlay/mlir/python/BUILD.bazel
782

I don't think this line is necessary here.

This revision is now accepted and ready to land.Jul 31 2023, 9:04 AM
  • Rebase to main. This should fix the build failure since the dependent patch has now landed.
  • Remove unnecessary line from BUILD file.