From a6769c46ee1c80e01d10556f0ef19aa27ca9d258 Mon Sep 17 00:00:00 2001 From: Vyas Ramasubramani Date: Mon, 17 Aug 2026 16:05:39 -0700 Subject: [PATCH 1/2] Use cuda::stream_ref in Python stream shims --- python/cudf/udf_cpp/strings/src/strings/udf/udf_apis.cu | 8 ++++---- .../pylibcudf/libcudf/detail/utilities/stream_pool.pxd | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/python/cudf/udf_cpp/strings/src/strings/udf/udf_apis.cu b/python/cudf/udf_cpp/strings/src/strings/udf/udf_apis.cu index f0ce1f836cef..87c88f97885c 100644 --- a/python/cudf/udf_cpp/strings/src/strings/udf/udf_apis.cu +++ b/python/cudf/udf_cpp/strings/src/strings/udf/udf_apis.cu @@ -1,5 +1,5 @@ /* - * SPDX-FileCopyrightText: Copyright (c) 2022-2026, NVIDIA CORPORATION. + * SPDX-FileCopyrightText: Copyright (c) 2022-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. * SPDX-License-Identifier: Apache-2.0 */ @@ -48,7 +48,7 @@ struct managed_udf_string_to_string_view_transform_fn { * @param stream CUDA stream used for allocating/copying device memory and launching kernels */ std::unique_ptr to_string_view_array(cudf::column_view const input, - rmm::cuda_stream_view stream) + cuda::stream_ref stream) { return std::make_unique( std::move(cudf::strings::create_string_vector_from_column( @@ -62,7 +62,7 @@ std::unique_ptr to_string_view_array(cudf::column_view const * @param stream CUDA stream used for allocating/copying device memory and launching kernels */ std::unique_ptr column_from_managed_udf_string_array( - managed_udf_string* managed_strings, cudf::size_type size, rmm::cuda_stream_view stream) + managed_udf_string* managed_strings, cudf::size_type size, cuda::stream_ref stream) { // create string_views of the udf_strings auto indices = rmm::device_uvector(size, stream); @@ -73,7 +73,7 @@ std::unique_ptr column_from_managed_udf_string_array( managed_udf_string_to_string_view_transform_fn{}); auto result = cudf::make_strings_column(indices, cudf::string_view(nullptr, 0), stream); - stream.synchronize(); + stream.sync(); return result; } diff --git a/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd b/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd index 399a868db717..b0b76b22caec 100644 --- a/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd +++ b/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd @@ -1,4 +1,4 @@ -# SPDX-FileCopyrightText: Copyright (c) 2025-2026, NVIDIA CORPORATION. +# SPDX-FileCopyrightText: Copyright (c) 2025-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: Apache-2.0 from cuda.bindings.cyruntime cimport cudaStream_t @@ -12,7 +12,7 @@ cdef extern from * nogil: """ #include #include - #include + #include #include namespace { @@ -20,7 +20,7 @@ cdef extern from * nogil: cudf::host_span streams, cudaStream_t stream ) { - std::vector stream_views(streams.begin(), streams.end()); + std::vector stream_views(streams.begin(), streams.end()); cudf::detail::join_streams(stream_views, stream); } } From 1b03abe65a26d4acdb6a2fb3c270d2b08ab04894 Mon Sep 17 00:00:00 2001 From: Vyas Ramasubramani Date: Mon, 17 Aug 2026 17:00:32 -0700 Subject: [PATCH 2/2] Use cuda stream header in Python shims --- .../pylibcudf/libcudf/detail/utilities/stream_pool.pxd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd b/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd index b0b76b22caec..32794c022237 100644 --- a/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd +++ b/python/pylibcudf/pylibcudf/libcudf/detail/utilities/stream_pool.pxd @@ -12,7 +12,7 @@ cdef extern from * nogil: """ #include #include - #include + #include #include namespace {