Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
memleaks --
authorAugustin Degomme <degomme@idpann.imag.fr>
Thu, 29 Aug 2013 12:36:20 +0000 (14:36 +0200)
committerAugustin Degomme <degomme@idpann.imag.fr>
Thu, 29 Aug 2013 12:41:11 +0000 (14:41 +0200)
src/smpi/colls/allgatherv-mpich-ring.c
src/smpi/colls/alltoall-simple.c
src/smpi/colls/reduce_scatter-mpich.c

index aeacb3f..83a07f8 100644 (file)
@@ -59,8 +59,8 @@ smpi_coll_tuned_allgatherv_mpich_ring(void *sendbuf, int sendcount,
   for (i = 1; i < comm_size; i++)
     if (min > recvcounts[i])
       min = recvcounts[i];
   for (i = 1; i < comm_size; i++)
     if (min > recvcounts[i])
       min = recvcounts[i];
-  if (min * recvtype_extent < 32768)
-    min = 32768 / recvtype_extent;
+  if (min * recvtype_extent < 32768*8)
+    min = 32768*8 / recvtype_extent;
   /* Handle the case where the datatype extent is larger than
    * the pipeline size. */
   if (!min)
   /* Handle the case where the datatype extent is larger than
    * the pipeline size. */
   if (!min)
index f6edcdc..1d813e4 100644 (file)
@@ -92,7 +92,7 @@ int smpi_coll_tuned_alltoall_simple(void *send_buff, int send_count,
 
 
   /* All done */
 
 
   /* All done */
-
+  for(i= 0;i<nreqs;i++)if(req[i])smpi_mpi_request_free(&req[i]);
   if (req)
     xbt_free((char *) req);
   if (statuses)
   if (req)
     xbt_free((char *) req);
   if (statuses)
index 8fb8342..586142b 100644 (file)
@@ -45,6 +45,7 @@ int smpi_coll_tuned_reduce_scatter_mpich_pair(void *sendbuf, void *recvbuf, int
     }
     
     if (total_count == 0) {
     }
     
     if (total_count == 0) {
+        xbt_free(disps);
         return MPI_ERR_COUNT;
     }
 
         return MPI_ERR_COUNT;
     }
 
@@ -134,7 +135,10 @@ int smpi_coll_tuned_reduce_scatter_mpich_pair(void *sendbuf, void *recvbuf, int
             if (mpi_errno) return(mpi_errno);
         }
     
             if (mpi_errno) return(mpi_errno);
         }
     
-return MPI_SUCCESS;
+        xbt_free(disps);
+        xbt_free(tmp_recvbuf);
+
+        return MPI_SUCCESS;
 }
     
 
 }