[Ada] Tidy up implementation of System.Fat_Gen.Valid and inline it again

Pierre-Marie de Rodat derodat@adacore.com
Mon Dec 14 15:56:03 GMT 2020


Besides the improved commentary, the removal of superfluous subtypes and
other small tweaks throughout to make it more readable, this replaces the
use of T'Mantissa by the more appropriate T'Machine_Mantissa in the body
of System.Fat_Gen.Valid and also removes an unnecessary trick used to
distinguish zero from other denormalized numbers when T'Denorm is False.

This also inlines again the function, because it compiles to only a few
machine instructions for most architectures.

Tested on x86_64-pc-linux-gnu, committed on trunk

gcc/ada/

	* libgnat/s-fatgen.ads (Valid): Add again pragma Inline.
	* libgnat/s-fatgen.adb (Valid): Improve commentary, tidy up left
	and right, and remove superfluous trick for denormalized numbers.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-diff
Size: 10323 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20201214/04fcec94/attachment-0001.bin>


More information about the Gcc-patches mailing list