[Mlir-commits] [mlir] [mlir] Accept OpaqueAttr as a valid memory space if the context allows unregistered dialects (PR #187682)
Adam Paszke
llvmlistbot at llvm.org
Thu Mar 26 03:44:27 PDT 2026
================
@@ -616,6 +616,12 @@ bool mlir::detail::isSupportedMemorySpace(Attribute memorySpace) {
if (llvm::isa<IntegerAttr, StringAttr, DictionaryAttr>(memorySpace))
return true;
+ // Allow opaque attributes if unregistered dialects are allowed.
+ // They hold unregistered custom dialect attributes.
+ if (memorySpace.getContext()->allowsUnregisteredDialects() &&
+ isa<OpaqueAttr>(memorySpace))
+ return true;
+
// Allow custom dialect attributes.
if (!isa<BuiltinDialect>(memorySpace.getDialect()))
----------------
apaszke wrote:
So... should I do it? WDYT?
https://github.com/llvm/llvm-project/pull/187682
More information about the Mlir-commits
mailing list