Skip to content

Commit

Permalink
Fix qualifier
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhardmgruber committed Jan 10, 2025
1 parent 3afef56 commit eac776c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
5 changes: 4 additions & 1 deletion cub/cub/agent/agent_spmv_orig.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@
#include <cub/thread/thread_search.cuh>
#include <cub/util_type.cuh>

#include <thrust/detail/config/namespace.h>
#include <thrust/iterator/counting_iterator.h>

#include <cuda/std/type_traits>

#include <iterator>
Expand Down Expand Up @@ -374,7 +377,7 @@ struct AgentSpmv
CTA_SYNC();

// Search for the thread's starting coordinate within the merge tile
CountingInputIterator<OffsetT> tile_nonzero_indices(tile_start_coord.y);
THRUST_NS_QUALIFIER::counting_iterator<OffsetT> tile_nonzero_indices(tile_start_coord.y);
CoordinateT thread_start_coord;

MergePathSearch(
Expand Down
10 changes: 4 additions & 6 deletions cub/test/catch2_test_device_reduce.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -203,12 +203,11 @@ inline __half* unwrap_it(half_t* it)
}

template <class OffsetT>
inline THRUST_NS_QUALIFIER::constant_iterator<__half, OffsetT>
unwrap_it(THRUST_NS_QUALIFIER::constant_iterator<half_t, OffsetT> it)
inline thrust::constant_iterator<__half, OffsetT> unwrap_it(thrust::constant_iterator<half_t, OffsetT> it)
{
half_t wrapped_val = *it;
__half val = wrapped_val.operator __half();
return THRUST_NS_QUALIFIER::constant_iterator<__half, OffsetT>(val);
return thrust::constant_iterator<__half, OffsetT>(val);
}
#endif

Expand All @@ -219,12 +218,11 @@ inline __nv_bfloat16* unwrap_it(bfloat16_t* it)
}

template <class OffsetT>
THRUST_NS_QUALIFIER::constant_iterator<__nv_bfloat16, OffsetT> inline unwrap_it(
THRUST_NS_QUALIFIER::constant_iterator<bfloat16_t, OffsetT> it)
thrust::constant_iterator<__nv_bfloat16, OffsetT> inline unwrap_it(thrust::constant_iterator<bfloat16_t, OffsetT> it)
{
bfloat16_t wrapped_val = *it;
__nv_bfloat16 val = wrapped_val.operator __nv_bfloat16();
return THRUST_NS_QUALIFIER::constant_iterator<__nv_bfloat16, OffsetT>(val);
return thrust::constant_iterator<__nv_bfloat16, OffsetT>(val);
}
#endif

Expand Down

0 comments on commit eac776c

Please sign in to comment.