aboutsummaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/fail.c2
-rw-r--r--source/fail.h2
-rw-r--r--source/functionInfos.c24
-rw-r--r--source/functions.h27
-rw-r--r--source/functions_common.c11
-rw-r--r--source/genCases.h6
-rw-r--r--source/genCases_common.c2
-rw-r--r--source/genCases_extF80.c2
-rw-r--r--source/genCases_f128.c2
-rw-r--r--source/genCases_f16.c2
-rw-r--r--source/genCases_f32.c2
-rw-r--r--source/genCases_f64.c8
-rw-r--r--source/genCases_i32.c2
-rw-r--r--source/genCases_i64.c2
-rw-r--r--source/genCases_ui32.c2
-rw-r--r--source/genCases_ui64.c2
-rw-r--r--source/genCases_writeTestsTotal.c2
-rw-r--r--source/genLoops.c82
-rw-r--r--source/genLoops.h37
-rw-r--r--source/random.c2
-rw-r--r--source/random.h2
-rw-r--r--source/readHex.c2
-rw-r--r--source/readHex.h2
-rw-r--r--source/slowfloat.c102
-rw-r--r--source/slowfloat.h22
-rw-r--r--source/standardFunctionInfos.c24
-rw-r--r--source/subj-C/subjfloat.c132
-rw-r--r--source/subj-C/subjfloat_config.h24
-rw-r--r--source/subjfloat.h26
-rw-r--r--source/subjfloat_functions.c24
-rw-r--r--source/testLoops.h39
-rw-r--r--source/testLoops_common.c2
-rw-r--r--source/test_a_extF80_z_f128.c2
-rw-r--r--source/test_a_extF80_z_f16.c2
-rw-r--r--source/test_a_extF80_z_f32.c2
-rw-r--r--source/test_a_extF80_z_f64.c10
-rw-r--r--source/test_a_extF80_z_i32_rx.c2
-rw-r--r--source/test_a_extF80_z_i32_x.c2
-rw-r--r--source/test_a_extF80_z_i64_rx.c2
-rw-r--r--source/test_a_extF80_z_i64_x.c2
-rw-r--r--source/test_a_extF80_z_ui32_rx.c2
-rw-r--r--source/test_a_extF80_z_ui32_x.c2
-rw-r--r--source/test_a_extF80_z_ui64_rx.c2
-rw-r--r--source/test_a_extF80_z_ui64_x.c2
-rw-r--r--source/test_a_f128_z_extF80.c8
-rw-r--r--source/test_a_f128_z_f16.c2
-rw-r--r--source/test_a_f128_z_f32.c8
-rw-r--r--source/test_a_f128_z_f64.c8
-rw-r--r--source/test_a_f128_z_i32_rx.c2
-rw-r--r--source/test_a_f128_z_i32_x.c2
-rw-r--r--source/test_a_f128_z_i64_rx.c2
-rw-r--r--source/test_a_f128_z_i64_x.c2
-rw-r--r--source/test_a_f128_z_ui32_rx.c2
-rw-r--r--source/test_a_f128_z_ui32_x.c2
-rw-r--r--source/test_a_f128_z_ui64_rx.c2
-rw-r--r--source/test_a_f128_z_ui64_x.c2
-rw-r--r--source/test_a_f16_z_extF80.c6
-rw-r--r--source/test_a_f16_z_f128.c6
-rw-r--r--source/test_a_f16_z_f32.c6
-rw-r--r--source/test_a_f16_z_f64.c8
-rw-r--r--source/test_a_f16_z_i32_rx.c12
-rw-r--r--source/test_a_f16_z_i32_x.c12
-rw-r--r--source/test_a_f16_z_i64_rx.c12
-rw-r--r--source/test_a_f16_z_i64_x.c12
-rw-r--r--source/test_a_f16_z_ui32_rx.c12
-rw-r--r--source/test_a_f16_z_ui32_x.c12
-rw-r--r--source/test_a_f16_z_ui64_rx.c12
-rw-r--r--source/test_a_f16_z_ui64_x.c12
-rw-r--r--source/test_a_f32_z_extF80.c8
-rw-r--r--source/test_a_f32_z_f128.c2
-rw-r--r--source/test_a_f32_z_f16.c2
-rw-r--r--source/test_a_f32_z_f64.c10
-rw-r--r--source/test_a_f32_z_i32_rx.c2
-rw-r--r--source/test_a_f32_z_i32_x.c2
-rw-r--r--source/test_a_f32_z_i64_rx.c2
-rw-r--r--source/test_a_f32_z_i64_x.c2
-rw-r--r--source/test_a_f32_z_ui32_rx.c2
-rw-r--r--source/test_a_f32_z_ui32_x.c2
-rw-r--r--source/test_a_f32_z_ui64_rx.c2
-rw-r--r--source/test_a_f32_z_ui64_x.c2
-rw-r--r--source/test_a_f64_z_extF80.c10
-rw-r--r--source/test_a_f64_z_f128.c8
-rw-r--r--source/test_a_f64_z_f16.c6
-rw-r--r--source/test_a_f64_z_f32.c10
-rw-r--r--source/test_a_f64_z_i32_rx.c10
-rw-r--r--source/test_a_f64_z_i32_x.c10
-rw-r--r--source/test_a_f64_z_i64_rx.c10
-rw-r--r--source/test_a_f64_z_i64_x.c10
-rw-r--r--source/test_a_f64_z_ui32_rx.c10
-rw-r--r--source/test_a_f64_z_ui32_x.c10
-rw-r--r--source/test_a_f64_z_ui64_rx.c10
-rw-r--r--source/test_a_f64_z_ui64_x.c10
-rw-r--r--source/test_a_i32_z_extF80.c8
-rw-r--r--source/test_a_i32_z_f128.c2
-rw-r--r--source/test_a_i32_z_f16.c2
-rw-r--r--source/test_a_i32_z_f32.c2
-rw-r--r--source/test_a_i32_z_f64.c10
-rw-r--r--source/test_a_i64_z_extF80.c8
-rw-r--r--source/test_a_i64_z_f128.c2
-rw-r--r--source/test_a_i64_z_f16.c2
-rw-r--r--source/test_a_i64_z_f32.c2
-rw-r--r--source/test_a_i64_z_f64.c12
-rw-r--r--source/test_a_ui32_z_extF80.c8
-rw-r--r--source/test_a_ui32_z_f128.c2
-rw-r--r--source/test_a_ui32_z_f16.c2
-rw-r--r--source/test_a_ui32_z_f32.c2
-rw-r--r--source/test_a_ui32_z_f64.c10
-rw-r--r--source/test_a_ui64_z_extF80.c8
-rw-r--r--source/test_a_ui64_z_f128.c2
-rw-r--r--source/test_a_ui64_z_f16.c2
-rw-r--r--source/test_a_ui64_z_f32.c2
-rw-r--r--source/test_a_ui64_z_f64.c12
-rw-r--r--source/test_ab_extF80_z_bool.c2
-rw-r--r--source/test_ab_f128_z_bool.c9
-rw-r--r--source/test_ab_f16_z_bool.c6
-rw-r--r--source/test_ab_f32_z_bool.c8
-rw-r--r--source/test_ab_f64_z_bool.c10
-rw-r--r--source/test_abcz_f128.c12
-rw-r--r--source/test_abcz_f16.c6
-rw-r--r--source/test_abcz_f32.c8
-rw-r--r--source/test_abcz_f64.c12
-rw-r--r--source/test_abz_extF80.c8
-rw-r--r--source/test_abz_f128.c9
-rw-r--r--source/test_abz_f16.c6
-rw-r--r--source/test_abz_f32.c8
-rw-r--r--source/test_abz_f64.c10
-rw-r--r--source/test_az_extF80.c8
-rw-r--r--source/test_az_extF80_rx.c8
-rw-r--r--source/test_az_f128.c2
-rw-r--r--source/test_az_f128_rx.c2
-rw-r--r--source/test_az_f16.c6
-rw-r--r--source/test_az_f16_rx.c6
-rw-r--r--source/test_az_f32.c2
-rw-r--r--source/test_az_f32_rx.c2
-rw-r--r--source/test_az_f64.c12
-rw-r--r--source/test_az_f64_rx.c12
-rw-r--r--source/testfloat.c83
-rw-r--r--source/testfloat_gen.c46
-rw-r--r--source/testfloat_ver.c40
-rw-r--r--source/testsoftfloat.c44
-rw-r--r--source/timesoftfloat.c144
-rw-r--r--source/uint128.c2
-rw-r--r--source/uint128.h2
-rw-r--r--source/uint128_inline.c2
-rw-r--r--source/verCases.h15
-rw-r--r--source/verCases_common.c9
-rw-r--r--source/verCases_inline.c10
-rw-r--r--source/verCases_writeFunctionName.c11
-rw-r--r--source/verLoops.c191
-rw-r--r--source/verLoops.h34
-rw-r--r--source/writeCase.h35
-rw-r--r--source/writeCase_a_extF80M.c2
-rw-r--r--source/writeCase_a_f128M.c2
-rw-r--r--source/writeCase_a_f16.c8
-rw-r--r--source/writeCase_a_f32.c2
-rw-r--r--source/writeCase_a_f64.c10
-rw-r--r--source/writeCase_a_ui32.c2
-rw-r--r--source/writeCase_a_ui64.c2
-rw-r--r--source/writeCase_ab_extF80M.c2
-rw-r--r--source/writeCase_ab_f128M.c12
-rw-r--r--source/writeCase_ab_f16.c8
-rw-r--r--source/writeCase_ab_f32.c10
-rw-r--r--source/writeCase_ab_f64.c10
-rw-r--r--source/writeCase_abc_extF80M.c65
-rw-r--r--source/writeCase_abc_f128M.c14
-rw-r--r--source/writeCase_abc_f16.c14
-rw-r--r--source/writeCase_abc_f32.c8
-rw-r--r--source/writeCase_abc_f64.c16
-rw-r--r--source/writeCase_z_bool.c2
-rw-r--r--source/writeCase_z_extF80M.c8
-rw-r--r--source/writeCase_z_f128M.c2
-rw-r--r--source/writeCase_z_f16.c8
-rw-r--r--source/writeCase_z_f32.c2
-rw-r--r--source/writeCase_z_f64.c10
-rw-r--r--source/writeCase_z_ui32.c2
-rw-r--r--source/writeCase_z_ui64.c2
-rw-r--r--source/writeHex.c10
-rw-r--r--source/writeHex.h6
178 files changed, 1325 insertions, 826 deletions
diff --git a/source/fail.c b/source/fail.c
index 732218a..1177389 100644
--- a/source/fail.c
+++ b/source/fail.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/fail.h b/source/fail.h
index 6a4519a..fa9438c 100644
--- a/source/fail.h
+++ b/source/fail.h
@@ -1,7 +1,7 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/functionInfos.c b/source/functionInfos.c
index 1828c6a..f5b9f9d 100644
--- a/source/functionInfos.c
+++ b/source/functionInfos.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -59,7 +59,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "ui32_to_f16", ARG_1 | EFF_R },
#endif
{ "ui32_to_f32", ARG_1 | EFF_R },
+#ifdef FLOAT64
{ "ui32_to_f64", ARG_1 },
+#endif
#ifdef EXTFLOAT80
{ "ui32_to_extF80", ARG_1 },
#endif
@@ -70,7 +72,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "ui64_to_f16", ARG_1 | EFF_R },
#endif
{ "ui64_to_f32", ARG_1 | EFF_R },
+#ifdef FLOAT64
{ "ui64_to_f64", ARG_1 | EFF_R },
+#endif
#ifdef EXTFLOAT80
{ "ui64_to_extF80", ARG_1 },
#endif
@@ -81,7 +85,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "i32_to_f16", ARG_1 | EFF_R },
#endif
{ "i32_to_f32", ARG_1 | EFF_R },
+#ifdef FLOAT64
{ "i32_to_f64", ARG_1 },
+#endif
#ifdef EXTFLOAT80
{ "i32_to_extF80", ARG_1 },
#endif
@@ -92,7 +98,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "i64_to_f16", ARG_1 | EFF_R },
#endif
{ "i64_to_f32", ARG_1 | EFF_R },
+#ifdef FLOAT64
{ "i64_to_f64", ARG_1 | EFF_R },
+#endif
#ifdef EXTFLOAT80
{ "i64_to_extF80", ARG_1 },
#endif
@@ -111,7 +119,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "f16_to_i32_r_minMag", ARG_1 | ARG_E },
{ "f16_to_i64_r_minMag", ARG_1 | ARG_E },
{ "f16_to_f32", ARG_1 },
+#ifdef FLOAT64
{ "f16_to_f64", ARG_1 },
+#endif
#ifdef EXTFLOAT80
{ "f16_to_extF80", ARG_1 },
#endif
@@ -146,7 +156,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
#ifdef FLOAT16
{ "f32_to_f16", ARG_1 | EFF_R | EFF_T },
#endif
+#ifdef FLOAT64
{ "f32_to_f64", ARG_1 },
+#endif
#ifdef EXTFLOAT80
{ "f32_to_extF80", ARG_1 },
#endif
@@ -169,6 +181,7 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "f32_lt_quiet", ARG_2 },
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
+#ifdef FLOAT64
{ "f64_to_ui32", ARG_1 | ARG_R | ARG_E },
{ "f64_to_ui64", ARG_1 | ARG_R | ARG_E },
{ "f64_to_i32", ARG_1 | ARG_R | ARG_E },
@@ -201,6 +214,7 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "f64_eq_signaling", ARG_2 },
{ "f64_le_quiet", ARG_2 },
{ "f64_lt_quiet", ARG_2 },
+#endif
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -216,7 +230,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "extF80_to_f16", ARG_1 | EFF_R | EFF_T },
#endif
{ "extF80_to_f32", ARG_1 | EFF_R | EFF_T },
+#ifdef FLOAT64
{ "extF80_to_f64", ARG_1 | EFF_R | EFF_T },
+#endif
#ifdef FLOAT128
{ "extF80_to_f128", ARG_1 },
#endif
@@ -249,7 +265,9 @@ const struct functionInfo functionInfos[NUM_FUNCTIONS] = {
{ "f128_to_f16", ARG_1 | EFF_R | EFF_T },
#endif
{ "f128_to_f32", ARG_1 | EFF_R | EFF_T },
+#ifdef FLOAT64
{ "f128_to_f64", ARG_1 | EFF_R | EFF_T },
+#endif
#ifdef EXTFLOAT80
{ "f128_to_extF80", ARG_1 | EFF_R | EFF_T },
#endif
diff --git a/source/functions.h b/source/functions.h
index 3c128cf..e92572d 100644
--- a/source/functions.h
+++ b/source/functions.h
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -49,7 +49,9 @@ enum {
#else
UI32_TO_F32 = 1,
#endif
+#ifdef FLOAT64
UI32_TO_F64,
+#endif
#ifdef EXTFLOAT80
UI32_TO_EXTF80,
#endif
@@ -60,7 +62,9 @@ enum {
UI64_TO_F16,
#endif
UI64_TO_F32,
+#ifdef FLOAT64
UI64_TO_F64,
+#endif
#ifdef EXTFLOAT80
UI64_TO_EXTF80,
#endif
@@ -71,7 +75,9 @@ enum {
I32_TO_F16,
#endif
I32_TO_F32,
+#ifdef FLOAT64
I32_TO_F64,
+#endif
#ifdef EXTFLOAT80
I32_TO_EXTF80,
#endif
@@ -82,7 +88,9 @@ enum {
I64_TO_F16,
#endif
I64_TO_F32,
+#ifdef FLOAT64
I64_TO_F64,
+#endif
#ifdef EXTFLOAT80
I64_TO_EXTF80,
#endif
@@ -101,7 +109,9 @@ enum {
F16_TO_I32_R_MINMAG,
F16_TO_I64_R_MINMAG,
F16_TO_F32,
+#ifdef FLOAT64
F16_TO_F64,
+#endif
#ifdef EXTFLOAT80
F16_TO_EXTF80,
#endif
@@ -136,7 +146,9 @@ enum {
#ifdef FLOAT16
F32_TO_F16,
#endif
+#ifdef FLOAT64
F32_TO_F64,
+#endif
#ifdef EXTFLOAT80
F32_TO_EXTF80,
#endif
@@ -159,6 +171,7 @@ enum {
F32_LT_QUIET,
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
+#ifdef FLOAT64
F64_TO_UI32,
F64_TO_UI64,
F64_TO_I32,
@@ -191,6 +204,7 @@ enum {
F64_EQ_SIGNALING,
F64_LE_QUIET,
F64_LT_QUIET,
+#endif
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -206,7 +220,9 @@ enum {
EXTF80_TO_F16,
#endif
EXTF80_TO_F32,
+#ifdef FLOAT64
EXTF80_TO_F64,
+#endif
#ifdef FLOAT128
EXTF80_TO_F128,
#endif
@@ -239,7 +255,9 @@ enum {
F128_TO_F16,
#endif
F128_TO_F32,
+#ifdef FLOAT64
F128_TO_F64,
+#endif
#ifdef EXTFLOAT80
F128_TO_EXTF80,
#endif
@@ -267,6 +285,9 @@ enum {
ROUND_MIN,
ROUND_MAX,
ROUND_NEAR_MAXMAG,
+#ifdef FLOAT_ROUND_ODD
+ ROUND_ODD,
+#endif
NUM_ROUNDINGMODES
};
enum {
diff --git a/source/functions_common.c b/source/functions_common.c
index 0e979ea..d8d7cbf 100644
--- a/source/functions_common.c
+++ b/source/functions_common.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -46,7 +46,10 @@ const uint_fast8_t roundingModes[NUM_ROUNDINGMODES] = {
softfloat_round_minMag,
softfloat_round_min,
softfloat_round_max,
- softfloat_round_near_maxMag
+ softfloat_round_near_maxMag,
+#ifdef FLOAT_ROUND_ODD
+ softfloat_round_odd
+#endif
};
const uint_fast8_t tininessModes[NUM_TININESSMODES] = {
diff --git a/source/genCases.h b/source/genCases.h
index 63c6a3e..24dc20b 100644
--- a/source/genCases.h
+++ b/source/genCases.h
@@ -1,11 +1,11 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -80,6 +80,7 @@ void genCases_f32_abc_init( void );
void genCases_f32_abc_next( void );
extern float32_t genCases_f32_a, genCases_f32_b, genCases_f32_c;
+#ifdef FLOAT64
void genCases_f64_a_init( void );
void genCases_f64_a_next( void );
void genCases_f64_ab_init( void );
@@ -87,6 +88,7 @@ void genCases_f64_ab_next( void );
void genCases_f64_abc_init( void );
void genCases_f64_abc_next( void );
extern float64_t genCases_f64_a, genCases_f64_b, genCases_f64_c;
+#endif
#ifdef EXTFLOAT80
void genCases_extF80_a_init( void );
diff --git a/source/genCases_common.c b/source/genCases_common.c
index 28da76b..1192d57 100644
--- a/source/genCases_common.c
+++ b/source/genCases_common.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_extF80.c b/source/genCases_extF80.c
index e5a552c..10ecd42 100644
--- a/source/genCases_extF80.c
+++ b/source/genCases_extF80.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_f128.c b/source/genCases_f128.c
index d02b991..0ca78fa 100644
--- a/source/genCases_f128.c
+++ b/source/genCases_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_f16.c b/source/genCases_f16.c
index c5aa1b7..2d59d5a 100644
--- a/source/genCases_f16.c
+++ b/source/genCases_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_f32.c b/source/genCases_f32.c
index 7e81530..7dcb8ca 100644
--- a/source/genCases_f32.c
+++ b/source/genCases_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_f64.c b/source/genCases_f64.c
index 1ef34be..4b151b6 100644
--- a/source/genCases_f64.c
+++ b/source/genCases_f64.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -42,6 +42,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "softfloat.h"
#include "genCases.h"
+#ifdef FLOAT64
+
struct sequence {
int expNum, term1Num, term2Num;
bool done;
@@ -802,3 +804,5 @@ void genCases_f64_abc_next( void )
}
+#endif
+
diff --git a/source/genCases_i32.c b/source/genCases_i32.c
index ff6ac15..6c9c50f 100644
--- a/source/genCases_i32.c
+++ b/source/genCases_i32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_i64.c b/source/genCases_i64.c
index a7daf0c..c348d51 100644
--- a/source/genCases_i64.c
+++ b/source/genCases_i64.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_ui32.c b/source/genCases_ui32.c
index 08c978f..49658dc 100644
--- a/source/genCases_ui32.c
+++ b/source/genCases_ui32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_ui64.c b/source/genCases_ui64.c
index 9e28757..7dc5629 100644
--- a/source/genCases_ui64.c
+++ b/source/genCases_ui64.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genCases_writeTestsTotal.c b/source/genCases_writeTestsTotal.c
index 833cda4..28b8dab 100644
--- a/source/genCases_writeTestsTotal.c
+++ b/source/genCases_writeTestsTotal.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/genLoops.c b/source/genLoops.c
index f8a843a..c855edd 100644
--- a/source/genLoops.c
+++ b/source/genLoops.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -38,6 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
+#include <signal.h>
#include "platform.h"
#include "uint128.h"
#include "fail.h"
@@ -46,7 +47,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "genLoops.h"
-volatile bool genLoops_stop = false;
+volatile sig_atomic_t genLoops_stop = false;
bool genLoops_forever;
bool genLoops_givenCount;
@@ -57,7 +58,9 @@ uint_fast8_t *genLoops_trueFlagsPtr;
union ui16_f16 { uint16_t ui; float16_t f; };
#endif
union ui32_f32 { uint32_t ui; float32_t f; };
+#ifdef FLOAT64
union ui64_f64 { uint64_t ui; float64_t f; };
+#endif
static void checkEnoughCases( void )
{
@@ -391,6 +394,8 @@ void gen_abc_f32( void )
}
+#ifdef FLOAT64
+
void gen_a_f64( void )
{
union ui64_f64 uA;
@@ -451,6 +456,8 @@ void gen_abc_f64( void )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_extF80( void )
@@ -601,6 +608,8 @@ void gen_a_ui32_z_f32( float32_t trueFunction( uint32_t ) )
}
+#ifdef FLOAT64
+
void gen_a_ui32_z_f64( float64_t trueFunction( uint32_t ) )
{
union ui64_f64 uTrueZ;
@@ -619,6 +628,8 @@ void gen_a_ui32_z_f64( float64_t trueFunction( uint32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_ui32_z_extF80( void trueFunction( uint32_t, extFloat80_t * ) )
@@ -703,6 +714,8 @@ void gen_a_ui64_z_f32( float32_t trueFunction( uint64_t ) )
}
+#ifdef FLOAT64
+
void gen_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
{
union ui64_f64 uTrueZ;
@@ -721,6 +734,8 @@ void gen_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_ui64_z_extF80( void trueFunction( uint64_t, extFloat80_t * ) )
@@ -805,6 +820,8 @@ void gen_a_i32_z_f32( float32_t trueFunction( int32_t ) )
}
+#ifdef FLOAT64
+
void gen_a_i32_z_f64( float64_t trueFunction( int32_t ) )
{
union ui64_f64 uTrueZ;
@@ -823,6 +840,8 @@ void gen_a_i32_z_f64( float64_t trueFunction( int32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_i32_z_extF80( void trueFunction( int32_t, extFloat80_t * ) )
@@ -907,6 +926,8 @@ void gen_a_i64_z_f32( float32_t trueFunction( int64_t ) )
}
+#ifdef FLOAT64
+
void gen_a_i64_z_f64( float64_t trueFunction( int64_t ) )
{
union ui64_f64 uTrueZ;
@@ -925,6 +946,8 @@ void gen_a_i64_z_f64( float64_t trueFunction( int64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_i64_z_extF80( void trueFunction( int64_t, extFloat80_t * ) )
@@ -1177,6 +1200,8 @@ void gen_a_f16_z_f32( float32_t trueFunction( float16_t ) )
}
+#ifdef FLOAT64
+
void gen_a_f16_z_f64( float64_t trueFunction( float16_t ) )
{
union ui16_f16 uA;
@@ -1197,6 +1222,8 @@ void gen_a_f16_z_f64( float64_t trueFunction( float16_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_f16_z_extF80( void trueFunction( float16_t, extFloat80_t * ) )
@@ -1566,6 +1593,8 @@ void gen_a_f32_z_f16( float16_t trueFunction( float32_t ) )
#endif
+#ifdef FLOAT64
+
void gen_a_f32_z_f64( float64_t trueFunction( float32_t ) )
{
union ui32_f32 uA;
@@ -1586,6 +1615,8 @@ void gen_a_f32_z_f64( float64_t trueFunction( float32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void gen_a_f32_z_extF80( void trueFunction( float32_t, extFloat80_t * ) )
@@ -1743,6 +1774,8 @@ void gen_ab_f32_z_bool( bool trueFunction( float32_t, float32_t ) )
}
+#ifdef FLOAT64
+
void
gen_a_f64_z_ui32_rx(
uint_fast32_t trueFunction( float64_t, uint_fast8_t, bool ),
@@ -2130,6 +2163,8 @@ void gen_ab_f64_z_bool( bool trueFunction( float64_t, float64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void
@@ -2344,6 +2379,8 @@ void gen_a_extF80_z_f32( float32_t trueFunction( const extFloat80_t * ) )
}
+#ifdef FLOAT64
+
void gen_a_extF80_z_f64( float64_t trueFunction( const extFloat80_t * ) )
{
union ui64_f64 uTrueZ;
@@ -2362,6 +2399,8 @@ void gen_a_extF80_z_f64( float64_t trueFunction( const extFloat80_t * ) )
}
+#endif
+
#ifdef FLOAT128
void
@@ -2452,37 +2491,6 @@ void
}
void
- gen_abcz_extF80(
- void
- trueFunction(
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- extFloat80_t *
- )
- )
-{
- extFloat80_t trueZ;
- uint_fast8_t trueFlags;
-
- genCases_extF80_abc_init();
- checkEnoughCases();
- while ( ! genLoops_stop && (! genCases_done || genLoops_forever) ) {
- genCases_extF80_abc_next();
- writeHex_uiExtF80M( &genCases_extF80_a, ' ' );
- writeHex_uiExtF80M( &genCases_extF80_b, ' ' );
- writeHex_uiExtF80M( &genCases_extF80_c, ' ' );
- *genLoops_trueFlagsPtr = 0;
- trueFunction(
- &genCases_extF80_a, &genCases_extF80_b, &genCases_extF80_c, &trueZ
- );
- trueFlags = *genLoops_trueFlagsPtr;
- if ( writeGenOutputs_extF80M( &trueZ, trueFlags ) ) break;
- }
-
-}
-
-void
gen_ab_extF80_z_bool(
bool trueFunction( const extFloat80_t *, const extFloat80_t * ) )
{
@@ -2719,6 +2727,8 @@ void gen_a_f128_z_f32( float32_t trueFunction( const float128_t * ) )
}
+#ifdef FLOAT64
+
void gen_a_f128_z_f64( float64_t trueFunction( const float128_t * ) )
{
union ui64_f64 uTrueZ;
@@ -2737,6 +2747,8 @@ void gen_a_f128_z_f64( float64_t trueFunction( const float128_t * ) )
}
+#endif
+
#ifdef EXTFLOAT80
void
diff --git a/source/genLoops.h b/source/genLoops.h
index 2125a96..0ea24ab 100644
--- a/source/genLoops.h
+++ b/source/genLoops.h
@@ -1,11 +1,11 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -37,9 +37,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <stdbool.h>
#include <stdint.h>
+#include <signal.h>
#include "softfloat.h"
-extern volatile bool genLoops_stop;
+extern volatile sig_atomic_t genLoops_stop;
extern bool genLoops_forever;
extern bool genLoops_givenCount;
@@ -58,9 +59,11 @@ void gen_abc_f16( void );
void gen_a_f32( void );
void gen_ab_f32( void );
void gen_abc_f32( void );
+#ifdef FLOAT64
void gen_a_f64( void );
void gen_ab_f64( void );
void gen_abc_f64( void );
+#endif
#ifdef EXTFLOAT80
void gen_a_extF80( void );
void gen_ab_extF80( void );
@@ -76,7 +79,9 @@ void gen_abc_f128( void );
void gen_a_ui32_z_f16( float16_t ( uint32_t ) );
#endif
void gen_a_ui32_z_f32( float32_t ( uint32_t ) );
+#ifdef FLOAT64
void gen_a_ui32_z_f64( float64_t ( uint32_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_ui32_z_extF80( void ( uint32_t, extFloat80_t * ) );
#endif
@@ -87,7 +92,9 @@ void gen_a_ui32_z_f128( void ( uint32_t, float128_t * ) );
void gen_a_ui64_z_f16( float16_t ( uint64_t ) );
#endif
void gen_a_ui64_z_f32( float32_t ( uint64_t ) );
+#ifdef FLOAT64
void gen_a_ui64_z_f64( float64_t ( uint64_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_ui64_z_extF80( void ( uint64_t, extFloat80_t * ) );
#endif
@@ -98,7 +105,9 @@ void gen_a_ui64_z_f128( void ( uint64_t, float128_t * ) );
void gen_a_i32_z_f16( float16_t ( int32_t ) );
#endif
void gen_a_i32_z_f32( float32_t ( int32_t ) );
+#ifdef FLOAT64
void gen_a_i32_z_f64( float64_t ( int32_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_i32_z_extF80( void ( int32_t, extFloat80_t * ) );
#endif
@@ -109,7 +118,9 @@ void gen_a_i32_z_f128( void ( int32_t, float128_t * ) );
void gen_a_i64_z_f16( float16_t ( int64_t ) );
#endif
void gen_a_i64_z_f32( float32_t ( int64_t ) );
+#ifdef FLOAT64
void gen_a_i64_z_f64( float64_t ( int64_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_i64_z_extF80( void ( int64_t, extFloat80_t * ) );
#endif
@@ -135,7 +146,9 @@ void gen_a_f16_z_ui64_x( uint_fast64_t ( float16_t, bool ), bool );
void gen_a_f16_z_i32_x( int_fast32_t ( float16_t, bool ), bool );
void gen_a_f16_z_i64_x( int_fast64_t ( float16_t, bool ), bool );
void gen_a_f16_z_f32( float32_t ( float16_t ) );
+#ifdef FLOAT64
void gen_a_f16_z_f64( float64_t ( float16_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_f16_z_extF80( void ( float16_t, extFloat80_t * ) );
#endif
@@ -170,7 +183,9 @@ void gen_a_f32_z_i64_x( int_fast64_t ( float32_t, bool ), bool );
#ifdef FLOAT16
void gen_a_f32_z_f16( float16_t ( float32_t ) );
#endif
+#ifdef FLOAT64
void gen_a_f32_z_f64( float64_t ( float32_t ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_f32_z_extF80( void ( float32_t, extFloat80_t * ) );
#endif
@@ -185,6 +200,7 @@ void gen_abz_f32( float32_t ( float32_t, float32_t ) );
void gen_abcz_f32( float32_t ( float32_t, float32_t, float32_t ) );
void gen_ab_f32_z_bool( bool ( float32_t, float32_t ) );
+#ifdef FLOAT64
void
gen_a_f64_z_ui32_rx(
uint_fast32_t ( float64_t, uint_fast8_t, bool ), uint_fast8_t, bool );
@@ -218,6 +234,7 @@ void
void gen_abz_f64( float64_t ( float64_t, float64_t ) );
void gen_abcz_f64( float64_t ( float64_t, float64_t, float64_t ) );
void gen_ab_f64_z_bool( bool ( float64_t, float64_t ) );
+#endif
#ifdef EXTFLOAT80
void
@@ -254,7 +271,9 @@ void gen_a_extF80_z_i64_x( int_fast64_t ( const extFloat80_t *, bool ), bool );
void gen_a_extF80_z_f16( float16_t ( const extFloat80_t * ) );
#endif
void gen_a_extF80_z_f32( float32_t ( const extFloat80_t * ) );
+#ifdef FLOAT64
void gen_a_extF80_z_f64( float64_t ( const extFloat80_t * ) );
+#endif
#ifdef FLOAT128
void gen_a_extF80_z_f128( void ( const extFloat80_t *, float128_t * ) );
#endif
@@ -269,16 +288,6 @@ void
gen_abz_extF80(
void ( const extFloat80_t *, const extFloat80_t *, extFloat80_t * ) );
void
- gen_abcz_extF80(
- void
- (
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- extFloat80_t *
- )
- );
-void
gen_ab_extF80_z_bool( bool ( const extFloat80_t *, const extFloat80_t * ) );
#endif
@@ -315,7 +324,9 @@ void gen_a_f128_z_i64_x( int_fast64_t ( const float128_t *, bool ), bool );
void gen_a_f128_z_f16( float16_t ( const float128_t * ) );
#endif
void gen_a_f128_z_f32( float32_t ( const float128_t * ) );
+#ifdef FLOAT64
void gen_a_f128_z_f64( float64_t ( const float128_t * ) );
+#endif
#ifdef EXTFLOAT80
void gen_a_f128_z_extF80( void ( const float128_t *, extFloat80_t * ) );
#endif
diff --git a/source/random.c b/source/random.c
index 9e81ae7..9905041 100644
--- a/source/random.c
+++ b/source/random.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/random.h b/source/random.h
index 4dfa33f..4323212 100644
--- a/source/random.h
+++ b/source/random.h
@@ -1,7 +1,7 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/readHex.c b/source/readHex.c
index 0acb363..c999726 100644
--- a/source/readHex.c
+++ b/source/readHex.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/readHex.h b/source/readHex.h
index 4632d14..880c4e2 100644
--- a/source/readHex.h
+++ b/source/readHex.h
@@ -1,7 +1,7 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/slowfloat.c b/source/slowfloat.c
index 8ecf41f..5af10aa 100644
--- a/source/slowfloat.c
+++ b/source/slowfloat.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -53,7 +53,9 @@ uint_fast8_t slow_extF80_roundingPrecision;
union ui16_f16 { uint16_t ui; float16_t f; };
#endif
union ui32_f32 { uint32_t ui; float32_t f; };
+#ifdef FLOAT64
union ui64_f64 { uint64_t ui; float64_t f; };
+#endif
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
@@ -108,6 +110,11 @@ void
case softfloat_round_near_maxMag:
if ( roundBits < UINT64_C( 0x100000000000 ) ) goto noIncrement;
break;
+#ifdef FLOAT_ROUND_ODD
+ case softfloat_round_odd:
+ sigX64 |= UINT64_C( 0x200000000000 );
+ goto noIncrement;
+#endif
}
sigX64 += UINT64_C( 0x200000000000 );
if ( sigX64 == UINT64_C( 0x0100000000000000 ) ) {
@@ -156,6 +163,11 @@ void
case softfloat_round_near_maxMag:
if ( roundBits < 0x80000000 ) goto noIncrement;
break;
+#ifdef FLOAT_ROUND_ODD
+ case softfloat_round_odd:
+ sigX64 |= UINT64_C( 0x100000000 );
+ goto noIncrement;
+#endif
}
sigX64 += UINT64_C( 0x100000000 );
if ( sigX64 == UINT64_C( 0x0100000000000000 ) ) {
@@ -199,6 +211,11 @@ void
case softfloat_round_near_maxMag:
if ( roundBits < 4 ) goto noIncrement;
break;
+#ifdef FLOAT_ROUND_ODD
+ case softfloat_round_odd:
+ sigX64 |= 8;
+ goto noIncrement;
+#endif
}
sigX64 += 8;
if ( sigX64 == UINT64_C( 0x0100000000000000 ) ) {
@@ -246,8 +263,13 @@ void
case softfloat_round_near_maxMag:
if ( roundBits < UINT64_C( 0x0080000000000000 ) ) goto noIncrement;
break;
+#ifdef FLOAT_ROUND_ODD
+ case softfloat_round_odd:
+ sigX0 |= UINT64_C( 0x100000000000000 );
+ goto noIncrement;
+#endif
}
- sigX0 += UINT64_C( 0x0100000000000000 );
+ sigX0 += UINT64_C( 0x100000000000000 );
sigX64 = xPtr->sig.v64 + ! sigX0;
if ( sigX64 == UINT64_C( 0x0100000000000000 ) ) {
++xPtr->exp;
@@ -291,6 +313,11 @@ void
case softfloat_round_near_maxMag:
if ( roundBits < 0x40 ) goto noIncrement;
break;
+#ifdef FLOAT_ROUND_ODD
+ case softfloat_round_odd:
+ sigX0 |= 0x80;
+ goto noIncrement;
+#endif
}
sigX0 += 0x80;
sigX64 = xPtr->sig.v64 + ! sigX0;
@@ -346,6 +373,9 @@ uint_fast32_t
return (xPtr->isInf && xPtr->sign) ? 0 : 0xFFFFFFFF;
}
if ( xPtr->isZero ) return 0;
+ if ( roundingMode == softfloat_round_odd ) {
+ roundingMode = softfloat_round_minMag;
+ }
savedExceptionFlags = slowfloat_exceptionFlags;
x = *xPtr;
shiftDist = 52 - x.exp;
@@ -412,6 +442,9 @@ uint_fast64_t
(xPtr->isInf && xPtr->sign) ? 0 : UINT64_C( 0xFFFFFFFFFFFFFFFF );
}
if ( xPtr->isZero ) return 0;
+ if ( roundingMode == softfloat_round_odd ) {
+ roundingMode = softfloat_round_minMag;
+ }
savedExceptionFlags = slowfloat_exceptionFlags;
x = *xPtr;
shiftDist = 112 - x.exp;
@@ -479,6 +512,9 @@ int_fast32_t
return (xPtr->isInf && xPtr->sign) ? -0x7FFFFFFF - 1 : 0x7FFFFFFF;
}
if ( xPtr->isZero ) return 0;
+ if ( roundingMode == softfloat_round_odd ) {
+ roundingMode = softfloat_round_minMag;
+ }
savedExceptionFlags = slowfloat_exceptionFlags;
x = *xPtr;
shiftDist = 52 - x.exp;
@@ -552,6 +588,9 @@ int_fast64_t
: INT64_C( 0x7FFFFFFFFFFFFFFF );
}
if ( xPtr->isZero ) return 0;
+ if ( roundingMode == softfloat_round_odd ) {
+ roundingMode = softfloat_round_minMag;
+ }
savedExceptionFlags = slowfloat_exceptionFlags;
x = *xPtr;
shiftDist = 112 - x.exp;
@@ -672,6 +711,7 @@ static float16_t floatXToF16( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_max:
+ case softfloat_round_odd:
uiZ = 0xFBFF;
break;
}
@@ -684,6 +724,7 @@ static float16_t floatXToF16( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_min:
+ case softfloat_round_odd:
uiZ = 0x7BFF;
break;
}
@@ -806,6 +847,7 @@ static float32_t floatXToF32( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_max:
+ case softfloat_round_odd:
uiZ = 0xFF7FFFFF;
break;
}
@@ -818,6 +860,7 @@ static float32_t floatXToF32( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_min:
+ case softfloat_round_odd:
uiZ = 0x7F7FFFFF;
break;
}
@@ -849,6 +892,8 @@ static float32_t floatXToF32( const struct floatX *xPtr )
}
+#ifdef FLOAT64
+
static void f64ToFloatX( float64_t a, struct floatX *xPtr )
{
union ui64_f64 uA;
@@ -939,6 +984,7 @@ static float64_t floatXToF64( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_max:
+ case softfloat_round_odd:
uiZ = UINT64_C( 0xFFEFFFFFFFFFFFFF );
break;
}
@@ -951,6 +997,7 @@ static float64_t floatXToF64( const struct floatX *xPtr )
break;
case softfloat_round_minMag:
case softfloat_round_min:
+ case softfloat_round_odd:
uiZ = UINT64_C( 0x7FEFFFFFFFFFFFFF );
break;
}
@@ -982,6 +1029,8 @@ static float64_t floatXToF64( const struct floatX *xPtr )
}
+#endif
+
#ifdef EXTFLOAT80
static void extF80MToFloatX( const extFloat80_t *aPtr, struct floatX *xPtr )
@@ -1088,6 +1137,7 @@ static void floatXToExtF80M( const struct floatX *xPtr, extFloat80_t *zPtr )
break;
case softfloat_round_minMag:
case softfloat_round_max:
+ case softfloat_round_odd:
switch ( slow_extF80_roundingPrecision ) {
case 32:
uiZ0 = UINT64_C( 0xFFFFFF0000000000 );
@@ -1113,6 +1163,7 @@ static void floatXToExtF80M( const struct floatX *xPtr, extFloat80_t *zPtr )
break;
case softfloat_round_minMag:
case softfloat_round_min:
+ case softfloat_round_odd:
switch ( slow_extF80_roundingPrecision ) {
case 32:
uiZ0 = UINT64_C( 0xFFFFFF0000000000 );
@@ -1262,6 +1313,7 @@ static void floatXToF128M( const struct floatX *xPtr, float128_t *zPtr )
break;
case softfloat_round_minMag:
case softfloat_round_max:
+ case softfloat_round_odd:
uiZPtr->v64 = UINT64_C( 0xFFFEFFFFFFFFFFFF );
uiZPtr->v0 = UINT64_C( 0xFFFFFFFFFFFFFFFF );
break;
@@ -1276,6 +1328,7 @@ static void floatXToF128M( const struct floatX *xPtr, float128_t *zPtr )
break;
case softfloat_round_minMag:
case softfloat_round_min:
+ case softfloat_round_odd:
uiZPtr->v64 = UINT64_C( 0x7FFEFFFFFFFFFFFF );
uiZPtr->v0 = UINT64_C( 0xFFFFFFFFFFFFFFFF );
break;
@@ -1302,7 +1355,7 @@ static void floatXToF128M( const struct floatX *xPtr, float128_t *zPtr )
uiZ64 = (uint_fast64_t) exp<<48;
if ( x.sign ) uiZ64 |= UINT64_C( 0x8000000000000000 );
x.sig = shortShiftRightJam128( x.sig, 7 );
- uiZPtr->v64 = uiZ64 | x.sig.v64 & UINT64_C( 0x0000FFFFFFFFFFFF );
+ uiZPtr->v64 = uiZ64 | (x.sig.v64 & UINT64_C( 0x0000FFFFFFFFFFFF ));
uiZPtr->v0 = x.sig.v0;
}
@@ -1325,6 +1378,9 @@ void
struct uint128 sig;
if ( xPtr->isNaN || xPtr->isInf ) return;
+ if ( roundingMode == softfloat_round_odd ) {
+ roundingMode = softfloat_round_minMag;
+ }
exp = xPtr->exp;
shiftDist = 112 - exp;
if ( shiftDist <= 0 ) return;
@@ -2010,6 +2066,8 @@ float32_t slow_ui32_to_f32( uint32_t a )
}
+#ifdef FLOAT64
+
float64_t slow_ui32_to_f64( uint32_t a )
{
struct floatX x;
@@ -2019,6 +2077,8 @@ float64_t slow_ui32_to_f64( uint32_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_ui32_to_extF80M( uint32_t a, extFloat80_t *zPtr )
@@ -2067,6 +2127,8 @@ float32_t slow_ui64_to_f32( uint64_t a )
}
+#ifdef FLOAT64
+
float64_t slow_ui64_to_f64( uint64_t a )
{
struct floatX x;
@@ -2076,6 +2138,8 @@ float64_t slow_ui64_to_f64( uint64_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_ui64_to_extF80M( uint64_t a, extFloat80_t *zPtr )
@@ -2124,6 +2188,8 @@ float32_t slow_i32_to_f32( int32_t a )
}
+#ifdef FLOAT64
+
float64_t slow_i32_to_f64( int32_t a )
{
struct floatX x;
@@ -2133,6 +2199,8 @@ float64_t slow_i32_to_f64( int32_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_i32_to_extF80M( int32_t a, extFloat80_t *zPtr )
@@ -2181,6 +2249,8 @@ float32_t slow_i64_to_f32( int64_t a )
}
+#ifdef FLOAT64
+
float64_t slow_i64_to_f64( int64_t a )
{
struct floatX x;
@@ -2190,6 +2260,8 @@ float64_t slow_i64_to_f64( int64_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_i64_to_extF80M( int64_t a, extFloat80_t *zPtr )
@@ -2303,6 +2375,8 @@ float32_t slow_f16_to_f32( float16_t a )
}
+#ifdef FLOAT64
+
float64_t slow_f16_to_f64( float16_t a )
{
struct floatX x;
@@ -2312,6 +2386,8 @@ float64_t slow_f16_to_f64( float16_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_f16_to_extF80M( float16_t a, extFloat80_t *zPtr )
@@ -2589,6 +2665,8 @@ float16_t slow_f32_to_f16( float32_t a )
#endif
+#ifdef FLOAT64
+
float64_t slow_f32_to_f64( float32_t a )
{
struct floatX x;
@@ -2598,6 +2676,8 @@ float64_t slow_f32_to_f64( float32_t a )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_f32_to_extF80M( float32_t a, extFloat80_t *zPtr )
@@ -2784,6 +2864,8 @@ bool slow_f32_lt_quiet( float32_t a, float32_t b )
}
+#ifdef FLOAT64
+
uint_fast32_t
slow_f64_to_ui32( float64_t a, uint_fast8_t roundingMode, bool exact )
{
@@ -3067,6 +3149,8 @@ bool slow_f64_lt_quiet( float64_t a, float64_t b )
}
+#endif
+
#ifdef EXTFLOAT80
uint_fast32_t
@@ -3175,6 +3259,8 @@ float32_t slow_extF80M_to_f32( const extFloat80_t *aPtr )
}
+#ifdef FLOAT64
+
float64_t slow_extF80M_to_f64( const extFloat80_t *aPtr )
{
struct floatX x;
@@ -3184,6 +3270,8 @@ float64_t slow_extF80M_to_f64( const extFloat80_t *aPtr )
}
+#endif
+
#ifdef FLOAT128
void slow_extF80M_to_f128M( const extFloat80_t *aPtr, float128_t *zPtr )
@@ -3466,6 +3554,8 @@ float32_t slow_f128M_to_f32( const float128_t *aPtr )
}
+#ifdef FLOAT64
+
float64_t slow_f128M_to_f64( const float128_t *aPtr )
{
struct floatX x;
@@ -3475,6 +3565,8 @@ float64_t slow_f128M_to_f64( const float128_t *aPtr )
}
+#endif
+
#ifdef EXTFLOAT80
void slow_f128M_to_extF80M( const float128_t *aPtr, extFloat80_t *zPtr )
diff --git a/source/slowfloat.h b/source/slowfloat.h
index 7e9d5f5..9ba5580 100644
--- a/source/slowfloat.h
+++ b/source/slowfloat.h
@@ -1,11 +1,11 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -50,7 +50,9 @@ extern uint_fast8_t slow_extF80_roundingPrecision;
float16_t slow_ui32_to_f16( uint32_t );
#endif
float32_t slow_ui32_to_f32( uint32_t );
+#ifdef FLOAT64
float64_t slow_ui32_to_f64( uint32_t );
+#endif
#ifdef EXTFLOAT80
void slow_ui32_to_extF80M( uint32_t, extFloat80_t * );
#endif
@@ -61,7 +63,9 @@ void slow_ui32_to_f128M( uint32_t, float128_t * );
float16_t slow_ui64_to_f16( uint64_t );
#endif
float32_t slow_ui64_to_f32( uint64_t );
+#ifdef FLOAT64
float64_t slow_ui64_to_f64( uint64_t );
+#endif
#ifdef EXTFLOAT80
void slow_ui64_to_extF80M( uint64_t, extFloat80_t * );
#endif
@@ -72,7 +76,9 @@ void slow_ui64_to_f128M( uint64_t, float128_t * );
float16_t slow_i32_to_f16( int32_t );
#endif
float32_t slow_i32_to_f32( int32_t );
+#ifdef FLOAT64
float64_t slow_i32_to_f64( int32_t );
+#endif
#ifdef EXTFLOAT80
void slow_i32_to_extF80M( int32_t, extFloat80_t * );
#endif
@@ -83,7 +89,9 @@ void slow_i32_to_f128M( int32_t, float128_t * );
float16_t slow_i64_to_f16( int64_t );
#endif
float32_t slow_i64_to_f32( int64_t );
+#ifdef FLOAT64
float64_t slow_i64_to_f64( int64_t );
+#endif
#ifdef EXTFLOAT80
void slow_i64_to_extF80M( int64_t, extFloat80_t * );
#endif
@@ -101,7 +109,9 @@ uint_fast64_t slow_f16_to_ui64_r_minMag( float16_t, bool );
int_fast32_t slow_f16_to_i32_r_minMag( float16_t, bool );
int_fast64_t slow_f16_to_i64_r_minMag( float16_t, bool );
float32_t slow_f16_to_f32( float16_t );
+#ifdef FLOAT64
float64_t slow_f16_to_f64( float16_t );
+#endif
#ifdef EXTFLOAT80
void slow_f16_to_extF80M( float16_t, extFloat80_t * );
#endif
@@ -135,7 +145,9 @@ int_fast64_t slow_f32_to_i64_r_minMag( float32_t, bool );
#ifdef FLOAT16
float16_t slow_f32_to_f16( float32_t );
#endif
+#ifdef FLOAT64
float64_t slow_f32_to_f64( float32_t );
+#endif
#ifdef EXTFLOAT80
void slow_f32_to_extF80M( float32_t, extFloat80_t * );
#endif
@@ -157,6 +169,7 @@ bool slow_f32_eq_signaling( float32_t, float32_t );
bool slow_f32_le_quiet( float32_t, float32_t );
bool slow_f32_lt_quiet( float32_t, float32_t );
+#ifdef FLOAT64
uint_fast32_t slow_f64_to_ui32( float64_t, uint_fast8_t, bool );
uint_fast64_t slow_f64_to_ui64( float64_t, uint_fast8_t, bool );
int_fast32_t slow_f64_to_i32( float64_t, uint_fast8_t, bool );
@@ -189,6 +202,7 @@ bool slow_f64_lt( float64_t, float64_t );
bool slow_f64_eq_signaling( float64_t, float64_t );
bool slow_f64_le_quiet( float64_t, float64_t );
bool slow_f64_lt_quiet( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
uint_fast32_t slow_extF80M_to_ui32( const extFloat80_t *, uint_fast8_t, bool );
@@ -203,7 +217,9 @@ int_fast64_t slow_extF80M_to_i64_r_minMag( const extFloat80_t *, bool );
float16_t slow_extF80M_to_f16( const extFloat80_t * );
#endif
float32_t slow_extF80M_to_f32( const extFloat80_t * );
+#ifdef FLOAT64
float64_t slow_extF80M_to_f64( const extFloat80_t * );
+#endif
#ifdef FLOAT128
void slow_extF80M_to_f128M( const extFloat80_t *, float128_t * );
#endif
@@ -254,7 +270,9 @@ int_fast64_t slow_f128M_to_i64_r_minMag( const float128_t *, bool );
float16_t slow_f128M_to_f16( const float128_t * );
#endif
float32_t slow_f128M_to_f32( const float128_t * );
+#ifdef FLOAT64
float64_t slow_f128M_to_f64( const float128_t * );
+#endif
#ifdef EXTFLOAT80
void slow_f128M_to_extF80M( const float128_t *, extFloat80_t * );
#endif
diff --git a/source/standardFunctionInfos.c b/source/standardFunctionInfos.c
index 3432d39..4b1c653 100644
--- a/source/standardFunctionInfos.c
+++ b/source/standardFunctionInfos.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -52,7 +52,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "ui32_to_f16", UI32_TO_F16, 0, 0 },
#endif
{ "ui32_to_f32", UI32_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "ui32_to_f64", UI32_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "ui32_to_extF80", UI32_TO_EXTF80, 0, 0 },
#endif
@@ -63,7 +65,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "ui64_to_f16", UI64_TO_F16, 0, 0 },
#endif
{ "ui64_to_f32", UI64_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "ui64_to_f64", UI64_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "ui64_to_extF80", UI64_TO_EXTF80, 0, 0 },
#endif
@@ -74,7 +78,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "i32_to_f16", I32_TO_F16, 0, 0 },
#endif
{ "i32_to_f32", I32_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "i32_to_f64", I32_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "i32_to_extF80", I32_TO_EXTF80, 0, 0 },
#endif
@@ -85,7 +91,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "i64_to_f16", I64_TO_F16, 0, 0 },
#endif
{ "i64_to_f32", I64_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "i64_to_f64", I64_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "i64_to_extF80", I64_TO_EXTF80, 0, 0 },
#endif
@@ -136,7 +144,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "f16_to_i64_rx_max", F16_TO_I64, RMAX, true },
{ "f16_to_i64_rx_near_maxMag", F16_TO_I64, RNMAXM, true },
{ "f16_to_f32", F16_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "f16_to_f64", F16_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "f16_to_extF80", F16_TO_EXTF80, 0, 0 },
#endif
@@ -208,7 +218,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
#ifdef FLOAT16
{ "f32_to_f16", F32_TO_F16, 0, 0 },
#endif
+#ifdef FLOAT64
{ "f32_to_f64", F32_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "f32_to_extF80", F32_TO_EXTF80, 0, 0 },
#endif
@@ -236,6 +248,7 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "f32_lt_quiet", F32_LT_QUIET, 0, 0 },
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
+#ifdef FLOAT64
{ "f64_to_ui32_r_near_even", F64_TO_UI32, RNEVEN, false },
{ "f64_to_ui32_r_minMag", F64_TO_UI32, RMINM, false },
{ "f64_to_ui32_r_min", F64_TO_UI32, RMIN, false },
@@ -305,6 +318,7 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "f64_eq_signaling", F64_EQ_SIGNALING, 0, 0 },
{ "f64_le_quiet", F64_LE_QUIET, 0, 0 },
{ "f64_lt_quiet", F64_LT_QUIET, 0, 0 },
+#endif
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -352,7 +366,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "extF80_to_f16", EXTF80_TO_F16, 0, 0 },
#endif
{ "extF80_to_f32", EXTF80_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "extF80_to_f64", EXTF80_TO_F64, 0, 0 },
+#endif
#ifdef FLOAT128
{ "extF80_to_f128", EXTF80_TO_F128, 0, 0 },
#endif
@@ -422,7 +438,9 @@ const struct standardFunctionInfo standardFunctionInfos[] = {
{ "f128_to_f16", F128_TO_F16, 0, 0 },
#endif
{ "f128_to_f32", F128_TO_F32, 0, 0 },
+#ifdef FLOAT64
{ "f128_to_f64", F128_TO_F64, 0, 0 },
+#endif
#ifdef EXTFLOAT80
{ "f128_to_extF80", F128_TO_EXTF80, 0, 0 },
#endif
diff --git a/source/subj-C/subjfloat.c b/source/subj-C/subjfloat.c
index b42075e..f5381a4 100644
--- a/source/subj-C/subjfloat.c
+++ b/source/subj-C/subjfloat.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -95,7 +95,6 @@ uint_fast8_t subjfloat_clearExceptionFlags( void )
}
union f32_f { float32_t f32; float f; };
-union f64_d { float64_t f64; double d; };
float32_t subj_ui32_to_f32( uint32_t a )
{
@@ -106,15 +105,6 @@ float32_t subj_ui32_to_f32( uint32_t a )
}
-float64_t subj_ui32_to_f64( uint32_t a )
-{
- union f64_d uZ;
-
- uZ.d = a;
- return uZ.f64;
-
-}
-
float32_t subj_ui64_to_f32( uint64_t a )
{
union f32_f uZ;
@@ -124,15 +114,6 @@ float32_t subj_ui64_to_f32( uint64_t a )
}
-float64_t subj_ui64_to_f64( uint64_t a )
-{
- union f64_d uZ;
-
- uZ.d = a;
- return uZ.f64;
-
-}
-
float32_t subj_i32_to_f32( int32_t a )
{
union f32_f uZ;
@@ -142,15 +123,6 @@ float32_t subj_i32_to_f32( int32_t a )
}
-float64_t subj_i32_to_f64( int32_t a )
-{
- union f64_d uZ;
-
- uZ.d = a;
- return uZ.f64;
-
-}
-
float32_t subj_i64_to_f32( int64_t a )
{
union f32_f uZ;
@@ -160,15 +132,6 @@ float32_t subj_i64_to_f32( int64_t a )
}
-float64_t subj_i64_to_f64( int64_t a )
-{
- union f64_d uZ;
-
- uZ.d = a;
- return uZ.f64;
-
-}
-
uint_fast32_t subj_f32_to_ui32_rx_minMag( float32_t a )
{
union f32_f uA;
@@ -205,17 +168,6 @@ int_fast64_t subj_f32_to_i64_rx_minMag( float32_t a )
}
-float64_t subj_f32_to_f64( float32_t a )
-{
- union f32_f uA;
- union f64_d uZ;
-
- uA.f32 = a;
- uZ.d = uA.f;
- return uZ.f64;
-
-}
-
float32_t subj_f32_add( float32_t a, float32_t b )
{
union f32_f uA, uB, uZ;
@@ -290,6 +242,60 @@ bool subj_f32_lt( float32_t a, float32_t b )
}
+/*----------------------------------------------------------------------------
+*----------------------------------------------------------------------------*/
+
+#ifdef FLOAT64
+
+union f64_d { float64_t f64; double d; };
+
+float64_t subj_ui32_to_f64( uint32_t a )
+{
+ union f64_d uZ;
+
+ uZ.d = a;
+ return uZ.f64;
+
+}
+
+float64_t subj_ui64_to_f64( uint64_t a )
+{
+ union f64_d uZ;
+
+ uZ.d = a;
+ return uZ.f64;
+
+}
+
+float64_t subj_i32_to_f64( int32_t a )
+{
+ union f64_d uZ;
+
+ uZ.d = a;
+ return uZ.f64;
+
+}
+
+float64_t subj_i64_to_f64( int64_t a )
+{
+ union f64_d uZ;
+
+ uZ.d = a;
+ return uZ.f64;
+
+}
+
+float64_t subj_f32_to_f64( float32_t a )
+{
+ union f32_f uA;
+ union f64_d uZ;
+
+ uA.f32 = a;
+ uZ.d = uA.f;
+ return uZ.f64;
+
+}
+
uint_fast32_t subj_f64_to_ui32_rx_minMag( float64_t a )
{
union f64_d uA;
@@ -421,6 +427,11 @@ bool subj_f64_lt( float64_t a, float64_t b )
}
+#endif
+
+/*----------------------------------------------------------------------------
+*----------------------------------------------------------------------------*/
+
#if defined EXTFLOAT80 && defined LONG_DOUBLE_IS_EXTFLOAT80
void subj_ui32_to_extF80M( uint32_t a, extFloat80_t *zPtr )
@@ -460,6 +471,8 @@ void subj_f32_to_extF80M( float32_t a, extFloat80_t *zPtr )
}
+#ifdef FLOAT64
+
void subj_f64_to_extF80M( float64_t a, extFloat80_t *zPtr )
{
union f64_d uA;
@@ -469,6 +482,8 @@ void subj_f64_to_extF80M( float64_t a, extFloat80_t *zPtr )
}
+#endif
+
uint_fast32_t subj_extF80M_to_ui32_rx_minMag( const extFloat80_t *aPtr )
{
@@ -506,6 +521,8 @@ float32_t subj_extF80M_to_f32( const extFloat80_t *aPtr )
}
+#ifdef FLOAT64
+
float64_t subj_extF80M_to_f64( const extFloat80_t *aPtr )
{
union f64_d uZ;
@@ -515,6 +532,8 @@ float64_t subj_extF80M_to_f64( const extFloat80_t *aPtr )
}
+#endif
+
void
subj_extF80M_add(
const extFloat80_t *aPtr, const extFloat80_t *bPtr, extFloat80_t *zPtr )
@@ -578,6 +597,9 @@ bool subj_extF80M_lt( const extFloat80_t *aPtr, const extFloat80_t *bPtr )
#endif
+/*----------------------------------------------------------------------------
+*----------------------------------------------------------------------------*/
+
#if defined FLOAT128 && defined LONG_DOUBLE_IS_FLOAT128
void subj_ui32_to_f128M( uint32_t a, float128_t *zPtr )
@@ -617,6 +639,8 @@ void subj_f32_to_f128M( float32_t a, float128_t *zPtr )
}
+#ifdef FLOAT64
+
void subj_f64_to_f128M( float64_t a, float128_t *zPtr )
{
union f64_d uA;
@@ -626,6 +650,8 @@ void subj_f64_to_f128M( float64_t a, float128_t *zPtr )
}
+#endif
+
uint_fast32_t subj_f128M_to_ui32_rx_minMag( const float128_t *aPtr )
{
@@ -663,6 +689,8 @@ float32_t subj_f128M_to_f32( const float128_t *aPtr )
}
+#ifdef FLOAT64
+
float64_t subj_f128M_to_f64( const float128_t *aPtr )
{
union f64_d uZ;
@@ -672,6 +700,8 @@ float64_t subj_f128M_to_f64( const float128_t *aPtr )
}
+#endif
+
void
subj_f128M_add(
const float128_t *aPtr, const float128_t *bPtr, float128_t *zPtr )
diff --git a/source/subj-C/subjfloat_config.h b/source/subj-C/subjfloat_config.h
index 74ef090..b356382 100644
--- a/source/subj-C/subjfloat_config.h
+++ b/source/subj-C/subjfloat_config.h
@@ -5,19 +5,14 @@
*----------------------------------------------------------------------------*/
#define SUBJ_UI32_TO_F32
-#define SUBJ_UI32_TO_F64
#define SUBJ_UI64_TO_F32
-#define SUBJ_UI64_TO_F64
#define SUBJ_I32_TO_F32
-#define SUBJ_I32_TO_F64
#define SUBJ_I64_TO_F32
-#define SUBJ_I64_TO_F64
#define SUBJ_F32_TO_UI32_RX_MINMAG
#define SUBJ_F32_TO_UI64_RX_MINMAG
#define SUBJ_F32_TO_I32_RX_MINMAG
#define SUBJ_F32_TO_I64_RX_MINMAG
-#define SUBJ_F32_TO_F64
#define SUBJ_F32_ADD
#define SUBJ_F32_SUB
#define SUBJ_F32_MUL
@@ -26,6 +21,15 @@
#define SUBJ_F32_LE
#define SUBJ_F32_LT
+#ifdef FLOAT64
+
+#define SUBJ_UI32_TO_F64
+#define SUBJ_UI64_TO_F64
+#define SUBJ_I32_TO_F64
+#define SUBJ_I64_TO_F64
+
+#define SUBJ_F32_TO_F64
+
#define SUBJ_F64_TO_UI32_RX_MINMAG
#define SUBJ_F64_TO_UI64_RX_MINMAG
#define SUBJ_F64_TO_I32_RX_MINMAG
@@ -40,6 +44,8 @@
#define SUBJ_F64_LE
#define SUBJ_F64_LT
+#endif
+
#if defined EXTFLOAT80 && defined LONG_DOUBLE_IS_EXTFLOAT80
#define SUBJ_UI32_TO_EXTF80
@@ -48,14 +54,18 @@
#define SUBJ_I64_TO_EXTF80
#define SUBJ_F32_TO_EXTF80
+#ifdef FLOAT64
#define SUBJ_F64_TO_EXTF80
+#endif
#define SUBJ_EXTF80_TO_UI32_RX_MINMAG
#define SUBJ_EXTF80_TO_UI64_RX_MINMAG
#define SUBJ_EXTF80_TO_I32_RX_MINMAG
#define SUBJ_EXTF80_TO_I64_RX_MINMAG
#define SUBJ_EXTF80_TO_F32
+#ifdef FLOAT64
#define SUBJ_EXTF80_TO_F64
+#endif
#define SUBJ_EXTF80_ADD
#define SUBJ_EXTF80_SUB
#define SUBJ_EXTF80_MUL
@@ -74,14 +84,18 @@
#define SUBJ_I64_TO_F128
#define SUBJ_F32_TO_F128
+#ifdef FLOAT64
#define SUBJ_F64_TO_F128
+#endif
#define SUBJ_F128_TO_UI32_RX_MINMAG
#define SUBJ_F128_TO_UI64_RX_MINMAG
#define SUBJ_F128_TO_I32_RX_MINMAG
#define SUBJ_F128_TO_I64_RX_MINMAG
#define SUBJ_F128_TO_F32
+#ifdef FLOAT64
#define SUBJ_F128_TO_F64
+#endif
#define SUBJ_F128_ADD
#define SUBJ_F128_SUB
#define SUBJ_F128_MUL
diff --git a/source/subjfloat.h b/source/subjfloat.h
index 7f83302..cf29ee1 100644
--- a/source/subjfloat.h
+++ b/source/subjfloat.h
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -58,7 +58,9 @@ uint_fast8_t subjfloat_clearExceptionFlags( void );
float16_t subj_ui32_to_f16( uint32_t );
#endif
float32_t subj_ui32_to_f32( uint32_t );
+#ifdef FLOAT64
float64_t subj_ui32_to_f64( uint32_t );
+#endif
#ifdef EXTFLOAT80
void subj_ui32_to_extF80M( uint32_t, extFloat80_t * );
#endif
@@ -69,7 +71,9 @@ void subj_ui32_to_f128M( uint32_t, float128_t * );
float16_t subj_ui64_to_f16( uint64_t );
#endif
float32_t subj_ui64_to_f32( uint64_t );
+#ifdef FLOAT64
float64_t subj_ui64_to_f64( uint64_t );
+#endif
#ifdef EXTFLOAT80
void subj_ui64_to_extF80M( uint64_t, extFloat80_t * );
#endif
@@ -80,7 +84,9 @@ void subj_ui64_to_f128M( uint64_t, float128_t * );
float16_t subj_i32_to_f16( int32_t );
#endif
float32_t subj_i32_to_f32( int32_t );
+#ifdef FLOAT64
float64_t subj_i32_to_f64( int32_t );
+#endif
#ifdef EXTFLOAT80
void subj_i32_to_extF80M( int32_t, extFloat80_t * );
#endif
@@ -91,7 +97,9 @@ void subj_i32_to_f128M( int32_t, float128_t * );
float16_t subj_i64_to_f16( int64_t );
#endif
float32_t subj_i64_to_f32( int64_t );
+#ifdef FLOAT64
float64_t subj_i64_to_f64( int64_t );
+#endif
#ifdef EXTFLOAT80
void subj_i64_to_extF80M( int64_t, extFloat80_t * );
#endif
@@ -146,7 +154,9 @@ int_fast64_t subj_f16_to_i64_rx_max( float16_t );
int_fast64_t subj_f16_to_i64_rx_near_maxMag( float16_t );
float32_t subj_f16_to_f32( float16_t );
+#ifdef FLOAT64
float64_t subj_f16_to_f64( float16_t );
+#endif
#ifdef EXTFLOAT80
void subj_f16_to_extF80M( float16_t, extFloat80_t * );
#endif
@@ -223,7 +233,9 @@ int_fast64_t subj_f32_to_i64_rx_near_maxMag( float32_t );
#ifdef FLOAT16
float16_t subj_f32_to_f16( float32_t );
#endif
+#ifdef FLOAT64
float64_t subj_f32_to_f64( float32_t );
+#endif
#ifdef EXTFLOAT80
void subj_f32_to_extF80M( float32_t, extFloat80_t * );
#endif
@@ -253,6 +265,8 @@ bool subj_f32_lt_quiet( float32_t, float32_t );
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
+#ifdef FLOAT64
+
uint_fast32_t subj_f64_to_ui32_r_near_even( float64_t );
uint_fast32_t subj_f64_to_ui32_r_minMag( float64_t );
uint_fast32_t subj_f64_to_ui32_r_min( float64_t );
@@ -326,6 +340,8 @@ bool subj_f64_eq_signaling( float64_t, float64_t );
bool subj_f64_le_quiet( float64_t, float64_t );
bool subj_f64_lt_quiet( float64_t, float64_t );
+#endif
+
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -376,7 +392,9 @@ int_fast64_t subj_extF80M_to_i64_rx_near_maxMag( const extFloat80_t * );
float16_t subj_extF80M_to_f16( const extFloat80_t * );
#endif
float32_t subj_extF80M_to_f32( const extFloat80_t * );
+#ifdef FLOAT64
float64_t subj_extF80M_to_f64( const extFloat80_t * );
+#endif
#ifdef EXTFLOAT80
void subj_extF80M_to_f128M( const extFloat80_t *, float128_t * );
#endif
@@ -464,7 +482,9 @@ int_fast64_t subj_f128M_to_i64_rx_near_maxMag( extFloat80_t * );
float16_t subj_f128M_to_f16( const float128_t * );
#endif
float32_t subj_f128M_to_f32( const float128_t * );
+#ifdef FLOAT64
float64_t subj_f128M_to_f64( const float128_t * );
+#endif
#ifdef FLOAT128
void subj_f128M_to_extF80M( const float128_t *, extFloat80_t * );
#endif
diff --git a/source/subjfloat_functions.c b/source/subjfloat_functions.c
index ab1983e..4f3334a 100644
--- a/source/subjfloat_functions.c
+++ b/source/subjfloat_functions.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -66,11 +66,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_UI32_TO_F64
(genericFuncType *) subj_ui32_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_UI32_TO_EXTF80
(genericFuncType *) subj_ui32_to_extF80M,
@@ -97,11 +99,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_UI64_TO_F64
(genericFuncType *) subj_ui64_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_UI64_TO_EXTF80
(genericFuncType *) subj_ui64_to_extF80M,
@@ -128,11 +132,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_I32_TO_F64
(genericFuncType *) subj_i32_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_I32_TO_EXTF80
(genericFuncType *) subj_i32_to_extF80M,
@@ -159,11 +165,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_I64_TO_F64
(genericFuncType *) subj_i64_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_I64_TO_EXTF80
(genericFuncType *) subj_i64_to_extF80M,
@@ -386,11 +394,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F16_TO_F64
(genericFuncType *) subj_f16_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F16_TO_EXTF80
(genericFuncType *) subj_f16_to_extF80M,
@@ -710,11 +720,13 @@ genericFuncType *const subjfloat_functions[] = {
0,
#endif
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F32_TO_F64
(genericFuncType *) subj_f32_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F32_TO_EXTF80
(genericFuncType *) subj_f32_to_extF80M,
@@ -826,6 +838,7 @@ genericFuncType *const subjfloat_functions[] = {
#endif
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
+#ifdef FLOAT64
#ifdef SUBJ_F64_TO_UI32_R_NEAR_EVEN
(genericFuncType *) subj_f64_to_ui32_r_near_even,
#else
@@ -1147,6 +1160,7 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#endif
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -1362,11 +1376,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_EXTF80_TO_F64
(genericFuncType *) subj_extF80M_to_f64,
#else
0,
#endif
+#endif
#ifdef FLOAT128
#ifdef SUBJ_EXTF80_TO_F128
(genericFuncType *) subj_extF80M_to_f128M,
@@ -1680,11 +1696,13 @@ genericFuncType *const subjfloat_functions[] = {
#else
0,
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F128_TO_F64
(genericFuncType *) subj_f128M_to_f64,
#else
0,
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F128_TO_EXTF80
(genericFuncType *) subj_f128M_to_extF80M,
diff --git a/source/testLoops.h b/source/testLoops.h
index 77f6e61..66df969 100644
--- a/source/testLoops.h
+++ b/source/testLoops.h
@@ -1,11 +1,11 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -51,7 +51,9 @@ extern uint_fast8_t (*testLoops_subjFlagsFunction)( void );
void test_a_ui32_z_f16( float16_t ( uint32_t ), float16_t ( uint32_t ) );
#endif
void test_a_ui32_z_f32( float32_t ( uint32_t ), float32_t ( uint32_t ) );
+#ifdef FLOAT64
void test_a_ui32_z_f64( float64_t ( uint32_t ), float64_t ( uint32_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_ui32_z_extF80(
@@ -67,7 +69,9 @@ void
void test_a_ui64_z_f16( float16_t ( uint64_t ), float16_t ( uint64_t ) );
#endif
void test_a_ui64_z_f32( float32_t ( uint64_t ), float32_t ( uint64_t ) );
+#ifdef FLOAT64
void test_a_ui64_z_f64( float64_t ( uint64_t ), float64_t ( uint64_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_ui64_z_extF80(
@@ -82,7 +86,9 @@ void
void test_a_i32_z_f16( float16_t ( int32_t ), float16_t ( int32_t ) );
#endif
void test_a_i32_z_f32( float32_t ( int32_t ), float32_t ( int32_t ) );
+#ifdef FLOAT64
void test_a_i32_z_f64( float64_t ( int32_t ), float64_t ( int32_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_i32_z_extF80(
@@ -97,7 +103,9 @@ void
void test_a_i64_z_f16( float16_t ( int64_t ), float16_t ( int64_t ) );
#endif
void test_a_i64_z_f32( float32_t ( int64_t ), float32_t ( int64_t ) );
+#ifdef FLOAT64
void test_a_i64_z_f64( float64_t ( int64_t ), float64_t ( int64_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_i64_z_extF80(
@@ -157,7 +165,9 @@ void
int_fast64_t ( float16_t, bool ), int_fast64_t ( float16_t, bool ), bool
);
void test_a_f16_z_f32( float32_t ( float16_t ), float32_t ( float16_t ) );
+#ifdef FLOAT64
void test_a_f16_z_f64( float64_t ( float16_t ), float64_t ( float16_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_f16_z_extF80(
@@ -238,7 +248,9 @@ void
#ifdef FLOAT16
void test_a_f32_z_f16( float16_t ( float32_t ), float16_t ( float32_t ) );
#endif
+#ifdef FLOAT64
void test_a_f32_z_f64( float64_t ( float32_t ), float64_t ( float32_t ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_f32_z_extF80(
@@ -271,6 +283,7 @@ void
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
+#ifdef FLOAT64
void
test_a_f64_z_ui32_rx(
uint_fast32_t ( float64_t, uint_fast8_t, bool ),
@@ -348,6 +361,7 @@ void
void
test_ab_f64_z_bool(
bool ( float64_t, float64_t ), bool ( float64_t, float64_t ) );
+#endif
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
@@ -412,9 +426,11 @@ void
void
test_a_extF80_z_f32(
float32_t ( const extFloat80_t * ), float32_t ( const extFloat80_t * ) );
+#ifdef FLOAT64
void
test_a_extF80_z_f64(
float64_t ( const extFloat80_t * ), float64_t ( const extFloat80_t * ) );
+#endif
#ifdef FLOAT128
void
test_a_extF80_z_f128(
@@ -440,23 +456,6 @@ void
void ( const extFloat80_t *, const extFloat80_t *, extFloat80_t * )
);
void
- test_abcz_extF80(
- void
- (
- const extFloat80_t,
- const extFloat80_t,
- const extFloat80_t,
- extFloat80_t *
- ),
- void
- (
- const extFloat80_t,
- const extFloat80_t,
- const extFloat80_t,
- extFloat80_t *
- )
- );
-void
test_ab_extF80_z_bool(
bool ( const extFloat80_t *, const extFloat80_t * ),
bool ( const extFloat80_t *, const extFloat80_t * )
@@ -526,9 +525,11 @@ void
void
test_a_f128_z_f32(
float32_t ( const float128_t * ), float32_t ( const float128_t * ) );
+#ifdef FLOAT64
void
test_a_f128_z_f64(
float64_t ( const float128_t * ), float64_t ( const float128_t * ) );
+#endif
#ifdef EXTFLOAT80
void
test_a_f128_z_extF80(
diff --git a/source/testLoops_common.c b/source/testLoops_common.c
index 78c79b3..fc932a5 100644
--- a/source/testLoops_common.c
+++ b/source/testLoops_common.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_f128.c b/source/test_a_extF80_z_f128.c
index d1c7bd0..ea3fcef 100644
--- a/source/test_a_extF80_z_f128.c
+++ b/source/test_a_extF80_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_f16.c b/source/test_a_extF80_z_f16.c
index 19e0b83..067e884 100644
--- a/source/test_a_extF80_z_f16.c
+++ b/source/test_a_extF80_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_f32.c b/source/test_a_extF80_z_f32.c
index 5a5f885..7a4aa2c 100644
--- a/source/test_a_extF80_z_f32.c
+++ b/source/test_a_extF80_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_f64.c b/source/test_a_extF80_z_f64.c
index f6016c8..fe4da7f 100644
--- a/source/test_a_extF80_z_f64.c
+++ b/source/test_a_extF80_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef EXTFLOAT80
+#if defined FLOAT64 && defined EXTFLOAT80
#pragma STDC FENV_ACCESS ON
@@ -93,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &genCases_extF80_a, " " );
+ writeCase_a_extF80M( &genCases_extF80_a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_extF80_z_i32_rx.c b/source/test_a_extF80_z_i32_rx.c
index 9df8dc6..39e91a6 100644
--- a/source/test_a_extF80_z_i32_rx.c
+++ b/source/test_a_extF80_z_i32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_i32_x.c b/source/test_a_extF80_z_i32_x.c
index 8c70e79..e00c091 100644
--- a/source/test_a_extF80_z_i32_x.c
+++ b/source/test_a_extF80_z_i32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_i64_rx.c b/source/test_a_extF80_z_i64_rx.c
index 54d7ea6..4dff8a9 100644
--- a/source/test_a_extF80_z_i64_rx.c
+++ b/source/test_a_extF80_z_i64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_i64_x.c b/source/test_a_extF80_z_i64_x.c
index f52ae5a..db87ad0 100644
--- a/source/test_a_extF80_z_i64_x.c
+++ b/source/test_a_extF80_z_i64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_ui32_rx.c b/source/test_a_extF80_z_ui32_rx.c
index f768040..9ef255f 100644
--- a/source/test_a_extF80_z_ui32_rx.c
+++ b/source/test_a_extF80_z_ui32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_ui32_x.c b/source/test_a_extF80_z_ui32_x.c
index bbef2dd..da9503e 100644
--- a/source/test_a_extF80_z_ui32_x.c
+++ b/source/test_a_extF80_z_ui32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_ui64_rx.c b/source/test_a_extF80_z_ui64_rx.c
index 25346ba..c132e81 100644
--- a/source/test_a_extF80_z_ui64_rx.c
+++ b/source/test_a_extF80_z_ui64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_extF80_z_ui64_x.c b/source/test_a_extF80_z_ui64_x.c
index 9323f44..9fc6591 100644
--- a/source/test_a_extF80_z_ui64_x.c
+++ b/source/test_a_extF80_z_ui64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_extF80.c b/source/test_a_f128_z_extF80.c
index b65b37d..416c318 100644
--- a/source/test_a_f128_z_extF80.c
+++ b/source/test_a_f128_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -93,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f128M( &genCases_f128_a, " " );
+ writeCase_a_f128M( &genCases_f128_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f128_z_f16.c b/source/test_a_f128_z_f16.c
index f9438fb..4d2478a 100644
--- a/source/test_a_f128_z_f16.c
+++ b/source/test_a_f128_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_f32.c b/source/test_a_f128_z_f32.c
index 3064231..a15bdd9 100644
--- a/source/test_a_f128_z_f32.c
+++ b/source/test_a_f128_z_f32.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -93,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f128M( &genCases_f128_a, " " );
+ writeCase_a_f128M( &genCases_f128_a, "\n\t" );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f128_z_f64.c b/source/test_a_f128_z_f64.c
index 4f09acb..2b2d4ee 100644
--- a/source/test_a_f128_z_f64.c
+++ b/source/test_a_f128_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef FLOAT128
+#if defined FLOAT64 && defined FLOAT128
#pragma STDC FENV_ACCESS ON
diff --git a/source/test_a_f128_z_i32_rx.c b/source/test_a_f128_z_i32_rx.c
index 92ca0d4..cc8fe3f 100644
--- a/source/test_a_f128_z_i32_rx.c
+++ b/source/test_a_f128_z_i32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_i32_x.c b/source/test_a_f128_z_i32_x.c
index 06f1f69..3cf92d8 100644
--- a/source/test_a_f128_z_i32_x.c
+++ b/source/test_a_f128_z_i32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_i64_rx.c b/source/test_a_f128_z_i64_rx.c
index 71cca80..f55c865 100644
--- a/source/test_a_f128_z_i64_rx.c
+++ b/source/test_a_f128_z_i64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_i64_x.c b/source/test_a_f128_z_i64_x.c
index c219e5d..c4df486 100644
--- a/source/test_a_f128_z_i64_x.c
+++ b/source/test_a_f128_z_i64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_ui32_rx.c b/source/test_a_f128_z_ui32_rx.c
index 30e8806..63d3990 100644
--- a/source/test_a_f128_z_ui32_rx.c
+++ b/source/test_a_f128_z_ui32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_ui32_x.c b/source/test_a_f128_z_ui32_x.c
index 9bce868..327a7f9 100644
--- a/source/test_a_f128_z_ui32_x.c
+++ b/source/test_a_f128_z_ui32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_ui64_rx.c b/source/test_a_f128_z_ui64_rx.c
index 28c27a2..280d155 100644
--- a/source/test_a_f128_z_ui64_rx.c
+++ b/source/test_a_f128_z_ui64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f128_z_ui64_x.c b/source/test_a_f128_z_ui64_x.c
index 66fb1f1..34b9bc9 100644
--- a/source/test_a_f128_z_ui64_x.c
+++ b/source/test_a_f128_z_ui64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f16_z_extF80.c b/source/test_a_f16_z_extF80.c
index 150b71b..078c6a9 100644
--- a/source/test_a_f16_z_extF80.c
+++ b/source/test_a_f16_z_extF80.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -92,7 +92,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f16_z_f128.c b/source/test_a_f16_z_f128.c
index 2372955..917c12a 100644
--- a/source/test_a_f16_z_f128.c
+++ b/source/test_a_f16_z_f128.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -92,7 +92,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f16_z_f32.c b/source/test_a_f16_z_f32.c
index 7612e5d..2179307 100644
--- a/source/test_a_f16_z_f32.c
+++ b/source/test_a_f16_z_f32.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -90,7 +90,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f16_z_f64.c b/source/test_a_f16_z_f64.c
index bbc3f69..8738af8 100644
--- a/source/test_a_f16_z_f64.c
+++ b/source/test_a_f16_z_f64.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef FLOAT16
+#if defined FLOAT16 && defined FLOAT64
#pragma STDC FENV_ACCESS ON
@@ -90,7 +90,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f16_z_i32_rx.c b/source/test_a_f16_z_i32_rx.c
index 326bf3d..304453d 100644
--- a/source/test_a_f16_z_i32_rx.c
+++ b/source/test_a_f16_z_i32_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -92,7 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_i32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_i32_x.c b/source/test_a_f16_z_i32_x.c
index 217cfae..ab183c2 100644
--- a/source/test_a_f16_z_i32_x.c
+++ b/source/test_a_f16_z_i32_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -91,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_i32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_i64_rx.c b/source/test_a_f16_z_i64_rx.c
index e5b445b..2d2c06e 100644
--- a/source/test_a_f16_z_i64_rx.c
+++ b/source/test_a_f16_z_i64_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -93,7 +95,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_i64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -103,3 +105,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_i64_x.c b/source/test_a_f16_z_i64_x.c
index 392d747..6fd93cc 100644
--- a/source/test_a_f16_z_i64_x.c
+++ b/source/test_a_f16_z_i64_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -92,7 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_i64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_ui32_rx.c b/source/test_a_f16_z_ui32_rx.c
index bb0ed33..9391cea 100644
--- a/source/test_a_f16_z_ui32_rx.c
+++ b/source/test_a_f16_z_ui32_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -92,7 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_ui32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_ui32_x.c b/source/test_a_f16_z_ui32_x.c
index 42184ba..9c9b01e 100644
--- a/source/test_a_f16_z_ui32_x.c
+++ b/source/test_a_f16_z_ui32_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -91,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_ui32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_ui64_rx.c b/source/test_a_f16_z_ui64_rx.c
index 1ee7359..238b19c 100644
--- a/source/test_a_f16_z_ui64_rx.c
+++ b/source/test_a_f16_z_ui64_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -92,7 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_ui64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f16_z_ui64_x.c b/source/test_a_f16_z_ui64_x.c
index 1d9b225..a0ce754 100644
--- a/source/test_a_f16_z_ui64_x.c
+++ b/source/test_a_f16_z_ui64_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT16
+
#pragma STDC FENV_ACCESS ON
void
@@ -91,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_ui64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f32_z_extF80.c b/source/test_a_f32_z_extF80.c
index 8a4fd51..a7d45f1 100644
--- a/source/test_a_f32_z_extF80.c
+++ b/source/test_a_f32_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -92,7 +92,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f32( genCases_f32_a, " " );
+ writeCase_a_f32( genCases_f32_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f32_z_f128.c b/source/test_a_f32_z_f128.c
index 06b9d2c..340412d 100644
--- a/source/test_a_f32_z_f128.c
+++ b/source/test_a_f32_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_f16.c b/source/test_a_f32_z_f16.c
index 8aba974..50eb0b8 100644
--- a/source/test_a_f32_z_f16.c
+++ b/source/test_a_f32_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_f64.c b/source/test_a_f32_z_f64.c
index 895fcf0..24acc54 100644
--- a/source/test_a_f32_z_f64.c
+++ b/source/test_a_f32_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -98,3 +100,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f32_z_i32_rx.c b/source/test_a_f32_z_i32_rx.c
index 2d09367..3b7ec71 100644
--- a/source/test_a_f32_z_i32_rx.c
+++ b/source/test_a_f32_z_i32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_i32_x.c b/source/test_a_f32_z_i32_x.c
index 5b231cf..d45e544 100644
--- a/source/test_a_f32_z_i32_x.c
+++ b/source/test_a_f32_z_i32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_i64_rx.c b/source/test_a_f32_z_i64_rx.c
index 2a46473..42bc2c2 100644
--- a/source/test_a_f32_z_i64_rx.c
+++ b/source/test_a_f32_z_i64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_i64_x.c b/source/test_a_f32_z_i64_x.c
index a226906..a13ebcb 100644
--- a/source/test_a_f32_z_i64_x.c
+++ b/source/test_a_f32_z_i64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_ui32_rx.c b/source/test_a_f32_z_ui32_rx.c
index 1d60af7..e54f60a 100644
--- a/source/test_a_f32_z_ui32_rx.c
+++ b/source/test_a_f32_z_ui32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_ui32_x.c b/source/test_a_f32_z_ui32_x.c
index 0ef3daf..9a2bfff 100644
--- a/source/test_a_f32_z_ui32_x.c
+++ b/source/test_a_f32_z_ui32_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_ui64_rx.c b/source/test_a_f32_z_ui64_rx.c
index 8e885c4..940024f 100644
--- a/source/test_a_f32_z_ui64_rx.c
+++ b/source/test_a_f32_z_ui64_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f32_z_ui64_x.c b/source/test_a_f32_z_ui64_x.c
index 00dc606..47b896b 100644
--- a/source/test_a_f32_z_ui64_x.c
+++ b/source/test_a_f32_z_ui64_x.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_f64_z_extF80.c b/source/test_a_f64_z_extF80.c
index e844f43..08b70f3 100644
--- a/source/test_a_f64_z_extF80.c
+++ b/source/test_a_f64_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef EXTFLOAT80
+#if defined FLOAT64 && defined EXTFLOAT80
#pragma STDC FENV_ACCESS ON
@@ -92,7 +92,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( genCases_f64_a, " " );
+ writeCase_a_f64( genCases_f64_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_f64_z_f128.c b/source/test_a_f64_z_f128.c
index 5a37a5a..fcc908a 100644
--- a/source/test_a_f64_z_f128.c
+++ b/source/test_a_f64_z_f128.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef FLOAT128
+#if defined FLOAT64 && defined FLOAT128
#pragma STDC FENV_ACCESS ON
diff --git a/source/test_a_f64_z_f16.c b/source/test_a_f64_z_f16.c
index faafce6..dfec3dc 100644
--- a/source/test_a_f64_z_f16.c
+++ b/source/test_a_f64_z_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -43,7 +43,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
-#ifdef FLOAT16
+#if defined FLOAT16 && defined FLOAT64
#pragma STDC FENV_ACCESS ON
diff --git a/source/test_a_f64_z_f32.c b/source/test_a_f64_z_f32.c
index 8239f59..c76235c 100644
--- a/source/test_a_f64_z_f32.c
+++ b/source/test_a_f64_z_f32.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -98,3 +100,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_i32_rx.c b/source/test_a_f64_z_i32_rx.c
index fe692d1..d1cb8a5 100644
--- a/source/test_a_f64_z_i32_rx.c
+++ b/source/test_a_f64_z_i32_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_i32_x.c b/source/test_a_f64_z_i32_x.c
index 818dd0a..ffb4b80 100644
--- a/source/test_a_f64_z_i32_x.c
+++ b/source/test_a_f64_z_i32_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_i64_rx.c b/source/test_a_f64_z_i64_rx.c
index 99455cb..8fc6b62 100644
--- a/source/test_a_f64_z_i64_rx.c
+++ b/source/test_a_f64_z_i64_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -103,3 +105,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_i64_x.c b/source/test_a_f64_z_i64_x.c
index 42ebd62..0bbe57d 100644
--- a/source/test_a_f64_z_i64_x.c
+++ b/source/test_a_f64_z_i64_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_ui32_rx.c b/source/test_a_f64_z_ui32_rx.c
index e627b02..35eac02 100644
--- a/source/test_a_f64_z_ui32_rx.c
+++ b/source/test_a_f64_z_ui32_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_ui32_x.c b/source/test_a_f64_z_ui32_x.c
index 941ba75..3f63f8c 100644
--- a/source/test_a_f64_z_ui32_x.c
+++ b/source/test_a_f64_z_ui32_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_ui64_rx.c b/source/test_a_f64_z_ui64_rx.c
index 9520417..07e25a7 100644
--- a/source/test_a_f64_z_ui64_rx.c
+++ b/source/test_a_f64_z_ui64_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_a_f64_z_ui64_x.c b/source/test_a_f64_z_ui64_x.c
index 5af2a02..38346cc 100644
--- a/source/test_a_f64_z_ui64_x.c
+++ b/source/test_a_f64_z_ui64_x.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -101,3 +103,5 @@ void
}
+#endif
+
diff --git a/source/test_a_i32_z_extF80.c b/source/test_a_i32_z_extF80.c
index 3b2b3e2..6c0d0b7 100644
--- a/source/test_a_i32_z_extF80.c
+++ b/source/test_a_i32_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -87,7 +87,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i32( genCases_i32_a, " " );
+ writeCase_a_i32( genCases_i32_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_i32_z_f128.c b/source/test_a_i32_z_f128.c
index 0053c81..ac6419f 100644
--- a/source/test_a_i32_z_f128.c
+++ b/source/test_a_i32_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i32_z_f16.c b/source/test_a_i32_z_f16.c
index 9e3218e..3df6bc7 100644
--- a/source/test_a_i32_z_f16.c
+++ b/source/test_a_i32_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i32_z_f32.c b/source/test_a_i32_z_f32.c
index 4b9ac1e..5a507da 100644
--- a/source/test_a_i32_z_f32.c
+++ b/source/test_a_i32_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i32_z_f64.c b/source/test_a_i32_z_f64.c
index f526772..a492357 100644
--- a/source/test_a_i32_z_f64.c
+++ b/source/test_a_i32_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -93,3 +95,5 @@ void
}
+#endif
+
diff --git a/source/test_a_i64_z_extF80.c b/source/test_a_i64_z_extF80.c
index f729c29..1dbc4b4 100644
--- a/source/test_a_i64_z_extF80.c
+++ b/source/test_a_i64_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -87,7 +87,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i64( genCases_i64_a, " " );
+ writeCase_a_i64( genCases_i64_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_i64_z_f128.c b/source/test_a_i64_z_f128.c
index 6b0f57e..3a2abef 100644
--- a/source/test_a_i64_z_f128.c
+++ b/source/test_a_i64_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i64_z_f16.c b/source/test_a_i64_z_f16.c
index c775908..2fa118a 100644
--- a/source/test_a_i64_z_f16.c
+++ b/source/test_a_i64_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i64_z_f32.c b/source/test_a_i64_z_f32.c
index 794d6df..d6c6206 100644
--- a/source/test_a_i64_z_f32.c
+++ b/source/test_a_i64_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_i64_z_f64.c b/source/test_a_i64_z_f64.c
index 8788494..6e8de63 100644
--- a/source/test_a_i64_z_f64.c
+++ b/source/test_a_i64_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -83,7 +85,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i64( genCases_i64_a, " " );
+ writeCase_a_i64( genCases_i64_a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -93,3 +95,5 @@ void
}
+#endif
+
diff --git a/source/test_a_ui32_z_extF80.c b/source/test_a_ui32_z_extF80.c
index 701fd86..3bd8837 100644
--- a/source/test_a_ui32_z_extF80.c
+++ b/source/test_a_ui32_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -87,7 +87,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui32( genCases_ui32_a, " " );
+ writeCase_a_ui32( genCases_ui32_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_ui32_z_f128.c b/source/test_a_ui32_z_f128.c
index a1505d7..3e14487 100644
--- a/source/test_a_ui32_z_f128.c
+++ b/source/test_a_ui32_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui32_z_f16.c b/source/test_a_ui32_z_f16.c
index 149c1b4..b0f4e7c 100644
--- a/source/test_a_ui32_z_f16.c
+++ b/source/test_a_ui32_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui32_z_f32.c b/source/test_a_ui32_z_f32.c
index 82710a3..bc2aec0 100644
--- a/source/test_a_ui32_z_f32.c
+++ b/source/test_a_ui32_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui32_z_f64.c b/source/test_a_ui32_z_f64.c
index c47cba8..4dba9f1 100644
--- a/source/test_a_ui32_z_f64.c
+++ b/source/test_a_ui32_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -93,3 +95,5 @@ void
}
+#endif
+
diff --git a/source/test_a_ui64_z_extF80.c b/source/test_a_ui64_z_extF80.c
index 8e84802..3339c5d 100644
--- a/source/test_a_ui64_z_extF80.c
+++ b/source/test_a_ui64_z_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -87,7 +87,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui64( genCases_ui64_a, " " );
+ writeCase_a_ui64( genCases_ui64_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_a_ui64_z_f128.c b/source/test_a_ui64_z_f128.c
index 9e5c346..c4912ed 100644
--- a/source/test_a_ui64_z_f128.c
+++ b/source/test_a_ui64_z_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui64_z_f16.c b/source/test_a_ui64_z_f16.c
index 2b74134..92406c0 100644
--- a/source/test_a_ui64_z_f16.c
+++ b/source/test_a_ui64_z_f16.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui64_z_f32.c b/source/test_a_ui64_z_f32.c
index e9818d5..fb20ca5 100644
--- a/source/test_a_ui64_z_f32.c
+++ b/source/test_a_ui64_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_a_ui64_z_f64.c b/source/test_a_ui64_z_f64.c
index e194060..3758955 100644
--- a/source/test_a_ui64_z_f64.c
+++ b/source/test_a_ui64_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -83,7 +85,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui64( genCases_ui64_a, " " );
+ writeCase_a_ui64( genCases_ui64_a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -93,3 +95,5 @@ void
}
+#endif
+
diff --git a/source/test_ab_extF80_z_bool.c b/source/test_ab_extF80_z_bool.c
index 8a04c32..96b0461 100644
--- a/source/test_ab_extF80_z_bool.c
+++ b/source/test_ab_extF80_z_bool.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_ab_f128_z_bool.c b/source/test_ab_f128_z_bool.c
index 49187ef..9b2eadf 100644
--- a/source/test_ab_f128_z_bool.c
+++ b/source/test_ab_f128_z_bool.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -89,8 +89,7 @@ void
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f128M(
- &genCases_f128_a, &genCases_f128_b, "\n\t" );
+ writeCase_ab_f128M( &genCases_f128_a, &genCases_f128_b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_ab_f16_z_bool.c b/source/test_ab_f16_z_bool.c
index 2424d38..4830bc4 100644
--- a/source/test_ab_f16_z_bool.c
+++ b/source/test_ab_f16_z_bool.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -89,7 +89,7 @@ void
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f16( genCases_f16_a, genCases_f16_b, " " );
+ writeCase_ab_f16( genCases_f16_a, genCases_f16_b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_ab_f32_z_bool.c b/source/test_ab_f32_z_bool.c
index 0cf4da4..ec07400 100644
--- a/source/test_ab_f32_z_bool.c
+++ b/source/test_ab_f32_z_bool.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -87,7 +87,7 @@ void
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f32( genCases_f32_a, genCases_f32_b, " " );
+ writeCase_ab_f32( genCases_f32_a, genCases_f32_b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_ab_f64_z_bool.c b/source/test_ab_f64_z_bool.c
index d239996..63c5b51 100644
--- a/source/test_ab_f64_z_bool.c
+++ b/source/test_ab_f64_z_bool.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -97,3 +99,5 @@ void
}
+#endif
+
diff --git a/source/test_abcz_f128.c b/source/test_abcz_f128.c
index bffdec3..1d80098 100644
--- a/source/test_abcz_f128.c
+++ b/source/test_abcz_f128.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -111,11 +111,7 @@ void
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
writeCase_abc_f128M(
- &genCases_f128_a,
- &genCases_f128_b,
- &genCases_f128_c,
- "\n\t"
- );
+ &genCases_f128_a, &genCases_f128_b, &genCases_f128_c );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abcz_f16.c b/source/test_abcz_f16.c
index 87945db..aa8c4da 100644
--- a/source/test_abcz_f16.c
+++ b/source/test_abcz_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -97,7 +97,7 @@ void
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
writeCase_abc_f16(
- genCases_f16_a, genCases_f16_b, genCases_f16_c, " " );
+ genCases_f16_a, genCases_f16_b, genCases_f16_c );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abcz_f32.c b/source/test_abcz_f32.c
index 1b06deb..4f6f037 100644
--- a/source/test_abcz_f32.c
+++ b/source/test_abcz_f32.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -95,7 +95,7 @@ void
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
writeCase_abc_f32(
- genCases_f32_a, genCases_f32_b, genCases_f32_c, "\n\t" );
+ genCases_f32_a, genCases_f32_b, genCases_f32_c );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abcz_f64.c b/source/test_abcz_f64.c
index ce34e7c..fb2e3b6 100644
--- a/source/test_abcz_f64.c
+++ b/source/test_abcz_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -95,7 +97,7 @@ void
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
writeCase_abc_f64(
- genCases_f64_a, genCases_f64_b, genCases_f64_c, "\n\t" );
+ genCases_f64_a, genCases_f64_b, genCases_f64_c );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -105,3 +107,5 @@ void
}
+#endif
+
diff --git a/source/test_abz_extF80.c b/source/test_abz_extF80.c
index c697dbe..d4b07ff 100644
--- a/source/test_abz_extF80.c
+++ b/source/test_abz_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -99,7 +99,7 @@ void
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
writeCase_ab_extF80M(
- &genCases_extF80_a, &genCases_extF80_b, " " );
+ &genCases_extF80_a, &genCases_extF80_b, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abz_f128.c b/source/test_abz_f128.c
index 46b9333..f0a7c23 100644
--- a/source/test_abz_f128.c
+++ b/source/test_abz_f128.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -94,8 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f128M(
- &genCases_f128_a, &genCases_f128_b, "\n\t" );
+ writeCase_ab_f128M( &genCases_f128_a, &genCases_f128_b );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abz_f16.c b/source/test_abz_f16.c
index 5220788..6f48ccc 100644
--- a/source/test_abz_f16.c
+++ b/source/test_abz_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -94,7 +94,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f16( genCases_f16_a, genCases_f16_b, " " );
+ writeCase_ab_f16( genCases_f16_a, genCases_f16_b );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abz_f32.c b/source/test_abz_f32.c
index 1d57bb7..94cd651 100644
--- a/source/test_abz_f32.c
+++ b/source/test_abz_f32.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -92,7 +92,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f32( genCases_f32_a, genCases_f32_b, " " );
+ writeCase_ab_f32( genCases_f32_a, genCases_f32_b );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_abz_f64.c b/source/test_abz_f64.c
index 9b7c517..ddaa4c7 100644
--- a/source/test_abz_f64.c
+++ b/source/test_abz_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -102,3 +104,5 @@ void
}
+#endif
+
diff --git a/source/test_az_extF80.c b/source/test_az_extF80.c
index 4469628..54f8b79 100644
--- a/source/test_az_extF80.c
+++ b/source/test_az_extF80.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -93,7 +93,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &genCases_extF80_a, " " );
+ writeCase_a_extF80M( &genCases_extF80_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_az_extF80_rx.c b/source/test_az_extF80_rx.c
index 2f754c4..1c19794 100644
--- a/source/test_az_extF80_rx.c
+++ b/source/test_az_extF80_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -98,7 +98,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &genCases_extF80_a, " " );
+ writeCase_a_extF80M( &genCases_extF80_a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_az_f128.c b/source/test_az_f128.c
index 9ea38c3..a2495ca 100644
--- a/source/test_az_f128.c
+++ b/source/test_az_f128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_az_f128_rx.c b/source/test_az_f128_rx.c
index 5335490..827114e 100644
--- a/source/test_az_f128_rx.c
+++ b/source/test_az_f128_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_az_f16.c b/source/test_az_f16.c
index a5f34f4..ea30460 100644
--- a/source/test_az_f16.c
+++ b/source/test_az_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -90,7 +90,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_az_f16_rx.c b/source/test_az_f16_rx.c
index a919fc3..523b051 100644
--- a/source/test_az_f16_rx.c
+++ b/source/test_az_f16_rx.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -95,7 +95,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( genCases_f16_a, " " );
+ writeCase_a_f16( genCases_f16_a );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/test_az_f32.c b/source/test_az_f32.c
index a76ae05..9190ab0 100644
--- a/source/test_az_f32.c
+++ b/source/test_az_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_az_f32_rx.c b/source/test_az_f32_rx.c
index 2b2892f..e63266b 100644
--- a/source/test_az_f32_rx.c
+++ b/source/test_az_f32_rx.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/test_az_f64.c b/source/test_az_f64.c
index e6e0d63..e66eaa7 100644
--- a/source/test_az_f64.c
+++ b/source/test_az_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,6 +43,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -88,7 +90,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( genCases_f64_a, " " );
+ writeCase_a_f64( genCases_f64_a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -98,3 +100,5 @@ void
}
+#endif
+
diff --git a/source/test_az_f64_rx.c b/source/test_az_f64_rx.c
index fcab07d..cb8c9d2 100644
--- a/source/test_az_f64_rx.c
+++ b/source/test_az_f64_rx.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,6 +44,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeCase.h"
#include "testLoops.h"
+#ifdef FLOAT64
+
#pragma STDC FENV_ACCESS ON
void
@@ -93,7 +95,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( genCases_f64_a, " " );
+ writeCase_a_f64( genCases_f64_a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -103,3 +105,5 @@ void
}
+#endif
+
diff --git a/source/testfloat.c b/source/testfloat.c
index f58cf53..f72e726 100644
--- a/source/testfloat.c
+++ b/source/testfloat.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -65,7 +65,9 @@ static void (*subjFunctionPtr)();
typedef float16_t funcType_a_ui32_z_f16( uint32_t );
#endif
typedef float32_t funcType_a_ui32_z_f32( uint32_t );
+#ifdef FLOAT64
typedef float64_t funcType_a_ui32_z_f64( uint32_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_ui32_z_extF80( uint32_t, extFloat80_t * );
#endif
@@ -76,7 +78,9 @@ typedef void funcType_a_ui32_z_f128( uint32_t, float128_t * );
typedef float16_t funcType_a_ui64_z_f16( uint64_t );
#endif
typedef float32_t funcType_a_ui64_z_f32( uint64_t );
+#ifdef FLOAT64
typedef float64_t funcType_a_ui64_z_f64( uint64_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_ui64_z_extF80( uint64_t, extFloat80_t * );
#endif
@@ -87,7 +91,9 @@ typedef void funcType_a_ui64_z_f128( uint64_t, float128_t * );
typedef float16_t funcType_a_i32_z_f16( int32_t );
#endif
typedef float32_t funcType_a_i32_z_f32( int32_t );
+#ifdef FLOAT64
typedef float64_t funcType_a_i32_z_f64( int32_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_i32_z_extF80( int32_t, extFloat80_t * );
#endif
@@ -98,7 +104,9 @@ typedef void funcType_a_i32_z_f128( int32_t, float128_t * );
typedef float16_t funcType_a_i64_z_f16( int64_t );
#endif
typedef float32_t funcType_a_i64_z_f32( int64_t );
+#ifdef FLOAT64
typedef float64_t funcType_a_i64_z_f64( int64_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_i64_z_extF80( int64_t, extFloat80_t * );
#endif
@@ -112,7 +120,9 @@ typedef uint_fast64_t funcType_a_f16_z_ui64( float16_t );
typedef int_fast32_t funcType_a_f16_z_i32( float16_t );
typedef int_fast64_t funcType_a_f16_z_i64( float16_t );
typedef float32_t funcType_a_f16_z_f32( float16_t );
+#ifdef FLOAT64
typedef float64_t funcType_a_f16_z_f64( float16_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_f16_z_extF80( float16_t, extFloat80_t * );
#endif
@@ -132,7 +142,9 @@ typedef int_fast64_t funcType_a_f32_z_i64( float32_t );
#ifdef FLOAT16
typedef float16_t funcType_a_f32_z_f16( float32_t );
#endif
+#ifdef FLOAT64
typedef float64_t funcType_a_f32_z_f64( float32_t );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_f32_z_extF80( float32_t, extFloat80_t * );
#endif
@@ -144,6 +156,7 @@ typedef float32_t funcType_abz_f32( float32_t, float32_t );
typedef float32_t funcType_abcz_f32( float32_t, float32_t, float32_t );
typedef bool funcType_ab_f32_z_bool( float32_t, float32_t );
+#ifdef FLOAT64
typedef uint_fast32_t funcType_a_f64_z_ui32( float64_t );
typedef uint_fast64_t funcType_a_f64_z_ui64( float64_t );
typedef int_fast32_t funcType_a_f64_z_i32( float64_t );
@@ -162,6 +175,7 @@ typedef float64_t funcType_az_f64( float64_t );
typedef float64_t funcType_abz_f64( float64_t, float64_t );
typedef float64_t funcType_abcz_f64( float64_t, float64_t, float64_t );
typedef bool funcType_ab_f64_z_bool( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
typedef uint_fast32_t funcType_a_extF80_z_ui32( const extFloat80_t * );
@@ -172,7 +186,9 @@ typedef int_fast64_t funcType_a_extF80_z_i64( const extFloat80_t * );
typedef float16_t funcType_a_extF80_z_f16( const extFloat80_t * );
#endif
typedef float32_t funcType_a_extF80_z_f32( const extFloat80_t * );
+#ifdef FLOAT64
typedef float64_t funcType_a_extF80_z_f64( const extFloat80_t * );
+#endif
#ifdef FLOAT128
typedef void funcType_a_extF80_z_f128( const extFloat80_t *, float128_t * );
#endif
@@ -194,7 +210,9 @@ typedef int_fast64_t funcType_a_f128_z_i64( const float128_t * );
typedef float16_t funcType_a_f128_z_f16( const float128_t * );
#endif
typedef float32_t funcType_a_f128_z_f32( const float128_t * );
+#ifdef FLOAT64
typedef float64_t funcType_a_f128_z_f64( const float128_t * );
+#endif
#ifdef EXTFLOAT80
typedef void funcType_a_f128_z_extF80( const float128_t *, extFloat80_t * );
#endif
@@ -312,6 +330,8 @@ float32_t
}
+#ifdef FLOAT64
+
static
uint_fast32_t
subjFunction_a_f64_z_ui32_rx(
@@ -361,6 +381,8 @@ float64_t
}
+#endif
+
#ifdef EXTFLOAT80
static
@@ -488,8 +510,10 @@ void
#endif
funcType_abz_f32 *trueFunction_abz_f32;
funcType_ab_f32_z_bool *trueFunction_ab_f32_z_bool;
+#ifdef FLOAT64
funcType_abz_f64 *trueFunction_abz_f64;
funcType_ab_f64_z_bool *trueFunction_ab_f64_z_bool;
+#endif
#ifdef EXTFLOAT80
funcType_abz_extF80 *trueFunction_abz_extF80;
funcType_ab_extF80_z_bool *trueFunction_ab_extF80_z_bool;
@@ -519,12 +543,14 @@ void
ui32_to_f32, (funcType_a_ui32_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_UI32_TO_F64
case UI32_TO_F64:
test_a_ui32_z_f64(
ui32_to_f64, (funcType_a_ui32_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_UI32_TO_EXTF80
case UI32_TO_EXTF80:
@@ -555,12 +581,14 @@ void
ui64_to_f32, (funcType_a_ui64_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_UI64_TO_F64
case UI64_TO_F64:
test_a_ui64_z_f64(
ui64_to_f64, (funcType_a_ui64_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_UI64_TO_EXTF80
case UI64_TO_EXTF80:
@@ -591,12 +619,14 @@ void
i32_to_f32, (funcType_a_i32_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_I32_TO_F64
case I32_TO_F64:
test_a_i32_z_f64(
i32_to_f64, (funcType_a_i32_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_I32_TO_EXTF80
case I32_TO_EXTF80:
@@ -627,12 +657,14 @@ void
i64_to_f32, (funcType_a_i64_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_I64_TO_F64
case I64_TO_F64:
test_a_i64_z_f64(
i64_to_f64, (funcType_a_i64_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_I64_TO_EXTF80
case I64_TO_EXTF80:
@@ -674,12 +706,14 @@ void
f16_to_f32, (funcType_a_f16_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F16_TO_F64
case F16_TO_F64:
test_a_f16_z_f64(
f16_to_f64, (funcType_a_f16_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F16_TO_EXTF80
case F16_TO_EXTF80:
@@ -802,12 +836,14 @@ void
break;
#endif
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F32_TO_F64
case F32_TO_F64:
test_a_f32_z_f64(
f32_to_f64, (funcType_a_f32_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F32_TO_EXTF80
case F32_TO_EXTF80:
@@ -905,6 +941,7 @@ void
break;
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
+#ifdef FLOAT64
case F64_TO_UI32:
test_a_f64_z_ui32_rx(
f64_to_ui32, subjFunction_a_f64_z_ui32_rx, roundingMode, exact );
@@ -1030,6 +1067,7 @@ void
(funcType_ab_f64_z_bool *) subjFunctionPtr
);
break;
+#endif
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -1073,12 +1111,14 @@ void
extF80M_to_f32, (funcType_a_extF80_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_EXTF80_TO_F64
case EXTF80_TO_F64:
test_a_extF80_z_f64(
extF80M_to_f64, (funcType_a_extF80_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef FLOAT128
#ifdef SUBJ_EXTF80_TO_F128
case EXTF80_TO_F128:
@@ -1198,12 +1238,14 @@ void
f128M_to_f32, (funcType_a_f128_z_f32 *) subjFunctionPtr );
break;
#endif
+#ifdef FLOAT64
#ifdef SUBJ_F128_TO_F64
case F128_TO_F64:
test_a_f128_z_f64(
f128M_to_f64, (funcType_a_f128_z_f64 *) subjFunctionPtr );
break;
#endif
+#endif
#ifdef EXTFLOAT80
#ifdef SUBJ_F128_TO_EXTF80
case F128_TO_EXTF80:
@@ -1345,6 +1387,9 @@ void
#ifndef SUBJFLOAT_ROUND_NEAR_MAXMAG
if ( roundingCode != ROUND_NEAR_MAXMAG ) {
#endif
+#if defined FLOAT_ROUND_ODD && ! defined SUBJFLOAT_ROUND_NEAR_MAXMAG
+ if ( roundingCode != ROUND_ODD ) {
+#endif
if (
functionAttribs
& (FUNC_ARG_ROUNDINGMODE | FUNC_EFF_ROUNDINGMODE)
@@ -1364,6 +1409,9 @@ void
}
testFunctionInstance( functionCode, roundingMode, exact );
if ( roundingCodeIn || ! roundingCode ) break;
+#if defined FLOAT_ROUND_ODD && ! defined SUBJFLOAT_ROUND_NEAR_MAXMAG
+ }
+#endif
#ifndef SUBJFLOAT_ROUND_NEAR_MAXMAG
}
#endif
@@ -1429,7 +1477,7 @@ int main( int argc, char *argv[] )
" -errors <num> --Stop each function test after <num> errors.\n"
" * -errors 20\n"
" -errorstop --Exit after first function with any error.\n"
-" -forever --Test one function repeatedly (implies `-level 2').\n"
+" -forever --Test one function repeatedly (implies '-level 2').\n"
" -checkNaNs --Check for bitwise correctness of NaN results.\n"
#ifdef EXTFLOAT80
" -precision32 --For extF80, test only 32-bit rounding precision.\n"
@@ -1460,7 +1508,9 @@ int main( int argc, char *argv[] )
" f16 --Binary 16-bit floating-point (half-precision).\n"
#endif
" f32 --Binary 32-bit floating-point (single-precision).\n"
+#ifdef FLOAT64
" f64 --Binary 64-bit floating-point (double-precision).\n"
+#endif
#ifdef EXTFLOAT80
" extF80 --Binary 80-bit extended floating-point.\n"
#endif
@@ -1472,7 +1522,14 @@ int main( int argc, char *argv[] )
" minMag --Round to minimum magnitude (toward zero).\n"
" min --Round to minimum (down).\n"
" max --Round to maximum (up).\n"
+#ifdef SUBJFLOAT_ROUND_NEAR_MAXMAG
" near_maxMag --Round to nearest/maximum magnitude (nearest/away).\n"
+#endif
+#if defined FLOAT_ROUND_ODD && defined SUBJFLOAT_ROUND_ODD
+" odd --Round to odd (jamming). (Not allowed as an inherent\n"
+" rounding mode. For 'roundToInt_x', rounds to minimum\n"
+" magnitude instead.)\n"
+#endif
,
stdout
);
@@ -1555,9 +1612,17 @@ int main( int argc, char *argv[] )
roundingCode = ROUND_NEAR_MAXMAG;
#else
fail(
- "Rounding mode near_maxMag is not supported or cannot be tested"
+ "Rounding mode 'near_maxMag' is not supported or cannot be tested"
);
#endif
+#ifdef FLOAT_ROUND_ODD
+ } else if ( ! strcmp( argPtr, "rodd" ) ) {
+#ifdef SUBJFLOAT_ROUND_ODD
+ roundingCode = ROUND_ODD;
+#else
+ fail( "Rounding mode 'odd' is not supported or cannot be tested" );
+#endif
+#endif
} else if ( ! strcmp( argPtr, "tininessbefore" ) ) {
softfloat_detectTininess = softfloat_tininess_beforeRounding;
} else if ( ! strcmp( argPtr, "tininessafter" ) ) {
@@ -1575,7 +1640,7 @@ int main( int argc, char *argv[] )
for (;;) {
functionNamePtr = standardFunctionInfoPtr->namePtr;
if ( ! functionNamePtr ) {
- fail( "Invalid argument `%s'", *argv );
+ fail( "Invalid argument '%s'", *argv );
}
if ( ! strcmp( argPtr, functionNamePtr ) ) break;
++standardFunctionInfoPtr;
@@ -1585,7 +1650,7 @@ int main( int argc, char *argv[] )
[standardFunctionInfoPtr - standardFunctionInfos];
if ( ! subjFunctionPtr ) {
fail(
- "Function `%s' is not supported or cannot be tested",
+ "Function '%s' is not supported or cannot be tested",
argPtr
);
}
@@ -1606,7 +1671,7 @@ int main( int argc, char *argv[] )
standardFunctionInfoPtr, roundingPrecision, roundingCode );
} else {
if ( testLoops_forever ) {
- fail( "Can test only one function with `-forever' option" );
+ fail( "Can test only one function with '-forever' option" );
}
if ( numOperands == 1 ) {
standardFunctionInfoPtr = standardFunctionInfos;
@@ -1656,7 +1721,7 @@ int main( int argc, char *argv[] )
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
optionError:
- fail( "`%s' option requires numeric argument", *argv );
+ fail( "'%s' option requires numeric argument", *argv );
}
diff --git a/source/testfloat_gen.c b/source/testfloat_gen.c
index 82621bb..287904e 100644
--- a/source/testfloat_gen.c
+++ b/source/testfloat_gen.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -94,8 +94,10 @@ int main( int argc, char *argv[] )
#endif
float32_t (*trueFunction_abz_f32)( float32_t, float32_t );
bool (*trueFunction_ab_f32_z_bool)( float32_t, float32_t );
+#ifdef FLOAT64
float64_t (*trueFunction_abz_f64)( float64_t, float64_t );
bool (*trueFunction_ab_f64_z_bool)( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
void
(*trueFunction_abz_extF80)(
@@ -149,7 +151,7 @@ int main( int argc, char *argv[] )
" -level <num> --Testing level <num> (1 or 2).\n"
" * -level 1\n"
" -n <num> --Generate <num> test cases.\n"
-" -forever --Generate test cases indefinitely (implies `-level 2').\n"
+" -forever --Generate test cases indefinitely (implies '-level 2').\n"
#ifdef EXTFLOAT80
" -precision32 --For extF80, rounding precision is 32 bits.\n"
" -precision64 --For extF80, rounding precision is 64 bits.\n"
@@ -160,6 +162,10 @@ int main( int argc, char *argv[] )
" -rmin --Round to minimum (down).\n"
" -rmax --Round to maximum (up).\n"
" -rnear_maxMag --Round to nearest/maximum magnitude (nearest/away).\n"
+#ifdef FLOAT_ROUND_ODD
+" -rodd --Round to odd (jamming). (For rounding to an integer\n"
+" value, rounds to minimum magnitude instead.)\n"
+#endif
" -tininessbefore --Detect underflow tininess before rounding.\n"
" * -tininessafter --Detect underflow tininess after rounding.\n"
" * -notexact --Rounding to integer is not exact (no inexact\n"
@@ -189,7 +195,9 @@ int main( int argc, char *argv[] )
" f16 --Binary 16-bit floating-point (half-precision).\n"
#endif
" f32 --Binary 32-bit floating-point (single-precision).\n"
+#ifdef FLOAT64
" f64 --Binary 64-bit floating-point (double-precision).\n"
+#endif
#ifdef EXTFLOAT80
" extF80 --Binary 80-bit extended floating-point.\n"
#endif
@@ -266,6 +274,10 @@ int main( int argc, char *argv[] )
|| ! strcmp( argPtr, "rnearest_maxMag" )
) {
roundingMode = softfloat_round_near_maxMag;
+#ifdef FLOAT_ROUND_ODD
+ } else if ( ! strcmp( argPtr, "rodd" ) ) {
+ roundingMode = softfloat_round_odd;
+#endif
} else if ( ! strcmp( argPtr, "tininessbefore" ) ) {
softfloat_detectTininess = softfloat_tininess_beforeRounding;
} else if ( ! strcmp( argPtr, "tininessafter" ) ) {
@@ -305,11 +317,13 @@ int main( int argc, char *argv[] )
! strcmp( argPtr, "f32" ) || ! strcmp( argPtr, "float32" )
) {
functionCode = TYPE_F32;
+#ifdef FLOAT64
goto absorbArg;
} else if (
! strcmp( argPtr, "f64" ) || ! strcmp( argPtr, "float64" )
) {
functionCode = TYPE_F64;
+#endif
#ifdef EXTFLOAT80
goto absorbArg;
} else if (
@@ -402,6 +416,7 @@ int main( int argc, char *argv[] )
case TYPE_F32_3:
gen_abc_f32();
break;
+#ifdef FLOAT64
case TYPE_F64:
gen_a_f64();
break;
@@ -411,6 +426,7 @@ int main( int argc, char *argv[] )
case TYPE_F64_3:
gen_abc_f64();
break;
+#endif
#ifdef EXTFLOAT80
case TYPE_EXTF80:
gen_a_extF80();
@@ -443,9 +459,11 @@ int main( int argc, char *argv[] )
case UI32_TO_F32:
gen_a_ui32_z_f32( ui32_to_f32 );
break;
+#ifdef FLOAT64
case UI32_TO_F64:
gen_a_ui32_z_f64( ui32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI32_TO_EXTF80:
gen_a_ui32_z_extF80( ui32_to_extF80M );
@@ -464,9 +482,11 @@ int main( int argc, char *argv[] )
case UI64_TO_F32:
gen_a_ui64_z_f32( ui64_to_f32 );
break;
+#ifdef FLOAT64
case UI64_TO_F64:
gen_a_ui64_z_f64( ui64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI64_TO_EXTF80:
gen_a_ui64_z_extF80( ui64_to_extF80M );
@@ -485,9 +505,11 @@ int main( int argc, char *argv[] )
case I32_TO_F32:
gen_a_i32_z_f32( i32_to_f32 );
break;
+#ifdef FLOAT64
case I32_TO_F64:
gen_a_i32_z_f64( i32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I32_TO_EXTF80:
gen_a_i32_z_extF80( i32_to_extF80M );
@@ -506,9 +528,11 @@ int main( int argc, char *argv[] )
case I64_TO_F32:
gen_a_i64_z_f32( i64_to_f32 );
break;
+#ifdef FLOAT64
case I64_TO_F64:
gen_a_i64_z_f64( i64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I64_TO_EXTF80:
gen_a_i64_z_extF80( i64_to_extF80M );
@@ -537,9 +561,11 @@ int main( int argc, char *argv[] )
case F16_TO_F32:
gen_a_f16_z_f32( f16_to_f32 );
break;
+#ifdef FLOAT64
case F16_TO_F64:
gen_a_f16_z_f64( f16_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F16_TO_EXTF80:
gen_a_f16_z_extF80( f16_to_extF80M );
@@ -616,9 +642,11 @@ int main( int argc, char *argv[] )
gen_a_f32_z_f16( f32_to_f16 );
break;
#endif
+#ifdef FLOAT64
case F32_TO_F64:
gen_a_f32_z_f64( f32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F32_TO_EXTF80:
gen_a_f32_z_extF80( f32_to_extF80M );
@@ -677,6 +705,7 @@ int main( int argc, char *argv[] )
break;
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
+#ifdef FLOAT64
case F64_TO_UI32:
gen_a_f64_z_ui32_rx( f64_to_ui32, roundingMode, exact );
break;
@@ -753,6 +782,7 @@ int main( int argc, char *argv[] )
gen_ab_f64_z_bool:
gen_ab_f64_z_bool( trueFunction_ab_f64_z_bool );
break;
+#endif
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -776,9 +806,11 @@ int main( int argc, char *argv[] )
case EXTF80_TO_F32:
gen_a_extF80_z_f32( extF80M_to_f32 );
break;
+#ifdef FLOAT64
case EXTF80_TO_F64:
gen_a_extF80_z_f64( extF80M_to_f64 );
break;
+#endif
#ifdef FLOAT128
case EXTF80_TO_F128:
gen_a_extF80_z_f128( extF80M_to_f128M );
@@ -851,9 +883,11 @@ int main( int argc, char *argv[] )
case F128_TO_F32:
gen_a_f128_z_f32( f128M_to_f32 );
break;
+#ifdef FLOAT64
case F128_TO_F64:
gen_a_f128_z_f64( f128M_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F128_TO_EXTF80:
gen_a_f128_z_extF80( f128M_to_extF80M );
@@ -911,9 +945,9 @@ int main( int argc, char *argv[] )
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
optionError:
- fail( "`%s' option requires numeric argument", *argv );
+ fail( "'%s' option requires numeric argument", *argv );
invalidArg:
- fail( "Invalid argument `%s'", *argv );
+ fail( "Invalid argument '%s'", *argv );
}
diff --git a/source/testfloat_ver.c b/source/testfloat_ver.c
index e5a74fd..39a4688 100644
--- a/source/testfloat_ver.c
+++ b/source/testfloat_ver.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -71,8 +71,10 @@ int main( int argc, char *argv[] )
#endif
float32_t (*trueFunction_abz_f32)( float32_t, float32_t );
bool (*trueFunction_ab_f32_z_bool)( float32_t, float32_t );
+#ifdef FLOAT64
float64_t (*trueFunction_abz_f64)( float64_t, float64_t );
bool (*trueFunction_ab_f64_z_bool)( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
void
(*trueFunction_abz_extF80)(
@@ -132,6 +134,10 @@ int main( int argc, char *argv[] )
" -rmin --Round to minimum (down).\n"
" -rmax --Round to maximum (up).\n"
" -rnear_maxMag --Round to nearest/maximum magnitude (nearest/away).\n"
+#ifdef FLOAT_ROUND_ODD
+" -rodd --Round to odd (jamming). (For rounding to an integer\n"
+" value, rounds to minimum magnitude instead.)\n"
+#endif
" -tininessbefore --Detect underflow tininess before rounding.\n"
" * -tininessafter --Detect underflow tininess after rounding.\n"
" * -notexact --Rounding to integer is not exact (no inexact\n"
@@ -156,7 +162,9 @@ int main( int argc, char *argv[] )
" f16 --Binary 16-bit floating-point (half-precision).\n"
#endif
" f32 --Binary 32-bit floating-point (single-precision).\n"
+#ifdef FLOAT64
" f64 --Binary 64-bit floating-point (double-precision).\n"
+#endif
#ifdef EXTFLOAT80
" extF80 --Binary 80-bit extended floating-point.\n"
#endif
@@ -208,6 +216,10 @@ int main( int argc, char *argv[] )
|| ! strcmp( argPtr, "rnearest_maxMag" )
) {
roundingCode = ROUND_NEAR_MAXMAG;
+#ifdef FLOAT_ROUND_ODD
+ } else if ( ! strcmp( argPtr, "rodd" ) ) {
+ roundingCode = ROUND_ODD;
+#endif
} else if ( ! strcmp( argPtr, "tininessbefore" ) ) {
tininessCode = TININESS_BEFORE_ROUNDING;
} else if ( ! strcmp( argPtr, "tininessafter" ) ) {
@@ -277,9 +289,11 @@ int main( int argc, char *argv[] )
case UI32_TO_F32:
ver_a_ui32_z_f32( ui32_to_f32 );
break;
+#ifdef FLOAT64
case UI32_TO_F64:
ver_a_ui32_z_f64( ui32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI32_TO_EXTF80:
ver_a_ui32_z_extF80( ui32_to_extF80M );
@@ -298,9 +312,11 @@ int main( int argc, char *argv[] )
case UI64_TO_F32:
ver_a_ui64_z_f32( ui64_to_f32 );
break;
+#ifdef FLOAT64
case UI64_TO_F64:
ver_a_ui64_z_f64( ui64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI64_TO_EXTF80:
ver_a_ui64_z_extF80( ui64_to_extF80M );
@@ -319,9 +335,11 @@ int main( int argc, char *argv[] )
case I32_TO_F32:
ver_a_i32_z_f32( i32_to_f32 );
break;
+#ifdef FLOAT64
case I32_TO_F64:
ver_a_i32_z_f64( i32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I32_TO_EXTF80:
ver_a_i32_z_extF80( i32_to_extF80M );
@@ -340,9 +358,11 @@ int main( int argc, char *argv[] )
case I64_TO_F32:
ver_a_i64_z_f32( i64_to_f32 );
break;
+#ifdef FLOAT64
case I64_TO_F64:
ver_a_i64_z_f64( i64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I64_TO_EXTF80:
ver_a_i64_z_extF80( i64_to_extF80M );
@@ -371,9 +391,11 @@ int main( int argc, char *argv[] )
case F16_TO_F32:
ver_a_f16_z_f32( f16_to_f32 );
break;
+#ifdef FLOAT64
case F16_TO_F64:
ver_a_f16_z_f64( f16_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F16_TO_EXTF80:
ver_a_f16_z_extF80( f16_to_extF80M );
@@ -450,9 +472,11 @@ int main( int argc, char *argv[] )
ver_a_f32_z_f16( f32_to_f16 );
break;
#endif
+#ifdef FLOAT64
case F32_TO_F64:
ver_a_f32_z_f64( f32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F32_TO_EXTF80:
ver_a_f32_z_extF80( f32_to_extF80M );
@@ -511,6 +535,7 @@ int main( int argc, char *argv[] )
break;
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
+#ifdef FLOAT64
case F64_TO_UI32:
ver_a_f64_z_ui32_rx( f64_to_ui32, roundingMode, exact );
break;
@@ -587,6 +612,7 @@ int main( int argc, char *argv[] )
ver_ab_f64_z_bool:
ver_ab_f64_z_bool( trueFunction_ab_f64_z_bool );
break;
+#endif
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -610,9 +636,11 @@ int main( int argc, char *argv[] )
case EXTF80_TO_F32:
ver_a_extF80_z_f32( extF80M_to_f32 );
break;
+#ifdef FLOAT64
case EXTF80_TO_F64:
ver_a_extF80_z_f64( extF80M_to_f64 );
break;
+#endif
#ifdef FLOAT128
case EXTF80_TO_F128:
ver_a_extF80_z_f128( extF80M_to_f128M );
@@ -685,9 +713,11 @@ int main( int argc, char *argv[] )
case F128_TO_F32:
ver_a_f128_z_f32( f128M_to_f32 );
break;
+#ifdef FLOAT64
case F128_TO_F64:
ver_a_f128_z_f64( f128M_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F128_TO_EXTF80:
ver_a_f128_z_extF80( f128M_to_extF80M );
@@ -745,9 +775,9 @@ int main( int argc, char *argv[] )
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
optionError:
- fail( "`%s' option requires numeric argument", *argv );
+ fail( "'%s' option requires numeric argument", *argv );
invalidArg:
- fail( "Invalid argument `%s'", *argv );
+ fail( "Invalid argument '%s'", *argv );
}
diff --git a/source/testsoftfloat.c b/source/testsoftfloat.c
index 85585c1..b5aeb09 100644
--- a/source/testsoftfloat.c
+++ b/source/testsoftfloat.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -84,10 +84,12 @@ void
float32_t (*subjFunction_abz_f32)( float32_t, float32_t );
bool (*trueFunction_ab_f32_z_bool)( float32_t, float32_t );
bool (*subjFunction_ab_f32_z_bool)( float32_t, float32_t );
+#ifdef FLOAT64
float64_t (*trueFunction_abz_f64)( float64_t, float64_t );
float64_t (*subjFunction_abz_f64)( float64_t, float64_t );
bool (*trueFunction_ab_f64_z_bool)( float64_t, float64_t );
bool (*subjFunction_ab_f64_z_bool)( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
void (*trueFunction_abz_extF80M)(
const extFloat80_t *, const extFloat80_t *, extFloat80_t * );
@@ -123,9 +125,11 @@ void
case UI32_TO_F32:
test_a_ui32_z_f32( slow_ui32_to_f32, ui32_to_f32 );
break;
+#ifdef FLOAT64
case UI32_TO_F64:
test_a_ui32_z_f64( slow_ui32_to_f64, ui32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI32_TO_EXTF80:
test_a_ui32_z_extF80( slow_ui32_to_extF80M, ui32_to_extF80M );
@@ -144,9 +148,11 @@ void
case UI64_TO_F32:
test_a_ui64_z_f32( slow_ui64_to_f32, ui64_to_f32 );
break;
+#ifdef FLOAT64
case UI64_TO_F64:
test_a_ui64_z_f64( slow_ui64_to_f64, ui64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI64_TO_EXTF80:
test_a_ui64_z_extF80( slow_ui64_to_extF80M, ui64_to_extF80M );
@@ -165,9 +171,11 @@ void
case I32_TO_F32:
test_a_i32_z_f32( slow_i32_to_f32, i32_to_f32 );
break;
+#ifdef FLOAT64
case I32_TO_F64:
test_a_i32_z_f64( slow_i32_to_f64, i32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I32_TO_EXTF80:
test_a_i32_z_extF80( slow_i32_to_extF80M, i32_to_extF80M );
@@ -186,9 +194,11 @@ void
case I64_TO_F32:
test_a_i64_z_f32( slow_i64_to_f32, i64_to_f32 );
break;
+#ifdef FLOAT64
case I64_TO_F64:
test_a_i64_z_f64( slow_i64_to_f64, i64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I64_TO_EXTF80:
test_a_i64_z_extF80( slow_i64_to_extF80M, i64_to_extF80M );
@@ -237,9 +247,11 @@ void
case F16_TO_F32:
test_a_f16_z_f32( slow_f16_to_f32, f16_to_f32 );
break;
+#ifdef FLOAT64
case F16_TO_F64:
test_a_f16_z_f64( slow_f16_to_f64, f16_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F16_TO_EXTF80:
test_a_f16_z_extF80( slow_f16_to_extF80M, f16_to_extF80M );
@@ -349,9 +361,11 @@ void
test_a_f32_z_f16( slow_f32_to_f16, f32_to_f16 );
break;
#endif
+#ifdef FLOAT64
case F32_TO_F64:
test_a_f32_z_f64( slow_f32_to_f64, f32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F32_TO_EXTF80:
test_a_f32_z_extF80( slow_f32_to_extF80M, f32_to_extF80M );
@@ -423,6 +437,7 @@ void
break;
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
+#ifdef FLOAT64
case F64_TO_UI32:
test_a_f64_z_ui32_rx(
slow_f64_to_ui32, f64_to_ui32, roundingMode, exact );
@@ -532,6 +547,7 @@ void
test_ab_f64_z_bool(
trueFunction_ab_f64_z_bool, subjFunction_ab_f64_z_bool );
break;
+#endif
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -575,9 +591,11 @@ void
case EXTF80_TO_F32:
test_a_extF80_z_f32( slow_extF80M_to_f32, extF80M_to_f32 );
break;
+#ifdef FLOAT64
case EXTF80_TO_F64:
test_a_extF80_z_f64( slow_extF80M_to_f64, extF80M_to_f64 );
break;
+#endif
#ifdef FLOAT128
case EXTF80_TO_F128:
test_a_extF80_z_f128( slow_extF80M_to_f128M, extF80M_to_f128M );
@@ -683,9 +701,11 @@ void
case F128_TO_F32:
test_a_f128_z_f32( slow_f128M_to_f32, f128M_to_f32 );
break;
+#ifdef FLOAT64
case F128_TO_F64:
test_a_f128_z_f64( slow_f128M_to_f64, f128M_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F128_TO_EXTF80:
test_a_f128_z_extF80( slow_f128M_to_extF80M, f128M_to_extF80M );
@@ -913,7 +933,7 @@ int main( int argc, char *argv[] )
" -errors <num> --Stop each function test after <num> errors.\n"
" * -errors 20\n"
" -errorstop --Exit after first function with any error.\n"
-" -forever --Test one function repeatedly (implies `-level 2').\n"
+" -forever --Test one function repeatedly (implies '-level 2').\n"
#ifdef EXTFLOAT80
" -precision32 --For extF80, test only 32-bit rounding precision.\n"
" -precision64 --For extF80, test only 64-bit rounding precision.\n"
@@ -925,6 +945,10 @@ int main( int argc, char *argv[] )
" -rmax --Test only rounding to maximum (up).\n"
" -rnear_maxMag --Test only rounding to nearest/maximum magnitude\n"
" (nearest/away).\n"
+#ifdef FLOAT_ROUND_ODD
+" -rodd --Test only rounding to odd (jamming). (For rounding to\n"
+" an integer value, 'minMag' rounding is done instead.)\n"
+#endif
" -tininessbefore --Test only underflow tininess detected before rounding.\n"
" -tininessafter --Test only underflow tininess detected after rounding.\n"
" -notexact --Test only non-exact rounding to integer (no inexact\n"
@@ -951,7 +975,9 @@ int main( int argc, char *argv[] )
" f16 --Binary 16-bit floating-point (half-precision).\n"
#endif
" f32 --Binary 32-bit floating-point (single-precision).\n"
+#ifdef FLOAT64
" f64 --Binary 64-bit floating-point (double-precision).\n"
+#endif
#ifdef EXTFLOAT80
" extF80 --Binary 80-bit extended floating-point.\n"
#endif
@@ -1022,6 +1048,10 @@ int main( int argc, char *argv[] )
|| ! strcmp( argPtr, "rnearest_maxMag" )
) {
roundingCode = ROUND_NEAR_MAXMAG;
+#ifdef FLOAT_ROUND_ODD
+ } else if ( ! strcmp( argPtr, "rodd" ) ) {
+ roundingCode = ROUND_ODD;
+#endif
} else if ( ! strcmp( argPtr, "tininessbefore" ) ) {
tininessCode = TININESS_BEFORE_ROUNDING;
} else if ( ! strcmp( argPtr, "tininessafter" ) ) {
@@ -1043,7 +1073,7 @@ int main( int argc, char *argv[] )
while ( strcmp( argPtr, functionInfos[functionCode].namePtr ) ) {
++functionCode;
if ( functionCode == NUM_FUNCTIONS ) {
- fail( "Invalid argument `%s'", *argv );
+ fail( "Invalid argument '%s'", *argv );
}
}
haveFunctionArg = true;
@@ -1068,7 +1098,7 @@ int main( int argc, char *argv[] )
);
} else {
if ( testLoops_forever ) {
- fail( "Can test only one function with `-forever' option" );
+ fail( "Can test only one function with '-forever' option" );
}
if ( numOperands == 1 ) {
for (
@@ -1106,7 +1136,7 @@ int main( int argc, char *argv[] )
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
optionError:
- fail( "`%s' option requires numeric argument", *argv );
+ fail( "'%s' option requires numeric argument", *argv );
}
diff --git a/source/timesoftfloat.c b/source/timesoftfloat.c
index b7a4d29..1ead1b1 100644
--- a/source/timesoftfloat.c
+++ b/source/timesoftfloat.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -70,7 +70,10 @@ static void reportTime( int_fast64_t count, clock_t clockTicks )
", rounding minMag",
", rounding min",
", rounding max",
- ", rounding near_maxMag"
+ ", rounding near_maxMag",
+#ifdef FLOAT_ROUND_ODD
+ ", rounding odd"
+#endif
};
printf(
@@ -107,7 +110,9 @@ static void reportTime( int_fast64_t count, clock_t clockTicks )
union ui16_f16 { uint16_t ui; float16_t f; };
#endif
union ui32_f32 { uint32_t ui; float32_t f; };
+#ifdef FLOAT64
union ui64_f64 { uint64_t ui; float64_t f; };
+#endif
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
@@ -187,6 +192,8 @@ static void time_a_ui32_z_f32( float32_t function( uint32_t ) )
}
+#ifdef FLOAT64
+
static void time_a_ui32_z_f64( float64_t function( uint32_t ) )
{
int_fast64_t count;
@@ -216,6 +223,8 @@ static void time_a_ui32_z_f64( float64_t function( uint32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_ui32_z_extF80( void function( uint32_t, extFloat80_t * ) )
@@ -370,6 +379,8 @@ static void time_a_ui64_z_f32( float32_t function( uint64_t ) )
}
+#ifdef FLOAT64
+
static void time_a_ui64_z_f64( float64_t function( uint64_t ) )
{
int_fast64_t count;
@@ -399,6 +410,8 @@ static void time_a_ui64_z_f64( float64_t function( uint64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_ui64_z_extF80( void function( uint64_t, extFloat80_t * ) )
@@ -545,6 +558,8 @@ static void time_a_i32_z_f32( float32_t function( int32_t ) )
}
+#ifdef FLOAT64
+
static void time_a_i32_z_f64( float64_t function( int32_t ) )
{
int_fast64_t count;
@@ -574,6 +589,8 @@ static void time_a_i32_z_f64( float64_t function( int32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_i32_z_extF80( void function( int32_t, extFloat80_t * ) )
@@ -728,6 +745,8 @@ static void time_a_i64_z_f32( float32_t function( int64_t ) )
}
+#ifdef FLOAT64
+
static void time_a_i64_z_f64( float64_t function( int64_t ) )
{
int_fast64_t count;
@@ -757,6 +776,8 @@ static void time_a_i64_z_f64( float64_t function( int64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_i64_z_extF80( void function( int64_t, extFloat80_t * ) )
@@ -1157,6 +1178,8 @@ static void time_a_f16_z_f32( float32_t function( float16_t ) )
}
+#ifdef FLOAT64
+
static void time_a_f16_z_f64( float64_t function( float16_t ) )
{
int_fast64_t count;
@@ -1189,6 +1212,8 @@ static void time_a_f16_z_f64( float64_t function( float16_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_f16_z_extF80( void function( float16_t, extFloat80_t * ) )
@@ -1809,6 +1834,8 @@ static void time_a_f32_z_f16( float16_t function( float32_t ) )
#endif
+#ifdef FLOAT64
+
static void time_a_f32_z_f64( float64_t function( float32_t ) )
{
int_fast64_t count;
@@ -1841,6 +1868,8 @@ static void time_a_f32_z_f64( float64_t function( float32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
static void time_a_f32_z_extF80( void function( float32_t, extFloat80_t * ) )
@@ -2128,6 +2157,8 @@ static void time_az_f32_pos( float32_t function( float32_t ) )
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
+#ifdef FLOAT64
+
enum { numInputs_f64 = 32 };
static const uint64_t inputs_F64UI[numInputs_f64] = {
@@ -2827,6 +2858,8 @@ static void time_az_f64_pos( float64_t function( float64_t ) )
}
+#endif
+
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
@@ -3207,6 +3240,8 @@ static void time_a_extF80_z_f32( float32_t function( const extFloat80_t * ) )
}
+#ifdef FLOAT64
+
static void time_a_extF80_z_f64( float64_t function( const extFloat80_t * ) )
{
int_fast64_t count;
@@ -3236,6 +3271,8 @@ static void time_a_extF80_z_f64( float64_t function( const extFloat80_t * ) )
}
+#endif
+
#ifdef FLOAT128
static
@@ -3353,68 +3390,6 @@ void
static
void
- time_abcz_extF80(
- void
- function(
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- extFloat80_t *
- )
- )
-{
- int_fast64_t count;
- int inputNumA, inputNumB, inputNumC;
- clock_t startClock;
- int_fast64_t i;
- extFloat80_t z;
- clock_t endClock;
-
- count = 0;
- inputNumA = 0;
- inputNumB = 0;
- inputNumC = 0;
- startClock = clock();
- do {
- for ( i = minIterations; i; --i ) {
- function(
- &inputs_extF80[inputNumA].f,
- &inputs_extF80[inputNumB].f,
- &inputs_extF80[inputNumC].f,
- &z
- );
- inputNumA = (inputNumA + 1) & (numInputs_extF80 - 1);
- if ( ! inputNumA ) ++inputNumB;
- inputNumB = (inputNumB + 1) & (numInputs_extF80 - 1);
- if ( ! inputNumB ) ++inputNumC;
- inputNumC = (inputNumC + 1) & (numInputs_extF80 - 1);
- }
- count += minIterations;
- } while ( clock() - startClock < CLOCKS_PER_SEC );
- inputNumA = 0;
- inputNumB = 0;
- inputNumC = 0;
- startClock = clock();
- for ( i = count; i; --i ) {
- function(
- &inputs_extF80[inputNumA].f,
- &inputs_extF80[inputNumB].f,
- &inputs_extF80[inputNumC].f,
- &z
- );
- inputNumA = (inputNumA + 1) & (numInputs_extF80 - 1);
- if ( ! inputNumA ) ++inputNumB;
- inputNumB = (inputNumB + 1) & (numInputs_extF80 - 1);
- if ( ! inputNumB ) ++inputNumC;
- inputNumC = (inputNumC + 1) & (numInputs_extF80 - 1);
- }
- endClock = clock();
- reportTime( count, endClock - startClock );
-
-}
-
-static
-void
time_ab_extF80_z_bool(
bool function( const extFloat80_t *, const extFloat80_t * ) )
{
@@ -3903,6 +3878,8 @@ static void time_a_f128_z_f32( float32_t function( const float128_t * ) )
}
+#ifdef FLOAT64
+
static void time_a_f128_z_f64( float64_t function( const float128_t * ) )
{
int_fast64_t count;
@@ -3932,6 +3909,8 @@ static void time_a_f128_z_f64( float64_t function( const float128_t * ) )
}
+#endif
+
#ifdef EXTFLOAT80
static
@@ -4227,8 +4206,10 @@ void
#endif
float32_t (*function_abz_f32)( float32_t, float32_t );
bool (*function_ab_f32_z_bool)( float32_t, float32_t );
+#ifdef FLOAT64
float64_t (*function_abz_f64)( float64_t, float64_t );
bool (*function_ab_f64_z_bool)( float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
void
(*function_abz_extF80)(
@@ -4236,9 +4217,9 @@ void
bool
(*function_ab_extF80_z_bool)(
const extFloat80_t *, const extFloat80_t * );
- void
#endif
#ifdef FLOAT128
+ void
(*function_abz_f128)(
const float128_t *, const float128_t *, float128_t * );
bool (*function_ab_f128_z_bool)( const float128_t *, const float128_t * );
@@ -4255,9 +4236,11 @@ void
case UI32_TO_F32:
time_a_ui32_z_f32( ui32_to_f32 );
break;
+#ifdef FLOAT64
case UI32_TO_F64:
time_a_ui32_z_f64( ui32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI32_TO_EXTF80:
time_a_ui32_z_extF80( ui32_to_extF80M );
@@ -4276,9 +4259,11 @@ void
case UI64_TO_F32:
time_a_ui64_z_f32( ui64_to_f32 );
break;
+#ifdef FLOAT64
case UI64_TO_F64:
time_a_ui64_z_f64( ui64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case UI64_TO_EXTF80:
time_a_ui64_z_extF80( ui64_to_extF80M );
@@ -4297,9 +4282,11 @@ void
case I32_TO_F32:
time_a_i32_z_f32( i32_to_f32 );
break;
+#ifdef FLOAT64
case I32_TO_F64:
time_a_i32_z_f64( i32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I32_TO_EXTF80:
time_a_i32_z_extF80( i32_to_extF80M );
@@ -4318,9 +4305,11 @@ void
case I64_TO_F32:
time_a_i64_z_f32( i64_to_f32 );
break;
+#ifdef FLOAT64
case I64_TO_F64:
time_a_i64_z_f64( i64_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case I64_TO_EXTF80:
time_a_i64_z_extF80( i64_to_extF80M );
@@ -4361,9 +4350,11 @@ void
case F16_TO_F32:
time_a_f16_z_f32( f16_to_f32 );
break;
+#ifdef FLOAT64
case F16_TO_F64:
time_a_f16_z_f64( f16_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F16_TO_EXTF80:
time_a_f16_z_extF80( f16_to_extF80M );
@@ -4452,9 +4443,11 @@ void
time_a_f32_z_f16( f32_to_f16 );
break;
#endif
+#ifdef FLOAT64
case F32_TO_F64:
time_a_f32_z_f64( f32_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F32_TO_EXTF80:
time_a_f32_z_extF80( f32_to_extF80M );
@@ -4513,6 +4506,7 @@ void
break;
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
+#ifdef FLOAT64
case F64_TO_UI32:
time_a_f64_z_ui32_rx( f64_to_ui32, roundingMode, exact );
break;
@@ -4601,6 +4595,7 @@ void
time_ab_f64_z_bool:
time_ab_f64_z_bool( function_ab_f64_z_bool );
break;
+#endif
/*--------------------------------------------------------------------
*--------------------------------------------------------------------*/
#ifdef EXTFLOAT80
@@ -4636,9 +4631,11 @@ void
case EXTF80_TO_F32:
time_a_extF80_z_f32( extF80M_to_f32 );
break;
+#ifdef FLOAT64
case EXTF80_TO_F64:
time_a_extF80_z_f64( extF80M_to_f64 );
break;
+#endif
#ifdef FLOAT128
case EXTF80_TO_F128:
time_a_extF80_z_f128( extF80M_to_f128M );
@@ -4723,9 +4720,11 @@ void
case F128_TO_F32:
time_a_f128_z_f32( f128M_to_f32 );
break;
+#ifdef FLOAT64
case F128_TO_F64:
time_a_f128_z_f64( f128M_to_f64 );
break;
+#endif
#ifdef EXTFLOAT80
case F128_TO_EXTF80:
time_a_f128_z_extF80( f128M_to_extF80M );
@@ -4918,6 +4917,9 @@ int main( int argc, char *argv[] )
" -rmax --Time only rounding to maximum (up).\n"
" -rnear_maxMag --Time only rounding to nearest/maximum magnitude\n"
" (nearest/away).\n"
+#ifdef FLOAT_ROUND_ODD
+" -rodd --Time only rounding to odd (jamming).\n"
+#endif
" -tininessbefore --Time only underflow tininess detected before rounding.\n"
" -tininessafter --Time only underflow tininess detected after rounding.\n"
" -notexact --Time only non-exact rounding to integer (no inexact\n"
@@ -4945,7 +4947,9 @@ int main( int argc, char *argv[] )
" f16 --Binary 16-bit floating-point (half-precision).\n"
#endif
" f32 --Binary 32-bit floating-point (single-precision).\n"
+#ifdef FLOAT64
" f64 --Binary 64-bit floating-point (double-precision).\n"
+#endif
#ifdef EXTFLOAT80
" extF80 --Binary 80-bit extended floating-point.\n"
#endif
@@ -4986,6 +4990,10 @@ int main( int argc, char *argv[] )
|| ! strcmp( argPtr, "rnearest_maxMag" )
) {
roundingCode = ROUND_NEAR_MAXMAG;
+#ifdef FLOAT_ROUND_ODD
+ } else if ( ! strcmp( argPtr, "rodd" ) ) {
+ roundingCode = ROUND_ODD;
+#endif
} else if ( ! strcmp( argPtr, "tininessbefore" ) ) {
tininessCode = TININESS_BEFORE_ROUNDING;
} else if ( ! strcmp( argPtr, "tininessafter" ) ) {
@@ -5011,7 +5019,7 @@ int main( int argc, char *argv[] )
while ( strcmp( argPtr, functionInfos[functionCode].namePtr ) ) {
++functionCode;
if ( functionCode == NUM_FUNCTIONS ) {
- fail( "Invalid argument `%s'", *argv );
+ fail( "Invalid argument '%s'", *argv );
}
}
haveFunctionArg = true;
diff --git a/source/uint128.c b/source/uint128.c
index e9b24e5..79ebd6c 100644
--- a/source/uint128.c
+++ b/source/uint128.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/uint128.h b/source/uint128.h
index 0f433bb..79dcc3b 100644
--- a/source/uint128.h
+++ b/source/uint128.h
@@ -1,7 +1,7 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/uint128_inline.c b/source/uint128_inline.c
index 4f5f60f..cead96a 100644
--- a/source/uint128_inline.c
+++ b/source/uint128_inline.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/verCases.h b/source/verCases.h
index 941a0e5..dddc865 100644
--- a/source/verCases.h
+++ b/source/verCases.h
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -38,6 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <stdbool.h>
#include <stdint.h>
#include <stdio.h>
+#include <signal.h>
#include "uint128.h"
#include "softfloat.h"
@@ -55,7 +56,7 @@ extern bool verCases_errorStop;
void verCases_writeFunctionName( FILE * );
-extern volatile bool verCases_stop;
+extern volatile sig_atomic_t verCases_stop;
extern bool verCases_anyErrors;
@@ -100,6 +101,8 @@ INLINE bool f32_isNaN( float32_t a )
return 0x7F800000 < (uA.ui & 0x7FFFFFFF);
}
+#ifdef FLOAT64
+
INLINE bool f64_same( float64_t a, float64_t b )
{
union { uint64_t ui; float64_t f; } uA, uB;
@@ -117,6 +120,8 @@ INLINE bool f64_isNaN( float64_t a )
< (uA.ui & UINT64_C( 0x7FFFFFFFFFFFFFFF ));
}
+#endif
+
#ifdef EXTFLOAT80
INLINE bool extF80M_same( const extFloat80_t *aPtr, const extFloat80_t *bPtr )
@@ -165,8 +170,10 @@ bool f16_isNaN( float16_t );
#endif
bool f32_same( float32_t, float32_t );
bool f32_isNaN( float32_t );
+#ifdef FLOAT64
bool f64_same( float64_t, float64_t );
bool f64_isNaN( float64_t );
+#endif
#ifdef EXTFLOAT80
bool extF80M_same( const extFloat80_t *, const extFloat80_t * );
bool extF80M_isNaN( const extFloat80_t * );
diff --git a/source/verCases_common.c b/source/verCases_common.c
index db8e588..2c5728e 100644
--- a/source/verCases_common.c
+++ b/source/verCases_common.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -39,6 +39,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
+#include <signal.h>
#include "platform.h"
#include "verCases.h"
@@ -52,7 +53,7 @@ bool verCases_checkNaNs = false;
uint_fast32_t verCases_maxErrorCount = 0;
bool verCases_errorStop = false;
-volatile bool verCases_stop = false;
+volatile sig_atomic_t verCases_stop = false;
bool verCases_anyErrors = false;
diff --git a/source/verCases_inline.c b/source/verCases_inline.c
index 0cdc479..cc6a2fb 100644
--- a/source/verCases_inline.c
+++ b/source/verCases_inline.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -75,6 +75,8 @@ bool f32_isNaN( float32_t a )
return 0x7F800000 < (uA.ui & 0x7FFFFFFF);
}
+#ifdef FLOAT64
+
bool f64_same( float64_t a, float64_t b )
{
union { uint64_t ui; float64_t f; } uA, uB;
@@ -92,6 +94,8 @@ bool f64_isNaN( float64_t a )
< (uA.ui & UINT64_C( 0x7FFFFFFFFFFFFFFF ));
}
+#endif
+
#ifdef EXTFLOAT80
bool extF80M_same( const extFloat80_t *aPtr, const extFloat80_t *bPtr )
diff --git a/source/verCases_writeFunctionName.c b/source/verCases_writeFunctionName.c
index 93c91ac..cc5bb2b 100644
--- a/source/verCases_writeFunctionName.c
+++ b/source/verCases_writeFunctionName.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -48,7 +48,10 @@ void verCases_writeFunctionName( FILE *streamPtr )
", rounding minMag",
", rounding min",
", rounding max",
- ", rounding near_maxMag"
+ ", rounding near_maxMag",
+#ifdef FLOAT_ROUND_ODD
+ ", rounding odd"
+#endif
};
fputs( verCases_functionNamePtr, streamPtr );
diff --git a/source/verLoops.c b/source/verLoops.c
index ff61436..85c7c74 100644
--- a/source/verLoops.c
+++ b/source/verLoops.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -136,6 +136,8 @@ static void readVerInput_f32( float32_t *aPtr )
}
+#ifdef FLOAT64
+
static void readVerInput_f64( float64_t *aPtr )
{
union { uint64_t ui; float64_t f; } uA;
@@ -145,6 +147,8 @@ static void readVerInput_f64( float64_t *aPtr )
}
+#endif
+
#ifdef EXTFLOAT80
static void readVerInput_extF80( extFloat80_t *aPtr )
@@ -293,6 +297,8 @@ void ver_a_ui32_z_f32( float32_t trueFunction( uint32_t ) )
}
+#ifdef FLOAT64
+
void ver_a_ui32_z_f64( float64_t trueFunction( uint32_t ) )
{
int count;
@@ -337,6 +343,8 @@ void ver_a_ui32_z_f64( float64_t trueFunction( uint32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_ui32_z_extF80( void trueFunction( uint32_t, extFloat80_t * ) )
@@ -373,7 +381,7 @@ void ver_a_ui32_z_extF80( void trueFunction( uint32_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui32( a, " " );
+ writeCase_a_ui32( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -528,6 +536,8 @@ void ver_a_ui64_z_f32( float32_t trueFunction( uint64_t ) )
}
+#ifdef FLOAT64
+
void ver_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
{
int count;
@@ -562,7 +572,7 @@ void ver_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui64( a, " " );
+ writeCase_a_ui64( a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -572,6 +582,8 @@ void ver_a_ui64_z_f64( float64_t trueFunction( uint64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_ui64_z_extF80( void trueFunction( uint64_t, extFloat80_t * ) )
@@ -608,7 +620,7 @@ void ver_a_ui64_z_extF80( void trueFunction( uint64_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_ui64( a, " " );
+ writeCase_a_ui64( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -763,6 +775,8 @@ void ver_a_i32_z_f32( float32_t trueFunction( int32_t ) )
}
+#ifdef FLOAT64
+
void ver_a_i32_z_f64( float64_t trueFunction( int32_t ) )
{
int count;
@@ -807,6 +821,8 @@ void ver_a_i32_z_f64( float64_t trueFunction( int32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_i32_z_extF80( void trueFunction( int32_t, extFloat80_t * ) )
@@ -843,7 +859,7 @@ void ver_a_i32_z_extF80( void trueFunction( int32_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i32( a, " " );
+ writeCase_a_i32( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -998,6 +1014,8 @@ void ver_a_i64_z_f32( float32_t trueFunction( int64_t ) )
}
+#ifdef FLOAT64
+
void ver_a_i64_z_f64( float64_t trueFunction( int64_t ) )
{
int count;
@@ -1032,7 +1050,7 @@ void ver_a_i64_z_f64( float64_t trueFunction( int64_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i64( a, " " );
+ writeCase_a_i64( a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1042,6 +1060,8 @@ void ver_a_i64_z_f64( float64_t trueFunction( int64_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_i64_z_extF80( void trueFunction( int64_t, extFloat80_t * ) )
@@ -1078,7 +1098,7 @@ void ver_a_i64_z_extF80( void trueFunction( int64_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_i64( a, " " );
+ writeCase_a_i64( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1184,7 +1204,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_ui32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1235,7 +1255,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_ui64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1286,7 +1306,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_i32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1338,7 +1358,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_i64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1386,7 +1406,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_ui32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1434,7 +1454,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_ui64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1482,7 +1502,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_i32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1531,7 +1551,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_i64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1578,7 +1598,7 @@ void ver_a_f16_z_f32( float32_t trueFunction( float16_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1588,6 +1608,8 @@ void ver_a_f16_z_f32( float32_t trueFunction( float16_t ) )
}
+#ifdef FLOAT64
+
void ver_a_f16_z_f64( float64_t trueFunction( float16_t ) )
{
int count;
@@ -1625,7 +1647,7 @@ void ver_a_f16_z_f64( float64_t trueFunction( float16_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1635,6 +1657,8 @@ void ver_a_f16_z_f64( float64_t trueFunction( float16_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_f16_z_extF80( void trueFunction( float16_t, extFloat80_t * ) )
@@ -1674,7 +1698,7 @@ void ver_a_f16_z_extF80( void trueFunction( float16_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1725,7 +1749,7 @@ void ver_a_f16_z_f128( void trueFunction( float16_t, float128_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1773,7 +1797,7 @@ void ver_az_f16( float16_t trueFunction( float16_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1824,7 +1848,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f16( a, " " );
+ writeCase_a_f16( a );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1874,7 +1898,7 @@ void ver_abz_f16( float16_t trueFunction( float16_t, float16_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f16( a, b, " " );
+ writeCase_ab_f16( a, b );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1926,7 +1950,7 @@ void ver_abcz_f16( float16_t trueFunction( float16_t, float16_t, float16_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_abc_f16( a, b, c, "\n\t" );
+ writeCase_abc_f16( a, b, c );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -1971,7 +1995,7 @@ void ver_ab_f16_z_bool( bool trueFunction( float16_t, float16_t ) )
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f16( a, b, " " );
+ writeCase_ab_f16( a, b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -2435,6 +2459,8 @@ void ver_a_f32_z_f16( float16_t trueFunction( float32_t ) )
#endif
+#ifdef FLOAT64
+
void ver_a_f32_z_f64( float64_t trueFunction( float32_t ) )
{
int count;
@@ -2482,6 +2508,8 @@ void ver_a_f32_z_f64( float64_t trueFunction( float32_t ) )
}
+#endif
+
#ifdef EXTFLOAT80
void ver_a_f32_z_extF80( void trueFunction( float32_t, extFloat80_t * ) )
@@ -2521,7 +2549,7 @@ void ver_a_f32_z_extF80( void trueFunction( float32_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f32( a, " " );
+ writeCase_a_f32( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -2721,7 +2749,7 @@ void ver_abz_f32( float32_t trueFunction( float32_t, float32_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f32( a, b, " " );
+ writeCase_ab_f32( a, b );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -2773,7 +2801,7 @@ void ver_abcz_f32( float32_t trueFunction( float32_t, float32_t, float32_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_abc_f32( a, b, c, "\n\t" );
+ writeCase_abc_f32( a, b, c );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -2818,7 +2846,7 @@ void ver_ab_f32_z_bool( bool trueFunction( float32_t, float32_t ) )
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f32( a, b, " " );
+ writeCase_ab_f32( a, b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -2831,6 +2859,8 @@ void ver_ab_f32_z_bool( bool trueFunction( float32_t, float32_t ) )
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
+#ifdef FLOAT64
+
void
ver_a_f64_z_ui32_rx(
uint_fast32_t trueFunction( float64_t, uint_fast8_t, bool ),
@@ -3366,7 +3396,7 @@ void ver_a_f64_z_extF80( void trueFunction( float64_t, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( a, " " );
+ writeCase_a_f64( a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -3465,7 +3495,7 @@ void ver_az_f64( float64_t trueFunction( float64_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( a, " " );
+ writeCase_a_f64( a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -3516,7 +3546,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f64( a, " " );
+ writeCase_a_f64( a, "\n\t" );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -3618,7 +3648,7 @@ void ver_abcz_f64( float64_t trueFunction( float64_t, float64_t, float64_t ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_abc_f64( a, b, c, "\n\t" );
+ writeCase_abc_f64( a, b, c );
writeCase_z_f64( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -3673,6 +3703,8 @@ void ver_ab_f64_z_bool( bool trueFunction( float64_t, float64_t ) )
}
+#endif
+
/*----------------------------------------------------------------------------
*----------------------------------------------------------------------------*/
@@ -4115,7 +4147,7 @@ void ver_a_extF80_z_f16( float16_t trueFunction( const extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &a, "\n\t" );
+ writeCase_a_extF80M( &a, " " );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4164,7 +4196,7 @@ void ver_a_extF80_z_f32( float32_t trueFunction( const extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &a, "\n\t" );
+ writeCase_a_extF80M( &a, " " );
writeCase_z_f32( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4174,6 +4206,8 @@ void ver_a_extF80_z_f32( float32_t trueFunction( const extFloat80_t * ) )
}
+#ifdef FLOAT64
+
void ver_a_extF80_z_f64( float64_t trueFunction( const extFloat80_t * ) )
{
int count;
@@ -4221,6 +4255,8 @@ void ver_a_extF80_z_f64( float64_t trueFunction( const extFloat80_t * ) )
}
+#endif
+
#ifdef FLOAT128
void
@@ -4261,7 +4297,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &a, "\n\t" );
+ writeCase_a_extF80M( &a, " " );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4309,7 +4345,7 @@ void ver_az_extF80( void trueFunction( const extFloat80_t *, extFloat80_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &a, " " );
+ writeCase_a_extF80M( &a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4361,7 +4397,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_extF80M( &a, " " );
+ writeCase_a_extF80M( &a, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4417,70 +4453,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_extF80M( &a, &b, " " );
- writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
- if ( verCases_errorCount == verCases_maxErrorCount ) break;
- }
- }
- }
- verCases_writeTestsPerformed( 10000 - count );
-
-}
-
-void
- ver_abcz_extF80(
- void
- trueFunction(
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- extFloat80_t *
- )
- )
-{
- int count;
- extFloat80_t a, b, c, subjZ;
- uint_fast8_t subjFlags;
- extFloat80_t trueZ;
- uint_fast8_t trueFlags;
-
- verCases_errorCount = 0;
- verCases_tenThousandsCount = 0;
- count = 10000;
- while ( ! atEndOfInput() ) {
- readVerInput_extF80( &a );
- readVerInput_extF80( &b );
- readVerInput_extF80( &c );
- readVerInput_extF80( &subjZ );
- readVerInput_flags( &subjFlags );
- *verLoops_trueFlagsPtr = 0;
- trueFunction( &a, &b, &c, &trueZ );
- trueFlags = *verLoops_trueFlagsPtr;
- --count;
- if ( ! count ) {
- verCases_perTenThousand();
- count = 10000;
- }
- if ( ! extF80M_same( &trueZ, &subjZ ) || (trueFlags != subjFlags) ) {
- if (
- ! verCases_checkNaNs
- && ( extF80M_isSignalingNaN( &a )
- || extF80M_isSignalingNaN( &b )
- || extF80M_isSignalingNaN( &c )
- )
- ) {
- trueFlags |= softfloat_flag_invalid;
- }
- if (
- verCases_checkNaNs
- || ! extF80M_isNaN( &trueZ )
- || ! extF80M_isNaN( &subjZ )
- || extF80M_isSignalingNaN( &subjZ )
- || (trueFlags != subjFlags)
- ) {
- ++verCases_errorCount;
- verCases_writeErrorFound( 10000 - count );
- writeCase_abc_extF80M( &a, &b, &c, "\n\t" );
+ writeCase_ab_extF80M( &a, &b, "\n\t" );
writeCase_z_extF80M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -4982,7 +4955,7 @@ void ver_a_f128_z_f16( float16_t trueFunction( const float128_t * ) )
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_a_f128M( &a, "\n\t" );
+ writeCase_a_f128M( &a, " " );
writeCase_z_f16( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -5041,6 +5014,8 @@ void ver_a_f128_z_f32( float32_t trueFunction( const float128_t * ) )
}
+#ifdef FLOAT64
+
void ver_a_f128_z_f64( float64_t trueFunction( const float128_t * ) )
{
int count;
@@ -5088,6 +5063,8 @@ void ver_a_f128_z_f64( float64_t trueFunction( const float128_t * ) )
}
+#endif
+
#ifdef EXTFLOAT80
void
@@ -5281,7 +5258,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f128M( &a, &b, "\n\t" );
+ writeCase_ab_f128M( &a, &b );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -5344,7 +5321,7 @@ void
) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_abc_f128M( &a, &b, &c, "\n\t" );
+ writeCase_abc_f128M( &a, &b, &c );
writeCase_z_f128M( &trueZ, trueFlags, &subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
@@ -5392,7 +5369,7 @@ void
if ( (trueZ != subjZ) || (trueFlags != subjFlags) ) {
++verCases_errorCount;
verCases_writeErrorFound( 10000 - count );
- writeCase_ab_f128M( &a, &b, " " );
+ writeCase_ab_f128M( &a, &b );
writeCase_z_bool( trueZ, trueFlags, subjZ, subjFlags );
if ( verCases_errorCount == verCases_maxErrorCount ) break;
}
diff --git a/source/verLoops.h b/source/verLoops.h
index 347bda3..61d59ca 100644
--- a/source/verLoops.h
+++ b/source/verLoops.h
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -45,7 +45,9 @@ extern uint_fast8_t *verLoops_trueFlagsPtr;
void ver_a_ui32_z_f16( float16_t ( uint32_t ) );
#endif
void ver_a_ui32_z_f32( float32_t ( uint32_t ) );
+#ifdef FLOAT64
void ver_a_ui32_z_f64( float64_t ( uint32_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_ui32_z_extF80( void ( uint32_t, extFloat80_t * ) );
#endif
@@ -56,7 +58,9 @@ void ver_a_ui32_z_f128( void ( uint32_t, float128_t * ) );
void ver_a_ui64_z_f16( float16_t ( uint64_t ) );
#endif
void ver_a_ui64_z_f32( float32_t ( uint64_t ) );
+#ifdef FLOAT64
void ver_a_ui64_z_f64( float64_t ( uint64_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_ui64_z_extF80( void ( uint64_t, extFloat80_t * ) );
#endif
@@ -67,7 +71,9 @@ void ver_a_ui64_z_f128( void ( uint64_t, float128_t * ) );
void ver_a_i32_z_f16( float16_t ( int32_t ) );
#endif
void ver_a_i32_z_f32( float32_t ( int32_t ) );
+#ifdef FLOAT64
void ver_a_i32_z_f64( float64_t ( int32_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_i32_z_extF80( void ( int32_t, extFloat80_t * ) );
#endif
@@ -78,7 +84,9 @@ void ver_a_i32_z_f128( void ( int32_t, float128_t * ) );
void ver_a_i64_z_f16( float16_t ( int64_t ) );
#endif
void ver_a_i64_z_f32( float32_t ( int64_t ) );
+#ifdef FLOAT64
void ver_a_i64_z_f64( float64_t ( int64_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_i64_z_extF80( void ( int64_t, extFloat80_t * ) );
#endif
@@ -104,7 +112,9 @@ void ver_a_f16_z_ui64_x( uint_fast64_t ( float16_t, bool ), bool );
void ver_a_f16_z_i32_x( int_fast32_t ( float16_t, bool ), bool );
void ver_a_f16_z_i64_x( int_fast64_t ( float16_t, bool ), bool );
void ver_a_f16_z_f32( float32_t ( float16_t ) );
+#ifdef FLOAT64
void ver_a_f16_z_f64( float64_t ( float16_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_f16_z_extF80( void ( float16_t, extFloat80_t * ) );
#endif
@@ -139,7 +149,9 @@ void ver_a_f32_z_i64_x( int_fast64_t ( float32_t, bool ), bool );
#ifdef FLOAT16
void ver_a_f32_z_f16( float16_t ( float32_t ) );
#endif
+#ifdef FLOAT64
void ver_a_f32_z_f64( float64_t ( float32_t ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_f32_z_extF80( void ( float32_t, extFloat80_t * ) );
#endif
@@ -154,6 +166,7 @@ void ver_abz_f32( float32_t ( float32_t, float32_t ) );
void ver_abcz_f32( float32_t ( float32_t, float32_t, float32_t ) );
void ver_ab_f32_z_bool( bool ( float32_t, float32_t ) );
+#ifdef FLOAT64
void
ver_a_f64_z_ui32_rx(
uint_fast32_t ( float64_t, uint_fast8_t, bool ), uint_fast8_t, bool );
@@ -187,6 +200,7 @@ void
void ver_abz_f64( float64_t ( float64_t, float64_t ) );
void ver_abcz_f64( float64_t ( float64_t, float64_t, float64_t ) );
void ver_ab_f64_z_bool( bool ( float64_t, float64_t ) );
+#endif
#ifdef EXTFLOAT80
void
@@ -223,7 +237,9 @@ void ver_a_extF80_z_i64_x( int_fast64_t ( const extFloat80_t *, bool ), bool );
void ver_a_extF80_z_f16( float16_t ( const extFloat80_t * ) );
#endif
void ver_a_extF80_z_f32( float32_t ( const extFloat80_t * ) );
+#ifdef FLOAT64
void ver_a_extF80_z_f64( float64_t ( const extFloat80_t * ) );
+#endif
#ifdef FLOAT128
void ver_a_extF80_z_f128( void ( const extFloat80_t *, float128_t * ) );
#endif
@@ -238,16 +254,6 @@ void
ver_abz_extF80(
void ( const extFloat80_t *, const extFloat80_t *, extFloat80_t * ) );
void
- ver_abcz_extF80(
- void
- (
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- extFloat80_t *
- )
- );
-void
ver_ab_extF80_z_bool( bool ( const extFloat80_t *, const extFloat80_t * ) );
#endif
@@ -284,7 +290,9 @@ void ver_a_f128_z_i64_x( int_fast64_t ( const float128_t *, bool ), bool );
void ver_a_f128_z_f16( float16_t ( const float128_t * ) );
#endif
void ver_a_f128_z_f32( float32_t ( const float128_t * ) );
+#ifdef FLOAT64
void ver_a_f128_z_f64( float64_t ( const float128_t * ) );
+#endif
#ifdef EXTFLOAT80
void ver_a_f128_z_extF80( void ( const float128_t *, extFloat80_t * ) );
#endif
diff --git a/source/writeCase.h b/source/writeCase.h
index f8eb025..40ea0b4 100644
--- a/source/writeCase.h
+++ b/source/writeCase.h
@@ -1,12 +1,12 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -44,37 +44,30 @@ void writeCase_a_ui64( uint_fast64_t, const char * );
#define writeCase_a_i32 writeCase_a_ui32
#define writeCase_a_i64 writeCase_a_ui64
#ifdef FLOAT16
-void writeCase_a_f16( float16_t, const char * );
-void writeCase_ab_f16( float16_t, float16_t, const char * );
-void writeCase_abc_f16( float16_t, float16_t, float16_t, const char * );
+void writeCase_a_f16( float16_t );
+void writeCase_ab_f16( float16_t, float16_t );
+void writeCase_abc_f16( float16_t, float16_t, float16_t );
#endif
void writeCase_a_f32( float32_t, const char * );
-void writeCase_ab_f32( float32_t, float32_t, const char * );
-void writeCase_abc_f32( float32_t, float32_t, float32_t, const char * );
+void writeCase_ab_f32( float32_t, float32_t );
+void writeCase_abc_f32( float32_t, float32_t, float32_t );
+#ifdef FLOAT64
void writeCase_a_f64( float64_t, const char * );
void writeCase_ab_f64( float64_t, float64_t, const char * );
-void writeCase_abc_f64( float64_t, float64_t, float64_t, const char * );
+void writeCase_abc_f64( float64_t, float64_t, float64_t );
+#endif
#ifdef EXTFLOAT80
void writeCase_a_extF80M( const extFloat80_t *, const char * );
void
writeCase_ab_extF80M(
const extFloat80_t *, const extFloat80_t *, const char * );
-void
- writeCase_abc_extF80M(
- const extFloat80_t *,
- const extFloat80_t *,
- const extFloat80_t *,
- const char *
- );
#endif
#ifdef FLOAT128
void writeCase_a_f128M( const float128_t *, const char * );
-void
- writeCase_ab_f128M( const float128_t *, const float128_t *, const char * );
+void writeCase_ab_f128M( const float128_t *, const float128_t * );
void
writeCase_abc_f128M(
- const float128_t *, const float128_t *, const float128_t *, const char *
- );
+ const float128_t *, const float128_t *, const float128_t * );
#endif
void writeCase_z_bool( bool, uint_fast8_t, bool, uint_fast8_t );
@@ -88,7 +81,9 @@ void
void writeCase_z_f16( float16_t, uint_fast8_t, float16_t, uint_fast8_t );
#endif
void writeCase_z_f32( float32_t, uint_fast8_t, float32_t, uint_fast8_t );
+#ifdef FLOAT64
void writeCase_z_f64( float64_t, uint_fast8_t, float64_t, uint_fast8_t );
+#endif
#ifdef EXTFLOAT80
void
writeCase_z_extF80M(
diff --git a/source/writeCase_a_extF80M.c b/source/writeCase_a_extF80M.c
index ada36fc..5d6b7ad 100644
--- a/source/writeCase_a_extF80M.c
+++ b/source/writeCase_a_extF80M.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_a_f128M.c b/source/writeCase_a_f128M.c
index 67315fd..535f7b6 100644
--- a/source/writeCase_a_f128M.c
+++ b/source/writeCase_a_f128M.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_a_f16.c b/source/writeCase_a_f16.c
index 4354dd9..3f8b3eb 100644
--- a/source/writeCase_a_f16.c
+++ b/source/writeCase_a_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -43,11 +43,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifdef FLOAT16
-void writeCase_a_f16( float16_t a, const char *sepStringPtr )
+void writeCase_a_f16( float16_t a )
{
writeHex_f16( a, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( " ", stdout );
}
diff --git a/source/writeCase_a_f32.c b/source/writeCase_a_f32.c
index 3ce35a9..0f7c1eb 100644
--- a/source/writeCase_a_f32.c
+++ b/source/writeCase_a_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_a_f64.c b/source/writeCase_a_f64.c
index 41e5852..24a4df7 100644
--- a/source/writeCase_a_f64.c
+++ b/source/writeCase_a_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -41,6 +41,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
+#ifdef FLOAT64
+
void writeCase_a_f64( float64_t a, const char *sepStringPtr )
{
@@ -49,3 +51,5 @@ void writeCase_a_f64( float64_t a, const char *sepStringPtr )
}
+#endif
+
diff --git a/source/writeCase_a_ui32.c b/source/writeCase_a_ui32.c
index 20856a2..dfe90b2 100644
--- a/source/writeCase_a_ui32.c
+++ b/source/writeCase_a_ui32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_a_ui64.c b/source/writeCase_a_ui64.c
index 133628f..88bf7f5 100644
--- a/source/writeCase_a_ui64.c
+++ b/source/writeCase_a_ui64.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_ab_extF80M.c b/source/writeCase_ab_extF80M.c
index 009401a..5705234 100644
--- a/source/writeCase_ab_extF80M.c
+++ b/source/writeCase_ab_extF80M.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_ab_f128M.c b/source/writeCase_ab_f128M.c
index a4c5dda..5e9d971 100644
--- a/source/writeCase_ab_f128M.c
+++ b/source/writeCase_ab_f128M.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -43,15 +43,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifdef FLOAT128
-void
- writeCase_ab_f128M(
- const float128_t *aPtr, const float128_t *bPtr, const char *sepStringPtr )
+void writeCase_ab_f128M( const float128_t *aPtr, const float128_t *bPtr )
{
writeHex_f128M( aPtr, 0 );
fputs( " ", stdout );
writeHex_f128M( bPtr, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( "\n\t", stdout );
}
diff --git a/source/writeCase_ab_f16.c b/source/writeCase_ab_f16.c
index 23dc7ee..4063c45 100644
--- a/source/writeCase_ab_f16.c
+++ b/source/writeCase_ab_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -43,13 +43,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifdef FLOAT16
-void writeCase_ab_f16( float16_t a, float16_t b, const char *sepStringPtr )
+void writeCase_ab_f16( float16_t a, float16_t b )
{
writeHex_f16( a, 0 );
fputs( " ", stdout );
writeHex_f16( b, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( " ", stdout );
}
diff --git a/source/writeCase_ab_f32.c b/source/writeCase_ab_f32.c
index f5d8385..e18cfe9 100644
--- a/source/writeCase_ab_f32.c
+++ b/source/writeCase_ab_f32.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -41,13 +41,13 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
-void writeCase_ab_f32( float32_t a, float32_t b, const char *sepStringPtr )
+void writeCase_ab_f32( float32_t a, float32_t b )
{
writeHex_f32( a, 0 );
fputs( " ", stdout );
writeHex_f32( b, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( " ", stdout );
}
diff --git a/source/writeCase_ab_f64.c b/source/writeCase_ab_f64.c
index 349b99d..efaaa4e 100644
--- a/source/writeCase_ab_f64.c
+++ b/source/writeCase_ab_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -41,6 +41,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
+#ifdef FLOAT64
+
void writeCase_ab_f64( float64_t a, float64_t b, const char *sepStringPtr )
{
@@ -51,3 +53,5 @@ void writeCase_ab_f64( float64_t a, float64_t b, const char *sepStringPtr )
}
+#endif
+
diff --git a/source/writeCase_abc_extF80M.c b/source/writeCase_abc_extF80M.c
deleted file mode 100644
index 5620d48..0000000
--- a/source/writeCase_abc_extF80M.c
+++ /dev/null
@@ -1,65 +0,0 @@
-
-/*============================================================================
-
-This C source file is part of TestFloat, Release 3b, a package of programs for
-testing the correctness of floating-point arithmetic complying with the IEEE
-Standard for Floating-Point, by John R. Hauser.
-
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are met:
-
- 1. Redistributions of source code must retain the above copyright notice,
- this list of conditions, and the following disclaimer.
-
- 2. Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions, and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
- 3. Neither the name of the University nor the names of its contributors may
- be used to endorse or promote products derived from this software without
- specific prior written permission.
-
-THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS "AS IS", AND ANY
-EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, ARE
-DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY
-DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-=============================================================================*/
-
-#include <stdint.h>
-#include <stdio.h>
-#include "platform.h"
-#include "writeHex.h"
-#include "writeCase.h"
-
-#ifdef EXTFLOAT80
-
-void
- writeCase_abc_extF80M(
- const extFloat80_t *aPtr,
- const extFloat80_t *bPtr,
- const extFloat80_t *cPtr,
- const char *sepStringPtr
- )
-{
-
- writeHex_extF80M( aPtr, 0 );
- fputs( " ", stdout );
- writeHex_extF80M( bPtr, 0 );
- fputs( "\n\t", stdout );
- writeHex_extF80M( cPtr, 0 );
- fputs( sepStringPtr, stdout );
-
-}
-
-#endif
-
diff --git a/source/writeCase_abc_f128M.c b/source/writeCase_abc_f128M.c
index 5ddcac2..0824b0f 100644
--- a/source/writeCase_abc_f128M.c
+++ b/source/writeCase_abc_f128M.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -45,11 +45,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
void
writeCase_abc_f128M(
- const float128_t *aPtr,
- const float128_t *bPtr,
- const float128_t *cPtr,
- const char *sepStringPtr
- )
+ const float128_t *aPtr, const float128_t *bPtr, const float128_t *cPtr )
{
writeHex_f128M( aPtr, 0 );
@@ -57,7 +53,7 @@ void
writeHex_f128M( bPtr, 0 );
fputs( "\n\t", stdout );
writeHex_f128M( cPtr, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( "\n\t", stdout );
}
diff --git a/source/writeCase_abc_f16.c b/source/writeCase_abc_f16.c
index 1f0471d..a37ca9d 100644
--- a/source/writeCase_abc_f16.c
+++ b/source/writeCase_abc_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -41,9 +41,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
-void
- writeCase_abc_f16(
- float16_t a, float16_t b, float16_t c, const char *sepStringPtr )
+#ifdef FLOAT16
+
+void writeCase_abc_f16( float16_t a, float16_t b, float16_t c )
{
writeHex_f16( a, 0 );
@@ -51,7 +51,9 @@ void
writeHex_f16( b, 0 );
fputs( " ", stdout );
writeHex_f16( c, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( " ", stdout );
}
+#endif
+
diff --git a/source/writeCase_abc_f32.c b/source/writeCase_abc_f32.c
index 53067ee..f1338e9 100644
--- a/source/writeCase_abc_f32.c
+++ b/source/writeCase_abc_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
@@ -41,9 +41,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
-void
- writeCase_abc_f32(
- float32_t a, float32_t b, float32_t c, const char *sepStringPtr )
+void writeCase_abc_f32( float32_t a, float32_t b, float32_t c )
{
writeHex_f32( a, 0 );
@@ -51,7 +49,7 @@ void
writeHex_f32( b, 0 );
fputs( " ", stdout );
writeHex_f32( c, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( "\n\t", stdout );
}
diff --git a/source/writeCase_abc_f64.c b/source/writeCase_abc_f64.c
index 891c0e1..afef373 100644
--- a/source/writeCase_abc_f64.c
+++ b/source/writeCase_abc_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -41,9 +41,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
-void
- writeCase_abc_f64(
- float64_t a, float64_t b, float64_t c, const char *sepStringPtr )
+#ifdef FLOAT64
+
+void writeCase_abc_f64( float64_t a, float64_t b, float64_t c )
{
writeHex_f64( a, 0 );
@@ -51,7 +51,9 @@ void
writeHex_f64( b, 0 );
fputs( " ", stdout );
writeHex_f64( c, 0 );
- fputs( sepStringPtr, stdout );
+ fputs( "\n\t", stdout );
}
+#endif
+
diff --git a/source/writeCase_z_bool.c b/source/writeCase_z_bool.c
index 6c1cc7d..c6e62e2 100644
--- a/source/writeCase_z_bool.c
+++ b/source/writeCase_z_bool.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_z_extF80M.c b/source/writeCase_z_extF80M.c
index 70c9c77..a49650d 100644
--- a/source/writeCase_z_extF80M.c
+++ b/source/writeCase_z_extF80M.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -56,7 +56,7 @@ void
fputs( "=> ", stdout );
writeHex_extF80M( subjZPtr, ' ' );
writeHex_softfloat_flags( subjFlags, 0 );
- fputs( "\n\texpected ", stdout );
+ fputs( " expected ", stdout );
writeHex_extF80M( trueZPtr, ' ' );
writeHex_softfloat_flags( trueFlags, '\n' );
fflush( stdout );
diff --git a/source/writeCase_z_f128M.c b/source/writeCase_z_f128M.c
index 00d96f8..e0e3617 100644
--- a/source/writeCase_z_f128M.c
+++ b/source/writeCase_z_f128M.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_z_f16.c b/source/writeCase_z_f16.c
index 6168c5f..2a96c0f 100644
--- a/source/writeCase_z_f16.c
+++ b/source/writeCase_z_f16.c
@@ -1,11 +1,11 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -42,6 +42,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
+#ifdef FLOAT16
+
void
writeCase_z_f16(
float16_t trueZ,
@@ -61,3 +63,5 @@ void
}
+#endif
+
diff --git a/source/writeCase_z_f32.c b/source/writeCase_z_f32.c
index 04d7d16..6093daf 100644
--- a/source/writeCase_z_f32.c
+++ b/source/writeCase_z_f32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_z_f64.c b/source/writeCase_z_f64.c
index b448555..aaf449e 100644
--- a/source/writeCase_z_f64.c
+++ b/source/writeCase_z_f64.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014 The Regents of the University of California.
-All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2017 The Regents of the University of
+California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -42,6 +42,8 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "writeHex.h"
#include "writeCase.h"
+#ifdef FLOAT64
+
void
writeCase_z_f64(
float64_t trueZ,
@@ -61,3 +63,5 @@ void
}
+#endif
+
diff --git a/source/writeCase_z_ui32.c b/source/writeCase_z_ui32.c
index 9553cf9..642fa5c 100644
--- a/source/writeCase_z_ui32.c
+++ b/source/writeCase_z_ui32.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeCase_z_ui64.c b/source/writeCase_z_ui64.c
index f4c7e46..f826992 100644
--- a/source/writeCase_z_ui64.c
+++ b/source/writeCase_z_ui64.c
@@ -1,7 +1,7 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
diff --git a/source/writeHex.c b/source/writeHex.c
index 0a3109c..21a8cb8 100644
--- a/source/writeHex.c
+++ b/source/writeHex.c
@@ -1,12 +1,12 @@
/*============================================================================
-This C source file is part of TestFloat, Release 3b, a package of programs for
+This C source file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015, 2016 The Regents of the University of
-California. All rights reserved.
+Copyright 2011, 2012, 2013, 2014, 2015, 2016, 2017 The Regents of the
+University of California. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
@@ -152,6 +152,8 @@ void writeHex_f32( float32_t a, char sepChar )
}
+#ifdef FLOAT64
+
void writeHex_f64( float64_t a, char sepChar )
{
union { uint64_t ui; float64_t f; } uA;
@@ -168,6 +170,8 @@ void writeHex_f64( float64_t a, char sepChar )
}
+#endif
+
#ifdef EXTFLOAT80
void writeHex_extF80M( const extFloat80_t *aPtr, char sepChar )
diff --git a/source/writeHex.h b/source/writeHex.h
index 84d2a2f..e92e449 100644
--- a/source/writeHex.h
+++ b/source/writeHex.h
@@ -1,11 +1,11 @@
/*============================================================================
-This C header file is part of TestFloat, Release 3b, a package of programs for
+This C header file is part of TestFloat, Release 3c, a package of programs for
testing the correctness of floating-point arithmetic complying with the IEEE
Standard for Floating-Point, by John R. Hauser.
-Copyright 2011, 2012, 2013, 2014, 2015 The Regents of the University of
+Copyright 2011, 2012, 2013, 2014, 2015, 2017 The Regents of the University of
California. All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -48,7 +48,9 @@ void writeHex_ui64( uint_fast64_t, char );
void writeHex_f16( float16_t, char );
#endif
void writeHex_f32( float32_t, char );
+#ifdef FLOAT64
void writeHex_f64( float64_t, char );
+#endif
#ifdef EXTFLOAT80
void writeHex_extF80M( const extFloat80_t *, char );
#endif