mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
float128: Add test-{float128,ifloat128,float128-finite}
This adds test support for float128, and lays some groundwork for future _FloatN types. * math/gen-libm-test.pl (@all_floats): Add ifloat128 and float128. (%all_floats_pfx): Add macro prefix for float128 (FLT128). * math/libm-test-exp10.inc (pow10_test): Do not test for _FloatN, * math/libm-test-isfinite.inc (finite_test): Likewise. * math/libm-test-lgamma.inc (gamma_test): Likewise. * math/libm-test-nexttoward.inc (nexttoward_test): Likewise. (nexttoward_test_data}: Likewise. * math/libm-test-remainder.inc (drem_test): Likewise. * math/libm-test-scalb.inc (scalb_test): Likewise. (scalb_test_data): Likewise. * math/libm-test-significand.inc (significand_test): Likewise. (significand_test_data): Likewise. * math/libm-test-support.c (check_complex): Replace __complex__ FLOAT with CFLOAT to get the support for old compiler. * math/libm-test-support.h (check_complex): Likewise. * math/test-double.h (CFLOAT, TEST_FLOATN): New macros. * math/test-float.h (CFLOAT, TEST_FLOATN): Likewise. * math/test-ldouble.h (CFLOAT, TEST_FLOATN): Likewise. * math/test-float128.h: New file. * math/test-math-floatn.h: New file.
This commit is contained in:
committed by
Gabriel F. T. Gomes
parent
8fd3101431
commit
3c023dbf57
@ -20,6 +20,7 @@
|
||||
|
||||
static const struct test_ff_f_data scalb_test_data[] =
|
||||
{
|
||||
#if !TEST_FLOATN
|
||||
/* Results in this case are unspecified by POSIX, so, for an
|
||||
otherwise fully-determined function, spurious "inexact"
|
||||
exceptions are OK. */
|
||||
@ -144,12 +145,15 @@ static const struct test_ff_f_data scalb_test_data[] =
|
||||
|
||||
TEST_ff_f (scalb, 0.8L, 4, 12.8L, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
|
||||
TEST_ff_f (scalb, -0.854375L, 5, -27.34L, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
|
||||
#endif
|
||||
};
|
||||
|
||||
static void
|
||||
scalb_test (void)
|
||||
{
|
||||
#if !TEST_FLOATN
|
||||
ALL_RM_TEST (scalb, 1, scalb_test_data, RUN_TEST_LOOP_ff_f, END);
|
||||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
|
Reference in New Issue
Block a user