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]

qhull segfault if compiled with -O2


Hi.

I compiled qhull [1] with the following versions:

 gcc (GCC) 4.2.1
 gcc (GCC) 4.3.0 20070906 (experimental)

When compiled with -O it works:

 qhull/src$ make CFLAGS=-O -j > /dev/null; ./rbox 5 | ./qhull > /dev/null

but if I

 qhull/src$ touch qset.c

and recompile it with -O2 then qhull segfaults:

 qhull/src$ make CFLAGS=-O2 -j > /dev/null; ./rbox 5 | ./qhull
 Segmentation fault

If I touch the file again and recompile with -O2, but with an older
version of gcc

 gcc (GCC) 4.1.1 20070105 (Red Hat 4.1.1-52)

it works again.

[1] <http://www.qhull.org/download/qhull-2003.1.tar.gz>
[2] sha1 of qset.c is cb61179b8dee6b36a8cdc4cba0a6fcc6383e1771

Yes, I read `What we do not want' section, but it seems a single file
will be of no use. The bug repeats on different versions of Linux
(both 2.4 and 2.6).

-- 
Regards,
ASK


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