This is the mail archive of the gcc-patches@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]

Re: Combine_stack_adjustements fix


> On Fri, Sep 08, 2000 at 02:41:39PM +0200, Jan Hubicka wrote:
> > This patch avoids this problem by changing regmove to do only the
> > safe transformations - when second adjustemnt is allocating instruction,
> 
> I'm not entirely pleased with the solution.  It shouldn't be hard
> to notice that we've stored the stack value somewhere.
OK - I think it can be followup of this patch - when we notice, that stack
pointer is moved (it should be pretty hard - for example it is always
loaded to ebp, so it would need some kind of alias/flow analysis), we should
use this notion of safe transformation and thus avoid the problem - still
it is the question how often the dummy allocation followed by deallocation
is performed - my theory is that only for functions with dummy stack frames
such as
main()
{
  char c[20];
}
Certanly we should take care to avoid these earlier, since they only waste
stack frame - the common sitionations caused by the preferred-stack-boundary
code (I believe that these are 99.9% of cases) are still handled properly
tought - I can do some code size measurements, in case you are interested.
Objects from spec2000 can be OK?

Do you think that my idea of creating ADDRESSOF for each stack object (not
only pseudos) makes sense? I can dig out the patch.

Honza
> 
> 
> r~

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