From 081b6798810386ffdded93e65c005e9a97424eec Mon Sep 17 00:00:00 2001 From: Mike Dubman Date: Thu, 6 Feb 2014 08:38:32 +0000 Subject: [PATCH] OMPI: add call to del_procs fixed by AlexM, reviewed by miked cmr=v1.7.5:reviewer=ompi-rm1.7 This commit was SVN r30571. --- ompi/runtime/ompi_mpi_finalize.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/ompi/runtime/ompi_mpi_finalize.c b/ompi/runtime/ompi_mpi_finalize.c index 4b2e4531bd..0ec835a51e 100644 --- a/ompi/runtime/ompi_mpi_finalize.c +++ b/ompi/runtime/ompi_mpi_finalize.c @@ -94,6 +94,9 @@ int ompi_mpi_finalize(void) opal_list_item_t *item; struct timeval ompistart, ompistop; ompi_rte_collective_t *coll; + ompi_proc_t** procs; + size_t nprocs; + /* Be a bit social if an erroneous program calls MPI_FINALIZE in two different threads, otherwise we may deadlock in @@ -150,6 +153,18 @@ int ompi_mpi_finalize(void) MPI lifetime, to get better latency when not using TCP */ opal_progress_event_users_increment(); + + if (NULL == (procs = ompi_proc_world(&nprocs))) { + return OMPI_ERROR; + } + + if (OMPI_SUCCESS != (ret = MCA_PML_CALL(del_procs(procs, nprocs)))) { + free(procs); + return ret; + } + free(procs); + + /* check to see if we want timing information */ if (ompi_enable_timing != 0 && 0 == OMPI_PROC_MY_NAME->vpid) { gettimeofday(&ompistart, NULL);