Skip to content

[Rust] Add ThreadData and group query foundations - #12091

Draft
tpn wants to merge 6 commits into
NVIDIA:mainfrom
tpn:codex/cuda-coop-rust-r02
Draft

tpn wants to merge 6 commits into
NVIDIA:mainfrom
tpn:codex/cuda-coop-rust-r02

Conversation

@tpn

@tpn tpn commented Oct 20, 2026

Copy link
Copy Markdown
Contributor

Adds initialized-slot-aware ThreadData and hierarchy/group queries for Rust cuda.coop. Payload types are inferred from writes, the main item count remains a const generic, and checked reads expose only initialized slots. Hierarchy queries preserve the common block-major ordering and mapped-group membership rules.

This builds on #12088; the focused delta covers the payload and query foundation. Collective operations, synchronization, and scratch storage remain subsequent foundation work.

For coordinated draft validation, the library and native fixture pin cuda-device to tpn/cuda-rust@8c4a42e9c95b2a6bdc14a7531904d8469f0e7ca6 from cuda-rust #1563 and use nightly-2026-10-11. This does not claim support with upstream-main Oxide.

Validation: 11 host tests and 18 doctests; strict clippy, warning-free rustdoc and Rust guide build, and repository pre-commit checks. The CUDA 13.3/sm120 fixture passes 308,480 query/payload value checks, five expected trap cases, and memcheck. Existing C++ thread/warp rank tests independently confirm ordering. Native validation uses the coordinated O03 compiler; current-head CI is tracked separately.

tpn added 6 commits October 19, 2026 21:39
Create a host-only Cargo workspace that specializes selected CUB forms
through NVRTC and reports exact scratch layouts with their LTO output.
Bind specialization identities to source, headers and toolkit bytes.
Include a runnable provider example, Rust guide and CPU checks.

Signed-off-by: Trent Nelson <trent@trent.me>
Install the pinned toolchain without updating rustup itself.

Signed-off-by: Trent Nelson <trent@trent.me>
Signed-off-by: Trent Nelson <trent@trent.me>
Select fixture output locations from raw CUDA coordinates and exercise
payload initialization, access and copying at both item counts. Annotate
compile-fail examples and clarify hierarchy ordering in the guide.

Signed-off-by: Trent Nelson <trent@trent.me>
Signed-off-by: Trent Nelson <trent@trent.me>
@copy-pr-bot

copy-pr-bot Bot commented Oct 20, 2026

Copy link
Copy Markdown
Contributor

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.

@github-project-automation github-project-automation Bot moved this to Todo in CCCL Oct 20, 2026
@cccl-authenticator-app cccl-authenticator-app Bot moved this from Todo to In Progress in CCCL Oct 20, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

1 participant