Expand description
The 80-bit extended format, because the field sends it.
Fast DDS and OpenDDS both map IDL long double to the compiler’s
long double and copy its sixteen bytes onto the wire. On x86-64
that type is the x87 double-extended format — one sign bit, a
fifteen-bit exponent biased by 16383, and a sixty-four-bit
significand with an explicit integer bit — padded to sixteen bytes
with six bytes the compiler never writes. Measured on Debian 13 /
gcc 14.2, 1.5L is
00 00 00 00 00 00 00 c0 ff 3f followed by six bytes of whatever the
stack held. On aarch64 the same source emits binary128 instead,
because there long double is binary128.
So the same vendor, the same IDL and the same value give two
different payloads on two architectures, and a third on a platform
where long double is double — macOS on Apple silicon, measured at
LDBL_MANT_DIG = 53. docs/float128-column.md §2 records the runs.
A binary128 type that could not read those bytes would be conformant
and useless. These conversions are how the reader meets the field
where it is; nothing here writes x87 unless a caller asks for it by
name, and Float128::to_x87_extended reports what a conversion
costs rather than performing it silently.
Structs§
- Extended80
- An x87 double-extended value: the ten bytes that carry it.
Functions§
- looks_
like_ x87 - Whether a sixteen-byte payload is plausibly x87 rather than binary128.