|
TiledArray
0.7.0
|
A 2D processor grid. More...
#include <proc_grid.h>
Public Types | |
| typedef uint_fast32_t | size_type |
Public Member Functions | |
| ProcGrid () | |
| Default constructor. More... | |
| ProcGrid (World &world, const size_type rows, const size_type cols, const std::size_t row_size, const std::size_t col_size) | |
| Construct a process grid. More... | |
| ProcGrid (const ProcGrid &other) | |
| Copy constructor. More... | |
| ProcGrid & | operator= (const ProcGrid &other) |
| Copy assignment operator. More... | |
| size_type | rows () const |
| Element row count accessor. More... | |
| size_type | cols () const |
| Element column count accessor. More... | |
| size_type | size () const |
| Element count accessor. More... | |
| size_type | local_rows () const |
| Local element row count accessor. More... | |
| size_type | local_cols () const |
| Local element column count accessor. More... | |
| size_type | local_size () const |
| Local element count accessor. More... | |
| ProcessID | rank_row () const |
| Rank row accessor. More... | |
| ProcessID | rank_col () const |
| Rank row accessor. More... | |
| size_type | proc_rows () const |
| Process row count accessor. More... | |
| size_type | proc_cols () const |
| Process column count accessor. More... | |
| size_type | proc_size () const |
| Process grid size accessor. More... | |
| madness::Group | make_row_group (const madness::DistributedID &did) const |
| Construct a row group. More... | |
| madness::Group | make_col_group (const madness::DistributedID &did) const |
| Construct a column group. More... | |
| ProcessID | map_row (const size_type row) const |
| Map a row to the process in this process's column. More... | |
| ProcessID | map_col (const size_type col) const |
| Map a column to the process in this process's row. More... | |
| std::shared_ptr< Pmap > | make_pmap () const |
| Construct a cyclic process. More... | |
| std::shared_ptr< Pmap > | make_col_phase_pmap (const size_type rows) const |
| Construct column phased a cyclic process. More... | |
| std::shared_ptr< Pmap > | make_row_phase_pmap (const size_type cols) const |
| Construct row phased a cyclic process. More... | |
A 2D processor grid.
ProcGrid attempts to create a near optimal 2D grid of P processes for an MxN grid of tiles. The size of the grid is optimized such that the total communication time required for SUMMA and the number of unused processes is minimized. The total communication time of SUMMA is given by:
where
is the number of process rows;
,
, and
are the number of tile rows and columns in a matrix product with average tiles sizes of
,
, and
, respectively;
is the number or available processes;
is the message latency; and
is the message data rate. If we evaluate
and assume that
, the expression simplifies to:
where the positive, real root of
give the optimal optimal communication time.
Definition at line 59 of file proc_grid.h.
| typedef uint_fast32_t TiledArray::detail::ProcGrid::size_type |
Definition at line 61 of file proc_grid.h.
|
inline |
|
inline |
Construct a process grid.
| world | The world where the process grid will live |
| rows | The number of tile rows |
| cols | The number of tile columns |
| row_size | The number of element rows |
| col_size | The number of element columns |
Definition at line 269 of file proc_grid.h.
|
inline |
Copy constructor.
| other | The other process grid to be copied |
Definition at line 327 of file proc_grid.h.
|
inline |
Element column count accessor.
Definition at line 364 of file proc_grid.h.

|
inline |
Local element column count accessor.
Definition at line 379 of file proc_grid.h.
|
inline |
Local element row count accessor.
Definition at line 374 of file proc_grid.h.
|
inline |
Local element count accessor.
Definition at line 384 of file proc_grid.h.
|
inline |
Construct a column group.
| did | The distributed id for the result group |
Group object that includes all processes in rank_col Definition at line 444 of file proc_grid.h.
|
inline |
Construct column phased a cyclic process.
Construct a cyclic process map where the column phase of the process matches that of this process grid.
| rows | The number of rows in the process map |
Definition at line 500 of file proc_grid.h.


|
inline |
Construct a cyclic process.
Construct a cyclic process map with the same phase as the process grid.
Definition at line 488 of file proc_grid.h.

|
inline |
Construct a row group.
| did | The distributed id for the result group |
Group object that includes all processes in rank_row Definition at line 417 of file proc_grid.h.
|
inline |
Construct row phased a cyclic process.
Construct a cyclic process map where the column phase of the process matches that of this process grid.
| cols | The number of columns in the process map |
Definition at line 512 of file proc_grid.h.


|
inline |
Map a column to the process in this process's row.
| col | The column to be mapped |
(rank_row,col) Definition at line 479 of file proc_grid.h.
|
inline |
Map a row to the process in this process's column.
| row | The row to be mapped |
(row,rank_col) Definition at line 470 of file proc_grid.h.
Copy assignment operator.
| other | The other process grid to be copied |
Definition at line 339 of file proc_grid.h.
|
inline |
Process column count accessor.
Definition at line 404 of file proc_grid.h.

|
inline |
Process row count accessor.
Definition at line 399 of file proc_grid.h.

|
inline |
Process grid size accessor.
Definition at line 410 of file proc_grid.h.
|
inline |
Rank row accessor.
Definition at line 394 of file proc_grid.h.
|
inline |
Rank row accessor.
Definition at line 389 of file proc_grid.h.
|
inline |
Element row count accessor.
Definition at line 359 of file proc_grid.h.

|
inline |
Element count accessor.
Definition at line 369 of file proc_grid.h.