ADS
Algorithms and Data Structures
Loading...
Searching...
No Matches
ADS::MPIExecutor Class Reference

the processes of a communicator, one worker each More...

#include <ADS/distributed/MPIExecutor.h>

Public member functions

 MPIExecutor (MPI_Comm comm=MPI_COMM_WORLD)
 the executor of the processes of comm
std::size_t rank (void) const
 the rank of the process
std::size_t size (void) const
 the number of the processes
MPI_Comm comm (void) const
 the communicator
template<class F>
void run (F &&f) const
 the call f( rank ), the worker of this process; every process calls it
void barrier (void) const
 returns when all the processes have called it

Detailed description

the processes of a communicator, one worker each

Constructor and destructor documentation

◆ MPIExecutor()

ADS::MPIExecutor::MPIExecutor ( MPI_Comm comm = MPI_COMM_WORLD)
inlineexplicit

the executor of the processes of comm

Precondition
MPI is initialized

Member function documentation

◆ barrier()

void ADS::MPIExecutor::barrier ( void ) const
inline

returns when all the processes have called it

◆ comm()

MPI_Comm ADS::MPIExecutor::comm ( void ) const
inlinenodiscard

the communicator

◆ rank()

std::size_t ADS::MPIExecutor::rank ( void ) const
inlinenodiscard

the rank of the process

◆ run()

template<class F>
void ADS::MPIExecutor::run ( F && f) const
inline

the call f( rank ), the worker of this process; every process calls it

◆ size()

std::size_t ADS::MPIExecutor::size ( void ) const
inlinenodiscard

the number of the processes


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