Remove remaining uses of CONST_DOUBLE_FROM_REAL_VALUE
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Oct 2015 11:36:08 +0000 (11:36 +0000)
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 5 Oct 2015 11:36:08 +0000 (11:36 +0000)
This patch replaces all uses of CONST_DOUBLE_FROM_REAL_VALUE
with the already-existing const_double_from_real_value.

Bootstrapped & regression-tested on x86_64-linux-gnu.  Also tested by
building one target per CPU directory and checking that there were
no new warnings and no changes in testsuite output at -O2.

gcc/
* real.h (CONST_DOUBLE_ATOF): Use const_double_from_real_value
instead of CONST_DOUBLE_FROM_REAL_VALUE.
(CONST_DOUBLE_FROM_REAL_VALUE): Delete.
* config/c6x/c6x.md (divsf3, divdf3): Use const_double_from_real_value
instead of CONST_DOUBLE_FROM_REAL_VALUE.
* config/epiphany/epiphany.md (fixuns_truncsfsi2): Likewise.
* config/i386/i386.c (standard_80387_constant_rtx): Likewise.
(ix86_expand_builtin, ix86_emit_i387_log1p, ix86_emit_i387_round)
(ix86_emit_swsqrtsf): Likewise.
* config/ia64/ia64.c (ia64_expand_builtin): Likewise.
* config/mips/mips.md (fixuns_truncdfsi2, fixuns_truncdfdi2)
(fixuns_truncsfsi2, fixuns_truncsfdi2): Likewise.
* config/pa/pa.c (pa_expand_builtin): Likewise.
* config/rs6000/rs6000.c (rs6000_load_constant_and_splat): Likewise.
(rs6000_scale_v2df): Likewise.
* config/rs6000/rs6000.md (*cmptf_internal2): Likewise.
* config/s390/s390.md (fixuns_truncdddi2, fixuns_trunctddi2)
(fixuns_trunc<BFP:mode><GPR:mode>2): Likewise.
* config/s390/vx-builtins.md (vec_ctd_s64, vec_ctd_u64, vec_ctsl)
(vec_ctul): Likewise.
* config/sparc/sparc.c (sparc_emit_fixunsdi): Likewise.
* config/spu/spu.c (hwint_to_const_double, spu_float_const): Likewise.
* config/spu/spu.md (floatunsdisf2, floatunstisf2): Likewise.
* cse.c (fold_rtx): Likewise.
* emit-rtl.c (immed_double_const): Likewise (in comments).
(init_emit_once): Likewise.
* expr.c (compress_float_constant, expand_expr_real_1)
(const_vector_from_tree): Likewise.
* optabs.c (expand_float, expand_fix): Likewise.
* reg-stack.c (reg_to_stack): Likewise.
* simplify-rtx.c (avoid_constant_pool_reference): Likewise.
(simplify_const_unary_operation, simplify_binary_operation_1)
(simplify_const_binary_operation, simplify_relational_operation)
(simplify_immed_subreg): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@228477 138bc75d-0d04-0410-961f-82ee72b054a4

21 files changed:
gcc/ChangeLog
gcc/config/c6x/c6x.md
gcc/config/epiphany/epiphany.md
gcc/config/i386/i386.c
gcc/config/ia64/ia64.c
gcc/config/mips/mips.md
gcc/config/pa/pa.c
gcc/config/rs6000/rs6000.c
gcc/config/rs6000/rs6000.md
gcc/config/s390/s390.md
gcc/config/s390/vx-builtins.md
gcc/config/sparc/sparc.c
gcc/config/spu/spu.c
gcc/config/spu/spu.md
gcc/cse.c
gcc/emit-rtl.c
gcc/expr.c
gcc/optabs.c
gcc/real.h
gcc/reg-stack.c
gcc/simplify-rtx.c

index d256700..853c728 100644 (file)
@@ -1,5 +1,42 @@
 2015-10-05  Richard Sandiford  <richard.sandiford@arm.com>
 
