Alpha vs EXCEPTION_TESTS
Joseph S. Myers
joseph@codesourcery.com
Wed Jun 26 00:29:00 GMT 2013
On Tue, 25 Jun 2013, Richard Henderson wrote:
> Thus the current state of affairs wherein if one really wants
> the inexact flag to be correct throughout libm, one has to rebuild
> the library with -mieee-with-inexact set in cflags or whatever.
> (Those few files like fma for which we rely on inexact for correct
> results have individual CFLAGS-foo variables set in the Makefile.)
>
> With the recent enhancements to the testsuite, we now have
>
> > testing float (without inline functions)
> > Failure: scalbn (1, INT_MAX): Exception "Inexact" not set
>
> etc.
>
> I'm wondering if there were ideas about the best way to adjust
> the EXCEPTION_TESTS macro to filter the implemented exceptions.
I'd think the correct thing is to build more files with
-mieee-with-inexact (for those functions that are bound to IEEE
floating-point operations and for which libm-test.inc duly tests whether
the exceptions are present or absent, that is; not for the bulk of libm
where there are no requirements on whether "inexact" is raised or not ...
and if the requirement is always that no "inexact" is raised, or the
operation is always exact, of course you don't add the option).
(strtod and floating-point printf should, I think, raise "inexact" when
applicable, in addition to certain libm functions - but so far they don't
attempt to do so and there are no tests that they do.)
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Libc-alpha
mailing list