Skip to content

Commit 03c0df1

Browse files
PointKernelbdice
andauthored
Update include/cuco/detail/storage/counter_storage.cuh
Co-authored-by: Bradley Dice <[email protected]>
1 parent 2323643 commit 03c0df1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

include/cuco/detail/storage/counter_storage.cuh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,11 @@ class counter_storage : public storage_base<cuco::extent<SizeType, 1>> {
9696
CUCO_CUDA_TRY(cudaMallocHost(&h_count, sizeof(size_type)));
9797
CUCO_CUDA_TRY(cudaMemcpyAsync(
9898
h_count, this->data(), sizeof(size_type), cudaMemcpyDeviceToHost, stream.get()));
99+
#if CCCL_MAJOR_VERSION > 3 || (CCCL_MAJOR_VERSION == 3 && CCCL_MINOR_VERSION >= 1)
99100
stream.sync();
101+
#else // ^^^ CCCL >= 3.1 ^^^ / vvv CCCL < 3.1 vvv
102+
stream.wait();
103+
#endif // CCCL < 3.1
100104
size_type result = *h_count;
101105
CUCO_CUDA_TRY(cudaFreeHost(h_count));
102106
return result;

0 commit comments

Comments
 (0)