Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
These free's are buggy.
authorArnaud Giersch <arnaud.giersch@iut-bm.univ-fcomte.fr>
Wed, 1 Feb 2012 16:04:45 +0000 (17:04 +0100)
committerArnaud Giersch <arnaud.giersch@iut-bm.univ-fcomte.fr>
Wed, 1 Feb 2012 17:48:41 +0000 (18:48 +0100)
AFAICT, it's the responsibility of smpi_mpi_waitall to free the
requests.

src/smpi/smpi_coll.c

index 1c05340..7798de8 100644 (file)
@@ -118,9 +118,6 @@ static void tree_bcast(void *buf, int count, MPI_Datatype datatype,
   }
   smpi_mpi_startall(tree->numChildren, requests);
   smpi_mpi_waitall(tree->numChildren, requests, MPI_STATUS_IGNORE);
-  for (i = 0; i < tree->numChildren; i++){
-    xbt_free (requests[i]);
-  }
   xbt_free(requests);
 }
 
@@ -159,9 +156,6 @@ static void tree_antibcast(void *buf, int count, MPI_Datatype datatype,
   }
   smpi_mpi_startall(tree->numChildren, requests);
   smpi_mpi_waitall(tree->numChildren, requests, MPI_STATUS_IGNORE);
-  for (i = 0; i < tree->numChildren; i++){
-    xbt_free (requests[i]);
-  }
   xbt_free(requests);
 }