This is the mail archive of the 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/22296] glibc 2.26: signbit build issue with Gcc 5.5.0 on x86_64

--- Comment #2 from cvs-commit at gcc dot <cvs-commit at gcc dot> ---
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  386e1c26ac473d6863133ab9cbe3bbda16c15816 (commit)
      from  3d265601358974c9be8264e53dadd8f9aea5690c (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 -----------------------------------------------------------------;h=386e1c26ac473d6863133ab9cbe3bbda16c15816

commit 386e1c26ac473d6863133ab9cbe3bbda16c15816
Author: Romain Naour <>
Date:   Mon Oct 16 23:21:56 2017 +0200

    Let signbit use the builtin in C++ mode with gcc < 6.x (bug 22296)

    When using gcc < 6.x, signbit does not use the type-generic
    __builtin_signbit builtin, instead it uses __MATH_TG.
    However, when library support for float128 is available, __MATH_TG uses
    __builtin_types_compatible_p, which is not available in C++ mode.

    On the other hand, libstdc++ undefines (in cmath) many macros from
    math.h, including signbit, so that it can provide its own functions.
    However, during its configure tests, libstdc++ just tests for the
    availability of the macros (it does not undefine them, nor does it
    provide its own functions).

    Finally, libstdc++ configure tests include math.h and get the definition
    of signbit that uses __MATH_TG (and __builtin_types_compatible_p).
    Since libstdc++ does not undefine the macros during its configure
    tests, they fail.

    This patch lets signbit use the builtin in C++ mode when gcc < 6.x is
    used. This allows the configure test in libstdc++ to work.

    Tested for x86_64.

        [BZ #22296]
        * math/math.h: Let signbit use the builtin in C++ mode with gcc
        < 6.x

    Cc: Gabriel F. T. Gomes <>
    Cc: Joseph Myers <>


Summary of changes:
 ChangeLog   |    6 ++++++
 math/math.h |    9 +++++++++
 2 files changed, 15 insertions(+), 0 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]