https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119014
--- Comment #20 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
C23 documents it in detail, and so does float.h:
/* The floating-point expression evaluation method. The precise
definitions of these values are generalised to include support for
the interchange and extended types defined in ISO/IEC TS 18661-3.
Prior to this (for C99/C11) the definitions were:
-1 indeterminate
0 evaluate all operations and constants just to the range and
precision of the type
1 evaluate operations and constants of type float and double
to the range and precision of the double type, evaluate
long double operations and constants to the range and
precision of the long double type
2 evaluate all operations and constants to the range and
precision of the long double type
The TS 18661-3 definitions are:
-1 indeterminate
0 evaluate all operations and constants, whose semantic type has
at most the range and precision of float, to the range and
precision of float; evaluate all other operations and constants
to the range and precision of the semantic type.
1 evaluate all operations and constants, whose semantic type has
at most the range and precision of double, to the range and
precision of double; evaluate all other operations and constants
to the range and precision of the semantic type.
2 evaluate all operations and constants, whose semantic type has
at most the range and precision of long double, to the range and
precision of long double; evaluate all other operations and
constants to the range and precision of the semantic type.
N where _FloatN is a supported interchange floating type
evaluate all operations and constants, whose semantic type has
at most the range and precision of the _FloatN type, to the
range and precision of the _FloatN type; evaluate all other
operations and constants to the range and precision of the
semantic type.
N + 1, where _FloatNx is a supported extended floating type
evaluate operations and constants, whose semantic type has at
most the range and precision of the _FloatNx type, to the range
and precision of the _FloatNx type; evaluate all other
operations and constants to the range and precision of the
So, only __FLT_EVAL_METHOD_TS_18661_3__ should be possibly 16 for
-fexcess-precision=16.