Commit bcb2d701 by Eric Christopher Committed by Eric Christopher

rs6000.c (rs6000_emit_prologue): Update sp_offset depending on stack size.

2007-05-27  Eric Christopher  <echristo@apple.com>

	    * config/rs6000/rs6000.c (rs6000_emit_prologue): Update
	    sp_offset depending on stack size. Save r12 depending
	    on registers we're saving later.
	    (rs6000_emit_epilogue): Update sp_offset depending only
	    on stack size.

From-SVN: r125116
parent d51157de
2007-05-27 Eric Christopher <echristo@apple.com>
* config/rs6000/rs6000.c (rs6000_emit_prologue): Update
sp_offset depending on stack size. Save r12 depending
on registers we're saving later.
(rs6000_emit_epilogue): Update sp_offset depending only
on stack size.
2007-05-27 Zdenek Dvorak <dvorakz@suse.cz>
* tree-vrp.c (execute_vrp): Do not check whether current_loops == NULL.
......
......@@ -15050,8 +15050,17 @@ rs6000_emit_prologue (void)
if (!WORLD_SAVE_P (info) && info->push_p
&& !(DEFAULT_ABI == ABI_V4 || current_function_calls_eh_return))
{
rs6000_emit_allocate_stack (info->total_size, FALSE);
if (info->total_size < 32767)
sp_offset = info->total_size;
else
frame_reg_rtx = frame_ptr_rtx;
rs6000_emit_allocate_stack (info->total_size,
(frame_reg_rtx != sp_reg_rtx
&& ((info->altivec_size != 0)
|| (info->vrsave_mask != 0)
)));
if (frame_reg_rtx != sp_reg_rtx)
rs6000_emit_stack_tie ();
}
/* Set frame pointer, if needed. */
......@@ -15392,8 +15401,7 @@ rs6000_emit_epilogue (int sibcall)
}
/* Set sp_offset based on the stack push from the prologue. */
if ((DEFAULT_ABI == ABI_V4 || current_function_calls_eh_return)
&& info->total_size < 32767)
if (info->total_size < 32767)
sp_offset = info->total_size;
/* Restore AltiVec registers if needed. */
......
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