From owner-freebsd-numerics@FreeBSD.ORG Sun Aug 12 23:01:32 2012 Return-Path: Delivered-To: freebsd-numerics@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CBEBA1065673 for ; Sun, 12 Aug 2012 23:01:32 +0000 (UTC) (envelope-from peter@rulingia.com) Received: from vps.rulingia.com (host-122-100-2-194.octopus.com.au [122.100.2.194]) by mx1.freebsd.org (Postfix) with ESMTP id 5F7928FC08 for ; Sun, 12 Aug 2012 23:01:31 +0000 (UTC) Received: from server.rulingia.com (c220-239-249-137.belrs5.nsw.optusnet.com.au [220.239.249.137]) by vps.rulingia.com (8.14.5/8.14.5) with ESMTP id q7CN1VUg075583 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 13 Aug 2012 09:01:31 +1000 (EST) (envelope-from peter@rulingia.com) X-Bogosity: Ham, spamicity=0.000000 Received: from server.rulingia.com (localhost.rulingia.com [127.0.0.1]) by server.rulingia.com (8.14.5/8.14.5) with ESMTP id q7CN1PVh021068 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 13 Aug 2012 09:01:25 +1000 (EST) (envelope-from peter@server.rulingia.com) Received: (from peter@localhost) by server.rulingia.com (8.14.5/8.14.5/Submit) id q7CN1P8E021067 for freebsd-numerics@freebsd.org; Mon, 13 Aug 2012 09:01:25 +1000 (EST) (envelope-from peter) Resent-From: Peter Jeremy Resent-Date: Mon, 13 Aug 2012 09:01:25 +1000 Resent-Message-ID: <20120812230125.GV20453@server.rulingia.com> Resent-To: freebsd-numerics@freebsd.org From: Peter Jeremy Mail-Followup-To: freebsd-numerics@freebsd.org To: Steve Kargl Message-ID: <20120722233134.GB8033@server.rulingia.com> References: <20120717042125.GF66913@server.rulingia.com> <20120717043848.GB87001@troutmask.apl.washington.edu> <20120717225328.GA86902@server.rulingia.com> <20120717232740.GA95026@troutmask.apl.washington.edu> <20120718001337.GA87817@server.rulingia.com> <20120718123627.D1575@besplex.bde.org> <20120722121219.GC73662@server.rulingia.com> <20120722220031.GA7791@server.rulingia.com> <20120722221614.GB53450@zim.MIT.EDU> <20120722231056.GA84338@troutmask.apl.washington.edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="DBIVS5p969aUjpLe" Content-Disposition: inline In-Reply-To: <20120722231056.GA84338@troutmask.apl.washington.edu> X-PGP-Key: http://www.rulingia.com/keys/peter.pgp User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Diane Bruce , John Baldwin , David Chisnall , Stephen Montgomery-Smith , Bruce Evans , Bruce Evans , David Schultz , Warner Losh Subject: Re: Use of C99 extra long double math functions after r236148 X-BeenThere: freebsd-numerics@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussions of high quality implementation of libm functions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Sun, 12 Aug 2012 23:01:33 -0000 X-Original-Date: Mon, 23 Jul 2012 09:31:34 +1000 X-List-Received-Date: Sun, 12 Aug 2012 23:01:33 -0000 --DBIVS5p969aUjpLe Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2012-Jul-22 16:10:56 -0700, Steve Kargl wrote: >The above isn't necessarily true. The Fortran standards from >2003 and 2008, very care about NaN. Under certain conditions, >if one has something like=20 > > x =3D sin(NaN) > >in Fortran, then the returned NaN must be the one in the function >call. Even if it was a SNaN? My understanding is that SNaN should be quietened if they are used in any further floating point operations. > Having libm, do > > if (x =3D=3D NaN) > return (x + x); > >does/may not return the correct NaN. I presume you mean if (isnan(x)) return (x + x); Do you have a test case that shows that? As far as I can tell, all the FPUs I have access to will return a quietened variant of the input NaN in this case (ie, only the signalling bit is altered). --=20 Peter Jeremy --DBIVS5p969aUjpLe Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlAMjVYACgkQ/opHv/APuIcdBQCeIi9S9Yq+faBLz7W9dLuYbAVD O3cAn1psBIXlikmAG3Au8jyyhxwoGbEZ =D0AN -----END PGP SIGNATURE----- --DBIVS5p969aUjpLe--