Commit 36c713e0 by Kaveh R. Ghazi Committed by Kaveh Ghazi

configure.ac (MPFR check): Bump minimum version to 2.3.0 and recommended version to 2.3.2.

	* configure.ac (MPFR check): Bump minimum version to 2.3.0 and
	recommended version to 2.3.2.

	* configure: Regenerate.

gcc:
	* builtins.c: Remove MPFR_VERSION_NUM(2,3,0) conditionals.
	* doc/install.texi: Bump recommended MPFR to 2.3.2.
	
fortran:
	* simplify.c: Remove MPFR_VERSION_NUM(2,3,0) conditionals.

From-SVN: r141085
parent ae3fb6fd
2008-10-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* configure.ac (MPFR check): Bump minimum version to 2.3.0 and
recommended version to 2.3.2.
* configure: Regenerate.
2008-10-01 Mark Mitchell <mark@codesourcery.com> 2008-10-01 Mark Mitchell <mark@codesourcery.com>
* MAINTAINERS (Blanket Write Privs): Change to Global Reviewers. * MAINTAINERS (Blanket Write Privs): Change to Global Reviewers.
......
...@@ -4674,7 +4674,7 @@ int ...@@ -4674,7 +4674,7 @@ int
main () main ()
{ {
#if MPFR_VERSION < MPFR_VERSION_NUM(2,2,1) #if MPFR_VERSION < MPFR_VERSION_NUM(2,3,0)
choke me choke me
#endif #endif
mpfr_t n; mpfr_t n;
...@@ -4724,7 +4724,7 @@ int ...@@ -4724,7 +4724,7 @@ int
main () main ()
{ {
#if MPFR_VERSION < MPFR_VERSION_NUM(2,3,0) #if MPFR_VERSION < MPFR_VERSION_NUM(2,3,2)
choke me choke me
#endif #endif
mpfr_t n; mpfr_init(n); mpfr_t n; mpfr_init(n);
...@@ -4780,7 +4780,7 @@ rm -f conftest.err conftest.$ac_objext \ ...@@ -4780,7 +4780,7 @@ rm -f conftest.err conftest.$ac_objext \
CFLAGS="$saved_CFLAGS" CFLAGS="$saved_CFLAGS"
if test x$have_gmp != xyes; then if test x$have_gmp != xyes; then
{ { echo "$as_me:$LINENO: error: Building GCC requires GMP 4.1+ and MPFR 2.3.0+. { { echo "$as_me:$LINENO: error: Building GCC requires GMP 4.1+ and MPFR 2.3.2+.
Try the --with-gmp and/or --with-mpfr options to specify their locations. Try the --with-gmp and/or --with-mpfr options to specify their locations.
Copies of these libraries' source code can be found at their respective Copies of these libraries' source code can be found at their respective
hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/. hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
...@@ -4788,7 +4788,7 @@ See also http://gcc.gnu.org/install/prerequisites.html for additional info. ...@@ -4788,7 +4788,7 @@ See also http://gcc.gnu.org/install/prerequisites.html for additional info.
If you obtained GMP and/or MPFR from a vendor distribution package, make If you obtained GMP and/or MPFR from a vendor distribution package, make
sure that you have installed both the libraries and the header files. sure that you have installed both the libraries and the header files.
They may be located in separate packages." >&5 They may be located in separate packages." >&5
echo "$as_me: error: Building GCC requires GMP 4.1+ and MPFR 2.3.0+. echo "$as_me: error: Building GCC requires GMP 4.1+ and MPFR 2.3.2+.
Try the --with-gmp and/or --with-mpfr options to specify their locations. Try the --with-gmp and/or --with-mpfr options to specify their locations.
Copies of these libraries' source code can be found at their respective Copies of these libraries' source code can be found at their respective
hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/. hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
......
...@@ -1267,11 +1267,11 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then ...@@ -1267,11 +1267,11 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then
if test x"$have_gmp" = xyes; then if test x"$have_gmp" = xyes; then
saved_LIBS="$LIBS" saved_LIBS="$LIBS"
LIBS="$LIBS $gmplibs" LIBS="$LIBS $gmplibs"
dnl MPFR 2.2.1 is acceptable, but MPFR 2.3.0 is better. dnl MPFR 2.3.0 is acceptable, but MPFR 2.3.2 is better.
AC_MSG_CHECKING([for correct version of mpfr.h]) AC_MSG_CHECKING([for correct version of mpfr.h])
AC_TRY_LINK([#include <gmp.h> AC_TRY_LINK([#include <gmp.h>
#include <mpfr.h>],[ #include <mpfr.h>],[
#if MPFR_VERSION < MPFR_VERSION_NUM(2,2,1) #if MPFR_VERSION < MPFR_VERSION_NUM(2,3,0)
choke me choke me
#endif #endif
mpfr_t n; mpfr_t n;
...@@ -1284,7 +1284,7 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then ...@@ -1284,7 +1284,7 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then
mpfr_subnormalize (x, t, GMP_RNDN); mpfr_subnormalize (x, t, GMP_RNDN);
], [AC_TRY_LINK([#include <gmp.h> ], [AC_TRY_LINK([#include <gmp.h>
#include <mpfr.h>],[ #include <mpfr.h>],[
#if MPFR_VERSION < MPFR_VERSION_NUM(2,3,0) #if MPFR_VERSION < MPFR_VERSION_NUM(2,3,2)
choke me choke me
#endif #endif
mpfr_t n; mpfr_init(n); mpfr_t n; mpfr_init(n);
...@@ -1295,7 +1295,7 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then ...@@ -1295,7 +1295,7 @@ if test -d ${srcdir}/gcc && test "x$have_gmp" = xno; then
CFLAGS="$saved_CFLAGS" CFLAGS="$saved_CFLAGS"
if test x$have_gmp != xyes; then if test x$have_gmp != xyes; then
AC_MSG_ERROR([Building GCC requires GMP 4.1+ and MPFR 2.3.0+. AC_MSG_ERROR([Building GCC requires GMP 4.1+ and MPFR 2.3.2+.
Try the --with-gmp and/or --with-mpfr options to specify their locations. Try the --with-gmp and/or --with-mpfr options to specify their locations.
Copies of these libraries' source code can be found at their respective Copies of these libraries' source code can be found at their respective
hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/. hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
......
2008-10-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* builtins.c: Remove MPFR_VERSION_NUM(2,3,0) conditionals.
* doc/install.texi: Bump recommended MPFR to 2.3.2.
2008-10-12 Kenneth Zadeck <zadeck@naturalbridge.com> 2008-10-12 Kenneth Zadeck <zadeck@naturalbridge.com>
PR middle-end/37808 PR middle-end/37808
......
...@@ -231,13 +231,11 @@ static tree do_mpfr_arg2 (tree, tree, tree, ...@@ -231,13 +231,11 @@ static tree do_mpfr_arg2 (tree, tree, tree,
static tree do_mpfr_arg3 (tree, tree, tree, tree, static tree do_mpfr_arg3 (tree, tree, tree, tree,
int (*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t)); int (*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t));
static tree do_mpfr_sincos (tree, tree, tree); static tree do_mpfr_sincos (tree, tree, tree);
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
static tree do_mpfr_bessel_n (tree, tree, tree, static tree do_mpfr_bessel_n (tree, tree, tree,
int (*)(mpfr_ptr, long, mpfr_srcptr, mp_rnd_t), int (*)(mpfr_ptr, long, mpfr_srcptr, mp_rnd_t),
const REAL_VALUE_TYPE *, bool); const REAL_VALUE_TYPE *, bool);
static tree do_mpfr_remquo (tree, tree, tree); static tree do_mpfr_remquo (tree, tree, tree);
static tree do_mpfr_lgamma_r (tree, tree, tree); static tree do_mpfr_lgamma_r (tree, tree, tree);
#endif
/* Return true if NODE should be considered for inline expansion regardless /* Return true if NODE should be considered for inline expansion regardless
of the optimization level. This means whenever a function is invoked with of the optimization level. This means whenever a function is invoked with
...@@ -10140,7 +10138,6 @@ fold_builtin_1 (tree fndecl, tree arg0, bool ignore) ...@@ -10140,7 +10138,6 @@ fold_builtin_1 (tree fndecl, tree arg0, bool ignore)
&dconstm1, NULL, false); &dconstm1, NULL, false);
break; break;
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
CASE_FLT_FN (BUILT_IN_J0): CASE_FLT_FN (BUILT_IN_J0):
if (validate_arg (arg0, REAL_TYPE)) if (validate_arg (arg0, REAL_TYPE))
return do_mpfr_arg1 (arg0, type, mpfr_j0, return do_mpfr_arg1 (arg0, type, mpfr_j0,
...@@ -10164,7 +10161,6 @@ fold_builtin_1 (tree fndecl, tree arg0, bool ignore) ...@@ -10164,7 +10161,6 @@ fold_builtin_1 (tree fndecl, tree arg0, bool ignore)
return do_mpfr_arg1 (arg0, type, mpfr_y1, return do_mpfr_arg1 (arg0, type, mpfr_y1,
&dconst0, NULL, false); &dconst0, NULL, false);
break; break;
#endif
CASE_FLT_FN (BUILT_IN_NAN): CASE_FLT_FN (BUILT_IN_NAN):
case BUILT_IN_NAND32: case BUILT_IN_NAND32:
...@@ -10280,7 +10276,6 @@ fold_builtin_2 (tree fndecl, tree arg0, tree arg1, bool ignore) ...@@ -10280,7 +10276,6 @@ fold_builtin_2 (tree fndecl, tree arg0, tree arg1, bool ignore)
switch (fcode) switch (fcode)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
CASE_FLT_FN (BUILT_IN_JN): CASE_FLT_FN (BUILT_IN_JN):
if (validate_arg (arg0, INTEGER_TYPE) if (validate_arg (arg0, INTEGER_TYPE)
&& validate_arg (arg1, REAL_TYPE)) && validate_arg (arg1, REAL_TYPE))
...@@ -10307,7 +10302,6 @@ fold_builtin_2 (tree fndecl, tree arg0, tree arg1, bool ignore) ...@@ -10307,7 +10302,6 @@ fold_builtin_2 (tree fndecl, tree arg0, tree arg1, bool ignore)
&& validate_arg(arg1, POINTER_TYPE)) && validate_arg(arg1, POINTER_TYPE))
return do_mpfr_lgamma_r (arg0, arg1, type); return do_mpfr_lgamma_r (arg0, arg1, type);
break; break;
#endif
CASE_FLT_FN (BUILT_IN_ATAN2): CASE_FLT_FN (BUILT_IN_ATAN2):
if (validate_arg (arg0, REAL_TYPE) if (validate_arg (arg0, REAL_TYPE)
...@@ -10464,14 +10458,12 @@ fold_builtin_3 (tree fndecl, tree arg0, tree arg1, tree arg2, bool ignore) ...@@ -10464,14 +10458,12 @@ fold_builtin_3 (tree fndecl, tree arg0, tree arg1, tree arg2, bool ignore)
return do_mpfr_arg3 (arg0, arg1, arg2, type, mpfr_fma); return do_mpfr_arg3 (arg0, arg1, arg2, type, mpfr_fma);
break; break;
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
CASE_FLT_FN (BUILT_IN_REMQUO): CASE_FLT_FN (BUILT_IN_REMQUO):
if (validate_arg (arg0, REAL_TYPE) if (validate_arg (arg0, REAL_TYPE)
&& validate_arg(arg1, REAL_TYPE) && validate_arg(arg1, REAL_TYPE)
&& validate_arg(arg2, POINTER_TYPE)) && validate_arg(arg2, POINTER_TYPE))
return do_mpfr_remquo (arg0, arg1, arg2); return do_mpfr_remquo (arg0, arg1, arg2);
break; break;
#endif
case BUILT_IN_MEMSET: case BUILT_IN_MEMSET:
return fold_builtin_memset (arg0, arg1, arg2, type, ignore); return fold_builtin_memset (arg0, arg1, arg2, type, ignore);
...@@ -13082,7 +13074,6 @@ do_mpfr_sincos (tree arg, tree arg_sinp, tree arg_cosp) ...@@ -13082,7 +13074,6 @@ do_mpfr_sincos (tree arg, tree arg_sinp, tree arg_cosp)
return result; return result;
} }
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
/* If argument ARG1 is an INTEGER_CST and ARG2 is a REAL_CST, call the /* If argument ARG1 is an INTEGER_CST and ARG2 is a REAL_CST, call the
two-argument mpfr order N Bessel function FUNC on them and return two-argument mpfr order N Bessel function FUNC on them and return
the resulting value as a tree with type TYPE. The mpfr precision the resulting value as a tree with type TYPE. The mpfr precision
...@@ -13267,7 +13258,6 @@ do_mpfr_lgamma_r (tree arg, tree arg_sg, tree type) ...@@ -13267,7 +13258,6 @@ do_mpfr_lgamma_r (tree arg, tree arg_sg, tree type)
return result; return result;
} }
#endif
/* FIXME tuples. /* FIXME tuples.
The functions below provide an alternate interface for folding The functions below provide an alternate interface for folding
......
...@@ -309,7 +309,7 @@ library search path, you will have to configure with the ...@@ -309,7 +309,7 @@ library search path, you will have to configure with the
@option{--with-gmp} configure option. See also @option{--with-gmp} configure option. See also
@option{--with-gmp-lib} and @option{--with-gmp-include}. @option{--with-gmp-lib} and @option{--with-gmp-include}.
@item MPFR Library version 2.3.0 (or later) @item MPFR Library version 2.3.2 (or later)
Necessary to build GCC@. It can be downloaded from Necessary to build GCC@. It can be downloaded from
@uref{http://www.mpfr.org/}. The version of MPFR that is bundled with @uref{http://www.mpfr.org/}. The version of MPFR that is bundled with
......
2008-10-13 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* simplify.c: Remove MPFR_VERSION_NUM(2,3,0) conditionals.
2008-10-12 Daniel Kraft <d@domob.eu> 2008-10-12 Daniel Kraft <d@domob.eu>
PR fortran/37688 PR fortran/37688
......
...@@ -668,7 +668,6 @@ gfc_simplify_atan2 (gfc_expr *y, gfc_expr *x) ...@@ -668,7 +668,6 @@ gfc_simplify_atan2 (gfc_expr *y, gfc_expr *x)
gfc_expr * gfc_expr *
gfc_simplify_bessel_j0 (gfc_expr *x ATTRIBUTE_UNUSED) gfc_simplify_bessel_j0 (gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
if (x->expr_type != EXPR_CONSTANT) if (x->expr_type != EXPR_CONSTANT)
...@@ -678,16 +677,12 @@ gfc_simplify_bessel_j0 (gfc_expr *x ATTRIBUTE_UNUSED) ...@@ -678,16 +677,12 @@ gfc_simplify_bessel_j0 (gfc_expr *x ATTRIBUTE_UNUSED)
mpfr_j0 (result->value.real, x->value.real, GFC_RND_MODE); mpfr_j0 (result->value.real, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_J0"); return range_check (result, "BESSEL_J0");
#else
return NULL;
#endif
} }
gfc_expr * gfc_expr *
gfc_simplify_bessel_j1 (gfc_expr *x ATTRIBUTE_UNUSED) gfc_simplify_bessel_j1 (gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
if (x->expr_type != EXPR_CONSTANT) if (x->expr_type != EXPR_CONSTANT)
...@@ -697,9 +692,6 @@ gfc_simplify_bessel_j1 (gfc_expr *x ATTRIBUTE_UNUSED) ...@@ -697,9 +692,6 @@ gfc_simplify_bessel_j1 (gfc_expr *x ATTRIBUTE_UNUSED)
mpfr_j1 (result->value.real, x->value.real, GFC_RND_MODE); mpfr_j1 (result->value.real, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_J1"); return range_check (result, "BESSEL_J1");
#else
return NULL;
#endif
} }
...@@ -707,7 +699,6 @@ gfc_expr * ...@@ -707,7 +699,6 @@ gfc_expr *
gfc_simplify_bessel_jn (gfc_expr *order ATTRIBUTE_UNUSED, gfc_simplify_bessel_jn (gfc_expr *order ATTRIBUTE_UNUSED,
gfc_expr *x ATTRIBUTE_UNUSED) gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
long n; long n;
...@@ -719,16 +710,12 @@ gfc_simplify_bessel_jn (gfc_expr *order ATTRIBUTE_UNUSED, ...@@ -719,16 +710,12 @@ gfc_simplify_bessel_jn (gfc_expr *order ATTRIBUTE_UNUSED,
mpfr_jn (result->value.real, n, x->value.real, GFC_RND_MODE); mpfr_jn (result->value.real, n, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_JN"); return range_check (result, "BESSEL_JN");
#else
return NULL;
#endif
} }
gfc_expr * gfc_expr *
gfc_simplify_bessel_y0 (gfc_expr *x ATTRIBUTE_UNUSED) gfc_simplify_bessel_y0 (gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
if (x->expr_type != EXPR_CONSTANT) if (x->expr_type != EXPR_CONSTANT)
...@@ -738,16 +725,12 @@ gfc_simplify_bessel_y0 (gfc_expr *x ATTRIBUTE_UNUSED) ...@@ -738,16 +725,12 @@ gfc_simplify_bessel_y0 (gfc_expr *x ATTRIBUTE_UNUSED)
mpfr_y0 (result->value.real, x->value.real, GFC_RND_MODE); mpfr_y0 (result->value.real, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_Y0"); return range_check (result, "BESSEL_Y0");
#else
return NULL;
#endif
} }
gfc_expr * gfc_expr *
gfc_simplify_bessel_y1 (gfc_expr *x ATTRIBUTE_UNUSED) gfc_simplify_bessel_y1 (gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
if (x->expr_type != EXPR_CONSTANT) if (x->expr_type != EXPR_CONSTANT)
...@@ -757,9 +740,6 @@ gfc_simplify_bessel_y1 (gfc_expr *x ATTRIBUTE_UNUSED) ...@@ -757,9 +740,6 @@ gfc_simplify_bessel_y1 (gfc_expr *x ATTRIBUTE_UNUSED)
mpfr_y1 (result->value.real, x->value.real, GFC_RND_MODE); mpfr_y1 (result->value.real, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_Y1"); return range_check (result, "BESSEL_Y1");
#else
return NULL;
#endif
} }
...@@ -767,7 +747,6 @@ gfc_expr * ...@@ -767,7 +747,6 @@ gfc_expr *
gfc_simplify_bessel_yn (gfc_expr *order ATTRIBUTE_UNUSED, gfc_simplify_bessel_yn (gfc_expr *order ATTRIBUTE_UNUSED,
gfc_expr *x ATTRIBUTE_UNUSED) gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
long n; long n;
...@@ -779,9 +758,6 @@ gfc_simplify_bessel_yn (gfc_expr *order ATTRIBUTE_UNUSED, ...@@ -779,9 +758,6 @@ gfc_simplify_bessel_yn (gfc_expr *order ATTRIBUTE_UNUSED,
mpfr_yn (result->value.real, n, x->value.real, GFC_RND_MODE); mpfr_yn (result->value.real, n, x->value.real, GFC_RND_MODE);
return range_check (result, "BESSEL_YN"); return range_check (result, "BESSEL_YN");
#else
return NULL;
#endif
} }
...@@ -2483,7 +2459,6 @@ gfc_simplify_len_trim (gfc_expr *e, gfc_expr *kind) ...@@ -2483,7 +2459,6 @@ gfc_simplify_len_trim (gfc_expr *e, gfc_expr *kind)
gfc_expr * gfc_expr *
gfc_simplify_lgamma (gfc_expr *x ATTRIBUTE_UNUSED) gfc_simplify_lgamma (gfc_expr *x ATTRIBUTE_UNUSED)
{ {
#if MPFR_VERSION >= MPFR_VERSION_NUM(2,3,0)
gfc_expr *result; gfc_expr *result;
int sg; int sg;
...@@ -2495,9 +2470,6 @@ gfc_simplify_lgamma (gfc_expr *x ATTRIBUTE_UNUSED) ...@@ -2495,9 +2470,6 @@ gfc_simplify_lgamma (gfc_expr *x ATTRIBUTE_UNUSED)
mpfr_lgamma (result->value.real, &sg, x->value.real, GFC_RND_MODE); mpfr_lgamma (result->value.real, &sg, x->value.real, GFC_RND_MODE);
return range_check (result, "LGAMMA"); return range_check (result, "LGAMMA");
#else
return NULL;
#endif
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment