Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Programming IT Technology

A Review of GCC 4.0 429

ChaoticCoyote writes " I've just posted a short review of GCC 4.0, which compares it against GCC 3.4.3 on Opteron and Pentium 4 systems, using LAME, POV-Ray, the Linux kernel, and SciMark2 as benchmarks. My conclusion: Is GCC 4.0 better than its predecessors? In terms of raw numbers, the answer is a definite "no". I've tried GCC 4.0 on other programs, with similar results to the tests above, and I won't be recompiling my Gentoo systems with GCC 4.0 in the near future. The GCC 3.4 series still has life in it, and the GCC folk have committed to maintaining it. A 3.4.4 update is pending as I write this. That said, no one should expect a "point-oh-point-oh" release to deliver the full potential of a product, particularly when it comes to a software system with the complexity of GCC. Version 4.0.0 is laying a foundation for the future, and should be seen as a technological step forward with new internal architectures and the addition of Fortran 95. If you compile a great deal of C++, you'll want to investigate GCC 4.0. Keep an eye on 4.0. Like a baby, we won't really appreciate its value until it's matured a bit. "
This discussion has been archived. No new comments can be posted.

A Review of GCC 4.0

Comments Filter:
  • by Anonymous Coward on Monday May 02, 2005 @12:45PM (#12408863)
    Well clearly the problem is that you compiled GCC 4.0.0 with GCC 3.4.3! What I did was go through the GCC 4.0 source code in two seperate windows, fire up hexedit in another, and go through line by line "compiling" GCC 4.0 with the GCC 4.0 source, in my head. I wouldn't recommend doing this with -funroll-loops, my hands started cramping up.

    Or you could wait to compile 4.0 until the 3.0 branch makes it to 3.9.9, then it will be close enough anyway. YMMV, people say I give out bad advice, go figure...
  • by Anonymous Coward on Monday May 02, 2005 @12:51PM (#12408943)
    "Like a baby, we won't really appreciate its value until it's matured a bit."

    Does this mean I have to wait until it's 18?
  • by Tim Browse ( 9263 ) on Monday May 02, 2005 @12:53PM (#12408977)
    Like a baby, we won't really appreciate its value until it's matured a bit.

    Is that what you say to new parents? :-)

  • by jmcneill ( 256391 ) on Monday May 02, 2005 @12:54PM (#12408983) Homepage
    Where are the screenshots?
  • by Martin Blank ( 154261 ) on Monday May 02, 2005 @12:55PM (#12408995) Homepage Journal
    Generally yes, although you'll only have to wait until 16 in some states.
  • by Stiletto ( 12066 ) on Monday May 02, 2005 @12:57PM (#12409031)
    If you really, positively need an extra 5% performance, you might as well just buy a computer that's 5% faster.

    You work at Microsoft, right? No? Intel?
  • by discordja ( 612393 ) on Monday May 02, 2005 @01:01PM (#12409087)
    I can see how that'd throw you off since it's May 2. :)
  • by Laxitive ( 10360 ) on Monday May 02, 2005 @01:02PM (#12409099) Journal
    "Like a baby, we won't really appreciate its value until it's matured a bit."

    Seriously, this is why I don't appreciate babies. At least after about 4 or 5 years, they're useful for mild manual labour. Sure they'll complain and cry, but all you gotta do is tie their dishwashing to the number of fish heads they're allotted that week. Works pretty well, I gotta say. Anyway, at least they're not a net productivity drain like babies are.

    Anyway, what I mean to say is: from your description, it looks like I'll be staying away from GCC 4 for a while, too. Goddamn babies.

    -Laxitive
  • by shreevatsa ( 845645 ) <shreevatsa.slash ... m minus caffeine> on Monday May 02, 2005 @01:07PM (#12409155)
    The worst part is that they now say that the
    <?
    ,
    >?
    ,
    <?=
    and
    >?=
    operators are deprecated, and will be removed. Damn, I liked them so much. Sure, they weren't part of the standard, and only a GCC extension, but it's just so much more fun to say
    a = b <? c
    than to say
    a = min(b,c)
    or even
    a=b<c?b:c
    . The best use was saying
    a<?=b
    instead of the painful
    a=min(a,b)
    .
  • but then the gcc 4 you compiled with gcc 3.4.3 would produce tainted compilations, and the second 4.0.0 compilation would lean towards 3.4.3 because it was compiled with a compiler that was compiled by 3.4.3. You would have to then take the second compilation of 4.0.0 and compile 4.0.0 with it, at which point the similarity to 3.4.3 would make it somewhere along the lines of 3.7.0. If you continue to compile it, while it will never reach 4.0.0, it will approach closely enough that for all intents and purposes, it will be 4.0.0. The forumula is as follows:

    V3-V1~2(V3-V2)

    where V1 was used to compile V2, and V2 was used to compile V3.
  • Like a baby (Score:4, Funny)

    by Anonymous Coward on Monday May 02, 2005 @01:25PM (#12409395)
    Like a baby, we won't really appreciate its value until it's matured a bit.

    "Come here son. Did you know your mother and I almost decided to not keep you when you were born? You were just a baby at the time, you didn't seem to have any value. I mean, seriously, what use is there for a baby? I'm glad we didn't make that mistake.
    Now go play outside and don't come back before dinner time, and pick up the trash when you leave."
  • by GnuPooh ( 696143 ) on Monday May 02, 2005 @01:32PM (#12409484) Homepage
    I don't wanna read the review it reveals the ending or something. I mean what good is a compiler without some big unexpected surpises?
  • by Gannoc ( 210256 ) on Monday May 02, 2005 @01:36PM (#12409542)
    Like a baby, we won't really appreciate its value until it's matured a bit.

    Are you kidding? Babies are worth $15,000-$20,000 easily, even if they're female. Once e-Bay stops being a bunch of pussies and we get some open bidding started, I expect their value to go up even higher.


    Once again, we see that the ./ editors have no idea what they're writing about.

  • Re:Expected (Score:5, Funny)

    by markov_chain ( 202465 ) on Monday May 02, 2005 @01:48PM (#12409765)
    Is it that surprising that a Gentoo user thinks of compiling time as the performance metric? :)
  • by Anonymous Coward on Monday May 02, 2005 @02:00PM (#12409901)
    So I've spent the 2 hours and made all the algorithms logaritmic; Indeed I've got 500% performance. Now the program takes 10 seconds while before it took 50. So now, let's find the best compiler settings to get that extra 5% and do it in 7.23secs.

    But, noooo. Pclminion claims that if I spend another two hours I can get an extra 500%. So I'll bring it down to 2 seconds. And then, I can spend another 2 hours and get another 500% speed up and get it done to 0.4 secs. According to this logic I can optimize everything to run in instant time.
  • Kids running Gentoo delude themselves into thinking that omitting the frame pointer on compiles is going to make a massive difference in terms of performance, and fail to remember it makes bug hunting far more difficult when applications crash.

    Gentoo? Crash? No way, dude. It, like, never crashSegmentation fault.

  • Re:Expected (Score:3, Funny)

    by lpp ( 115405 ) on Monday May 02, 2005 @02:13PM (#12410064) Homepage Journal
    GCC 4.0.0 can't be all that bad. After all, that's one less Gentoo user I have to listen to go on about how awesome their uber-tweaked system is.
  • Users?? (Score:5, Funny)

    by bobbuck ( 675253 ) on Monday May 02, 2005 @02:18PM (#12410131)
    Does Gentoo have users? I though they only had installers.
  • by m50d ( 797211 ) on Monday May 02, 2005 @02:24PM (#12410216) Homepage Journal
    Dude, when did you ever see "Segmentation fault" sent over the network? If you're going to use that old joke at least do it r#i*&$£!"^ NO CARRIER
  • by shreevatsa ( 845645 ) <shreevatsa.slash ... m minus caffeine> on Monday May 02, 2005 @02:30PM (#12410284)
    I don't get it. I was very serious when I wrote that, still this comment has 60%Funny, and even 20%Troll.
    In case you were wondering why anyone would want to use a=min(a,b), you really haven't programmed enough. To take a simplistic example, how would you find the largest integer in an array? (Sure, you can just #include , then say *max_element(a,a+N) and be done with it, but let's suppose you don't want to do that...)
    Well, the way to do it would be to write a loop like this:
    int largest = 0;
    for(int i=0;i<N;++i)
    largest=max(largest,a[i]);
    I really think it's faster and better to code the last line as largest>?=a[i]. There is less unnecessary clutter.
    Oh well. I guess this comment will now lose all its Funny mod points, but what the heck.
  • No danger (Score:3, Funny)

    by SuperKendall ( 25149 ) * on Monday May 02, 2005 @03:25PM (#12411020)
    I don't get it. I was very serious when I wrote that, still this comment has 60%Funny, and even 20%Troll. ....
    Oh well. I guess this comment will now lose all its Funny mod points, but what the heck.


    To the contray, now it's even funnier.
  • by damiena ( 263598 ) on Monday May 02, 2005 @03:38PM (#12411202)
    AYNARD: It reads, 'Here may be found the last words of Joseph of
    Aramathea. He who is valiant and pure of spirit may find the
    Holy Grail in the Castle of Segmentation Fault'.
    ARTHUR: What?
    MAYNARD: '... the Castle of Segmentation Fault'.
    BEDEVERE: What is that?
    MAYNARD: He must have crashed while carving it.
    LAUNCELOT: Oh, come on!
    MAYNARD: Well, that's what it says.
    ARTHUR: Look, if he was crashing, he wouldn't bother to send it over the network
    'aaggggh'. He'd just print it!
    MAYNARD: Well, that's what's his comment says
    GALAHAD: Perhaps he was dictating.
  • by Heywood Jablonski ( 543761 ) on Monday May 02, 2005 @03:51PM (#12411356)
    The worst part is that they now say that the <? , >? , <?= and >?= operators are deprecated...

    That's because they were conflicting with the new gphp front-end.

  • by Anonymous Coward on Tuesday May 03, 2005 @03:26AM (#12417533)
    No, no no. To erase the taint you have to create antitaint.

    gcc40_by34 = gcc34.compile(gcc40.src());
    gcc34_by40 = gcc40_by34.compile(gcc34.src());

    gcc40_by34_by40 = gcc34_by40.compile(gcc40.src());
    gcc40_taintfree = gcc40_by34_by40.compile(gcc40.src());

    Then its just a series of compiles to apply the antitaint.
    Everybody knows that!

The hardest part of climbing the ladder of success is getting through the crowd at the bottom.

Working...