20 #define DEBUG_TYPE "dlti-transforms"
26 void transform::QueryOp::getEffects(
38 if (
auto strKey = dyn_cast<StringAttr>(key))
39 keys.push_back(strKey);
40 else if (
auto typeKey = dyn_cast<TypeAttr>(key))
41 keys.push_back(typeKey.getValue());
44 "only StringAttr and TypeAttr are allowed");
47 FailureOr<Attribute> result =
dlti::query(target, keys,
true);
51 "'transform.dlti.query' op failed to apply");
62 class DLTITransformDialectExtension
64 DLTITransformDialectExtension> {
73 #include "mlir/Dialect/DLTI/TransformOps/DLTITransformOps.cpp.inc"
79 #define GET_OP_CLASSES
80 #include "mlir/Dialect/DLTI/TransformOps/DLTITransformOps.cpp.inc"
#define MLIR_DEFINE_EXPLICIT_INTERNAL_INLINE_TYPE_ID(CLASS_NAME)
Attributes are known-constant values of operations.
The result of a transform IR operation application.
static DiagnosedSilenceableFailure success()
Constructs a DiagnosedSilenceableFailure in the success state.
The DialectRegistry maps a dialect namespace to a constructor for the matching dialect.
void addExtensions()
Add the given extensions to the registry.
Operation is the basic unit of execution within MLIR.
Base class for extensions of the Transform dialect that supports injecting operations into the Transf...
FailureOr< Attribute > query(Operation *op, ArrayRef< DataLayoutEntryKey > keys, bool emitError=false)
Perform a DLTI-query at op, recursively querying each key of keys on query interface-implementing att...
void registerTransformDialectExtension(DialectRegistry ®istry)
Include the generated interface declarations.
DiagnosedSilenceableFailure emitSilenceableFailure(Location loc, const Twine &message={})
Emits a silenceable failure with the given message.
DiagnosedDefiniteFailure emitDefiniteFailure(Location loc, const Twine &message={})
Emits a definite failure with the given message.