[Mlir-commits] [mlir] [MLIR][Transform][SMT] Introduce transform.smt.constrain_params (PR #159450)
Rolf Morel
llvmlistbot at llvm.org
Thu Sep 18 12:56:59 PDT 2025
================
@@ -0,0 +1,37 @@
+# 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
+
+from typing import Sequence
+
+from ...ir import Type, Block
+from .._transform_smt_extension_ops_gen import *
+from .._transform_smt_extension_ops_gen import _Dialect
+from ...dialects import transform
+
+try:
+ from .._ods_common import _cext as _ods_cext
+except ImportError as e:
+ raise RuntimeError("Error loading imports from extension module") from e
+
+
+ at _ods_cext.register_operation(_Dialect, replace=True)
+class ConstrainParamsOp(ConstrainParamsOp):
+ def __init__(
+ self,
+ params: Sequence[transform.AnyParamType],
+ arg_types: Sequence[Type],
+ loc=None,
+ ip=None,
+ ):
+ assert len(params) == len(arg_types)
----------------
rolfmorel wrote:
Good call. Done.
https://github.com/llvm/llvm-project/pull/159450
More information about the Mlir-commits
mailing list