47 mpi->
comm = (MPI_Comm*) calloc (ndims,
sizeof(MPI_Comm));
48 if (ndims == 1) MPI_Comm_dup(mpi->
world,mpi->
comm);
50 ip = (
int*) calloc (ndims-1,
sizeof(
int));
51 iproc = (
int*) calloc (ndims-1,
sizeof(
int));
52 for (n=0; n<ndims; n++) {
54 for (i=0; i<ndims; i++) {
56 ip[tick] = mpi->
ip[i];
57 iproc[tick] = mpi->
iproc[i];
63 MPI_Comm_split(mpi->
world,color,key,&mpi->
comm[n]);
83 for (n=0; n<ndims; n++) MPI_Comm_free(&mpi->
comm[n]);
86 MPI_Comm_free(&mpi->
world);
MPI related function definitions.
#define _ArrayIndex1D_(N, imax, i, ghost, index)
int MPICreateCommunicators(int ndims, void *m)
int MPIFreeCommunicators(int ndims, void *m)
Structure of MPI-related variables.
Contains macros and function definitions for common array operations.