Re: Built-in testing for signaling nan?

2013-11-07 Thread N.M. Maclaren
On Nov 7 2013, FX wrote: Given how murky signaling NaNs are in practice, I think it's worth asking: why do you want to know? Because I am writing an implementation of the IEEE support modules in GNU Fortran, which are part of the Fortran 2003 standard. And the standard provides for a procedu

Re: Built-in testing for signaling nan?

2013-11-06 Thread FX
> Given how murky signaling NaNs are in practice, I think it's worth > asking: why do you want to know? Because I am writing an implementation of the IEEE support modules in GNU Fortran, which are part of the Fortran 2003 standard. And the standard provides for a procedure (IEEE_CLASS) to distin

Re: Built-in testing for signaling nan?

2013-11-06 Thread Ian Lance Taylor
On Wed, Nov 6, 2013 at 5:44 AM, FX wrote: > > GCC has a number of floating-point-related type-generic built-ins, which are > great and which we largely rely on in the gfortran runtime library (rather > than depending on the possibly poor-quality target math library). > > However, I have not been

Re: Built-in testing for signaling nan?

2013-11-06 Thread Joseph S. Myers
On Wed, 6 Nov 2013, N.M. Maclaren wrote: > > > Yes, due to the poor quality of the IEEE 754 specifications. In 1984, > > > the distinction was left completely unspecified (even in intent). In > > > 2008, there is a recommendation (no more) that the top bit of the payload > > > is used, with no s

Re: Built-in testing for signaling nan?

2013-11-06 Thread N.M. Maclaren
Yes, due to the poor quality of the IEEE 754 specifications. In 1984, the distinction was left completely unspecified (even in intent). In 2008, there is a recommendation (no more) that the top bit of the payload is used, with no specification of what to do if that is zero (which is the most obv

Re: Built-in testing for signaling nan?

2013-11-06 Thread Joseph S. Myers
On Wed, 6 Nov 2013, N.M. Maclaren wrote: > Yes, due to the poor quality of the IEEE 754 specifications. In 1984, > the distinction was left completely unspecified (even in intent). In > 2008, there is a recommendation (no more) that the top bit of the payload > is used, with no specification of

Re: Built-in testing for signaling nan?

2013-11-06 Thread N.M. Maclaren
On Nov 6 2013, FX wrote: GCC has a number of floating-point-related type-generic built-ins, which are great and which we largely rely on in the gfortran runtime library (rather than depending on the possibly poor-quality target math library). However, I have not been able to find a way to te

Re: Built-in testing for signaling nan?

2013-11-06 Thread Joseph S. Myers
On Wed, 6 Nov 2013, FX wrote: > GCC has a number of floating-point-related type-generic built-ins, which > are great and which we largely rely on in the gfortran runtime library > (rather than depending on the possibly poor-quality target math > library). > > However, I have not been able to f

Built-in testing for signaling nan?

2013-11-06 Thread FX
Hi all, GCC has a number of floating-point-related type-generic built-ins, which are great and which we largely rely on in the gfortran runtime library (rather than depending on the possibly poor-quality target math library). However, I have not been able to find a way to test for a signaling N