[all-commits] [llvm/llvm-project] 9b2a1b: [mlir] separable registration of attribute and typ...
ftynse via All-commits
all-commits at lists.llvm.org
Tue Jun 15 06:20:50 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9b2a1bcf6fbe79cfa3725cfd654f45cce0375d3b
https://github.com/llvm/llvm-project/commit/9b2a1bcf6fbe79cfa3725cfd654f45cce0375d3b
Author: Alex Zinenko <zinenko at google.com>
Date: 2021-06-15 (Tue, 15 Jun 2021)
Changed paths:
M mlir/docs/Interfaces.md
M mlir/include/mlir/IR/AttributeSupport.h
M mlir/include/mlir/IR/Attributes.h
M mlir/include/mlir/IR/StorageUniquerSupport.h
M mlir/include/mlir/IR/TypeSupport.h
M mlir/include/mlir/IR/Types.h
M mlir/include/mlir/Support/InterfaceSupport.h
M mlir/lib/IR/MLIRContext.cpp
M mlir/test/lib/Dialect/Test/CMakeLists.txt
M mlir/test/lib/Dialect/Test/TestAttributes.cpp
M mlir/test/lib/Dialect/Test/TestAttributes.h
M mlir/test/lib/Dialect/Test/TestInterfaces.td
M mlir/tools/mlir-tblgen/OpInterfacesGen.cpp
M mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp
M mlir/unittests/IR/CMakeLists.txt
A mlir/unittests/IR/InterfaceAttachmentTest.cpp
Log Message:
-----------
[mlir] separable registration of attribute and type interfaces
It may be desirable to provide an interface implementation for an attribute or
a type without modifying the definition of said attribute or type. Notably,
this allows to implement interfaces for attributes and types outside of the
dialect that defines them and, in particular, provide interfaces for built-in
types. Provide the mechanism to do so.
Currently, separable registration requires the attribute or type to have been
registered with the context, i.e. for the dialect containing the attribute or
type to be loaded. This can be relaxed in the future using a mechanism similar
to delayed dialect interface registration.
See https://llvm.discourse.group/t/rfc-separable-attribute-type-interfaces/3637
Depends On D104233
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D104234
More information about the All-commits
mailing list