This is an archive of the discontinued LLVM Phabricator instance.

Fix canonicalizer to copy the entire GreedyRewriteConfig instead of selected fields
ClosedPublic

Authored by mehdi_amini on Aug 8 2023, 7:03 PM.

Details

Summary

It is surprising for the user that only some fields were honored.

Also make the FrozenRewritePatternSet a shared_ptr<const T>.

Fixes #64543

Diff Detail

Event Timeline

mehdi_amini created this revision.Aug 8 2023, 7:03 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 8 2023, 7:03 PM
mehdi_amini requested review of this revision.Aug 8 2023, 7:03 PM
zero9178 added inline comments.Aug 9 2023, 12:24 PM
mlir/lib/Transforms/Canonicalizer.cpp
30

Isn't this equal to the deault generated copy constructor and can therefore be omitted entirely? This violates the rule of 5 otherwise (although unlikely to matter in our case).

Mogball accepted this revision.Aug 9 2023, 1:29 PM
This revision is now accepted and ready to land.Aug 9 2023, 1:29 PM
jpienaar accepted this revision.Aug 9 2023, 1:47 PM
This revision was landed with ongoing or failed builds.Aug 9 2023, 7:59 PM
This revision was automatically updated to reflect the committed changes.