-/* Copyright (c) 2007-2015. The SimGrid Team.
- * All rights reserved. */
+/* Copyright (c) 2007-2017. 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. */
Request::startall(size - 1, requests);
Request::waitall(size - 1, requests, MPI_STATUS_IGNORE);
for (int src = 0; src < size-1; src++) {
- Request::unuse(&requests[src]);
+ Request::unref(&requests[src]);
}
xbt_free(requests);
}
Request::startall(size - 1, requests);
Request::waitall(size - 1, requests, MPI_STATUS_IGNORE);
for (int src = 0; src < size-1; src++) {
- Request::unuse(&requests[src]);
+ Request::unref(&requests[src]);
}
xbt_free(requests);
}
Request::startall(2 * (size - 1), requests);
Request::waitall(2 * (size - 1), requests, MPI_STATUS_IGNORE);
for (int other = 0; other < 2*(size-1); other++) {
- Request::unuse(&requests[other]);
+ Request::unref(&requests[other]);
}
xbt_free(requests);
}
Request::startall(2 * (size - 1), requests);
Request::waitall(2 * (size - 1), requests, MPI_STATUS_IGNORE);
for (int other = 0; other < 2*(size-1); other++) {
- Request::unuse(&requests[other]);
+ Request::unref(&requests[other]);
}
xbt_free(requests);
}
Request::startall(size - 1, requests);
Request::waitall(size - 1, requests, MPI_STATUS_IGNORE);
for (int dst = 0; dst < size-1; dst++) {
- Request::unuse(&requests[dst]);
+ Request::unref(&requests[dst]);
}
xbt_free(requests);
}
Request::startall(size - 1, requests);
Request::waitall(size - 1, requests, MPI_STATUS_IGNORE);
for (int dst = 0; dst < size-1; dst++) {
- Request::unuse(&requests[dst]);
+ Request::unref(&requests[dst]);
}
xbt_free(requests);
}
if(index == MPI_UNDEFINED) {
break;
}else{
- Request::unuse(&requests[index]);
+ Request::unref(&requests[index]);
}
- if(op) /* op can be MPI_OP_NULL that does nothing */
- if(op!=MPI_OP_NULL) op->apply( tmpbufs[index], recvbuf, &count, datatype);
+ if (op != MPI_OP_NULL) /* op can be MPI_OP_NULL that does nothing */
+ op->apply(tmpbufs[index], recvbuf, &count, datatype);
}
for(index = 0; index < size - 1; index++) {
smpi_free_tmp_buffer(tmpbufs[index]);
if(index == MPI_UNDEFINED) {
break;
}
- if(index < rank) {
- // #Request is below rank: it's a irecv
- if(op!=MPI_OP_NULL) op->apply( tmpbufs[index], recvbuf, &count, datatype);
- }
+ if (index < rank)
+ // #Request is below rank: it's a irecv.
+ op->apply(tmpbufs[index], recvbuf, &count, datatype);
}
}else{
//non commutative case, wait in order
for (int other = 0; other < size - 1; other++) {
Request::wait(&(requests[other]), MPI_STATUS_IGNORE);
- if(index < rank) {
- if(op!=MPI_OP_NULL) op->apply( tmpbufs[other], recvbuf, &count, datatype);
- }
+ if (index < rank && op != MPI_OP_NULL)
+ op->apply(tmpbufs[other], recvbuf, &count, datatype);
}
}
for(index = 0; index < rank; index++) {
smpi_free_tmp_buffer(tmpbufs[index]);
}
for(index = 0; index < size-1; index++) {
- Request::unuse(&requests[index]);
+ Request::unref(&requests[index]);
}
xbt_free(tmpbufs);
xbt_free(requests);
smpi_free_tmp_buffer(tmpbufs[index]);
}
for(index = 0; index < size-1; index++) {
- Request::unuse(&requests[index]);
+ Request::unref(&requests[index]);
}
xbt_free(tmpbufs);
xbt_free(requests);