- Remove unnecessary #include's (but still leave some that are
unnecessary for this demo component, but will generally be needed for a real coll component, by way of example) - Re-indent to 4 space tabs, since this component is used as a template - Update to new coll selection API (with the data parameter) This commit was SVN r4252.
Этот коммит содержится в:
родитель
5e47dafca6
Коммит
adf454c3c4
@ -20,9 +20,31 @@
|
|||||||
|
|
||||||
AUTOMAKE_OPTIONS = foreign dist-bzip2
|
AUTOMAKE_OPTIONS = foreign dist-bzip2
|
||||||
|
|
||||||
|
|
||||||
EXTRA_DIST = VERSION
|
EXTRA_DIST = VERSION
|
||||||
|
|
||||||
|
# Source files
|
||||||
|
|
||||||
|
sources = \
|
||||||
|
coll_demo.h \
|
||||||
|
coll_demo_allgather.c \
|
||||||
|
coll_demo_allgatherv.c \
|
||||||
|
coll_demo_allreduce.c \
|
||||||
|
coll_demo_alltoall.c \
|
||||||
|
coll_demo_alltoallv.c \
|
||||||
|
coll_demo_alltoallw.c \
|
||||||
|
coll_demo_barrier.c \
|
||||||
|
coll_demo_bcast.c \
|
||||||
|
coll_demo_component.c \
|
||||||
|
coll_demo_gather.c \
|
||||||
|
coll_demo_gatherv.c \
|
||||||
|
coll_demo_module.c \
|
||||||
|
coll_demo_reduce.c \
|
||||||
|
coll_demo_reduce_scatter.c \
|
||||||
|
coll_demo_scan.c \
|
||||||
|
coll_demo_exscan.c \
|
||||||
|
coll_demo_scatter.c \
|
||||||
|
coll_demo_scatterv.c
|
||||||
|
|
||||||
# Make the output library in this directory, and name it either
|
# Make the output library in this directory, and name it either
|
||||||
# mca_<type>_<name>.la (for DSO builds) or libmca_<type>_<name>.la
|
# mca_<type>_<name>.la (for DSO builds) or libmca_<type>_<name>.la
|
||||||
# (for static builds).
|
# (for static builds).
|
||||||
@ -45,26 +67,3 @@ noinst_LTLIBRARIES = $(component_noinst)
|
|||||||
libmca_coll_demo_la_SOURCES = $(sources)
|
libmca_coll_demo_la_SOURCES = $(sources)
|
||||||
libmca_coll_demo_la_LIBADD = src/libmca_coll_demo.la
|
libmca_coll_demo_la_LIBADD = src/libmca_coll_demo.la
|
||||||
libmca_coll_demo_la_LDFLAGS = -module -avoid-version
|
libmca_coll_demo_la_LDFLAGS = -module -avoid-version
|
||||||
|
|
||||||
# Source files
|
|
||||||
|
|
||||||
sources = \
|
|
||||||
coll_demo.h \
|
|
||||||
coll_demo.c \
|
|
||||||
coll_demo_allgather.c \
|
|
||||||
coll_demo_allgatherv.c \
|
|
||||||
coll_demo_allreduce.c \
|
|
||||||
coll_demo_alltoall.c \
|
|
||||||
coll_demo_alltoallv.c \
|
|
||||||
coll_demo_alltoallw.c \
|
|
||||||
coll_demo_barrier.c \
|
|
||||||
coll_demo_bcast.c \
|
|
||||||
coll_demo_component.c \
|
|
||||||
coll_demo_gather.c \
|
|
||||||
coll_demo_gatherv.c \
|
|
||||||
coll_demo_reduce.c \
|
|
||||||
coll_demo_reduce_scatter.c \
|
|
||||||
coll_demo_scan.c \
|
|
||||||
coll_demo_exscan.c \
|
|
||||||
coll_demo_scatter.c \
|
|
||||||
coll_demo_scatterv.c
|
|
||||||
|
@ -27,190 +27,183 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/* Globally exported variables */
|
||||||
* Globally exported variable
|
|
||||||
*/
|
|
||||||
|
|
||||||
extern const mca_coll_base_component_1_0_0_t mca_coll_demo_component;
|
extern const mca_coll_base_component_1_0_0_t mca_coll_demo_component;
|
||||||
extern int mca_coll_demo_priority_param;
|
extern int mca_coll_demo_priority_param;
|
||||||
extern int mca_coll_demo_verbose_param;
|
extern int mca_coll_demo_verbose_param;
|
||||||
extern int mca_coll_demo_verbose;
|
extern int mca_coll_demo_verbose;
|
||||||
|
|
||||||
|
|
||||||
/*
|
/* Component functions */
|
||||||
* coll API functions
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
int mca_coll_demo_init_query(bool *allow_demo_user_threads,
|
||||||
|
bool *have_hidden_threads);
|
||||||
|
const struct mca_coll_base_module_1_0_0_t *
|
||||||
|
mca_coll_demo_comm_query(struct ompi_communicator_t *comm, int *priority,
|
||||||
|
struct mca_coll_base_comm_t **data);
|
||||||
|
|
||||||
|
/* Module functions */
|
||||||
|
|
||||||
/* API functions */
|
const struct mca_coll_base_module_1_0_0_t *
|
||||||
|
mca_coll_demo_module_init(struct ompi_communicator_t *comm);
|
||||||
|
int mca_coll_demo_module_finalize(struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_init_query(bool *allow_demo_user_threads,
|
int mca_coll_demo_allgather_intra(void *sbuf, int scount,
|
||||||
bool *have_hidden_threads);
|
|
||||||
const struct mca_coll_base_module_1_0_0_t *
|
|
||||||
mca_coll_demo_comm_query(struct ompi_communicator_t *comm, int *priority);
|
|
||||||
int mca_coll_demo_comm_unquery(struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
const struct mca_coll_base_module_1_0_0_t *
|
|
||||||
mca_coll_demo_module_init(struct ompi_communicator_t *comm);
|
|
||||||
int mca_coll_demo_module_finalize(struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
int mca_coll_demo_allgather_intra(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype,
|
|
||||||
void *rbuf, int rcount,
|
|
||||||
struct ompi_datatype_t *rdtype,
|
|
||||||
struct ompi_communicator_t *comm);
|
|
||||||
int mca_coll_demo_allgather_inter(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype,
|
|
||||||
void *rbuf, int rcount,
|
|
||||||
struct ompi_datatype_t *rdtype,
|
|
||||||
struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
int mca_coll_demo_allgatherv_intra(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype,
|
struct ompi_datatype_t *sdtype,
|
||||||
void * rbuf, int *rcounts, int *disps,
|
void *rbuf, int rcount,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_allgatherv_inter(void *sbuf, int scount,
|
int mca_coll_demo_allgather_inter(void *sbuf, int scount,
|
||||||
struct ompi_datatype_t *sdtype,
|
struct ompi_datatype_t *sdtype,
|
||||||
void * rbuf, int *rcounts, int *disps,
|
void *rbuf, int rcount,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_allreduce_intra(void *sbuf, void *rbuf, int count,
|
int mca_coll_demo_allgatherv_intra(void *sbuf, int scount,
|
||||||
struct ompi_datatype_t *dtype,
|
struct ompi_datatype_t *sdtype,
|
||||||
struct ompi_op_t *op,
|
void * rbuf, int *rcounts, int *disps,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_datatype_t *rdtype,
|
||||||
int mca_coll_demo_allreduce_inter(void *sbuf, void *rbuf, int count,
|
struct ompi_communicator_t *comm);
|
||||||
struct ompi_datatype_t *dtype,
|
int mca_coll_demo_allgatherv_inter(void *sbuf, int scount,
|
||||||
struct ompi_op_t *op,
|
struct ompi_datatype_t *sdtype,
|
||||||
struct ompi_communicator_t *comm);
|
void * rbuf, int *rcounts, int *disps,
|
||||||
|
struct ompi_datatype_t *rdtype,
|
||||||
int mca_coll_demo_alltoall_intra(void *sbuf, int scount,
|
struct ompi_communicator_t *comm);
|
||||||
struct ompi_datatype_t *sdtype,
|
|
||||||
void* rbuf, int rcount,
|
int mca_coll_demo_allreduce_intra(void *sbuf, void *rbuf, int count,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *dtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_op_t *op,
|
||||||
int mca_coll_demo_alltoall_inter(void *sbuf, int scount,
|
struct ompi_communicator_t *comm);
|
||||||
struct ompi_datatype_t *sdtype,
|
int mca_coll_demo_allreduce_inter(void *sbuf, void *rbuf, int count,
|
||||||
void* rbuf, int rcount,
|
struct ompi_datatype_t *dtype,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_alltoallv_intra(void *sbuf, int *scounts, int *sdisps,
|
int mca_coll_demo_alltoall_intra(void *sbuf, int scount,
|
||||||
struct ompi_datatype_t *sdtype,
|
struct ompi_datatype_t *sdtype,
|
||||||
void *rbuf, int *rcounts, int *rdisps,
|
void* rbuf, int rcount,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_alltoallv_inter(void *sbuf, int *scounts, int *sdisps,
|
int mca_coll_demo_alltoall_inter(void *sbuf, int scount,
|
||||||
struct ompi_datatype_t *sdtype,
|
struct ompi_datatype_t *sdtype,
|
||||||
void *rbuf, int *rcounts, int *rdisps,
|
void* rbuf, int rcount,
|
||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_alltoallw_intra(void *sbuf, int *scounts, int *sdisps,
|
int mca_coll_demo_alltoallv_intra(void *sbuf, int *scounts, int *sdisps,
|
||||||
struct ompi_datatype_t **sdtypes,
|
struct ompi_datatype_t *sdtype,
|
||||||
void *rbuf, int *rcounts, int *rdisps,
|
void *rbuf, int *rcounts, int *rdisps,
|
||||||
struct ompi_datatype_t **rdtypes,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_alltoallw_inter(void *sbuf, int *scounts, int *sdisps,
|
int mca_coll_demo_alltoallv_inter(void *sbuf, int *scounts, int *sdisps,
|
||||||
struct ompi_datatype_t **sdtypes,
|
struct ompi_datatype_t *sdtype,
|
||||||
void *rbuf, int *rcounts, int *rdisps,
|
void *rbuf, int *rcounts, int *rdisps,
|
||||||
struct ompi_datatype_t **rdtypes,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_barrier_intra(struct ompi_communicator_t *comm);
|
int mca_coll_demo_alltoallw_intra(void *sbuf, int *scounts, int *sdisps,
|
||||||
int mca_coll_demo_barrier_inter(struct ompi_communicator_t *comm);
|
struct ompi_datatype_t **sdtypes,
|
||||||
|
void *rbuf, int *rcounts, int *rdisps,
|
||||||
int mca_coll_demo_bcast_intra(void *buff, int count,
|
struct ompi_datatype_t **rdtypes,
|
||||||
struct ompi_datatype_t *datatype,
|
struct ompi_communicator_t *comm);
|
||||||
int root,
|
int mca_coll_demo_alltoallw_inter(void *sbuf, int *scounts, int *sdisps,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_datatype_t **sdtypes,
|
||||||
int mca_coll_demo_bcast_inter(void *buff, int count,
|
void *rbuf, int *rcounts, int *rdisps,
|
||||||
struct ompi_datatype_t *datatype,
|
struct ompi_datatype_t **rdtypes,
|
||||||
int root,
|
struct ompi_communicator_t *comm);
|
||||||
struct ompi_communicator_t *comm);
|
|
||||||
|
int mca_coll_demo_barrier_intra(struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_exscan_intra(void *sbuf, void *rbuf, int count,
|
int mca_coll_demo_barrier_inter(struct ompi_communicator_t *comm);
|
||||||
struct ompi_datatype_t *dtype,
|
|
||||||
struct ompi_op_t *op,
|
int mca_coll_demo_bcast_intra(void *buff, int count,
|
||||||
|
struct ompi_datatype_t *datatype,
|
||||||
|
int root,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_exscan_inter(void *sbuf, void *rbuf, int count,
|
int mca_coll_demo_bcast_inter(void *buff, int count,
|
||||||
struct ompi_datatype_t *dtype,
|
struct ompi_datatype_t *datatype,
|
||||||
struct ompi_op_t *op,
|
int root,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_gather_intra(void *sbuf, int scount,
|
int mca_coll_demo_exscan_intra(void *sbuf, void *rbuf, int count,
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
struct ompi_datatype_t *dtype,
|
||||||
int rcount, struct ompi_datatype_t *rdtype,
|
struct ompi_op_t *op,
|
||||||
int root, struct ompi_communicator_t *comm);
|
|
||||||
int mca_coll_demo_gather_inter(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
|
||||||
int rcount, struct ompi_datatype_t *rdtype,
|
|
||||||
int root, struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
int mca_coll_demo_gatherv_intra(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
|
||||||
int *rcounts, int *disps,
|
|
||||||
struct ompi_datatype_t *rdtype, int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_gatherv_inter(void *sbuf, int scount,
|
int mca_coll_demo_exscan_inter(void *sbuf, void *rbuf, int count,
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
struct ompi_datatype_t *dtype,
|
||||||
int *rcounts, int *disps,
|
struct ompi_op_t *op,
|
||||||
struct ompi_datatype_t *rdtype, int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_reduce_intra(void *sbuf, void* rbuf, int count,
|
int mca_coll_demo_gather_intra(void *sbuf, int scount,
|
||||||
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
|
int rcount, struct ompi_datatype_t *rdtype,
|
||||||
|
int root, struct ompi_communicator_t *comm);
|
||||||
|
int mca_coll_demo_gather_inter(void *sbuf, int scount,
|
||||||
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
|
int rcount, struct ompi_datatype_t *rdtype,
|
||||||
|
int root, struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
|
int mca_coll_demo_gatherv_intra(void *sbuf, int scount,
|
||||||
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
|
int *rcounts, int *disps,
|
||||||
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
int mca_coll_demo_gatherv_inter(void *sbuf, int scount,
|
||||||
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
|
int *rcounts, int *disps,
|
||||||
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
|
int mca_coll_demo_reduce_intra(void *sbuf, void* rbuf, int count,
|
||||||
|
struct ompi_datatype_t *dtype,
|
||||||
|
struct ompi_op_t *op,
|
||||||
|
int root,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
int mca_coll_demo_reduce_inter(void *sbuf, void* rbuf, int count,
|
||||||
|
struct ompi_datatype_t *dtype,
|
||||||
|
struct ompi_op_t *op,
|
||||||
|
int root,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
|
int mca_coll_demo_reduce_scatter_intra(void *sbuf, void *rbuf,
|
||||||
|
int *rcounts,
|
||||||
|
struct ompi_datatype_t *dtype,
|
||||||
|
struct ompi_op_t *op,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
int mca_coll_demo_reduce_scatter_inter(void *sbuf, void *rbuf,
|
||||||
|
int *rcounts,
|
||||||
|
struct ompi_datatype_t *dtype,
|
||||||
|
struct ompi_op_t *op,
|
||||||
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
|
int mca_coll_demo_scan_intra(void *sbuf, void *rbuf, int count,
|
||||||
struct ompi_datatype_t *dtype,
|
struct ompi_datatype_t *dtype,
|
||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
int mca_coll_demo_reduce_inter(void *sbuf, void* rbuf, int count,
|
int mca_coll_demo_scan_inter(void *sbuf, void *rbuf, int count,
|
||||||
struct ompi_datatype_t *dtype,
|
struct ompi_datatype_t *dtype,
|
||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_reduce_scatter_intra(void *sbuf, void *rbuf,
|
int mca_coll_demo_scatter_intra(void *sbuf, int scount,
|
||||||
int *rcounts,
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
struct ompi_datatype_t *dtype,
|
int rcount, struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_op_t *op,
|
int root, struct ompi_communicator_t *comm);
|
||||||
struct ompi_communicator_t *comm);
|
int mca_coll_demo_scatter_inter(void *sbuf, int scount,
|
||||||
int mca_coll_demo_reduce_scatter_inter(void *sbuf, void *rbuf,
|
struct ompi_datatype_t *sdtype, void *rbuf,
|
||||||
int *rcounts,
|
int rcount, struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_datatype_t *dtype,
|
int root, struct ompi_communicator_t *comm);
|
||||||
struct ompi_op_t *op,
|
|
||||||
struct ompi_communicator_t *comm);
|
int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts, int *disps,
|
||||||
|
struct ompi_datatype_t *sdtype,
|
||||||
int mca_coll_demo_scan_intra(void *sbuf, void *rbuf, int count,
|
void* rbuf, int rcount,
|
||||||
struct ompi_datatype_t *dtype,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_op_t *op,
|
struct ompi_communicator_t *comm);
|
||||||
struct ompi_communicator_t *comm);
|
int mca_coll_demo_scatterv_inter(void *sbuf, int *scounts, int *disps,
|
||||||
int mca_coll_demo_scan_inter(void *sbuf, void *rbuf, int count,
|
struct ompi_datatype_t *sdtype,
|
||||||
struct ompi_datatype_t *dtype,
|
void* rbuf, int rcount,
|
||||||
struct ompi_op_t *op,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_communicator_t *comm);
|
struct ompi_communicator_t *comm);
|
||||||
|
|
||||||
int mca_coll_demo_scatter_intra(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
|
||||||
int rcount, struct ompi_datatype_t *rdtype,
|
|
||||||
int root, struct ompi_communicator_t *comm);
|
|
||||||
int mca_coll_demo_scatter_inter(void *sbuf, int scount,
|
|
||||||
struct ompi_datatype_t *sdtype, void *rbuf,
|
|
||||||
int rcount, struct ompi_datatype_t *rdtype,
|
|
||||||
int root, struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts, int *disps,
|
|
||||||
struct ompi_datatype_t *sdtype,
|
|
||||||
void* rbuf, int rcount,
|
|
||||||
struct ompi_datatype_t *rdtype, int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
|
||||||
int mca_coll_demo_scatterv_inter(void *sbuf, int *scounts, int *disps,
|
|
||||||
struct ompi_datatype_t *sdtype,
|
|
||||||
void* rbuf, int rcount,
|
|
||||||
struct ompi_datatype_t *rdtype, int root,
|
|
||||||
struct ompi_communicator_t *comm);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#if defined(c_plusplus) || defined(__cplusplus)
|
#if defined(c_plusplus) || defined(__cplusplus)
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* allgather_intra
|
* allgather_intra
|
||||||
*
|
*
|
||||||
* Function: - allgather using other MPI collections
|
* Function: - allgather
|
||||||
* Accepts: - same as MPI_Allgather()
|
* Accepts: - same as MPI_Allgather()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -35,16 +34,16 @@ int mca_coll_demo_allgather_intra(void *sbuf, int scount,
|
|||||||
int rcount, struct ompi_datatype_t *rdtype,
|
int rcount, struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allgather_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allgather_intra");
|
||||||
return comm->c_coll_basic_module->coll_allgather(sbuf, scount, sdtype, rbuf,
|
return comm->c_coll_basic_module->coll_allgather(sbuf, scount, sdtype, rbuf,
|
||||||
rcount, rdtype, comm);
|
rcount, rdtype, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* allgather_inter
|
* allgather_inter
|
||||||
*
|
*
|
||||||
* Function: - allgather using other MPI collections
|
* Function: - allgather
|
||||||
* Accepts: - same as MPI_Allgather()
|
* Accepts: - same as MPI_Allgather()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -54,7 +53,7 @@ int mca_coll_demo_allgather_inter(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allgather_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allgather_inter");
|
||||||
return comm->c_coll_basic_module->coll_allgather(sbuf, scount, sdtype, rbuf,
|
return comm->c_coll_basic_module->coll_allgather(sbuf, scount, sdtype, rbuf,
|
||||||
rcount, rdtype, comm);
|
rcount, rdtype, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* allgatherv_intra
|
* allgatherv_intra
|
||||||
*
|
*
|
||||||
* Function: - allgather using other MPI collectives
|
* Function: - allgather
|
||||||
* Accepts: - same as MPI_Allgatherv()
|
* Accepts: - same as MPI_Allgatherv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -36,17 +35,17 @@ int mca_coll_demo_allgatherv_intra(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allgatherv_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allgatherv_intra");
|
||||||
return comm->c_coll_basic_module->coll_allgatherv(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_allgatherv(sbuf, scount, sdtype,
|
||||||
rbuf, rcounts, disps,
|
rbuf, rcounts, disps,
|
||||||
rdtype, comm);
|
rdtype, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* allgatherv_inter
|
* allgatherv_inter
|
||||||
*
|
*
|
||||||
* Function: - allgather using other MPI collectives
|
* Function: - allgather
|
||||||
* Accepts: - same as MPI_Allgatherv()
|
* Accepts: - same as MPI_Allgatherv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -56,8 +55,8 @@ int mca_coll_demo_allgatherv_inter(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allgatherv_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allgatherv_inter");
|
||||||
return comm->c_coll_basic_module->coll_allgatherv(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_allgatherv(sbuf, scount, sdtype,
|
||||||
rbuf, rcounts, disps,
|
rbuf, rcounts, disps,
|
||||||
rdtype, comm);
|
rdtype, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* allreduce_intra
|
* allreduce_intra
|
||||||
*
|
*
|
||||||
* Function: - allreduce using other MPI collectives
|
* Function: - allreduce
|
||||||
* Accepts: - same as MPI_Allreduce()
|
* Accepts: - same as MPI_Allreduce()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -35,9 +34,9 @@ int mca_coll_demo_allreduce_intra(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allreduce_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allreduce_intra");
|
||||||
return comm->c_coll_basic_module->coll_allreduce(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_allreduce(sbuf, rbuf, count, dtype,
|
||||||
op, comm);
|
op, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -53,7 +52,7 @@ int mca_coll_demo_allreduce_inter(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo allreduce_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo allreduce_inter");
|
||||||
return comm->c_coll_basic_module->coll_allreduce(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_allreduce(sbuf, rbuf, count, dtype,
|
||||||
op, comm);
|
op, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -36,10 +35,10 @@ int mca_coll_demo_alltoall_intra(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoall_intra\n");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoall_intra\n");
|
||||||
return comm->c_coll_basic_module->coll_alltoall(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_alltoall(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
comm);
|
comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -56,8 +55,8 @@ int mca_coll_demo_alltoall_inter(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoall_inter\n");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoall_inter\n");
|
||||||
return comm->c_coll_basic_module->coll_alltoall(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_alltoall(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
comm);
|
comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -37,10 +36,10 @@ mca_coll_demo_alltoallv_intra(void *sbuf, int *scounts, int *sdisps,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallv_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallv_intra");
|
||||||
return comm->c_coll_basic_module->coll_alltoallv(sbuf, scounts, sdisps,
|
return comm->c_coll_basic_module->coll_alltoallv(sbuf, scounts, sdisps,
|
||||||
sdtype, rbuf, rcounts,
|
sdtype, rbuf, rcounts,
|
||||||
rdisps, rdtype, comm);
|
rdisps, rdtype, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -58,8 +57,8 @@ mca_coll_demo_alltoallv_inter(void *sbuf, int *scounts, int *sdisps,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallv_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallv_inter");
|
||||||
return comm->c_coll_basic_module->coll_alltoallv(sbuf, scounts, sdisps,
|
return comm->c_coll_basic_module->coll_alltoallv(sbuf, scounts, sdisps,
|
||||||
sdtype, rbuf, rcounts,
|
sdtype, rbuf, rcounts,
|
||||||
rdisps, rdtype, comm);
|
rdisps, rdtype, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* alltoallw_intra
|
* alltoallw_intra
|
||||||
*
|
*
|
||||||
* Function: - MPI_Alltoallw for non-ompid RPIs
|
* Function: - MPI_Alltoallw
|
||||||
* Accepts: - same as MPI_Alltoallw()
|
* Accepts: - same as MPI_Alltoallw()
|
||||||
* Returns: - MPI_SUCCESS or an MPI error code
|
* Returns: - MPI_SUCCESS or an MPI error code
|
||||||
*/
|
*/
|
||||||
@ -36,17 +35,17 @@ int mca_coll_demo_alltoallw_intra(void *sbuf, int *scounts, int *sdisps,
|
|||||||
struct ompi_datatype_t **rdtypes,
|
struct ompi_datatype_t **rdtypes,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallw_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallw_intra");
|
||||||
return comm->c_coll_basic_module->coll_alltoallw(sbuf, scounts, sdisps,
|
return comm->c_coll_basic_module->coll_alltoallw(sbuf, scounts, sdisps,
|
||||||
sdtypes, rbuf, rcounts,
|
sdtypes, rbuf, rcounts,
|
||||||
rdisps, rdtypes, comm);
|
rdisps, rdtypes, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* alltoallw_inter
|
* alltoallw_inter
|
||||||
*
|
*
|
||||||
* Function: - MPI_Alltoallw for non-lamd RPIs
|
* Function: - MPI_Alltoallw
|
||||||
* Accepts: - same as MPI_Alltoallw()
|
* Accepts: - same as MPI_Alltoallw()
|
||||||
* Returns: - MPI_SUCCESS or an MPI error code
|
* Returns: - MPI_SUCCESS or an MPI error code
|
||||||
*/
|
*/
|
||||||
@ -56,8 +55,8 @@ int mca_coll_demo_alltoallw_inter(void *sbuf, int *scounts, int *sdisps,
|
|||||||
struct ompi_datatype_t **rdtypes,
|
struct ompi_datatype_t **rdtypes,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallw_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo alltoallw_inter");
|
||||||
return comm->c_coll_basic_module->coll_alltoallw(sbuf, scounts, sdisps,
|
return comm->c_coll_basic_module->coll_alltoallw(sbuf, scounts, sdisps,
|
||||||
sdtypes, rbuf, rcounts,
|
sdtypes, rbuf, rcounts,
|
||||||
rdisps, rdtypes, comm);
|
rdisps, rdtypes, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,26 +25,26 @@
|
|||||||
/*
|
/*
|
||||||
* barrier_intra
|
* barrier_intra
|
||||||
*
|
*
|
||||||
* Function: - barrier using O(N) algorithm
|
* Function: - barrier
|
||||||
* Accepts: - same as MPI_Barrier()
|
* Accepts: - same as MPI_Barrier()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_barrier_intra(struct ompi_communicator_t *comm)
|
int mca_coll_demo_barrier_intra(struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo barrier_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo barrier_intra");
|
||||||
return comm->c_coll_basic_module->coll_barrier(comm);
|
return comm->c_coll_basic_module->coll_barrier(comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* barrier_inter
|
* barrier_inter
|
||||||
*
|
*
|
||||||
* Function: - barrier using O(log(N)) algorithm
|
* Function: - barrier
|
||||||
* Accepts: - same as MPI_Barrier()
|
* Accepts: - same as MPI_Barrier()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_barrier_inter(struct ompi_communicator_t *comm)
|
int mca_coll_demo_barrier_inter(struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo barrier_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo barrier_inter");
|
||||||
return comm->c_coll_basic_module->coll_barrier(comm);
|
return comm->c_coll_basic_module->coll_barrier(comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* bcast_intra
|
* bcast_intra
|
||||||
*
|
*
|
||||||
* Function: - broadcast using O(N) algorithm
|
* Function: - broadcast
|
||||||
* Accepts: - same arguments as MPI_Bcast()
|
* Accepts: - same arguments as MPI_Bcast()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -34,16 +33,16 @@ int mca_coll_demo_bcast_intra(void *buff, int count,
|
|||||||
struct ompi_datatype_t *datatype, int root,
|
struct ompi_datatype_t *datatype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo bcast_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo bcast_intra");
|
||||||
return comm->c_coll_basic_module->coll_bcast(buff, count, datatype,
|
return comm->c_coll_basic_module->coll_bcast(buff, count, datatype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* bcast_inter
|
* bcast_inter
|
||||||
*
|
*
|
||||||
* Function: - broadcast using O(N) algorithm
|
* Function: - broadcast
|
||||||
* Accepts: - same arguments as MPI_Bcast()
|
* Accepts: - same arguments as MPI_Bcast()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -51,7 +50,7 @@ int mca_coll_demo_bcast_inter(void *buff, int count,
|
|||||||
struct ompi_datatype_t *datatype, int root,
|
struct ompi_datatype_t *datatype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo bcast_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo bcast_inter");
|
||||||
return comm->c_coll_basic_module->coll_bcast(buff, count, datatype,
|
return comm->c_coll_basic_module->coll_bcast(buff, count, datatype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
@ -19,11 +19,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
#include "coll-demo-version.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "mca/coll/coll.h"
|
#include "mca/coll/coll.h"
|
||||||
|
#include "coll-demo-version.h"
|
||||||
#include "coll_demo.h"
|
#include "coll_demo.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -44,6 +43,7 @@ int mca_coll_demo_verbose = 0;
|
|||||||
*/
|
*/
|
||||||
static int demo_open(void);
|
static int demo_open(void);
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Instantiate the public struct with all of our public information
|
* Instantiate the public struct with all of our public information
|
||||||
* and pointers to our public functions in it
|
* and pointers to our public functions in it
|
||||||
@ -51,48 +51,46 @@ static int demo_open(void);
|
|||||||
|
|
||||||
const mca_coll_base_component_1_0_0_t mca_coll_demo_component = {
|
const mca_coll_base_component_1_0_0_t mca_coll_demo_component = {
|
||||||
|
|
||||||
/* First, the mca_component_t struct containing meta information
|
/* First, the mca_component_t struct containing meta information
|
||||||
about the component itself */
|
about the component itself */
|
||||||
|
|
||||||
{
|
{
|
||||||
/* Indicate that we are a coll v1.0.0 component (which also implies a
|
/* Indicate that we are a coll v1.0.0 component (which also
|
||||||
specific MCA version) */
|
implies a specific MCA version) */
|
||||||
|
|
||||||
MCA_COLL_BASE_VERSION_1_0_0,
|
MCA_COLL_BASE_VERSION_1_0_0,
|
||||||
|
|
||||||
/* Component name and version */
|
/* Component name and version */
|
||||||
|
|
||||||
"demo",
|
"demo",
|
||||||
MCA_coll_demo_MAJOR_VERSION,
|
MCA_coll_demo_MAJOR_VERSION,
|
||||||
MCA_coll_demo_MINOR_VERSION,
|
MCA_coll_demo_MINOR_VERSION,
|
||||||
MCA_coll_demo_RELEASE_VERSION,
|
MCA_coll_demo_RELEASE_VERSION,
|
||||||
|
|
||||||
/* Component open and close functions */
|
/* Component open and close functions */
|
||||||
|
|
||||||
demo_open,
|
demo_open,
|
||||||
|
NULL
|
||||||
|
},
|
||||||
|
|
||||||
|
/* Next the MCA v1.0.0 component meta data */
|
||||||
|
|
||||||
|
{
|
||||||
|
/* Whether the component is checkpointable or not */
|
||||||
|
|
||||||
|
true
|
||||||
|
},
|
||||||
|
|
||||||
|
/* Initialization / querying functions */
|
||||||
|
|
||||||
|
mca_coll_demo_init_query,
|
||||||
|
mca_coll_demo_comm_query,
|
||||||
NULL
|
NULL
|
||||||
},
|
|
||||||
|
|
||||||
/* Next the MCA v1.0.0 component meta data */
|
|
||||||
|
|
||||||
{
|
|
||||||
/* Whether the component is checkpointable or not */
|
|
||||||
|
|
||||||
true
|
|
||||||
},
|
|
||||||
|
|
||||||
/* Initialization / querying functions */
|
|
||||||
|
|
||||||
mca_coll_demo_init_query,
|
|
||||||
mca_coll_demo_comm_query,
|
|
||||||
NULL
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
static int demo_open(void)
|
static int demo_open(void)
|
||||||
{
|
{
|
||||||
/* Use a low priority, but allow other components to be lower */
|
|
||||||
|
|
||||||
mca_coll_demo_priority_param =
|
mca_coll_demo_priority_param =
|
||||||
mca_base_param_register_int("coll", "demo", "priority", NULL, 20);
|
mca_base_param_register_int("coll", "demo", "priority", NULL, 20);
|
||||||
mca_coll_demo_verbose_param =
|
mca_coll_demo_verbose_param =
|
||||||
|
@ -13,9 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -28,8 +25,8 @@
|
|||||||
/*
|
/*
|
||||||
* exscan_intra
|
* exscan_intra
|
||||||
*
|
*
|
||||||
* Function: - demo exscan operation
|
* Function: - exscan
|
||||||
* Accepts: - same arguments as MPI_Exccan()
|
* Accepts: - same arguments as MPI_Exscan()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_exscan_intra(void *sbuf, void *rbuf, int count,
|
int mca_coll_demo_exscan_intra(void *sbuf, void *rbuf, int count,
|
||||||
@ -37,17 +34,17 @@ int mca_coll_demo_exscan_intra(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo exscan_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo exscan_intra");
|
||||||
return comm->c_coll_basic_module->coll_exscan(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_exscan(sbuf, rbuf, count, dtype,
|
||||||
op, comm);
|
op, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* exscan_inter
|
* exscan_inter
|
||||||
*
|
*
|
||||||
* Function: - demo exscan operation
|
* Function: - exscan
|
||||||
* Accepts: - same arguments as MPI_Exccan()
|
* Accepts: - same arguments as MPI_Exscan()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_exscan_inter(void *sbuf, void *rbuf, int count,
|
int mca_coll_demo_exscan_inter(void *sbuf, void *rbuf, int count,
|
||||||
@ -55,7 +52,7 @@ int mca_coll_demo_exscan_inter(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo exscan_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo exscan_inter");
|
||||||
return comm->c_coll_basic_module->coll_exscan(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_exscan(sbuf, rbuf, count, dtype,
|
||||||
op, comm);
|
op, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -25,7 +24,7 @@
|
|||||||
/*
|
/*
|
||||||
* gather_intra
|
* gather_intra
|
||||||
*
|
*
|
||||||
* Function: - demo gather operation
|
* Function: - gather
|
||||||
* Accepts: - same arguments as MPI_Gather()
|
* Accepts: - same arguments as MPI_Gather()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -35,10 +34,10 @@ int mca_coll_demo_gather_intra(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
int root, struct ompi_communicator_t *comm)
|
int root, struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo gather_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo gather_intra");
|
||||||
return comm->c_coll_basic_module->coll_gather(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_gather(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -55,8 +54,8 @@ int mca_coll_demo_gather_inter(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype,
|
struct ompi_datatype_t *rdtype,
|
||||||
int root, struct ompi_communicator_t *comm)
|
int root, struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo gather_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo gather_inter");
|
||||||
return comm->c_coll_basic_module->coll_gather(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_gather(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -26,8 +25,8 @@
|
|||||||
/*
|
/*
|
||||||
* gatherv_intra
|
* gatherv_intra
|
||||||
*
|
*
|
||||||
* Function: - demo gatherv operation
|
* Function: - gatherv
|
||||||
* Accepts: - same arguments as MPI_Bcast()
|
* Accepts: - same arguments as MPI_Gatherv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_gatherv_intra(void *sbuf, int scount,
|
int mca_coll_demo_gatherv_intra(void *sbuf, int scount,
|
||||||
@ -36,18 +35,18 @@ int mca_coll_demo_gatherv_intra(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype, int root,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo gatherv_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo gatherv_intra");
|
||||||
return comm->c_coll_basic_module->coll_gatherv(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_gatherv(sbuf, scount, sdtype,
|
||||||
rbuf, rcounts, disps,
|
rbuf, rcounts, disps,
|
||||||
rdtype, root, comm);
|
rdtype, root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* gatherv_inter
|
* gatherv_inter
|
||||||
*
|
*
|
||||||
* Function: - demo gatherv operation
|
* Function: - gatherv
|
||||||
* Accepts: - same arguments as MPI_Bcast()
|
* Accepts: - same arguments as MPI_Gatherv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_gatherv_inter(void *sbuf, int scount,
|
int mca_coll_demo_gatherv_inter(void *sbuf, int scount,
|
||||||
@ -56,8 +55,8 @@ int mca_coll_demo_gatherv_inter(void *sbuf, int scount,
|
|||||||
struct ompi_datatype_t *rdtype, int root,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo gatherv_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo gatherv_inter");
|
||||||
return comm->c_coll_basic_module->coll_gatherv(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_gatherv(sbuf, scount, sdtype,
|
||||||
rbuf, rcounts, disps,
|
rbuf, rcounts, disps,
|
||||||
rdtype, root, comm);
|
rdtype, root, comm);
|
||||||
}
|
}
|
||||||
|
@ -29,29 +29,29 @@
|
|||||||
*/
|
*/
|
||||||
static const mca_coll_base_module_1_0_0_t intra = {
|
static const mca_coll_base_module_1_0_0_t intra = {
|
||||||
|
|
||||||
/* Initialization / finalization functions */
|
/* Initialization / finalization functions */
|
||||||
|
|
||||||
mca_coll_demo_module_init,
|
mca_coll_demo_module_init,
|
||||||
mca_coll_demo_module_finalize,
|
mca_coll_demo_module_finalize,
|
||||||
|
|
||||||
/* Collective function pointers */
|
/* Collective function pointers */
|
||||||
|
|
||||||
mca_coll_demo_allgather_intra,
|
mca_coll_demo_allgather_intra,
|
||||||
mca_coll_demo_allgatherv_intra,
|
mca_coll_demo_allgatherv_intra,
|
||||||
mca_coll_demo_allreduce_intra,
|
mca_coll_demo_allreduce_intra,
|
||||||
mca_coll_demo_alltoall_intra,
|
mca_coll_demo_alltoall_intra,
|
||||||
mca_coll_demo_alltoallv_intra,
|
mca_coll_demo_alltoallv_intra,
|
||||||
mca_coll_demo_alltoallw_intra,
|
mca_coll_demo_alltoallw_intra,
|
||||||
mca_coll_demo_barrier_intra,
|
mca_coll_demo_barrier_intra,
|
||||||
mca_coll_demo_bcast_intra,
|
mca_coll_demo_bcast_intra,
|
||||||
NULL, /* Leave exscan blank just to force basic to be loaded used */
|
NULL, /* Leave exscan blank just to force basic to be used */
|
||||||
mca_coll_demo_gather_intra,
|
mca_coll_demo_gather_intra,
|
||||||
mca_coll_demo_gatherv_intra,
|
mca_coll_demo_gatherv_intra,
|
||||||
mca_coll_demo_reduce_intra,
|
mca_coll_demo_reduce_intra,
|
||||||
mca_coll_demo_reduce_scatter_intra,
|
mca_coll_demo_reduce_scatter_intra,
|
||||||
mca_coll_demo_scan_intra,
|
mca_coll_demo_scan_intra,
|
||||||
mca_coll_demo_scatter_intra,
|
mca_coll_demo_scatter_intra,
|
||||||
mca_coll_demo_scatterv_intra
|
mca_coll_demo_scatterv_intra
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -60,29 +60,29 @@ static const mca_coll_base_module_1_0_0_t intra = {
|
|||||||
*/
|
*/
|
||||||
static const mca_coll_base_module_1_0_0_t inter = {
|
static const mca_coll_base_module_1_0_0_t inter = {
|
||||||
|
|
||||||
/* Initialization / finalization functions */
|
/* Initialization / finalization functions */
|
||||||
|
|
||||||
mca_coll_demo_module_init,
|
mca_coll_demo_module_init,
|
||||||
mca_coll_demo_module_finalize,
|
mca_coll_demo_module_finalize,
|
||||||
|
|
||||||
/* Collective function pointers */
|
/* Collective function pointers */
|
||||||
|
|
||||||
mca_coll_demo_allgather_inter,
|
mca_coll_demo_allgather_inter,
|
||||||
mca_coll_demo_allgatherv_inter,
|
mca_coll_demo_allgatherv_inter,
|
||||||
mca_coll_demo_allreduce_inter,
|
mca_coll_demo_allreduce_inter,
|
||||||
mca_coll_demo_alltoall_inter,
|
mca_coll_demo_alltoall_inter,
|
||||||
mca_coll_demo_alltoallv_inter,
|
mca_coll_demo_alltoallv_inter,
|
||||||
mca_coll_demo_alltoallw_inter,
|
mca_coll_demo_alltoallw_inter,
|
||||||
mca_coll_demo_barrier_inter,
|
mca_coll_demo_barrier_inter,
|
||||||
mca_coll_demo_bcast_inter,
|
mca_coll_demo_bcast_inter,
|
||||||
mca_coll_demo_exscan_inter,
|
mca_coll_demo_exscan_inter,
|
||||||
mca_coll_demo_gather_inter,
|
mca_coll_demo_gather_inter,
|
||||||
mca_coll_demo_gatherv_inter,
|
mca_coll_demo_gatherv_inter,
|
||||||
mca_coll_demo_reduce_inter,
|
mca_coll_demo_reduce_inter,
|
||||||
mca_coll_demo_reduce_scatter_inter,
|
mca_coll_demo_reduce_scatter_inter,
|
||||||
NULL,
|
NULL,
|
||||||
mca_coll_demo_scatter_inter,
|
mca_coll_demo_scatter_inter,
|
||||||
mca_coll_demo_scatterv_inter
|
mca_coll_demo_scatterv_inter
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -93,12 +93,12 @@ static const mca_coll_base_module_1_0_0_t inter = {
|
|||||||
int mca_coll_demo_init_query(bool *allow_demo_user_threads,
|
int mca_coll_demo_init_query(bool *allow_demo_user_threads,
|
||||||
bool *have_hidden_user_threads)
|
bool *have_hidden_user_threads)
|
||||||
{
|
{
|
||||||
*allow_demo_user_threads = true;
|
*allow_demo_user_threads = true;
|
||||||
*have_hidden_user_threads = false;
|
*have_hidden_user_threads = false;
|
||||||
|
|
||||||
/* All done */
|
/* All done */
|
||||||
|
|
||||||
return OMPI_SUCCESS;
|
return OMPI_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -108,14 +108,15 @@ int mca_coll_demo_init_query(bool *allow_demo_user_threads,
|
|||||||
* priority we want to return.
|
* priority we want to return.
|
||||||
*/
|
*/
|
||||||
const mca_coll_base_module_1_0_0_t *
|
const mca_coll_base_module_1_0_0_t *
|
||||||
mca_coll_demo_comm_query(struct ompi_communicator_t *comm, int *priority)
|
mca_coll_demo_comm_query(struct ompi_communicator_t *comm, int *priority,
|
||||||
|
struct mca_coll_base_comm_t **data)
|
||||||
{
|
{
|
||||||
if (OMPI_SUCCESS != mca_base_param_lookup_int(mca_coll_demo_priority_param,
|
if (OMPI_SUCCESS !=
|
||||||
priority)) {
|
mca_base_param_lookup_int(mca_coll_demo_priority_param, priority)) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
return OMPI_COMM_IS_INTER(comm) ? &inter : &intra;
|
return OMPI_COMM_IS_INTER(comm) ? &inter : &intra;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -140,5 +141,5 @@ mca_coll_demo_module_init(struct ompi_communicator_t *comm)
|
|||||||
*/
|
*/
|
||||||
int mca_coll_demo_module_finalize(struct ompi_communicator_t *comm)
|
int mca_coll_demo_module_finalize(struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
return OMPI_SUCCESS;
|
return OMPI_SUCCESS;
|
||||||
}
|
}
|
@ -13,9 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -28,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* reduce_intra
|
* reduce_intra
|
||||||
*
|
*
|
||||||
* Function: - reduction using O(N) algorithm
|
* Function: - reduction
|
||||||
* Accepts: - same as MPI_Reduce()
|
* Accepts: - same as MPI_Reduce()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -37,16 +34,16 @@ int mca_coll_demo_reduce_intra(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
int root, struct ompi_communicator_t *comm)
|
int root, struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo reduce_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo reduce_intra");
|
||||||
return comm->c_coll_basic_module->coll_reduce(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_reduce(sbuf, rbuf, count, dtype,
|
||||||
op, root, comm);
|
op, root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* reduce_log_inter
|
* reduce_inter
|
||||||
*
|
*
|
||||||
* Function: - reduction using O(N) algorithm
|
* Function: - reduction
|
||||||
* Accepts: - same as MPI_Reduce()
|
* Accepts: - same as MPI_Reduce()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -55,7 +52,7 @@ int mca_coll_demo_reduce_inter(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
int root, struct ompi_communicator_t *comm)
|
int root, struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo reduce_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo reduce_inter");
|
||||||
return comm->c_coll_basic_module->coll_reduce(sbuf, rbuf, count, dtype,
|
return comm->c_coll_basic_module->coll_reduce(sbuf, rbuf, count, dtype,
|
||||||
op, root, comm);
|
op, root, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,10 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <errno.h>
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -38,9 +34,9 @@ int mca_coll_demo_reduce_scatter_intra(void *sbuf, void *rbuf, int *rcounts,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_intra");
|
||||||
return comm->c_coll_basic_module->coll_reduce_scatter(sbuf, rbuf, rcounts,
|
return comm->c_coll_basic_module->coll_reduce_scatter(sbuf, rbuf, rcounts,
|
||||||
dtype, op, comm);
|
dtype, op, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -56,7 +52,7 @@ int mca_coll_demo_reduce_scatter_inter(void *sbuf, void *rbuf, int *rcounts,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_inter");
|
||||||
return comm->c_coll_basic_module->coll_reduce_scatter(sbuf, rbuf, rcounts,
|
return comm->c_coll_basic_module->coll_reduce_scatter(sbuf, rbuf, rcounts,
|
||||||
dtype, op, comm);
|
dtype, op, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,9 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -28,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* scan
|
* scan
|
||||||
*
|
*
|
||||||
* Function: - demo scan operation
|
* Function: - scan
|
||||||
* Accepts: - same arguments as MPI_Scan()
|
* Accepts: - same arguments as MPI_Scan()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
@ -37,7 +34,12 @@ int mca_coll_demo_scan_intra(void *sbuf, void *rbuf, int count,
|
|||||||
struct ompi_op_t *op,
|
struct ompi_op_t *op,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scan_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scan_intra");
|
||||||
return comm->c_coll_basic_module->coll_scan(sbuf, rbuf, count,
|
return comm->c_coll_basic_module->coll_scan(sbuf, rbuf, count,
|
||||||
dtype, op, comm);
|
dtype, op, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* NOTE: There is no exscan defined for intercommunicators (see MPI-2).
|
||||||
|
*/
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -37,10 +36,10 @@ int mca_coll_demo_scatter_intra(void *sbuf, int scount,
|
|||||||
int root,
|
int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_intra");
|
||||||
return comm->c_coll_basic_module->coll_scatter(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_scatter(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -58,8 +57,8 @@ int mca_coll_demo_scatter_inter(void *sbuf, int scount,
|
|||||||
int root,
|
int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatter_inter");
|
||||||
return comm->c_coll_basic_module->coll_scatter(sbuf, scount, sdtype,
|
return comm->c_coll_basic_module->coll_scatter(sbuf, scount, sdtype,
|
||||||
rbuf, rcount, rdtype,
|
rbuf, rcount, rdtype,
|
||||||
root, comm);
|
root, comm);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "ompi_config.h"
|
#include "ompi_config.h"
|
||||||
#include "coll_demo.h"
|
|
||||||
|
|
||||||
#include "mpi.h"
|
#include "mpi.h"
|
||||||
#include "include/constants.h"
|
#include "include/constants.h"
|
||||||
@ -27,7 +26,7 @@
|
|||||||
* scatterv_intra
|
* scatterv_intra
|
||||||
*
|
*
|
||||||
* Function: - scatterv operation
|
* Function: - scatterv operation
|
||||||
* Accepts: - same arguments as MPI_Scatter()
|
* Accepts: - same arguments as MPI_Scatterv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts,
|
int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts,
|
||||||
@ -36,10 +35,10 @@ int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts,
|
|||||||
struct ompi_datatype_t *rdtype, int root,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatterv_intra");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatterv_intra");
|
||||||
return comm->c_coll_basic_module->coll_scatterv(sbuf, scounts, disps,
|
return comm->c_coll_basic_module->coll_scatterv(sbuf, scounts, disps,
|
||||||
sdtype, rbuf, rcount, rdtype,
|
sdtype, rbuf, rcount,
|
||||||
root, comm);
|
rdtype, root, comm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -47,7 +46,7 @@ int mca_coll_demo_scatterv_intra(void *sbuf, int *scounts,
|
|||||||
* scatterv_inter
|
* scatterv_inter
|
||||||
*
|
*
|
||||||
* Function: - scatterv operation
|
* Function: - scatterv operation
|
||||||
* Accepts: - same arguments as MPI_Scatter()
|
* Accepts: - same arguments as MPI_Scatterv()
|
||||||
* Returns: - MPI_SUCCESS or error code
|
* Returns: - MPI_SUCCESS or error code
|
||||||
*/
|
*/
|
||||||
int mca_coll_demo_scatterv_inter(void *sbuf, int *scounts,
|
int mca_coll_demo_scatterv_inter(void *sbuf, int *scounts,
|
||||||
@ -56,8 +55,8 @@ int mca_coll_demo_scatterv_inter(void *sbuf, int *scounts,
|
|||||||
struct ompi_datatype_t *rdtype, int root,
|
struct ompi_datatype_t *rdtype, int root,
|
||||||
struct ompi_communicator_t *comm)
|
struct ompi_communicator_t *comm)
|
||||||
{
|
{
|
||||||
ompi_output_verbose(10, mca_coll_base_output, "In demo scatterv_inter");
|
ompi_output_verbose(10, mca_coll_base_output, "In demo scatterv_inter");
|
||||||
return comm->c_coll_basic_module->coll_scatterv(sbuf, scounts, disps,
|
return comm->c_coll_basic_module->coll_scatterv(sbuf, scounts, disps,
|
||||||
sdtype, rbuf, rcount, rdtype,
|
sdtype, rbuf, rcount,
|
||||||
root, comm);
|
rdtype, root, comm);
|
||||||
}
|
}
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user