rtl.h (assign_stack_temp, [...]): Remove 'keep' argument.
authorMichael Matz <matz@suse.de>
Tue, 29 May 2012 14:44:47 +0000 (14:44 +0000)
committerMichael Matz <matz@gcc.gnu.org>
Tue, 29 May 2012 14:44:47 +0000 (14:44 +0000)
* rtl.h (assign_stack_temp, assign_stack_temp_for_type,
assign_temp): Remove 'keep' argument.
(mark_temp_addr_taken): Remove prototype.
* tree.h (expand_decl): Remove prototype.
* function.c (struct temp_slot): Remove addr_taken and keep
member.
(assign_stack_temp_for_type) Don't initialize above, remove
keep argument.
(assign_stack_temp, assign_temp): Remove keep argument.
(mark_temp_addr_taken): Remove.
(preserve_temp_slots): Remove handling of addr_taken and keep
members.
(free_temp_slots): Ditto.
* expr.c (expand_expr_real_1 <COMPOUND_LITERAL_EXPR>): Remove
dead code.
* stmt.c (expand_asm_operands): Remove dead code.
(expand_decl): Remove.
* c-decl.c (finish_struct): Don't call expand_decl.
* builtins.c (expand_builtin_cexpi): Adjust calls to assign_temp
and assign_stack_temp.
* calls.c (save_fixed_argument_area, initialize_argument_information,
expand_call, emit_library_call_value_1, store_one_arg): Ditto.
* expmed.c (extract_bit_field_1): Ditto.
* expr.c (emit_group_load_1, emit_group_store,
copy_blkmode_from_reg, emit_push_insn, expand_assignment,
store_field, expand_constructor, expand_cond_expr_using_cmove,
expand_expr_real_2, expand_expr_real_1): Ditto.
* stmt.c (expand_asm_operands, expand_return): Ditto.

* function.c (pop_temp_slots): Call free_temp_slots.
* calls.c (store_one_arg): Don't call preserve_temp_slots or
free_temp_slots.
* expr.c (expand_assignment): Don't call free_temp_slots.

* config/arm/arm.c (neon_expand_vector_init): Ditto.
* config/i386/i386.c (ix86_expand_vector_set): Ditto.
(ix86_expand_vector_extract): Ditto.
* config/ia64/ia64.c (spill_xfmode_rfmode_operand,
ia64_expand_movxf_movrf): Ditto.
* config/mips/mips.c (mips_expand_vi_general): Ditto.
* config/mmix/mmix.md (floatdisf2, floatunsdisf2, truncdfsf2,
extendsfdf2): Ditto.
* config/rs6000/rs6000.c (rs6000_expand_vector_init,
rs6000_expand_vector_set, rs6000_expand_vector_extract,
rs6000_allocate_stack_temp): Ditto.
* config/rs6000/rs6000.md (fix_trunctfsi2_fprs): Ditto.
* config/sparc/sparc.c (emit_soft_tfmode_libcall,
sparc_emit_float_lib_cmp, sparc_emit_float_lib_cmp,
sparc_expand_vector_init): Ditto.

From-SVN: r187965

19 files changed:
gcc/ChangeLog
gcc/builtins.c
gcc/c-decl.c
gcc/calls.c
gcc/config/arm/arm.c
gcc/config/i386/i386.c
gcc/config/ia64/ia64.c
gcc/config/mips/mips.c
gcc/config/mmix/mmix.md
gcc/config/rs6000/rs6000.c
gcc/config/rs6000/rs6000.md
gcc/config/s390/s390.c
gcc/config/sparc/sparc.c
gcc/expmed.c
gcc/expr.c
gcc/function.c
gcc/rtl.h
gcc/stmt.c
gcc/tree.h

index 5d2b2e48e68b6b4cbb0c233f2cc653d41c9f0fc0..b883dca1d019c7e7d2ad5aca19c139068b6726f6 100644 (file)
@@ -1,3 +1,55 @@
+2012-05-29  Michael Matz  <matz@suse.de>
+
+       * rtl.h (assign_stack_temp, assign_stack_temp_for_type,
+       assign_temp): Remove 'keep' argument.
+       (mark_temp_addr_taken): Remove prototype.
+       * tree.h (expand_decl): Remove prototype.
+       * function.c (struct temp_slot): Remove addr_taken and keep
+       member.
+       (assign_stack_temp_for_type) Don't initialize above, remove
+       keep argument.
+       (assign_stack_temp, assign_temp): Remove keep argument.
+       (mark_temp_addr_taken): Remove.
+       (preserve_temp_slots): Remove handling of addr_taken and keep
+       members.
+       (free_temp_slots): Ditto.
+       * expr.c (expand_expr_real_1 <COMPOUND_LITERAL_EXPR>): Remove
+       dead code.
+       * stmt.c (expand_asm_operands): Remove dead code.
+       (expand_decl): Remove.
+       * c-decl.c (finish_struct): Don't call expand_decl.
+       * builtins.c (expand_builtin_cexpi): Adjust calls to assign_temp
+       and assign_stack_temp.
+       * calls.c (save_fixed_argument_area, initialize_argument_information,
+       expand_call, emit_library_call_value_1, store_one_arg): Ditto.
+       * expmed.c (extract_bit_field_1): Ditto.
+       * expr.c (emit_group_load_1, emit_group_store,
+       copy_blkmode_from_reg, emit_push_insn, expand_assignment,
+       store_field, expand_constructor, expand_cond_expr_using_cmove,
+       expand_expr_real_2, expand_expr_real_1): Ditto.
+       * stmt.c (expand_asm_operands, expand_return): Ditto.
+
+       * function.c (pop_temp_slots): Call free_temp_slots.
+       * calls.c (store_one_arg): Don't call preserve_temp_slots or
+       free_temp_slots.
+       * expr.c (expand_assignment): Don't call free_temp_slots.
+
+       * config/arm/arm.c (neon_expand_vector_init): Ditto.
+       * config/i386/i386.c (ix86_expand_vector_set): Ditto.
+       (ix86_expand_vector_extract): Ditto.
+       * config/ia64/ia64.c (spill_xfmode_rfmode_operand,
+       ia64_expand_movxf_movrf): Ditto.
+       * config/mips/mips.c (mips_expand_vi_general): Ditto.
+       * config/mmix/mmix.md (floatdisf2, floatunsdisf2, truncdfsf2,
+       extendsfdf2): Ditto.
+       * config/rs6000/rs6000.c (rs6000_expand_vector_init,
+       rs6000_expand_vector_set, rs6000_expand_vector_extract,
+       rs6000_allocate_stack_temp): Ditto.
+       * config/rs6000/rs6000.md (fix_trunctfsi2_fprs): Ditto.
+       * config/sparc/sparc.c (emit_soft_tfmode_libcall,
+       sparc_emit_float_lib_cmp, sparc_emit_float_lib_cmp,
+       sparc_expand_vector_init): Ditto.
+
 2012-05-29  Michael Matz  <matz@suse.de>
 
        * c-tree.h (c_expand_decl): Remove prototype.
