X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/9b73466ada27682d1729f394549479da83ef4a99..09601ee5e16b23f0b9e8f65c2c00b0cf2dd5d901:/teshsuite/smpi/mpich3-test/coll/alltoallw2.c diff --git a/teshsuite/smpi/mpich3-test/coll/alltoallw2.c b/teshsuite/smpi/mpich3-test/coll/alltoallw2.c index 7d40236f41..379cdaeed4 100644 --- a/teshsuite/smpi/mpich3-test/coll/alltoallw2.c +++ b/teshsuite/smpi/mpich3-test/coll/alltoallw2.c @@ -16,133 +16,133 @@ Because there are separate send and receive types to alltoallw, there need to be tests to rearrange data on the fly. Not done yet. - + The first test sends i items to processor i from all processors. Currently, the test uses only MPI_INT; this is adequate for testing systems that use point-to-point operations */ -int main( int argc, char **argv ) +int main(int argc, char **argv) { MPI_Comm comm; - int *sbuf, *rbuf; - int rank, size; - int *sendcounts, *recvcounts, *rdispls, *sdispls; - int i, j, *p, err; + int *sbuf, *rbuf; + int rank, size; + int *sendcounts, *recvcounts, *rdispls, *sdispls; + int i, j, *p, err; MPI_Datatype *sendtypes, *recvtypes; - - MTest_Init( &argc, &argv ); + + MTest_Init(&argc, &argv); err = 0; - - while (MTestGetIntracommGeneral( &comm, 2, 1 )) { - if (comm == MPI_COMM_NULL) continue; - - /* Create the buffer */ - MPI_Comm_size( comm, &size ); - MPI_Comm_rank( comm, &rank ); - sbuf = (int *)malloc( size * size * sizeof(int) ); - rbuf = (int *)malloc( size * size * sizeof(int) ); - if (!sbuf || !rbuf) { - fprintf( stderr, "Could not allocated buffers!\n" ); - MPI_Abort( comm, 1 ); - } - - /* Load up the buffers */ - for (i=0; i