MPI_Get
MPI_Get allows the calling process to retrieve data from another process, as long as the desired data are contained within the target window and the copied data fits in the origin (calling side) buffer. In essence, we're making a call to MPI_Irecv (non-blocking receive) without needing to wait for the other process to call MPI_Send.
- origin_addr
- address of the buffer to receive the data
- origin_count
- the number of entries in the origin buffer
- origin_datatype
- the datatype of each entry
- target_rank
- the rank of the target
- target_disp
- displacement from target window start to the beginning of the target buffer (target offset)
- target_count
- number of entries in the target buffer
- target_datatype
- datatype of each entry in the target buffer
- win
- the window object
Several arguments should be familiar from MPI_Send and MPI_Recv calls; for example, *_count and *_datatype are the same as in MPI_Send and MPI_Recv and specify the size and shape of the data to be moved. Group and communicator information are replaced with the MPI_Win object, which essentially holds references to those fields. Finally, target_rank is the identifier of the process from which data will be retrieved. It is important to note that the target_datatype is defined by the caller but must be interpreted by the target. This will only cause problems in a heterogeneous environment where non-portable datatypes are used. In an environment like Stampede2's, where all the processor architectures match exactly within a given queue, datatypes will be interpreted correctly by all processes.