This class represents a BLACS process grid for use with ScaLAPACK.
More...
#include <BlacsProcessGrid.hpp>
This class represents a BLACS process grid for use with ScaLAPACK.
◆ BlacsProcessGrid() [1/2]
sgpp::datadriven::BlacsProcessGrid::BlacsProcessGrid |
( |
int |
rows = -1 , |
|
|
int |
columns = -1 |
|
) |
| |
|
explicit |
Creates a BLACS process grid with a certain number of rows and columns.
There must be at least rows * columns processes available. If rows or columns is set to < 1, a square grid of maximum size is created from the available processes. Always call this method from all processes, as the init method of a BLACS grid has to be called from all processes, otherwise a deadlock will occur.
- Parameters
-
rows | number of rows of the process grid, default -1 (square grid) |
columns | number of columns of the process grid, default -1 (square grid) |
References availableProcesses().
◆ BlacsProcessGrid() [2/2]
sgpp::datadriven::BlacsProcessGrid::BlacsProcessGrid |
( |
const BlacsProcessGrid & |
| ) |
|
|
delete |
Cannot be copied, otherwise errors with multiple calls to blacs_gridexit are possible.
◆ ~BlacsProcessGrid()
sgpp::datadriven::BlacsProcessGrid::~BlacsProcessGrid |
( |
| ) |
|
◆ availableProcesses()
int sgpp::datadriven::BlacsProcessGrid::availableProcesses |
( |
| ) |
|
|
static |
Can only be called after BLACS initialization.
- Returns
- the number of available mpi processes
Referenced by BlacsProcessGrid().
◆ exitBlacs()
void sgpp::datadriven::BlacsProcessGrid::exitBlacs |
( |
| ) |
|
|
static |
Exit BLACS, should only be called once.
Referenced by main().
◆ getContextHandle()
int sgpp::datadriven::BlacsProcessGrid::getContextHandle |
( |
| ) |
const |
- Returns
- the context handle of the BLACS context
◆ getCurrentColumn()
int sgpp::datadriven::BlacsProcessGrid::getCurrentColumn |
( |
| ) |
const |
- Returns
- Column of the current process
◆ getCurrentProcess()
int sgpp::datadriven::BlacsProcessGrid::getCurrentProcess |
( |
| ) |
|
|
static |
◆ getCurrentRow()
int sgpp::datadriven::BlacsProcessGrid::getCurrentRow |
( |
| ) |
const |
- Returns
- Row of the current process
◆ getProcessesInGrid()
int sgpp::datadriven::BlacsProcessGrid::getProcessesInGrid |
( |
| ) |
const |
- Returns
- the number of processes in the current grid.
◆ getRowColumnIndex()
int sgpp::datadriven::BlacsProcessGrid::getRowColumnIndex |
( |
| ) |
const |
- Returns
- index of the process in the current grid.
◆ getTotalColumns()
int sgpp::datadriven::BlacsProcessGrid::getTotalColumns |
( |
| ) |
const |
- Returns
- Total number of columns of the grid
◆ getTotalRows()
int sgpp::datadriven::BlacsProcessGrid::getTotalRows |
( |
| ) |
const |
- Returns
- Total number of rows of the grid
◆ initializeBlacs()
void sgpp::datadriven::BlacsProcessGrid::initializeBlacs |
( |
| ) |
|
|
static |
Initialize BLACS, should only be called once.
Referenced by main().
◆ isProcessInGrid()
bool sgpp::datadriven::BlacsProcessGrid::isProcessInGrid |
( |
| ) |
const |
- Returns
- True if the current process is part of this grid, else false
◆ operator=()
The documentation for this class was generated from the following files: