rmm
rmm copied to clipboard
Adding support for cupy.cuda.stream.ExternalStream
Description
Cupy offers the cupy.cuda.stream.ExternalStream for utilizing external CUDA streams. Moreover, cupy.cuda.get_current_stream() will return an instance of cupy.cuda.stream.ExternalStream instead of cupy.cuda.stream.Stream, particularly when the current cuPy stream has been changed.
Therefore, we must verify both types of instances to avoid errors.
See details in the https://docs.cupy.dev/en/stable/user_guide/interoperability.html#cuda-stream-pointers
Checklist
- [x] I am familiar with the Contributing Guidelines.
- [ ] New or existing tests cover these changes.
- [x] The documentation is up to date with these changes.
This pull request requires additional validation before any workflows can run on NVIDIA's runners.
Pull request vetters can view their responsibilities here.
Contributors can view more details about this message here.
/ok to test
Hi @harrism @miscco @jrhemstad,
Would you kindly inform me if there are any additional steps required for this fix to be accepted?
Thank you so much, Lilo
/ok to test
/ok to test
/ok to test
Can we add a test for this change?
Can we add a test for this change?
Agree, that's a good suggestion. However looking, we don't appear to have any tests of this Stream Cython class.
/ok to test
BTW, I did not mean to negate @bdice's request for tests. Just to say that we don't have existing tests to base this off of. @bdice do you want to block merging until a test is added?
No need to block on tests if existing functionality is untested, but this is a gap that might be worth addressing in the future.
/ok to test
/merge
Thanks @lilohuang!