Bug 190039 - C++ crash on seemingly innocous code.
Summary: C++ crash on seemingly innocous code.
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc4
Version: 5
Hardware: All
OS: Linux
medium
urgent
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-04-26 21:33 UTC by Marcus Brubaker
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2006-04-27 08:50:20 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Preprocessor output from GCC (63.77 KB, text/plain)
2006-04-26 21:33 UTC, Marcus Brubaker
no flags Details
Test case (6.41 KB, text/plain)
2006-04-26 21:36 UTC, Marcus Brubaker
no flags Details


Links
System ID Private Priority Status Summary Last Updated
GNU Compiler Collection 27335 0 None None None Never

Description Marcus Brubaker 2006-04-26 21:33:08 UTC
Description of problem:
GCC chokes on some C++ code.

Version-Release number of selected component (if applicable):
gcc-c++-4.1.0-3

How reproducible:
Every time.

Steps to reproduce:
Compile attached source with the following command:
        g++ -c nmtest.cpp -funroll-loops -O2 -o nmtest.o

  
Actual results:
Crash with the following output:
nmtest.cpp: In function âint main()â:
nmtest.cpp:293: internal compiler error: in get_loop_body, at cfgloop.c:799
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
Preprocessed source stored into /tmp/ccGuOWMs.out file, please attach this to
your bugreport.


Expected results:
Compiled code.

Additional info:
This is using ccache but I don't expect that it has anything to do with this.  I
have wiped the cache and rebuilt from scratch with the same results.

I will attach some code in a follow up comment.  The preprocessor output is
attached here.

Comment 1 Marcus Brubaker 2006-04-26 21:33:08 UTC
Created attachment 128274 [details]
Preprocessor output from GCC

Comment 2 Marcus Brubaker 2006-04-26 21:36:41 UTC
Created attachment 128275 [details]
Test case

Comment 3 Marcus Brubaker 2006-04-26 21:38:30 UTC
The bug only triggers with combination of -funroll-loops and -O2.  Use only one
flag or the other on its own and the code compiles fine.


Comment 4 Jakub Jelinek 2006-04-27 08:50:20 UTC
Tracking upstream.


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