RFR: Use isnan instead of isnanf

David Holmes david.holmes at oracle.com
Wed Apr 12 00:30:56 UTC 2017


Hi Mikael,

On 12/04/2017 9:04 AM, Mikael Vidstedt wrote:
>
> isnanf is not available in musl. posix says that isnan handles both float and double arguments (typically through a macro checking the size of the operand and delegation to the corresponding/actual isnan primitive).
>
> This change makes the two JDK wrapper macros call isnan instead of isnanf. I’ve tried to verify that the toolchains I have access to does the Right(tm) thing for float, but additional verification/testing is probably warranted before this is “productized”.
>
> hotspot: http://cr.openjdk.java.net/~mikael/webrevs/portola/isnan/webrev.00/hotspot/webrev/
> jdk: http://cr.openjdk.java.net/~mikael/webrevs/portola/isnan/webrev.00/jdk/webrev/

Are we building with C99 support enabled?

The feature test macros are shown as:

isnan():
   _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE || _ISOC99_SOURCE || 
_POSIX_C_SOURCE >= 200112L;
   or cc -std=c99

isnanf(), isnanl():
   _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE >= 600

On linux we don't seem to do anything to explicitly enable access to 
either of these ??

Thanks,
David

> Cheers,
> Mikael
>


More information about the portola-dev mailing list