![]() |
Shamrock 2025.10.0
Astrophysical Code
|
Sort by keys algorithms. More...
#include "shambase/exception.hpp"#include "shambase/overloaded.hpp"#include "shamalgs/ImplVariant.hpp"#include "shamalgs/details/algorithm/batcherOddEvenSort.hpp"#include "shamalgs/primitives/device/details/sort_by_keys_std_sort.hpp"#include "shamalgs/primitives/sort_by_keys.hpp"#include "shamcomm/logs.hpp"#include <algorithm>#include <vector>Go to the source code of this file.
Classes | |
| struct | shamalgs::primitives::impl::StdSort |
| Copy the buffers to host, std::sort the zipped key/value pairs, and copy back. More... | |
| struct | shamalgs::primitives::impl::BatcherOddEvenHostSerial |
| Copy the buffers to host, sort with Batcher's odd-even merge sort, and copy back. More... | |
| struct | shamalgs::primitives::impl::BatcherOddEven |
| Copy the buffers to host, sort with Batcher's odd-even merge sort, and copy back. More... | |
Namespaces | |
| namespace | shamalgs |
| namespace to contain everything implemented by shamalgs | |
| namespace | shamalgs::primitives |
| namespace for primitive algorithm (e.g. sort, scan, reductions, ...) | |
| namespace | shamalgs::primitives::impl |
| namespace to control implementation behavior | |
Functions | |
| template<class Tkey, class Tval> | |
| void | shamalgs::primitives::details::sort_by_keys_batcher_odd_even_host_serial (sham::DeviceBuffer< Tkey > &buf_key, sham::DeviceBuffer< Tval > &buf_values, u32 len) |
| std::vector< std::string > | shamalgs::primitives::impl::get_default_impl_list_sort_by_keys () |
| Get list of available sort by keys implementations, as config json strings. | |
| std::string | shamalgs::primitives::impl::get_current_impl_sort_by_keys () |
| Get the current implementation for sort by keys, as a config json string. | |
| bool | shamalgs::primitives::impl::is_impl_set_sort_by_keys () |
| Check if an implementation has been selected for sort by keys. | |
| void | shamalgs::primitives::impl::set_impl_sort_by_keys (const std::string &impl) |
| Set the implementation for sort by keys, from a config json string. | |
| void | shamalgs::primitives::impl::autoselect_impl_sort_by_keys (const sham::DeviceScheduler_ptr &dev_sched) |
| Select the default implementation for sort by keys. | |
| template<class Tkey, class Tval> | |
| void | shamalgs::primitives::sort_by_keys (sham::DeviceBuffer< Tkey > &buf_key, sham::DeviceBuffer< Tval > &buf_values, u32 len) |
| Sort key-value pairs using USM buffers (general length). | |
| template void | shamalgs::primitives::sort_by_keys (sham::DeviceBuffer< u32 > &buf_key, sham::DeviceBuffer< u32 > &buf_values, u32 len) |
| template void | shamalgs::primitives::sort_by_keys (sham::DeviceBuffer< u64 > &buf_key, sham::DeviceBuffer< u32 > &buf_values, u32 len) |
| template void | shamalgs::primitives::sort_by_keys (sham::DeviceBuffer< f64 > &buf_key, sham::DeviceBuffer< f64 > &buf_values, u32 len) |
| template void | shamalgs::primitives::sort_by_keys (sham::DeviceBuffer< f32 > &buf_key, sham::DeviceBuffer< f32 > &buf_values, u32 len) |
Variables | |
| shamalgs::ImplVariantGlobal< StdSort, BatcherOddEvenHostSerial, BatcherOddEven > | shamalgs::primitives::impl::sort_by_keys_impl |
Sort by keys algorithms.
Definition in file sort_by_keys.cpp.
|
inline |
Copy both buffers to host, sort the zipped key/value pairs with batcher_odd_even_host_serial, and copy back
Definition at line 32 of file sort_by_keys.cpp.