LAM/MPI logo

LAM/MPI General User's Mailing List Archives

  |   Home   |   Download   |   Documentation   |   FAQ   |   all just in this list

From: Jeff Squyres (jsquyres_at_[hidden])
Date: 2005-10-18 07:09:57


On Oct 18, 2005, at 4:53 AM, wakun wrote:

> Thanks. I understand now. But may I ask another question, as you
> mentioned above, will all the nodes calling MPI_Reduce send the entire
> buffer or just the data specified by CSData be sent?

Just as with any MPI communications function, MPI will only send the
data as indicated by the count and datatype on the sender. In other
words, MPI only knows what you tell it -- and you've only told it the
count, the datatype, and the starting pointer. So yes, it will only
send "count" instances of the data represented by CSData in your
example.

You should probably read a full description of MPI_REDUCE and MPI's
reduction operations:

        http://www.mpi-forum.org/docs/mpi-11-html/node76.html#Node76

-- 
{+} Jeff Squyres
{+} The Open MPI Project
{+} http://www.open-mpi.org/