Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
sort_by_key_pow2_len.hpp
Go to the documentation of this file.
1// -------------------------------------------------------//
2//
3// SHAMROCK code for hydrodynamics
4// Copyright (c) 2021-2026 Timothée David--Cléris <tim.shamrock@proton.me>
5// SPDX-License-Identifier: CeCILL Free Software License Agreement v2.1
6// Shamrock is licensed under the CeCILL 2.1 License, see LICENSE for more information
7//
8// -------------------------------------------------------//
9
10#pragma once
11
28
32
33namespace shamalgs::primitives {
34
60 template<class Tkey, class Tval>
62 sycl::queue &q, sycl::buffer<Tkey> &buf_key, sycl::buffer<Tval> &buf_values, u32 len);
63
89 template<class Tkey, class Tval>
91 const sham::DeviceScheduler_ptr &sched,
92 sham::DeviceBuffer<Tkey> &buf_key,
93 sham::DeviceBuffer<Tval> &buf_values,
94 u32 len);
95
96} // namespace shamalgs::primitives
std::uint32_t u32
32 bit unsigned integer
namespace for primitive algorithm (e.g. sort, scan, reductions, ...)
void sort_by_key_pow2_len(sycl::queue &q, sycl::buffer< Tkey > &buf_key, sycl::buffer< Tval > &buf_values, u32 len)
Sort key-value pairs using sycl::buffers (power-of-2 optimized).