This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Fix remainder exceptions and directed-rounding results (bugs 15480, 15485)
- From: Andreas Jaeger <aj at suse dot com>
- To: libc-alpha at sourceware dot org
- Date: Fri, 17 May 2013 20:27:40 +0200
- Subject: Re: Fix remainder exceptions and directed-rounding results (bugs 15480, 15485)
- References: <Pine dot LNX dot 4 dot 64 dot 1305171652200 dot 21342 at digraph dot polyomino dot org dot uk>
On 05/17/2013 06:54 PM, Joseph S. Myers wrote:
The dbl-64 implementation of the remainder function assumes
round-to-nearest (the results of this function should not depend on
the rounding mode at all) and can generate spurious "inexact"
exceptions. This patch fixes both problems by using
SET_RESTORE_ROUND_NOEX (FE_TONEAREST) in the appropriate case of this
function (other parts of the function do not do anything depending on
rounding mode or generating spurious exceptions, and may be required
to generate correct "invalid" exceptions in certain cases).
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