> Hello again,
>
> I just can't leave this one alone . . . I'm not sure what you had
> in mind for the displacements parameter. The current standard
> says that (e.g.) MPI_Scatterv has the same effect as if there
> were n calls to
>
> MPI_Send(sendbuf + displacements[i]*extent(sendtype), sendcounts[i],
> sendtype, i, . . . )
>
> If sendtype were changed to an array, then the obvious generalization
> would be
>
> MPI_Send(sendbuf + displacements[i]*extent(sendtype[i]), sendcounts[i],
> sendtype[i], i, . . . ),
>
> but it probably won't make any sense to measure the displacements in terms of
> extent(sendtype[i]). Sendtypes 0, 1, . . . , i-1 may not be expressible in
> convenient multiples of the ith type. I expect the only thing that will
> work here is bytes. That is, the effect of (the new and improved)
> MPI_Scatterv is the same as if there were n calls to
>
> MPI_Send( ((char*) sendbuf) + displacements[i], sendcounts[i],
> sendtype[i], i, . . . )
>
> Is this what you had in mind?
Displacements in bytes are one option (I probably got that wrong in my
example). Another possibility is to specify a "least common denominator"
datatype, and require that all other datatypes be built out of this datatype.
Thus, if we scatter from a matic of reals, the lcd datatype is MPI_REAL, all
other datatypes are built of reals, and displacements are in size_of_real.
>
> Regards,
> Peter Pacheco
> peter@usfca.edu
-------------------
Marc Snir
IBM T.J. Watson Research Center
P.O. Box 218, Yorktown Heights, NY 10598
email: snir@watson.ibm.com
phone: 914-945-3204
fax: 914-945-4425