core 1.5.0
Shared MPI block decomposition, asynchronous ghost-layer exchange, SDF geometry, load balancing (header-only C++20)
Loading...
Searching...
No Matches
mpi_stub.hpp File Reference
#include <cstdlib>
#include <cstring>
#include <map>

Go to the source code of this file.

Classes

struct  MPI_Status
 

Namespaces

namespace  peclet
 
namespace  peclet::core
 
namespace  peclet::core::mpi_stub
 

Macros

#define MPI_COMM_WORLD   0
 
#define MPI_COMM_NULL   (-1)
 
#define MPI_REQUEST_NULL   0
 
#define MPI_INFO_NULL   0
 
#define MPI_STATUS_IGNORE   (static_cast<MPI_Status*>(nullptr))
 
#define MPI_STATUSES_IGNORE   (static_cast<MPI_Status*>(nullptr))
 
#define MPI_ANY_SOURCE   (-1)
 
#define MPI_UNDEFINED   (-32766)
 
#define MPI_UNWEIGHTED   (static_cast<int*>(nullptr))
 
#define MPI_SUCCESS   0
 
#define MPI_BYTE   1
 
#define MPI_INT   4
 
#define MPI_LONG   8
 
#define MPI_DOUBLE   8
 
#define MPI_SUM   0
 
#define MPI_MAX   1
 
#define MPI_MIN   2
 
#define MPI_LAND   3
 
#define MPI_COMM_NULL_COPY_FN   (static_cast<MPI_Comm_copy_attr_function*>(nullptr))
 
#define MPI_COMM_NULL_DELETE_FN   (static_cast<MPI_Comm_delete_attr_function*>(nullptr))
 
#define MPI_KEYVAL_INVALID   (-1)
 

Typedefs

using MPI_Comm = int
 
using MPI_Request = int
 
using MPI_Datatype = int
 
using MPI_Op = int
 
using MPI_Info = int
 
using MPI_Comm_copy_attr_function = int(MPI_Comm, int, void *, void *, void *, int *)
 
using MPI_Comm_delete_attr_function = int(MPI_Comm, int, void *, void *)
 

Functions

int MPI_Init (int *, char ***)
 
int MPI_Initialized (int *f)
 
int MPI_Finalize ()
 
int MPI_Finalized (int *f)
 
int MPI_Abort (MPI_Comm, int code)
 
int MPI_Comm_rank (MPI_Comm, int *r)
 
int MPI_Comm_size (MPI_Comm, int *s)
 
std::map< std::pair< int, int >, void * > & peclet::core::mpi_stub::attrs ()
 
int & peclet::core::mpi_stub::nextKeyval ()
 
int MPI_Comm_create_keyval (MPI_Comm_copy_attr_function *, MPI_Comm_delete_attr_function *, int *keyval, void *)
 
int MPI_Comm_get_attr (MPI_Comm c, int keyval, void *val, int *flag)
 
int MPI_Comm_set_attr (MPI_Comm c, int keyval, void *val)
 
int MPI_Comm_free (MPI_Comm *)
 
int MPI_Barrier (MPI_Comm)
 
int MPI_Allreduce (const void *sbuf, void *rbuf, int count, MPI_Datatype dt, MPI_Op, MPI_Comm)
 
int MPI_Bcast (void *, int, MPI_Datatype, int, MPI_Comm)
 
int MPI_Send (const void *, int, MPI_Datatype, int, int, MPI_Comm)
 
int MPI_Recv (void *, int, MPI_Datatype, int, int, MPI_Comm, MPI_Status *)
 
int MPI_Isend (const void *, int, MPI_Datatype, int, int, MPI_Comm, MPI_Request *)
 
int MPI_Irecv (void *, int, MPI_Datatype, int, int, MPI_Comm, MPI_Request *)
 
int MPI_Issend (const void *, int, MPI_Datatype, int, int, MPI_Comm, MPI_Request *)
 
int MPI_Iprobe (int, int, MPI_Comm, int *flag, MPI_Status *)
 
int MPI_Get_count (const MPI_Status *, MPI_Datatype, int *c)
 
int MPI_Test (MPI_Request *, int *flag, MPI_Status *)
 
int MPI_Testall (int, MPI_Request *, int *flag, MPI_Status *)
 
int MPI_Wait (MPI_Request *, MPI_Status *)
 
int MPI_Waitall (int, MPI_Request *, MPI_Status *)
 
int MPI_Waitany (int, MPI_Request *, int *idx, MPI_Status *)
 
int MPI_Ibarrier (MPI_Comm, MPI_Request *)
 
