Block-Structured AMR Software Framework
AMReX_Tuple.H File Reference
#include <AMReX_Config.H>
#include <AMReX_Array.H>
#include <AMReX_Functional.H>
#include <AMReX_GpuQualifiers.H>
#include <AMReX_TypeList.H>
#include <AMReX_TypeTraits.H>
#include <array>
#include <functional>
#include <tuple>

Go to the source code of this file.

Classes

struct  amrex::detail::gpu_tuple_element< I, T >
 
struct  amrex::detail::gpu_tuple_impl< I, Head, Tail... >
 
struct  amrex::detail::gpu_tuple_impl< I, Head >
 
class  amrex::GpuTuple< Ts >
 
struct  amrex::GpuTupleSize< GpuTuple< Ts... > >
 
struct  amrex::GpuTupleElement< I, GpuTuple< Head, Tail... > >
 
struct  amrex::GpuTupleElement< 0, GpuTuple< Head, Tail... > >
 
struct  amrex::detail::unwrap< T >
 
struct  amrex::detail::unwrap< std::reference_wrapper< T > >
 
struct  amrex::detail::tuple_cat_result<... >
 
struct  amrex::detail::tuple_cat_result< GpuTuple< Ts... > >
 
struct  amrex::detail::tuple_cat_result< GpuTuple< T1s... >, GpuTuple< T2s... >, TPs... >
 
struct  amrex::detail::SplitIndexList< Is >
 
struct  amrex::detail::invoke_result< V, F, Args >
 
struct  amrex::detail::invoke_result< decltype(void(INVOKE(std::declval< F >(), std::declval< Args >()...))), F, Args... >
 
struct  amrex::detail::apply_result< F,... >
 
struct  amrex::detail::apply_result< F, GpuTuple< Ts... > >
 
struct  std::tuple_size< amrex::GpuTuple< Ts... > >
 
struct  std::tuple_element< std::size_t{0}, amrex::GpuTuple< T, Ts... > >
 
struct  std::tuple_element< s, amrex::GpuTuple< T, Ts... > >
 

Namespaces

 amrex
 
 amrex::detail
 

Typedefs

template<class... Ts>
using amrex::Tuple = std::tuple< Ts... >
 
template<typename T >
using amrex::detail::tuple_decay_t = typename unwrap< std::decay_t< T > >::type
 

Functions

template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type & amrex::detail::get_impl (detail::gpu_tuple_element< I, typename GpuTupleElement< I, GpuTuple< Ts... > >::type > &te) noexcept
 
template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type const & amrex::detail::get_impl (detail::gpu_tuple_element< I, typename GpuTupleElement< I, GpuTuple< Ts... > >::type > const &te) noexcept
 
template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type && amrex::detail::get_impl (detail::gpu_tuple_element< I, typename GpuTupleElement< I, GpuTuple< Ts... > >::type > &&te) noexcept
 
template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type & amrex::get (GpuTuple< Ts... > &tup) noexcept
 
template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type const & amrex::get (GpuTuple< Ts... > const &tup) noexcept
 
template<std::size_t I, typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTupleElement< I, GpuTuple< Ts... > >::type && amrex::get (GpuTuple< Ts... > &&tup) noexcept
 
template<std::size_t I, std::size_t N, typename TP1 , typename TP2 >
AMREX_GPU_HOST_DEVICE std::enable_if_t<(I< N-1), void > amrex::detail::tuple_copy (TP1 &a, TP2 &&b)
 
template<std::size_t I, std::size_t N, typename TP1 , typename TP2 >
AMREX_GPU_HOST_DEVICE std::enable_if_t< I==N-1, void > amrex::detail::tuple_copy (TP1 &a, TP2 &&b)
 
template<typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTuple< detail::tuple_decay_t< Ts >... > amrex::makeTuple (Ts &&... args)
 
template<typename R , typename TP1 , typename TP2 , std::size_t... N1, std::size_t... N2>
constexpr AMREX_GPU_HOST_DEVICEamrex::detail::make_tuple (TP1 const &a, TP2 const &b, std::index_sequence< N1... > const &, std::index_sequence< N2... > const &)
 
template<typename TP >
constexpr AMREX_GPU_HOST_DEVICE auto amrex::TupleCat (TP &&a) -> typename detail::tuple_cat_result< detail::tuple_decay_t< TP > >::type
 
template<typename TP1 , typename TP2 >
constexpr AMREX_GPU_HOST_DEVICE auto amrex::TupleCat (TP1 &&a, TP2 &&b) -> typename detail::tuple_cat_result< detail::tuple_decay_t< TP1 >, detail::tuple_decay_t< TP2 > >::type
 
template<typename TP1 , typename TP2 , typename... TPs>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::TupleCat (TP1 &&a, TP2 &&b, TPs &&... args) -> typename detail::tuple_cat_result< detail::tuple_decay_t< TP1 >, detail::tuple_decay_t< TP2 >, detail::tuple_decay_t< TPs >... >::type
 
template<std::size_t start, typename... Args, std::size_t... Is>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::detail::GetSubTuple (const GpuTuple< Args... > &tup, std::index_sequence< Is... >) noexcept
 
template<typename... Args, std::size_t... Is, typename SIL >
constexpr AMREX_GPU_HOST_DEVICE auto amrex::detail::TupleSplitImp (const GpuTuple< Args... > &tup, std::index_sequence< Is... >, SIL) noexcept
 
template<std::size_t... Is, typename... Args>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::TupleSplit (const GpuTuple< Args... > &tup) noexcept
 Returns a GpuTuple of GpuTuples obtained by splitting the input GpuTuple according to the sizes specified by the template arguments. More...
 
template<typename F , typename... Args>
AMREX_GPU_HOST_DEVICE auto amrex::detail::INVOKE (F &&f, Args &&... args) -> decltype(f(std::forward< Args >(args)...))
 
template<typename F , typename TP , std::size_t... N>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::detail::apply_impl (F &&f, TP &&t, std::index_sequence< N... >) -> typename detail::apply_result< F, detail::tuple_decay_t< TP > >::type
 
template<typename F , typename TP >
constexpr AMREX_GPU_HOST_DEVICE auto amrex::Apply (F &&f, TP &&t) -> typename detail::apply_result< F, detail::tuple_decay_t< TP > >::type
 
template<typename... Args>
constexpr AMREX_GPU_HOST_DEVICE GpuTuple< Args &... > amrex::Tie (Args &... args) noexcept
 
template<typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTuple< Ts &&... > amrex::ForwardAsTuple (Ts &&... args) noexcept
 
template<typename... Ts>
constexpr AMREX_GPU_HOST_DEVICE GpuTuple< Ts... > amrex::MakeZeroTuple (GpuTuple< Ts... >) noexcept
 Return a GpuTuple containing all zeros. Note that a default-constructed GpuTuple can have uninitialized values. More...
 
template<typename T , std::size_t... I>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::detail::tuple_to_array_helper (T const &tup, std::index_sequence< I... >)
 
template<typename T >
constexpr AMREX_GPU_HOST_DEVICE auto amrex::tupleToArray (GpuTuple< T > const &tup)
 
template<typename T , typename T2 , typename... Ts, std::enable_if_t< Same< T, T2, Ts... >::value, int > = 0>
constexpr AMREX_GPU_HOST_DEVICE auto amrex::tupleToArray (GpuTuple< T, T2, Ts... > const &tup)
 Convert GpuTuple<T,T2,Ts...> to GpuArray. More...