Skip to content

Change deprecated calls of stream_ref.wait() to stream_ref.sync() - #23653

Merged
rapids-bot[bot] merged 1 commit into
NVIDIA:mainfrom
davidwendt:stream-wait-deprecated
Aug 13, 2026
Merged

Change deprecated calls of stream_ref.wait() to stream_ref.sync()#23653
rapids-bot[bot] merged 1 commit into
NVIDIA:mainfrom
davidwendt:stream-wait-deprecated

Conversation

@davidwendt

@davidwendt davidwendt commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Description

Fixes deprecation warnings for calls to cuda::stream_ref::wait() by changing them to the recommended cuda::stream_ref::sync() instead.

Example deprecation warning:

/cudf/cpp/src/partitioning/partitioning.cu:745:12: warning: 'void cuda::__4::stream_ref::wait() const' is deprecated: Use sync() instead. [-Wdeprecated-declarations]
  745 |     stream.wait();  // Async D2H copy must finish before returning host vec
      |     ~~~~~~~^~
/cudf/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include/cuda/__stream/stream_ref.h:179:95: note: declared here
  179 |   CCCL_DEPRECATED_BECAUSE("Use sync() instead.") _CCCL_HOST_API void wait() const

Introduced by #23645

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@davidwendt davidwendt self-assigned this Aug 13, 2026
@davidwendt
davidwendt requested a review from a team as a code owner August 13, 2026 19:51
@davidwendt davidwendt added the 3 - Ready for Review Ready for review by team label Aug 13, 2026
@davidwendt davidwendt added libcudf Affects libcudf (C++/CUDA) code. improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Aug 13, 2026
@coderabbitai

coderabbitai Bot commented Aug 13, 2026

Copy link
Copy Markdown

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: 1507cb2b-60e2-4304-8775-26309f56798b

📥 Commits

Reviewing files that changed from the base of the PR and between 0b57a3b and 0e64479.

📒 Files selected for processing (3)
  • cpp/src/copying/contiguous_split.cu
  • cpp/src/partitioning/partitioning.cu
  • cpp/tests/copying/concatenate_tests.cpp

📝 Walkthrough

Summary by CodeRabbit

  • Bug Fixes
    • Improved synchronization during data copying and hash partitioning operations.
    • Ensured host-side partition metadata is fully available before results are returned.
    • Improved reliability of asynchronous column data and mask transfers.
  • Tests
    • Updated copy-related validation to reflect the improved synchronization behavior.

Walkthrough

Changes

CUDA stream synchronization

Layer / File(s) Summary
Replace stream wait calls with sync calls
cpp/src/copying/contiguous_split.cu, cpp/src/partitioning/partitioning.cu, cpp/tests/copying/concatenate_tests.cpp
Production paths and the test fixture now call stream.sync() instead of stream.wait() before accessing copied metadata, partition offsets, or initialized device data.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Mergeability Score: ⚪ Minimal · up to 0e644

This is a localized deprecated API replacement with no actionable merge-blocking risk remaining after normal checks and review.

Suggested reviewers: pmattione-nvidia, qbacpey, vyasr

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely describes replacing deprecated stream_ref.wait() calls with stream_ref.sync().
Description check ✅ Passed The description explains the deprecation warning, the replacement, and the affected API calls.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@davidwendt davidwendt changed the title Change deprecated calls of stream.wait() to stream.sync() Change deprecated calls of stream_ref.wait() to stream_ref.sync() Aug 13, 2026

@bdice bdice left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry. I did think about this deprecation when I reviewed #23645, but I forgot which method was deprecated. cc: @vyasr

@vyasr vyasr left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to audit our CI. I did think about this but I thought I got all the cases, and I trusted CI passing as sufficient because we build with warnings as errors. I don't yet understand how my PR could have passed CI in the current state unless CCCL has an extra knob for its own deprecation warnings somehow.

@davidwendt

Copy link
Copy Markdown
Contributor Author

/merge

@rapids-bot
rapids-bot Bot merged commit 2b457c1 into NVIDIA:main Aug 13, 2026
152 checks passed
@davidwendt
davidwendt deleted the stream-wait-deprecated branch August 14, 2026 00:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3 - Ready for Review Ready for review by team improvement Improvement / enhancement to an existing function libcudf Affects libcudf (C++/CUDA) code. non-breaking Non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants