Fix fdim handling of infinities (bug 15797)
Andreas Jaeger
aj@suse.com
Wed Aug 21 19:53:00 GMT 2013
On 08/21/2013 06:43 PM, Joseph S. Myers wrote:
> This patch fixes bug 15797, incorrect fdim handling of infinities, by
> removing the bogus check for infinities when returning x - y for NaN
> arguments and instead checking later when determining whether an
> infinite result means overflow. Appropriate testcases are added and
> existing ones made to verify that errno is unchanged. (It does not do
> anything about bug 6796, missing errno setting on overflow from
> architecture-specific versions, or add any testcases relating to
> overflow.)
>
> Tested x86_64 and x86.
>
> 2013-08-21 Joseph Myers <joseph@codesourcery.com>
>
> [BZ #15797]
> * math/s_fdim.c (__fdim): Check for infinite arguments if result
> is infinite, not alongside NaN test.
> * math/s_fdimf.c (__fdimf): Likewise.
> * math/s_fdiml.c (__fdiml): Likewise.
> * math/libm-test.inc (fdim_test_data): Add more tests. Test that
> errno is unchanged.
Ok, thanks,
Andreas
--
Andreas Jaeger aj@{suse.com,opensuse.org} Twitter/Identica: jaegerandi
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn,Jennifer Guild,Felix Imendörffer,HRB16746 (AG Nürnberg)
GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126
More information about the Libc-alpha
mailing list