From 90ca6847bbd0c7b2debb5a985d7f49e464f68577 Mon Sep 17 00:00:00 2001 From: Tobias Burnus Date: Wed, 27 Nov 2019 10:16:24 +0100 Subject: PR 92463 - Cleanups due to minimum MPFR version bump to 3.1.0 PR middle-end/92463 * configure.ac: Use MPFR_RNDN instead of GMP's MP_RNDN. * configure: Regenerate gcc/ PR middle-end/92463 * builtins.c (do_mpfr_ckconv, do_mpc_ckconv, do_mpfr_remquo, do_mpfr_lgamma_r, do_mpc_arg2): Use MPFR_RNDx instead of GMP_RNDx, mpfr_rnd_t instead of mp_rnd_t. * fold-const-call.c (do_mpfr_ckconv, do_mpfr_arg1, do_mpfr_sincos, do_mpfr_arg2, do_mpfr_arg3, do_mpc_arg1, do_mpc_arg2): Likewise. * gimple-ssa-sprintf.c (format_floating_max, format_floating): Use mpfr_exp_t instead of mp_exp_t. * real.c (real_from_string, dconst_e_ptr, dconst_sqrt2_ptr): Use MPFR_RNDx instead of GMP_RNDx. * realmpfr.c (real_from_mpfr, mpfr_from_real): Use mpfr_rnd_t and mpfr_exp_t instead mp_rnd_t and mp_exp_t, respectively. * realmpfr.h (real_from_mpfr, mpfr_from_real): Use mpfr_rnd_t instead of mp_rnd_t and remove MPFR_RNDx poisoning. * ubsan.c (ubsan_instrument_float_cast): MPFR_RNDx instead of GMP_RNDx. fortran/ PR middle-end/92463 * arith.c (gfc_check_real_range): Replace mp_exp_t by mpfr_exp_t. From-SVN: r278761 --- gcc/ubsan.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gcc/ubsan.c') diff --git a/gcc/ubsan.c b/gcc/ubsan.c index d269630..f12674b 100644 --- a/gcc/ubsan.c +++ b/gcc/ubsan.c @@ -1860,7 +1860,7 @@ ubsan_instrument_float_cast (location_t loc, tree type, tree expr) representable decimal number greater or equal than 1 << (prec - !uns_p). */ mpfr_init2 (m, prec + 2); - mpfr_set_ui_2exp (m, 1, prec - !uns_p, GMP_RNDN); + mpfr_set_ui_2exp (m, 1, prec - !uns_p, MPFR_RNDN); mpfr_snprintf (buf, sizeof buf, "%.*RUe", p - 1, m); decimal_real_from_string (&maxval, buf); max = build_real (expr_type, maxval); @@ -1873,8 +1873,8 @@ ubsan_instrument_float_cast (location_t loc, tree type, tree expr) /* Use mpfr_snprintf rounding to compute the largest representable decimal number less or equal than (-1 << (prec - 1)) - 1. */ - mpfr_set_si_2exp (m, -1, prec - 1, GMP_RNDN); - mpfr_sub_ui (m, m, 1, GMP_RNDN); + mpfr_set_si_2exp (m, -1, prec - 1, MPFR_RNDN); + mpfr_sub_ui (m, m, 1, MPFR_RNDN); mpfr_snprintf (buf, sizeof buf, "%.*RDe", p - 1, m); decimal_real_from_string (&minval, buf); min = build_real (expr_type, minval); -- cgit v1.1