From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3579 invoked by alias); 5 Jan 2012 06:56:22 -0000 Received: (qmail 3570 invoked by uid 22791); 5 Jan 2012 06:56:21 -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, 05 Jan 2012 06:56:09 +0000 From: "guojiufu at gmail dot com" To: glibc-bugs@sources.redhat.com Subject: [Bug math/13563] New: LoP asinl returns unexpected value on long double Date: Thu, 05 Jan 2012 06:56:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: math X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: guojiufu at gmail dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: aj at suse dot de X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: 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-01/txt/msg00025.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=13563 Bug #: 13563 Summary: LoP asinl returns unexpected value on long double Product: glibc Version: unspecified Status: NEW Severity: normal Priority: P2 Component: math AssignedTo: aj@suse.de ReportedBy: guojiufu@gmail.com Classification: Unclassified #include #include #include typedef union { long double ld; struct{long l1, l2, l3, l4;} s; } U ; int main(void) { U u ; long double arg = (1.L-((__extension__ 0x1p-105L))/(long double)2); long double a = asinl(arg); u.ld = arg ; printf("size of long double=%d long=%d\n", sizeof(long double), sizeof(long)); printf("%X %X %X %X\n", u.s.l1,u.s.l2,u.s.l3,u.s.l4); printf("%.30Lg\n",arg); printf("%.30Lg\n",a); return 0; } > gcc t.c -lm;./a.out EXPECTED OUTPUT: size of long double=8 long=4 3FF00000 0 FE97FF4 0 1 1.57079632679489655799898173427 ACTUAL OUTPUT: size of long double=16 long=4 3FF00000 0 B9500000 0 1 nan <-should be 1.570796326794.... This issue happens at Linux on Power system -- Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.