This is an archive of the discontinued LLVM Phabricator instance.

[mlir][bufferize] Extract buffer hoisting into separate function
ClosedPublic

Authored by springerm on Mar 12 2022, 6:36 AM.

Details

Summary

This improves the modularity of the bufferization.

From now on, all ops that do not implement BufferizableOpInterface are considered hoisting barriers. Previously, all ops that do not implement the interface were not considered barriers and such ops had to be marked as barriers explicitly. This was unsafe because we could've hoisted across unknown ops where it was not safe to hoist.

As a side effect, this allows for cleaning up AffineBufferizableOpInterfaceImpl. This build unit no longer needed and can be deleted.

Depends On D121362

Diff Detail

Event Timeline

springerm created this revision.Mar 12 2022, 6:36 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 12 2022, 6:36 AM
springerm requested review of this revision.Mar 12 2022, 6:36 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 12 2022, 6:36 AM
springerm retitled this revision from [mlir][bufferize][NFC] Extract buffer hoisting into separate function to [mlir][bufferize] Extract buffer hoisting into separate function.
springerm edited the summary of this revision. (Show Details)
gysit accepted this revision.Mar 15 2022, 3:42 AM

LGTM!

This revision is now accepted and ready to land.Mar 15 2022, 3:42 AM
This revision was landed with ongoing or failed builds.Mar 15 2022, 5:31 AM
This revision was automatically updated to reflect the committed changes.
mlir/lib/Dialect/Bufferization/IR/BufferizableOpInterface.cpp