[Mpi-comments] Error in MPI_Neighbor_alltoallw example?
Rajeev Thakur
thakur at mcs.anl.gov
Fri Dec 5 10:04:04 CST 2014
Yes, see https://svn.mpi-forum.org/trac/mpi-forum-web/ticket/420
Rajeev
On Dec 5, 2014, at 9:41 AM, Timothy Brown <Timothy.Brown-1 at Colorado.EDU> wrote:
> Hello.
>
> I was trying to use MPI_Neighbor_alltoallw() and was following the example on page 333 of the MPI-3.0 standard. However I believe the send and receive counts are incorrect. Lines 21 to 25:
>
> DO i=1,num_neigh
> sndcounts(i) = 100
> rcvcounts(i) = 100
> rcvtypes(i) = sndtypes(i)
> END DO
>
> Since the send/receive counts for 1 and 2 are vectors types of length 100, we should be sending/receiving only 1 type/element. As follows:
>
> sndcounts(1) = 1
> sndcounts(2) = 1
> sndcounts(3) = 100
> sndcounts(4) = 100
>
> rcvcounts = sndcounts
>
> Indeed if I compile the example as per the standard, I get data corruption.
>
> I couldn't find this in the errata published on May 14, 2014. However if it is a known mistake please ignore my comment.
>
> Regards
> Timothy Brown
> _______________________________________________
> mpi-comments mailing list
> mpi-comments at lists.mpi-forum.org
> http://lists.mpi-forum.org/mailman/listinfo.cgi/mpi-comments
More information about the mpi-comments
mailing list