AXOM
Axom provides a robust, flexible software infrastructure for the development of multi-physics applications and computational tools.
Sorting.hpp File Reference

Classes

struct  axom::utilities::detail::Delimiter
 
struct  axom::utilities::detail::less_than< T >
 Predicate that implements less than. More...
 
struct  axom::utilities::detail::greater_than< T >
 Predicate that implements greater than. More...
 
struct  axom::utilities::Sorting< T, N >
 This is a template suitable for sorting small arrays on device. More...
 
struct  axom::utilities::Sorting< T, 3 >
 Template specialization for sorting arrays with 3 elements. More...
 
struct  axom::utilities::Sorting< T, 4 >
 Template specialization for sorting arrays with 4 elements. More...
 

Namespaces

 axom
 
 axom::utilities
 
 axom::utilities::detail
 

Functions

template<typename T >
constexpr static AXOM_HOST_DEVICEaxom::utilities::detail::stack_size (T N)
 Computes stack size for qsort. More...
 
template<typename T >
AXOM_HOST_DEVICE void axom::utilities::detail::ifswap (T &a, T &b)
 Swap 2 elements if b < a. param a The first value. param b The second value. More...
 
AXOM_HOST_DEVICE void axom::utilities::detail::internal_swap (axom::IndexType, axom::IndexType)
 This method is called when there are no more values to swap. More...
 
template<typename T , typename... Args>
AXOM_HOST_DEVICE void axom::utilities::detail::internal_swap (axom::IndexType idx1, axom::IndexType idx2, T values, Args... args)
 Swap one set of values, move to next ones. More...
 
template<typename T , typename Predicate , typename... Args>
AXOM_HOST_DEVICE void axom::utilities::detail::ifswap_multiple (Predicate &&predicate, axom::IndexType idx1, axom::IndexType idx2, T values, Args... args)
 
template<typename T , typename Predicate , typename... Args>
static AXOM_HOST_DEVICE axom::IndexType axom::utilities::detail::partitionMultiple (Predicate &&predicate, axom::IndexType low, axom::IndexType high, T values, Args... args)
 Create a partition for qsort. More...
 
template<typename T , typename Predicate , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::detail::qsortMultiple (Predicate &&predicate, axom::IndexType n, T values, Args... args)
 Sort the input array using qsort. More...
 
template<typename T , typename Predicate , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::detail::insertionSortMultiple (Predicate &&predicate, axom::IndexType n, T values, Args... args)
 Perform actual sort on multiple data arrays. More...
 
template<typename T , typename Predicate , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::detail::sort_multiple_internal (Predicate &&predicate, axom::IndexType n, T first, Delimiter, Args... args)
 Terminal case for argument reordering where we know all of the array arguments as well as the array length argument. More...
 
template<typename T , typename Predicate , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::detail::sort_multiple_internal (Predicate &&predicate, T first, Delimiter d, axom::IndexType n, Args... args)
 Shift args to end until the array length is at the desired position. More...
 
template<typename T , typename Predicate , typename S , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::detail::sort_multiple_internal (Predicate &&predicate, T first, Delimiter d, S second, Args... args)
 Shift args to end until the array length is at the desired position. More...
 
template<typename T , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::sort_multiple (T first, Args... args)
 Sort multiple arrays, using the first array as the key for sorting. All other arrays are sorted the same. More...
 
template<typename T , typename... Args>
static AXOM_HOST_DEVICE void axom::utilities::reverse_sort_multiple (T first, Args... args)
 Sort multiple arrays in reverse order, using the first array as the key for sorting. All other arrays are sorted the same. More...