MPI学习(四)-广播、散播、收集、归约和全归约的MPI语法
MPI-广播、散播、收集、归约和全归约的MPI语法
广播:MPI_Bcast
 | int MPI_Bcast(void *buffer, int count, MPI_Datatype datatype, int root, MPI_Comm comm)
 
 
  | 

散播:MPI_Scatter
 | int MPI_Scatter(void *sendbuf, int sendcount, MPI_Datatype sendtype, void *recvbuf, int root, MPI_Comm comm)
 
 
 
 
  | 

收集:MPI_Gather
 | int MPI_Gather(void *sendbuf, int sendcount, MPI_Datatype sendtype, void *recvbuf, int recvcount, MPI_Datatype recvtype, int root, MPI_Comm comm)
 
  | 

归约:MPI_Reduce
 | int MPI_Reduce(void *sendbuf, void *recvbuf, int count, MPI_Datatype datatype, MPI_Op op, int root,  MPI_Comm comm)
 
 
  | 


全归约:MPI_Allreduce
 | int MPI_Allreduce(void *sendbuf, void *recvbuf, int count, MPI_Datatype datatype, MPI_Op op, MPI_Comm comm)
 
  | 
