#include <Group.h>
Public Types | |
typedef std::vector< Process * > | process_group |
Container type for process groups. | |
Public Member Functions | |
Constructors & destructor | |
Group (ident_t id, const process_group &processes) | |
Get group information | |
uint32_t | num_processes () const |
Process * | get_process (uint32_t rank) const |
uint32_t | get_rank (Process *process) const |
The numerical identifiers of the individual groups are globally defined and continuously enumerated, i.e., the ID is element of [0,#process_groups-1].
Group | ( | ident_t | id, | |
const process_group & | processes | |||
) |
Creates a new instance and initializes the data with the given values id and processes, respectively. The given processes have to be sorted by their numerical identifiers (i.e., their rank numbers) in ascending order!
id | Group identifier | |
processes | List of processes defining the group |
Process * get_process | ( | uint32_t | rank | ) | const |
Returns the Process with the given rank with respect to this group.
rank | Rank number of the requested process |
RuntimeError | if an invalid rank is given ("Rank out of range") |
uint32_t get_rank | ( | Process * | process | ) | const |
Returns the rank number of the given process with respect to this group.
process | Process object |
RuntimeError | if the process is not part of this group ("Unknown process") |
uint32_t num_processes | ( | ) | const |
Returns the number of processes belonging to this group.
![]() |
Copyright © 1998–2009 Forschungszentrum Jülich, Jülich Supercomputing Centre |