29 #ifndef HIPCUB_ROCPRIM_DEVICE_DEVICE_ADJACENT_DIFFERENCE_HPP_
30 #define HIPCUB_ROCPRIM_DEVICE_DEVICE_ADJACENT_DIFFERENCE_HPP_
32 #include "../../../config.hpp"
34 #include <hipcub/thread/thread_operators.hpp>
35 #include <rocprim/device/device_adjacent_difference.hpp>
37 BEGIN_HIPCUB_NAMESPACE
39 struct DeviceAdjacentDifference
41 template<
typename InputIteratorT,
42 typename OutputIteratorT,
44 typename NumItemsT = std::uint32_t>
45 static HIPCUB_RUNTIME_FUNCTION hipError_t SubtractLeftCopy(
void* d_temp_storage,
46 std::size_t& temp_storage_bytes,
47 InputIteratorT d_input,
48 OutputIteratorT d_output,
50 DifferenceOpT difference_op = {},
51 hipStream_t stream = 0,
52 bool debug_synchronous =
false)
54 return ::rocprim::adjacent_difference(
55 d_temp_storage, temp_storage_bytes, d_input, d_output,
56 num_items, difference_op, stream, debug_synchronous
60 template<
typename RandomAccessIteratorT,
62 typename NumItemsT = std::uint32_t>
63 static HIPCUB_RUNTIME_FUNCTION hipError_t SubtractLeft(
void* d_temp_storage,
64 std::size_t& temp_storage_bytes,
65 RandomAccessIteratorT d_input,
67 DifferenceOpT difference_op = {},
68 hipStream_t stream = 0,
69 bool debug_synchronous =
false)
71 return ::rocprim::adjacent_difference_inplace(
72 d_temp_storage, temp_storage_bytes, d_input,
73 num_items, difference_op, stream, debug_synchronous
77 template<
typename InputIteratorT,
78 typename OutputIteratorT,
80 typename NumItemsT = std::uint32_t>
81 static HIPCUB_RUNTIME_FUNCTION hipError_t SubtractRightCopy(
void* d_temp_storage,
82 std::size_t& temp_storage_bytes,
83 InputIteratorT d_input,
84 OutputIteratorT d_output,
86 DifferenceOpT difference_op = {},
87 hipStream_t stream = 0,
88 bool debug_synchronous =
false)
90 return ::rocprim::adjacent_difference_right(
91 d_temp_storage, temp_storage_bytes, d_input, d_output,
92 num_items, difference_op, stream, debug_synchronous
96 template<
typename RandomAccessIteratorT,
98 typename NumItemsT = std::uint32_t>
99 static HIPCUB_RUNTIME_FUNCTION hipError_t SubtractRight(
void* d_temp_storage,
100 std::size_t& temp_storage_bytes,
101 RandomAccessIteratorT d_input,
103 DifferenceOpT difference_op = {},
104 hipStream_t stream = 0,
105 bool debug_synchronous =
false)
107 return ::rocprim::adjacent_difference_right_inplace(
108 d_temp_storage, temp_storage_bytes, d_input,
109 num_items, difference_op, stream, debug_synchronous
Definition: thread_operators.hpp:86