Red Hat Bugzilla – Bug 205730
Internal compiler error in c_expand_expr, at c-common.c:3830
Last modified: 2007-11-30 17:07:10 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:126.96.36.199) Gecko/20060728 Firefox/188.8.131.52
Description of problem:
When compiling specific C++ program that uses templates in class definitions the compiler produce an internal error.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.Compile the enclosed code
The enclosed code does not compile, but generates an internal error from the compiler.
The code compiles well on RedHat Enterprise Linux 4 (Update 4) with gcc-3.4.6-3
Created attachment 135832 [details]
Code that produce internal error
Created attachment 135877 [details]
Somewhat simplified source file that produces the same internal error
Created attachment 135878 [details]
Very similar code that produce another internal error
The attached code produces this error message:
$ g++ -c test1.cpp
test1.cpp: In function `void __static_initialization_and_destruction_0(int,
test1.cpp:24: Internal compiler error in find_function_data, at function.c:333
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/cck1Nk3p.out file, please attach this to
Created attachment 135970 [details]
fixes ICE in find_function_data, at function.c:333
Created attachment 135971 [details]
fixes ICE in c_expand_expr, at c-common.c:3830
Comment #4 appears to be the patch for PR 8564, whereas comment #5 is the patch
for PR 8511. Patches for PR 10158 and PR 10956 fix regressions introduced with
the patch for PR 8511, so it would probably be wise to bring in their
combination. Jakub, want me to put together a single combined patch?
Created attachment 139816 [details]
Combined patch that fixes the bugs
This bug is filed against RHEL 3, which is in maintenance phase.
During the maintenance phase, only security errata and select mission
critical bug fixes will be released for enterprise products. Since
this bug does not meet that criteria, it is now being closed.
For more information of the RHEL errata support policy, please visit:
If you feel this bug is indeed mission critical, please contact your
support representative. You may be asked to provide detailed
information on how this bug is affecting you.