3
3
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
4
4
* University Research and Technology
5
5
* Corporation. All rights reserved.
6
- * Copyright (c) 2004-2016 The University of Tennessee and The University
6
+ * Copyright (c) 2004-2019 The University of Tennessee and The University
7
7
* of Tennessee Research Foundation. All rights
8
8
* reserved.
9
9
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
15
15
* Copyright (c) 2014-2015 Research Organization for Information Science
16
16
* and Technology (RIST). All rights reserved.
17
17
* Copyright (c) 2017 IBM Corporation. All rights reserved.
18
+ * Copyright (c) 2019 Google, LLC. All rights reserved.
18
19
* $COPYRIGHT$
19
20
*
20
21
* Additional copyrights may follow
36
37
#include "coll_basic.h"
37
38
#include "ompi/mca/topo/base/base.h"
38
39
40
+ /**
41
+ * We only have 1024 tags for the neighbor collective, so for now we only support
42
+ * 512 dimensions.
43
+ */
39
44
static int
40
45
mca_coll_basic_neighbor_alltoall_cart (const void * sbuf , int scount , struct ompi_datatype_t * sdtype , void * rbuf ,
41
46
int rcount , struct ompi_datatype_t * rdtype , struct ompi_communicator_t * comm ,
@@ -67,7 +72,7 @@ mca_coll_basic_neighbor_alltoall_cart(const void *sbuf, int scount, struct ompi_
67
72
if (MPI_PROC_NULL != srank ) {
68
73
nreqs ++ ;
69
74
rc = MCA_PML_CALL (irecv (rbuf , rcount , rdtype , srank ,
70
- MCA_COLL_BASE_TAG_ALLTOALL ,
75
+ MCA_COLL_BASE_TAG_NEIGHBOR_BASE - 2 * dim ,
71
76
comm , preqs ++ ));
72
77
if (OMPI_SUCCESS != rc ) break ;
73
78
}
@@ -77,7 +82,7 @@ mca_coll_basic_neighbor_alltoall_cart(const void *sbuf, int scount, struct ompi_
77
82
if (MPI_PROC_NULL != drank ) {
78
83
nreqs ++ ;
79
84
rc = MCA_PML_CALL (irecv (rbuf , rcount , rdtype , drank ,
80
- MCA_COLL_BASE_TAG_ALLTOALL ,
85
+ MCA_COLL_BASE_TAG_NEIGHBOR_BASE - 2 * dim - 1 ,
81
86
comm , preqs ++ ));
82
87
if (OMPI_SUCCESS != rc ) break ;
83
88
}
@@ -104,7 +109,7 @@ mca_coll_basic_neighbor_alltoall_cart(const void *sbuf, int scount, struct ompi_
104
109
* a const for the send buffer. */
105
110
nreqs ++ ;
106
111
rc = MCA_PML_CALL (isend ((void * ) sbuf , scount , sdtype , srank ,
107
- MCA_COLL_BASE_TAG_ALLTOALL ,
112
+ MCA_COLL_BASE_TAG_NEIGHBOR_BASE - 2 * dim - 1 ,
108
113
MCA_PML_BASE_SEND_STANDARD ,
109
114
comm , preqs ++ ));
110
115
if (OMPI_SUCCESS != rc ) break ;
@@ -115,7 +120,7 @@ mca_coll_basic_neighbor_alltoall_cart(const void *sbuf, int scount, struct ompi_
115
120
if (MPI_PROC_NULL != drank ) {
116
121
nreqs ++ ;
117
122
rc = MCA_PML_CALL (isend ((void * ) sbuf , scount , sdtype , drank ,
118
- MCA_COLL_BASE_TAG_ALLTOALL ,
123
+ MCA_COLL_BASE_TAG_NEIGHBOR_BASE - 2 * dim ,
119
124
MCA_PML_BASE_SEND_STANDARD ,
120
125
comm , preqs ++ ));
121
126
if (OMPI_SUCCESS != rc ) break ;
0 commit comments