This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug math/22631] [m68k] Bad const attributes in bits/mathinline.h


https://sourceware.org/bugzilla/show_bug.cgi?id=22631

--- Comment #1 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  664251859260d3cca6a477fb08c3b9f2b78a4fd9 (commit)
      from  8e52f573a1e0c2c39968051bcf683805540deb03 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=664251859260d3cca6a477fb08c3b9f2b78a4fd9

commit 664251859260d3cca6a477fb08c3b9f2b78a4fd9
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Tue Dec 19 02:02:26 2017 +0000

    Fix m68k bits/mathinline.h attributes (bug 22631).

    m68k bits/mathinline.h declares various functions with const
    attributes.  These are inappropriate for functions that have results
    depending on the rounding mode; the machine-independent
    bits/mathcalls.h only uses const attributes for a very few functions
    with no rounding mode dependence, and the m68k header should do
    likewise.  GCC uses pure for such functions with -frounding-math,
    resulting in GCC mainline warning for conflicts with between the
    header and the built-in attributes and glibc failing to build for m68k
    with GCC mainline.

    This patch fixes the attributes to avoid using const except when
    bits/mathcalls.h does so.  (There are a few functions where maybe
    bits/mathcalls.h could do so but doesn't, but keeping the headers in
    sync in this regard seems to be the safe approach.)

    Tested compilation with build-many-glibcs.py with GCC mainline.

        [BZ #22631]
        * sysdeps/m68k/m680x0/fpu/bits/mathinline.h (__m81_defun): Add
        argument for attrubutes.  All callers changed.
        (__inline_mathop1): Likewise.  All callers changed.
        (__inline_mathop): Likewise.  All callers changed.
        [__USE_MISC] (scalbn): Use __inline_forward instead of
        __inline_forward_c.
        [__USE_ISOC99] (scalbln): Likewise.
        [__USE_ISOC99] (nearbyint): Likewise.
        [__USE_ISOC99] (lrint): Likewise.
        [__USE_MISC] (scalbnf): Likewise.
        [__USE_ISOC99] (scalblnf): Likewise.
        [__USE_ISOC99] (nearbyintf): Likewise.
        [__USE_ISOC99] (lrintf): Likewise.
        [__USE_MISC] (scalbnl): Likewise.
        [__USE_ISOC99] (scalblnl): Likewise.
        [__USE_ISOC99] (nearbyintl): Likewise.
        [__USE_ISOC99] (lrintl): Likewise.
        * sysdeps/m68k/m680x0/fpu/mathimpl.h: All callers of
        __inline_mathop and __m81_defun changed.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                                 |   21 ++++++
 sysdeps/m68k/m680x0/fpu/bits/mathinline.h |  105 +++++++++++++++--------------
 sysdeps/m68k/m680x0/fpu/mathimpl.h        |   36 +++++-----
 3 files changed, 94 insertions(+), 68 deletions(-)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]