Chi-Tech
chi::MPI_Info Class Reference

#include <mpi_info.h>

Public Member Functions

 MPI_Info (const MPI_Info &)=delete
 
MPI_Info operator= (const MPI_Info &)=delete
 
void Barrier () const
 

Static Public Member Functions

static MPI_InfoGetInstance () noexcept
 
static void Call (int mpi_error_code)
 

Data Fields

const int & location_id = location_id_
 Current process rank. More...
 
const int & process_count = process_count_
 Total number of processes. More...
 
const MPI_Comm & comm = communicator_
 MPI communicator. More...
 

Protected Member Functions

void SetCommunicator (MPI_Comm new_communicator)
 
void SetLocationID (int in_location_id)
 
void SetProcessCount (int in_process_count)
 

Private Member Functions

 MPI_Info ()=default
 

Private Attributes

MPI_Comm communicator_ = MPI_COMM_WORLD
 
int location_id_ = 0
 
int process_count_ = 1
 
bool location_id_set_ = false
 
bool process_count_set_ = false
 

Friends

class ::Chi
 

Detailed Description

An object for storing various MPI states.

Definition at line 14 of file mpi_info.h.

Constructor & Destructor Documentation

◆ MPI_Info() [1/2]

chi::MPI_Info::MPI_Info ( )
privatedefault

◆ MPI_Info() [2/2]

chi::MPI_Info::MPI_Info ( const MPI_Info )
delete

Member Function Documentation

◆ Barrier()

void chi::MPI_Info::Barrier ( ) const

Calls the generic MPI_Barrier with the current communicator.

Definition at line 38 of file mpi_info.cc.

◆ Call()

void chi::MPI_Info::Call ( int  mpi_error_code)
static

Definition at line 43 of file mpi_info.cc.

◆ GetInstance()

MPI_Info & chi::MPI_Info::GetInstance ( )
staticnoexcept

Access to the singleton

Definition at line 10 of file mpi_info.cc.

◆ operator=()

MPI_Info chi::MPI_Info::operator= ( const MPI_Info )
delete

◆ SetCommunicator()

void chi::MPI_Info::SetCommunicator ( MPI_Comm  new_communicator)
protected

Sets the active communicator

Definition at line 17 of file mpi_info.cc.

◆ SetLocationID()

void chi::MPI_Info::SetLocationID ( int  in_location_id)
protected

Sets the rank.

Definition at line 23 of file mpi_info.cc.

◆ SetProcessCount()

void chi::MPI_Info::SetProcessCount ( int  in_process_count)
protected

Sets the number of processes in the communicator.

Definition at line 31 of file mpi_info.cc.

Friends And Related Function Documentation

◆ ::Chi

friend class ::Chi
friend

Definition at line 16 of file mpi_info.h.

Field Documentation

◆ comm

const MPI_Comm& chi::MPI_Info::comm = communicator_

MPI communicator.

Definition at line 28 of file mpi_info.h.

◆ communicator_

MPI_Comm chi::MPI_Info::communicator_ = MPI_COMM_WORLD
private

Definition at line 18 of file mpi_info.h.

◆ location_id

const int& chi::MPI_Info::location_id = location_id_

Current process rank.

Definition at line 26 of file mpi_info.h.

◆ location_id_

int chi::MPI_Info::location_id_ = 0
private

Definition at line 19 of file mpi_info.h.

◆ location_id_set_

bool chi::MPI_Info::location_id_set_ = false
private

Definition at line 22 of file mpi_info.h.

◆ process_count

const int& chi::MPI_Info::process_count = process_count_

Total number of processes.

Definition at line 27 of file mpi_info.h.

◆ process_count_

int chi::MPI_Info::process_count_ = 1
private

Definition at line 20 of file mpi_info.h.

◆ process_count_set_

bool chi::MPI_Info::process_count_set_ = false
private

Definition at line 23 of file mpi_info.h.


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