Skip to content

Document CUB temp storage alignment#9302

Open
jrhemstad wants to merge 1 commit into
NVIDIA:mainfrom
jrhemstad:codex/document-cub-temp-storage-alignment
Open

Document CUB temp storage alignment#9302
jrhemstad wants to merge 1 commit into
NVIDIA:mainfrom
jrhemstad:codex/document-cub-temp-storage-alignment

Conversation

@jrhemstad

Copy link
Copy Markdown
Collaborator

Updates the tempstorage alias to clarify that no special alignment is required.

Updates all documentation to use the Doxygen alias.

@jrhemstad jrhemstad requested review from a team as code owners June 8, 2026 23:10
@jrhemstad jrhemstad requested a review from gonidelis June 8, 2026 23:10
@jrhemstad jrhemstad requested a review from NaderAlAwar June 8, 2026 23:10
@copy-pr-bot

copy-pr-bot Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

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.

@github-project-automation github-project-automation Bot moved this to Todo in CCCL Jun 8, 2026
@cccl-authenticator-app cccl-authenticator-app Bot moved this from Todo to In Review in CCCL Jun 8, 2026
@jrhemstad

Copy link
Copy Markdown
Collaborator Author

/ok to test fb52488

@jrhemstad jrhemstad force-pushed the codex/document-cub-temp-storage-alignment branch from fb52488 to 7b84060 Compare June 8, 2026 23:13
@jrhemstad

Copy link
Copy Markdown
Collaborator Author

/ok to test 7b84060

@coderabbitai

coderabbitai Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: a42cd15f-8263-434d-b172-26728da41e1e

📥 Commits

Reviewing files that changed from the base of the PR and between fb52488 and 93cb78c.

📒 Files selected for processing (21)
  • cub/cub/device/device_adjacent_difference.cuh
  • cub/cub/device/device_copy.cuh
  • cub/cub/device/device_find.cuh
  • cub/cub/device/device_for.cuh
  • cub/cub/device/device_histogram.cuh
  • cub/cub/device/device_memcpy.cuh
  • cub/cub/device/device_merge.cuh
  • cub/cub/device/device_merge_sort.cuh
  • cub/cub/device/device_partition.cuh
  • cub/cub/device/device_radix_sort.cuh
  • cub/cub/device/device_reduce.cuh
  • cub/cub/device/device_run_length_encode.cuh
  • cub/cub/device/device_scan.cuh
  • cub/cub/device/device_segmented_radix_sort.cuh
  • cub/cub/device/device_segmented_reduce.cuh
  • cub/cub/device/device_segmented_scan.cuh
  • cub/cub/device/device_segmented_sort.cuh
  • cub/cub/device/device_select.cuh
  • cub/cub/device/device_topk.cuh
  • docs/cub/Doxyfile
  • docs/cub/api_docs/device_wide.rst
✅ Files skipped from review due to trivial changes (19)
  • docs/cub/api_docs/device_wide.rst
  • cub/cub/device/device_memcpy.cuh
  • docs/cub/Doxyfile
  • cub/cub/device/device_find.cuh
  • cub/cub/device/device_adjacent_difference.cuh
  • cub/cub/device/device_topk.cuh
  • cub/cub/device/device_segmented_radix_sort.cuh
  • cub/cub/device/device_reduce.cuh
  • cub/cub/device/device_segmented_reduce.cuh
  • cub/cub/device/device_merge_sort.cuh
  • cub/cub/device/device_copy.cuh
  • cub/cub/device/device_for.cuh
  • cub/cub/device/device_select.cuh
  • cub/cub/device/device_segmented_scan.cuh
  • cub/cub/device/device_radix_sort.cuh
  • cub/cub/device/device_merge.cuh
  • cub/cub/device/device_segmented_sort.cuh
  • cub/cub/device/device_scan.cuh
  • cub/cub/device/device_histogram.cuh
🚧 Files skipped from review as they are similar to previous changes (1)
  • cub/cub/device/device_partition.cuh

Note: CodeRabbit is enabled on this repository as a convenience for maintainers
and contributors. Use your best judgment when considering its review comments and
suggestions — a suggested change may be inadequate, unnecessary, or safe to ignore.
Contributors are not expected to address every comment. Human reviews are what
ultimately matter for merging.

Overview

This PR updates CUB's documentation to standardize how temporary storage parameters are documented and clarifies that no special alignment is required. The changes are documentation-only and do not modify any functional code or API signatures.

Changes

Doxygen Alias Update (docs/cub/Doxyfile)

  • Refined the devicestorage alias to clarify that no special alignment is required for d_temp_storage and to document the requirement for a pointer-sized allocation during execution

API Documentation Updates (cub/cub/device/*.cuh)
Updated Doxygen documentation across 22 device headers to replace verbose descriptive text about temporary storage allocation with a standardized @devicestorage Doxygen tag. This change was applied to:

  • DeviceAdjacentDifference, DeviceCopy, DeviceFind, DeviceFor
  • DeviceHistogram, DeviceMemcpy, DeviceMerge, DeviceMergeSort
  • DevicePartition, DeviceRadixSort, DeviceReduce, DeviceRunLengthEncode
  • DeviceScan, DeviceSegmentedRadixSort, DeviceSegmentedReduce, DeviceSegmentedScan
  • DeviceSegmentedSort, DeviceSelect, DeviceTopK

API Documentation Update (docs/cub/api_docs/device_wide.rst)

  • Clarified the temporary storage allocation step by rewording to explicitly state that allocating device-accessible memory is required and that no special alignment is required

Impact

  • Lines changed: ~124 insertions, ~283 deletions across all files
  • Scope: Documentation only; no functional code changes
  • Review effort: Low

Walkthrough

This PR standardizes Doxygen documentation for temporary storage parameters across 16 CUB device algorithm headers. Verbose multi-line descriptions of d_temp_storage allocation behavior are replaced with a centralized @devicestorage tag, defined in the Doxyfile and clarified in user-facing API docs.

Changes

Doxygen Temporary Storage Documentation Standardization

Layer / File(s) Summary
Define @devicestorage tag and user guidance
docs/cub/Doxyfile, docs/cub/api_docs/device_wide.rst
The @devicestorage Doxygen alias is updated to document device-accessible memory requirements, execution-time pointer validity, and clarify that no special alignment is needed. User-facing API documentation is updated to specify device-accessible memory allocation and note the lack of alignment requirements.
Apply @devicestorage tag across device APIs
cub/cub/device/device_adjacent_difference.cuh, device_copy.cuh, device_find.cuh, device_for.cuh, device_histogram.cuh, device_memcpy.cuh, device_merge.cuh, device_merge_sort.cuh, device_partition.cuh, device_radix_sort.cuh, device_reduce.cuh, device_run_length_encode.cuh, device_scan.cuh, device_segmented_radix_sort.cuh, device_segmented_reduce.cuh, device_segmented_scan.cuh, device_segmented_sort.cuh, device_select.cuh, device_topk.cuh
Replace verbose d_temp_storage parameter documentation (describing allocation behavior and nullptr handling) with the standardized @devicestorage tag across 156 individual overloads and variants.

Comment @coderabbitai help to get the list of available commands and usage tips.

@jrhemstad jrhemstad force-pushed the codex/document-cub-temp-storage-alignment branch from 7b84060 to 93cb78c Compare June 8, 2026 23:23
@jrhemstad

Copy link
Copy Markdown
Collaborator Author

/ok to test 93cb78c

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

Labels

None yet

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

3 participants