From 6e9d32f8c0cc3a96693829c8def3f41717600a55 Mon Sep 17 00:00:00 2001 From: Augustin Degomme Date: Sun, 27 May 2018 12:00:49 +0200 Subject: [PATCH] fix issue where some end of recv events were not generated whe MPI_STATUS_IGNORE was sent. --- src/smpi/bindings/smpi_pmpi_request.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/smpi/bindings/smpi_pmpi_request.cpp b/src/smpi/bindings/smpi_pmpi_request.cpp index e63ceef911..fa24998944 100644 --- a/src/smpi/bindings/smpi_pmpi_request.cpp +++ b/src/smpi/bindings/smpi_pmpi_request.cpp @@ -335,12 +335,15 @@ int PMPI_Recv(void *buf, int count, MPI_Datatype datatype, int src, int tag, MPI retval = MPI_SUCCESS; // the src may not have been known at the beginning of the recv (MPI_ANY_SOURCE) - if (status != MPI_STATUS_IGNORE) { - int src_traced = getPid(comm, status->MPI_SOURCE); - if (not TRACE_smpi_view_internals()) { - TRACE_smpi_recv(src_traced, my_proc_id, tag); - } + int src_traced=0; + if (status != MPI_STATUS_IGNORE) + src_traced = getPid(comm, status->MPI_SOURCE); + else + src_traced = getPid(comm, src); + if (not TRACE_smpi_view_internals()) { + TRACE_smpi_recv(src_traced, my_proc_id, tag); } + TRACE_smpi_comm_out(my_proc_id); } -- 2.20.1