about summary refs log tree commit diff
path: root/malloc
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2017-10-17 20:16:01 +0000
committerJoseph Myers <joseph@codesourcery.com>2017-10-17 20:16:01 +0000
commit13c92696d2f66e94e4f04248550cc2b8f283bfd0 (patch)
treeed78614959cadafa22818b78bc27150d1001eeb6 /malloc
parent71d85045fdaefbd2dc1708ed6123ebdb880cb3ed (diff)
downloadglibc-13c92696d2f66e94e4f04248550cc2b8f283bfd0.tar.gz
glibc-13c92696d2f66e94e4f04248550cc2b8f283bfd0.tar.xz
glibc-13c92696d2f66e94e4f04248550cc2b8f283bfd0.zip
Use __f128 to define FLT128_* constants in include/float.h for old GCC.
When using compilers before GCC 7, include/float.h provides fallback
definitions of FLT128_* constants.  These definitions use 'Q' constant
suffixes, which works for configurations with _Float128 ABI-distinct
from long double, but not where it has the same ABI as long double.
This patch changes the definitions to use the __f128 macro from
<bits/floatn.h>, so allowing them to work in the non-distinct
_Float128 case (where they are used in building glibc tests, not for
building glibc itself) as well.

Tested (a) with build-many-glibcs.py with GCC 6 (installed stripped
shared libraries unchanged by the patch); (b) with
build-many-glibcs.py with GCC 6 together with the main patch to enable
float128 aliases; (c) for x86_64 with both GCC 6 and GCC 7.

	* include/float.h [!__GNUC_PREREQ (7, 0) && __HAVE_FLOAT128 &&
	__GLIBC_USE (IEC_60559_TYPES_EXT)] (FLT128_MAX): Define using
	__f128.
	[!__GNUC_PREREQ (7, 0) && __HAVE_FLOAT128 && __GLIBC_USE
	(IEC_60559_TYPES_EXT)] (FLT128_EPSILON): Likewise.
	[!__GNUC_PREREQ (7, 0) && __HAVE_FLOAT128 && __GLIBC_USE
	(IEC_60559_TYPES_EXT)] (FLT128_MIN): Likewise.
	[!__GNUC_PREREQ (7, 0) && __HAVE_FLOAT128 && __GLIBC_USE
	(IEC_60559_TYPES_EXT)] (FLT128_TRUE_MIN): Likewise.
Diffstat (limited to 'malloc')
0 files changed, 0 insertions, 0 deletions