From 14aa63526a63156b1ae10de42af2730cbd7234d7 Mon Sep 17 00:00:00 2001 From: David Edelsohn Date: Thu, 10 Dec 2009 02:42:40 +0000 Subject: [PATCH] builtins.c (do_mpc_ckconv): Pass the component type to real_from_mpfr(). * builtins.c (do_mpc_ckconv): Pass the component type to real_from_mpfr(). From-SVN: r155122 --- gcc/ChangeLog | 5 +++++ gcc/builtins.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9fff002..e9815ac 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2009-12-09 David Edelsohn + + * builtins.c (do_mpc_ckconv): Pass the component type to + real_from_mpfr(). + 2009-12-09 Xinliang David Li PR tree-optimization/42337 diff --git a/gcc/builtins.c b/gcc/builtins.c index 532a481..75a7e10 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -12726,8 +12726,8 @@ do_mpc_ckconv (mpc_srcptr m, tree type, int inexact, int force_convert) { REAL_VALUE_TYPE re, im; - real_from_mpfr (&re, mpc_realref (m), type, GMP_RNDN); - real_from_mpfr (&im, mpc_imagref (m), type, GMP_RNDN); + real_from_mpfr (&re, mpc_realref (m), TREE_TYPE (type), GMP_RNDN); + real_from_mpfr (&im, mpc_imagref (m), TREE_TYPE (type), GMP_RNDN); /* Proceed iff GCC's REAL_VALUE_TYPE can hold the MPFR values, check for overflow/underflow. If the REAL_VALUE_TYPE is zero but the mpft_t is not, then we underflowed in the -- 2.7.4