Subject: Re: SIGFPE?
To: Robert Elz <kre@munnari.OZ.AU>
From: Richard Rauch <rauch@eecs.ukans.edu>
List: netbsd-help
Date: 05/02/2001 06:04:11
[...]
> | generic to all ports, however, and so I'm posting to this list rather than
> | to port-i386.)
>
> No, it is generic to ports with ieee floating point support, but not to
> others.
>
> ieee float specifies that (floating) x/0 is not to raise an exception,
[...]
> Thus, you get no SIGFPE from the division. You might get one later
> from attempting to operate upon the result (perhaps - depends upon the
> operation).
I didn't know that IEEE specified that. Thanks.
> Integer divide by 0 generates SIGFPE as it isn't subject to the ieee
[...]
> | (b) Inasmuch as SIGFPE seems to be used, it is applied to integer
> | arithmetic, rather than to floating point arithmetic.
>
> It is used for all arithmetic exceptions. The name comes form the (kind of
[...]
So this is a documentation error? (Again, signal(7) simply explains
SIGFPE as a floating point exception. From what you say, this is
technically correct for some systems, but a little obscure even there.
In general, it seems to be at best misleading.)
"I probably don't know what I'm talking about." --rauch@eecs.ukans.edu