rs6000.c (rs6000_emit_epilogue): Simplify use_backchain_to_restore_sp initialisation.

* config/rs6000/rs6000.c (rs6000_emit_epilogue): Simplify
	use_backchain_to_restore_sp initialisation.
	(rs6000_legitimate_offset_address_p): Simplify offset test.

From-SVN: r177309
This commit is contained in:
Alan Modra 2011-08-04 12:41:02 +09:30 committed by Alan Modra
parent c7c2e8316c
commit ea6c2b0e96
2 changed files with 8 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2011-08-04 Alan Modra <amodra@gmail.com>
* config/rs6000/rs6000.c (rs6000_emit_epilogue): Simplify
use_backchain_to_restore_sp initialisation.
(rs6000_legitimate_offset_address_p): Simplify offset test.
2011-08-03 Richard Henderson <rth@redhat.com>
* config/spu/spu.md: Use define_c_enum instead of define_constants.

View File

@ -5392,7 +5392,7 @@ rs6000_legitimate_offset_address_p (enum machine_mode mode, rtx x, int strict)
}
offset += 0x8000;
return (offset < 0x10000) && (offset + extra < 0x10000);
return offset < 0x10000 - extra;
}
bool
@ -20712,10 +20712,7 @@ rs6000_emit_epilogue (int sibcall)
here will not trigger at the moment; We don't actually need a
frame pointer for alloca, but the generic parts of the compiler
give us one anyway. */
use_backchain_to_restore_sp = (info->total_size > 32767
|| info->total_size
+ (info->lr_save_p ? info->lr_save_offset : 0)
> 32767
use_backchain_to_restore_sp = (info->total_size > 32767 - info->lr_save_offset
|| (cfun->calls_alloca
&& !frame_pointer_needed));
restore_lr = (info->lr_save_p