1 #ifndef AMREX_EB2_IF_UNION_H_
2 #define AMREX_EB2_IF_UNION_H_
3 #include <AMReX_Config.H>
18 namespace UIF_detail {
22 return std::forward<F>(
f)(p);
25 template <
typename F,
typename... Fs>
38 template <
typename F,
typename... Fs>
46 template <
class... Fs>
55 return op_impl(p, std::make_index_sequence<
sizeof...(Fs)>());
58 template <
class U=
UnionIF<Fs...>, std::enable_if_t<IsGPUable<U>::value,
int> = 0>
67 template <std::size_t... Is>
68 [[nodiscard]]
inline Real
op_impl (
const RealArray& p, std::index_sequence<Is...>)
const noexcept
73 template <std::size_t... Is>
81 template <
class Head,
class... Tail>
89 template <
class... Fs>
#define AMREX_GPU_HOST_DEVICE
Definition: AMReX_GpuQualifiers.H:20
#define AMREX_D_DECL(a, b, c)
Definition: AMReX_SPACE.H:104
Definition: AMReX_EB2_IF_Union.H:49
AMREX_GPU_HOST_DEVICE Real op_impl(AMREX_D_DECL(Real x, Real y, Real z), std::index_sequence< Is... >) const noexcept
Definition: AMReX_EB2_IF_Union.H:75
Real operator()(const RealArray &p) const noexcept
Definition: AMReX_EB2_IF_Union.H:53
Real op_impl(const RealArray &p, std::index_sequence< Is... >) const noexcept
Definition: AMReX_EB2_IF_Union.H:68
Definition: AMReX_Tuple.H:93
constexpr AMREX_GPU_HOST_DEVICE GpuTuple()=default
Real do_max(const RealArray &p, F &&f) noexcept
Definition: AMReX_EB2_IF_Union.H:20
Definition: AMReX_FabArrayBase.H:32
constexpr UnionIF< std::decay_t< Fs > ... > makeUnion(Fs &&... fs)
Definition: AMReX_EB2_IF_Union.H:91
static int f(amrex::Real t, N_Vector y_data, N_Vector y_rhs, void *user_data)
Definition: AMReX_SundialsIntegrator.H:44
AMREX_GPU_HOST_DEVICE constexpr AMREX_FORCE_INLINE const T & max(const T &a, const T &b) noexcept
Definition: AMReX_Algorithm.H:35
Array< Real, AMREX_SPACEDIM > RealArray
Definition: AMReX_Array.H:26
Definition: AMReX_EB2_IF_Base.H:15