int MPI_Dist_graph_create_adjacent (MPI_Comm c, int, const int *, const int *, int, const int *, const int *, MPI_Info, int, MPI_Comm *out)
 
int MPI_Neighbor_alltoallv (const void *, const int *, const int *, MPI_Datatype, void *, const int *, const int *, MPI_Datatype, MPI_Comm)
 

Macro Definition Documentation

◆ MPI_COMM_WORLD

#define MPI_COMM_WORLD   0

Definition at line 27 of file mpi_stub.hpp.

◆ MPI_COMM_NULL

#define MPI_COMM_NULL   (-1)

Definition at line 28 of file mpi_stub.hpp.

◆ MPI_REQUEST_NULL

#define MPI_REQUEST_NULL   0

Definition at line 29 of file mpi_stub.hpp.

◆ MPI_INFO_NULL

#define MPI_INFO_NULL   0

Definition at line 30 of file mpi_stub.hpp.

◆ MPI_STATUS_IGNORE

#define MPI_STATUS_IGNORE   (static_cast<MPI_Status*>(nullptr))

Definition at line 31 of file mpi_stub.hpp.

◆ MPI_STATUSES_IGNORE

#define MPI_STATUSES_IGNORE   (static_cast<MPI_Status*>(nullptr))

Definition at line 32 of file mpi_stub.hpp.

◆ MPI_ANY_SOURCE

#define MPI_ANY_SOURCE   (-1)

Definition at line 33 of file mpi_stub.hpp.

◆ MPI_UNDEFINED

#define MPI_UNDEFINED   (-32766)

Definition at line 34 of file mpi_stub.hpp.

◆ MPI_UNWEIGHTED

#define MPI_UNWEIGHTED   (static_cast<int*>(nullptr))

Definition at line 35 of file mpi_stub.hpp.

◆ MPI_SUCCESS

#define MPI_SUCCESS   0

Definition at line 36 of file mpi_stub.hpp.

◆ MPI_BYTE

#define MPI_BYTE   1

Definition at line 38 of file mpi_stub.hpp.

◆ MPI_INT

#define MPI_INT   4

Definition at line 39 of file mpi_stub.hpp.

◆ MPI_LONG

#define MPI_LONG   8

Definition at line 40 of file mpi_stub.hpp.

◆ MPI_DOUBLE

#define MPI_DOUBLE   8

Definition at line 41 of file mpi_stub.hpp.

◆ MPI_SUM

#define MPI_SUM   0

Definition at line 43 of file mpi_stub.hpp.

◆ MPI_MAX

#define MPI_MAX   1

Definition at line 44 of file mpi_stub.hpp.

◆ MPI_MIN

#define MPI_MIN   2

Definition at line 45 of file mpi_stub.hpp.

◆ MPI_LAND

#define MPI_LAND   3

Definition at line 46 of file mpi_stub.hpp.

◆ MPI_COMM_NULL_COPY_FN

#define MPI_COMM_NULL_COPY_FN   (static_cast<MPI_Comm_copy_attr_function*>(nullptr))

Definition at line 77 of file mpi_stub.hpp.

◆ MPI_COMM_NULL_DELETE_FN

#define MPI_COMM_NULL_DELETE_FN   (static_cast<MPI_Comm_delete_attr_function*>(nullptr))

Definition at line 78 of file mpi_stub.hpp.

◆ MPI_KEYVAL_INVALID

#define MPI_KEYVAL_INVALID   (-1)

Definition at line 79 of file mpi_stub.hpp.

Typedef Documentation

◆ MPI_Comm

using MPI_Comm = int

Definition at line 17 of file mpi_stub.hpp.

◆ MPI_Request

using MPI_Request = int

Definition at line 18 of file mpi_stub.hpp.

◆ MPI_Datatype

using MPI_Datatype = int

Definition at line 19 of file mpi_stub.hpp.

◆ MPI_Op

using MPI_Op = int

Definition at line 20 of file mpi_stub.hpp.

◆ MPI_Info

using MPI_Info = int

Definition at line 21 of file mpi_stub.hpp.

◆ MPI_Comm_copy_attr_function

using MPI_Comm_copy_attr_function = int(MPI_Comm, int, void*, void*, void*, int*)

Definition at line 75 of file mpi_stub.hpp.

◆ MPI_Comm_delete_attr_function

using MPI_Comm_delete_attr_function = int(MPI_Comm, int, void*, void*)

Definition at line 76 of file mpi_stub.hpp.

Function Documentation

◆ MPI_Init()

int MPI_Init ( int *  ,
char ***   
)
inline

Definition at line 48 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Initialized()

int MPI_Initialized ( int *  f)
inline

