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: Loop Optimizer Deficiency revisited


> >
> > I think you are talking about "[rtlopt] GCSE global variables removal"
> > http://gcc.gnu.org/ml/gcc-patches/2002-09/msg01355.html
> > submitted by Zdenek. I'll try this with my test case, and communicate
> > if there are any improvements.
>
> Nope, that is something different. The right patch is
> http://gcc.gnu.org/ml/gcc-patches/2003-03/msg00467.html.
>

Thanks for correcting me but this patch does not solve the problem.
The compiler still generates the same code i.e. duplicate loop test code.

Please note that I have merged the patch with GCC 3.2 released. Since
the original patch was generated with newer version of gcse.c I
encountered some error related to FOR_EACH_BB and the type of 'bb'
which I was able to resolve.

It seems to me that this problem is related to removal of .jump2,
shouldn't the new jump threading "pass" with cfg take care
of this. Please comment.

Thanks and Regards,
Nitin

>
> > To improve my understanding I rephrase the problem and my understanding.
> > Please correct me, if I'm wrong.
> >
> > GCC 3.2 would duplicate the entire loop test in .jump and would
> > not merge is anywhere latter. Since the loop size is small, increase
> > in size is significant, it duplicates more expressions hence *increases*
> > size furthered when compiled with **-Os** [cse2 performs badly
> with -Os].
> > However GCC 2.96 would do the same in .jump but would merge the
> loop test in
> >  .jump2 (irrespective of -Os is given or not). From the archives I could
> > make
> > out the jump2 was removed by jump over CFG. But it does not
> seems to cater
> > this problem.  The probable solution is that GCC 3.2 should take care of
> > this
> > while during GCSE phase while doing code hoisting ( when
> invoked with -Os).
> >
> > Would an improved store motion take care of these cse2 and unification
> > issues?

>


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