[ODE] [Fwd: Re: 0.6-RC1 is Released]

Jaroslav Sinecky sinecky at telefonica.net
Thu May 25 08:37:07 MST 2006


Resending to list ...

-------- Original Message --------
Subject: 	Re: [ODE] 0.6-RC1 is Released
Date: 	Thu, 25 May 2006 11:33:09 +0200
From: 	Jaroslav Sinecky <sinecky at telefonica.net>
Reply-To: 	jsinecky at tiscali.cz
To: 	Bram Stolk <bram at sara.nl>
References: 
<DBA08B6C105D63418EA89BA6A5B1E07503726FEF at cole.ad.nps.navy.mil> 
<b60bb5ae0605241246u1d558e74g3e23c02e07cf08fa at mail.gmail.com> 
<4474C1F3.8000002 at aeongames.com> <44756740.4000806 at sara.nl>



Seems like there is no isnanf in MSVC, I only see _isnan(double), but 
don't know if we can use it cause I'm not sure what happens when you 
convert isnan float to double.
Also, I see this in opcode:

   #define IR(x)                    ((udword&)(x))
...
   inline_ bool IsNAN(float value)  { return (IR(value)&0x7f800000) == 0x7f800000;    }

Jaroslav


Bram Stolk wrote:
> Rodrigo Hernandez wrote:
>
>   
>> There are 3 Versions:
>>
>> HAS___ISNANF means use __isnanf
>> HAS__ISNANF means use _isnanf
>> HAS_ISNANF means use isnanf
>>
>> I am not sure which one VC++ uses, probably one of the later 2, you may 
>> replace the default one in common.h to use whichever VC++ uses too.
>>     
>
> I thought that the default VC was the _isnanf variant?
> If that is so, the common.h looks good to me:
>
> #ifdef HAVE___ISNANF
> #define dIsNan(x) (__isnanf(x))
> #elif defined(HAVE__ISNANF)
> #define dIsNan(x) (_isnanf(x))
> #elif defined(HAVE_ISNANF)
> #define dIsNan(x) (isnanf(x))
> #else
>    /*
>       fall back to _isnanf which is the VC way,
>       this may seem redundant since we already checked
>       for _isnan before, but if isnan is detected by
>       configure but is not found during compilation
>       we should always make sure we check for __isnanf,
>       _isnan and isnan in that order before falling
>       back to a default
>    */
> #define dIsNan(x) (_isnanf(x))
> #endif
>
> Because:
> If I grep on NAN in build/config-default.h I get no matches,
> so it should be using _isnanf()
>
> This is weird...
> If we can't solve this, I'll yank the asserts from
> test_basket.
> The isnan was only used as paranoia asserting there.
> (Which normally is a good thing, but not if isnan is
>   unreliable)
>
>    Bram
>
>
>
>   
>> Cheers.
>> _______________________________________________
>> ODE mailing list
>> ODE at q12.org
>> http://q12.org/mailman/listinfo/ode
>>     
>
> _______________________________________________
> ODE mailing list
> ODE at q12.org
> http://q12.org/mailman/listinfo/ode
>
>   




More information about the ODE mailing list