Migrate stream APIs from rmm::cuda_stream_view to cuda::stream_ref - #1181
Migrate stream APIs from rmm::cuda_stream_view to cuda::stream_ref#1181bdice wants to merge 3 commits into
Conversation
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
9f09f62 to
33c9d4e
Compare
pentschev
left a comment
There was a problem hiding this comment.
Could we update the declaration void wait() declaration to void sync() as part of the migration? I don't think it's currently used anywhere and probably exposed only for completeness, regardless, I think it makes sense to update it (or remove it completely) rather than having a stale one declaration.
Signed-off-by: Bradley Dice <bdice@bradleydice.com>
6db731c to
11a1656
Compare
|
Rebased onto preparation PR #1199 and validated against the rebased RMM stack. Local |
|
CI follow-up: all four devcontainer failures use the pre-migration RMM Cython declaration where |
Summary
Track the coordinated migration of stream APIs and call sites from
rmm::cuda_stream_viewto CCCL'scuda::stream_ref. This propagatescuda::stream_refthrough RMM containers and memory resources, RAFT resource and handle APIs, downstream C++ interfaces, Python/Cython bindings, benchmarks, tests, and documentation.This updates RapidsMPF C++ and Python/Cython stream handling to preserve references returned by RMM stream pools and extract raw handles only where required.
Depends on rapidsai/rmm#2372.
Tracked in rapidsai/build-planning#318.
Migrations
cuda::stream_refthrough stream pools, resource accessors, conditionals, and downstream APIs without converting tormm::cuda_stream_viewcuda::stream_refconstructions for default/legacy/per-thread streamsrmm::cuda_stream_default➡️cuda::stream_ref{cudaStream_t{cudaStreamDefault}}rmm::cuda_stream_legacy➡️cuda::stream_ref{cudaStreamLegacy}rmm::cuda_stream_per_thread➡️cuda::stream_ref{cudaStreamPerThread}.get()when calling an API that requires a rawcudaStream_t, including CUDA runtime, library, CUB, and legacy API boundaries (previouslyrmm::cuda_stream_viewusedvalue()).sync()when synchronizing acuda::stream_ref(previouslyrmm::cuda_stream_viewusedsynchronize())