[mlir][bazel] Move InliningUtils into a separate target. #85411
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Various (in-tree as well as downstream) targets currently depend on
InliningUtils.h
to avoid circular dependencies. E.g.TransformUtils
depends onArithDialect
, soArithDialect
can't depend onTransformUtils
exportingInliningUtils.h
. This change exposes that header and it's implementation as a separate target. Having targets that implement all the declared functions is the preferred approach for bazel build graphs.See also PR #84878, which moves the interface definitions to a separate file in the
Interfaces
directory. This turned out to be controversial and putting it in a different directory didn't seem to have any support either. Instead, this PR only changes the bazel build without moving any C++ code.