]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Document a few more characteristics of floating-point support
authorEric Botcazou <ebotcazou@adacore.com>
Mon, 18 Jan 2021 18:30:27 +0000 (19:30 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Thu, 6 May 2021 07:51:28 +0000 (03:51 -0400)
gcc/ada/

* doc/gnat_rm/implementation_defined_characteristics.rst (3.5.7):
Mention the IEEE standard explicitly.  Use current format names.
Document assumed rounding mode and new features of I/O support.
* gnat_rm.texi: Regenerate.

gcc/ada/doc/gnat_rm/implementation_defined_characteristics.rst
gcc/ada/gnat_rm.texi

index 10fcfc93c1d0330ddd42d6ccfe47b07cf5bad802..8d0be38d9aafd3498dbb191917ea7d44d781d8a7 100644 (file)
@@ -129,20 +129,29 @@ There are no nonstandard real types.
   "What combinations of requested decimal precision and range
   are supported for floating point types.  See 3.5.7(7)."
 
-The precision and range is as defined by the IEEE standard.
+The precision and range are defined by the IEEE Standard for Floating-Point
+Arithmetic (IEEE 754-2019).
 
 *
   "The predefined floating point types declared in
   ``Standard``.  See 3.5.7(16)."
 
-====================== ====================================================
+====================== ===============================================
 Type                   Representation
-====================== ====================================================
-*Short_Float*          32 bit IEEE short
-*Float*                (Short) 32 bit IEEE short
-*Long_Float*           64 bit IEEE long
-*Long_Long_Float*      64 bit IEEE long (80 bit IEEE long on x86 processors)
-====================== ====================================================
+====================== ===============================================
+*Short_Float*          IEEE Binary32 (Single)
+*Float*                IEEE Binary32 (Single)
+*Long_Float*           IEEE Binary64 (Double)
+*Long_Long_Float*      IEEE Binary64 (Double) on non-x86 architectures
+                       IEEE 80-bit Extended on x86 architecture
+====================== ===============================================
+
+The default rounding mode specified by the IEEE 754 Standard is assumed for
+static computations, i.e. round to nearest, ties to even. The input routines
+yield correctly rounded values for Short_Float, Float and Long_Float at least.
+The output routines can compute up to twice as many exact digits as the value
+of ``T'Digits`` for any type, for example 30 digits for Long_Float; if more
+digits are requested, zeros are printed.
 
 *
   "The small of an ordinary fixed point type.  See 3.5.9(8)."
index 9427dccf674e6c83ebb372e836f6b878121d28c6..569b9812eff89ad0f68dc3a5bf2a1cf3dfe3d79b 100644 (file)
@@ -15667,7 +15667,8 @@ There are no nonstandard real types.
 are supported for floating point types.  See 3.5.7(7)."
 @end itemize
 
-The precision and range is as defined by the IEEE standard.
+The precision and range are defined by the IEEE Standard for Floating-Point
+Arithmetic (IEEE 754-2019).
 
 
 @itemize *
@@ -15678,7 +15679,7 @@ The precision and range is as defined by the IEEE standard.
 @end itemize
 
 
-@multitable {xxxxxxxxxxxxxxxxxxxxxxxx} {xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
+@multitable {xxxxxxxxxxxxxxxxxxxxxxxx} {xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx} 
 @headitem
 
 Type
@@ -15693,7 +15694,7 @@ Representation
 
 @tab
 
-32 bit IEEE short
+IEEE Binary32 (Single)
 
 @item
 
@@ -15701,7 +15702,7 @@ Representation
 
 @tab
 
-(Short) 32 bit IEEE short
+IEEE Binary32 (Single)
 
 @item
 
@@ -15709,7 +15710,7 @@ Representation
 
 @tab
 
-64 bit IEEE long
+IEEE Binary64 (Double)
 
 @item
 
@@ -15717,11 +15718,19 @@ Representation
 
 @tab
 
-64 bit IEEE long (80 bit IEEE long on x86 processors)
+IEEE Binary64 (Double) on non-x86 architectures
+IEEE 80-bit Extended on x86 architecture
 
 @end multitable
 
 
+The default rounding mode specified by the IEEE 754 Standard is assumed for
+static computations, i.e. round to nearest, ties to even. The input routines
+yield correctly rounded values for Short_Float, Float and Long_Float at least.
+The output routines can compute up to twice as many exact digits as the value
+of @code{T'Digits} for any type, for example 30 digits for Long_Float; if more
+digits are requested, zeros are printed.
+
 
 @itemize *