Commit be763023 by Richard Sandiford Committed by Richard Sandiford

mips.c (MIPS_MAX_FIRST_STACK_STEP): New macro.

	* config/mips/mips.c (MIPS_MAX_FIRST_STACK_STEP): New macro.
	(mips_save_restore_fn): New typedef.
	(mips_add_large_offset_to_sp, mips_emit_frame_related_store): Remove.
	(mips_set_frame_expr, mips_frame_set): Move above prologue code.
	(save_restore_insns): Remove, replacing with...
	(mips_save_restore_reg, mips_for_each_saved_reg): ...these new fns.
	(mips_save_reg, mips_restore_reg): New function.
	(mips_expand_prologue, mips_expand_epilogue): Rework.
	* config/mips/mips.h (MIPS_TEMP1_REGNUM, MIPS_TEMP2_REGNUM): Remove.
	(MIPS_PROLOGUE_TEMP_REGNUM, MIPS_EPILOGUE_TEMP_REGNUM): New macros.
	(MIPS_PROLOGUE_TEMP, MIPS_EPILOGUE_TEMP): New macros.

From-SVN: r72182
parent aaa21542
2003-10-07 Richard Sandiford <rsandifo@redhat.com> 2003-10-07 Richard Sandiford <rsandifo@redhat.com>
* config/mips/mips.c (MIPS_MAX_FIRST_STACK_STEP): New macro.
(mips_save_restore_fn): New typedef.
(mips_add_large_offset_to_sp, mips_emit_frame_related_store): Remove.
(mips_set_frame_expr, mips_frame_set): Move above prologue code.
(save_restore_insns): Remove, replacing with...
(mips_save_restore_reg, mips_for_each_saved_reg): ...these new fns.
(mips_save_reg, mips_restore_reg): New function.
(mips_expand_prologue, mips_expand_epilogue): Rework.
* config/mips/mips.h (MIPS_TEMP1_REGNUM, MIPS_TEMP2_REGNUM): Remove.
(MIPS_PROLOGUE_TEMP_REGNUM, MIPS_EPILOGUE_TEMP_REGNUM): New macros.
(MIPS_PROLOGUE_TEMP, MIPS_EPILOGUE_TEMP): New macros.
2003-10-07 Richard Sandiford <rsandifo@redhat.com>
* config/mips/mips.c (mips_expand_prologue): Remove unused * config/mips/mips.c (mips_expand_prologue): Remove unused
traversal of function arguments. traversal of function arguments.
......
...@@ -1674,15 +1674,18 @@ extern char mips_hard_regno_mode_ok[][FIRST_PSEUDO_REGISTER]; ...@@ -1674,15 +1674,18 @@ extern char mips_hard_regno_mode_ok[][FIRST_PSEUDO_REGISTER];
/* Pass structure addresses as an "invisible" first argument. */ /* Pass structure addresses as an "invisible" first argument. */
#define STRUCT_VALUE 0 #define STRUCT_VALUE 0
/* Mips registers used in prologue/epilogue code when the stack frame /* Registers used as temporaries in prologue/epilogue code. If we're
is larger than 32K bytes. These registers must come from the generating mips16 code, these registers must come from the core set
scratch register set, and not used for passing and returning of 8. The prologue register mustn't conflict with any incoming
arguments and any other information used in the calling sequence arguments, the static chain pointer, or the frame pointer. The
(such as pic). Must start at 12, since t0/t3 are parameter passing epilogue temporary mustn't conflict with the return registers, the
registers in the 64 bit ABI. */ frame pointer, the EH stack adjustment, or the EH data registers. */
#define MIPS_TEMP1_REGNUM (GP_REG_FIRST + 12) #define MIPS_PROLOGUE_TEMP_REGNUM (GP_REG_FIRST + 3)
#define MIPS_TEMP2_REGNUM (GP_REG_FIRST + 13) #define MIPS_EPILOGUE_TEMP_REGNUM (GP_REG_FIRST + (TARGET_MIPS16 ? 6 : 8))
#define MIPS_PROLOGUE_TEMP(MODE) gen_rtx_REG (MODE, MIPS_PROLOGUE_TEMP_REGNUM)
#define MIPS_EPILOGUE_TEMP(MODE) gen_rtx_REG (MODE, MIPS_EPILOGUE_TEMP_REGNUM)
/* Define this macro if it is as good or better to call a constant /* Define this macro if it is as good or better to call a constant
function address than to call an address kept in a register. */ function address than to call an address kept in a register. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment