[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gcc
Subject:    Re: who owns stack args?
From:       Jeff Law <law () redhat ! com>
Date:       2016-02-24 20:54:20
Message-ID: 56CE187C.1010309 () redhat ! com
[Download RAW message or body]

On 02/24/2016 01:42 PM, Alexander Monakov wrote:
> On Wed, 24 Feb 2016, DJ Delorie wrote:
>> The real question is: are stack arguments call-clobbered or
>> call-preserved?  Does the answer depend on the "pure" attribute?
>
> Stack area holding stack arguments should belong to the callee for tail-calls
> to work (the callee will trash that area when laying out arguments for the
> tail call; thanks to Rich Felker for pointing that out to me).
>
> Thus it cannot depend on attribute-pure.
Which would imply that the outgoing argument stack slots must always be 
considered clobbered by a call.

FWIW, I'm fine with that interpretation ;-)

jeff
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic