Remove the memchecker macro in pml base request, used in req_wait.c, which actually is in the wrong place. Instead, one simple call from send_request_free and recv_request_free(already done) will do all the work, fast and clean.
This commit was SVN r18095.
Этот коммит содержится в:
родитель
3f0f09fd1f
Коммит
28746bbcdb
@ -25,7 +25,6 @@
|
||||
#include "ompi/class/ompi_free_list.h"
|
||||
#include "ompi/request/request.h"
|
||||
#include "ompi/datatype/convertor.h"
|
||||
#include "ompi/memchecker.h"
|
||||
|
||||
BEGIN_C_DECLS
|
||||
|
||||
@ -76,15 +75,6 @@ typedef struct mca_pml_base_request_t mca_pml_base_request_t;
|
||||
|
||||
OMPI_DECLSPEC OBJ_CLASS_DECLARATION(mca_pml_base_request_t);
|
||||
|
||||
static inline void MCA_PML_BASE_REQUEST_MEMCHECKER_DEFINED(mca_pml_base_request_t * req) {
|
||||
#if OMPI_WANT_MEMCHECKER
|
||||
memchecker_call(&opal_memchecker_base_mem_defined,
|
||||
req->req_addr,
|
||||
req->req_count,
|
||||
req->req_datatype);
|
||||
#endif
|
||||
}
|
||||
|
||||
END_C_DECLS
|
||||
|
||||
#endif
|
||||
|
@ -103,7 +103,10 @@ static int mca_pml_ob1_send_request_free(struct ompi_request_t** request)
|
||||
}
|
||||
|
||||
OPAL_THREAD_UNLOCK(&ompi_request_lock);
|
||||
|
||||
MEMCHECKER(
|
||||
memchecker_convertor_call(&opal_memchecker_base_mem_defined,
|
||||
&sendreq->req_send.req_base.req_convertor);
|
||||
);
|
||||
*request = MPI_REQUEST_NULL;
|
||||
return OMPI_SUCCESS;
|
||||
}
|
||||
|
@ -26,7 +26,6 @@
|
||||
#include "opal/runtime/opal_cr.h"
|
||||
#include "ompi/mca/crcp/crcp.h"
|
||||
#include "ompi/mca/pml/base/pml_base_request.h"
|
||||
#include "ompi/memchecker.h"
|
||||
|
||||
|
||||
int ompi_request_default_wait(
|
||||
@ -40,13 +39,7 @@ int ompi_request_default_wait(
|
||||
#if OPAL_ENABLE_FT == 1
|
||||
OMPI_CRCP_REQUEST_COMPLETE(req);
|
||||
#endif
|
||||
|
||||
MEMCHECKER(
|
||||
if (req->req_state != OMPI_REQUEST_INACTIVE) {
|
||||
MCA_PML_BASE_REQUEST_MEMCHECKER_DEFINED((mca_pml_base_request_t*) req);
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
/* return status. If it's a generalized request, we *have* to
|
||||
invoke the query_fn, even if the user procided STATUS_IGNORE.
|
||||
MPI-2:8.2. */
|
||||
@ -209,17 +202,6 @@ finished:
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
MEMCHECKER(
|
||||
rptr = requests;
|
||||
for (i = 0; i < count; i++, rptr++) {
|
||||
request = *rptr;
|
||||
if ((true == request->req_complete) &&
|
||||
(OMPI_REQUEST_INACTIVE != request->req_state)) {
|
||||
MCA_PML_BASE_REQUEST_MEMCHECKER_DEFINED((mca_pml_base_request_t*) request);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
return rc;
|
||||
}
|
||||
@ -304,17 +286,6 @@ int ompi_request_default_wait_all( size_t count,
|
||||
}
|
||||
#endif
|
||||
|
||||
MEMCHECKER(
|
||||
rptr = requests;
|
||||
for (i = 0; i < count; i++, rptr++) {
|
||||
request = *rptr;
|
||||
if ((true == request->req_complete) &&
|
||||
(OMPI_REQUEST_INACTIVE != request->req_state)) {
|
||||
MCA_PML_BASE_REQUEST_MEMCHECKER_DEFINED((mca_pml_base_request_t*) request);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
rptr = requests;
|
||||
if (MPI_STATUSES_IGNORE != statuses) {
|
||||
/* fill out status and free request if required */
|
||||
@ -483,17 +454,6 @@ finished:
|
||||
}
|
||||
#endif
|
||||
|
||||
MEMCHECKER(
|
||||
rptr = requests;
|
||||
for (i = 0; i < count; i++, rptr++) {
|
||||
request = *rptr;
|
||||
if ((true == request->req_complete) &&
|
||||
(OMPI_REQUEST_INACTIVE != request->req_state)) {
|
||||
MCA_PML_BASE_REQUEST_MEMCHECKER_DEFINED((mca_pml_base_request_t*) request);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
if(num_requests_null_inactive == count) {
|
||||
*outcount = MPI_UNDEFINED;
|
||||
} else {
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user