This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Committed: RX: Fix allocation of second frame slot
- From: Nick Clifton <nickc at redhat dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Tue, 05 Jan 2010 15:45:33 +0000
- Subject: Committed: RX: Fix allocation of second frame slot
Hi Guys,
I have applied the patch below to fix a couple of bugs in the RX
backend when it is necessary to allocate a pair of slots in the
stack frame in order to be able to save the interrupt register
during interrupts.
Cheers
Nick
gcc/ChangeLog
2010-01-05 Nick Clifton <nickc@redhat.com>
* config/rx/rx.c (rx_get_stack_layout): Fix allocation of second
register to push into the stack frame when the accumulator has to
be saved during interrupts.
Index: gcc/config/rx/rx.c
===================================================================
RCS file: /cvs/cvsfiles/devo/gcc/config/rx/rx.c,v
retrieving revision 1.82
diff -c -3 -p -r1.82 rx.c
*** gcc/config/rx/rx.c 20 Dec 2009 16:41:39 -0000 1.82
--- gcc/config/rx/rx.c 31 Dec 2009 14:25:38 -0000
*************** rx_get_stack_layout (unsigned int * lowe
*** 1077,1084 ****
save_mask |= (1 << 13) | (1 << 14);
if (low == 0)
low = 13;
! if (high == 0)
! high = 14;
}
/* Decide if it would be faster fill in the call-saved area of the stack
--- 1077,1084 ----
save_mask |= (1 << 13) | (1 << 14);
if (low == 0)
low = 13;
! if (high == 0 || low == high)
! high = low + 1;
}
/* Decide if it would be faster fill in the call-saved area of the stack