MPI allows the user to do the following:
MPI_Isend( ..., &request ); MPI_Request_free( &request );The MPI implementation is required to complete the communication even though no MPI_Wait or MPI_Test will be called by the user for the request.
Providing for the above example can be handled in a number of ways, none of them entirely satisfactory. One is to have a list of ``abandoned'' requests that the ADI would check; that is, the ADI must check that the list is empty (which should be the usual case). Another is to add an acknowledgement to communications, allowing the system to find and remove requests when they are actually completed. In cases where the ADI is involved in the details of data exchange (rather than passing data to another layer), a simple reference count or even a marker that the user had freed the request could be used. This probably needs its own interface, to allow the device to adapt to what it needs. However, how this is implemented does not affect the design of the ADI, other than to have a mechanism for indicating an ``abandoned'' request. This is accomplished with MPID_Request_free, which serves, for the ADI, the same purpose as MPI_Request_free serves in the MPI implementation.