From ca48b3962b1a54bbd9b59bae3d52313af3361063 Mon Sep 17 00:00:00 2001 From: Prabhanjan Kambadur Date: Wed, 21 Apr 2004 20:55:54 +0000 Subject: [PATCH] Changing some prototypes and also changing the functions. There were some spelling mistakes and other problems. Also commiting the MPI topology functions This commit was SVN r1075. --- include/mpi.h | 4 +-- src/communicator/communicator.h | 2 +- src/mca/topo/base/Makefile.am | 2 +- src/mca/topo/base/base.h | 2 +- src/mca/topo/topo.h | 6 ++++ src/mpi/c/cart_coords.c | 44 +++++++++++++++++++++++++++ src/mpi/c/cart_create.c | 42 ++++++++++++++++++++++++- src/mpi/c/cart_get.c | 37 ++++++++++++++++++++++ src/mpi/c/cart_map.c | 38 +++++++++++++++++++++++ src/mpi/c/cart_rank.c | 38 +++++++++++++++++++++++ src/mpi/c/cart_shift.c | 43 ++++++++++++++++++++++++++ src/mpi/c/cart_sub.c | 39 ++++++++++++++++++++++++ src/mpi/c/graph_create.c | 36 ++++++++++++++++++++++ src/mpi/c/graph_get.c | 39 ++++++++++++++++++++++++ src/mpi/c/graph_map.c | 35 +++++++++++++++++++++ src/mpi/c/graph_neighbors.c | 44 +++++++++++++++++++++++++++ src/mpi/c/graph_neighbors_count.c | 43 ++++++++++++++++++++++++++ src/mpi/c/graphdims_get.c | 39 ++++++++++++++++++++++++ src/mpi/f77/cart_create_f.c | 10 +++--- src/mpi/f77/profile/prototypes_pmpi.h | 10 +++--- src/mpi/f77/prototypes_mpi.h | 10 +++--- 21 files changed, 542 insertions(+), 21 deletions(-) diff --git a/include/mpi.h b/include/mpi.h index 7e28a86fb2..d572d51086 100644 --- a/include/mpi.h +++ b/include/mpi.h @@ -435,7 +435,7 @@ extern "C" { int MPI_Cancel(MPI_Request *request); int MPI_Cart_coords(MPI_Comm comm, int rank, int maxdims, int *coords); int MPI_Cart_create(MPI_Comm old_comm, int ndims, int *dims, - int *periods, int redorder, MPI_Comm *comm_cart); + int *periods, int reorder, MPI_Comm *comm_cart); int MPI_Cart_get(MPI_Comm comm, int maxdims, int *dims, int *periods, int *coords); int MPI_Cart_map(MPI_Comm comm, int ndims, int *dims, @@ -946,7 +946,7 @@ extern "C" { int PMPI_Cancel(MPI_Request *request); int PMPI_Cart_coords(MPI_Comm comm, int rank, int maxdims, int *coords); int PMPI_Cart_create(MPI_Comm old_comm, int ndims, int *dims, - int *periods, int redorder, MPI_Comm *comm_cart); + int *periods, int reorder, MPI_Comm *comm_cart); int PMPI_Cart_get(MPI_Comm comm, int maxdims, int *dims, int *periods, int *coords); int PMPI_Cart_map(MPI_Comm comm, int ndims, int *dims, diff --git a/src/communicator/communicator.h b/src/communicator/communicator.h index 6325fa65d2..7b1ca743ba 100644 --- a/src/communicator/communicator.h +++ b/src/communicator/communicator.h @@ -145,7 +145,7 @@ static inline int lam_cube_dim(int nprocs) { size_t size; if (1 > nprocs) return LAM_ERROR; - for(dim = 0, size = 1; size < nprocs; ++dim, size <<= 1); + for(dim = 0, size = 1; size < (size_t)nprocs; ++dim, size <<= 1); return dim; } diff --git a/src/mca/topo/base/Makefile.am b/src/mca/topo/base/Makefile.am index 507aea3e5d..912e0c44f9 100644 --- a/src/mca/topo/base/Makefile.am +++ b/src/mca/topo/base/Makefile.am @@ -19,7 +19,7 @@ libmca_topo_base_la_SOURCES = \ topo_base_cart_shift.c \ topo_base_cart_sub.c \ topo_base_graph_create.c \ - topo_base_graph_dims_get.c \ + topo_base_graphdims_get.c \ topo_base_graph_get.c \ topo_base_graph_neighbors.c \ topo_base_graph_neighbors_count.c \ diff --git a/src/mca/topo/base/base.h b/src/mca/topo/base/base.h index 3ec777c953..91d00efde5 100644 --- a/src/mca/topo/base/base.h +++ b/src/mca/topo/base/base.h @@ -79,7 +79,7 @@ extern "C" { int reorder, MPI_Comm *comm_graph); - int topo_base_graph_dims_get (MPI_Comm comm, + int topo_base_graphdims_get (MPI_Comm comm, int *nodes, int *nedges); diff --git a/src/mca/topo/topo.h b/src/mca/topo/topo.h index ec62f7b175..2955548498 100644 --- a/src/mca/topo/topo.h +++ b/src/mca/topo/topo.h @@ -181,6 +181,11 @@ typedef int (*mca_topo_base_graph_map_fn_t) int *edges, int *newrank); +typedef int (*mca_topo_base_graphdims_get_fn_t) + (MPI_Comm comm, + int *nnodes, + int *nnedges); + typedef int (*mca_topo_base_graph_neighbors_fn_t) (MPI_Comm comm, int rank, @@ -223,6 +228,7 @@ struct mca_topo_1_0_0_t { mca_topo_base_graph_create_fn_t topo_graph_create; mca_topo_base_graph_get_fn_t topo_graph_get; mca_topo_base_graph_map_fn_t topo_graph_map; + mca_topo_base_graphdims_get_fn_t topo_graphdims_get; mca_topo_base_graph_neighbors_fn_t topo_graph_neighbors; mca_topo_base_graph_neighbors_count_fn_t topo_graph_neighbors_count; }; diff --git a/src/mpi/c/cart_coords.c b/src/mpi/c/cart_coords.c index cced82be95..e9cdd5907a 100644 --- a/src/mpi/c/cart_coords.c +++ b/src/mpi/c/cart_coords.c @@ -6,6 +6,10 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "mca/topo/topo.h" +#include "errhandler/errhandler.h" +#include "group/group.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_coords = PMPI_Cart_coords @@ -16,5 +20,45 @@ #endif int MPI_Cart_coords(MPI_Comm comm, int rank, int maxdims, int *coords) { + int err; + mca_topo_base_cart_coords_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_coords"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_coords"); + } + if (!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_coords"); + } + if ( (0 > maxdims) || ((0 < maxdims) && (NULL == coords))) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_coords"); + } + if ((0 > rank) || (rank > lam_group_size(comm->c_local_group))) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_RANK, + "MPI_Cart_coords"); + } + } + + /* get the function pointer on this communicator */ + func = comm->c_topo.topo_cart_coords; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_coords"); + } + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, rank, maxdims, coords))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_coords"); + } + + /* all done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_create.c b/src/mpi/c/cart_create.c index 97060c4634..8e9a89b5fd 100644 --- a/src/mpi/c/cart_create.c +++ b/src/mpi/c/cart_create.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "mca/topo/topo.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_create = PMPI_Cart_create @@ -16,6 +19,43 @@ #endif int MPI_Cart_create(MPI_Comm old_comm, int ndims, int *dims, - int *periods, int redorder, MPI_Comm *comm_cart) { + int *periods, int reorder, MPI_Comm *comm_cart) { + + int err; + mca_topo_base_cart_create_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == old_comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_create"); + } + if (LAM_COMM_IS_INTER(old_comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_create"); + } + if (1 > ndims) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_create"); + } + if (NULL == dims || NULL == periods || NULL == comm_cart) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_create"); + } + } + /* get the function pointer to do the right thing */ + func = old_comm->c_topo.topo_cart_create; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_create"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(old_comm, ndims, dims, periods, reorder, comm_cart))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_create"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_get.c b/src/mpi/c/cart_get.c index 8471f326bd..e29136182a 100644 --- a/src/mpi/c/cart_get.c +++ b/src/mpi/c/cart_get.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "mca/topo/topo.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_get = PMPI_Cart_get @@ -17,5 +20,39 @@ int MPI_Cart_get(MPI_Comm comm, int maxdims, int *dims, int *periods, int *coords) { + /* local variables */ + mca_topo_base_cart_get_fn_t func; + int err; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm || LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_get"); + } + if (!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_get"); + } + if ((0 > maxdims) || (0 < maxdims && + ((NULL == dims) || (NULL == periods) || (NULL == coords)))) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_get"); + } + } + /* get the function pointer to do the right thing */ + func = comm->c_topo.topo_cart_get; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_get"); + } + + /* all arguments are checked and now call the back end function */ + if ( MPI_SUCCESS != + (err = func(comm, maxdims, dims, periods, coords))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_get"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_map.c b/src/mpi/c/cart_map.c index 6179202ffa..01794702b6 100644 --- a/src/mpi/c/cart_map.c +++ b/src/mpi/c/cart_map.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "mca/topo/topo.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_map = PMPI_Cart_map @@ -17,5 +20,40 @@ int MPI_Cart_map(MPI_Comm comm, int ndims, int *dims, int *periods, int *newrank) { + int err; + mca_topo_base_cart_map_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_map"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_map"); + } + if(!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_map"); + } + if ((NULL == dims) || (NULL == periods) || (NULL == newrank)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_map"); + } + } + + /* get the function pointer on this communicator */ + func = comm->c_topo.topo_cart_map; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_map"); + } + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, ndims, dims, periods, newrank))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_map"); + } + return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_rank.c b/src/mpi/c/cart_rank.c index e92f9bc1ef..244d78f518 100644 --- a/src/mpi/c/cart_rank.c +++ b/src/mpi/c/cart_rank.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "mca/topo/topo.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_rank = PMPI_Cart_rank @@ -17,5 +20,40 @@ int MPI_Cart_rank(MPI_Comm comm, int *coords, int *rank) { + int err; + mca_topo_base_cart_rank_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_rank"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_rank"); + } + if (!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_rank"); + } + if ((NULL == coords) || (NULL == rank)){ + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_rank"); + } + } + + /* get the function pointer on this communicator */ + func = comm->c_topo.topo_cart_rank; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_rank"); + } + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, coords, rank))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_rank"); + } + return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_shift.c b/src/mpi/c/cart_shift.c index 217dc8a8e0..4aa0388c33 100644 --- a/src/mpi/c/cart_shift.c +++ b/src/mpi/c/cart_shift.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "mca/topo/topo.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_shift = PMPI_Cart_shift @@ -17,5 +20,45 @@ int MPI_Cart_shift(MPI_Comm comm, int direction, int disp, int *rank_source, int *rank_dest) { + int err; + mca_topo_base_cart_shift_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_shift"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_shift"); + } + if (!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_shift"); + } + if (0 > direction) { /* yet to detect direction >= comm->c_topo_ndims */ + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_DIMS, + "MPI_Cart_shift"); + } + if (NULL == rank_source || NULL == rank_dest) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_shift"); + } + } + + /* get the function pointer on this communicator */ + func = comm->c_topo.topo_cart_shift; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_shift"); + } + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, direction, disp, rank_source, rank_dest))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_shift"); + } + + /* all done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/cart_sub.c b/src/mpi/c/cart_sub.c index 8a17cb3db5..58fe76930a 100644 --- a/src/mpi/c/cart_sub.c +++ b/src/mpi/c/cart_sub.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "mca/topo/topo.h" +#include "errhandler/errhandler.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Cart_sub = PMPI_Cart_sub @@ -17,5 +20,41 @@ int MPI_Cart_sub(MPI_Comm comm, int *remain_dims, MPI_Comm *new_comm) { + int err; + mca_topo_base_cart_sub_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_sub"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Cart_sub"); + } + if (!LAM_COMM_IS_CART(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Cart_sub"); + } + if (NULL == remain_dims || NULL == new_comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Cart_sub"); + } + } + + /* get the function pointer on this communicator */ + func = comm->c_topo.topo_cart_sub; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Cart_sub"); + } + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, remain_dims, new_comm))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Cart_sub"); + } + + /* all done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graph_create.c b/src/mpi/c/graph_create.c index 30e4c7bab2..b2fccacdd7 100644 --- a/src/mpi/c/graph_create.c +++ b/src/mpi/c/graph_create.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graph_create = PMPI_Graph_create @@ -17,5 +20,38 @@ int MPI_Graph_create(MPI_Comm comm_old, int nnodes, int *index, int *edges, int reorder, MPI_Comm *comm_graph) { + + int err; + mca_topo_base_graph_create_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm_old) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_create"); + } + if (LAM_COMM_IS_INTER(comm_old)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_create"); + } + if (1 > nnodes || NULL == index || NULL == edges) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graph_create"); + } + } + /* get the function pointer to do the right thing */ + func = comm_old->c_topo.topo_graph_create; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graph_create"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm_old, nnodes, index, edges, reorder, comm_graph))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graph_create"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graph_get.c b/src/mpi/c/graph_get.c index ddb015fe9f..7d22de12ce 100644 --- a/src/mpi/c/graph_get.c +++ b/src/mpi/c/graph_get.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graph_get = PMPI_Graph_get @@ -17,5 +20,41 @@ int MPI_Graph_get(MPI_Comm comm, int maxindex, int maxedges, int *index, int *edges) { + int err; + mca_topo_base_graph_get_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_get"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_get"); + } + if (!LAM_COMM_IS_GRAPH(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Graph_get"); + } + if (0 > maxindex || 0 > maxedges || NULL == index || NULL == edges) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graph_get"); + } + } + /* get the function pointer to do the right thing */ + func = comm->c_topo.topo_graph_get; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graph_get"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, maxindex, maxedges, index, edges))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graph_get"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graph_map.c b/src/mpi/c/graph_map.c index b059978f47..ef26b86e29 100644 --- a/src/mpi/c/graph_map.c +++ b/src/mpi/c/graph_map.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graph_map = PMPI_Graph_map @@ -17,5 +20,37 @@ int MPI_Graph_map(MPI_Comm comm, int nnodes, int *index, int *edges, int *newrank) { + int err; + mca_topo_base_graph_map_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_map"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_map"); + } + if (1 > nnodes || NULL == index || NULL == edges || NULL == newrank) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graph_map"); + } + } + /* map the function pointer to do the right thing */ + func = comm->c_topo.topo_graph_map; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graph_map"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, nnodes, index, edges, newrank))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graph_map"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graph_neighbors.c b/src/mpi/c/graph_neighbors.c index 2043dd8e40..341856ade6 100644 --- a/src/mpi/c/graph_neighbors.c +++ b/src/mpi/c/graph_neighbors.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graph_neighbors = PMPI_Graph_neighbors @@ -17,5 +20,46 @@ int MPI_Graph_neighbors(MPI_Comm comm, int rank, int maxneighbors, int *neighbors) { + int err; + mca_topo_base_graph_neighbors_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_neighbors"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_neighbors"); + } + if (!LAM_COMM_IS_GRAPH(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Graph_neighbors"); + } + + if ((0 > maxneighbors) || ((0 < maxneighbors) && NULL == neighbors)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graph_neighbors"); + } + if ((0 > rank) || (rank > lam_group_size(comm->c_local_group))) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_RANK, + "MPI_Graph_neighbors"); + } + } + /* neighbors the function pointer to do the right thing */ + func = comm->c_topo.topo_graph_neighbors; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graph_neighbors"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, rank, maxneighbors, neighbors))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graph_neighbors"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graph_neighbors_count.c b/src/mpi/c/graph_neighbors_count.c index 48a2f9d514..1b1768a7c2 100644 --- a/src/mpi/c/graph_neighbors_count.c +++ b/src/mpi/c/graph_neighbors_count.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graph_neighbors_count = PMPI_Graph_neighbors_count @@ -16,5 +19,45 @@ #endif int MPI_Graph_neighbors_count(MPI_Comm comm, int rank, int *nneighbors) { + int err; + mca_topo_base_graph_neighbors_count_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_neighbors_count"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graph_neighbors_count"); + } + if (!LAM_COMM_IS_GRAPH(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Graph_neighbors_count"); + } + if ((0 > rank) || (rank > lam_group_size(comm->c_local_group))) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_RANK, + "MPI_Graph_neighbors"); + } + if (NULL == nneighbors) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graph_neighbors_count"); + } + } + /* get the function pointer to do the right thing */ + func = comm->c_topo.topo_graph_neighbors_count; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graph_neighbors_count"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, rank, nneighbors))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graph_neighbors_count"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/c/graphdims_get.c b/src/mpi/c/graphdims_get.c index 597de1eb0f..a7bebbd0f2 100644 --- a/src/mpi/c/graphdims_get.c +++ b/src/mpi/c/graphdims_get.c @@ -6,6 +6,9 @@ #include "mpi.h" #include "mpi/c/bindings.h" +#include "communicator/communicator.h" +#include "errhandler/errhandler.h" +#include "mca/topo/topo.h" #if LAM_HAVE_WEAK_SYMBOLS && LAM_PROFILING_DEFINES #pragma weak MPI_Graphdims_get = PMPI_Graphdims_get @@ -16,5 +19,41 @@ #endif int MPI_Graphdims_get(MPI_Comm comm, int *nnodes, int *nedges) { + int err; + mca_topo_base_graphdims_get_fn_t func; + + /* check the arguments */ + if (MPI_PARAM_CHECK) { + if (MPI_COMM_NULL == comm) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graphdims_get"); + } + if (LAM_COMM_IS_INTER(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_COMM, + "MPI_Graphdims_get"); + } + if (!LAM_COMM_IS_GRAPH(comm)) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_TOPOLOGY, + "MPI_Graphdims_get"); + } + if (NULL == nnodes || NULL == nedges) { + return LAM_ERRHANDLER_INVOKE (MPI_COMM_WORLD, MPI_ERR_ARG, + "MPI_Graphdims_get"); + } + } + /* get the function pointer to do the right thing */ + func = comm->c_topo.topo_graphdims_get; + if (NULL == func) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_OTHER, + "MPI_Graphdims_get"); + } + + /* call the function */ + if ( MPI_SUCCESS != + (err = func(comm, nnodes, nedges))) { + return LAM_ERRHANDLER_INVOKE(MPI_COMM_WORLD, err, "MPI_Graphdims_get"); + } + + /* All done */ return MPI_SUCCESS; } diff --git a/src/mpi/f77/cart_create_f.c b/src/mpi/f77/cart_create_f.c index c76f39f6cf..4de4e55b4a 100644 --- a/src/mpi/f77/cart_create_f.c +++ b/src/mpi/f77/cart_create_f.c @@ -20,8 +20,8 @@ LAM_GENERATE_F77_BINDINGS (PMPI_CART_CREATE, pmpi_cart_create_, pmpi_cart_create__, pmpi_cart_create_f, - (MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr), - (old_comm, ndims, dims, periods, redorder, comm_cart, ierr) ) + (MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr), + (old_comm, ndims, dims, periods, reorder, comm_cart, ierr) ) #endif #if LAM_HAVE_WEAK_SYMBOLS @@ -37,8 +37,8 @@ LAM_GENERATE_F77_BINDINGS (MPI_CART_CREATE, mpi_cart_create_, mpi_cart_create__, mpi_cart_create_f, - (MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr), - (old_comm, ndims, dims, periods, redorder, comm_cart, ierr) ) + (MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr), + (old_comm, ndims, dims, periods, reorder, comm_cart, ierr) ) #endif @@ -46,7 +46,7 @@ LAM_GENERATE_F77_BINDINGS (MPI_CART_CREATE, #include "mpi/c/profile/defines.h" #endif -void mpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr) +void mpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr) { } diff --git a/src/mpi/f77/profile/prototypes_pmpi.h b/src/mpi/f77/profile/prototypes_pmpi.h index 5428fffd02..2db445cb64 100644 --- a/src/mpi/f77/profile/prototypes_pmpi.h +++ b/src/mpi/f77/profile/prototypes_pmpi.h @@ -41,7 +41,7 @@ void pmpi_buffer_attach_f(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_buffer_detach_f(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_cancel_f(MPI_Fint *request, MPI_Fint *ierr); void pmpi_cart_coords_f(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void pmpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void pmpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void pmpi_cart_get_f(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void pmpi_cart_map_f(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void pmpi_cart_rank_f(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -328,7 +328,7 @@ void pmpi_buffer_attach(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_buffer_detach(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_cancel(MPI_Fint *request, MPI_Fint *ierr); void pmpi_cart_coords(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void pmpi_cart_create(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void pmpi_cart_create(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void pmpi_cart_get(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void pmpi_cart_map(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void pmpi_cart_rank(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -615,7 +615,7 @@ void pmpi_buffer_attach_(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_buffer_detach_(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_cancel_(MPI_Fint *request, MPI_Fint *ierr); void pmpi_cart_coords_(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void pmpi_cart_create_(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void pmpi_cart_create_(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void pmpi_cart_get_(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void pmpi_cart_map_(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void pmpi_cart_rank_(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -902,7 +902,7 @@ void pmpi_buffer_attach__(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_buffer_detach__(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void pmpi_cancel__(MPI_Fint *request, MPI_Fint *ierr); void pmpi_cart_coords__(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void pmpi_cart_create__(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void pmpi_cart_create__(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void pmpi_cart_get__(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void pmpi_cart_map__(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void pmpi_cart_rank__(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -1189,7 +1189,7 @@ void PMPI_BUFFER_ATTACH(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void PMPI_BUFFER_DETACH(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void PMPI_CANCEL(MPI_Fint *request, MPI_Fint *ierr); void PMPI_CART_COORDS(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void PMPI_CART_CREATE(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void PMPI_CART_CREATE(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void PMPI_CART_GET(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void PMPI_CART_MAP(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void PMPI_CART_RANK(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); diff --git a/src/mpi/f77/prototypes_mpi.h b/src/mpi/f77/prototypes_mpi.h index 71ac4a5944..8b1d01db17 100644 --- a/src/mpi/f77/prototypes_mpi.h +++ b/src/mpi/f77/prototypes_mpi.h @@ -42,7 +42,7 @@ void mpi_buffer_attach_f(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_buffer_detach_f(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_cancel_f(MPI_Fint *request, MPI_Fint *ierr); void mpi_cart_coords_f(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void mpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void mpi_cart_create_f(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void mpi_cart_get_f(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void mpi_cart_map_f(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void mpi_cart_rank_f(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -331,7 +331,7 @@ void mpi_buffer_attach(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_buffer_detach(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_cancel(MPI_Fint *request, MPI_Fint *ierr); void mpi_cart_coords(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void mpi_cart_create(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void mpi_cart_create(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void mpi_cart_get(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void mpi_cart_map(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void mpi_cart_rank(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -618,7 +618,7 @@ void mpi_buffer_attach_(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_buffer_detach_(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_cancel_(MPI_Fint *request, MPI_Fint *ierr); void mpi_cart_coords_(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void mpi_cart_create_(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void mpi_cart_create_(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void mpi_cart_get_(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void mpi_cart_map_(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void mpi_cart_rank_(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -905,7 +905,7 @@ void mpi_buffer_attach__(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_buffer_detach__(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void mpi_cancel__(MPI_Fint *request, MPI_Fint *ierr); void mpi_cart_coords__(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void mpi_cart_create__(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void mpi_cart_create__(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void mpi_cart_get__(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void mpi_cart_map__(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void mpi_cart_rank__(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr); @@ -1192,7 +1192,7 @@ void MPI_BUFFER_ATTACH(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void MPI_BUFFER_DETACH(char *buffer, MPI_Fint *size, MPI_Fint *ierr); void MPI_CANCEL(MPI_Fint *request, MPI_Fint *ierr); void MPI_CART_COORDS(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims, MPI_Fint *coords, MPI_Fint *ierr); -void MPI_CART_CREATE(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *redorder, MPI_Fint *comm_cart, MPI_Fint *ierr); +void MPI_CART_CREATE(MPI_Fint *old_comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *reorder, MPI_Fint *comm_cart, MPI_Fint *ierr); void MPI_CART_GET(MPI_Fint *comm, MPI_Fint *maxdims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *coords, MPI_Fint *ierr); void MPI_CART_MAP(MPI_Fint *comm, MPI_Fint *ndims, MPI_Fint *dims, MPI_Fint *periods, MPI_Fint *newrank, MPI_Fint *ierr); void MPI_CART_RANK(MPI_Fint *comm, MPI_Fint *coords, MPI_Fint *rank, MPI_Fint *ierr);