[Mlir-commits] [mlir] [MLIR][Python] Support Python-defined rewrite patterns (PR #162699)
Maksim Levental
llvmlistbot at llvm.org
Thu Oct 9 22:21:11 PDT 2025
================
@@ -324,6 +329,54 @@ MLIR_CAPI_EXPORTED MlirLogicalResult mlirApplyPatternsAndFoldGreedily(
MLIR_CAPI_EXPORTED MlirRewriterBase
mlirPatternRewriterAsBase(MlirPatternRewriter rewriter);
+//===----------------------------------------------------------------------===//
+/// RewritePattern API
+//===----------------------------------------------------------------------===//
+
+/// PatternBenefit represents the benefit of a pattern match.
+typedef unsigned short MlirPatternBenefit;
----------------
makslevental wrote:
just curious: why a typedef for this?
https://github.com/llvm/llvm-project/pull/162699
More information about the Mlir-commits
mailing list