Ok.  Please apply. Important is here that we don't normalize NaN/Inf.
I did so for pow, and well, it caused some troubles.

Thanks,
Kai

2016-08-22 15:41 GMT+02:00 Martin Storsjö <mar...@martin.st>:
> rintl doesn't need changes since it calls rint().
> ---
>  mingw-w64-crt/math/rint.c  | 2 ++
>  mingw-w64-crt/math/rintf.c | 2 ++
>  2 files changed, 4 insertions(+)
>
> diff --git a/mingw-w64-crt/math/rint.c b/mingw-w64-crt/math/rint.c
> index 01f9644..6d0b632 100644
> --- a/mingw-w64-crt/math/rint.c
> +++ b/mingw-w64-crt/math/rint.c
> @@ -23,6 +23,8 @@ double rint (double x) {
>  #if defined(_AMD64_) || defined(__x86_64__) || defined(_X86_) || 
> defined(__i386__)
>    __asm__ __volatile__ ("frndint;" : "=t" (retval) : "0" (x));
>  #elif defined(__arm__) || defined(_ARM_)
> +    if (isnan(x) || isinf(x))
> +        return x;
>      retval = __rint_internal(x);
>  #endif
>    return retval;
> diff --git a/mingw-w64-crt/math/rintf.c b/mingw-w64-crt/math/rintf.c
> index 09c641b..37d4a92 100644
> --- a/mingw-w64-crt/math/rintf.c
> +++ b/mingw-w64-crt/math/rintf.c
> @@ -23,6 +23,8 @@ float rintf (float x) {
>  #if defined(_AMD64_) || defined(__x86_64__) || defined(_X86_) || 
> defined(__i386__)
>    __asm__ __volatile__ ("frndint;": "=t" (retval) : "0" (x));
>  #elif defined(__arm__) || defined(_ARM_)
> +    if (isnan(x) || isinf(x))
> +        return x;
>      retval = __rintf_internal(x);
>  #endif
>    return retval;
> --
> 2.7.4
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Mingw-w64-public mailing list
> Mingw-w64-public@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

------------------------------------------------------------------------------
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to