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: Serious performance regression -- some tree optimizer questions


> Likewise, no pass recognizes that in a sequence:
>
>  i = a + b
>  x = array[i]
>
> where both the base 'array' and the value 'a' are loop-invariant,
> but the value 'b' isn't, 'array' and 'a' can be combined into
> a new base address 'array + a*stride' which can be moved out of
> the loop.  (The old RTL loop optimizer was able to do this.)
>
>
> Any suggestions how to further investigate this?  Is this just
> the way things are with the current tree optimizers, or is this
> supposed to work and we just need to find the bug?

Just to say that, given how intricate the code is in loop.c, it would not be 
very surprising if the old RTL loop optimizer outperformed the new ones for 
the few years to come in many cases.  This code can't have evolved into its 
current state without reasons.

-- 
Eric Botcazou


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