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]

Re: Loop unroll fixes


> > There are three testcases for Zoltan's 3 patches.  Two of these testcases
> > are not regressions.  They fail at -O2 -funroll-loops in both gcc-2.95.2
> > and gcc-3.0.1.  The bugs should be fixed in mainline of course, but I see
> > no critical need to include them in gcc 3.0.2.

Oh, that only because I had one testcase catching 2 bugs.  How about this:

------------------- BEGIN ---------------
void abort(void);
int
sum(int m)
{
    int i;
    int s = 0;

    for (i = 0; i < m; i += 2)
	s += i;

    return s;
}

int
main(void)
{
    if (sum(15) != 56)
	abort();
    return 0;
}
------------------- END ----------------

That works on 2.95.2, but fails on 3.0.x.  In fact, that's the most
serious one, that's the one that coredumped the program I'm working
on.  I was quite busy with work recently, but I may have some more
time coming up.

Zoli


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