From: Christian Heinrich Date: Tue, 27 Mar 2018 09:24:28 +0000 (+0200) Subject: [SMPI] Replay: Cleanup WaitAction a bit X-Git-Tag: v3.20~600^2~19 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/04048ece1f04e168f88227a87410ef0eaecb2845?ds=sidebyside [SMPI] Replay: Cleanup WaitAction a bit --- diff --git a/src/smpi/internals/smpi_replay.cpp b/src/smpi/internals/smpi_replay.cpp index 6865c2fc65..48616908ab 100644 --- a/src/smpi/internals/smpi_replay.cpp +++ b/src/smpi/internals/smpi_replay.cpp @@ -143,9 +143,10 @@ public: int rank = request->comm() != MPI_COMM_NULL ? request->comm()->rank() : -1; - MPI_Group group = request->comm()->group(); - int src_traced = group->rank(request->src()); - int dst_traced = group->rank(request->dst()); + // Must be taken before Request::wait() since the request may be set to + // MPI_REQUEST_NULL by Request::wait! + int src = request->comm()->group()->rank(request->src()); + int dst = request->comm()->group()->rank(request->dst()); bool is_wait_for_receive = (request->flags() & RECV); // TODO: Here we take the rank while we normally take the process id (look for my_proc_id) TRACE_smpi_comm_in(rank, __FUNCTION__, new simgrid::instr::NoOpTIData("wait"));