+       * real.h (CONST_DOUBLE_ATOF): Use const_double_from_real_value
+       instead of CONST_DOUBLE_FROM_REAL_VALUE.
+       (CONST_DOUBLE_FROM_REAL_VALUE): Delete.
+       * config/c6x/c6x.md (divsf3, divdf3): Use const_double_from_real_value
+       instead of CONST_DOUBLE_FROM_REAL_VALUE.
+       * config/epiphany/epiphany.md (fixuns_truncsfsi2): Likewise.
+       * config/i386/i386.c (standard_80387_constant_rtx): Likewise.
+       (ix86_expand_builtin, ix86_emit_i387_log1p, ix86_emit_i387_round)
+       (ix86_emit_swsqrtsf): Likewise.
+       * config/ia64/ia64.c (ia64_expand_builtin): Likewise.
+       * config/mips/mips.md (fixuns_truncdfsi2, fixuns_truncdfdi2)
+       (fixuns_truncsfsi2, fixuns_truncsfdi2): Likewise.
+       * config/pa/pa.c (pa_expand_builtin): Likewise.
+       * config/rs6000/rs6000.c (rs6000_load_constant_and_splat): Likewise.
+       (rs6000_scale_v2df): Likewise.
+       * config/rs6000/rs6000.md (*cmptf_internal2): Likewise.
+       * config/s390/s390.md (fixuns_truncdddi2, fixuns_trunctddi2)
+       (fixuns_trunc<BFP:mode><GPR:mode>2): Likewise.
+       * config/s390/vx-builtins.md (vec_ctd_s64, vec_ctd_u64, vec_ctsl)
+       (vec_ctul): Likewise.
+       * config/sparc/sparc.c (sparc_emit_fixunsdi): Likewise.
+       * config/spu/spu.c (hwint_to_const_double, spu_float_const): Likewise.
+       * config/spu/spu.md (floatunsdisf2, floatunstisf2): Likewise.
+       * cse.c (fold_rtx): Likewise.
+       * emit-rtl.c (immed_double_const): Likewise (in comments).
+       (init_emit_once): Likewise.
+       * expr.c (compress_float_constant, expand_expr_real_1)
+       (const_vector_from_tree): Likewise.
+       * optabs.c (expand_float, expand_fix): Likewise.
+       * reg-stack.c (reg_to_stack): Likewise.
+       * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
+       (simplify_const_unary_operation, simplify_binary_operation_1)
+       (simplify_const_binary_operation, simplify_relational_operation)
+       (simplify_immed_subreg): Likewise.
+
+2015-10-05  Richard Sandiford  <richard.sandiford@arm.com>
+
        * doc/tm.texi.in (REAL_ARITHMETIC): Delete.
        * doc/tm.texi: Regenerate.
        * real.h (REAL_ARITHMETIC): Delete.
index 075968d..692d83f 100644 (file)
   "TARGET_FP && flag_reciprocal_math"
 {
   operands[3] = force_reg (SFmode,
-                          CONST_DOUBLE_FROM_REAL_VALUE (dconst2, SFmode));
+                          const_double_from_real_value (dconst2, SFmode));
   operands[4] = gen_reg_rtx (SFmode);
   operands[5] = gen_reg_rtx (SFmode);
   operands[6] = gen_reg_rtx (SFmode);
   "TARGET_FP && flag_reciprocal_math"
 {
   operands[3] = force_reg (DFmode,
-                          CONST_DOUBLE_FROM_REAL_VALUE (dconst2, DFmode));
+                          const_double_from_real_value (dconst2, DFmode));
   operands[4] = gen_reg_rtx (DFmode);
   operands[5] = gen_reg_rtx (DFmode);
   operands[6] = gen_reg_rtx (DFmode);
index 4280926..4c8b5d6 100644 (file)
       rtx cmp = gen_rtx_LT (VOIDmode, cc1, CONST0_RTX (SFmode));
 
       real_2expN (&offset, 31, SFmode);
-      limit = CONST_DOUBLE_FROM_REAL_VALUE (offset, SFmode);
+      limit = const_double_from_real_value (offset, SFmode);
       limit = force_reg (SFmode, limit);
       emit_insn (gen_fix_truncsfsi2 (operands[0], operands[1]));
       emit_insn (gen_subsf3_f (tmp, operands[1], limit));
