DistDir
Functions
Backend_mpi

Functions

t_mpi_exchangenew_mpi_exchanger (MPI_Datatype type, int size)
 Create t_mpi_exchange object. More...
 
void delete_mpi_exchanger (t_mpi_exchange *mpi_exchange)
 Free memory of t_mpi_exchange object. More...
 
void mpi_wrapper_isend_int (int *buffer, int count, MPI_Datatype datatype, int dest, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Isend for integer buffers. More...
 
void mpi_wrapper_isend_float (float *buffer, int count, MPI_Datatype datatype, int dest, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Isend for float buffers. More...
 
void mpi_wrapper_isend_double (double *buffer, int count, MPI_Datatype datatype, int dest, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Isend for double buffers. More...
 
void mpi_wrapper_irecv_int (int *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Irecv for integer buffers. More...
 
void mpi_wrapper_irecv_float (float *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Irecv for float buffers. More...
 
void mpi_wrapper_irecv_double (double *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Request *request, int offset)
 Lightweight wrapper around MPI_Irecv for double buffers. More...
 
void mpi_wrapper_recv_int (int *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Status *status, int offset)
 Lightweight wrapper around MPI_Recv for integer buffers. More...
 
void mpi_wrapper_recv_float (float *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Status *status, int offset)
 Lightweight wrapper around MPI_Recv for float buffers. More...
 
void mpi_wrapper_recv_double (double *buffer, int count, MPI_Datatype datatype, int source, int tag, MPI_Comm comm, MPI_Status *status, int offset)
 Lightweight wrapper around MPI_Recv for double buffers. More...
 
void mpi_wrapper_waitall (int count, MPI_Request *requests, MPI_Status *statuses)
 Lightweight wrapper around MPI_Waitall. More...
 

Detailed Description

Communication backend using MPI library

Function Documentation

◆ delete_mpi_exchanger()

void delete_mpi_exchanger ( t_mpi_exchange mpi_exchange)

Free memory of t_mpi_exchange object.

Parameters
[in,out]mpi_exchangepointer to t_mpi_exchange object

◆ mpi_wrapper_irecv_double()

void mpi_wrapper_irecv_double ( double *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Irecv for double buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_irecv_float()

void mpi_wrapper_irecv_float ( float *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Irecv for float buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_irecv_int()

void mpi_wrapper_irecv_int ( int *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Irecv for integer buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_isend_double()

void mpi_wrapper_isend_double ( double *  buffer,
int  count,
MPI_Datatype  datatype,
int  dest,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Isend for double buffers.

Parameters
[in]bufferbuffer to be sent
[in]countsize of the message
[in]datatypedata type of buffer
[in]destrank to send the message to
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_isend_float()

void mpi_wrapper_isend_float ( float *  buffer,
int  count,
MPI_Datatype  datatype,
int  dest,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Isend for float buffers.

Parameters
[in]bufferbuffer to be sent
[in]countsize of the message
[in]datatypedata type of buffer
[in]destrank to send the message to
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_isend_int()

void mpi_wrapper_isend_int ( int *  buffer,
int  count,
MPI_Datatype  datatype,
int  dest,
int  tag,
MPI_Comm  comm,
MPI_Request *  request,
int  offset 
)

Lightweight wrapper around MPI_Isend for integer buffers.

Parameters
[in]bufferbuffer to be sent
[in]countsize of the message
[in]datatypedata type of buffer
[in]destrank to send the message to
[in]tagmessage tag
[in]commMPI communicator
[out]requestMPI request for non blocking messages
[in]offsetbuffer offset

◆ mpi_wrapper_recv_double()

void mpi_wrapper_recv_double ( double *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Status *  status,
int  offset 
)

Lightweight wrapper around MPI_Recv for double buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]statusmessage status
[in]offsetbuffer offset

◆ mpi_wrapper_recv_float()

void mpi_wrapper_recv_float ( float *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Status *  status,
int  offset 
)

Lightweight wrapper around MPI_Recv for float buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]statusmessage status
[in]offsetbuffer offset

◆ mpi_wrapper_recv_int()

void mpi_wrapper_recv_int ( int *  buffer,
int  count,
MPI_Datatype  datatype,
int  source,
int  tag,
MPI_Comm  comm,
MPI_Status *  status,
int  offset 
)

Lightweight wrapper around MPI_Recv for integer buffers.

Parameters
[in]bufferbuffer to be received
[in]countsize of the message
[in]datatypedata type of buffer
[in]sourcerank to receive the message from
[in]tagmessage tag
[in]commMPI communicator
[out]statusmessage status
[in]offsetbuffer offset

◆ mpi_wrapper_waitall()

void mpi_wrapper_waitall ( int  count,
MPI_Request *  requests,
MPI_Status *  statuses 
)

Lightweight wrapper around MPI_Waitall.

Parameters
[in]countnumber of non blocking messages
[in]requestsarray of MPI request
[out]statusesarray of message statuses

◆ new_mpi_exchanger()

t_mpi_exchange* new_mpi_exchanger ( MPI_Datatype  type,
int  size 
)

Create t_mpi_exchange object.

Parameters
[in]typeMPI type
[in]sizesize of MPI requests and statuses
Returns
pointer to t_mpi_exchange object