KaMPIng 0.1.1
Flexible and (near) zero-overhead C++ bindings for MPI
|
Factory methods for buffer wrappers. More...
#include <cstddef>
#include <initializer_list>
#include <type_traits>
#include <utility>
#include "kamping/data_buffer.hpp"
#include "kamping/mpi_ops.hpp"
#include "kamping/named_parameter_types.hpp"
#include "kamping/named_parameters_detail/status_parameters.hpp"
#include "kamping/operation_builder.hpp"
#include "kamping/parameter_objects.hpp"
#include "kamping/request.hpp"
#include "kamping/serialization.hpp"
Go to the source code of this file.
Classes | |
struct | kamping::internal::unused_tparam |
An unused template parameter. More... | |
Namespaces | |
namespace | kamping::internal |
Internal namespace marking the code that is not user-facing. | |
Functions | |
template<typename Data > | |
auto | kamping::send_buf (internal::ignore_t< Data > ignore) |
Generates a dummy send buf that wraps a nullptr . | |
template<typename Data , typename Enable = std::enable_if_t<!internal::is_serialization_buffer_v<Data>>> | |
auto | kamping::send_buf (Data &&data) |
Passes a container/single value as a send buffer to the underlying MPI call. | |
template<typename SerializationBufferType , std::enable_if_t< internal::is_serialization_buffer_v< SerializationBufferType >, bool > = true> | |
auto | kamping::send_buf (SerializationBufferType &&data) |
Passes a container/single value as a send buffer to the underlying MPI call. Additionally indicates to use serialization to transfer the data. | |
template<typename T > | |
auto | kamping::send_buf (std::initializer_list< T > data) |
Passes the data provided as an initializer list as a send buffer to the underlying MPI call. | |
template<typename Data , typename Enable = std::enable_if_t<std::is_rvalue_reference_v<Data&&>>> | |
auto | kamping::send_buf_out (Data &&data) |
Passes a container/single value as rvalue as a send buffer to the underlying MPI call. This transfers ownership of the data to the call and re-returns ownership to the caller as part of the result object. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Data , typename Enable = std::enable_if_t<!internal::is_serialization_buffer_v<Data>>> | |
auto | kamping::send_recv_buf (Data &&data) |
Passes a container/single value as a send or receive buffer to the underlying MPI call. | |
template<typename SerializationBufferType , typename Enable = std::enable_if_t<internal::is_serialization_buffer_v<SerializationBufferType>>> | |
auto | kamping::send_recv_buf (SerializationBufferType &&buffer) |
Passes a container/single value as a send or receive buffer to the underlying MPI call. Additionally indicates to use serialization to transfer the data. | |
template<typename Container > | |
auto | kamping::send_recv_buf (AllocNewT< Container >) |
Indicates to use an object of type. | |
template<typename ValueType > | |
auto | kamping::send_recv_buf (AllocContainerOfT< ValueType >) |
Indicates to use a parameter object encapsulating an underlying container with a value_type . | |
template<typename Container > | |
auto | kamping::send_counts (Container &&container) |
Passes a container as send counts to the underlying call, i.e. the container's storage must contain the send count to each relevant PE. | |
template<typename T > | |
auto | kamping::send_counts (std::initializer_list< T > counts) |
Passes the initializer list as send counts to the underlying call. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container > | |
auto | kamping::send_counts_out (Container &&container) |
Passes a container , into which the send counts deduced by KaMPIng will be written, to the underlying call. Container must satisfy the following constraints: | |
template<typename Container > | |
auto | kamping::send_counts_out (AllocNewT< Container >) |
Indicates to construct an object of type Container , into which the send counts deduced by KaMPIng will be written, in the underlying call. Container must satisfy the following constraints: | |
template<template< typename... > typename Container> | |
auto | kamping::send_counts_out (AllocNewUsingT< Container >) |
Indicates to construct a container with type Container<int> , into which the send counts deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::send_counts_out () |
Indicates to construct a container with type kamping::Communicator::default_container_type<int>, into which the send counts deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::send_count (int count) |
Passes count as send count to the underlying call. | |
auto | kamping::send_count_out (int &count) |
Passes count , into which the send count deduced by KaMPIng will be written, to the underlying call. | |
auto | kamping::send_count_out () |
Indicates to deduce the send count and return it to the caller as part of the underlying call's result object. | |
template<typename Container > | |
auto | kamping::recv_counts (Container &&container) |
Passes a container as recv counts to the underlying call, i.e. the container's storage must contain the recv count from each relevant PE. | |
template<typename T > | |
auto | kamping::recv_counts (std::initializer_list< T > counts) |
Passes the initializer list as recv counts to the underlying call. | |
auto | kamping::recv_counts (internal::ignore_t< void > ignore) |
Indicates that the recv counts are ignored. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container > | |
auto | kamping::recv_counts_out (Container &&container) |
Passes a container , into which the recv counts deduced by KaMPIng will be written, to the underlying call. Container must satisfy the following constraints: | |
template<typename Data > | |
auto | kamping::recv_counts_out (AllocNewT< Data > container) |
Indicates to construct an object of type Container , into which the recv counts deduced by KaMPIng will be written, in the underlying call. Container must satisfy the following constraints: | |
template<template< typename... > typename Data> | |
auto | kamping::recv_counts_out (AllocNewUsingT< Data > container) |
Indicates to construct a container with type Container<int> , into which the recv counts deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::recv_counts_out () |
Indicates to construct a container with type kamping::Communicator::default_container_type<int>, into which the recv counts deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::recv_count (int count) |
Passes count as recv count to the underlying call. | |
auto | kamping::recv_count_out (int &count) |
Passes count , into which the recv count deduced by KaMPIng will be written, to the underlying call. | |
auto | kamping::recv_count_out () |
Indicates to deduce the recv count and return it to the caller as part of the underlying call's result object. | |
auto | kamping::send_recv_count (int count) |
Passes count as send/recv count to the underlying call. | |
auto | kamping::send_recv_count_out (int &count) |
Passes count , into which the send/recv count deduced by KaMPIng will be written, to the underlying call. | |
auto | kamping::send_recv_count_out () |
Indicates to deduce the send/recv count and return it to the caller as part of the underlying call's result object. | |
template<typename Container > | |
auto | kamping::send_displs (Container &&container) |
Passes a container as send displacements to the underlying call, i.e. the container's storage must contain the send displacement for each relevant PE. | |
template<typename T > | |
auto | kamping::send_displs (std::initializer_list< T > displs) |
Passes the initializer list as send displacements to the underlying call. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container > | |
auto | kamping::send_displs_out (Container &&container) |
Passes a container , into which the send displacements deduced by KaMPIng will be written, to the underlying call. Container must satisfy the following constraints: | |
template<typename Container > | |
auto | kamping::send_displs_out (AllocNewT< Container >) |
Indicates to construct an object of type Container , into which the send displacements deduced by KaMPIng will be written, in the underlying call. Container must satisfy the following constraints: | |
template<template< typename... > typename Container> | |
auto | kamping::send_displs_out (AllocNewUsingT< Container >) |
Indicates to construct a container with type Container<int> , into which the send displacements deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::send_displs_out () |
Indicates to construct a container with type kamping::Communicator::default_container_type<int>, into which the send displacements deduced by KaMPIng will be written, in the underlying call. | |
template<typename Container > | |
auto | kamping::recv_displs (Container &&container) |
Passes a container as receive displacements to the underlying call, i.e. the container's storage must contain the receive displacement for each relevant PE. | |
template<typename T > | |
auto | kamping::recv_displs (std::initializer_list< T > displs) |
Passes the initializer list as receive displacements to the underlying call. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container > | |
auto | kamping::recv_displs_out (Container &&container) |
Passes a container , into which the receive displacements deduced by KaMPIng will be written, to the underlying call. Container must satisfy the following constraints: | |
template<typename Container > | |
auto | kamping::recv_displs_out (AllocNewT< Container >) |
Indicates to construct an object of type Container , into which the receive displacements deduced by KaMPIng will be written, in the underlying call. Container must satisfy the following constraints: | |
template<template< typename... > typename Container> | |
auto | kamping::recv_displs_out (AllocNewUsingT< Container >) |
Indicates to construct a container with type Container<int> , into which the receive displacements deduced by KaMPIng will be written, in the underlying call. | |
auto | kamping::recv_displs_out () |
Indicates to construct a container with type kamping::Communicator::default_container_type<int>, into which the receive displacements deduced by KaMPIng will be written, in the underlying call. | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container , typename Enable = std::enable_if_t<!internal::is_serialization_buffer_v<Container>>> | |
auto | kamping::recv_buf_out (Container &&container) |
Passes a container , into which the received elements will be written, to the underlying call. Container must satisfy the following constraints: | |
template<BufferResizePolicy resize_policy = BufferResizePolicy::no_resize, typename Container , typename Enable = std::enable_if_t<!internal::is_serialization_buffer_v<Container>>> | |
auto | kamping::recv_buf (Container &&container) |
Passes a container , into which the received elements will be written, to the underlying call. Container must satisfy the following constraints: | |
template<typename SerializationBufferType , typename Enable = std::enable_if_t<internal::is_serialization_buffer_v<SerializationBufferType>>> | |
auto | kamping::recv_buf_out (SerializationBufferType &&buffer) |
Indicates to deserialize the received elements in the underlying call. | |
template<typename SerializationBufferType , typename Enable = std::enable_if_t<internal::is_serialization_buffer_v<SerializationBufferType>>> | |
auto | kamping::recv_buf (SerializationBufferType &&buffer) |
Indicates to deserialize the received elements in the underlying call. | |
template<typename Container > | |
auto | kamping::recv_buf_out (AllocNewT< Container >) |
Indicates to construct a container of type Container , into which the received elements will be written, in the underlying call. | |
template<typename Container > | |
auto | kamping::recv_buf (AllocNewT< Container > tag) |
Indicates to construct a container of type Container , into which the received elements will be written, in the underlying call. | |
template<typename ValueType > | |
auto | kamping::recv_buf_out (AllocContainerOfT< ValueType >) |
Indicates to construct a container with type kamping::Communicator::default_container_type<ValueType> , into which the received elements will be written, in the underlying call. | |
template<typename ValueType > | |
auto | kamping::recv_buf (AllocContainerOfT< ValueType > tag) |
Indicates to construct a container with type kamping::Communicator::default_container_type<ValueType> , into which the received elements will be written, in the underlying call. | |
auto | kamping::root (int rank) |
Passes rank as root rank to the underlying call. This parameter is needed in functions like MPI_Gather . | |
auto | kamping::root (size_t rank) |
Passes rank as root rank to the underlying call. This parameter is needed in functions like MPI_Gather . | |
auto | kamping::destination (int rank) |
Passes rank as destination rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Send . | |
auto | kamping::destination (size_t rank) |
Passes rank as destination rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Send . | |
auto | kamping::destination (internal::rank_null_t) |
Passes MPI_PROC_NULL as destination rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Send . | |
auto | kamping::source (int rank) |
Passes rank as source rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Recv . | |
auto | kamping::source (size_t rank) |
Passes rank as source rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Recv . | |
auto | kamping::source (internal::rank_any_t) |
Indicates to use MPI_ANY_SOURCE as source rank in the underlying call, i.e. accepting any rank as source rank. This parameter is needed in point-to-point exchange routines like MPI_Recv . | |
auto | kamping::source (internal::rank_null_t) |
Passes MPI_PROC_NULL as source rank to the underlying call. This parameter is needed in point-to-point exchange routines like MPI_Recv . | |
auto | kamping::tag (internal::any_tag_t) |
Indicates to use MPI_ANY_TAG as tag in the underlying call. | |
auto | kamping::tag (int value) |
Passes value as tag to the underlying call. | |
template<typename EnumType , typename = std::enable_if_t<std::is_enum_v<EnumType>>> | |
auto | kamping::tag (EnumType value) |
Converts the passed enum value to its integer representaiton and passes this value to the underlying call. | |
auto | kamping::request (Request &request) |
Passes a request handle to the underlying MPI call. | |
template<typename IndexType > | |
auto | kamping::request (PooledRequest< IndexType > request) |
Passes a request from a RequestPool to the underlying MPI call. | |
auto | kamping::request () |
Internally allocate a request object and return it to the user. | |
template<typename SendModeTag > | |
auto | kamping::send_mode (SendModeTag) |
Passes the send mode parameter for point to point communication to the underlying call. Pass any of the tags from the kamping::send_modes namespace. | |
template<typename Op , typename Commutative = ops::internal::undefined_commutative_tag> | |
internal::OperationBuilder< Op, Commutative > | kamping::op (Op &&op, Commutative commute=ops::internal::undefined_commutative_tag{}) |
Passes a reduction operation to ther underlying call. Accepts function objects, lambdas, function pointers or native MPI_Op as argument. | |
template<typename Container > | |
auto | kamping::values_on_rank_0 (Container &&container) |
Passes a container containing the value(s) to return on the first rank to kamping::Communicator::exscan(). | |
template<typename T > | |
auto | kamping::values_on_rank_0 (std::initializer_list< T > values) |
Passes the data to be returned on the first rank in MPI_Exscan which is provided as an initializer list to kamping::Communicator::exscan(). | |
auto | kamping::send_type (MPI_Datatype send_type) |
Passes send_type as send type to the underlying call. | |
auto | kamping::send_type_out () |
Indicates to deduce the send type in the underlying call and return it as part of underlying call's result object. | |
auto | kamping::send_type_out (MPI_Datatype &send_type) |
Passes send_type , into which the send type deduced by KaMPIng will be written, to the underlying call. The type will be stored at the location referred to by the provided reference. | |
auto | kamping::recv_type (MPI_Datatype recv_type) |
Passes recv_type as recv type to the underlying call. | |
auto | kamping::recv_type_out () |
Indicates to deduce the receive type in the underlying call and return it as part of underlying call's result object. | |
auto | kamping::recv_type_out (MPI_Datatype &recv_type) |
Passes recv_type , into which the recv type deduced by KaMPIng will be written, to the underlying call. The type will be stored at the location referred to by the provided reference. | |
auto | kamping::send_recv_type (MPI_Datatype send_recv_type) |
Passes send_recv_type as send/recv type to the underlying call. (This parameter is in MPI routines such as MPI_Bcast , ... .) | |
auto | kamping::send_recv_type_out () |
Indicates to deduce the send/recv type in the underlying call and return it as part of underlying call's result object. (This parameter is used in MPI routines such as MPI_Bcast , ... .) | |
auto | kamping::send_recv_type_out (MPI_Datatype &send_recv_type) |
Passes send_recv_type , into which the send/recv type deduced by KaMPIng will be written, to the underlying call. The type will be stored at the location referred to by the provided reference. (This parameter is used in MPI routines such as MPI_Bcast , ... .) | |
Factory methods for buffer wrappers.