Error Handler Operations
Function Syntax
- Register a user routine function as an MPI error handler.
MPI_File_create_errhandler(MPI_File_errhandler_function *function, MPI_Errhandler *errhandler)
PMPI_File_create_errhandler(MPI_File_errhandler_function *function, MPI_Errhandler *errhandler)
- Pass an error code to an error handler.
MPI_File_call_errhandler(MPI_File fh, int errorcode)
PMPI_File_call_errhandler(MPI_File fh, int errorcode)
- Set an error handler for a file.
MPI_File_set_errhandler(MPI_File fh, MPI_Errhandler errhandler)
PMPI_File_set_errhandler(MPI_File fh, MPI_Errhandler errhandler)
- Get the error handler for a file.
MPI_File_get_errhandler(MPI_File fh, MPI_Errhandler *errhandler)
PMPI_File_get_errhandler(MPI_File fh, MPI_Errhandler *errhandler)
Parameters
Parameter |
Description |
Value Range |
Input/Output |
|---|---|---|---|
*function |
Custom error handler |
Non-empty |
Input |
*errhandler |
Destination address for storing the MPI error handler (handle) |
Non-empty |
Output |
fh |
File (handle) bound to an error handler handle |
Non-empty |
Input |
errorcode |
MPI error code |
Non-empty |
Input |
errhandler |
MPI error handler (handle) |
Non-empty |
Input |
Return Value
- Success: MPI_SUCCESS
- Failure: An error code is returned.
Error Code
Error Code |
Description |
|---|---|
MPI_ERR_FILE |
Invalid file handle |
MPI_ERR_ARG |
Other invalid arguments |
MPI_ERR_OTHER |
Other errors |
Notes
The correctness of custom error handlers remains the sole responsibility of the application.