Bug 48371 - g++ slow compile times
g++ slow compile times
Status: CLOSED CURRENTRELEASE
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-07-10 10:53 EDT by Need Real Name
Modified: 2010-06-14 10:20 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-06-14 10:20: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 2001-07-10 10:53:21 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.72 [en] (X11; U; Linux 2.2.14-5.0 i586)

Description of problem:
Compiles with g++ take significantly (4 times or more) longer than under RH
6.2.  The current gcc related patches in thesupport section of the RH web
site do not fix this bug.
Our experience seems to match those discussed in: 
http://gcc.gnu.org/ml/gcc-bugs/2000-08/msg00688.html
I see what may be a patch posted at:
http://www.geocrawler.com/mail/msg.php3?msg_id=4291993&list=356
Will RedHat be posting a patch for this bug soon?

How reproducible:
Always

Steps to Reproduce:
1.  On RH 6.2, g++ -c bug2.cpp.  Returns almost immediately (under 2
seconds).
2. On RH 7.1 (with faster cpu), g++ -c bug2.cpp.  Takes about 22 seconds.
3

Actual Results:  On RH 6.2, the compile finishes in under 2 seconds on an
AMD K6 400MHz system.
On RH 7.1, the compiles takes about 22 seconds on an AMD K6 400MHz system.
We can repeat a major compile time difference on systems with faster
processors also.
No compiler error is generated.

Expected Results:  We expected no difference in compile times.

Additional info:

Our "bug2" program is:
int main()
{
int var1, var2, var3, var4, var5, var6, var7, var8, var9, var10, var11;

var1 =
        ( (1 * (var2 == 1)) |
        (( (1 * (var3 == 4)) |
        (2 * (var3 == 5)) |
        (4 * (var3 == 1)) |
        (4 * (var3 == 3)) |
        (4 * (var3 == 2))) * (var2 == 2 )) |
        (1 * (var4 == 3)) |
        (1 * (var4 == 1)) |
        (1 * (var4 == 2)) |
        (1 * (var4 == 3)) |
        (3 * (var5 == 3 )) |
        (3 * (var6 == 1 )) |
        (3 * (var6 == 2 )) |
        (3 * (var6 == 3 )));

var7 =
        ( (1 * (var8 == 1 )) |
        (4 * (var8 == 4 )) |
        (( (1 * (var9 == 4)) |
        (2 * (var10 == 1)) |
        (3 * (var10 == 2)) |
        (4 * (var10 == 3))) * (var11 == 4)));
}
Comment 1 Matthew Miller 2007-04-10 15:06:48 EDT
I'm just going through and checking on old bugs -- if you still have interest,
could you recheck against the latest Fedora Core release? Thanks.
Comment 2 Jakub Jelinek 2010-06-14 10:20:11 EDT
Compiles immediately with g++ 4.4.

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