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]
Other format: [Raw text]

Re: Speedup CSE by 5%


> > You are (of course) correct.  I've been working with gimple too much
> > lately and needed a reminder of the annoyingly recursive nature of
> > RTL.  Ugh.
> 
> I am currently timing bootstrap for a patch that introduces an iterator 
> FOR_EACH_RTX.  This manages its own stack and also gets rid of the 
> recursive calls.
> 
> The part that I feel less confortable with is allocating the stack with 
> alloca, but overall it is nice.  I attach the patch for cse.c as a proof 
> of concept.

I've implemented similar trick a while ago.  I simply allocated the
stack as static array extended by xmalloc on overflow.
http://gcc.gnu.org/ml/gcc-patches/2000-09/msg00890.html

My results were similar concerning speedup to CSE, but I don't have
exact numbers anymore, but the macro hackery is notably ugly.  Perhaps
factoring out some of code into inline functions would make it easier to
deal with.

Honza
> 
> Paolo


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