llvm/mlir/lib/ExecutionEngine
Alex Zinenko 2996a8d675 [mlir] avoid exposing mutable DialectRegistry from MLIRContext
MLIRContext allows its users to access directly to the DialectRegistry it
contains. While sometimes useful for registering additional dialects on an
already existing context, this breaks the encapsulation by essentially giving
raw accesses to a part of the context's internal state. Remove this mutable
access and instead provide a method to append a given DialectRegistry to the
one already contained in the context. Also provide a shortcut mechanism to
construct a context from an already existing registry, which seems to be a
common use case in the wild. Keep read-only access to the registry contained in
the context in case it needs to be copied or used for constructing another
context.

With this change, DialectRegistry is no longer concerned with loading the
dialects and deciding whether to invoke delayed interface registration. Loading
is concentrated in the MLIRContext, and the functionality of the registry
better reflects its name.

Depends On D96137

Reviewed By: mehdi_amini

Differential Revision: https://reviews.llvm.org/D96331
2021-02-10 12:07:34 +01:00
..
AsyncRuntime.cpp Fix MLIR Async Runtime DLL on Windows 2021-02-03 12:23:41 +00:00
CMakeLists.txt [mlir] Remove mlir_c_runner_utils_static. 2021-01-29 15:04:48 +01:00
CRunnerUtils.cpp [mlir] Fix integration tests 2021-01-28 16:54:50 +00:00
ExecutionEngine.cpp Rework ExecutionEngine::invoke() to make it more friendly to use from C++ 2021-02-06 01:32:50 +00:00
JitRunner.cpp [mlir] avoid exposing mutable DialectRegistry from MLIRContext 2021-02-10 12:07:34 +01:00
OptUtils.cpp Revert "Revert "[mlir] Convert from Async dialect to LLVM coroutines"" 2020-10-22 15:23:11 -04:00
RunnerUtils.cpp Revert "[mlir] add support for verification in integration tests" 2021-02-09 19:16:02 +01:00
SparseUtils.cpp [mlir][sparse] add asserts on reading in tensor data 2021-01-20 14:30:13 -08:00