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

[Bug optimization/11841] [3.3 Regression] The code compiled with -funroll-loops crashes


------- Additional Comments From reichelt at igpm dot rwth-aachen dot de  2004-03-30 21:57 -------
Subject: Re:  [3.3 Regression] The code compiled with
 -funroll-loops crashes

On 30 Mar, bangerth at dealii dot org wrote:
> 
> ------- Additional Comments From bangerth at dealii dot org  2004-03-30 21:43 -------
> Hm, Volker, you access d[1+1]=d[2] when d has only two elements. Was  
> this intentional, meaning that you want to make the point that only with  
> certain flags we segfault, or was this an oversight?  

Argghh! Stupid mistake on my part. I just went too far reducing the
testcase. But here's a corrected one: It *hangs* when compiled with
-O2 -funroll-loops:

=================================================
int main()
{
    double d[6];
    int i, j;

    for (i=0; i<4; ++i)
      for (j=0; j<3; ++j)
	d[i+j] = 0;

    return (int)&i;
}
=================================================

Sorry for the confusion.




-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11841


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