template<typename DATA_TYPE, int SHAPE>
atlas::mpi::Buffer struct

Buffer<DATA_TYPE,SHAPE>

Class that keeps allocation of a MPI buffer including counts and displacements, but with added index operator[] that returns an array::ArrayView<DATA_TYPE,SHAPE> of the part of the buffer for a processor index.

Base classes

template<typename DATA_TYPE>
struct eckit::mpi::Buffer<DATA_TYPE>
Buffer handles colleciton of vector pieces into a larger vector.

Public types

using value_type = DATA_TYPE
using iterator = std::vector<DATA_TYPE>::iterator

Public functions

auto begin() -> iterator
auto end() -> iterator

Public variables

int cnt
std::vector<int> counts
std::vector<int> displs
std::vector<DATA_TYPE> buffer

Typedef documentation

template<typename DATA_TYPE, int SHAPE>
typedef DATA_TYPE atlas::mpi::Buffer<DATA_TYPE, SHAPE>::value_type

template<typename DATA_TYPE, int SHAPE>
typedef std::vector<DATA_TYPE>::iterator atlas::mpi::Buffer<DATA_TYPE, SHAPE>::iterator

Function documentation

template<typename DATA_TYPE, int SHAPE>
iterator atlas::mpi::Buffer<DATA_TYPE, SHAPE>::begin()

template<typename DATA_TYPE, int SHAPE>
iterator atlas::mpi::Buffer<DATA_TYPE, SHAPE>::end()

Variable documentation

template<typename DATA_TYPE, int SHAPE>
int atlas::mpi::Buffer<DATA_TYPE, SHAPE>::cnt

template<typename DATA_TYPE, int SHAPE>
std::vector<int> atlas::mpi::Buffer<DATA_TYPE, SHAPE>::counts

template<typename DATA_TYPE, int SHAPE>
std::vector<int> atlas::mpi::Buffer<DATA_TYPE, SHAPE>::displs

template<typename DATA_TYPE, int SHAPE>
std::vector<DATA_TYPE> atlas::mpi::Buffer<DATA_TYPE, SHAPE>::buffer