index 8b20e439cc0457e2d1eaaec0b8a9e95b91e3c964..b885f5f657b085d9fb3fcfaabe5335e9f1abe89e 100644 (file)
@@ -2650,8 +2650,8 @@ expand_builtin_cexpi (tree exp, rtx target)
       else
        gcc_unreachable ();
 
-      op1 = assign_temp (TREE_TYPE (arg), 0, 1, 1);
-      op2 = assign_temp (TREE_TYPE (arg), 0, 1, 1);
+      op1 = assign_temp (TREE_TYPE (arg), 1, 1);
+      op2 = assign_temp (TREE_TYPE (arg), 1, 1);
       op1a = copy_addr_to_reg (XEXP (op1, 0));
       op2a = copy_addr_to_reg (XEXP (op2, 0));
       top1 = make_tree (build_pointer_type (TREE_TYPE (arg)), op1a);
index 41688a7220d061e3a6f0ed2c547e8e7dce09a1c5..29cd18c7dcd414a9d2d62d093392b98e794e7d5d 100644 (file)
@@ -7317,8 +7317,6 @@ finish_struct (location_t loc, tree t, tree fieldlist, tree attributes,
          if (c_dialect_objc ())
            objc_check_decl (decl);
          rest_of_decl_compilation (decl, toplevel, 0);
-         if (!toplevel)
-           expand_decl (decl);
        }
     }
   C_TYPE_INCOMPLETE_VARS (TYPE_MAIN_VARIANT (t)) = 0;
index ea9e5cf71a8dba8c0fe99fc0291446d9e86b0b84..d4bcd7b67d4fd3a950439d840cff2651c86180f1 100644 (file)
@@ -933,7 +933,7 @@ save_fixed_argument_area (int reg_parm_stack_space, rtx argblock, int *low_to_sa
        set_mem_align (stack_area, PARM_BOUNDARY);
        if (save_mode == BLKmode)
          {
-           save_area = assign_stack_temp (BLKmode, num_to_save, 0);
+           save_area = assign_stack_temp (BLKmode, num_to_save);
            emit_block_move (validize_mem (save_area), stack_area,
                             GEN_INT (num_to_save), BLOCK_OP_CALL_PARM);
          }
@@ -1258,7 +1258,7 @@ initialize_argument_information (int num_actuals ATTRIBUTE_UNUSED,
                  set_mem_attributes (copy, type, 1);
                }
              else
-               copy = assign_temp (type, 0, 1, 0);
+               copy = assign_temp (type, 1, 0);
 
              store_expr (args[i].tree_value, copy, 0, false);
 
@@ -2404,7 +2404,7 @@ expand_call (tree exp, rtx target, int ignore)
            /* For variable-sized objects, we must be called with a target
               specified.  If we were to allocate space on the stack here,
               we would have no way of knowing when to free it.  */
-           rtx d = assign_temp (rettype, 0, 1, 1);
+           rtx d = assign_temp (rettype, 1, 1);
            structure_value_addr = XEXP (d, 0);
            target = 0;
          }
@@ -3278,7 +3278,7 @@ expand_call (tree exp, rtx target, int ignore)
                                              (TYPE_QUALS (rettype)
                                               | TYPE_QUAL_CONST));
 
-             target = assign_temp (nt, 0, 1, 1);
+             target = assign_temp (nt, 1, 1);
            }
 
          if (! rtx_equal_p (target, valreg))
@@ -3694,7 +3694,7 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value,
          if (value != 0 && MEM_P (value))
            mem_value = value;
          else
-           mem_value = assign_temp (tfom, 0, 1, 1);
+           mem_value = assign_temp (tfom, 1, 1);
 #endif
          /* This call returns a big structure.  */
          flags &= ~(ECF_CONST | ECF_PURE | ECF_LOOPING_CONST_OR_PURE);
@@ -3809,7 +3809,7 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value,
          else
            {
              slot = assign_temp (lang_hooks.types.type_for_mode (mode, 0),
-                                 0, 1, 1);
+                                 1, 1);
              emit_move_insn (slot, val);
            }
 
@@ -4033,8 +4033,8 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value,
                    {
                      argvec[argnum].save_area
                        = assign_stack_temp (BLKmode,
-                                            argvec[argnum].locate.size.constant,
-                                            0);
+                                            argvec[argnum].locate.size.constant
+                                            );
 
                      emit_block_move (validize_mem (argvec[argnum].save_area),
                                       stack_area,
@@ -4444,7 +4444,7 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags,
                  tree nt = build_qualified_type (ot, (TYPE_QUALS (ot)
                                                       | TYPE_QUAL_CONST));
 
-                 arg->save_area = assign_temp (nt, 0, 1, 1);
+                 arg->save_area = assign_temp (nt, 1, 1);
                  preserve_temp_slots (arg->save_area);
                  emit_block_move (validize_mem (arg->save_area), stack_area,
                                   GEN_INT (arg->locate.size.constant),
@@ -4721,11 +4721,7 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags,
      be deferred during the rest of the arguments.  */
   NO_DEFER_POP;
 
-  /* Free any temporary slots made in processing this argument.  Show
-     that we might have taken the address of something and pushed that
-     as an operand.  */
-  preserve_temp_slots (NULL_RTX);
-  free_temp_slots ();
+  /* Free any temporary slots made in processing this argument.  */
   pop_temp_slots ();
 
   return sibcall_failure;
index e2eebda958ee0ab354688ab6c12eabbfbd4cfdfb..cb7eed5ae58b2fb0db32feaf98b732a1b020e038 100644 (file)
@@ -9459,7 +9459,7 @@ neon_expand_vector_init (rtx target, rtx vals)
 
   /* Construct the vector in memory one field at a time
      and load the whole vector.  */
-  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), 0);
+  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
   for (i = 0; i < n_elts; i++)
     emit_move_insn (adjust_address_nv (mem, inner_mode,
                                    i * GET_MODE_SIZE (inner_mode)),
index 30dbb0899715460f23f9dbdf9ff90dc473282e01..c6eb9628b3fca324d898e7bc666f68297dbd4d71 100644 (file)
@@ -34410,7 +34410,7 @@ half:
     }
   else
     {
-      rtx mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), false);
+      rtx mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
 
       emit_move_insn (mem, target);
 
@@ -34627,7 +34627,7 @@ ix86_expand_vector_extract (bool mmx_ok, rtx target, rtx vec, int elt)
     }
   else
     {
-      rtx mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), false);
+      rtx mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
 
       emit_move_insn (mem, vec);
 
index 9a8bc0789c6e4011db969e5770df87adb9c18259..e49ee2c74da1f201d3e9ccf94e0a90dd3da5e058 100644 (file)
@@ -1585,13 +1585,13 @@ spill_xfmode_rfmode_operand (rtx in, int force, enum machine_mode mode)
       && GET_MODE (SUBREG_REG (in)) == TImode
       && GET_CODE (SUBREG_REG (in)) == REG)
     {
-      rtx memt = assign_stack_temp (TImode, 16, 0);
+      rtx memt = assign_stack_temp (TImode, 16);
       emit_move_insn (memt, SUBREG_REG (in));
       return adjust_address (memt, mode, 0);
     }
   else if (force && GET_CODE (in) == REG)
     {
-      rtx memx = assign_stack_temp (mode, 16, 0);
+      rtx memx = assign_stack_temp (mode, 16);
       emit_move_insn (memx, in);
       return memx;
     }
@@ -1716,7 +1716,7 @@ ia64_expand_movxf_movrf (enum machine_mode mode, rtx operands[])
            memt = adjust_address (in, TImode, 0);
          else
            {
-             memt = assign_stack_temp (TImode, 16, 0);
+             memt = assign_stack_temp (TImode, 16);
              memx = adjust_address (memt, mode, 0);
              emit_move_insn (memx, in);
            }
index 2e6c3001178d72ac22105dd4e377ebf8fedcc138..416c1aa41bb5fddc207c20a8493ca2ba9d641aa8 100644 (file)
@@ -17201,7 +17201,7 @@ static void
 mips_expand_vi_general (enum machine_mode vmode, enum machine_mode imode,
                        unsigned nelt, unsigned nvar, rtx target, rtx vals)
 {
-  rtx mem = assign_stack_temp (vmode, GET_MODE_SIZE (vmode), 0);
+  rtx mem = assign_stack_temp (vmode, GET_MODE_SIZE (vmode));
   unsigned int i, isize = GET_MODE_SIZE (imode);
 
   if (nvar < nelt)
index dbd4c0f778d9d6f2b4a157f07ccad5ee78891489..1cd397a8a1458d9734b0c67957223ca77d96f68c 100644 (file)
@@ -529,7 +529,7 @@ DIVU %1,%1,%2\;GET %0,:rR\;NEGU %2,0,%0\;CSNN %0,$255,%2")
         better way.  */
       stack_slot
        = validize_mem (assign_stack_temp (SFmode,
-                                          GET_MODE_SIZE (SFmode), 0));
+                                          GET_MODE_SIZE (SFmode)));
       emit_insn (gen_floatdisf2 (stack_slot, operands[1]));
       emit_move_insn (operands[0], stack_slot);
       DONE;
@@ -563,7 +563,7 @@ DIVU %1,%1,%2\;GET %0,:rR\;NEGU %2,0,%0\;CSNN %0,$255,%2")
         way.  */
       stack_slot
        = validize_mem (assign_stack_temp (SFmode,
-                                          GET_MODE_SIZE (SFmode), 0));
+                                          GET_MODE_SIZE (SFmode)));
       emit_insn (gen_floatunsdisf2 (stack_slot, operands[1]));
       emit_move_insn (operands[0], stack_slot);
       DONE;
@@ -645,7 +645,7 @@ DIVU %1,%1,%2\;GET %0,:rR\;NEGU %2,0,%0\;CSNN %0,$255,%2")
         way.  */
       stack_slot
        = validize_mem (assign_stack_temp (SFmode,
-                                          GET_MODE_SIZE (SFmode), 0));
+                                          GET_MODE_SIZE (SFmode)));
       emit_insn (gen_truncdfsf2 (stack_slot, operands[1]));
       emit_move_insn (operands[0], stack_slot);
       DONE;
@@ -678,7 +678,7 @@ DIVU %1,%1,%2\;GET %0,:rR\;NEGU %2,0,%0\;CSNN %0,$255,%2")
         better way.  */
       stack_slot
        = validize_mem (assign_stack_temp (SFmode,
-                                          GET_MODE_SIZE (SFmode), 0));
+                                          GET_MODE_SIZE (SFmode)));
       emit_move_insn (stack_slot, operands[1]);
       emit_insn (gen_extendsfdf2 (operands[0], stack_slot));
       DONE;
index 3d895390bcca98ef9b4fcfe10e141f5770e55903..a11aefd14fc19c16346b3d8b78da4002fb97653b 100644 (file)
@@ -4576,7 +4576,7 @@ rs6000_expand_vector_init (rtx target, rtx vals)
      of 64-bit items is not supported on Altivec.  */
   if (all_same && GET_MODE_SIZE (inner_mode) <= 4)
     {
-      mem = assign_stack_temp (mode, GET_MODE_SIZE (inner_mode), 0);
+      mem = assign_stack_temp (mode, GET_MODE_SIZE (inner_mode));
       emit_move_insn (adjust_address_nv (mem, inner_mode, 0),
                      XVECEXP (vals, 0, 0));
       x = gen_rtx_UNSPEC (VOIDmode,
@@ -4612,7 +4612,7 @@ rs6000_expand_vector_init (rtx target, rtx vals)
 
   /* Construct the vector in memory one field at a time
      and load the whole vector.  */
-  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), 0);
+  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
   for (i = 0; i < n_elts; i++)
     emit_move_insn (adjust_address_nv (mem, inner_mode,
                                    i * GET_MODE_SIZE (inner_mode)),
@@ -4641,7 +4641,7 @@ rs6000_expand_vector_set (rtx target, rtx val, int elt)
     }
 
   /* Load single variable value.  */
-  mem = assign_stack_temp (mode, GET_MODE_SIZE (inner_mode), 0);
+  mem = assign_stack_temp (mode, GET_MODE_SIZE (inner_mode));
   emit_move_insn (adjust_address_nv (mem, inner_mode, 0), val);
   x = gen_rtx_UNSPEC (VOIDmode,
                      gen_rtvec (1, const0_rtx), UNSPEC_LVE);
@@ -4696,7 +4696,7 @@ rs6000_expand_vector_extract (rtx target, rtx vec, int elt)
     }
 
   /* Allocate mode-sized buffer.  */
-  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), 0);
+  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
 
   emit_move_insn (mem, vec);
 
@@ -27812,7 +27812,7 @@ rs6000_allocate_stack_temp (enum machine_mode mode,
                            bool offsettable_p,
                            bool reg_reg_p)
 {
-  rtx stack = assign_stack_temp (mode, GET_MODE_SIZE (mode), 0);
+  rtx stack = assign_stack_temp (mode, GET_MODE_SIZE (mode));
   rtx addr = XEXP (stack, 0);
   int strict_p = (reload_in_progress || reload_completed);
 
index 26b2720cac84aae207390703c6493e4ec645caaf..ba4acb69de789afe58f1417095376767eb2d7acc 100644 (file)
   operands[2] = gen_reg_rtx (DFmode);
   operands[3] = gen_reg_rtx (DFmode);
   operands[4] = gen_reg_rtx (DImode);
-  operands[5] = assign_stack_temp (DImode, GET_MODE_SIZE (DImode), 0);
+  operands[5] = assign_stack_temp (DImode, GET_MODE_SIZE (DImode));
 })
 
 (define_insn_and_split "*fix_trunctfsi2_internal"
index 934e68b53a34bda4b9eedcaa22e7716fbb70074a..ede3a5574fe14233eb7f7ebc075c98dda88de084 100644 (file)
@@ -9044,6 +9044,7 @@ s390_gimplify_va_arg (tree valist, tree type, gimple_seq *pre_p,
   lab_false = create_artificial_label (UNKNOWN_LOCATION);
   lab_over = create_artificial_label (UNKNOWN_LOCATION);
   addr = create_tmp_var (ptr_type_node, "addr");
+  mark_sym_for_renaming (addr);
 
   t = fold_convert (TREE_TYPE (reg), size_int (max_reg));
   t = build2 (GT_EXPR, boolean_type_node, reg, t);
index 4cb381e60e9776d99f748eaa75e1ef3f1e4fd560..54fce8f6ddb20cb272769c7ccb3c57628b47f939 100644 (file)
@@ -2738,7 +2738,7 @@ emit_soft_tfmode_libcall (const char *func_name, int nargs, rtx *operands)
            }
          else
            {
-             this_slot = assign_stack_temp (TFmode, GET_MODE_SIZE (TFmode), 0);
+             this_slot = assign_stack_temp (TFmode, GET_MODE_SIZE (TFmode));
 
              /* Operand 0 is the return value.  We'll copy it out later.  */
              if (i > 0)
@@ -7431,7 +7431,7 @@ sparc_emit_float_lib_cmp (rtx x, rtx y, enum rtx_code comparison)
        }
       else
        {
-         slot0 = assign_stack_temp (TFmode, GET_MODE_SIZE(TFmode), 0);
+         slot0 = assign_stack_temp (TFmode, GET_MODE_SIZE(TFmode));
          emit_move_insn (slot0, x);
        }
 
@@ -7444,7 +7444,7 @@ sparc_emit_float_lib_cmp (rtx x, rtx y, enum rtx_code comparison)
        }
       else
        {
-         slot1 = assign_stack_temp (TFmode, GET_MODE_SIZE(TFmode), 0);
+         slot1 = assign_stack_temp (TFmode, GET_MODE_SIZE(TFmode));
          emit_move_insn (slot1, y);
        }
 
@@ -11631,7 +11631,7 @@ sparc_expand_vector_init (rtx target, rtx vals)
        }
     }
 
-  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode), 0);
+  mem = assign_stack_temp (mode, GET_MODE_SIZE (mode));
   for (i = 0; i < n_elts; i++)
     emit_move_insn (adjust_address_nv (mem, inner_mode,
                                       i * GET_MODE_SIZE (inner_mode)),
index 45b150efc3e56639effb721299981b9dcc4c4b26..a64138738975b9158fced670ee68fd8361ef9b3d 100644 (file)
@@ -1351,7 +1351,7 @@ extract_bit_field_1 (rtx str_rtx, unsigned HOST_WIDE_INT bitsize,
        else
          {
            rtx mem = assign_stack_temp (GET_MODE (op0),
-                                        GET_MODE_SIZE (GET_MODE (op0)), 0);
+                                        GET_MODE_SIZE (GET_MODE (op0)));
            emit_move_insn (mem, op0);
            op0 = adjust_address (mem, BLKmode, 0);
          }
index fd995d173edbd5619dc334134f7701a1cb384cae..8d815c94836416c8ea8c493cadf4912064506dc2 100644 (file)
@@ -1615,7 +1615,7 @@ emit_group_load_1 (rtx *tmps, rtx dst, rtx orig_src, tree type, int ssize)
     {
       enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_src));
       if (imode == BLKmode)
-       src = assign_stack_temp (GET_MODE (orig_src), ssize, 0);
+       src = assign_stack_temp (GET_MODE (orig_src), ssize);
       else
        src = gen_reg_rtx (imode);
       if (imode != BLKmode)
@@ -1717,7 +1717,7 @@ emit_group_load_1 (rtx *tmps, rtx dst, rtx orig_src, tree type, int ssize)
              rtx mem;
 
              gcc_assert (!bytepos);
-             mem = assign_stack_temp (GET_MODE (src), slen, 0);
+             mem = assign_stack_temp (GET_MODE (src), slen);
              emit_move_insn (mem, src);
              tmps[i] = extract_bit_field (mem, bytelen * BITS_PER_UNIT,
                                           0, 1, false, NULL_RTX, mode, mode);
@@ -1732,7 +1732,7 @@ emit_group_load_1 (rtx *tmps, rtx dst, rtx orig_src, tree type, int ssize)
          int slen = GET_MODE_SIZE (GET_MODE (src));
          rtx mem;
 
-         mem = assign_stack_temp (GET_MODE (src), slen, 0);
+         mem = assign_stack_temp (GET_MODE (src), slen);
          emit_move_insn (mem, src);
          tmps[i] = adjust_address (mem, mode, (int) bytepos);
        }
@@ -1883,7 +1883,7 @@ emit_group_store (rtx orig_dst, rtx src, tree type ATTRIBUTE_UNUSED, int ssize)
     {
       enum machine_mode imode = int_mode_for_mode (GET_MODE (orig_dst));
       if (imode == BLKmode)
-        dst = assign_stack_temp (GET_MODE (orig_dst), ssize, 0);
+        dst = assign_stack_temp (GET_MODE (orig_dst), ssize);
       else
         dst = gen_reg_rtx (imode);
       emit_group_store (dst, src, type, ssize);
@@ -1933,7 +1933,7 @@ emit_group_store (rtx orig_dst, rtx src, tree type ATTRIBUTE_UNUSED, int ssize)
         it.  Allocate a temporary, and split this into a store/load to/from
         the temporary.  */
 
-      temp = assign_stack_temp (GET_MODE (dst), ssize, 0);
+      temp = assign_stack_temp (GET_MODE (dst), ssize);
       emit_group_store (temp, src, type, ssize);
       emit_group_load (dst, temp, type, ssize);
       return;
@@ -2028,8 +2028,7 @@ emit_group_store (rtx orig_dst, rtx src, tree type ATTRIBUTE_UNUSED, int ssize)
                  >= GET_MODE_ALIGNMENT (tmp_mode))
                {
                  dest = assign_stack_temp (dest_mode,
-                                           GET_MODE_SIZE (dest_mode),
-                                           0);
+                                           GET_MODE_SIZE (dest_mode));
                  emit_move_insn (adjust_address (dest,
                                                  tmp_mode,
                                                  bytepos),
@@ -2039,8 +2038,7 @@ emit_group_store (rtx orig_dst, rtx src, tree type ATTRIBUTE_UNUSED, int ssize)
              else
                {
                  dest = assign_stack_temp (tmp_mode,
-                                           GET_MODE_SIZE (tmp_mode),
-                                           0);
+                                           GET_MODE_SIZE (tmp_mode));
                  emit_move_insn (dest, tmps[i]);
                  dst = adjust_address (dest, dest_mode, bytepos);
                }
@@ -2108,7 +2106,7 @@ copy_blkmode_from_reg (rtx tgtblk, rtx srcreg, tree type)
       tgtblk = assign_temp (build_qualified_type (type,
                                                  (TYPE_QUALS (type)
                                                   | TYPE_QUAL_CONST)),
-                           0, 1, 1);
+                           1, 1);
       preserve_temp_slots (tgtblk);
     }
 
@@ -4030,7 +4028,7 @@ emit_push_insn (rtx x, enum machine_mode mode, tree type, rtx size,
          size = GEN_INT (GET_MODE_SIZE (mode));
          if (!MEM_P (xinner))
            {
-             temp = assign_temp (type, 0, 1, 1);
+             temp = assign_temp (type, 1, 1);
              emit_move_insn (temp, xinner);
              xinner = temp;
            }
@@ -4782,8 +4780,7 @@ expand_assignment (tree to, tree from, bool nontemporal)
          else
            {
              rtx temp = assign_stack_temp (GET_MODE (to_rtx),
-                                           GET_MODE_SIZE (GET_MODE (to_rtx)),
-                                           0);
+                                           GET_MODE_SIZE (GET_MODE (to_rtx)));
              write_complex_part (temp, XEXP (to_rtx, 0), false);
              write_complex_part (temp, XEXP (to_rtx, 1), true);
              result = store_field (temp, bitsize, bitpos,
@@ -4839,7 +4836,6 @@ expand_assignment (tree to, tree from, bool nontemporal)
 
       if (result)
        preserve_temp_slots (result);
-      free_temp_slots ();
       pop_temp_slots ();
       return;
     }
@@ -4887,7 +4883,6 @@ expand_assignment (tree to, tree from, bool nontemporal)
          emit_move_insn (to_rtx, value);
        }
       preserve_temp_slots (to_rtx);
-      free_temp_slots ();
       pop_temp_slots ();
       return;
     }
@@ -4914,7 +4909,6 @@ expand_assignment (tree to, tree from, bool nontemporal)
        emit_move_insn (to_rtx, temp);
 
       preserve_temp_slots (to_rtx);
-      free_temp_slots ();
       pop_temp_slots ();
       return;
     }
@@ -4944,7 +4938,6 @@ expand_assignment (tree to, tree from, bool nontemporal)
                         TYPE_MODE (sizetype));
 
       preserve_temp_slots (to_rtx);
-      free_temp_slots ();
       pop_temp_slots ();
       return;
     }
@@ -4954,7 +4947,6 @@ expand_assignment (tree to, tree from, bool nontemporal)
   push_temp_slots ();
   result = store_expr (from, to_rtx, 0, nontemporal);
   preserve_temp_slots (result);
-  free_temp_slots ();
   pop_temp_slots ();
   return;
 }
@@ -6314,7 +6306,7 @@ store_field (rtx target, HOST_WIDE_INT bitsize, HOST_WIDE_INT bitpos,
   if (mode == BLKmode
       && (REG_P (target) || GET_CODE (target) == SUBREG))
     {
-      rtx object = assign_temp (type, 0, 1, 1);
+      rtx object = assign_temp (type, 1, 1);
       rtx blk_object = adjust_address (object, BLKmode, 0);
 
       if (bitsize != (HOST_WIDE_INT) GET_MODE_BITSIZE (GET_MODE (target)))
@@ -7768,7 +7760,7 @@ expand_constructor (tree exp, rtx target, enum expand_modifier modifier,
        = assign_temp (build_qualified_type (type, (TYPE_QUALS (type)
                                                    | (TREE_READONLY (exp)
                                                       * TYPE_QUAL_CONST))),
-                      0, TREE_ADDRESSABLE (exp), 1);
+                      TREE_ADDRESSABLE (exp), 1);
     }
 
   store_constructor (exp, target, 0, int_expr_size (exp));
@@ -7892,7 +7884,7 @@ expand_cond_expr_using_cmove (tree treeop0 ATTRIBUTE_UNUSED,
   int unsignedp = TYPE_UNSIGNED (type);
   enum machine_mode mode = TYPE_MODE (type);
 
-  temp = assign_temp (type, 0, 0, 1);
+  temp = assign_temp (type, 0, 1);
 
   /* If we cannot do a conditional move on the mode, try doing it
      with the promoted mode. */
@@ -8050,7 +8042,7 @@ expand_expr_real_2 (sepops ops, rtx target, enum machine_mode tmode,
              if (TYPE_MODE (type) != BLKmode)
                target = gen_reg_rtx (TYPE_MODE (type));
              else
-               target = assign_temp (type, 0, 1, 1);
+               target = assign_temp (type, 1, 1);
            }
 
          if (MEM_P (target))
@@ -9037,7 +9029,7 @@ expand_expr_real_2 (sepops ops, rtx target, enum machine_mode tmode,
          && !MEM_P (original_target))
        temp = original_target;
       else
-       temp = assign_temp (type, 0, 0, 1);
+       temp = assign_temp (type, 0, 1);
 
       do_pending_stack_adjust ();
       NO_DEFER_POP;
@@ -9288,7 +9280,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
 
       /* This is the case of an array whose size is to be determined
         from its initializer, while the initializer is still being parsed.
-        See expand_decl.  */
+        ??? We aren't parsing while expanding anymore.  */
 
       if (MEM_P (decl_rtl) && REG_P (XEXP (decl_rtl, 0)))
        temp = validize_mem (decl_rtl);
@@ -9563,8 +9555,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
            else
              {
                temp = assign_stack_temp (DECL_MODE (base),
-                                         GET_MODE_SIZE (DECL_MODE (base)),
-                                         0);
+                                         GET_MODE_SIZE (DECL_MODE (base)));
                store_expr (base, temp, 0, false);
                temp = adjust_address (temp, BLKmode, offset);
                set_mem_size (temp, int_size_in_bytes (TREE_TYPE (exp)));
@@ -9922,7 +9913,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
            tree nt = build_qualified_type (TREE_TYPE (tem),
                                            (TYPE_QUALS (TREE_TYPE (tem))
                                             | TYPE_QUAL_CONST));
-           memloc = assign_temp (nt, 0, 1, 1);
+           memloc = assign_temp (nt, 1, 1);
            emit_move_insn (memloc, op0);
            op0 = memloc;
            mem_attrs_from_type = true;
@@ -10029,7 +10020,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
            if (ext_mode == BLKmode)
              {
                if (target == 0)
-                 target = assign_temp (type, 0, 1, 1);
+                 target = assign_temp (type, 1, 1);
 
                if (bitsize == 0)
                  return target;
@@ -10085,7 +10076,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
 
                new_rtx = assign_stack_temp_for_type (ext_mode,
                                                   GET_MODE_BITSIZE (ext_mode),
-                                                  0, type);
+                                                  type);
                emit_move_insn (new_rtx, op0);
                op0 = copy_rtx (new_rtx);
                PUT_MODE (op0, BLKmode);
@@ -10277,7 +10268,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
            target
              = assign_stack_temp_for_type
                (TYPE_MODE (inner_type),
-                GET_MODE_SIZE (TYPE_MODE (inner_type)), 0, inner_type);
+                GET_MODE_SIZE (TYPE_MODE (inner_type)), inner_type);
 
          emit_move_insn (target, op0);
          op0 = target;
@@ -10324,7 +10315,7 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
                = MAX (int_size_in_bytes (inner_type),
                       (HOST_WIDE_INT) GET_MODE_SIZE (mode));
              rtx new_rtx
-               = assign_stack_temp_for_type (mode, temp_size, 0, type);
+               = assign_stack_temp_for_type (mode, temp_size, type);
              rtx new_with_op0_mode
                = adjust_address (new_rtx, GET_MODE (op0), 0);
 
@@ -10440,28 +10431,6 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
       return expand_expr_real (treeop0, original_target, tmode,
                               modifier, alt_rtl);
 
-#if 0
-      {
-       /* Initialize the anonymous variable declared in the compound
-          literal, then return the variable.  */
-       tree decl = COMPOUND_LITERAL_EXPR_DECL (exp);
-
-       /* Create RTL for this variable.  */
-       if (!DECL_RTL_SET_P (decl))
-         {
-           if (DECL_HARD_REGISTER (decl))
-             /* The user specified an assembler name for this variable.
-                Set that up now.  */
-             rest_of_decl_compilation (decl, 0, 0);
-           else
-             expand_decl (decl);
-         }
-
-       return expand_expr_real (decl, original_target, tmode,
-                                modifier, alt_rtl);
-      }
-#endif
-
     default:
       return expand_expr_real_2 (&ops, target, tmode, modifier);
     }
