diff options
author | Kaveh R. Ghazi <ghazi@caip.rutgers.edu> | 2009-12-07 15:42:55 +0000 |
---|---|---|
committer | Kaveh Ghazi <ghazi@gcc.gnu.org> | 2009-12-07 15:42:55 +0000 |
commit | 16a19648a2e33854ec971362dbb4a0ca70f19bc4 (patch) | |
tree | c8a3b69415bd3b0d2e00cbba0570ff527b2650c8 /gcc/builtins.c | |
parent | 197eb5a168c47dbb71bd59cd45d71751d4874037 (diff) | |
download | gcc-16a19648a2e33854ec971362dbb4a0ca70f19bc4.zip gcc-16a19648a2e33854ec971362dbb4a0ca70f19bc4.tar.gz gcc-16a19648a2e33854ec971362dbb4a0ca70f19bc4.tar.bz2 |
re PR other/40302 (GCC must hard-require MPC before release)
PR other/40302
* builtins.c: Remove HAVE_mpc* checks throughout.
* fold-const.c: Likewise.
* real.h: Likewise.
* toplev.c: Likewise.
From-SVN: r155046
Diffstat (limited to 'gcc/builtins.c')
-rw-r--r-- | gcc/builtins.c | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/gcc/builtins.c b/gcc/builtins.c index df38f5e..532a481 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -58,9 +58,7 @@ along with GCC; see the file COPYING3. If not see #ifndef PAD_VARARGS_DOWN #define PAD_VARARGS_DOWN BYTES_BIG_ENDIAN #endif -#ifdef HAVE_mpc static tree do_mpc_arg1 (tree, tree, int (*)(mpc_ptr, mpc_srcptr, mpc_rnd_t)); -#endif /* Define the names of the builtin function types and codes. */ const char *const built_in_class_names[4] @@ -7152,20 +7150,17 @@ fold_builtin_cosh (location_t loc, tree arg, tree type, tree fndecl) NULL_TREE if no simplification can be made. */ static tree -fold_builtin_ccos (location_t loc, - tree arg, tree type ATTRIBUTE_UNUSED, tree fndecl, - bool hyper ATTRIBUTE_UNUSED) +fold_builtin_ccos (location_t loc, tree arg, tree type, tree fndecl, + bool hyper) { if (validate_arg (arg, COMPLEX_TYPE) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg))) == REAL_TYPE) { tree tmp; -#ifdef HAVE_mpc /* Calculate the result when the argument is a constant. */ if ((tmp = do_mpc_arg1 (arg, type, (hyper ? mpc_cosh : mpc_cos)))) return tmp; -#endif /* Optimize fn(-x) into fn(x). */ if ((tmp = fold_strip_sign_ops (arg))) @@ -7250,19 +7245,15 @@ fold_builtin_cexp (location_t loc, tree arg0, tree type) { tree rtype; tree realp, imagp, ifn; -#ifdef HAVE_mpc tree res; -#endif if (!validate_arg (arg0, COMPLEX_TYPE) || TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) != REAL_TYPE) return NULL_TREE; -#ifdef HAVE_mpc /* Calculate the result when the argument is a constant. */ if ((res = do_mpc_arg1 (arg0, type, mpc_exp))) return res; -#endif rtype = TREE_TYPE (TREE_TYPE (arg0)); @@ -9700,7 +9691,6 @@ fold_builtin_1 (location_t loc, tree fndecl, tree arg0, bool ignore) CASE_FLT_FN (BUILT_IN_CCOSH): return fold_builtin_ccos(loc, arg0, type, fndecl, /*hyper=*/ true); -#ifdef HAVE_mpc CASE_FLT_FN (BUILT_IN_CSIN): if (validate_arg (arg0, COMPLEX_TYPE) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) == REAL_TYPE) @@ -9737,7 +9727,6 @@ fold_builtin_1 (location_t loc, tree fndecl, tree arg0, bool ignore) return do_mpc_arg1 (arg0, type, mpc_sqrt); break; -#ifdef HAVE_mpc_arc CASE_FLT_FN (BUILT_IN_CASIN): if (validate_arg (arg0, COMPLEX_TYPE) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) == REAL_TYPE) @@ -9773,8 +9762,6 @@ fold_builtin_1 (location_t loc, tree fndecl, tree arg0, bool ignore) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) == REAL_TYPE) return do_mpc_arg1 (arg0, type, mpc_atanh); break; -#endif /* HAVE_mpc_arc */ -#endif /* HAVE_mpc */ CASE_FLT_FN (BUILT_IN_CABS): return fold_builtin_cabs (loc, arg0, type, fndecl); @@ -10092,7 +10079,6 @@ fold_builtin_2 (location_t loc, tree fndecl, tree arg0, tree arg1, bool ignore) CASE_FLT_FN (BUILT_IN_HYPOT): return fold_builtin_hypot (loc, fndecl, arg0, arg1, type); -#ifdef HAVE_mpc_pow CASE_FLT_FN (BUILT_IN_CPOW): if (validate_arg (arg0, COMPLEX_TYPE) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) == REAL_TYPE @@ -10100,7 +10086,6 @@ fold_builtin_2 (location_t loc, tree fndecl, tree arg0, tree arg1, bool ignore) && TREE_CODE (TREE_TYPE (TREE_TYPE (arg1))) == REAL_TYPE) return do_mpc_arg2 (arg0, arg1, type, /*do_nonfinite=*/ 0, mpc_pow); break; -#endif CASE_FLT_FN (BUILT_IN_LDEXP): return fold_builtin_load_exponent (loc, arg0, arg1, type, /*ldexp=*/true); @@ -12720,7 +12705,6 @@ do_mpfr_ckconv (mpfr_srcptr m, tree type, int inexact) return NULL_TREE; } -#ifdef HAVE_mpc /* Helper function for do_mpc_arg*(). Ensure M is a normal complex number and no overflow/underflow occurred. INEXACT is true if M was not exactly calculated. TYPE is the tree type for the result. @@ -12767,7 +12751,6 @@ do_mpc_ckconv (mpc_srcptr m, tree type, int inexact, int force_convert) } return NULL_TREE; } -#endif /* HAVE_mpc */ /* If argument ARG is a REAL_CST, call the one-argument mpfr function FUNC on it and return the resulting value as a tree with type TYPE. @@ -13165,7 +13148,6 @@ do_mpfr_lgamma_r (tree arg, tree arg_sg, tree type) return result; } -#ifdef HAVE_mpc /* If argument ARG is a COMPLEX_CST, call the one-argument mpc function FUNC on it and return the resulting value as a tree with type TYPE. The mpfr precision is set to the precision of TYPE. We @@ -13219,7 +13201,6 @@ do_mpc_arg1 (tree arg, tree type, int (*func)(mpc_ptr, mpc_srcptr, mpc_rnd_t)) DO_NONFINITE is true, then fold expressions containing Inf or NaN in the arguments and/or results. */ -#ifdef HAVE_mpc tree do_mpc_arg2 (tree arg0, tree arg1, tree type, int do_nonfinite, int (*func)(mpc_ptr, mpc_srcptr, mpc_srcptr, mpc_rnd_t)) @@ -13270,8 +13251,6 @@ do_mpc_arg2 (tree arg0, tree arg1, tree type, int do_nonfinite, return result; } -# endif -#endif /* HAVE_mpc */ /* FIXME tuples. The functions below provide an alternate interface for folding |