Bug 31168 - gcc crashes with: Internal error: Segmentation fault.
Summary: gcc crashes with: Internal error: Segmentation fault.
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: gcc
Version: 7.1
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: David Lawrence
URL:
Whiteboard:
: 31016 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2001-03-09 15:54 UTC by craigl
Modified: 2007-04-18 16:32 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2001-04-28 19:21:58 UTC
Embargoed:


Attachments (Terms of Use)
gcc crashed with internal error (686.32 KB, text/plain)
2001-04-27 21:13 UTC, V Lakshman
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2001:082 0 high SHIPPED_LIVE New version of GCC 2.96-RH available fixing several bugs 2001-06-14 04:00:00 UTC

Description craigl 2001-03-09 15:54:28 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.76 [en] (X11; U; Linux 2.2.14-5.0 i586)


i have been trying to compile the openh323 source code for a few days now. 
eventually, after working through all sorts of memory problems, i have
finally managed to get gcc to crash the way i saw it crash once.

i was just doing a normal compile, and i get the crash output listed in the
'actual results' area.

Reproducible: Always
Steps to Reproduce:
1. get pwlib_min_1.1pl19.tar.gz & openh323_1.1pl1.tar.gz from
http://openh323.org/bin/
2. untar in your home directory ( required for some reason )
then execute the following commands:
3. cd ~/pwlib/
4. make both
5. cd ~/openh323/
6. make opt

i get the crash when it is compiling h245_3.cxx
this is the fourth or fifth file though, and two of the prior ones take a
_very_ long time to compile ( > 9 hours on my p-100 w/ 64MB RAM ).

Actual Results: 
/usr/include/g++-3/iomanip.h: In method `void 
H245_H223AL1MParameters::PrintOn (ostream &) const':
/usr/include/g++-3/iomanip.h:56: Internal error: Segmentation fault.
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.
make[1]: *** [/home/craigl/openh323/lib/obj_linux_x86_r/h245_3.o] Error 1
make[1]: Leaving directory `/data/source/craigl/h323/openh323/src'
make: *** [opt] Error 2

Comment 1 craigl 2001-03-09 15:58:45 UTC
*** Bug 31016 has been marked as a duplicate of this bug. ***

Comment 2 Jakub Jelinek 2001-03-09 16:13:28 UTC
Can you please rerun the g++ command line on h245_3.cxx with the options which
result in the segfault with additional -save-temps -v options and attach here
h245_3.ii it creates (and mention the actual g++ command line used)?

Comment 3 V Lakshman 2001-04-27 21:13:08 UTC
Created attachment 16685 [details]
gcc crashed with internal error

Comment 4 V Lakshman 2001-04-27 21:15:22 UTC

I got a gcc crash when compiling a file (I compiled again with --save-temps and
have attached it to this bug report).

Note: the program compiles fine under the CVS g++-3.0 branch and is okay under
g++-2.95.  So, two possibilities:

 1. A problem in gcc that was fixed between 2.96 and 3.0
 2. A kernel/swap problem in RedHat 7.1

lakshman

Comment 5 V Lakshman 2001-04-27 22:01:47 UTC

I did some testing. I found that gcc would crash on the same non-comment line of
the
file __regardless of which line it was___ i.e. I commented out a block of code
just before the point gcc crashed with " #if 0 ... #endif " and sure enough,
gcc crashed immediately after the #endif.

Somehow, gcc can not handle the size of the file maybe? The RedHat 7.1 machine
I am building on has only 64MB memory.

lakshman


Comment 6 Jakub Jelinek 2001-04-28 19:21:53 UTC
No, the issue is related to old-style ABI mangling of
DimVal < 0 - so, 0 - mo, -1 - to, 0 - co >
(particularly -1 - to).
It does not happen on gcc-3.0 branch because it uses completely different mangling,
and does not happen in 2.95.x because the bug was introduced during development
after 2.95.x was branched off.
I made a patch which seems to work, will include it in gcc-c++-2.96-83.

Comment 7 Need Real Name 2001-07-23 08:34:00 UTC
Hi all,
   I've update the gcc to 2.96.85 following the instruction in redhat support,
   But I still encounter the segmentation fault while compiling mysql, can 
anyone tell me how to fix it? It can be compiled in redhat7.0 without error...
  Anthony
=====================================================================
c++ -DMYSQL_SERVER                      -
DDEFAULT_MYSQL_HOME="\"/usr/local/mysql\""                     -
DDATADIR="\"/usr/local/mysql/var\""                   -
DSHAREDIR="\"/usr/local/mysql/share/mysql\""                    -
DHAVE_CONFIG_H -I./../include                  -I./../regex                    -
I. -I../include -I.. -I.    -O3 -DDBUG_OFF   -fno-implicit-templates -c 
sql_parse.cc
sql_parse.cc: In function `void decrease_user_connections (const char 
*, const char *)':

c++: Internal error: Segmentation fault (program cc1plus)
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.
make[3]: *** [sql_parse.o] Error 1
make[3]: Leaving directory `/home/linux_package/mysql-3.23.38/sql'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/linux_package/mysql-3.23.38/sql'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/linux_package/mysql-3.23.38'
=========================================================================


Note You need to log in before you can comment on or make changes to this bug.