Skip to content

[mlir][Transforms] Dialect conversion: Make materializations optional #104668

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions mlir/include/mlir/Transforms/DialectConversion.h
Original file line number Diff line number Diff line change
Expand Up @@ -1124,6 +1124,17 @@ struct ConversionConfig {
// already been modified) and iterators into past IR state cannot be
// represented at the moment.
RewriterBase::Listener *listener = nullptr;

/// If set to "true", the dialect conversion attempts to build source/target/
/// argument materializations through the type converter API in lieu of
/// builtin.unrealized_conversion_cast ops. The conversion process fails if
/// at least one materialization could not be built.
///
/// If set to "false", the dialect conversion does not does not build any
/// custom materializations and instead inserts
/// builtin.unrealized_conversion_cast ops to ensure that the resulting IR
/// is valid.
bool buildMaterializations = true;
};

//===----------------------------------------------------------------------===//
Expand Down
Loading
Loading