A corresponding send() should be evoked at the corresponding rank
rank.source.
These are high level S4 methods. By default, check.type is TRUE
and an additional send()/recv() will make a handshaking call first,
then deliver the data next.
i.e. an integer vector of length two (type and length)
will be deliver first between send() and recv() to ensure
a buffer (of right type and right size/length) is properly allocated at
the rank.dest side.
Currently, four data types are considered: integer, double,
raw/byte, and default/raw.object. The default method will
make a serialize() call first to convert the general R object into
a raw vector before sending it away. After the raw vector
is received at the rank.dest side, the vector will be
unserialize() back to the R object format.
check.type set as FALSE will stop the additional
handhsaking call, but the buffer should be prepared carefully
by the user self. This is typically for the advanced users and
more specifically calls are needed. i.e. calling those
spmd.send.integer with spmd.recv.integer correspondingly.
check.type also needs to be set as FALSE for more efficient
calls such as isend()/recv() or send()/irecv(). Currently,
no check types are implemented in those mixed calls.