index 44847b4..ff52779 100644 (file)
@@ -10573,7 +10573,7 @@ standard_80387_constant_rtx (int idx)
       gcc_unreachable ();
     }
 
-  return CONST_DOUBLE_FROM_REAL_VALUE (ext_80387_constants_table[i],
+  return const_double_from_real_value (ext_80387_constants_table[i],
                                       XFmode);
 }
 
@@ -40143,7 +40143,7 @@ ix86_expand_builtin (tree exp, rtx target, rtx subtarget,
        rtx tmp;
 
        real_inf (&inf);
-       tmp = CONST_DOUBLE_FROM_REAL_VALUE (inf, mode);
+       tmp = const_double_from_real_value (inf, mode);
 
        tmp = validize_mem (force_const_mem (mode, tmp));
 
@@ -47021,7 +47021,7 @@ void ix86_emit_i387_log1p (rtx op0, rtx op1)
 
   emit_insn (gen_absxf2 (tmp, op1));
   test = gen_rtx_GE (VOIDmode, tmp,
-    CONST_DOUBLE_FROM_REAL_VALUE (
+    const_double_from_real_value (
        REAL_VALUE_ATOF ("0.29289321881345247561810596348408353", XFmode),
        XFmode));
   emit_jump_insn (gen_cbranchxf4 (test, XEXP (test, 0), XEXP (test, 1), label1));
@@ -47095,7 +47095,7 @@ void ix86_emit_i387_round (rtx op0, rtx op1)
   e2 = gen_reg_rtx (inmode);
   res = gen_reg_rtx (outmode);
 
-  half = CONST_DOUBLE_FROM_REAL_VALUE (dconsthalf, inmode);
+  half = const_double_from_real_value (dconsthalf, inmode);
 
   /* round(a) = sgn(a) * floor(fabs(a) + 0.5) */
 
@@ -47227,10 +47227,10 @@ void ix86_emit_swsqrtsf (rtx res, rtx a, machine_mode mode,
   e3 = gen_reg_rtx (mode);
 
   real_from_integer (&r, VOIDmode, -3, SIGNED);
-  mthree = CONST_DOUBLE_FROM_REAL_VALUE (r, SFmode);
+  mthree = const_double_from_real_value (r, SFmode);
 
   real_arithmetic (&r, NEGATE_EXPR, &dconsthalf, NULL);
-  mhalf = CONST_DOUBLE_FROM_REAL_VALUE (r, SFmode);
+  mhalf = const_double_from_real_value (r, SFmode);
   unspec = UNSPEC_RSQRT;
 
   if (VECTOR_MODE_P (mode))
index 779fc58..99c965a 100644 (file)
@@ -10473,7 +10473,7 @@ ia64_expand_builtin (tree exp, rtx target, rtx subtarget ATTRIBUTE_UNUSED,
        rtx tmp;
 
        real_inf (&inf);
-       tmp = CONST_DOUBLE_FROM_REAL_VALUE (inf, target_mode);
+       tmp = const_double_from_real_value (inf, target_mode);
 
        tmp = validize_mem (force_const_mem (target_mode, tmp));
 
index 1d1c42b..3ad41c6 100644 (file)
 
   if (reg1)                    /* Turn off complaints about unreached code.  */
     {
-      mips_emit_move (reg1, CONST_DOUBLE_FROM_REAL_VALUE (offset, DFmode));
+      mips_emit_move (reg1, const_double_from_real_value (offset, DFmode));
       do_pending_stack_adjust ();
 
       test = gen_rtx_GE (VOIDmode, operands[1], reg1);
 
   real_2expN (&offset, 63, DFmode);
 
-  mips_emit_move (reg1, CONST_DOUBLE_FROM_REAL_VALUE (offset, DFmode));
+  mips_emit_move (reg1, const_double_from_real_value (offset, DFmode));
   do_pending_stack_adjust ();
 
   test = gen_rtx_GE (VOIDmode, operands[1], reg1);
 
   real_2expN (&offset, 31, SFmode);
 
-  mips_emit_move (reg1, CONST_DOUBLE_FROM_REAL_VALUE (offset, SFmode));
+  mips_emit_move (reg1, const_double_from_real_value (offset, SFmode));
   do_pending_stack_adjust ();
 
   test = gen_rtx_GE (VOIDmode, operands[1], reg1);
 
   real_2expN (&offset, 63, SFmode);
 
-  mips_emit_move (reg1, CONST_DOUBLE_FROM_REAL_VALUE (offset, SFmode));
+  mips_emit_move (reg1, const_double_from_real_value (offset, SFmode));
   do_pending_stack_adjust ();
 
   test = gen_rtx_GE (VOIDmode, operands[1], reg1);
index 38daa5f..0dc0931 100644 (file)
@@ -652,7 +652,7 @@ pa_expand_builtin (tree exp, rtx target, rtx subtarget ATTRIBUTE_UNUSED,
        rtx tmp;
 
        real_inf (&inf);
-       tmp = CONST_DOUBLE_FROM_REAL_VALUE (inf, target_mode);
+       tmp = const_double_from_real_value (inf, target_mode);
 
        tmp = validize_mem (force_const_mem (target_mode, tmp));
 
index e408295..3b4820b 100644 (file)
@@ -31849,19 +31849,19 @@ rs6000_load_constant_and_splat (machine_mode mode, REAL_VALUE_TYPE dconst)
 
   if (mode == SFmode || mode == DFmode)
     {
-      rtx d = CONST_DOUBLE_FROM_REAL_VALUE (dconst, mode);
+      rtx d = const_double_from_real_value (dconst, mode);
       reg = force_reg (mode, d);
     }
   else if (mode == V4SFmode)
     {
-      rtx d = CONST_DOUBLE_FROM_REAL_VALUE (dconst, SFmode);
+      rtx d = const_double_from_real_value (dconst, SFmode);
       rtvec v = gen_rtvec (4, d, d, d, d);
       reg = gen_reg_rtx (mode);
       rs6000_expand_vector_init (reg, gen_rtx_PARALLEL (mode, v));
     }
   else if (mode == V2DFmode)
     {
-      rtx d = CONST_DOUBLE_FROM_REAL_VALUE (dconst, DFmode);
+      rtx d = const_double_from_real_value (dconst, DFmode);
       rtvec v = gen_rtvec (2, d, d);
       reg = gen_reg_rtx (mode);
       rs6000_expand_vector_init (reg, gen_rtx_PARALLEL (mode, v));
@@ -32699,7 +32699,7 @@ rs6000_scale_v2df (rtx tgt, rtx src, int scale)
   rtx elt;
   rtx scale_vec = gen_reg_rtx (V2DFmode);
   (void)real_powi (&r_pow, DFmode, &dconst2, hwi_scale);
-  elt = CONST_DOUBLE_FROM_REAL_VALUE (r_pow, DFmode);
+  elt = const_double_from_real_value (r_pow, DFmode);
   RTVEC_ELT (v, 0) = elt;
   RTVEC_ELT (v, 1) = elt;
   rs6000_expand_vector_init (scale_vec, gen_rtx_PARALLEL (V2DFmode, v));
index 8c53c40..df9d48e 100644 (file)
   operands[13] = gen_label_rtx ();
   real_inf (&rv);
   operands[14] = force_const_mem (DFmode,
-                                 CONST_DOUBLE_FROM_REAL_VALUE (rv, DFmode));
+                                 const_double_from_real_value (rv, DFmode));
   operands[15] = force_const_mem (DFmode,
-                                 CONST_DOUBLE_FROM_REAL_VALUE (dconst0,
+                                 const_double_from_real_value (dconst0,
                                                                DFmode));
   if (TARGET_TOC)
     {
index 2be7653..1822459 100644 (file)
       emit_insn (gen_extendddtd2 (temp, operands[1]));
       temp = force_reg (TDmode, temp);
       emit_cmp_and_jump_insns (temp,
-           CONST_DOUBLE_FROM_REAL_VALUE (cmp, TDmode),
+           const_double_from_real_value (cmp, TDmode),
            LT, NULL_RTX, VOIDmode, 0, label1);
       emit_insn (gen_subtd3 (temp, temp,
-           CONST_DOUBLE_FROM_REAL_VALUE (sub, TDmode)));
+           const_double_from_real_value (sub, TDmode)));
       emit_insn (gen_fix_trunctddi2_dfp (operands[0], temp, GEN_INT (11)));
       emit_jump (label2);
 
       decimal_real_from_string (&sub, "18446744073709551616.0"); /* 2^64 */
 
       emit_cmp_and_jump_insns (operands[1],
-           CONST_DOUBLE_FROM_REAL_VALUE (cmp, TDmode),
+           const_double_from_real_value (cmp, TDmode),
            LT, NULL_RTX, VOIDmode, 0, label1);
       emit_insn (gen_subtd3 (temp, operands[1],
-           CONST_DOUBLE_FROM_REAL_VALUE (sub, TDmode)));
+           const_double_from_real_value (sub, TDmode)));
       emit_insn (gen_fix_trunctddi2_dfp (operands[0], temp, GEN_INT (11)));
       emit_jump (label2);
 
       real_2expN (&sub, <GPR:bitsize>, <BFP:MODE>mode);
 
       emit_cmp_and_jump_insns (operands[1],
-           CONST_DOUBLE_FROM_REAL_VALUE (cmp, <BFP:MODE>mode),
+           const_double_from_real_value (cmp, <BFP:MODE>mode),
            LT, NULL_RTX, VOIDmode, 0, label1);
       emit_insn (gen_sub<BFP:mode>3 (temp, operands[1],
-           CONST_DOUBLE_FROM_REAL_VALUE (sub, <BFP:MODE>mode)));
+           const_double_from_real_value (sub, <BFP:MODE>mode)));
       emit_insn (gen_fix_trunc<BFP:mode><GPR:mode>2_bfp (operands[0], temp,
            GEN_INT (7)));
       emit_jump (label2);
index 7e20d2b..ff7408a 100644 (file)
   rtx c;
 
   real_2expN (&f, -INTVAL (operands[2]), DFmode);
-  c = CONST_DOUBLE_FROM_REAL_VALUE (f, DFmode);
+  c = const_double_from_real_value (f, DFmode);
 
   operands[3] = gen_rtx_CONST_VECTOR (V2DFmode, gen_rtvec (2, c, c));
   operands[3] = force_reg (V2DFmode, operands[3]);
   rtx c;
 
   real_2expN (&f, -INTVAL (operands[2]), DFmode);
-  c = CONST_DOUBLE_FROM_REAL_VALUE (f, DFmode);
+  c = const_double_from_real_value (f, DFmode);
 
   operands[3] = gen_rtx_CONST_VECTOR (V2DFmode, gen_rtvec (2, c, c));
   operands[3] = force_reg (V2DFmode, operands[3]);
   rtx c;
 
   real_2expN (&f, INTVAL (operands[2]), DFmode);
-  c = CONST_DOUBLE_FROM_REAL_VALUE (f, DFmode);
+  c = const_double_from_real_value (f, DFmode);
 
   operands[3] = gen_rtx_CONST_VECTOR (V2DFmode, gen_rtvec (2, c, c));
   operands[3] = force_reg (V2DFmode, operands[3]);
   rtx c;
 
   real_2expN (&f, INTVAL (operands[2]), DFmode);
-  c = CONST_DOUBLE_FROM_REAL_VALUE (f, DFmode);
+  c = const_double_from_real_value (f, DFmode);
 
   operands[3] = gen_rtx_CONST_VECTOR (V2DFmode, gen_rtvec (2, c, c));
   operands[3] = force_reg (V2DFmode, operands[3]);
index 43f0170..a7fe546 100644 (file)
@@ -8067,7 +8067,7 @@ sparc_emit_fixunsdi (rtx *operands, machine_mode mode)
   f0 = gen_reg_rtx (mode);
 
   emit_move_insn (limit,
-                 CONST_DOUBLE_FROM_REAL_VALUE (
+                 const_double_from_real_value (
                    REAL_VALUE_ATOF ("9223372036854775808.0", mode), mode));
   emit_cmp_and_jump_insns (in, limit, GE, NULL_RTX, mode, 0, neglab);
 
index bdedecc..62faff6 100644 (file)
@@ -1031,7 +1031,7 @@ hwint_to_const_double (machine_mode mode, HOST_WIDE_INT v)
       tv[0] = v >> 32;
     }
   real_from_target (&rv, tv, mode);
-  return CONST_DOUBLE_FROM_REAL_VALUE (rv, mode);
+  return const_double_from_real_value (rv, mode);
 }
 
 void
@@ -3075,7 +3075,7 @@ spu_float_const (const char *string, machine_mode mode)
 {
   REAL_VALUE_TYPE value;
   value = REAL_VALUE_ATOF (string, mode);
-  return CONST_DOUBLE_FROM_REAL_VALUE (value, mode);
+  return const_double_from_real_value (value, mode);
 }
 
 int
index 1416706..761dbc8 100644 (file)
     emit_insn (gen_shlqby_ti (op3_ti, op2_ti, GEN_INT (4)));
 
     emit_move_insn (operands[4],
-                   CONST_DOUBLE_FROM_REAL_VALUE (scale, SFmode));
+                   const_double_from_real_value (scale, SFmode));
     emit_insn (gen_fmasf4 (operands[0],
                           operands[2], operands[4], operands[3]));
     DONE;
     emit_insn (gen_shlqby_ti (op3_ti, op2_ti, GEN_INT (4)));
 
     emit_move_insn (operands[4],
-                   CONST_DOUBLE_FROM_REAL_VALUE (scale, SFmode));
+                   const_double_from_real_value (scale, SFmode));
     emit_insn (gen_fmasf4 (operands[2],
                           operands[2], operands[4], operands[3]));
 
