PhyStar  v0.0.0 thu24
gsmpi::GSMPI Class Reference

the base of keli mpi More...

#include <gsmpibase.hpp>

Inheritance diagram for gsmpi::GSMPI:
Collaboration diagram for gsmpi::GSMPI:

Public Member Functions

 GSMPI ()
 Construct a new KLMPI object. More...
 
void Init ()
 Initialize keli mpi. More...
 
int GetRank ()
 Get the Rank. More...
 
int GetRank () const
 
int GetNumofProc ()
 Get the Number of Procs. More...
 
int GetNumofProc () const
 
int GetNumofNbrs ()
 Get the Number of Neigbhors. More...
 
int GetNumofNbrs () const
 
const int * PtrNbrsList ()
 
const int * PtrNbrsList () const
 
int GetNumofNbrsExcludeNullAndSelfProc ()
 Get the Number of Neigbhors Without Nullproc And Self. More...
 
int GetNumofNbrsExcludeNullAndSelfProc () const
 
MPI_Comm GetComm () const
 Get the Communicator. More...
 
MPI_Comm GetComm ()
 
void SendRecv (auto &send, auto &recv, MPI_Datatype datatype)
 Send and Receive data by a graph communication. More...
 
void AllGather (auto &send, auto &recv, MPI_Datatype datatype)
 
void SendRecv_v1 (SerializedBuffer &send, SerializedBuffer &recv, MPI_Datatype datatype)
 
void Barrier ()
 MPI_Barrier() More...
 
void Bcast (auto &in, MPI_Datatype datatype)
 
void Bcast (auto &in, int count, MPI_Datatype datatype)
 
void Bcast (auto *in, int count, MPI_Datatype datatype)
 
void Reduce (auto &send, auto &recv, MPI_Datatype datatype, MPI_Op op)
 
void Reduce (auto &send, auto &recv, int count, MPI_Datatype datatype, MPI_Op op)
 
void Reduce (auto *send, auto *recv, int count, MPI_Datatype datatype, MPI_Op op)
 
void AllReduce (auto &send, auto &recv, MPI_Datatype datatype, MPI_Op op)
 
void AllReduce (auto &send, auto &recv, int count, MPI_Datatype datatype, MPI_Op op)
 
void AllReduce (auto *send, auto *recv, int count, MPI_Datatype datatype, MPI_Op op)
 

Protected Attributes

MPI_Comm _comm
 
int _nprocall
 
int _rank
 
int * _nbrs = nullptr
 
int _num_nbrs
 
int _num_nbrs_exclude_null_selfproc
 
int * _graph_index = nullptr
 
int * _graph_edge = nullptr
 
std::vector< int > _valid_nbrs_order
 

Detailed Description

the base of keli mpi

Constructor & Destructor Documentation

◆ GSMPI()

gsmpi::GSMPI::GSMPI ( )
inline

Construct a new KLMPI object.

Member Function Documentation

◆ AllGather()

void gsmpi::GSMPI::AllGather ( auto &  send,
auto &  recv,
MPI_Datatype  datatype 
)
inline

◆ AllReduce() [1/3]

