[97] | 1 | .\"Copyright 2006-2008 Sun Microsystems, Inc. |
---|
| 2 | .\" Copyright (c) 1996 Thinking Machines Corporation |
---|
| 3 | .TH MPI_File_iwrite_at 3 "Dec 08, 2009" "1.4" "Open MPI" |
---|
| 4 | .SH NAME |
---|
| 5 | \fBMPI_File_iwrite_at\fP \- Writes a file at an explicitly specified offset (nonblocking, noncollective). |
---|
| 6 | |
---|
| 7 | .SH SYNTAX |
---|
| 8 | .ft R |
---|
| 9 | .nf |
---|
| 10 | C Syntax |
---|
| 11 | #include <mpi.h> |
---|
| 12 | int MPI_File_iwrite_at(MPI_File \fIfh\fP, MPI_Offset \fIoffset\fP, |
---|
| 13 | void \fI*buf\fP, int \fIcount\fP, MPI_Datatype \fIdatatype\fP, MPI_Request \fI*request\fP) |
---|
| 14 | |
---|
| 15 | Fortran Syntax (see FORTRAN 77 NOTES) |
---|
| 16 | INCLUDE 'mpif.h' |
---|
| 17 | MPI_FILE_IWRITE_AT(\fIFH\fP, \fIOFFSET\fP, \fIBUF\fP, \fICOUNT\fP, \fIDATATYPE\fP, \fIREQUEST\fP, \fIIERROR\fP) |
---|
| 18 | <type> \fIBUF\fP(*) |
---|
| 19 | INTEGER \fIFH, COUNT, DATATYPE, REQUEST, IERROR\fP |
---|
| 20 | INTEGER(KIND=MPI_OFFSET_KIND) \fIOFFSET\fP |
---|
| 21 | |
---|
| 22 | .SH C++ Syntax |
---|
| 23 | .nf |
---|
| 24 | #include <mpi.h> |
---|
| 25 | MPI::Request MPI::File::Iwrite_at(MPI::Offset \fIoffset\fP, const void* \fIbuf\fP, |
---|
| 26 | int \fIcount\fP, const MPI::Datatype& \fIdatatype\fP) |
---|
| 27 | |
---|
| 28 | .SH INPUT/OUTPUT PARAMETER |
---|
| 29 | .ft R |
---|
| 30 | .TP 1i |
---|
| 31 | fh |
---|
| 32 | File handle (handle). |
---|
| 33 | |
---|
| 34 | .SH INPUT PARAMETERS |
---|
| 35 | .ft R |
---|
| 36 | .TP 1i |
---|
| 37 | offset |
---|
| 38 | File offset (integer). |
---|
| 39 | .ft R |
---|
| 40 | .TP 1i |
---|
| 41 | buf |
---|
| 42 | Initial address of buffer (choice). |
---|
| 43 | .ft R |
---|
| 44 | .TP 1i |
---|
| 45 | count |
---|
| 46 | Number of elements in buffer (integer). |
---|
| 47 | .ft R |
---|
| 48 | .TP 1i |
---|
| 49 | datatype |
---|
| 50 | Data type of each buffer element (handle). |
---|
| 51 | |
---|
| 52 | .SH OUTPUT PARAMETERS |
---|
| 53 | .ft R |
---|
| 54 | .TP 1i |
---|
| 55 | request |
---|
| 56 | Request object (handle). |
---|
| 57 | .TP 1i |
---|
| 58 | IERROR |
---|
| 59 | Fortran only: Error status (integer). |
---|
| 60 | |
---|
| 61 | .SH DESCRIPTION |
---|
| 62 | .ft R |
---|
| 63 | MPI_File_iwrite_at is a nonblocking version of MPI_File_write_at. It attempts to write into the file associated with |
---|
| 64 | .I fh |
---|
| 65 | (at the |
---|
| 66 | .I offset |
---|
| 67 | position) a total number of |
---|
| 68 | .I count |
---|
| 69 | data items having |
---|
| 70 | .I datatype |
---|
| 71 | type from the user's buffer |
---|
| 72 | .I buf. |
---|
| 73 | The offset is in |
---|
| 74 | .I etype |
---|
| 75 | units relative to the current view. That is, holes are not counted |
---|
| 76 | when locating an offset. The data is written into those parts of the |
---|
| 77 | file specified by the current view. MPI_File_iwrite_at stores the |
---|
| 78 | number of |
---|
| 79 | .I datatype |
---|
| 80 | elements actually written in |
---|
| 81 | .I status. |
---|
| 82 | All other fields of |
---|
| 83 | .I status |
---|
| 84 | are undefined. The request structure can be passed to MPI_Wait or MPI_Test, which will return a status with the number of bytes actually accessed. |
---|
| 85 | .sp |
---|
| 86 | It is erroneous to call this function if MPI_MODE_SEQENTIAL mode was specified when the file was open. |
---|
| 87 | |
---|
| 88 | .SH FORTRAN 77 NOTES |
---|
| 89 | .ft R |
---|
| 90 | The MPI standard prescribes portable Fortran syntax for |
---|
| 91 | the \fIOFFSET\fP argument only for Fortran 90. FORTRAN 77 |
---|
| 92 | users may use the non-portable syntax |
---|
| 93 | .sp |
---|
| 94 | .nf |
---|
| 95 | INTEGER*MPI_OFFSET_KIND \fIOFFSET\fP |
---|
| 96 | .fi |
---|
| 97 | .sp |
---|
| 98 | where MPI_OFFSET_KIND is a constant defined in mpif.h |
---|
| 99 | and gives the length of the declared integer in bytes. |
---|
| 100 | |
---|
| 101 | .SH ERRORS |
---|
| 102 | 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. |
---|
| 103 | .sp |
---|
| 104 | Before the error value is returned, the current MPI error handler is |
---|
| 105 | called. For MPI I/O function errors, the default error handler is set to MPI_ERRORS_RETURN. The error handler may be changed with MPI_File_set_errhandler; the predefined error handler MPI_ERRORS_ARE_FATAL may be used to make I/O errors fatal. Note that MPI does not guarantee that an MPI program can continue past an error. |
---|
| 106 | |
---|