This is an archive of the discontinued LLVM Phabricator instance.

[mlir] Finish removing Identifier from the C++ API
ClosedPublic

Authored by rriddle on Jan 4 2022, 2:16 PM.

Details

Summary

There have been a few API pieces remaining to allow for a smooth transition for
downstream users, but these have been up for a few months now. After this only
the C API will have reference to "Identifier", but those will be reworked in a followup.

The main updates are:

  • Identifier -> StringAttr
  • StringAttr::get requires the context as the first parameter
    • i.e. Identifier::get("...", ctx) -> StringAttr::get(ctx, "...")

Diff Detail

Event Timeline

rriddle created this revision.Jan 4 2022, 2:16 PM
Herald added a project: Restricted Project. · View Herald Transcript
rriddle requested review of this revision.Jan 4 2022, 2:16 PM
rriddle retitled this revision from [mlir] Finish removing Identifier from the C++ API r=mehdi_amini to [mlir] Finish removing Identifier from the C++ API.Jan 4 2022, 2:16 PM

Is the changes needed downstream effectively Identifier::get -> StringAttr::get with args switched? (and header removed)

Is the changes needed downstream effectively Identifier::get -> StringAttr::get with args switched? (and header removed)

Essentially yeah, given that Identifier is already removed. This is just removing the placeholder APIs(names) that were used for staging.

mehdi_amini accepted this revision.Jan 4 2022, 9:20 PM

LGTM, please include in the description of the commit that the fix is to reverse the argument order.

This revision is now accepted and ready to land.Jan 4 2022, 9:20 PM
rriddle edited the summary of this revision. (Show Details)Jan 5 2022, 10:33 AM
This revision was automatically updated to reflect the committed changes.
mlir/include/mlir/IR/BuiltinAttributes.td