summaryrefslogtreecommitdiff
path: root/tests/texp.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/texp.c')
-rw-r--r--tests/texp.c31
1 files changed, 13 insertions, 18 deletions
diff --git a/tests/texp.c b/tests/texp.c
index 0e85589b4..e0c9e26f2 100644
--- a/tests/texp.c
+++ b/tests/texp.c
@@ -273,26 +273,21 @@ check_special (void)
}
/* Check overflow. Corner case of mpfr_exp_2 */
- /* FIXME: The main purpose of the test below was on 32-bit ABI,
- but it is no longer run there. */
mpfr_set_prec (x, 64);
- if (mpfr_set_emax (1073741823) == 0)
- { /* 1073741823 is in the allowed exponent range */
- mpfr_set_emin (MPFR_EMIN_DEFAULT);
- mpfr_set_str (x,
- "0.1011000101110010000101111111010100001100000001110001100111001101E30",
- 2, MPFR_RNDN);
- mpfr_exp (x, x, MPFR_RNDD);
- if (mpfr_cmp_str (x,
- ".1111111111111111111111111111111111111111111111111111111111111111E1073741823",
- 2, MPFR_RNDN) != 0)
- {
- printf ("Wrong overflow detection in mpfr_exp\n");
- mpfr_dump (x);
- exit (1);
- }
+ mpfr_set_emax (MPFR_EMAX_DEFAULT);
+ mpfr_set_emin (MPFR_EMIN_DEFAULT);
+ mpfr_set_str (x,
+ "0.1011000101110010000101111111010100001100000001110001100111001101E30",
+ 2, MPFR_RNDN);
+ mpfr_exp (x, x, MPFR_RNDD);
+ if (mpfr_cmp_str (x,
+".1111111111111111111111111111111111111111111111111111111111111111E1073741823",
+ 2, MPFR_RNDN) != 0)
+ {
+ printf ("Wrong overflow detection in mpfr_exp\n");
+ mpfr_dump (x);
+ exit (1);
}
-
/* Check underflow. Corner case of mpfr_exp_2 */
mpfr_set_str (x,
"-0.1011000101110010000101111111011111010001110011110111100110101100E30",