index ef37579..a9cc26a 100644 (file)
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -3342,7 +3342,7 @@ fold_rtx (rtx x, rtx_insn *insn)
          if (SCALAR_FLOAT_MODE_P (mode))
            {
 #ifdef FLOAT_STORE_FLAG_VALUE
-             true_rtx = (CONST_DOUBLE_FROM_REAL_VALUE
+             true_rtx = (const_double_from_real_value
                          (FLOAT_STORE_FLAG_VALUE (mode), mode));
 #else
              true_rtx = NULL_RTX;
index a6ef154..c418c24 100644 (file)
@@ -648,7 +648,7 @@ immed_wide_int_const (const wide_int_ref &v, machine_mode mode)
    implied upper bits are copies of the high bit of i1.  The value
    itself is neither signed nor unsigned.  Do not use this routine for
    non-integer modes; convert to REAL_VALUE_TYPE and use
-   CONST_DOUBLE_FROM_REAL_VALUE.  */
+   const_double_from_real_value.  */
 
 rtx
 immed_double_const (HOST_WIDE_INT i0, HOST_WIDE_INT i1, machine_mode mode)
@@ -5936,13 +5936,13 @@ init_emit_once (void)
           mode != VOIDmode;
           mode = GET_MODE_WIDER_MODE (mode))
        const_tiny_rtx[i][(int) mode] =
-         CONST_DOUBLE_FROM_REAL_VALUE (*r, mode);
+         const_double_from_real_value (*r, mode);
 
       for (mode = GET_CLASS_NARROWEST_MODE (MODE_DECIMAL_FLOAT);
           mode != VOIDmode;
           mode = GET_MODE_WIDER_MODE (mode))
        const_tiny_rtx[i][(int) mode] =
-         CONST_DOUBLE_FROM_REAL_VALUE (*r, mode);
+         const_double_from_real_value (*r, mode);
 
       const_tiny_rtx[i][(int) VOIDmode] = GEN_INT (i);
 
index 0bbfccd..6bb24c0 100644 (file)
@@ -3654,7 +3654,7 @@ compress_float_constant (rtx x, rtx y)
       if (! exact_real_truncate (srcmode, &r))
        continue;
 
-      trunc_y = CONST_DOUBLE_FROM_REAL_VALUE (r, srcmode);
+      trunc_y = const_double_from_real_value (r, srcmode);
 
       if (targetm.legitimate_constant_p (srcmode, trunc_y))
        {
@@ -9708,7 +9708,7 @@ expand_expr_real_1 (tree exp, rtx target, machine_mode tmode,
         many insns, so we'd end up copying it to a register in any case.
 
         Now, we do the copying in expand_binop, if appropriate.  */
-      return CONST_DOUBLE_FROM_REAL_VALUE (TREE_REAL_CST (exp),
+      return const_double_from_real_value (TREE_REAL_CST (exp),
                                           TYPE_MODE (TREE_TYPE (exp)));
 
     case FIXED_CST:
@@ -11339,7 +11339,7 @@ const_vector_from_tree (tree exp)
       elt = VECTOR_CST_ELT (exp, i);
 
       if (TREE_CODE (elt) == REAL_CST)
-       RTVEC_ELT (v, i) = CONST_DOUBLE_FROM_REAL_VALUE (TREE_REAL_CST (elt),
+       RTVEC_ELT (v, i) = const_double_from_real_value (TREE_REAL_CST (elt),
                                                         inner);
       else if (TREE_CODE (elt) == FIXED_CST)
        RTVEC_ELT (v, i) = CONST_FIXED_FROM_FIXED_VALUE (TREE_FIXED_CST (elt),
index c49d66b..223daf7 100644 (file)
@@ -4605,7 +4605,7 @@ expand_float (rtx to, rtx from, int unsignedp)
 
       real_2expN (&offset, GET_MODE_PRECISION (GET_MODE (from)), fmode);
       temp = expand_binop (fmode, add_optab, target,
-                          CONST_DOUBLE_FROM_REAL_VALUE (offset, fmode),
+                          const_double_from_real_value (offset, fmode),
                           target, 0, OPTAB_LIB_WIDEN);
       if (temp != target)
        emit_move_insn (target, temp);
@@ -4748,7 +4748,7 @@ expand_fix (rtx to, rtx from, int unsignedp)
 
          bitsize = GET_MODE_PRECISION (GET_MODE (to));
          real_2expN (&offset, bitsize - 1, fmode);
-         limit = CONST_DOUBLE_FROM_REAL_VALUE (offset, fmode);
+         limit = const_double_from_real_value (offset, fmode);
          lab1 = gen_label_rtx ();
          lab2 = gen_label_rtx ();
 
index 3fff0c5..2e23b89 100644 (file)
@@ -382,7 +382,7 @@ extern REAL_VALUE_TYPE real_from_string2 (const char *, machine_mode);
   real_from_string2 (s, m)
 
 #define CONST_DOUBLE_ATOF(s, m) \
-  CONST_DOUBLE_FROM_REAL_VALUE (real_from_string2 (s, m), m)
+  const_double_from_real_value (real_from_string2 (s, m), m)
 
 #define REAL_VALUE_FIX(r) \
   real_to_integer (&(r))
@@ -431,8 +431,6 @@ REAL_VALUE_TYPE real_value_from_int_cst (const_tree, const_tree);
   ((to) = *CONST_DOUBLE_REAL_VALUE (from))
 
 /* Return a CONST_DOUBLE with value R and mode M.  */
-#define CONST_DOUBLE_FROM_REAL_VALUE(r, m) \
-  const_double_from_real_value (r, m)
 extern rtx const_double_from_real_value (REAL_VALUE_TYPE, machine_mode);
 
 /* Replace R by 1/R in the given machine mode, if the result is exact.  */
index 3944041..3ff8173 100644 (file)
@@ -3241,7 +3241,7 @@ reg_to_stack (void)
       REAL_VALUE_TYPE r;
 
       real_nan (&r, "", 1, SFmode);
-      not_a_num = CONST_DOUBLE_FROM_REAL_VALUE (r, SFmode);
+      not_a_num = const_double_from_real_value (r, SFmode);
       not_a_num = force_const_mem (SFmode, not_a_num);
     }
 
index 96eaae7..84a4bad 100644 (file)
@@ -228,7 +228,7 @@ avoid_constant_pool_reference (rtx x)
          REAL_VALUE_TYPE d;
 
          REAL_VALUE_FROM_CONST_DOUBLE (d, c);
-         return CONST_DOUBLE_FROM_REAL_VALUE (d, GET_MODE (x));
+         return const_double_from_real_value (d, GET_MODE (x));
        }
       return x;
 
@@ -1684,7 +1684,7 @@ simplify_const_unary_operation (enum rtx_code code, machine_mode mode,
 
       real_from_integer (&d, mode, std::make_pair (op, op_mode), SIGNED);
       d = real_value_truncate (mode, d);
-      return CONST_DOUBLE_FROM_REAL_VALUE (d, mode);
+      return const_double_from_real_value (d, mode);
     }
   else if (code == UNSIGNED_FLOAT && CONST_SCALAR_INT_P (op))
     {
@@ -1702,7 +1702,7 @@ simplify_const_unary_operation (enum rtx_code code, machine_mode mode,
 
       real_from_integer (&d, mode, std::make_pair (op, op_mode), UNSIGNED);
       d = real_value_truncate (mode, d);
-      return CONST_DOUBLE_FROM_REAL_VALUE (d, mode);
+      return const_double_from_real_value (d, mode);
     }
 
   if (CONST_SCALAR_INT_P (op) && width > 0)
@@ -1832,7 +1832,7 @@ simplify_const_unary_operation (enum rtx_code code, machine_mode mode,
        default:
          gcc_unreachable ();
        }
-      return CONST_DOUBLE_FROM_REAL_VALUE (d, mode);
+      return const_double_from_real_value (d, mode);
     }
   else if (CONST_DOUBLE_AS_FLOAT_P (op)
           && SCALAR_FLOAT_MODE_P (GET_MODE (op))
@@ -3112,7 +3112,7 @@ simplify_binary_operation_1 (enum rtx_code code, machine_mode mode,
                  && !real_equal (&d, &dconst0))
                {
                  real_arithmetic (&d, RDIV_EXPR, &dconst1, &d);
-                 tem = CONST_DOUBLE_FROM_REAL_VALUE (d, mode);
+                 tem = const_double_from_real_value (d, mode);
                  return simplify_gen_binary (MULT, mode, op0, tem);
                }
            }
@@ -3855,7 +3855,7 @@ simplify_const_binary_operation (enum rtx_code code, machine_mode mode,
              }
            }
           real_from_target (&r, tmp0, mode);
-          return CONST_DOUBLE_FROM_REAL_VALUE (r, mode);
+          return const_double_from_real_value (r, mode);
        }
       else
        {
@@ -3936,7 +3936,7 @@ simplify_const_binary_operation (enum rtx_code code, machine_mode mode,
              && (inexact || !real_identical (&result, &value)))
            return NULL_RTX;
 
-         return CONST_DOUBLE_FROM_REAL_VALUE (result, mode);
+         return const_double_from_real_value (result, mode);
        }
     }
 
@@ -4462,7 +4462,7 @@ simplify_relational_operation (enum rtx_code code, machine_mode mode,
          {
            REAL_VALUE_TYPE val;
            val = FLOAT_STORE_FLAG_VALUE (mode);
-           return CONST_DOUBLE_FROM_REAL_VALUE (val, mode);
+           return const_double_from_real_value (val, mode);
          }
 #else
          return NULL_RTX;
@@ -5760,7 +5760,7 @@ simplify_immed_subreg (machine_mode outermode, rtx op,
              }
 
            real_from_target (&r, tmp, outer_submode);
-           elems[elem] = CONST_DOUBLE_FROM_REAL_VALUE (r, outer_submode);
+           elems[elem] = const_double_from_real_value (r, outer_submode);
          }
          break;