X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/d68dcbd4cd142d73e90ab9376c34a435c10e1dc6..c4000f89d4644c3d7ff6187a62a0930c4d53e683:/src/smpi/mpi/smpi_comm.cpp diff --git a/src/smpi/mpi/smpi_comm.cpp b/src/smpi/mpi/smpi_comm.cpp index af7bd41886..2a80d4cd06 100644 --- a/src/smpi/mpi/smpi_comm.cpp +++ b/src/smpi/mpi/smpi_comm.cpp @@ -265,10 +265,8 @@ void Comm::cleanup_smp(){ Comm::unref(intra_comm_); if (leaders_comm_ != MPI_COMM_NULL) Comm::unref(leaders_comm_); - if (non_uniform_map_ != nullptr) - xbt_free(non_uniform_map_); - if (leaders_map_ != nullptr) - delete[] leaders_map_; + xbt_free(non_uniform_map_); + delete[] leaders_map_; } void Comm::unref(Comm* comm){ @@ -491,6 +489,17 @@ void Comm::finish_rma_calls(){ } } +MPI_Comm Comm::split_type(int type, int key, MPI_Info info) +{ + if(type != MPI_COMM_TYPE_SHARED){ + return MPI_COMM_NULL; + } + this->init_smp(); + this->ref(); + this->get_intra_comm()->ref(); + return this->get_intra_comm(); +} + } }