|
template<typename index> |
ioboxes< index > | heffte::mpi::gather_boxes (box3d< index > const my_inbox, box3d< index > const my_outbox, MPI_Comm const comm) |
| Gather all boxes across all ranks in the comm.
|
|
int | heffte::mpi::comm_rank (MPI_Comm const comm) |
| Returns the rank of this process within the specified comm.
|
|
bool | heffte::mpi::world_rank (int rank) |
| Returns true if this process has the me rank within the MPI_COMM_WORLD (useful for debugging).
|
|
int | heffte::mpi::world_rank () |
| Returns the rank of this process within the MPI_COMM_WORLD (useful for debugging).
|
|
template<typename vector_like> |
void | heffte::mpi::dump (int me, vector_like const &x, std::string const &message) |
| Write the message and the data from the vector-like x, performed only on rank me (if positive), otherwise using all ranks.
|
|
int | heffte::mpi::comm_size (MPI_Comm const comm) |
| Returns the size of the specified communicator.
|
|
MPI_Comm | heffte::mpi::new_comm_from_group (std::vector< int > const &ranks, MPI_Comm const comm) |
| Creates a new sub-communicator from the provided processes in comm.
|
|
void | heffte::mpi::comm_free (MPI_Comm const comm) |
| Calls free on the MPI comm.
|
|
template<typename scalar> |
MPI_Datatype | heffte::mpi::type_from () |
| Returns the MPI equivalent of the scalar C++ type.
|
|
template<> |
MPI_Datatype | heffte::mpi::type_from< int > () |
| Specialization to hand the int type.
|
|
template<> |
MPI_Datatype | heffte::mpi::type_from< float > () |
| Specialization to hand the float type.
|
|
template<> |
MPI_Datatype | heffte::mpi::type_from< double > () |
| Specialization to hand the double type.
|
|
template<> |
MPI_Datatype | heffte::mpi::type_from< std::complex< float > > () |
| Specialization to hand the single-precision complex type.
|
|
template<> |
MPI_Datatype | heffte::mpi::type_from< std::complex< double > > () |
| Specialization to hand the double-precision complex type.
|
|
HeFFTe is using the C-style of API for the message passing interface (MPI). A set of inline wrappers allow for easier inclusion into C++ methods which helps preserve const-correctness and simplifies variable initialization.
template<typename vector_like>
void heffte::mpi::dump |
( |
int | me, |
|
|
vector_like const & | x, |
|
|
std::string const & | message ) |
Write the message and the data from the vector-like x, performed only on rank me (if positive), otherwise using all ranks.
Very useful for debugging purposes, when a vector or vector-like object has to be inspected for a single MPI rank.
- Template Parameters
-
vector_like | is an object that can be used for ranged for-loop, e.g., std::vector or std::array |
- Parameters
-
me | the rank to write to cout |
x | is the data to be written out |
message | will be written on the line before x, helps identify what x should contain, e.g., result or reference data |