index 0fd4d36bfcc3952e9c629d46d26f1b7fff4a0e82..87edf7abbcd893ac5ce97f666793c671acded03a 100644 (file)
@@ -527,7 +527,6 @@ assign_stack_local (enum machine_mode mode, HOST_WIDE_INT size, int align)
   return assign_stack_local_1 (mode, size, align, ASLK_RECORD_PAD);
 }
 \f
-\f
 /* In order to evaluate some expressions, such as function calls returning
    structures in memory, we need to temporarily allocate stack locations.
    We record each allocated temporary in the following structure.
@@ -540,11 +539,7 @@ assign_stack_local (enum machine_mode mode, HOST_WIDE_INT size, int align)
    result could be in a temporary, we preserve it if we can determine which
    one it is in.  If we cannot determine which temporary may contain the
    result, all temporaries are preserved.  A temporary is preserved by
-   pretending it was allocated at the previous nesting level.
-
-   Automatic variables are also assigned temporary slots, at the nesting
-   level where they are defined.  They are marked a "kept" so that
-   free_temp_slots will not free them.  */
+   pretending it was allocated at the previous nesting level.  */
 
 struct GTY(()) temp_slot {
   /* Points to next temporary slot.  */
@@ -564,12 +559,8 @@ struct GTY(()) temp_slot {
   unsigned int align;
   /* Nonzero if this temporary is currently in use.  */
   char in_use;
-  /* Nonzero if this temporary has its address taken.  */
-  char addr_taken;
   /* Nesting level at which this slot is being used.  */
   int level;
-  /* Nonzero if this should survive a call to free_temp_slots.  */
-  int keep;
   /* The offset of the slot from the frame_pointer, including extra space
      for alignment.  This info is for combine_temp_slots.  */
   HOST_WIDE_INT base_offset;
@@ -775,17 +766,11 @@ find_temp_slot_from_address (rtx x)
    SIZE is the size in units of the space required.  We do no rounding here
    since assign_stack_local will do any required rounding.
 
-   KEEP is 1 if this slot is to be retained after a call to
-   free_temp_slots.  Automatic variables for a block are allocated
-   with this flag.  KEEP values of 2 or 3 were needed respectively
-   for variables whose lifetime is controlled by CLEANUP_POINT_EXPRs
-   or for SAVE_EXPRs, but they are now unused.
-
    TYPE is the type that will be used for the stack slot.  */
 
 rtx
 assign_stack_temp_for_type (enum machine_mode mode, HOST_WIDE_INT size,
-                           int keep, tree type)
+                           tree type)
 {
   unsigned int align;
   struct temp_slot *p, *best_p = 0, *selected = NULL, **pp;
@@ -795,9 +780,6 @@ assign_stack_temp_for_type (enum machine_mode mode, HOST_WIDE_INT size,
      of a variable size.  */
   gcc_assert (size != -1);
 
-  /* These are now unused.  */
-  gcc_assert (keep <= 1);
-
   align = get_stack_local_alignment (type, mode);
 
   /* Try to find an available, already-allocated temporary of the proper
@@ -846,7 +828,7 @@ assign_stack_temp_for_type (enum machine_mode mode, HOST_WIDE_INT size,
          if (best_p->size - rounded_size >= alignment)
            {
              p = ggc_alloc_temp_slot ();
-             p->in_use = p->addr_taken = 0;
+             p->in_use = 0;
              p->size = best_p->size - rounded_size;
              p->base_offset = best_p->base_offset + rounded_size;
              p->full_size = best_p->full_size - rounded_size;
@@ -918,10 +900,8 @@ assign_stack_temp_for_type (enum machine_mode mode, HOST_WIDE_INT size,
 
   p = selected;
   p->in_use = 1;
-  p->addr_taken = 0;
   p->type = type;
   p->level = temp_slot_level;
-  p->keep = keep;
 
   pp = temp_slots_at_level (p->level);
   insert_slot_to_list (p, pp);
@@ -946,26 +926,25 @@ assign_stack_temp_for_type (enum machine_mode mode, HOST_WIDE_INT size,
 }
 
 /* Allocate a temporary stack slot and record it for possible later
-   reuse.  First three arguments are same as in preceding function.  */
+   reuse.  First two arguments are same as in preceding function.  */
 
 rtx
-assign_stack_temp (enum machine_mode mode, HOST_WIDE_INT size, int keep)
+assign_stack_temp (enum machine_mode mode, HOST_WIDE_INT size)
 {
-  return assign_stack_temp_for_type (mode, size, keep, NULL_TREE);
+  return assign_stack_temp_for_type (mode, size, NULL_TREE);
 }
 \f
 /* Assign a temporary.
    If TYPE_OR_DECL is a decl, then we are doing it on behalf of the decl
    and so that should be used in error messages.  In either case, we
    allocate of the given type.
-   KEEP is as for assign_stack_temp.
    MEMORY_REQUIRED is 1 if the result must be addressable stack memory;
    it is 0 if a register is OK.
    DONT_PROMOTE is 1 if we should not promote values in register
    to wider modes.  */
 
 rtx
-assign_temp (tree type_or_decl, int keep, int memory_required,
+assign_temp (tree type_or_decl, int memory_required,
             int dont_promote ATTRIBUTE_UNUSED)
 {
   tree type, decl;
@@ -1011,7 +990,7 @@ assign_temp (tree type_or_decl, int keep, int memory_required,
          size = 1;
        }
 
-      tmp = assign_stack_temp_for_type (mode, size, keep, type);
+      tmp = assign_stack_temp_for_type (mode, size, type);
       return tmp;
     }
 
@@ -1139,32 +1118,10 @@ update_temp_slot_address (rtx old_rtx, rtx new_rtx)
   insert_temp_slot_address (new_rtx, p);
 }
 
-/* If X could be a reference to a temporary slot, mark the fact that its
-   address was taken.  */
-
-void
-mark_temp_addr_taken (rtx x)
-{
-  struct temp_slot *p;
-
-  if (x == 0)
-    return;
-
-  /* If X is not in memory or is at a constant address, it cannot be in
-     a temporary slot.  */
-  if (!MEM_P (x) || CONSTANT_P (XEXP (x, 0)))
-    return;
-
-  p = find_temp_slot_from_address (XEXP (x, 0));
-  if (p != 0)
-    p->addr_taken = 1;
-}
-
 /* If X could be a reference to a temporary slot, mark that slot as
    belonging to the to one level higher than the current level.  If X
    matched one of our slots, just mark that one.  Otherwise, we can't
-   easily predict which it is, so upgrade all of them.  Kept slots
-   need not be touched.
+   easily predict which it is, so upgrade all of them.
 
    This is called when an ({...}) construct occurs and a statement
    returns a value in memory.  */
@@ -1174,43 +1131,18 @@ preserve_temp_slots (rtx x)
 {
   struct temp_slot *p = 0, *next;
 
-  /* If there is no result, we still might have some objects whose address
-     were taken, so we need to make sure they stay around.  */
   if (x == 0)
-    {
-      for (p = *temp_slots_at_level (temp_slot_level); p; p = next)
-       {
-         next = p->next;
-
-         if (p->addr_taken)
-           move_slot_to_level (p, temp_slot_level - 1);
-       }
-
-      return;
-    }
+    return;
 
   /* If X is a register that is being used as a pointer, see if we have
-     a temporary slot we know it points to.  To be consistent with
-     the code below, we really should preserve all non-kept slots
-     if we can't find a match, but that seems to be much too costly.  */
+     a temporary slot we know it points to.  */
   if (REG_P (x) && REG_POINTER (x))
     p = find_temp_slot_from_address (x);
 
   /* If X is not in memory or is at a constant address, it cannot be in
-     a temporary slot, but it can contain something whose address was
-     taken.  */
+     a temporary slot.  */
   if (p == 0 && (!MEM_P (x) || CONSTANT_P (XEXP (x, 0))))
-    {
-      for (p = *temp_slots_at_level (temp_slot_level); p; p = next)
-       {
-         next = p->next;
-
-         if (p->addr_taken)
-           move_slot_to_level (p, temp_slot_level - 1);
-       }
-
-      return;
-    }
+    return;
 
   /* First see if we can find a match.  */
   if (p == 0)
@@ -1218,23 +1150,8 @@ preserve_temp_slots (rtx x)
 
   if (p != 0)
     {
-      /* Move everything at our level whose address was taken to our new
-        level in case we used its address.  */
-      struct temp_slot *q;
-
       if (p->level == temp_slot_level)
-       {
-         for (q = *temp_slots_at_level (temp_slot_level); q; q = next)
-           {
-             next = q->next;
-
-             if (p != q && q->addr_taken)
-               move_slot_to_level (q, temp_slot_level - 1);
-           }
-
-         move_slot_to_level (p, temp_slot_level - 1);
-         p->addr_taken = 0;
-       }
+       move_slot_to_level (p, temp_slot_level - 1);
       return;
     }
 
@@ -1242,9 +1159,7 @@ preserve_temp_slots (rtx x)
   for (p = *temp_slots_at_level (temp_slot_level); p; p = next)
     {
       next = p->next;
-
-      if (!p->keep)
-       move_slot_to_level (p, temp_slot_level - 1);
+      move_slot_to_level (p, temp_slot_level - 1);
     }
 }
 
@@ -1260,12 +1175,8 @@ free_temp_slots (void)
   for (p = *temp_slots_at_level (temp_slot_level); p; p = next)
     {
       next = p->next;
-
-      if (!p->keep)
-       {
-         make_slot_available (p);
-         some_available = true;
-       }
+      make_slot_available (p);
+      some_available = true;
     }
 
   if (some_available)
@@ -1289,22 +1200,7 @@ push_temp_slots (void)
 void
 pop_temp_slots (void)
 {
-  struct temp_slot *p, *next;
-  bool some_available = false;
-
-  for (p = *temp_slots_at_level (temp_slot_level); p; p = next)
-    {
-      next = p->next;
-      make_slot_available (p);
-      some_available = true;
-    }
-
-  if (some_available)
-    {
-      remove_unused_temp_slot_addresses ();
-      combine_temp_slots ();
-    }
-
+  free_temp_slots ();
   temp_slot_level--;
 }
 
index 6f7aabc32c2903dfe0c633421427a1601f95d0fe..ae5157e54c065a49e495b6119e7c17a2169082c2 100644 (file)
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -1730,10 +1730,9 @@ extern rtx assign_stack_local (enum machine_mode, HOST_WIDE_INT, int);
 #define ASLK_REDUCE_ALIGN 1
 #define ASLK_RECORD_PAD 2
 extern rtx assign_stack_local_1 (enum machine_mode, HOST_WIDE_INT, int, int);
-extern rtx assign_stack_temp (enum machine_mode, HOST_WIDE_INT, int);
-extern rtx assign_stack_temp_for_type (enum machine_mode,
-                                      HOST_WIDE_INT, int, tree);
-extern rtx assign_temp (tree, int, int, int);
+extern rtx assign_stack_temp (enum machine_mode, HOST_WIDE_INT);
+extern rtx assign_stack_temp_for_type (enum machine_mode, HOST_WIDE_INT, tree);
+extern rtx assign_temp (tree, int, int);
 
 /* In emit-rtl.c */
 extern rtx emit_insn_before (rtx, rtx);
@@ -2498,7 +2497,6 @@ extern void print_inline_rtx (FILE *, const_rtx, int);
 extern void reposition_prologue_and_epilogue_notes (void);
 extern int prologue_epilogue_contains (const_rtx);
 extern int sibcall_epilogue_contains (const_rtx);
-extern void mark_temp_addr_taken (rtx);
 extern void update_temp_slot_address (rtx, rtx);
 extern void maybe_copy_prologue_epilogue_insn (rtx, rtx);
 extern void set_return_jump_label (rtx);
index a9258b15c7d31d747df7fdd100b6df85793b7759..4ad4d0f1e595f32e0ca61c17b8d319109c6680b8 100644 (file)
@@ -827,7 +827,7 @@ expand_asm_operands (tree string, tree outputs, tree inputs,
        }
       else
        {
-         op = assign_temp (type, 0, 0, 1);
+         op = assign_temp (type, 0, 1);
          op = validize_mem (op);
          if (!MEM_P (op) && TREE_CODE (TREE_VALUE (tail)) == SSA_NAME)
            set_reg_attrs_for_decl_rtl (SSA_NAME_VAR (TREE_VALUE (tail)), op);
@@ -911,33 +911,6 @@ expand_asm_operands (tree string, tree outputs, tree inputs,
            }
          else
            gcc_unreachable ();
-#if 0
-           {
-             warning (0, "use of memory input without lvalue in "
-                      "asm operand %d is deprecated", i + noutputs);
-
-             if (CONSTANT_P (op))
-               {
-                 rtx mem = force_const_mem (TYPE_MODE (type), op);
-                 if (mem)
-                   op = validize_mem (mem);
-                 else
-                   op = force_reg (TYPE_MODE (type), op);
-               }
-             if (REG_P (op)
-                 || GET_CODE (op) == SUBREG
-                 || GET_CODE (op) == CONCAT)
-               {
-                 tree qual_type = build_qualified_type (type,
-                                                        (TYPE_QUALS (type)
-                                                         | TYPE_QUAL_CONST));
-                 rtx memloc = assign_temp (qual_type, 1, 1, 1);
-                 memloc = validize_mem (memloc);
-                 emit_move_insn (memloc, op);
-                 op = memloc;
-               }
-           }
-#endif
        }
 
       generating_concat_p = old_generating_concat_p;
@@ -1606,7 +1579,7 @@ expand_return (tree retval)
       tree ot = TREE_TYPE (DECL_RESULT (current_function_decl));
       tree nt = build_qualified_type (ot, TYPE_QUALS (ot) | TYPE_QUAL_CONST);
 
-      val = assign_temp (nt, 0, 0, 1);
+      val = assign_temp (nt, 0, 1);
       val = expand_expr (retval_rhs, val, GET_MODE (val), EXPAND_NORMAL);
       val = force_not_mem (val);
       /* Return the calculated value.  */
@@ -1692,113 +1665,6 @@ expand_nl_goto_receiver (void)
   emit_insn (gen_blockage ());
 }
 \f
-/* Generate RTL for the automatic variable declaration DECL.
-   (Other kinds of declarations are simply ignored if seen here.)  */
-
-void
-expand_decl (tree decl)
-{
-  tree type;
-
-  type = TREE_TYPE (decl);
-
-  /* For a CONST_DECL, set mode, alignment, and sizes from those of the
-     type in case this node is used in a reference.  */
-  if (TREE_CODE (decl) == CONST_DECL)
-    {
-      gcc_unreachable ();
-      DECL_MODE (decl) = TYPE_MODE (type);
-      DECL_ALIGN (decl) = TYPE_ALIGN (type);
-      DECL_SIZE (decl) = TYPE_SIZE (type);
-      DECL_SIZE_UNIT (decl) = TYPE_SIZE_UNIT (type);
-      return;
-    }
-
-  /* Otherwise, only automatic variables need any expansion done.  Static and
-     external variables, and external functions, will be handled by
-     `assemble_variable' (called from finish_decl).  TYPE_DECL requires
-     nothing.  PARM_DECLs are handled in `assign_parms'.  */
-  if (TREE_CODE (decl) != VAR_DECL)
-    return;
-
-  if (TREE_STATIC (decl) || DECL_EXTERNAL (decl))
-    return;
-
-  gcc_unreachable ();
-  /* Create the RTL representation for the variable.  */
-
-  if (type == error_mark_node)
-    SET_DECL_RTL (decl, gen_rtx_MEM (BLKmode, const0_rtx));
-
-  else if (DECL_SIZE (decl) == 0)
-    {
-      /* Variable with incomplete type.  */
-      rtx x;
-      if (DECL_INITIAL (decl) == 0)
-       /* Error message was already done; now avoid a crash.  */
-       x = gen_rtx_MEM (BLKmode, const0_rtx);
-      else
-       /* An initializer is going to decide the size of this array.
-          Until we know the size, represent its address with a reg.  */
-       x = gen_rtx_MEM (BLKmode, gen_reg_rtx (Pmode));
-
-      set_mem_attributes (x, decl, 1);
-      SET_DECL_RTL (decl, x);
-    }
-  else if (use_register_for_decl (decl))
-    {
-      /* Automatic variable that can go in a register.  */
-      enum machine_mode reg_mode = promote_decl_mode (decl, NULL);
-
-      SET_DECL_RTL (decl, gen_reg_rtx (reg_mode));
-
-      /* Note if the object is a user variable.  */
-      if (!DECL_ARTIFICIAL (decl))
-         mark_user_reg (DECL_RTL (decl));
-
-      if (POINTER_TYPE_P (type))
-       mark_reg_pointer (DECL_RTL (decl),
-                         TYPE_ALIGN (TREE_TYPE (TREE_TYPE (decl))));
-    }
-
-  else
-    {
-      rtx oldaddr = 0;
-      rtx addr;
-      rtx x;
-
-      /* Variable-sized decls are dealt with in the gimplifier.  */
-      gcc_assert (TREE_CODE (DECL_SIZE_UNIT (decl)) == INTEGER_CST);
-
-      /* If we previously made RTL for this decl, it must be an array
-        whose size was determined by the initializer.
-        The old address was a register; set that register now
-        to the proper address.  */
-      if (DECL_RTL_SET_P (decl))
-       {
-         gcc_assert (MEM_P (DECL_RTL (decl)));
-         gcc_assert (REG_P (XEXP (DECL_RTL (decl), 0)));
-         oldaddr = XEXP (DECL_RTL (decl), 0);
-       }
-
-      /* Set alignment we actually gave this decl.  */
-      DECL_ALIGN (decl) = (DECL_MODE (decl) == BLKmode ? BIGGEST_ALIGNMENT
-                          : GET_MODE_BITSIZE (DECL_MODE (decl)));
-      DECL_USER_ALIGN (decl) = 0;
-
-      x = assign_temp (decl, 1, 1, 1);
-      set_mem_attributes (x, decl, 1);
-      SET_DECL_RTL (decl, x);
-
-      if (oldaddr)
-       {
-         addr = force_operand (XEXP (DECL_RTL (decl), 0), oldaddr);
-         if (addr != oldaddr)
-           emit_move_insn (oldaddr, addr);
-       }
-    }
-}
-\f
 /* Emit code to save the current value of stack.  */
 rtx
 expand_stack_save (void)
index 69294b68f491b9e13fb3dba395ca7ba280492d03..94750b0b716e00c8a59e5348be0f5ea25751798b 100644 (file)
@@ -5693,7 +5693,6 @@ extern tree resolve_asm_operand_names (tree, tree, tree, tree);
 extern bool expand_switch_using_bit_tests_p (tree, tree, unsigned int,
                                             unsigned int);
 extern void expand_case (gimple);
-extern void expand_decl (tree);
 #ifdef HARD_CONST
 /* Silly ifdef to avoid having all includers depend on hard-reg-set.h.  */
 extern tree tree_overlaps_hard_reg_set (tree, HARD_REG_SET *);