diff options
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/calls.c | 13 |
2 files changed, 17 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 888ac2e6194..a8f41702d31 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2007-02-28 Bernd Schmidt <bernd.schmidt@analog.com> + + * calls.c (emit_library_call_value_1): Handle partial registers + correctly when building up CALL_INSN_FUNCTION_USAGE. + 2007-02-27 John David Anglin <dave.anglin@nrc-cnrc.gc.ca> * pa/predicates.md (move_src_operand): Allow zero for mode. diff --git a/gcc/calls.c b/gcc/calls.c index d9ba08c0ddb..8723e1f4fae 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -3774,7 +3774,18 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx value, if (reg != 0 && GET_CODE (reg) == PARALLEL) use_group_regs (&call_fusage, reg); else if (reg != 0) - use_reg (&call_fusage, reg); + { + int partial = argvec[count].partial; + if (partial) + { + int nregs; + gcc_assert (partial % UNITS_PER_WORD == 0); + nregs = partial / UNITS_PER_WORD; + use_regs (&call_fusage, REGNO (reg), nregs); + } + else + use_reg (&call_fusage, reg); + } } /* Pass the function the address in which to return a structure value. */ |