
3 Dec
2005
3 Dec
'05
11:01 a.m.
So go figure :-) Optimisation improves the compliance.... bizarre, anyway there are a whole heap of Optimisation options that probably change this behaviour. There is an entire man page for it separate from the main compiler one so I'll look through that to see which ones are important. I belive you can't actually tell at compile time if denormalised are supported like the code is doing I think you need:
if (std::numeric_limits<T>::has_denorm == std::denorm_present )
But thats on a brief inspection, may also want to test using denorm_min.
Thanks for the results, looks like I should check that the value isn't zero before assuming it's a denorm. And yes, I will test denorm_min as well. John.