From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23949 invoked by alias); 26 Apr 2013 11:31:33 -0000 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 Received: (qmail 23885 invoked by uid 55); 26 Apr 2013 11:31:31 -0000 From: "joseph at codesourcery dot com" To: glibc-bugs@sourceware.org Subject: [Bug math/14412] Removal of sysdeps/x86_64/fpu/s_sincos.S causes regressions Date: Fri, 26 Apr 2013 11:31: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: enhancement X-Bugzilla-Who: joseph at codesourcery dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: 2.18 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 X-SW-Source: 2013-04/txt/msg00171.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=14412 --- Comment #19 from joseph at codesourcery dot com 2013-04-26 11:31:29 UTC --- On Fri, 26 Apr 2013, jakub at redhat dot com wrote: > Perhaps we should add a predefined macro for -frounding-math in gcc, and the > precise variant of libm could be selected using that macro, if the correct > rounding precise variants would be suffixed differently (like the *_finite Basing things on a predefined macro like that won't work with any future GCC support for #pragma STDC FENV_ACCESS on (within the scope of that pragma, function versions supporting rounding modes should be called). So since you'd need a new compiler feature anyway, maybe something like __builtin_rounding_math () would be better as it would allow FENV_ACCESS support without further library changes (the safe default for older compilers without -ffast-math being to assume -frounding-math may be in effect). So you could have e.g. #define sin(x) (__builtin_rounding_math () ? sin (x) : __sin_noround (x)) (I'm using plain sin as the version supporting rounding modes for safety for programs declaring functions themselves rather than including the system header.) DTS 18661-1 constant rounding modes (see ) would require a further compiler feature to say "call this function with the dynamic rounding mode in effect being the constant mode for the current scope". -- 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.