
Contains module procedures associated with the mpi controller class
Getter for worldRank
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for worldSize
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for rowRank
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for rowSize
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for columnRank
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for columnSize
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for xHaloWidth
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Getter for xHaloWidth
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(in) | :: | this |
Return true if input is true on every processor
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| logical, | intent(inout) | :: | input |
Return min value on all processors
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| real(kind=rk), | intent(inout) | :: | input |
Return max value on all processors
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| real(kind=rk), | intent(inout) | :: | input |
MPI controller initialization routine - initializes communicators used outside of PETSc. Optionally sets up row/column communicators.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| integer(kind=ik), | intent(in), | optional | :: | numProcsX |
Number of processes in the x-direction |
|
| integer(kind=ik), | intent(in), | optional | :: | numProcsH |
Number of processes in the h-direction |
Broadcast variable with given name from row rank 0 process to other row processes - to be used only with non-distribution variables
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| type(VariableContainer), | intent(inout) | :: | varContainer |
Variable container in which to broadcasty |
||
| character(len=*), | intent(in) | :: | name |
Name of variable to broadcast |
Initialize distribution DoF data used in exchanging distribution data in a row
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| type(Partition), | intent(in) | :: | partitionObj |
Partition object used to retrieve DoF information |
||
| integer(kind=ik), | intent(in) | :: | xHaloWidth |
Halo width in x-direction |
||
| integer(kind=ik), | intent(in) | :: | numV |
Number of cells in v-grid |
Exchanges a distribution variable in a processor row
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| type(VariableContainer), | intent(inout) | :: | varContainer |
Variable container in which to broadcast |
||
| character(len=*), | intent(in) | :: | name |
Name of variable to broadcast |
Initialize neighbour pairs - if periodic in X adds additional pair to handle this
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| logical, | intent(in) | :: | periodic |
Exchanges a halos in x direction for given variable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| type(VariableContainer), | intent(inout) | :: | varContainer |
Variable container in which to perform halo exchange |
||
| character(len=*), | intent(in) | :: | name |
Name of variable to exchange |
||
| logical, | intent(in) | :: | varIsDist |
Set to true if variable is a distribution |
Set up row/column communication in controller
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| integer(kind=ik), | intent(in) | :: | numProcsX |
Number of processes in the x-direction |
||
| integer(kind=ik), | intent(in) | :: | numProcsH |
Number of processes in the h-direction |
Gather variable values into global vector for output on rank 0. If globVec in not allocated it will be allocated to the correct size, otherwise it is assumed it is of the correct size.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| real(kind=rk), | intent(in), | dimension(:) | :: | localVec |
Local vector to gather |
|
| real(kind=rk), | intent(inout), | allocatable, dimension(:) | :: | globVec |
Global vector on rank 0 to gather into |
|
| logical, | intent(in) | :: | varIsDist |
Set to true if the gathered variable is a distribution |
Scatter global variable values into local vectors from rank 0.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| real(kind=rk), | intent(inout), | dimension(:) | :: | globVec |
Global vector on rank 0 to scatter from |
|
| real(kind=rk), | intent(inout), | allocatable, dimension(:) | :: | localVec |
Local vector to scatter into |
|
| logical, | intent(in) | :: | varIsDist |
Set to true if the scattered variable is a distribution |
Broadcast real vector from rank rootProc
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| real(kind=rk), | intent(inout), | dimension(:) | :: | vec | ||
| integer(kind=ik), | intent(in), | optional | :: | rootProc |
Broadcast integer vector from rank 0
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| integer(kind=ik), | intent(inout), | dimension(:) | :: | vec |
Broadcast logical vector from rank 0
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| logical, | intent(inout), | dimension(:) | :: | vec |
Broadcast character vector from rank 0
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this | |||
| character(len=:), | intent(inout), | allocatable | :: | vec |
Calls MPI barrier on commWorld
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(MPIController), | intent(inout) | :: | this |