NVIDIA / NVIDIA/cccl

Validate current device and CUB stream matches

Open
#7,782 0 comments 2 reactions 0 assignees View on GitHub
good first issue help wanted
Dominant language
C++
Stars
2.5k
Forks
486
Avg merge
2d 6h
Merged PRs (30d)
295

Description

All CUB algorithms accept a user provided stream argument. We assume in many places that the current CUDA device matches to where the stream is going. For example, when we ask for the PTX architecture or the available SMEM on the current device. If the current device is not the one where kernels will be launched via the user-provided stream, errors may happen, like launching a kernel with more dynamic SMEM than is available on the device to where the stream goes to.

We should add a check, at least an assertion, to all CUB dispatching codes that the stream launches kernels to the same device as the current CUDA device.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.