|
Template Numerical Library version\ main:4904c12
|
CUDA radix sort using CUB's DeviceRadixSort. More...
#include <TNL/Algorithms/Sorting/CUBRadixSort.h>
Static Public Member Functions | |
| template<typename Array> | |
| static void | sort (Array &array) |
| Sort an array of arithmetic values into ascending order. | |
CUDA radix sort using CUB's DeviceRadixSort.
This class provides a wrapper for radix sort implementation from NVIDIA's CUB library. It uses the cub::DeviceRadixSort::SortKeys algorithm which performs a stable radix sort on device-resident data.
Radix sort is a stable sorting algorithm.
This implementation requires additional storage:
The total memory overhead is approximately \(2N + P\).
|
inlinestatic |
Sort an array of arithmetic values into ascending order.
| Array | is a type of container to be sorted. It must be TNL::Containers::Array or TNL::Containers::ArrayView with TNL::Devices::Cuda device type. |
| array | The array to sort (will be modified in-place). |