[Mlir-commits] [mlir] [mlir][c] Enable creating and setting greedy rewrite confing. (PR #162429)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Thu Jan 1 21:54:40 PST 2026
================
@@ -319,7 +339,83 @@ MLIR_CAPI_EXPORTED MlirLogicalResult mlirApplyPatternsAndFoldGreedilyWithOp(
MLIR_CAPI_EXPORTED MlirLogicalResult mlirApplyPatternsAndFoldGreedily(
MlirModule op, MlirFrozenRewritePatternSet patterns,
- MlirGreedyRewriteDriverConfig);
+ MlirGreedyRewriteDriverConfig config);
+
+//===----------------------------------------------------------------------===//
+/// GreedyRewriteDriverConfig API
+//===----------------------------------------------------------------------===//
+
+/// Creates a greedy rewrite driver configuration with default settings.
+MLIR_CAPI_EXPORTED MlirGreedyRewriteDriverConfig
+mlirGreedyRewriteDriverConfigCreate();
----------------
PragmaTwice wrote:
```suggestion
MLIR_CAPI_EXPORTED MlirGreedyRewriteDriverConfig
mlirGreedyRewriteDriverConfigCreate(void);
```
it seems in C we need to add a `void` to the parameter list for no-parameter functions.
https://github.com/llvm/llvm-project/pull/162429
More information about the Mlir-commits
mailing list