54 return op->
init(user_fn, commute);
81 inline int AMPI_Op_create(
const bool requiresPrimal,
const bool requiresPrimalSend,
82 MPI_User_function* primalFunction,
int primalFunctionCommute,
83 MPI_User_function* modifiedPrimalFunction,
int modifiedPrimalFunctionCommute,
87 return op->
init(requiresPrimal, requiresPrimalSend, primalFunction, primalFunctionCommute, modifiedPrimalFunction, modifiedPrimalFunctionCommute, preAdjointOperation, postAdjointOperation);
Global namespace for MeDiPack - Message Differentiation Package.
Definition adjointInterface.hpp:37
void(* PreAdjointOperation)(void *adjoints, void *primals, int count, int dim)
Definition typeDefinitions.h:49
int AMPI_Op_create(MPI_User_function *user_fn, int commute, AMPI_Op *op)
Default forward of the operator creation.
Definition operatorFunctions.hpp:53
int AMPI_Op_free(AMPI_Op *op)
Frees the operator.
Definition operatorFunctions.hpp:97
void(* PostAdjointOperation)(void *adjoints, void *primals, void *rootPrimals, int count, int dim)
Definition typeDefinitions.h:50
Structure for the special handling of the MPI_Op structure.
Definition op.hpp:50
int free()
Definition op.hpp:186
int init(const bool requiresPrimal, const bool requiresPrimalSend, MPI_User_function *primalFunction, int primalFunctionCommute, MPI_User_function *modifiedPrimalFunction, int modifiedPrimalFunctionCommute, const PreAdjointOperation preAdjointOperation, const PostAdjointOperation postAdjointOperation)
Creates an operator with a specialized adjoint handling.
Definition op.hpp:129