+2002-06-13 Jeffrey Law <law@redhat.com>
+
+ * alias.c (argument_registers): Remove.
+ (init_alias_once): Initialize static_reg_base_value here. Remove
+ initialization of argument_registers.
+ (init_alias_once_per_function): Remove.
+ (init_alias_analysis): Copy all the entries from static_reg_base_value
+ into new_reg_base_value all at once.
+ * rtl.h (init_alias_once_per_function): Remove declaration.
+ * function.c (prepare_function_start): Do not call
+ init_alias_once_per_function.
+
+ * caller-save.c (init_caller_save): Use gen_rtx_INSN instead of
+ starting a sequence and emitting an INSN.
+
2002-06-13 Richard Sandiford <rsandifo@redhat.com>
* config/mips/r3900.h (MIPS_CPU_STRING_DEFAULT): Make lower case.
}
\f
-static HARD_REG_SET argument_registers;
-
void
init_alias_once ()
{
numbers, so translate if necessary due to register windows. */
if (FUNCTION_ARG_REGNO_P (OUTGOING_REGNO (i))
&& HARD_REGNO_MODE_OK (i, Pmode))
- SET_HARD_REG_BIT (argument_registers, i);
-
- alias_sets = splay_tree_new (splay_tree_compare_ints, 0, 0);
-}
-
-/* Per-function initializer for the aliasing code.
-
- Allocate RTL for argument and other special use registers once
- per function here intead of multiple times per function in
- init_alias_analysis. */
-
-void
-init_alias_once_per_function ()
-{
- int i;
-
- /* Generate and mark all hard registers which may contain an address.
- The stack, frame and argument pointers may contain an address.
- An argument register which can hold a Pmode value may contain
- an address even if it is not in BASE_REGS.
-
- The address expression is VOIDmode for an argument and
- Pmode for other registers. */
-
- for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
- if (TEST_HARD_REG_BIT (argument_registers, i))
static_reg_base_value[i]
= gen_rtx_ADDRESS (VOIDmode, gen_rtx_REG (Pmode, i));
-
static_reg_base_value[STACK_POINTER_REGNUM]
= gen_rtx_ADDRESS (Pmode, stack_pointer_rtx);
static_reg_base_value[ARG_POINTER_REGNUM]
static_reg_base_value[HARD_FRAME_POINTER_REGNUM]
= gen_rtx_ADDRESS (Pmode, hard_frame_pointer_rtx);
#endif
+
+ alias_sets = splay_tree_new (splay_tree_compare_ints, 0, 0);
}
/* Initialize the aliasing machinery. Initialize the REG_KNOWN_VALUE
The address expression is VOIDmode for an argument and
Pmode for other registers. */
- for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
- if (TEST_HARD_REG_BIT (argument_registers, i))
- new_reg_base_value[i] = static_reg_base_value[i];
+ memcpy (new_reg_base_value, static_reg_base_value,
+ FIRST_PSEUDO_REGISTER * sizeof (rtx));
- new_reg_base_value[STACK_POINTER_REGNUM]
- = static_reg_base_value[STACK_POINTER_REGNUM];
- new_reg_base_value[ARG_POINTER_REGNUM]
- = static_reg_base_value[ARG_POINTER_REGNUM];
- new_reg_base_value[FRAME_POINTER_REGNUM]
- = static_reg_base_value[FRAME_POINTER_REGNUM];
-#if HARD_FRAME_POINTER_REGNUM != FRAME_POINTER_REGNUM
- new_reg_base_value[HARD_FRAME_POINTER_REGNUM]
- = static_reg_base_value[HARD_FRAME_POINTER_REGNUM];
-#endif
/* Walk the insns adding values to the new_reg_base_value array. */
for (insn = get_insns (); insn; insn = NEXT_INSN (insn))
{
savepat = gen_rtx_SET (VOIDmode, test_mem, test_reg);
restpat = gen_rtx_SET (VOIDmode, test_reg, test_mem);
- start_sequence ();
-
- saveinsn = emit_insn (savepat);
- restinsn = emit_insn (restpat);
+ saveinsn = gen_rtx_INSN (VOIDmode, 0, 0, 0, 0, 0, savepat, -1, 0, 0);
+ restinsn = gen_rtx_INSN (VOIDmode, 0, 0, 0, 0, 0, restpat, -1, 0, 0);
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
for (mode = 0 ; mode < MAX_MACHINE_MODE; mode++)
SET_HARD_REG_BIT (call_fixed_reg_set, i);
}
}
-
- end_sequence ();
}
\f
/* Initialize save areas by showing that we haven't allocated any yet. */