正在加载图片...
I Receiving a Message: MPl RECV C binding is shown below int MPI Recv(void *buf, int count, MPI Datatype dtype, int source, int tag, MPI Comm comm, MPI Status*status buf and status are output arguments the rest are inputs An error code is returned by the function Exam ple MP工Recv(c,10,MPI工NT,1,10,MP工 COMM WORLD,&stat); MPI Recv(&d,l, MPI DOUBLE,0, 19, Comml, &stat) Notes: A maximum of COUNT items of type DTYPE are accepted; if the message contains more, it is an error The sending and receiving processes must agree on the datatype; if they disagree, results are undefined(MPI does not check) When this routine returns, the received message data have been copied into the buffer; and the tag, source, and actual count of data received are available via the status argumentReceiving a Message: MPI_RECV • C binding is shown below. int MPI_Recv(void *buf, int count, MPI_Datatype dtype, int source, int tag, MPI_Comm comm, MPI_Status *status); – buf and status are output arguments; the rest are inputs. – An error code is returned by the function. Notes: • A maximum of COUNT items of type DTYPE are accepted; if the message contains more, it is an error. • The sending and receiving processes must agree on the datatype; if they disagree, results are undefined (MPI does not check). • When this routine returns, the received message data have been copied into the buffer; and the tag, source, and actual count of data received are available via the status argument. Example: MPI_Recv(c,10,MPI_INT,1,10,MPI_COMM_WORLD,&stat); MPI_Recv(&d,1,MPI_DOUBLE,0,19,Comm1,&stat);
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有