[97] | 1 | .\"Copyright 2006-2008 Sun Microsystems, Inc. |
---|
| 2 | .\" Copyright (c) 1996 Thinking Machines Corporation |
---|
| 3 | .TH MPI_Win_create_errhandler 3 "Dec 08, 2009" "1.4" "Open MPI" |
---|
| 4 | .SH NAME |
---|
| 5 | \fBMPI_Win_create_errhandler\fP \- Creates an error handler for a window. |
---|
| 6 | |
---|
| 7 | .SH SYNTAX |
---|
| 8 | .ft R |
---|
| 9 | .SH C Syntax |
---|
| 10 | .nf |
---|
| 11 | #include <mpi.h> |
---|
| 12 | int MPI_Win_create_errhandler(MPI_Win_errhandler_fn *\fIfunction\fP, |
---|
| 13 | MPI_Errhandler *\fIerrhandler\fP) |
---|
| 14 | |
---|
| 15 | .SH Fortran Syntax |
---|
| 16 | .nf |
---|
| 17 | INCLUDE 'mpif.h' |
---|
| 18 | MPI_WIN_CREATE_ERRHANDLER(\fIFUNCTION, ERRHANDLER, IERROR\fP) |
---|
| 19 | EXTERNAL \fIFUNCTION\fP |
---|
| 20 | INTEGER \fIERRHANDLER, IERROR\fP |
---|
| 21 | |
---|
| 22 | .SH C++ Syntax |
---|
| 23 | .nf |
---|
| 24 | #include <mpi.h> |
---|
| 25 | static MPI::Errhandler MPI::Win::Create_errhandler(MPI::Win:: |
---|
| 26 | Errhandler_fn* \fIfunction\fP) |
---|
| 27 | |
---|
| 28 | .SH INPUT PARAMETER |
---|
| 29 | .ft R |
---|
| 30 | .TP 1i |
---|
| 31 | function |
---|
| 32 | User-defined error-handling procedure (function). |
---|
| 33 | |
---|
| 34 | .SH OUTPUT PARAMETERS |
---|
| 35 | .ft R |
---|
| 36 | .TP 1i |
---|
| 37 | errhandler |
---|
| 38 | MPI error handler (handle). |
---|
| 39 | .TP 1i |
---|
| 40 | IERROR |
---|
| 41 | Fortran only: Error status (integer). |
---|
| 42 | |
---|
| 43 | .SH DESCRIPTION |
---|
| 44 | .ft R |
---|
| 45 | MPI_Win_create_errhandler should be, in C, a function of type MPI_Win_errhandler_fn, which is defined as |
---|
| 46 | .sp |
---|
| 47 | .nf |
---|
| 48 | typedef void MPI_Win_errhandler_fn(MPI Win *, int *, ...); |
---|
| 49 | .fi |
---|
| 50 | .sp |
---|
| 51 | The first argument is the window in use, the second is the error code to be returned. |
---|
| 52 | .sp |
---|
| 53 | In Fortran, the user routine should be of the form: |
---|
| 54 | .sp |
---|
| 55 | .nf |
---|
| 56 | SUBROUTINE WIN_ERRHANDLER_FN(WIN, ERROR_CODE, ...) |
---|
| 57 | INTEGER WIN, ERROR_CODE |
---|
| 58 | .fi |
---|
| 59 | .sp |
---|
| 60 | In C++, the user routine should be of the form: |
---|
| 61 | .sp |
---|
| 62 | .nf |
---|
| 63 | typedef void MPI::Win::Errhandler_fn(MPI::Win &, int *, ...); |
---|
| 64 | .fi |
---|
| 65 | |
---|
| 66 | .SH ERRORS |
---|
| 67 | Almost all MPI routines return an error value; C routines as the value of the function and Fortran routines in the last argument. C++ functions do not return errors. If the default error handler is set to MPI::ERRORS_THROW_EXCEPTIONS, then on error the C++ exception mechanism will be used to throw an MPI:Exception object. |
---|
| 68 | .sp |
---|
| 69 | Before the error value is returned, the current MPI error handler is |
---|
| 70 | called. By default, this error handler aborts the MPI job, except for I/O function errors. The error handler may be changed with MPI_Comm_set_errhandler; the predefined error handler MPI_ERRORS_RETURN may be used to cause error values to be returned. Note that MPI does not guarantee that an MPI program can continue past an error. |
---|
| 71 | |
---|