From af68829613cdfc26263726f069c9bdb9bd5773e7 Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Mon, 4 Oct 1993 17:47:19 -0400 Subject: [PATCH] (incoming_regs): Only use 16 registers for parameter passing. From-SVN: r5591 --- gcc/config/a29k/a29k.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/config/a29k/a29k.c b/gcc/config/a29k/a29k.c index 7d6e9c0dd91..631176134af 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); -- 2.30.2