Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[mc] Add comments
[simgrid.git] / src / include / smpi / smpi_interface.h
1 #ifndef _SMPI_INTERFACE_H
2 #define _SMPI_INTERFACE_H
3 #include "smpi/smpi.h"
4
5
6
7 /** \brief MPI collective description
8  */
9
10 typedef struct mpi_coll_description {
11   const char *name;
12   const char *description;
13   void *coll;
14 } s_mpi_coll_description_t, *mpi_coll_description_t;
15
16
17 /** \ingroup MPI gather
18  *  \brief The list of all available allgather collectives
19  */
20 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_gather_description[];
21 XBT_PUBLIC_DATA(int (*mpi_coll_gather_fun)
22                 (void *, int, MPI_Datatype, void *, int, MPI_Datatype,
23                  int, MPI_Comm));
24                  
25 /** \ingroup MPI allgather
26  *  \brief The list of all available allgather collectives
27  */
28 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_allgather_description[];
29 XBT_PUBLIC_DATA(int (*mpi_coll_allgather_fun)
30                 (void *, int, MPI_Datatype, void *, int, MPI_Datatype,
31                  MPI_Comm));
32
33 /** \ingroup MPI allgather
34  *  \brief The list of all available allgather collectives
35  */
36 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_allgatherv_description[];
37 XBT_PUBLIC_DATA(int (*mpi_coll_allgatherv_fun)
38                 (void *, int, MPI_Datatype, void *, int*, int*, MPI_Datatype,
39                  MPI_Comm));
40
41
42 /** \ingroup MPI allreduce
43  *  \brief The list of all available allgather collectives
44  */
45 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_allreduce_description[];
46 XBT_PUBLIC_DATA(int (*mpi_coll_allreduce_fun)
47                 (void *sbuf, void *rbuf, int rcount, MPI_Datatype dtype,
48                  MPI_Op op, MPI_Comm comm));
49
50
51 /** \ingroup MPI alltoall
52  *  \brief The list of all available alltoall collectives
53  */
54 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_alltoall_description[];
55 XBT_PUBLIC_DATA(int (*mpi_coll_alltoall_fun)
56                 (void *, int, MPI_Datatype, void *, int, MPI_Datatype,
57                  MPI_Comm));
58
59 /** \ingroup MPI alltoallv
60  *  \brief The list of all available alltoallv collectives
61  */
62 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_alltoallv_description[];
63 XBT_PUBLIC_DATA(int (*mpi_coll_alltoallv_fun)
64                 (void *, int*, int*, MPI_Datatype, void *, int*, int*, MPI_Datatype,
65                  MPI_Comm));
66
67
68 /** \ingroup MPI bcast
69  *  \brief The list of all available bcast collectives
70  */
71 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_bcast_description[];
72 XBT_PUBLIC_DATA(int (*mpi_coll_bcast_fun)
73                 (void *buf, int count, MPI_Datatype datatype, int root,
74                  MPI_Comm com));
75
76
77 /** \ingroup MPI reduce
78  *  \brief The list of all available reduce collectives
79  */
80 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_reduce_description[];
81 XBT_PUBLIC_DATA(int (*mpi_coll_reduce_fun)
82                 (void *buf, void *rbuf, int count, MPI_Datatype datatype,
83                  MPI_Op op, int root, MPI_Comm comm));
84
85 /** \ingroup MPI reduce_scatter
86  *  \brief The list of all available allgather collectives
87  */
88 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_reduce_scatter_description[];
89 XBT_PUBLIC_DATA(int (*mpi_coll_reduce_scatter_fun)
90                 (void *sbuf, void *rbuf, int *rcounts,
91                  MPI_Datatype dtype, MPI_Op op,MPI_Comm comm));
92
93 /** \ingroup MPI scatter
94  *  \brief The list of all available allgather collectives
95  */
96 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_scatter_description[];
97 XBT_PUBLIC_DATA(int (*mpi_coll_scatter_fun)
98                 (void *sendbuf, int sendcount, MPI_Datatype sendtype,
99                 void *recvbuf, int recvcount, MPI_Datatype recvtype,
100                 int root, MPI_Comm comm));
101
102 /** \ingroup MPI barrier
103  *  \brief The list of all available allgather collectives
104  */
105 XBT_PUBLIC_DATA(s_mpi_coll_description_t) mpi_coll_barrier_description[];
106 XBT_PUBLIC_DATA(int (*mpi_coll_barrier_fun)
107                 (MPI_Comm comm));
108
109
110 XBT_PUBLIC(void) coll_help(const char *category,
111                            s_mpi_coll_description_t * table);
112 XBT_PUBLIC(int) find_coll_description(s_mpi_coll_description_t * table,
113                                       char *name);
114 #endif                          /* _SMPI_INTERFAC_H */