tilegx.c (tilegx_expand_prologue): Avoid double-decrement of next_scratch_regno.

* config/tilegx/tilegx.c (tilegx_expand_prologue): Avoid
	double-decrement of next_scratch_regno.

From-SVN: r197139
This commit is contained in:
Walter Lee 2013-03-27 06:18:49 +00:00 committed by Walter Lee
parent 9332b0d294
commit 0a514f47b8
2 changed files with 9 additions and 5 deletions

View File

@ -1,3 +1,8 @@
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_expand_prologue): Avoid
double-decrement of next_scratch_regno.
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.md (insn_v1mulu): Fix constraints on

View File

@ -3999,11 +3999,10 @@ tilegx_expand_prologue (void)
if (r == NULL_RTX)
{
rtx p = compute_frame_addr (offset, &next_scratch_regno);
r = gen_rtx_REG (Pmode, next_scratch_regno--);
reg_save_addr[which_scratch] = r;
emit_insn (gen_rtx_SET (VOIDmode, r, p));
int prev_scratch_regno = next_scratch_regno;
r = compute_frame_addr (offset, &next_scratch_regno);
if (prev_scratch_regno != next_scratch_regno)
reg_save_addr[which_scratch] = r;
}
else
{