Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jun 1999 10:39:10 -0500
From:      Dan Nelson <dnelson@emsphone.com>
To:        Jos Backus <Jos.Backus@nl.origin-it.com>
Cc:        freebsd-hackers@FreeBSD.ORG, Tobi Oetiker <tobi@caida.org>
Subject:   Re: [tobi@caida.org: Re: [MRTG-DEV] CDEF's with LT and IF in .42]
Message-ID:  <19990630103910.B50144@dan.emsphone.com>
In-Reply-To: <19990630151551.C51182@hal.mpn.cp.philips.com>; from "Jos Backus" on Wed Jun 30 15:15:51 GMT 1999
References:  <19990630151551.C51182@hal.mpn.cp.philips.com>

next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Jun 30), Jos Backus said:
> ----- Forwarded message from Tobi Oetiker <tobi@caida.org> -----
> > OK found your problem .... it is that old FreeBSD does no proper
> > IEEE math ...
> > 
> > for some comparison operations it raises an sigfpe if an NaN is
> > involved ...
> >
> > the next release of rrdtool will come with a proper test to find
> > the problem and a proper fix in the software to ignore sigfpe
>
> Saw this on the MRTG-DEV list.
> NaN handling is perceived to be problematic, it seems.

The last time this came up (and it comes up every 6 months or so), the
consensus was that we would rather trap FP errors than blindly pass
them on to the user application.  If a program wants to ignore NaN,
divide-by-zero, underflow, and overflow conditions, let it wrap the
offending line of code with two fpsetmask() calls; one to mask the
condition, and one to restore the previous mask.  If you want to
completely ignore floating point errors, call fpsetmask(0) at the top
of main().

I scanned the mailinglists and the thread that covers this issue most
completely is

http://www.freebsd.org/cgi/mid.cgi?id=199710101907.OAA09470@millenia.srrc.usda.gov
 
	-Dan Nelson
	dnelson@emsphone.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990630103910.B50144>