This is an archive of the discontinued LLVM Phabricator instance.

[mlir][NFC] Expose the `CFGToSCFInterface` for the `ControlFlowToSCF` pass
ClosedPublic

Authored by zero9178 on Aug 15 2023, 5:35 AM.

Details

Summary

This is useful for any downstream users who may just want to use slightly different ops than the pass or need to take into account other ops in the input while still dealing with ControlFlow ops for the most part.
This also helps writing test implementations for transformCFGToSCF.

Since the implementation is now public, comments noting the post conditions of the methods have been added to ensure downstream users can stay compatible with the existing implementation.

Diff Detail

Event Timeline

zero9178 created this revision.Aug 15 2023, 5:35 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 15 2023, 5:35 AM
zero9178 requested review of this revision.Aug 15 2023, 5:35 AM
definelicht accepted this revision.Aug 15 2023, 5:42 AM

LGTM with grammar fixes 🤠

mlir/include/mlir/Conversion/ControlFlowToSCF/ControlFlowToSCF.h
27–29
34
40–42
53
This revision is now accepted and ready to land.Aug 15 2023, 5:42 AM
This revision was automatically updated to reflect the committed changes.
zero9178 marked 4 inline comments as done.