------- Comment #28 from volodyan at gmail dot com  2006-12-02 17:46 -------
(In reply to comment #27)
> I committed the patch that enables vectorization of strided accesses


Confirmed the bug on gcc-4.3/(Pentium-M)X86. Configured  as 
../gcc/configure   --enable-bootstrap --enable-languages=c
and built as
make BOOT_CFLAGS="-g   -msse2 -ftree-vectorize -O2" 

Bootstrap failed after wrong execution of the following loop from
cfgloopanal.c/dfs:

  printf("nvert= %d, nq in dfs=%d, post0=%d\n",g->n_vertices, nq, 
g->vertices[0].post);

  for (i = 0; i < g->n_vertices; i++)
    {
      g->vertices[i].component = -1;
      g->vertices[i].post = -1;
    }
 printf("post0=%d; i in dfs=%d\n", g->vertices[0].post, i);
[printf's added by me]

It appears that this loop, which is vectorized according to the vectorizer
dump, doesn't manage to initialize g->vertices[i].post = -1 - the second printf
outputs 0 instead of expected -1 leading to dfs falsely assuming that this
vertex is new and crashing later:

nvert= 10, nq in dfs=8, post0=0
post0=0; i in dfs=10
../../gcc/gcc/crtstuff.c: In function ‘__do_global_dtors_aux’:
../../gcc/gcc/crtstuff.c:265: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
make[3]: *** [crtbegin.o] Error 1
make[3]: Leaving directory `/Develop/mainline/build/gcc'
make[2]: *** [all-stage2-gcc] Error 2
make[2]: Leaving directory `/Develop/mainline/build'
make[1]: *** [stage2-bubble] Error 2
make[1]: Leaving directory `/Develop/mainline/build'
make: *** [all] Error 2
lnx-toshiba:/Develop/mainline/build #


Vladimir 


-- 


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

Reply via email to