aboutsummaryrefslogtreecommitdiff
path: root/math/Makefile
diff options
context:
space:
mode:
authorPaul E. Murphy <murphyp@linux.vnet.ibm.com>2016-07-15 14:05:51 -0500
committerGabriel F. T. Gomes <gftg@linux.vnet.ibm.com>2017-05-09 11:40:28 -0300
commit26265c3bce73ca85a4b6976ba62dc2111b46e414 (patch)
tree48b5edb196f5f1e3ae7ebd659d2f6a162c9338b9 /math/Makefile
parent695d7d138eda449678a1650a8b8b58181033353f (diff)
downloadglibc-26265c3bce73ca85a4b6976ba62dc2111b46e414.zip
glibc-26265c3bce73ca85a4b6976ba62dc2111b46e414.tar.gz
glibc-26265c3bce73ca85a4b6976ba62dc2111b46e414.tar.bz2
float128: Add _Float128 make bits to libm.
This adds the appropriate common bits for a platform to enable float128 and expose ABI. * math/Makefile: (type-float128-suffix): New variable (type-float128-routines): Likewise (type-float128-yes): Likewise (types): Append float128 if supported (types-basic): New variable to control the use of templates for float, double, and long double, but not for float128 or newer types. (type-basic-foreach): Likewise. * sysdeps/ieee754/float128/Makeconfig: New file. * sysdeps/ieee754/float128/Versions: New file.
Diffstat (limited to 'math/Makefile')
-rw-r--r--math/Makefile16
1 files changed, 14 insertions, 2 deletions
diff --git a/math/Makefile b/math/Makefile
index 97080a7..634c619 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -100,7 +100,7 @@ libm-compat-calls = \
# Finally, note that types is an intentionally recursive variable.
# We only know the full set of supported types for the target machine
# after the Rules makefile has been parsed.
-types = $(type-ldouble-$(long-double-fcts)) double float
+types-basic = $(type-ldouble-$(long-double-fcts)) double float
# long double support
type-ldouble-suffix := l
@@ -117,12 +117,23 @@ type-double-routines := branred doasin dosincos halfulp mpa mpatan2 \
type-float-suffix := f
type-float-routines := k_rem_pio2f
+# _Float128 support
+type-float128-suffix := f128
+type-float128-routines := t_sincosf128 k_sincosf128
+type-float128-yes := float128
+types = $(types-basic) $(type-float128-$(float128-fcts))
+
+# For each of the basic types (float, double, long double), replace the
+# occurrences of 'F' in arg 1 with the appropriate suffix for the type.
+type-basic-foreach = $(foreach t, $(types-basic), \
+ $(subst F,$(type-$(t)-suffix),$(1)))
# Apply suffix to each type in arg 1
type-foreach = $(foreach t,$(types),$(subst F,$(type-$(t)-suffix),$(1)))
libm-routines = $(strip $(libm-support) \
- $(call type-foreach, $(libm-compat-calls)) \
+ $(call type-basic-foreach, \
+ $(libm-compat-calls)) \
$(call type-foreach, $(libm-calls)) \
$(foreach t, $(types), $(type-$(t)-routines))) \
@@ -543,6 +554,7 @@ endif
CFLAGS-s_modf.c += -fsignaling-nans
CFLAGS-s_modff.c += -fsignaling-nans
CFLAGS-s_modfl.c += -fsignaling-nans
+CFLAGS-s_modff128.c += -fsignaling-nans
# The -lieee library is actually an object file.
# The module just defines the _LIB_VERSION_ variable.