Loading...
Searching...
No Matches
buffer_copy_kernels.hpp File Reference

Go to the source code of this file.

Classes

struct  terra::communication::detail_view_constraints::is_kokkos_view< T >
 
struct  terra::communication::detail_view_constraints::is_kokkos_view< Kokkos::View< Args... > >
 

Namespaces

namespace  terra
 
namespace  terra::communication
 
namespace  terra::communication::detail
 
namespace  terra::communication::detail_view_constraints
 

Enumerations

enum class  terra::communication::CommunicationReduction { terra::communication::SUM , terra::communication::MIN , terra::communication::MAX }
 Communication reduction modes. More...
 

Functions

template<typename T >
void terra::communication::detail::reduction_function (T *ptr, const T &val, const CommunicationReduction reduction_type)
 Helper function to defer to the respective Kokkos::atomic_xxx() reduction function.
 
template<typename DataView , bool is_scalar>
DataView::value_type terra::communication::detail::value (const DataView &data, int local_subdomain_id, int x, int y, int r, int d)
 
template<typename DataView , bool is_scalar>
DataView::value_type & terra::communication::detail::value_ref (const DataView &data, int local_subdomain_id, int x, int y, int r, int d)
 
constexpr int terra::communication::detail::idx (const int loop_idx, const int size, const grid::BoundaryPosition position, const grid::BoundaryDirection direction)
 
template<int VecDim, typename BufferView , typename ViewType >
std::enable_if_t< detail_view_constraints::is_kokkos_view_v< BufferView > &&detail_view_constraints::is_kokkos_view_v< ViewType > &&(std::decay_t< BufferView >::rank==1)> terra::communication::copy_to_buffer (const BufferView &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryVertex boundary_vertex)
 
template<int VecDim, typename BufferView , typename ViewType >
std::enable_if_t< detail_view_constraints::is_kokkos_view_v< BufferView > &&detail_view_constraints::is_kokkos_view_v< ViewType > &&(std::decay_t< BufferView >::rank==2)> terra::communication::copy_to_buffer (const BufferView &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryEdge boundary_edge)
 
template<int VecDim, typename BufferView , typename ViewType >
std::enable_if_t< detail_view_constraints::is_kokkos_view_v< BufferView > &&detail_view_constraints::is_kokkos_view_v< ViewType > &&(std::decay_t< BufferView >::rank==3)> terra::communication::copy_to_buffer (const BufferView &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryFace boundary_face)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_to_buffer (const grid::Grid0DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryVertex boundary_vertex)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_to_buffer (const grid::Grid1DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryEdge boundary_edge)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_to_buffer (const grid::Grid2DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryFace boundary_face)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_from_buffer_rotate_and_reduce (const grid::Grid0DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryVertex boundary_vertex, const CommunicationReduction reduction)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_from_buffer_rotate_and_reduce (const grid::Grid1DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryEdge boundary_edge, const grid::BoundaryDirection boundary_direction, const CommunicationReduction reduction)
 
template<typename ScalarType , int VecDim, typename ViewType >
void terra::communication::copy_from_buffer_rotate_and_reduce (const grid::Grid2DDataVec< ScalarType, VecDim > &buffer, const ViewType &data, const int local_subdomain_id, const grid::BoundaryFace boundary_face, const std::tuple< grid::BoundaryDirection, grid::BoundaryDirection > boundary_directions, const CommunicationReduction reduction)
 

Variables

template<class V >
constexpr bool terra::communication::detail_view_constraints::is_kokkos_view_v = is_kokkos_view<std::decay_t<V>>::value