X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/57e7dcd49d4873f73dc0337e4f172bd169f77a44..25cc8f2c515534fee077ff6ef9a71b55bfc2786f:/src/smpi/smpi_comm.c diff --git a/src/smpi/smpi_comm.c b/src/smpi/smpi_comm.c index 70267cd79e..d49b858293 100644 --- a/src/smpi/smpi_comm.c +++ b/src/smpi/smpi_comm.c @@ -48,7 +48,6 @@ MPI_Comm smpi_comm_new(MPI_Group group) void smpi_comm_destroy(MPI_Comm comm) { - smpi_group_destroy(comm->group); xbt_free(comm); } @@ -67,6 +66,16 @@ int smpi_comm_rank(MPI_Comm comm) return smpi_group_rank(smpi_comm_group(comm), smpi_process_index()); } +void smpi_comm_get_name (MPI_Comm comm, char* name, int* len) +{ + if(comm == MPI_COMM_WORLD) { + strcpy(name, "WORLD"); + *len = 5; + } else { + *len = snprintf(name, MPI_MAX_NAME_STRING, "%p", comm); + } +} + MPI_Comm smpi_comm_split(MPI_Comm comm, int color, int key) { int system_tag = 666;