void gsmpi::GSMPI::AllReduce ( auto &  send,
auto &  recv,
int  count,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm.

◆ AllReduce() [2/3]

void gsmpi::GSMPI::AllReduce ( auto &  send,
auto &  recv,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm.

◆ AllReduce() [3/3]

void gsmpi::GSMPI::AllReduce ( auto *  send,
auto *  recv,
int  count,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm.

◆ Barrier()

void gsmpi::GSMPI::Barrier ( )
inline

MPI_Barrier()

References _comm.

◆ Bcast() [1/3]

void gsmpi::GSMPI::Bcast ( auto &  in,
int  count,
MPI_Datatype  datatype 
)
inline

References _comm, and gsmpi::root.

◆ Bcast() [2/3]

void gsmpi::GSMPI::Bcast ( auto &  in,
MPI_Datatype  datatype 
)
inline

References _comm, and gsmpi::root.

◆ Bcast() [3/3]

void gsmpi::GSMPI::Bcast ( auto *  in,
int  count,
MPI_Datatype  datatype 
)
inline

References _comm, and gsmpi::root.

◆ GetComm() [1/2]

MPI_Comm gsmpi::GSMPI::GetComm ( )
inline

References _comm.

◆ GetComm() [2/2]

MPI_Comm gsmpi::GSMPI::GetComm ( ) const
inline

Get the Communicator.

Returns
MPI_Comm

References _comm.

Here is the caller graph for this function:

◆ GetNumofNbrs() [1/2]

int gsmpi::GSMPI::GetNumofNbrs ( )
inline

Get the Number of Neigbhors.

Returns
int

References _num_nbrs.

Here is the caller graph for this function:

◆ GetNumofNbrs() [2/2]

int gsmpi::GSMPI::GetNumofNbrs ( ) const
inline

References _num_nbrs.

◆ GetNumofNbrsExcludeNullAndSelfProc() [1/2]

int gsmpi::GSMPI::GetNumofNbrsExcludeNullAndSelfProc ( )
inline

Get the Number of Neigbhors Without Nullproc And Self.

Returns
int

References _num_nbrs_exclude_null_selfproc.

◆ GetNumofNbrsExcludeNullAndSelfProc() [2/2]

int gsmpi::GSMPI::GetNumofNbrsExcludeNullAndSelfProc ( ) const
inline

◆ GetNumofProc() [1/2]

int gsmpi::GSMPI::GetNumofProc ( )
inline

Get the Number of Procs.

Returns
int

References _nprocall.

◆ GetNumofProc() [2/2]

int gsmpi::GSMPI::GetNumofProc ( ) const
inline

References _nprocall.

◆ GetRank() [1/2]

int gsmpi::GSMPI::GetRank ( )
inline

Get the Rank.

Returns
int

References _rank.

◆ GetRank() [2/2]

int gsmpi::GSMPI::GetRank ( ) const
inline

References _rank.

◆ Init()

void gsmpi::GSMPI::Init ( )
inline

Initialize keli mpi.

References _comm, _nprocall, and _rank.

◆ PtrNbrsList() [1/2]

const int* gsmpi::GSMPI::PtrNbrsList ( )
inline

References _nbrs.

Here is the caller graph for this function:

◆ PtrNbrsList() [2/2]

const int* gsmpi::GSMPI::PtrNbrsList ( ) const
inline

References _nbrs.

◆ Reduce() [1/3]

void gsmpi::GSMPI::Reduce ( auto &  send,
auto &  recv,
int  count,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm, and gsmpi::root.

◆ Reduce() [2/3]

void gsmpi::GSMPI::Reduce ( auto &  send,
auto &  recv,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm, and gsmpi::root.

◆ Reduce() [3/3]

void gsmpi::GSMPI::Reduce ( auto *  send,
auto *  recv,
int  count,
MPI_Datatype  datatype,
MPI_Op  op 
)
inline

References _comm, and gsmpi::root.

◆ SendRecv()

void gsmpi::GSMPI::SendRecv< SerializedBuffer > ( auto &  send,
auto &  recv,
MPI_Datatype  datatype 
)
inline

Send and Receive data by a graph communication.

Parameters
sendsender
recvreceiver
datatypeMPI_Datatype

References _comm.

◆ SendRecv_v1()

void gsmpi::GSMPI::SendRecv_v1 ( SerializedBuffer send,
SerializedBuffer recv,
MPI_Datatype  datatype 
)
inline

Member Data Documentation

◆ _comm

MPI_Comm gsmpi::GSMPI::_comm
protected

◆ _graph_edge

int* gsmpi::GSMPI::_graph_edge = nullptr
protected

◆ _graph_index

int* gsmpi::GSMPI::_graph_index = nullptr
protected

◆ _nbrs

int* gsmpi::GSMPI::_nbrs = nullptr
protected

◆ _nprocall

int gsmpi::GSMPI::_nprocall
protected

◆ _num_nbrs

int gsmpi::GSMPI::_num_nbrs
protected

◆ _num_nbrs_exclude_null_selfproc

int gsmpi::GSMPI::_num_nbrs_exclude_null_selfproc
protected

◆ _rank

int gsmpi::GSMPI::_rank
protected

◆ _valid_nbrs_order

std::vector<int> gsmpi::GSMPI::_valid_nbrs_order
protected

The documentation for this class was generated from the following file: