Skip to content

Commit

Permalink
Get rid of custom cuda_stream_ref (#526)
Browse files Browse the repository at this point in the history
This PR fixes merge conflicts between #517 and #525.
  • Loading branch information
PointKernel authored Jul 3, 2024
1 parent dff0112 commit 2ad911f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions include/cuco/detail/open_addressing/open_addressing_impl.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -415,15 +415,15 @@ class open_addressing_impl {
FoundIt found_begin,
InsertedIt inserted_begin,
Ref container_ref,
cuda_stream_ref stream) noexcept
cuda::stream_ref stream) noexcept
{
auto const num_keys = cuco::detail::distance(first, last);
if (num_keys == 0) { return; }

auto const grid_size = cuco::detail::grid_size(num_keys, cg_size);

detail::insert_and_find<cg_size, cuco::detail::default_block_size()>
<<<grid_size, cuco::detail::default_block_size(), 0, stream>>>(
<<<grid_size, cuco::detail::default_block_size(), 0, stream.get()>>>(
first, num_keys, found_begin, inserted_begin, container_ref);
}

Expand Down
6 changes: 3 additions & 3 deletions include/cuco/detail/static_set/static_set.inl
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,10 @@ void static_set<Key, Extent, Scope, KeyEqual, ProbingScheme, Allocator, Storage>
InputIt last,
FoundIt found_begin,
InsertedIt inserted_begin,
cuda_stream_ref stream)
cuda::stream_ref stream)
{
insert_and_find_async(first, last, found_begin, inserted_begin, stream);
stream.synchronize();
stream.wait();
}

template <class Key,
Expand All @@ -206,7 +206,7 @@ void static_set<Key, Extent, Scope, KeyEqual, ProbingScheme, Allocator, Storage>
InputIt last,
FoundIt found_begin,
InsertedIt inserted_begin,
cuda_stream_ref stream) noexcept
cuda::stream_ref stream) noexcept
{
impl_->insert_and_find_async(
first, last, found_begin, inserted_begin, ref(op::insert_and_find), stream);
Expand Down
4 changes: 2 additions & 2 deletions include/cuco/static_set.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ class static_set {
InputIt last,
FoundIt found_begin,
InsertedIt inserted_begin,
cuda_stream_ref stream = {}) noexcept;
cuda::stream_ref stream = {}) noexcept;

/**
* @brief Inserts all elements in the range `[first, last)`.
Expand Down Expand Up @@ -393,7 +393,7 @@ class static_set {
InputIt last,
FoundIt found_begin,
InsertedIt inserted_begin,
cuda_stream_ref stream = {});
cuda::stream_ref stream = {});

/**
* @brief Erases keys in the range `[first, last)`.
Expand Down

0 comments on commit 2ad911f

Please sign in to comment.