+/* Copyright (c) 2013-2014. The SimGrid Team.
+ * All rights reserved. */
+
+/* This program is free software; you can redistribute it and/or modify it
+ * under the terms of the license (GNU LGPL) which comes with this package. */
+
/*
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
* University Research and Technology
* University of Stuttgart. All rights reserved.
* Copyright (c) 2004-2005 The Regents of the University of California.
* All rights reserved.
- * $COPYRIGHT$
*
* Additional copyrights may follow
- *
- * $HEADER$
*/
#include "colls_private.h"
"smpi_coll_tuned_gather_ompi_binomial rank %d recv %d mycount = %d",
rank, bmtree->tree_next[i], mycount);
- smpi_mpi_recv(ptmp + total_recv*rextent, rcount*size-total_recv, rdtype,
+ smpi_mpi_recv(ptmp + total_recv*rextent, mycount, rdtype,
bmtree->tree_next[i], COLL_TAG_GATHER,
comm, &status);
/* other non-leaf nodes */
free(tempbuf);
}
+ xbt_free(bmtree);
return MPI_SUCCESS;
err_hndl:
/* wait all second segments to complete */
ret = smpi_mpi_waitall(size, reqs, MPI_STATUSES_IGNORE);
+ if (ret != MPI_SUCCESS) { line = __LINE__; goto error_hndl; }
free(reqs);
}