On Wed, Nov 6, 2013 at 5:44 AM, FX <fxcoud...@gmail.com> 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 test for a signaling NaN using > the existing built-ins? __builtin_fpclassify() and __builtin_isnan() both > return the same thing for quite and signaling NaNs. We have a > __builtin_nans() function to generate a signaling NaN, but nothing to find > one. > > Am I missing something? Would it be hard to implement such a built-in?
Given how murky signaling NaNs are in practice, I think it's worth asking: why do you want to know? Ian