


| MPI_ABORT(comm, errorcode) | |
| IN comm | communicator of MPI processes to abort (handle) | 
| IN errorcode | error code to return to invoking environment (integer) | 
This routine makes a ``best attempt'' to abort all MPI processes in the group of comm. This function does not require that the invoking environment take any action with the error code. However, a Unix or POSIX environment should handle this as a return errorcode from the main program.
It may not be possible for an MPI implementation to abort only the processes represented by comm if this is a subset of the processes. In this case, the MPI implementation should attempt to abort all the connected processes but should not abort any unconnected processes. When using the World Model, and if no processes were spawned, accepted, or connected then this has the effect of aborting all the processes associated with MPI_COMM_WORLD. In the case of the Sessions Model, if an MPI process has instantiated multiple sessions, the union of the process sets in these sessions are considered connected processes. Thus invoking MPI_ABORT on a communicator derived from one of these sessions will result in all MPI processes in this union being aborted.
 
 
 
 Advice  
        to implementors.  
 
After aborting a subset of processes, a high quality implementation should  
    be able to provide error handling for communicators, windows, and files  
    involving both aborted and nonaborted processes. As an example, if the  
    user changes the error handler for  MPI_COMM_WORLD to  
     MPI_ERRORS_RETURN or a custom error handler, when a subset of  
     MPI_COMM_WORLD is aborted, the remaining processes in  
     MPI_COMM_WORLD should be able to continue communicating with each  
    other and receive an appropriate error code when attempting communication  
    with an aborted process (e.g., an error of class  MPI_ERR_PROC_ABORTED).  
    A high quality implementation should support  
    equivalent behavior for communicators derived from sessions.  
 ( End of advice to implementors.) 
 
 
 
 Advice to users.  
 
Whether the  errorcode is returned from the executable or from the  
 MPI process startup mechanism (e.g., mpiexec), is an aspect of quality  
of the  MPI library but not mandatory.  
 ( End of advice to users.) 
 
 
 
 Advice  
        to implementors.  
 
Where possible, a high-quality implementation will try to return the  
 errorcode from the  MPI process startup mechanism  
(e.g. mpiexec or singleton init).  
 ( End of advice to implementors.) 
 


