glibc/math
Szabolcs Nagy 4e0dca54e9 [BZ #22593] Fix nextafter and nexttoward declaration
These functions set errno and thus the const attribute was wrong.

	[BZ #22593]
	* math/bits/mathcalls.h (nextafter): Remove const.
	(nexttoward): Likewise.
2017-12-12 13:59:18 +00:00
..
bits [BZ #22593] Fix nextafter and nexttoward declaration 2017-12-12 13:59:18 +00:00
machine
atest-exp2.c
atest-exp.c
atest-sincos.c
auto-libm-test-in
auto-libm-test-out-acos
auto-libm-test-out-acosh
auto-libm-test-out-asin
auto-libm-test-out-asinh
auto-libm-test-out-atan
auto-libm-test-out-atan2
auto-libm-test-out-atanh
auto-libm-test-out-cabs
auto-libm-test-out-cacos
auto-libm-test-out-cacosh
auto-libm-test-out-carg
auto-libm-test-out-casin
auto-libm-test-out-casinh
auto-libm-test-out-catan
auto-libm-test-out-catanh
auto-libm-test-out-cbrt
auto-libm-test-out-ccos
auto-libm-test-out-ccosh
auto-libm-test-out-cexp
auto-libm-test-out-clog
auto-libm-test-out-clog10
auto-libm-test-out-cos
auto-libm-test-out-cosh
auto-libm-test-out-cpow
auto-libm-test-out-csin
auto-libm-test-out-csinh
auto-libm-test-out-csqrt
auto-libm-test-out-ctan
auto-libm-test-out-ctanh
auto-libm-test-out-erf
auto-libm-test-out-erfc
auto-libm-test-out-exp
auto-libm-test-out-exp2
auto-libm-test-out-exp10
auto-libm-test-out-expm1
auto-libm-test-out-fma
auto-libm-test-out-hypot
auto-libm-test-out-j0
auto-libm-test-out-j1
auto-libm-test-out-jn
auto-libm-test-out-lgamma
auto-libm-test-out-log
auto-libm-test-out-log1p
auto-libm-test-out-log2
auto-libm-test-out-log10
auto-libm-test-out-pow
auto-libm-test-out-sin
auto-libm-test-out-sincos
auto-libm-test-out-sinh
auto-libm-test-out-sqrt
auto-libm-test-out-tan
auto-libm-test-out-tanh
auto-libm-test-out-tgamma
auto-libm-test-out-y0
auto-libm-test-out-y1
auto-libm-test-out-yn
basic-test.c
bug-nextafter.c
bug-nexttoward.c
bug-tgmath1.c
cabs_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
carg_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
cimag_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
complex.h Include bits/cmathcalls.h for more _FloatN, _FloatNx types. 2017-11-01 23:42:31 +00:00
conj_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
creal_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
divtc3.c
e_exp2_template.c
e_exp10.c
e_exp10f.c
e_exp10l.c
e_scalb.c
e_scalbf.c
e_scalbl.c
fclrexcpt.c
fedisblxcpt.c
feenablxcpt.c
fegetenv.c
fegetexcept.c
fegetmode.c
fegetround.c
feholdexcpt.c
fenv.h
fesetenv.c
fesetexcept.c
fesetmode.c
fesetround.c
fetestexceptflag.c
feupdateenv.c
fgetexcptflg.c
fpu_control.c
fraiseexcpt.c
fromfp.h
fsetexcptflg.c
ftestexcept.c
gen-auto-libm-tests.c
gen-fromfp-tests-inputs
gen-fromfp-tests.py
gen-libm-test.pl
gen-tgmath-tests.py Fix gen-tgmath-tests.py for _Float64, _Float64x testing. 2017-11-24 21:22:34 +00:00
k_casinh_template.c
k_sincosl.c
lgamma-compat.h Prefer new libm function wrappers for !LIBM_SVID_COMPAT. 2017-09-05 23:35:55 +00:00
libm-test-acos.inc
libm-test-acosh.inc
libm-test-asin.inc
libm-test-asinh.inc
libm-test-atan2.inc
libm-test-atan.inc
libm-test-atanh.inc
libm-test-cabs.inc
libm-test-cacos.inc
libm-test-cacosh.inc Make cacosh (0 + iNaN) return NaN + i pi/2 (bug 22561, DR#471). 2017-12-06 21:35:20 +00:00
libm-test-canonicalize.inc
libm-test-carg.inc
libm-test-casin.inc
libm-test-casinh.inc
libm-test-catan.inc
libm-test-catanh.inc
libm-test-cbrt.inc
libm-test-ccos.inc
libm-test-ccosh.inc
libm-test-ceil.inc
libm-test-cexp.inc
libm-test-cimag.inc
libm-test-clog10.inc
libm-test-clog.inc
libm-test-conj.inc
libm-test-copysign.inc
libm-test-cos.inc
libm-test-cosh.inc
libm-test-cpow.inc
libm-test-cproj.inc
libm-test-creal.inc
libm-test-csin.inc
libm-test-csinh.inc
libm-test-csqrt.inc
libm-test-ctan.inc Fix ctanh (0 + i NaN), ctanh (0 + i Inf) (bug 22568, DR#471). 2017-12-07 16:21:00 +00:00
libm-test-ctanh.inc Fix ctanh (0 + i NaN), ctanh (0 + i Inf) (bug 22568, DR#471). 2017-12-07 16:21:00 +00:00
libm-test-driver.c
libm-test-erf.inc
libm-test-erfc.inc
libm-test-exp2.inc
libm-test-exp10.inc Obsolete pow10 functions. 2017-09-01 21:13:18 +00:00
libm-test-exp.inc
libm-test-expm1.inc
libm-test-fabs.inc
libm-test-fdim.inc
libm-test-floor.inc
libm-test-fma.inc
libm-test-fmax.inc
libm-test-fmaxmag.inc
libm-test-fmin.inc
libm-test-fminmag.inc
libm-test-fmod.inc
libm-test-fpclassify.inc
libm-test-frexp.inc
libm-test-fromfp.inc
libm-test-fromfpx.inc
libm-test-getpayload.inc
libm-test-hypot.inc
libm-test-ilogb.inc
libm-test-iscanonical.inc
libm-test-iseqsig.inc
libm-test-isfinite.inc
libm-test-isgreater.inc
libm-test-isgreaterequal.inc
libm-test-isinf.inc
libm-test-isless.inc
libm-test-islessequal.inc
libm-test-islessgreater.inc
libm-test-isnan.inc
libm-test-isnormal.inc
libm-test-issignaling.inc
libm-test-issubnormal.inc
libm-test-isunordered.inc
libm-test-iszero.inc
libm-test-j0.inc
libm-test-j1.inc
libm-test-jn.inc
libm-test-lgamma.inc
libm-test-llogb.inc
libm-test-llrint.inc
libm-test-llround.inc
libm-test-log1p.inc
libm-test-log2.inc
libm-test-log10.inc
libm-test-log.inc
libm-test-logb.inc
libm-test-lrint.inc
libm-test-lround.inc
libm-test-modf.inc
libm-test-nearbyint.inc
libm-test-nextafter.inc
libm-test-nextdown.inc
libm-test-nexttoward.inc
libm-test-nextup.inc
libm-test-pow.inc
libm-test-remainder.inc
libm-test-remquo.inc
libm-test-rint.inc
libm-test-round.inc
libm-test-roundeven.inc
libm-test-scalb.inc
libm-test-scalbln.inc
libm-test-scalbn.inc
libm-test-setpayload.inc
libm-test-setpayloadsig.inc
libm-test-signbit.inc
libm-test-significand.inc
libm-test-sin.inc
libm-test-sincos.inc
libm-test-sinh.inc
libm-test-sqrt.inc
libm-test-support.c Run libm long double tests for long double = double. 2017-10-11 17:46:19 +00:00
libm-test-support.h
libm-test-tan.inc
libm-test-tanh.inc
libm-test-tgamma.inc
libm-test-totalorder.inc
libm-test-totalordermag.inc
libm-test-trunc.inc
libm-test-ufromfp.inc
libm-test-ufromfpx.inc
libm-test-y0.inc
libm-test-y1.inc
libm-test-yn.inc
Makefile Replace = with += in CFLAGS-xxx.c/CPPFLAGS-xxx.c 2017-12-11 13:11:33 -08:00
math-svid-compat.h Simplify math-svid-compat code. 2017-08-28 15:19:52 +00:00
math.h Handle more _FloatN, _FloatNx types in __MATH_TG. 2017-11-03 23:50:00 +00:00
mul_split.h
mul_splitl.h
multc3.c
README.libm-test
s_cacos_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_cacosh_template.c Make cacosh (0 + iNaN) return NaN + i pi/2 (bug 22561, DR#471). 2017-12-06 21:35:20 +00:00
s_canonicalize_template.c
s_casin_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_casinh_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_catan_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_catanh_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_ccos_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_ccosh_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_cexp_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_clog10_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_clog_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_cpow_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_cproj_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_csin_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_csinh_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_csqrt_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_ctan_template.c Fix ctanh (0 + i NaN), ctanh (0 + i Inf) (bug 22568, DR#471). 2017-12-07 16:21:00 +00:00
s_ctanh_template.c Fix ctanh (0 + i NaN), ctanh (0 + i Inf) (bug 22568, DR#471). 2017-12-07 16:21:00 +00:00
s_fdim_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_fma.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
s_fmaf.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
s_fmal.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
s_fmax_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_fmaxmag_template.c
s_fmin_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_fminmag_template.c
s_iscanonicall.c
s_iseqsig_template.c
s_ldexp_template.c Remove declare_mgen_alias_2. 2017-09-12 20:00:00 +00:00
s_nan_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
s_nextafter.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
s_nextdown_template.c
s_nexttowardf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_nexttowardl.c
s_significand.c
s_significandf.c
s_significandl.c
setfpucw.c
t_sincosl.c
test-double-vlen2.h
test-double-vlen4.h
test-double-vlen8.h
test-double.h Run libm long double tests for long double = double. 2017-10-11 17:46:19 +00:00
test-fe-snans-always-signal.c
test-femode-traps.c
test-femode.c
test-fenv-clear-main.c
test-fenv-clear.c
test-fenv-preserve.c
test-fenv-return.c
test-fenv-tls.c
test-fenv.c
test-fenvinline.c
test-fesetexcept-traps.c
test-fesetexcept.c
test-fetestexceptflag.c
test-fexcept-traps.c
test-fexcept.c
test-finite-macros.c Fix bits/math-finite.h _MSUF_ expansion namespace (bug 22028). 2017-08-29 14:15:37 +00:00
test-float32.h Add header for _Float32 testing. 2017-12-06 22:17:11 +00:00
test-float32x.h Add headers for _Float64, _Float32x testing. 2017-12-05 17:34:25 +00:00
test-float64.h Add headers for _Float64, _Float32x testing. 2017-12-05 17:34:25 +00:00
test-float64x.h Support testing _Float64x libm functions. 2017-11-24 22:25:03 +00:00
test-float128.h Support running libm tests for float128 as alias for long double. 2017-10-16 13:28:30 +00:00
test-float-vlen4.h
test-float-vlen8.h
test-float-vlen16.h
test-float.h Run libm long double tests for long double = double. 2017-10-11 17:46:19 +00:00
test-flt-eval-method.c
test-fp-ilogb-constants.c
test-fp-llogb-constants.c
test-fpucw-ieee-static.c
test-fpucw-ieee.c
test-fpucw-static.c
test-fpucw.c
test-iseqsig-excess-precision.c
test-iszero-excess-precision.c
test-ldouble.h Run libm long double tests for long double = double. 2017-10-11 17:46:19 +00:00
test-math-cxx11.cc Ensure C99 and C11 interfaces are available for C++ [BZ #21326] 2017-10-09 16:18:11 +02:00
test-math-errno.h
test-math-finite.h
test-math-floatn.h
test-math-inline.h
test-math-iscanonical.cc test-math-iscanonical.cc: Return errors != 0 2017-10-04 14:31:16 -07:00
test-math-isinff.cc
test-math-issignaling.cc Provide a C++ version of issignaling that does not use __MATH_TG 2017-08-22 10:05:41 -03:00
test-math-iszero.cc Provide a C++ version of iszero that does not use __MATH_TG (bug 21930) 2017-08-28 15:22:37 -03:00
test-math-no-finite.h
test-math-no-inline.h
test-math-scalar.h
test-math-vector.h
test-matherr-2.c Fix tests that are testing obsoleted functionality 2017-09-05 12:24:00 -07:00
test-matherr-3.c Obsolete matherr, _LIB_VERSION, libieee.a. 2017-08-21 17:45:10 +00:00
test-matherr.c Fix tests that are testing obsoleted functionality 2017-09-05 12:24:00 -07:00
test-misc.c
test-nan-overflow.c
test-nan-payload.c
test-nearbyint-except-2.c
test-nearbyint-except.c
test-powl.c
test-signgam-finite-c11.c
test-signgam-finite-c99.c Remove _Mlong_double_ etc. macros. 2017-10-30 20:58:51 +00:00
test-signgam-finite.c
test-signgam-main.c
test-signgam-uchar-init-static.c
test-signgam-uchar-init.c
test-signgam-uchar-static.c
test-signgam-uchar.c
test-signgam-uint-init-static.c
test-signgam-uint-init.c
test-signgam-uint-static.c
test-signgam-uint.c
test-signgam-ullong-init-static.c
test-signgam-ullong-init.c
test-signgam-ullong-static.c
test-signgam-ullong.c
test-snan.c
test-tgmath2.c
test-tgmath-int.c
test-tgmath-ret.c
test-tgmath.c
tgmath.h Use __builtin_tgmath in tgmath.h with GCC 8 (bug 21660). 2017-11-15 02:08:56 +00:00
tst-CMPLX2.c
tst-CMPLX.c
tst-definitions.c
Versions Add _Float32 function aliases. 2017-12-07 00:48:31 +00:00
w_acos_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_acos_template.c
w_acosf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_acosh_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_acosh_template.c
w_acoshf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_acoshl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_acosl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_asin_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_asin_template.c
w_asinf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_asinl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_atan2_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_atan2_template.c
w_atan2f_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_atan2l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_atanh_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_atanh_template.c
w_atanhf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_atanhl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_cosh_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_cosh_template.c
w_coshf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_coshl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_exp2_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_exp2_template.c
w_exp2f_compat.c New expf and exp2f version without SVID compat wrapper 2017-09-25 10:45:08 +01:00
w_exp2f.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_exp2l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_exp10_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_exp10_template.c
w_exp10f_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_exp10l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_exp_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_exp_template.c
w_expf_compat.c New expf and exp2f version without SVID compat wrapper 2017-09-25 10:45:08 +01:00
w_expf.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_expl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_fmod_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_fmod_template.c
w_fmodf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_fmodl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_hypot_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_hypot_template.c
w_hypotf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_hypotl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_ilogb_template.c Define and use libm_alias_double. 2017-09-13 01:13:30 +00:00
w_j0_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_j0_template.c
w_j0f_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_j0l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_j1_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_j1_template.c
w_j1f_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_j1l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_jn_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_jn_template.c
w_jnf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_jnl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_lgamma_compat2.c
w_lgamma_compat.c
w_lgamma_compatf.c
w_lgamma_compatl.c
w_lgamma_main.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_lgamma_r_compat.c Use generic macros for lgamma_r function aliases. 2017-10-09 22:04:18 +00:00
w_lgamma_r_template.c Use generic macros for lgamma_r function aliases. 2017-10-09 22:04:18 +00:00
w_lgamma_template.c
w_lgamma.c fix gamma symbol for static linking and new targets 2017-10-02 17:33:13 +01:00
w_lgammaf_compat2.c
w_lgammaf_main.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_lgammaf_r_compat.c Use generic macros for lgamma_r function aliases. 2017-10-09 22:04:18 +00:00
w_lgammaf.c fix gamma symbol for static linking and new targets 2017-10-02 17:33:13 +01:00
w_lgammal_compat2.c
w_lgammal_main.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_lgammal_r_compat.c Use generic macros for lgamma_r function aliases. 2017-10-09 22:04:18 +00:00
w_lgammal.c fix gamma symbol for static linking and new targets 2017-10-02 17:33:13 +01:00
w_llogb_template.c
w_log1p_template.c
w_log2_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_log2_template.c
w_log2f_compat.c New symbol version for logf, log2f and powf without SVID compat 2017-10-02 14:38:03 +01:00
w_log2f.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_log2l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_log10_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_log10_template.c
w_log10f_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_log10l_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_log_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_log_template.c
w_logf_compat.c New symbol version for logf, log2f and powf without SVID compat 2017-10-02 14:38:03 +01:00
w_logf.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_logl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_pow_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_pow_template.c
w_powf_compat.c New symbol version for logf, log2f and powf without SVID compat 2017-10-02 14:38:03 +01:00
w_powf.c Add libm_alias_*_other_r macros. 2017-10-10 21:29:11 +00:00
w_powl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_remainder_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_remainder_template.c
w_remainder.c fix drem symbol for static linking and new targets 2017-10-03 14:31:59 +01:00
w_remainderf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_remainderf.c fix drem symbol for static linking and new targets 2017-10-03 14:31:59 +01:00
w_remainderl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_remainderl.c fix drem symbol for static linking and new targets 2017-10-03 14:31:59 +01:00
w_scalb_compat.c Prefer new libm function wrappers for !LIBM_SVID_COMPAT. 2017-09-05 23:35:55 +00:00
w_scalbf_compat.c Prefer new libm function wrappers for !LIBM_SVID_COMPAT. 2017-09-05 23:35:55 +00:00
w_scalbl_compat.c Prefer new libm function wrappers for !LIBM_SVID_COMPAT. 2017-09-05 23:35:55 +00:00
w_scalbln_template.c Clear up log1p, ldexp, scalbn, scalbln compat handling. 2017-09-13 15:47:26 +00:00
w_sinh_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_sinh_template.c
w_sinhf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_sinhl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_sqrt_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_sqrt_template.c
w_sqrtf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_sqrtl_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00
w_tgamma_compat.c Use libm_alias_double in math/. 2017-09-15 23:10:02 +00:00
w_tgamma_template.c
w_tgammaf_compat.c Use libm_alias_float in math/. 2017-09-15 17:12:02 +00:00
w_tgammal_compat.c Use libm_alias_ldouble in math/. 2017-09-18 17:51:33 +00:00

README for libm-test math test suite
====================================

The libm-test math test suite tests a number of function points of
math functions in the GNU C library.  The following sections contain a
brief overview.  Please note that the test drivers and the Perl script
"gen-libm-test.pl" have some options.  A full list of options is
available with --help (for the test drivers) and -h for
"gen-libm-test.pl".


What is tested?
===============
The tests just evaluate the functions at specified points and compare
the results with precomputed values and the requirements of the ISO
C99 standard.

Besides testing the special values mandated by IEEE 754 (infinities,
NaNs and minus zero), some more or less random values are tested.

Files that are part of libm-test
================================

The main files are "libm-test-<func>.inc".  They are independent of
the target platform and the specific real floating type and format and
contain placeholder test "templates" for math functions defined in
libm.  These files, along with generated files named
"auto-libm-test-out-<func>", are preprocessed by the Perl script
"gen-libm-test.pl" to expand the templates and produce a set of test
cases for each math function that are specific to the target platform
but still independent of the real floating type.  The results of the
processing are "libm-test-<func>.c" and a file "libm-test-ulps.h" with
platform specific deltas by which the actual math function results may
deviate from the expected results and still be considered correct.

The test drivers "test-double-<func>.c", "test-float-<func>.c", and
"test-ldouble-<func>.c", generated by the Makefile, test the normal
double, float and long double implementation of libm.  The test
drivers with an 'i' in their name ("test-idouble-<func>.c",
"test-ifloat-<func>.c", and "test-ildoubl-<func>.c") test the
corresponding inline functions (where available - otherwise they also
test the real functions in libm).  Each driver selects the desired
real floating type to exercise the math functions to test with (float,
double, or long double) by defining a small set of macros just before
including the generic "libm-test.c" file.  Each driver also either
defines or undefines the __NO_MATH_INLINES macro just before including
"libm-test-<func>.c" to select either the real or inline functions,
respectively.  Each driver is compiled into a single executable test
program with the corresponding name.

As mentioned above, the "gen-libm-test.pl" script looks for a file
named "libm-test-ulps" in the platform specific sysdep directory (or
its fpu or nofpu subdirectory) and for each variant (real floating
type and rounding mode) of every tested function reads from it the
maximum difference expressed as Units of Least Precision (ULP) the
actual result of the function may deviate from the expected result
before it's considered incorrect.

The "auto-libm-test-out-<func>" files contain sets of test cases to
exercise, the conditions under which to exercise each, and the
expected results.  The files are generated by the
"gen-auto-libm-tests" program from the "auto-libm-test-in" file.  See
the comments in gen-auto-libm-tests.c for details about the content
and format of the -in and -out files.

How can I generate "libm-test-ulps"?
====================================

To automatically generate a new "libm-test-ulps" run "make regen-ulps".
This generates the file "math/NewUlps" in the build directory.  The file
contains the sorted results of all the tests.  You can use the "NewUlps"
file as the machine's updated "libm-test-ulps" file.  Copy "NewUlps" to
"libm-test-ulps" in the appropriate machine sysdep directory.  Verify
the changes, post your patch, and check it in after review.

To manually generate a new "libm-test-ulps" file, first remove "ULPs"
file in the current directory, then you can execute for example:
    ./testrun.sh math/test-double -u --ignore-max-ulp=yes
This generates a file "ULPs" with all double ULPs in it, ignoring any
previously calculated ULPs, and running with the newly built dynamic
loader and math library (assumes you didn't install your build).  Now
generate the ULPs for all other formats, the tests will be appending the
data to the "ULPs" file.  As final step run "gen-libm-test.pl" with the
file as input and ask to generate a pretty printed output in the file
"NewUlps":
  gen-libm-test.pl -u ULPs -n NewUlps
Copy "NewUlps" to "libm-test-ulps" in the appropriate machine sysdep
directory.

Note that the test drivers have an option "-u" to output an unsorted
list of all epsilons that the functions have.  The output can be read
in directly but it's better to pretty print it first.
"gen-libm-test.pl" has an option to generate a pretty-printed and
sorted new ULPs file from the output of the test drivers.

Contents of libm-test-ulps
==========================

Since libm-test-ulps can be generated automatically, just a few notes.
The file contains lines for maximal errors of single functions, like:

Function "yn":
idouble: 6

The keywords are float, ifloat, double, idouble, ldouble and ildouble
(the prefix i stands for inline).

Adding tests to libm-test-<func>.inc
====================================

The tests are evaluated by a set of special test macros.  The macros
start with "TEST_" followed by a specification the input values, an
underscore and a specification of the output values.  As an example,
the test macro for a function with input of type FLOAT (FLOAT is
either float, double, long double) and output of type FLOAT is
"TEST_f_f".  The macro's parameter are the name of the function, the
input parameter, output parameter and optionally one exception
parameter.

The accepted parameter types are:
- "f" for FLOAT
- "j" for long double.
- "b" for boolean - just tests if the output parameter evaluates to 0
  or 1 (only for output).
- "c" for complex.  This parameter needs two values, first the real,
  then the imaginary part.
- "i" for int.
- "l" for long int.
- "L" for long long int.
- "u" for unsigned int.
- "M" for intmax_t.
- "U" for uintmax_t.
- "p" for an argument (described in the previous character) passed
  through a pointer rather than directly.
- "F" for the address of a FLOAT (only as input parameter)
- "I" for the address of an int (only as input parameter)
- "1" for an additional output (either output through a pointer passed
  as an argument, or to a global variable such as signgam).

How to read the test output
===========================

Running each test on its own at the default level of verbosity will
print on stdout a line describing the implementation of math functions
exercised by the test (float, double, or long double), along with
whether the inline set has been selected, regardless of whether or
not any inline functions actually exist.  This is then followed by
the details of test failures (if any).  The output concludes by
a summary listing the number of test cases exercised and the number
of test failures uncovered.

For each test failure (and for each test case at higher levels of
verbosity), the output contains the name of the function under test
and its arguments or conditions that triggered the failure.  Note
that the name of the function in the output need not correspond
exactly to the name of the math function actually invoked. For example,
the output will refer to the "acos" function even if the actual function
under test is acosf (for the float version) or acosl (for the long
double version).  Also note that the function arguments may be shown
in either the decimal or the  hexadecimal floating point format which
may or may not correspond to the format used in the auto-libm-test-in
file. Besides the name of the function, for each test failure the
output contains the actual and expected results and the difference
between the two, printed in both the decimal and hexadecimal
floating point format, and the ULP and maximum ULP for the test
case.