Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions dace/codegen/compiled_sdfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -556,10 +556,14 @@ def _construct_args(self, kwargs) -> Tuple[Tuple[Any], Tuple[Any]]:
callparams = tuple((carg, aname) for arg, carg, aname in zip(arglist, cargs, argnames)
if not (symbolic.issymbolic(arg) and (hasattr(arg, 'name') and arg.name in constants)))

newargs = tuple(carg for carg, aname in callparams)
# NOTE: While it makes sense to modify `self._lastargs[0]` it does not make sense to
# modify `self._lastargs[1]`, i.e. `initargs`, because it is only used the first time.
# The reason why modification of `self._lastargs[0]` is useful that it allows fast
# dispatch from Python, for example in GT4Py.next.
newargs = [carg for carg, aname in callparams]
initargs = tuple(carg for carg, aname in callparams if aname in symbols)

self._lastargs = newargs, initargs
self._lastargs = (newargs, initargs)
return self._lastargs

def clear_return_values(self):
Expand Down
Loading