1 //===-- mlir-c/Dialect/PDL.h - C API for PDL Dialect --------------*- C -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM
5 // See https://llvm.org/LICENSE.txt for license information.
6 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
8 //===----------------------------------------------------------------------===//
10 #ifndef MLIR_C_DIALECT_PDL_H
11 #define MLIR_C_DIALECT_PDL_H
13 #include "mlir-c/IR.h"
19 MLIR_DECLARE_CAPI_DIALECT_REGISTRATION(PDL
, pdl
);
21 //===---------------------------------------------------------------------===//
23 //===---------------------------------------------------------------------===//
25 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLType(MlirType type
);
27 //===---------------------------------------------------------------------===//
29 //===---------------------------------------------------------------------===//
31 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLAttributeType(MlirType type
);
33 MLIR_CAPI_EXPORTED MlirType
mlirPDLAttributeTypeGet(MlirContext ctx
);
35 //===---------------------------------------------------------------------===//
37 //===---------------------------------------------------------------------===//
39 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLOperationType(MlirType type
);
41 MLIR_CAPI_EXPORTED MlirType
mlirPDLOperationTypeGet(MlirContext ctx
);
43 //===---------------------------------------------------------------------===//
45 //===---------------------------------------------------------------------===//
47 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLRangeType(MlirType type
);
49 MLIR_CAPI_EXPORTED MlirType
mlirPDLRangeTypeGet(MlirType elementType
);
51 MLIR_CAPI_EXPORTED MlirType
mlirPDLRangeTypeGetElementType(MlirType type
);
53 //===---------------------------------------------------------------------===//
55 //===---------------------------------------------------------------------===//
57 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLTypeType(MlirType type
);
59 MLIR_CAPI_EXPORTED MlirType
mlirPDLTypeTypeGet(MlirContext ctx
);
61 //===---------------------------------------------------------------------===//
63 //===---------------------------------------------------------------------===//
65 MLIR_CAPI_EXPORTED
bool mlirTypeIsAPDLValueType(MlirType type
);
67 MLIR_CAPI_EXPORTED MlirType
mlirPDLValueTypeGet(MlirContext ctx
);
73 #endif // MLIR_C_DIALECT_PDL_H