267. External Data Representation: ``external32''

Up: File Interoperability Next: User-Defined Data Representations Previous: Datatypes for File Interoperability

All MPI implementations are required to support the data representation defined in this section. Support of optional datatypes (e.g., MPI_INTEGER2) is not required.

All floating point values are in big-endian IEEE format [27] of the appropriate size. Floating point values are represented by one of three IEEE formats. These are the IEEE ``Single,'' ``Double,'' and ``Double Extended'' formats, requiring 4, 8 and 16 bytes of storage, respectively. For the IEEE ``Double Extended'' formats, MPI specifies a Format Width of 16 bytes, with 15 exponent bits, bias = +16383, 112 fraction bits, and an encoding analogous to the ``Double'' format. All integral values are in two's complement big-endian format. Big-endian means most significant byte at lowest address byte. For C _Bool, Fortran LOGICAL and C++ bool, 0 implies false and nonzero implies true. C float _Complex, double _Complex and long double _Complex as well as Fortran COMPLEX and DOUBLE COMPLEX are represented by a pair of floating point format values for the real and imaginary components. Characters are in ISO 8859-1 format [28]. Wide characters (of type MPI_WCHAR) are in Unicode format [47].

All signed numerals (e.g., MPI_INT, MPI_REAL) have the sign bit at the most significant bit. MPI_COMPLEX and MPI_DOUBLE_COMPLEX have the sign bit of the real and imaginary parts at the most significant bit of each part.

According to IEEE specifications [27], the ``NaN'' (not a number) is system dependent. It should not be interpreted within MPI as anything other than ``NaN.''

Advice to implementors.

The MPI treatment of ``NaN'' is similar to the approach used in XDR (see ftp://ds.internic.net/rfc/rfc1832.txt). ( End of advice to implementors.)

All data is byte aligned, regardless of type. All data items are stored contiguously in the file (if the file view is contiguous).

Advice to implementors.

All bytes of LOGICAL and bool must be checked to determine the value. ( End of advice to implementors.)

Advice to users.

The type MPI_PACKED is treated as bytes and is not converted. The user should be aware that MPI_PACK has the option of placing a header in the beginning of the pack buffer. ( End of advice to users.)

``external32'' sizes of predefined datatypes

The size of the predefined datatypes returned from MPI_TYPE_CREATE_F90_REAL, MPI_TYPE_CREATE_F90_COMPLEX, and MPI_TYPE_CREATE_F90_INTEGER are defined in Section Additional Support for Fortran Numeric Intrinsic Types , page Parameterized Datatypes with Specified Precision and Exponent Range .

Advice to implementors.

When converting a larger size integer to a smaller size integer, only the less significant bytes are moved. Care must be taken to preserve the sign bit value. This allows no conversion errors if the data range is within the range of the smaller size integer. ( End of advice to implementors.)
Table External Data Representation: ``external32'' specifies the sizes of predefined datatypes in ``external32'' format.

Up: File Interoperability Next: User-Defined Data Representations Previous: Datatypes for File Interoperability

Return to MPI-2.2 Standard Index
Return to MPI Forum Home Page

(Unofficial) MPI-2.2 of September 4, 2009
HTML Generated on September 10, 2009