MPI_BUFFER_ATTACH, MPI_Buffer_attach Purpose Provides MPI with a buffer to use for buffering messages sent with MPI_BSEND and MPI_IBSEND. C synopsis #include int MPI_Buffer_attach(void* buffer,int size); C++ synopsis #include mpi.h void MPI::Attach_buffer(void* buffer, int size); FORTRAN synopsis include 'mpif.h' or use mpi MPI_BUFFER_ATTACH(CHOICE BUFFER,INTEGER SIZE,INTEGER IERROR) Description This subroutine provides MPI a buffer in the user's memory which is used for buffering outgoing messages. This buffer is used only by messages sent in buffered mode, and only one buffer is attached to a task at any time. Parameters buffer is the initial buffer address (choice) (IN) size is the buffer size in bytes (integer) (IN) IERROR is the FORTRAN return code. It is always the last argument. Notes MPI uses part of the buffer space to store information about the buffered messages. The number of bytes required by MPI for each buffered message is given by MPI_BSEND_OVERHEAD. If a buffer is already attached, it must be detached by MPI_BUFFER_DETACH before a new buffer can be attached. Errors Invalid size size < 0 Buffer is already attached MPI not initialized MPI already finalized Related information MPI_BSEND MPI_BUFFER_DETACH MPI_IBSEND