delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1997/04/22/20:04:05

From: noer AT cygnus DOT com (Geoffrey Noer)
Subject: Re: Problems with transcendentals in libm
22 Apr 1997 20:04:05 -0700 :
Approved: cygnus DOT gnu-win32 AT cygnus DOT com
Distribution: cygnus
Message-ID: <199704221825.LAA06655.cygnus.gnu-win32@cirdan.cygnus.com>
Original-To: mjo AT mrao DOT cam DOT ac DOT uk (Martin Oldfield)
Original-Cc: gnu-win32 AT cygnus DOT com
In-Reply-To: <m0ue8bP-000AdAC@joanna.robinson.cam.ac.uk> from "Martin Oldfield" at Jul 11, 96 00:23:00 am
X-Mailer: ELM [version 2.4 PL23]
Original-Sender: owner-gnu-win32 AT cygnus DOT com

Greetings,

I've confirmed that the following problem is fixed in the upcoming beta18
release.  I now get the same behavior for gnu-win32 gcc as for Solaris gcc,
with and without optimization on.  Thanks for the test case!

(I believe this was caused by errors in floating point initialization
in the crt0).

-- 
Geoffrey Noer
noer AT cygnus DOT com

Martin Oldfield wrote:
> 
> The following program produces bogus output. This appears to imply a
> bug in the cosh(x) and tanh(x) functions. Is this a known problem and
> are there any workarounds ?
[...]
> Broken lines running from cygwin32
> 
>          x:       logx       expx      tanhx      coshx      sinhx
>      0.368:         -1       1.44      0.352        NaN      0.376
>       2.72:          1       15.2        NaN        NaN       7.54
>       7.39:          2   1.62e+03        NaN        NaN        809
>       20.1:          3   5.28e+08        NaN        NaN   2.64e+08
> 
>     -0.368:       -Inf      0.692     -0.352        NaN     -0.376
>      -2.72:       -Inf      0.066        NaN        NaN      -7.54
>      -7.39:       -Inf   0.000618        NaN        NaN       -809
>      -20.1:       -Inf   1.89e-09        NaN        NaN  -2.64e+08
> 
> ------------------------------------------------------------------------
> 
> Comparable lines running under linux
> 
>          x:       logx       expx      tanhx      coshx      sinhx
>      0.368:         -1       1.44      0.352       1.07      0.376
>       2.72:          1       15.2      0.991       7.61       7.54
>       7.39:          2   1.62e+03          1        809        809
>       20.1:          3   5.28e+08          1   2.64e+08   2.64e+08
> 
>     -0.368:        NaN      0.692     -0.352       1.07     -0.376
>      -2.72:        NaN      0.066     -0.991       7.61      -7.54
>      -7.39:        NaN   0.000618         -1        809       -809
>      -20.1:        NaN   1.89e-09         -1   2.64e+08  -2.64e+08
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019