Bug 117773 - ICE compiling teTeX
Summary: ICE compiling teTeX
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc34
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-03-08 13:15 UTC by Tim Waugh
Modified: 2007-11-30 22:10 UTC (History)
0 users

Fixed In Version: 3.4.0-1
Clone Of:
Environment:
Last Closed: 2004-05-27 14:47:38 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
input.cc (158.39 KB, text/plain)
2004-03-08 13:16 UTC, Tim Waugh
no flags Details

Description Tim Waugh 2004-03-08 13:15:31 UTC
Description of problem:
ICE during tetex compilation.

Version-Release number of selected component (if applicable):
gcc34-3.4.0-0.6

How reproducible:
100%

Steps to Reproduce:
1. g++34 -O2 -c input.cc
  
Actual results:
GlobalParams.cc: In member function `void
GlobalParams::parseFile(GString*, FILE*)':
GlobalParams.cc:426: 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.
Preprocessed source stored into /tmp/ccdJyp5G.out file, please attach
this to your bugreport

Additional info:
Not triggered with -O1.

See attached input.cc.

Comment 1 Tim Waugh 2004-03-08 13:16:12 UTC
Created attachment 98368 [details]
input.cc

Comment 2 Jakub Jelinek 2004-03-08 22:45:07 UTC
Simplified into:
// { dg-do compile }
// { dg-options "-O2" }

extern char *foo (char *, int);

struct A
{
  int i;
  void bar (char *);
};

struct B
{
  B ();
  void baz (void *);
};

struct C
{
  C (const char *, int);
};

void
A::bar (char *a)
{
  B *b;
  char *p1, *p2 = a + 512;

  while (foo (a, 511))
    {
      b = new B ();
      p1 = a;
      while (*p1)
        {
          b->baz (new C (p1, p2 - p1));
          p1 = *p2 ? p2 + 1 : p2;
        }
    }
}

Both this testcase and your original testcase don't ICE in gcc-c++-3.4-0.3 though,
so it is apparently something newly introduced.  But certainly present
on vanilla gcc-3_4-branch as of today.

Comment 3 Jakub Jelinek 2004-03-11 10:14:30 UTC
Tracked upstream http://gcc.gnu.org/bugzilla/PR14527


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