Every call goes through MPI_Allreduce so call sites remain correct at any
rank count. At -np 1 the operations are identities; bit-identity with
the pre-MPI serial code is preserved by construction.
We deliberately use separate send/recv buffers rather than =MPI_IN_PLACE=: MS-MPI's legacy =mpi= module mishandles =MPI_IN_PLACE= at =-np 1=, returning garbage instead of the input value. Two-buffer Allreduce is the textbook form and works on every MPI implementation we care about.
See mpi_runtime.F90 for the rationale behind the mpi_f08 / legacy
mpi cpp split.
Return the maximum of a scalar real(wp) across all ranks.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | local |
Return the sum of a scalar real(wp) across all ranks.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | local |
Return the logical OR of a scalar logical across all ranks.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| logical, | intent(in) | :: | local |