diff options
| author | koraynilay <koray.fra@gmail.com> | 2025-02-22 15:55:59 +0100 |
|---|---|---|
| committer | H.J. Lu <hjl.tools@gmail.com> | 2025-02-23 11:47:11 +0800 |
| commit | 29803ed3ce420f01e7c567c97fc8945d5e5e5992 (patch) | |
| tree | 4a7a1083c0b6300271abe5684fbc6c110e1c6a1a | |
| parent | 689a62a4217fae78b9ce0db781dc2a421f2b1ab4 (diff) | |
| download | glibc-29803ed3ce420f01e7c567c97fc8945d5e5e5992.tar.xz glibc-29803ed3ce420f01e7c567c97fc8945d5e5e5992.zip | |
math: Fix `unknown type name '__float128'` for clang 3.4 to 3.8.1 (bug 32694)
When compiling a program that includes <bits/floatn.h> using a clang version
between 3.4 (included) and 3.8.1 (included), clang will fail with `unknown type
name '__float128'; did you mean '__cfloat128'?`. This changes fixes the clang
prerequirements macro call in floatn.h to check for clang 3.9 instead of 3.4,
since support for __float128 was actually enabled in 3.9 by:
commit 50f29e06a1b6a38f0bba9360cbff72c82d46cdd4
Author: Nemanja Ivanovic <nemanja.i.ibm@gmail.com>
Date: Wed Apr 13 09:49:45 2016 +0000
Enable support for __float128 in Clang
This fixes bug 32694.
Signed-off-by: koraynilay <koray.fra@gmail.com>
Reviewed-by: H.J. Lu <hjl.tools@gmail.com>
| -rw-r--r-- | sysdeps/x86/bits/floatn.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/x86/bits/floatn.h b/sysdeps/x86/bits/floatn.h index adc7ed2e9e..4674165bd7 100644 --- a/sysdeps/x86/bits/floatn.h +++ b/sysdeps/x86/bits/floatn.h @@ -31,7 +31,7 @@ #if (defined __x86_64__ \ ? __GNUC_PREREQ (4, 3) \ : (defined __GNU__ ? __GNUC_PREREQ (4, 5) : __GNUC_PREREQ (4, 4))) \ - || (__glibc_clang_prereq (3, 4) \ + || (__glibc_clang_prereq (3, 9) \ && (!defined __INTEL_LLVM_COMPILER \ || !defined SYCL_LANGUAGE_VERSION)) # define __HAVE_FLOAT128 1 @@ -93,7 +93,7 @@ typedef _Complex float __cfloat128 __attribute__ ((__mode__ (__TC__))); /* The type _Float128 exists only since GCC 7.0. */ # if !__GNUC_PREREQ (7, 0) \ || (defined __cplusplus && !__GNUC_PREREQ (13, 0)) \ - || __glibc_clang_prereq (3, 4) + || __glibc_clang_prereq (3, 9) typedef __float128 _Float128; # endif |
