Summary: | [4.3 Regression] GCC takes forever to compile a certain file | ||
---|---|---|---|
Product: | gcc | Reporter: | Frank Mehnert <frank.mehnert> |
Component: | tree-optimization | Assignee: | Richard Biener <rguenth> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | gcc-bugs, rguenth |
Priority: | P3 | Keywords: | compile-time-hog, memory-hog |
Version: | 4.3.1 | ||
Target Milestone: | 4.3.2 | ||
Host: | Target: | i?86-*-* | |
Build: | Known to work: | 4.2.4 4.4.0 | |
Known to fail: | 4.3.1 | Last reconfirmed: | 2008-06-09 13:02:04 |
Attachments: |
VBoxManage.cpp (preprocessed with -E -dD and compressed) from current VirtualBox SVN.
unincluded testcase |
Description
Frank Mehnert
2008-06-09 10:10:55 UTC
Created attachment 15740 [details]
VBoxManage.cpp (preprocessed with -E -dD and compressed) from current VirtualBox SVN.
If you compile this file with
g++ -c -o foo.o -O0 -fshort-wchar VBoxManage.cpp
it will be compiled successfully. It you compile it with
g++ -c -o foo.o -O1 -fshort-wchar VBoxManage.cpp
(gcc 4.3.1) the g++ compiler will loop forever (aborted after 5 minutes).
Seems to be "stuck" processing int handleModifyVM(int, char**, ComPtr<IVirtualBox, ComStrongRef>, ComPtr<ISession, ComStrongRef>) Confirmed. -fno-inline "fixes" it, but not -fno-tree-fre or -fno-tree-dominator-opts. --param max-fields-for-field-sensitive=0 fixes it (disabling SFTs and field-sensitive PTA) as well. Created attachment 15742 [details]
unincluded testcase
We can fix -O1 for 4.3. Subject: Bug 36474 Author: rguenth Date: Wed Jun 11 09:16:09 2008 New Revision: 136656 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=136656 Log: 2008-06-11 Richard Guenther <rguenther@suse.de> PR tree-optimization/36474 * opts.c (decode_options): Set max-fields-for-field-sensitive parameter to 100 for -O2, -Os and -O3. * params.def (max-fields-for-field-sensitive): Set default to zero. * doc/invoke.texi (max-fields-for-field-sensitive): Document defaults. * gcc.dg/tree-ssa/alias-15.c: Adjust testcase. Modified: branches/gcc-4_3-branch/gcc/ChangeLog branches/gcc-4_3-branch/gcc/doc/invoke.texi branches/gcc-4_3-branch/gcc/opts.c branches/gcc-4_3-branch/gcc/params.def branches/gcc-4_3-branch/gcc/testsuite/ChangeLog branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/tree-ssa/alias-15.c Fixed as far as possible. |