[Bug c++/31502] New: gcc/g++ randomly seg faults, sometimes freezes the entire machine
ye dot patrick at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sat Apr 7 11:45:00 GMT 2007
Machine info:
CPU: AMD 4200+ (64 bit)
RAM: 3G DDR
OS info:
Type: Linux
Distro: Ubuntu Edgy 6.10
Kernel: 2.6.17-10-generic #2 SMP Tue Dec 5 22:28:26 UTC 2006 i686 GNU/Linu
Bit: 32 bit OS
Overview of the problem: gcc and g++ would frequently and randomly seg faults,
and this would sometimes freeze the machine and force the "reset" button to be
pressed.
Code on which these errors have occurred: mplayer 1.0pre8, Blender.
Example of compilation command that produces the error:
gcc -c -O3 -g -Wdeclaration-after-statement -Wall -Wno-switch
-DHAVE_AV_CONFIG_H -I..
-I/home/jingy/install/blender/cvs_new/blender/extern/ffmpeg/libavutil
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -DHAVE_AV_CONFIG_H
-DMOZ_NOT_NET snow.c -o
/home/jingy/install/blender/cvs_new/blender/obj/linux-glibc2.4-i386/extern/ffmpeg/libavcodec/snow.o
Output of the compiler:
---
snow.c: In function Âpred_mvÂ:
snow.c:1961: warning: suggest parentheses around + or - inside shift
snow.c:1962: warning: suggest parentheses around + or - inside shift
snow.c:1963: warning: suggest parentheses around + or - inside shift
snow.c:1964: warning: suggest parentheses around + or - inside shift
snow.c:1965: warning: suggest parentheses around + or - inside shift
snow.c:1966: warning: suggest parentheses around + or - inside shift
snow.c: In function Âencode_q_branchÂ:
snow.c:1994: warning: initialization discards qualifiers from pointer target
type
snow.c:1995: warning: initialization discards qualifiers from pointer target
type
snow.c:1996: warning: initialization discards qualifiers from pointer target
type
snow.c:1997: warning: initialization discards qualifiers from pointer target
type
snow.c: In function Âencode_q_branch2Â:
snow.c:2221: warning: initialization discards qualifiers from pointer target
type
snow.c:2222: warning: initialization discards qualifiers from pointer target
type
snow.c: In function Âdecode_q_branchÂ:
snow.c:2274: warning: initialization discards qualifiers from pointer target
type
snow.c:2275: warning: initialization discards qualifiers from pointer target
type
snow.c: In function Âpred_blockÂ:
snow.c:2497: warning: suggest parentheses around && within ||
snow.c: In function Âff_snow_inner_add_yblockÂ:
snow.c:2538: warning: left shift count is negative
snow.c: In function Âadd_yblock_bufferedÂ:
snow.c:2567: warning: unused variable ÂyÂ
snow.c:2567: warning: unused variable ÂxÂ
snow.c:2555: warning: unused variable ÂdstÂ
snow.c: In function Âadd_yblockÂ:
snow.c:2809: warning: initialization discards qualifiers from pointer target
type
snow.c:2821: warning: left shift count is negative
snow.c: In function Âpredict_slice_bufferedÂ:
snow.c:2896: warning: passing argument 5 of Âadd_yblock_buffered discards
qualifiers from pointer target type
snow.c: In function Âget_block_bitsÂ:
snow.c:3028: warning: initialization discards qualifiers from pointer target
type
snow.c:3029: warning: initialization discards qualifiers from pointer target
type
snow.c: In function Âget_block_rdÂ:
snow.c:3065: warning: unused variable ÂobmcÂ
snow.c: In function Âget_4block_rdÂ:
snow.c:3182: warning: passing argument 2 of Âadd_yblock discards qualifiers
from pointer target type
snow.c:3168: warning: unused variable Âb_heightÂ
snow.c: In function Âcommon_initÂ:
snow.c:3872: warning: assignment from incompatible pointer type
snow.c:3872: warning: assignment from incompatible pointer type
snow.c:3873: warning: assignment from incompatible pointer type
snow.c:3873: warning: assignment from incompatible pointer type
snow.c:3874: warning: assignment from incompatible pointer type
snow.c:3874: warning: assignment from incompatible pointer type
snow.c:3875: warning: assignment from incompatible pointer type
snow.c:3875: warning: assignment from incompatible pointer type
snow.c: At top level:
snow.c:1327: warning: Âspatial_compose53i defined but not used
snow.c:1494: warning: Âspatial_compose97i defined but not used
snow.c: In function Âget_dcÂ:
snow.c:3021: 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.
For Debian GNU/Linux specific bug reporting instructions,
see <URL:file:///usr/share/doc/gcc-4.1/README.Bugs>.
The bug is not reproducible, so it is likely a hardware or OS problem.
make[3]: ***
[/home/jingy/install/blender/cvs_new/blender/obj/linux-glibc2.4-i386/extern/ffmpeg/libavcodec/snow.o]
Error 1
make[2]: *** [all] Error 1
make[1]: *** [all] Error 1
make: *** [all] Error 1
---
The output of the preprocessor (snow.i) can be downloaded from:
http://www.csse.unimelb.edu.au/~jingy/download/snow.i
Sometimes these errors would be immediately followed by a kernel warning
stating some memory protection has failed. Sometimes these errors would be so
severe that no other processes can be run.
Please feel free to contact me for further information.
Thanks a lot.
Patrick
--
Summary: gcc/g++ randomly seg faults, sometimes freezes the
entire machine
Product: gcc
Version: 4.1.2
Status: UNCONFIRMED
Severity: blocker
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ye dot patrick at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31502
More information about the Gcc-bugs
mailing list