From: tanmoy@qcd.lanl.gov (Tanmoy Bhattacharya)
Subject: Re: NaN in C/C++ on OSF1
Date: 1995/12/08 [thread overview]
Message-ID: <4a9ovt$h9b@newshost.lanl.gov> (raw)
In-Reply-To: 4a7lji$3j5@nntpd.lkg.dec.com
In article <4a7lji$3j5@nntpd.lkg.dec.com>, hobbs@steven.zko.dec.com (Steven
Hobbs) writes:
<snip>
|> Therefore, if you use cc with -ieee_with_no_inexact then sqrt(-1.0) will
return
|> a quietNaN and arithmetic on quietNaNs will *not* generate a signal
(unless you
|> enable signaling--see the ieee(3) man page). For historical reasons,
sqrt(-1.0)
|> produces 0.0 when -ieee_with_no_inexact is not enabled.
According to ANSI C, unless you do some implementation defined magic (like
`enabling signals' etc.), sqrt(-1.0) must _not_ produce an exception. It can
return any value defined by the implementation.
Cheers
Tanmoy
--
tanmoy@qcd.lanl.gov(128.165.23.46) DECNET: BETA::"tanmoy@lanl.gov"(1.218=1242)
Tanmoy Bhattacharya O:T-8(MS B285)LANL,NM87545 H:#9,3000,Trinity Drive,NM87544
Others see <gopher://yaleinfo.yale.edu:7700/00/Internet-People/internet-mail>,
<http://alpha.acast.nova.edu/cgi-bin/inmgq.pl>or<ftp://csd4.csd.uwm.edu/pub/
internetwork-mail-guide>. -- <http://nqcd.lanl.gov/people/tanmoy/tanmoy.html>
fax: 1 (505) 665 3003 voice: 1 (505) 665 4733 [ Home: 1 (505) 662 5596 ]
prev parent reply other threads:[~1995-12-08 5:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
1995-12-01 5:00 NaN in C/C++ on OSF1 Jan Christian Kerlefsen
1995-12-07 5:00 ` Steven Hobbs
1995-12-08 5:00 ` Tanmoy Bhattacharya [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox