|
KaMPIng 0.2.0
Flexible and (near) zero-overhead C++ bindings for MPI
|
Wrapper for a user defined reduction operation based on a function pointer. More...
#include <mpi_ops.hpp>
Public Member Functions | |
| UserOperationPtrWrapper< is_commutative > & | operator= (UserOperationPtrWrapper< is_commutative > const &)=delete |
| UserOperationPtrWrapper< is_commutative > & | operator= (UserOperationPtrWrapper< is_commutative > &&other_op) |
| move assignment | |
| UserOperationPtrWrapper (UserOperationPtrWrapper< is_commutative > const &)=delete | |
| UserOperationPtrWrapper (UserOperationPtrWrapper< is_commutative > &&other_op) | |
| move constructor | |
| UserOperationPtrWrapper () | |
| creates an empty operation wrapper | |
| UserOperationPtrWrapper (mpi_custom_operation_type ptr) | |
| creates an MPI operation for the specified function pointer | |
| MPI_Op | get_mpi_op () |
Wrapper for a user defined reduction operation based on a function pointer.
Internally, this creates an MPI_Op which is freed upon destruction.
| is_commutative | whether the operation is commutative or not |
|
inline |
creates an MPI operation for the specified function pointer
| ptr | the functor to call for reduction this parameter must match the semantics of the function pointer passed to MPI_Op_create according to the MPI standard. |
|
inline |
MPI_Op constructed for the provided functor.Do not free this operation manually, because the destructor calls it. Some MPI implementations silently segfault if an MPI_Op is freed multiple times.