[Mlir-commits] [mlir] [mlir][python] fix `replace=True` for `register_operation` and `register_type_caster` (PR #70264)
Maksim Levental
llvmlistbot at llvm.org
Wed Oct 25 17:33:59 PDT 2023
================
@@ -668,6 +671,27 @@ def testKnownOpView():
# CHECK: OpView object
print(repr(custom))
+ # constant should map to an extension OpView class in the arithmetic dialect.
+ constant = module.body.operations[3]
+ # CHECK: <mlir.dialects.arith.ConstantOp object
+ print(repr(constant))
+ # CHECK: literal value 0
+ print("literal value", constant.literal_value)
----------------
makslevental wrote:
The extension is being registered successfully irrespective of this PR.
https://github.com/llvm/llvm-project/pull/70264
More information about the Mlir-commits
mailing list