You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Tuple literals passed to generic functions fail during module hashing #2167
Passing a tuple literal directly to a generic @wp.func fails while hashing the kernel module. Assigning the same tuple to a local variable before the call works.
RuntimeError: Failed to determine type code for argument 'values' of function product:
Unrecognized type '(<class 'int'>, <class 'int'>)'
The traceback goes through Adjoint.get_references(), iter_call_callable_arg_targets(), Function.get_overload(), and get_type_code(). The literal's inferred argument type is a raw tuple of types, which the signature encoder does not recognize.
The equivalent kernel body succeeds:
values= (2, 3)
out[0] =product(values)
Generic calls should accept either spelling consistently, including during dependency discovery and module hashing.
Related: #2099, #2100, #2101, #2166. The reproducer uses flat integer tuples, indexed access, and disables backward generation, so it does not depend on nested tuples, argument unpacking, or autodiff. This also affects the natural grouped-input spelling proposed for #1813.
System Information
Warp 1.20.0.dev0, main commit 0c1ed78f7.
Python 3.12.3, Linux x86_64, CPU device.
Reproduced before applying tuple fixes; failure occurs before native kernel execution.
Activity