33 * Copyright (c) 2004-2007 The Trustees of Indiana University and Indiana
44 * University Research and Technology
55 * 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
77 * of Tennessee Research Foundation. All rights
88 * reserved.
99 * Copyright (c) 2004-2008 High Performance Computing Center Stuttgart,
@@ -53,7 +53,11 @@ struct ompi_isendrecv_context_t {
5353};
5454
5555typedef struct ompi_isendrecv_context_t ompi_isendrecv_context_t ;
56+ #if OMPI_BUILD_MPI_PROFILING
5657OBJ_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 */
5761
5862static int ompi_isendrecv_complete_func (ompi_comm_request_t * request )
5963{
@@ -66,7 +70,7 @@ static int ompi_isendrecv_complete_func (ompi_comm_request_t *request)
6670 *
6771 * Probably need to bring up in the MPI forum.
6872 */
69-
73+
7074 if (MPI_PROC_NULL != context -> source ) {
7175 OMPI_COPY_STATUS (& request -> super .req_status ,
7276 context -> subreq [0 ]-> req_status , false);
@@ -129,21 +133,21 @@ int MPI_Isendrecv(const void *sendbuf, int sendcount, MPI_Datatype sendtype,
129133
130134 OMPI_ERRHANDLER_CHECK (rc , comm , rc , FUNC_NAME );
131135 }
132-
136+
133137 crequest = ompi_comm_request_get ();
134138 if (NULL == crequest ) {
135139 return OMPI_ERR_OUT_OF_RESOURCE ;
136140 }
137-
141+
138142 context = OBJ_NEW (ompi_isendrecv_context_t );
139143 if (NULL == context ) {
140144 ompi_comm_request_return (crequest );
141145 return OMPI_ERR_OUT_OF_RESOURCE ;
142146 }
143147
144148 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 ;
147151 context -> source = source ;
148152
149153 if (source != MPI_PROC_NULL ) { /* post recv */
@@ -158,7 +162,7 @@ int MPI_Isendrecv(const void *sendbuf, int sendcount, MPI_Datatype sendtype,
158162
159163 if (dest != MPI_PROC_NULL ) { /* send */
160164 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 ++ ]));
162166 if (MPI_SUCCESS != rc ) {
163167 OBJ_RELEASE (context );
164168 ompi_comm_request_return (crequest );
0 commit comments