Changes to the DpctlSyclQueue and USMNdArray types. #1064
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Storing the Python dpctl.SyclQueue inside any instance of the DpctlSyclQueue type was causing segfaults due to the Python object getting garbage collected prematurely.
The changes in the PR update the DpctlSyclQueue type to only store the filter string associated with the dpctl.SyclQueue and not the actual Python object. In addition, the USMNdArray type now stores an instance of a DpctlSyclQueue in its queue parameter instead of a Python dpctl.SyclQueue object.
Due to these changes, all places where the Python dpctl.SyclQueue was getting extracted and used from a UsmNdArray instance or DpctlSyclQueue instance have been updated.
All test cases were also updated.