3
3
* Copyright (c) 2004-2007 The Trustees of Indiana University and Indiana
4
4
* University Research and Technology
5
5
* Corporation. All rights reserved.
6
- * Copyright (c) 2004-2021 The University of Tennessee and The University
6
+ * Copyright (c) 2004-2022 The University of Tennessee and The University
7
7
* of Tennessee Research Foundation. All rights
8
8
* reserved.
9
9
* Copyright (c) 2004-2008 High Performance Computing Center Stuttgart,
@@ -53,7 +53,11 @@ struct ompi_isendrecv_context_t {
53
53
};
54
54
55
55
typedef struct ompi_isendrecv_context_t ompi_isendrecv_context_t ;
56
+ #if OMPI_BUILD_MPI_PROFILING
56
57
OBJ_CLASS_INSTANCE (ompi_isendrecv_context_t , opal_object_t , NULL , NULL );
58
+ #else
59
+ OBJ_CLASS_DECLARATION (ompi_isendrecv_context_t );
60
+ #endif /* OMPI_BUILD_MPI_PROFILING */
57
61
58
62
static int ompi_isendrecv_complete_func (ompi_comm_request_t * request )
59
63
{
@@ -66,7 +70,7 @@ static int ompi_isendrecv_complete_func (ompi_comm_request_t *request)
66
70
*
67
71
* Probably need to bring up in the MPI forum.
68
72
*/
69
-
73
+
70
74
if (MPI_PROC_NULL != context -> source ) {
71
75
OMPI_COPY_STATUS (& request -> super .req_status ,
72
76
context -> subreq [0 ]-> req_status , false);
@@ -129,21 +133,21 @@ int MPI_Isendrecv(const void *sendbuf, int sendcount, MPI_Datatype sendtype,
129
133
130
134
OMPI_ERRHANDLER_CHECK (rc , comm , rc , FUNC_NAME );
131
135
}
132
-
136
+
133
137
crequest = ompi_comm_request_get ();
134
138
if (NULL == crequest ) {
135
139
return OMPI_ERR_OUT_OF_RESOURCE ;
136
140
}
137
-
141
+
138
142
context = OBJ_NEW (ompi_isendrecv_context_t );
139
143
if (NULL == context ) {
140
144
ompi_comm_request_return (crequest );
141
145
return OMPI_ERR_OUT_OF_RESOURCE ;
142
146
}
143
147
144
148
crequest -> context = & context -> super ;
145
- context -> subreq [0 ] = NULL ;
146
- context -> subreq [1 ] = NULL ;
149
+ context -> subreq [0 ] = MPI_REQUEST_NULL ;
150
+ context -> subreq [1 ] = MPI_REQUEST_NULL ;
147
151
context -> source = source ;
148
152
149
153
if (source != MPI_PROC_NULL ) { /* post recv */
@@ -158,7 +162,7 @@ int MPI_Isendrecv(const void *sendbuf, int sendcount, MPI_Datatype sendtype,
158
162
159
163
if (dest != MPI_PROC_NULL ) { /* send */
160
164
rc = MCA_PML_CALL (isend (sendbuf , sendcount , sendtype , dest ,
161
- sendtag , MCA_PML_BASE_SEND_STANDARD , comm , & context -> subreq [nreqs ++ ]));
165
+ sendtag , MCA_PML_BASE_SEND_STANDARD , comm , & context -> subreq [nreqs ++ ]));
162
166
if (MPI_SUCCESS != rc ) {
163
167
OBJ_RELEASE (context );
164
168
ompi_comm_request_return (crequest );
0 commit comments