From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21900 invoked by alias); 23 Feb 2012 19:49:33 -0000 Received: (qmail 21890 invoked by uid 22791); 23 Feb 2012 19:49:31 -0000 X-SWARE-Spam-Status: No, hits=-2.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO sourceware.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 23 Feb 2012 19:49:21 +0000 From: "rsa at us dot ibm.com" To: glibc-bugs@sources.redhat.com Subject: [Bug math/887] Math library function "logb" and "nextafter" inconsistent Date: Thu, 23 Feb 2012 19:49:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: math X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rsa at us dot ibm.com X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: rsa at us dot ibm.com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org X-SW-Source: 2012-02/txt/msg00423.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=887 --- Comment #11 from Ryan S. Arnold 2012-02-23 19:48:48 UTC --- Here's an actual testcase which demonstrates the behavior in logb that's undesireable: #include #include #include #include #define NUM_INPUTS 6 int main() { double ret; int i = 0; typedef union { long long ll; double d; } input; input inputs[NUM_INPUTS]; inputs[0].ll = 0X3FF0000000000000LL; inputs[1].ll = 0X3FF8000000000000LL; inputs[2].ll = 0X3FF2000000000000LL; inputs[3].ll = 0X3FFFFFFFFFFFFFFFLL; inputs[4].ll = 0X3FF7FFFFFFFFFFFFLL; inputs[5].ll = 0X3FF1FFFFFFFFFFFFLL; for (i=0;i