This is the mail archive of the mailing list for the eCos project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug 1001539] Single precision floating point math library

Please do not reply to this email, use the link below.

--- Comment #32 from Ilija Kocho <> ---
(In reply to comment #31)
> (In reply to comment #30)
> > (In reply to comment #29)
> > > 
> > > I'm referring to actual code Ref:float/ieee754_api/wf_asinf.c
> > > if (|x| > 1) POSIX mode sets errno = EDOM indeed, but returns 0 rather than
> > > NaN.
... as expected by the test.

I should have been clearer, sorry.

> > 
> > It's not required to return NaN. In fact the slightly older POSIX standard
> > I've got here (not online) says that more explicitly:
> > 
> > "If the value of x is not in the range [â1,1], and is not ÂInf or NaN,
> > either 0.0 or NaN shall be returned and errno shall be set to [EDOM].
> > 
> > If x is NaN, NaN shall be returned and errno may be set to [EDOM].
> > 
> > If x is ÂInf, either 0.0 shall be returned and errno set to [EDOM], or NaN
> > shall be returned and errno may be set to [EDOM]."
> > 
> > I assume in the more recent standard they decided to make it more general -
> > not necessarily 0.0 but any value as long as it's implementation-defined.
> > But that can certainly be 0.0.

The code is OK, according to standard, nevertheless for non IEEE model tests do
fail on vectors testing EDOM. We can either change the test (perhaps test
errno), or exclude EDOM tests for non IEEE models. I proposed exclusion of EDOM
vectors for non IEEE model, because I didn't want to alter the test code, but
I'm open for suggestions.


You are receiving this mail because:
You are the assignee for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]