MPI_STATUS_IGNORE implications

Steve Huss-Lederman (lederman@cs.wisc.edu)
Wed, 7 May 1997 09:17:47 -0500 (CDT)

I sent this to core and external since the issue of returning error
codes effects several chapters. The details after the first paragraph
are the implications for external.

A change toward the end of the last meeting was to allow passing
MPI_STATUS_IGNORE to MPI_GET_STATUS. We also clarified that
WAIT_{ALL|SOME} can still return MPI_ERR_IN_STATUS even if you gave
MPI_STATUSES_IGNORE. I believe this means that we wish to return the
error status in these cases but not any other information. Thus,
passing MPI_STATUS_IGNORE to MPI_GET_STATUS is a test for completion
and error code without getting other status info and allowing one to
get it later. I think one can also argue that the user didn't want
the error code but I don't think this is what the group went for.
Doing this would make such calls even cheaper.

To return the error code for a generalized request means calling the
query_fn even if MPI_STATUS_IGNORE is provided. The current text does
not allow this. The first change is to delete the sentence on
p. 3/21-23:

The callback function is not invoked if the user indicated that no
status needs be returned for this request, by supplying
\const{MPI\_STATUS\_IGNORE} or \const{MPI\_STATUSES\_IGNORE}.

And adding text at p. 3/41:

\begin{users}
If the user provided \const{MPI\_STATUS\_IGNORE} or
\const{MPI\_STATUSES\_IGNORE} to the \MPI/ function that causes the
\mpifunc{query\_fn} to be called, then \MPI/ will pass
\const{MPI\_STATUS\_IGNORE} to the \mpifunc{query\_fn}. In this case,
only the error code is returned (return value in C and C++ and in
\mpiarg{IERROR} in Fortran). Implementors of a \mpifunc{query\_fn}
should be careful to test for the case where \mpiarg{status} is
\const{MPI\_STATUS\_IGNORE} since accessing it as a normal status
handle is erroneous.
\end{users}