Bug 90708 - g++ aborts with error "Internal Compiler Error" on trivial program
g++ aborts with error "Internal Compiler Error" on trivial program
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
7.2
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-05-12 14:03 EDT by Need Real Name
Modified: 2007-04-18 12:53 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-05-13 16:52:11 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Need Real Name 2003-05-12 14:03:29 EDT
Description of problem:
On this system which has had no problem compiling programs in the past, I've 
started getting the following message today.

$ more ak1.cpp
#include <stdio.h>

int main ()
{
  printf ( "Hello World\n" );
}
$ g++ ak1.cpp

Internal compiler error: Error reporting routines re-entered.
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.
$

No further information was available, gcc works fine, only g++ is failing. 

$ g++ -v ak1.cpp
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.2 2.96-108.1)
 /usr/lib/gcc-lib/i386-redhat-linux/2.96/cpp0 -lang-c++ -D__GNUG__=2 -
D__EXCEPTIONS -v -D__GNUC__=2 -D__GNUC_MINOR__=96 -D__GNUC_PATCHLEVEL__=0 -
D__ELF__ -Dunix -Dlinux -D__ELF__ -D__unix__ -D__linux__ -D__unix -D__linux -
Asystem(posix) -D__NO_INLINE__ -Acpu(i386) -Amachine(i386) -Di386 -D__i386 -
D__i386__ -D__tune_i386__ ak1.cpp /tmp/ccn0BJSo.ii
GNU CPP version 2.96 20000731 (Red Hat Linux 7.2 2.96-108.1) (cpplib) (i386 
Linux/ELF)
ignoring nonexistent directory "/usr/i386-redhat-linux/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/include/g++-3
 /usr/local/include
 /usr/lib/gcc-lib/i386-redhat-linux/2.96/include
 /usr/include
End of search list.
 /usr/lib/gcc-lib/i386-redhat-linux/2.96/cc1plus /tmp/ccn0BJSo.ii -quiet -
dumpbase ak1.cpp -version -o /tmp/cc4fDw0C.s
GNU C++ version 2.96 20000731 (Red Hat Linux 7.2 2.96-108.1) (i386-redhat-
linux) compiled by GNU C version 2.96 20000731 (Red Hat Linux 7.2 2.96-108.1).

Internal compiler error: Error reporting routines re-entered.
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.
$



Version-Release number of selected component (if applicable):
gcc-c++-2.96-108.1

How reproducible:
Everytime on this machine, not sure how it got to be this way. It used to be 
just fine ...

Steps to Reproduce:
1. Unclear how you can reproduce this. I can't repro on a different machine.
2.
3.
    
Actual results:


Expected results:


Additional info:
I can't make this happen on a different machine. It is something to do with the 
current state of the machine and I suspect that if I reboot, it will fix itself.

Using strace, the following is seen.

read(3, "_restrict __ptr, size_t __size,\n"..., 4096) = 1686
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401c8000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401c9000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401ca000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401cb000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401cc000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401cd000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x401ce000
--- SIGSEGV (Segmentation fault) ---
open("/usr/share/locale/en_US/LC_MESSAGES/libc.mo", O_RDONLY) = -1 ENOENT (No 
such file or directory)
open("/usr/share/locale/en/LC_MESSAGES/libc.mo", O_RDONLY) = -1 ENOENT (No such 
file or directory)
--- SIGSEGV (Segmentation fault) ---
write(2, "\n", 1)                       = 1
write(2, "Internal compiler error: Error r"..., 160) = 160
write(4, "\t.file\t\"ak1.cpp\"\n\t.version\t\"01.0"..., 51) = 51
munmap(0x40171000, 4096)                = 0
_exit(33)                               = ?
Comment 1 Need Real Name 2003-05-12 15:50:36 EDT
After rebooting the system the problem has gone away. 
Comment 2 Jakub Jelinek 2003-05-13 16:52:11 EDT
This suggests your hardware is not in a good shape.

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