30 #ifndef HIPCUB_CUB_DEVICE_DEVICE_MERGE_SORT_HPP_
31 #define HIPCUB_CUB_DEVICE_DEVICE_MERGE_SORT_HPP_
33 #include "../../../config.hpp"
35 #include <cub/device/device_merge_sort.cuh>
37 BEGIN_HIPCUB_NAMESPACE
41 template<
typename KeyIteratorT,
typename ValueIteratorT,
typename OffsetT,
typename CompareOpT>
42 HIPCUB_RUNTIME_FUNCTION
static hipError_t SortPairs(
void * d_temp_storage,
43 std::size_t & temp_storage_bytes,
45 ValueIteratorT d_items,
47 CompareOpT compare_op,
48 hipStream_t stream = 0,
49 bool debug_synchronous =
false)
51 return hipCUDAErrorTohipError(::cub::DeviceMergeSort::SortPairs(d_temp_storage,
61 template<
typename KeyInputIteratorT,
62 typename ValueInputIteratorT,
63 typename KeyIteratorT,
64 typename ValueIteratorT,
67 HIPCUB_RUNTIME_FUNCTION
static hipError_t SortPairsCopy(
void * d_temp_storage,
68 std::size_t & temp_storage_bytes,
69 KeyInputIteratorT d_input_keys,
70 ValueInputIteratorT d_input_items,
71 KeyIteratorT d_output_keys,
72 ValueIteratorT d_output_items,
74 CompareOpT compare_op,
75 hipStream_t stream = 0,
76 bool debug_synchronous =
false)
78 return hipCUDAErrorTohipError(::cub::DeviceMergeSort::SortPairsCopy(d_temp_storage,
90 template<
typename KeyIteratorT,
typename OffsetT,
typename CompareOpT>
91 HIPCUB_RUNTIME_FUNCTION
static hipError_t SortKeys(
void * d_temp_storage,
92 std::size_t & temp_storage_bytes,
95 CompareOpT compare_op,
96 hipStream_t stream = 0,
97 bool debug_synchronous =
false)
99 return hipCUDAErrorTohipError(::cub::DeviceMergeSort::SortKeys(d_temp_storage,
108 template<
typename KeyInputIteratorT,
109 typename KeyIteratorT,
112 HIPCUB_RUNTIME_FUNCTION
static hipError_t SortKeysCopy(
void * d_temp_storage,
113 std::size_t & temp_storage_bytes,
114 KeyInputIteratorT d_input_keys,
115 KeyIteratorT d_output_keys,
117 CompareOpT compare_op,
118 hipStream_t stream = 0,
119 bool debug_synchronous =
false)
122 return hipCUDAErrorTohipError(::cub::DeviceMergeSort::SortKeysCopy(d_temp_storage,
132 template <
typename KeyIteratorT,
133 typename ValueIteratorT,
136 HIPCUB_RUNTIME_FUNCTION
static hipError_t
137 StableSortPairs(
void *d_temp_storage,
138 std::size_t &temp_storage_bytes,
140 ValueIteratorT d_items,
142 CompareOpT compare_op,
143 hipStream_t stream = 0,
144 bool debug_synchronous =
false)
146 return hipCUDAErrorTohipError(
147 ::cub::DeviceMergeSort::StableSortPairs(d_temp_storage,
158 template<
typename KeyIteratorT,
typename OffsetT,
typename CompareOpT>
159 HIPCUB_RUNTIME_FUNCTION
static hipError_t StableSortKeys(
void * d_temp_storage,
160 std::size_t & temp_storage_bytes,
163 CompareOpT compare_op,
164 hipStream_t stream = 0,
165 bool debug_synchronous =
false)
167 return hipCUDAErrorTohipError(::cub::DeviceMergeSort::StableSortKeys(d_temp_storage,
Definition: device_merge_sort.hpp:40