This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Dynamic FUNCTION_OUTGOING_VALUE?


On Fri, 2003-09-19 at 07:28, Alexandre Courbot wrote:
> What I had in mind was that the callee always returns to a fixed place, while 
> the callers can get the return value from a pseudo. Since patterns for 
> call_value looks typically like

I'm still not sure I get it.  If the return value is in a fixed place,
then we still need to copy it from that fixed place to the pseudo, so
why do you want a pseudo in the call insn itself?  That just seems to
hide the fact that the value is in a hard register which could cause
problems.  Unless maybe the call insn takes a destination register as an
option, and does the move itself.  That would be novel, and not directly
supported by gcc.  You'd still probably want a the fixed place mentioned
in a clobber in the call insn.

> What prevents me from creating a pseudo in FUNCTION_RETURN_VALUE is that is it 
> called several times for every function call, and even when outputting the 
> code of the callee. So it is impossible to assign a unique pseudo for every 
> function call.

You could try to write a patch to fix this.
-- 
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]