Cloudy
Spectral Synthesis Code for Astrophysics
Loading...
Searching...
No Matches
load_balance Class Reference

#include <mpi_utilities.h>

Public Member Functions

 load_balance ()
 
 load_balance (unsigned int nJobs, unsigned int nCPU)
 
 ~load_balance ()
 
void clear ()
 
void init (unsigned int nJobs, unsigned int nCPU)
 
int next_job ()
 
void finalize (exit_type exit_status)
 

Private Member Functions

void p_clear0 ()
 
void p_clear1 ()
 

Private Attributes

vector< int > p_jobs
 
unsigned int p_ptr
 
unsigned int p_rank
 
unsigned int p_ncpu
 

Constructor & Destructor Documentation

◆ load_balance() [1/2]

load_balance::load_balance ( )
inline

References p_clear1().

Here is the call graph for this function:

◆ load_balance() [2/2]

load_balance::load_balance ( unsigned int nJobs,
unsigned int nCPU )
inline

References init(), and p_clear1().

Here is the call graph for this function:

◆ ~load_balance()

load_balance::~load_balance ( )
inline

References p_clear0().

Here is the call graph for this function:

Member Function Documentation

◆ clear()

void load_balance::clear ( )
inline

References p_clear0(), and p_clear1().

Here is the call graph for this function:

◆ finalize()

void load_balance::finalize ( exit_type exit_status)

References cpu, MPI_Barrier, NULL, p_ncpu, p_rank, and wait.

Referenced by main().

◆ init()

void load_balance::init ( unsigned int nJobs,
unsigned int nCPU )

References cpu, EXIT_FAILURE, fork, fprintf(), ioQQQ, min(), MPI_Bcast, NULL, p_jobs, p_ncpu, p_ptr, p_rank, pid_t, and ran.

Referenced by load_balance().

Here is the call graph for this function:

◆ next_job()

int load_balance::next_job ( )
inline

References p_jobs, p_ncpu, and p_ptr.

Referenced by main().

◆ p_clear0()

void load_balance::p_clear0 ( )
inlineprivate

References p_jobs.

Referenced by clear(), and ~load_balance().

◆ p_clear1()

void load_balance::p_clear1 ( )
inlineprivate

References p_ncpu, p_ptr, and p_rank.

Referenced by clear(), load_balance(), and load_balance().

Member Data Documentation

◆ p_jobs

vector<int> load_balance::p_jobs
private

Referenced by init(), next_job(), and p_clear0().

◆ p_ncpu

unsigned int load_balance::p_ncpu
private

Referenced by finalize(), init(), next_job(), and p_clear1().

◆ p_ptr

unsigned int load_balance::p_ptr
private

Referenced by init(), next_job(), and p_clear1().

◆ p_rank

unsigned int load_balance::p_rank
private

Referenced by finalize(), init(), and p_clear1().


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