-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix[next]: Fix usage of DaCe fast-call to SDFG (#1656)
This PR addresses some flaky test failures observed in GT4Py CI. The root cause was that the dace backend did not check the connectivity arrays, which are passed as keyword-arguments to the SDFG. It did only check the positional arguments. The connectivity arrays do not have to be allocated on the device memory: for gpu execution, the backend ensures that the connectivity arrays are copied to device memory just before passing them to the SDFG call. Previous implementation worked sometimes, when by chance cupy was reusing the same array on gpu memory, hence the flaky behavior of the tests. New test is added for the connectivity case. The previous test case is cleaned up and improved, by invalidating all scalar positional arguments at each SDFG call: this allows to test that they are overridden before fast_call. Additionally, this PR reduces the overhead of regular SDFG call: previous implementation was copying all the connectivity arrays to gpu memory, with this PR we only allocate cupy arrays for the connectivities used in the SDFG.
- Loading branch information
Showing
4 changed files
with
185 additions
and
133 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.