diff --git a/mlir/lib/Bindings/Python/CMakeLists.txt b/mlir/lib/Bindings/Python/CMakeLists.txt --- a/mlir/lib/Bindings/Python/CMakeLists.txt +++ b/mlir/lib/Bindings/Python/CMakeLists.txt @@ -35,11 +35,26 @@ # Generate dialect-specific bindings. ################################################################################ +add_mlir_dialect_python_bindings(MLIRBindingsPythonLinalgOps + LinalgOps.td + linalg) +add_dependencies(MLIRBindingsPythonSources MLIRBindingsPythonLinalgOps) + +add_mlir_dialect_python_bindings(MLIRBindingsPythonShapeOps + ShapeOps.td + shape) +add_dependencies(MLIRBindingsPythonSources MLIRBindingsPythonShapeOps) + add_mlir_dialect_python_bindings(MLIRBindingsPythonStandardOps StandardOps.td std) add_dependencies(MLIRBindingsPythonSources MLIRBindingsPythonStandardOps) +add_mlir_dialect_python_bindings(MLIRBindingsPythonTensorOps + TensorOps.td + tensor) +add_dependencies(MLIRBindingsPythonSources MLIRBindingsPythonTensorOps) + ################################################################################ # Build core python extension ################################################################################ diff --git a/mlir/lib/Bindings/Python/LinalgOps.td b/mlir/lib/Bindings/Python/LinalgOps.td new file mode 100644 --- /dev/null +++ b/mlir/lib/Bindings/Python/LinalgOps.td @@ -0,0 +1,16 @@ +//===-- LinalgOps.td - Entry point for linalg bind ---------*- tablegen -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +#ifndef PYTHON_BINDINGS_LINALG_OPS +#define PYTHON_BINDINGS_LINALG_OPS + +include "mlir/Bindings/Python/Attributes.td" +include "mlir/Dialect/Linalg/IR/LinalgOps.td" +include "mlir/Dialect/Linalg/IR/LinalgStructuredOps.td" + +#endif diff --git a/mlir/lib/Bindings/Python/ShapeOps.td b/mlir/lib/Bindings/Python/ShapeOps.td new file mode 100644 --- /dev/null +++ b/mlir/lib/Bindings/Python/ShapeOps.td @@ -0,0 +1,15 @@ +//===-- ShapeOps.td - Entry point for TensorOps bind -------*- tablegen -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +#ifndef PYTHON_BINDINGS_SHAPE_OPS +#define PYTHON_BINDINGS_SHAPE_OPS + +include "mlir/Bindings/Python/Attributes.td" +include "mlir/Dialect/Shape/IR/ShapeOps.td" + +#endif diff --git a/mlir/lib/Bindings/Python/TensorOps.td b/mlir/lib/Bindings/Python/TensorOps.td new file mode 100644 --- /dev/null +++ b/mlir/lib/Bindings/Python/TensorOps.td @@ -0,0 +1,15 @@ +//===-- TensorOps.td - Entry point for TensorOps bind ------*- tablegen -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +#ifndef PYTHON_BINDINGS_TENSOR_OPS +#define PYTHON_BINDINGS_TENSOR_OPS + +include "mlir/Bindings/Python/Attributes.td" +include "mlir/Dialect/Tensor/IR/TensorOps.td" + +#endif