### Format of Eight-Byte Floating Point Data

IBM C and C++ Compilers conforms to IEEE format, in which a floating point number is represented in terms of sign (S), exponent (E), and fraction (F):

> (-1)S x 2E x 1.F

Type | double
Alignment | 4-byte aligned 8-byte aligned
Bit Mapping | In the internal representation, there is 1 bit for the sign (S), 11 bits for the exponent (E), and 52 bits for the fraction (F). The bits are mapped with the fraction in bit 0 to bit 51, the exponent in bit 52 to bit 62, and the sign in bit 63:
    6 66655555555
    3 21098765432
    S EEEEEEEEEEE

    5544444444443333333333222222222211111111110000000000
    1098765432109876543210987654321098765432109876543210
    FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
Read the lines vertically from top to bottom. For example, the third column of numbers shows that bit 61 is part of the exponent.``
Storage Mapping | In the following mapping, high memory is to the right.
byte 0 | byte 1 | byte 2 | ... | byte 5 | byte 6 | byte 7
--- | --- | --- | --- | --- | --- | ---
    76543210
      111111
    54321098
    22221111
    32109876
    ...
    44444444
    76543210
    55555544
    54321098
    66665555
    32109876
    FFFFFFFF
    FFFFFFFF
    FFFFFFFF
    ...
    FFFFFFFF
    EEEEFFFF
    SEEEEEEE

####

Data Mapping

Mapping of Fundamental Data Types
Mapping of Compound Data Types
Format of Four-Byte Floating Point Data
Format of Ten-Byte Floating Point Data in Sixteen Byte Fields