aboutsummaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1993-10-04 17:47:19 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1993-10-04 17:47:19 -0400
commitaf68829613cdfc26263726f069c9bdb9bd5773e7 (patch)
treef5a0f7c308f68822798e74fd01c7bf33bfb853c3 /gcc/config
parentc669233a498741f07784884a494c211628db82fd (diff)
downloadgcc-af68829613cdfc26263726f069c9bdb9bd5773e7.zip
gcc-af68829613cdfc26263726f069c9bdb9bd5773e7.tar.gz
gcc-af68829613cdfc26263726f069c9bdb9bd5773e7.tar.bz2
(incoming_regs): Only use 16 registers for parameter passing.
From-SVN: r5591
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/a29k/a29k.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/config/a29k/a29k.c b/gcc/config/a29k/a29k.c
index 7d6e9c0..6311761 100644
--- a/gcc/config/a29k/a29k.c
+++ b/gcc/config/a29k/a29k.c
@@ -772,9 +772,14 @@ incoming_reg (start, count)
{
int i;
+ /* We only use 16 argument registers, so truncate at the end of the
+ area. */
+ if (start + count > 16)
+ count = 16 - start;
+
if (! TARGET_NO_REUSE_ARGS)
/* Mark all the used registers as not fixed and saved over calls. */
- for (i = R_AR (start); i < R_AR (16) && i < R_AR (start + count); i++)
+ for (i = R_AR (start); i < R_AR (start + count); i++)
{
fixed_regs[i] = call_used_regs[i] = call_fixed_regs[i] = 0;
CLEAR_HARD_REG_BIT (fixed_reg_set, i);