Definition at line 51 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::detail::probeGpuAwareMpi().

◆ MPI_Finalize()

int MPI_Finalize ( )
inline

Definition at line 55 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Finalized()

int MPI_Finalized ( int *  f)
inline

Definition at line 58 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::GridHaloTopology< Dim >::operator=().

◆ MPI_Abort()

int MPI_Abort ( MPI_Comm  ,
int  code 
)
inline

Definition at line 62 of file mpi_stub.hpp.

◆ MPI_Comm_rank()

◆ MPI_Comm_size()

◆ MPI_Comm_create_keyval()

int MPI_Comm_create_keyval ( MPI_Comm_copy_attr_function *  ,
MPI_Comm_delete_attr_function *  ,
int *  keyval,
void *   
)
inline

◆ MPI_Comm_get_attr()

int MPI_Comm_get_attr ( MPI_Comm  c,
int  keyval,
void *  val,
int *  flag 
)
inline

Definition at line 95 of file mpi_stub.hpp.

References peclet::core::mpi_stub::attrs().

Referenced by peclet::core::halo::detail::nbxRoundTag().

◆ MPI_Comm_set_attr()

int MPI_Comm_set_attr ( MPI_Comm  c,
int  keyval,
void *  val 
)
inline

Definition at line 103 of file mpi_stub.hpp.

References peclet::core::mpi_stub::attrs().

Referenced by peclet::core::halo::detail::nbxRoundTag().

◆ MPI_Comm_free()

int MPI_Comm_free ( MPI_Comm *  )
inline

◆ MPI_Barrier()

int MPI_Barrier ( MPI_Comm  )
inline

Definition at line 110 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Allreduce()

int MPI_Allreduce ( const void *  sbuf,
void *  rbuf,
int  count,
MPI_Datatype  dt,
MPI_Op  ,
MPI_Comm   
)
inline

◆ MPI_Bcast()

int MPI_Bcast ( void *  ,
int  ,
MPI_Datatype  ,
int  ,
MPI_Comm   
)
inline

Definition at line 120 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::solver::andersonComm().

◆ MPI_Send()

int MPI_Send ( const void *  ,
int  ,
MPI_Datatype  ,
int  ,
int  ,
MPI_Comm   
)
inline

Definition at line 126 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Recv()

int MPI_Recv ( void *  ,
int  ,
MPI_Datatype  ,
int  ,
int  ,
MPI_Comm  ,
MPI_Status *   
)
inline

Definition at line 129 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Isend()

◆ MPI_Irecv()

◆ MPI_Issend()

int MPI_Issend ( const void *  ,
int  ,
MPI_Datatype  ,
int  ,
int  ,
MPI_Comm  ,
MPI_Request *   
)
inline

Definition at line 138 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Iprobe()

int MPI_Iprobe ( int  ,
int  ,
MPI_Comm  ,
int *  flag,
MPI_Status *   
)
inline

Definition at line 141 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Get_count()

int MPI_Get_count ( const MPI_Status *  ,
MPI_Datatype  ,
int *  c 
)
inline

Definition at line 145 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Test()

int MPI_Test ( MPI_Request *  ,
int *  flag,
MPI_Status *   
)
inline

Definition at line 149 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Testall()

int MPI_Testall ( int  ,
MPI_Request *  ,
int *  flag,
MPI_Status *   
)
inline

Definition at line 153 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Wait()

int MPI_Wait ( MPI_Request *  ,
MPI_Status *   
)
inline

Definition at line 157 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Waitall()

◆ MPI_Waitany()

int MPI_Waitany ( int  ,
MPI_Request *  ,
int *  idx,
MPI_Status *   
)
inline

◆ MPI_Ibarrier()

int MPI_Ibarrier ( MPI_Comm  ,
MPI_Request *   
)
inline

Definition at line 167 of file mpi_stub.hpp.

References MPI_SUCCESS.

Referenced by peclet::core::halo::NbxEngine::exchange().

◆ MPI_Dist_graph_create_adjacent()

int MPI_Dist_graph_create_adjacent ( MPI_Comm  c,
int  ,
const int *  ,
const int *  ,
int  ,
const int *  ,
const int *  ,
MPI_Info  ,
int  ,
MPI_Comm *  out 
)
inline

Definition at line 170 of file mpi_stub.hpp.

References MPI_SUCCESS.

◆ MPI_Neighbor_alltoallv()

int MPI_Neighbor_alltoallv ( const void *  ,
const int *  ,
const int *  ,
MPI_Datatype  ,
void *  ,
const int *  ,
const int *  ,
MPI_Datatype  ,
MPI_Comm   
)
inline