This is an automated email from the ASF dual-hosted git repository.

tqchen pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tvm.git


The following commit(s) were added to refs/heads/main by this push:
     new b67650f102 [FFI] fix two seemingly migration issue (#18258)
b67650f102 is described below

commit b67650f1020e9e4bd3d69052867611c08f951470
Author: wrongtest <[email protected]>
AuthorDate: Sun Aug 31 21:58:26 2025 +0800

    [FFI] fix two seemingly migration issue (#18258)
---
 ffi/python/tvm_ffi/cython/function.pxi | 1 +
 include/tvm/ir/expr.h                  | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/ffi/python/tvm_ffi/cython/function.pxi 
b/ffi/python/tvm_ffi/cython/function.pxi
index 00a0bb3515..a223da90cb 100644
--- a/ffi/python/tvm_ffi/cython/function.pxi
+++ b/ffi/python/tvm_ffi/cython/function.pxi
@@ -186,6 +186,7 @@ cdef inline int make_args(tuple py_args, TVMFFIAny* out, 
list temp_args,
             temp_args.append(tstr)
         elif arg is None:
             out[i].type_index = kTVMFFINone
+            out[i].v_int64 = 0
         elif isinstance(arg, Real):
             out[i].type_index = kTVMFFIFloat
             out[i].v_float64 = arg
diff --git a/include/tvm/ir/expr.h b/include/tvm/ir/expr.h
index 9b7645b56a..f0350af565 100644
--- a/include/tvm/ir/expr.h
+++ b/include/tvm/ir/expr.h
@@ -742,7 +742,9 @@ inline constexpr bool use_default_type_traits_v<Integer> = 
false;
 
 template <>
 struct TypeTraits<Integer> : public ObjectRefWithFallbackTraitsBase<Integer, 
int64_t> {
-  TVM_FFI_INLINE static Integer ConvertFallbackValue(int64_t value) { return 
Integer(value); }
+  TVM_FFI_INLINE static Integer ConvertFallbackValue(int64_t value) {
+    return Integer(TypeTraits<IntImm>::ConvertFallbackValue(value));
+  }
 };
 
 template <>

Reply via email to