Nonblocking Broadcast (original) (raw)


PreviousUpNext
Up: Nonblocking Collective Operations Next: Example using MPI_IBCAST Previous: Nonblocking Barrier Synchronization

MPI_IBCAST(buffer, count, datatype, root, comm, request)
INOUT buffer starting address of buffer (choice)
IN count number of entries in buffer (non-negative integer)
IN datatype data type of buffer (handle)
IN root rank of broadcast root (integer)
IN comm communicator (handle)
OUT request communication request (handle)

int MPI_Ibcast(void* buffer, int count, MPI_Datatype datatype, int root, MPI_Comm comm, MPI_Request *request)

MPI_Ibcast(buffer, count, datatype, root, comm, request, ierror)
TYPE(*), DIMENSION(..), ASYNCHRONOUS :: buffer
INTEGER, INTENT(IN) :: count, root
TYPE(MPI_Datatype), INTENT(IN) :: datatype
TYPE(MPI_Comm), INTENT(IN) :: comm
TYPE(MPI_Request), INTENT(OUT) :: request
INTEGER, OPTIONAL, INTENT(OUT) :: ierror
MPI_IBCAST(BUFFER, COUNT, DATATYPE, ROOT, COMM, REQUEST, IERROR)
BUFFER(*)
INTEGER COUNT, DATATYPE, ROOT, COMM, REQUEST, IERROR

This call starts a nonblocking variant of MPI_BCAST (see Section Broadcast ).


PreviousUpNext
Up: Nonblocking Collective Operations Next: Example using MPI_IBCAST Previous: Nonblocking Barrier Synchronization


122.1. Example using MPI_IBCAST

PreviousUpNext
Up: Nonblocking Broadcast Next: Nonblocking Gather Previous: Nonblocking Broadcast

The example in this section uses an intracommunicator.

Example

Start a broadcast of 100 ints from process 0 to every process in the group, perform some computation on independent data, and then complete the outstanding broadcast operation.

MPI_Comm comm; 
int array1[100], array2[100]; 
int root=0; 
MPI_Request req; 
... 
MPI_Ibcast(array1, 100, MPI_INT, root, comm, &req); 
compute(array2, 100); 
MPI_Wait(&req, MPI_STATUS_IGNORE); 

PreviousUpNext
Up: Nonblocking Broadcast Next: Nonblocking Gather Previous: Nonblocking Broadcast


Return to MPI-3.1 Standard Index
Return to MPI Forum Home Page


(Unofficial) MPI-3.1 of June 4, 2015
HTML Generated on June 4, 2015