Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
reduction.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
21#include "shambase/memory.hpp"
26#include "shambackends/math.hpp"
27#include "shambackends/sycl.hpp"
28#include "shambackends/vec.hpp"
29
30namespace shamalgs::reduction {
31
32 template<class T>
33 bool has_nan(sycl::queue &q, sycl::buffer<T> &buf, u64 cnt);
34
35 template<class T>
36 bool has_inf(sycl::queue &q, sycl::buffer<T> &buf, u64 cnt);
37
38 template<class T>
39 bool has_nan_or_inf(sycl::queue &q, sycl::buffer<T> &buf, u64 cnt);
40
41} // namespace shamalgs::reduction
std::uint64_t u64
64 bit unsigned integer
This header file contains utility functions related to exception handling in the code.
Boolean reduction algorithm for checking if all elements are non-zero.