Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
add a reference counter in order to avoide deleting MPI_Comm, and MPI_Group, too...
[simgrid.git] / src / smpi / private.h
index 6c34cd07c87fe7ce22eb4dcb2eb5a680809bb0f7..1e2a3c21426cd22d005e423fe3176c49ef5756ed 100644 (file)
@@ -26,6 +26,7 @@ typedef struct s_smpi_process_data *smpi_process_data_t;
 #define RECV_DELETE    0x10
 #define ISEND          0x20
 #define SSEND          0x40
+#define PREPARED       0x80
 // this struct is here to handle the problem of non-contignous data
 // for each such structure these function should be implemented (vector
 // index hvector hindex struct)
@@ -48,19 +49,19 @@ typedef struct s_smpi_mpi_datatype{
 } s_smpi_mpi_datatype_t;
 
 
-#define COLL_TAG_REDUCE 111
-#define COLL_TAG_SCATTER 222
-#define COLL_TAG_SCATTERV 333
-#define COLL_TAG_GATHER 444
-#define COLL_TAG_ALLGATHER 555
-#define COLL_TAG_ALLGATHERV 666
-#define COLL_TAG_BARRIER 777
-#define COLL_TAG_REDUCE_SCATTER 888
-#define COLL_TAG_ALLTOALLV 999
-#define COLL_TAG_ALLTOALL 1111
-#define COLL_TAG_GATHERV 2222
-#define COLL_TAG_BCAST 3333
-#define COLL_TAG_ALLREDUCE 4444
+#define COLL_TAG_REDUCE -112
+#define COLL_TAG_SCATTER -223
+#define COLL_TAG_SCATTERV -334
+#define COLL_TAG_GATHER -445
+#define COLL_TAG_ALLGATHER -556
+#define COLL_TAG_ALLGATHERV -667
+#define COLL_TAG_BARRIER -778
+#define COLL_TAG_REDUCE_SCATTER -889
+#define COLL_TAG_ALLTOALLV -1000
+#define COLL_TAG_ALLTOALL -1112
+#define COLL_TAG_GATHERV -2223
+#define COLL_TAG_BCAST -3334
+#define COLL_TAG_ALLREDUCE -4445
 //*****************************************************************************************
 
 typedef struct s_smpi_mpi_request {
@@ -172,6 +173,8 @@ int smpi_comm_size(MPI_Comm comm);
 void smpi_comm_get_name(MPI_Comm comm, char* name, int* len);
 int smpi_comm_rank(MPI_Comm comm);
 MPI_Comm smpi_comm_split(MPI_Comm comm, int color, int key);
+void smpi_comm_use(MPI_Comm comm);
+void smpi_comm_unuse(MPI_Comm comm);
 
 MPI_Request smpi_mpi_send_init(void *buf, int count, MPI_Datatype datatype,
                                int dst, int tag, MPI_Comm comm);