MLIR  20.0.0git
RegisterEverything.cpp
Go to the documentation of this file.
1 //===- RegisterEverything.cpp - API to register all dialects/passes -------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
11 
12 PYBIND11_MODULE(_mlirRegisterEverything, m) {
13  m.doc() = "MLIR All Upstream Dialects, Translations and Passes Registration";
14 
15  m.def("register_dialects", [](MlirDialectRegistry registry) {
16  mlirRegisterAllDialects(registry);
17  });
18  m.def("register_llvm_translations",
19  [](MlirContext context) { mlirRegisterAllLLVMTranslations(context); });
20 
21  // Register all passes on load.
23 }
PYBIND11_MODULE(_mlirRegisterEverything, m)
void mlirRegisterAllPasses()
Register all compiler passes of MLIR.
void mlirRegisterAllDialects(MlirDialectRegistry registry)
Appends all upstream dialects and extensions to the dialect registry.
void mlirRegisterAllLLVMTranslations(MlirContext context)
Register all translations to LLVM IR for dialects that can support it.