GCC 4.2 performance


#1

Has anyone experienced GCC 4.2 (default for 10.6) in XCode being much slower than 4.0? This isn’t a Juce question per-se, but the issue I’m having manifests at its worst while gcc is chomping on those huge amalgamated sources. I almost always switch my compiler to 4.0 for faster build times. But I’m wondering if there’s any disadvantage there, or if I’m the only one with this issue.


#2

It’s been happening on Snow Leopard.
http://www.rawmaterialsoftware.com/viewtopic.php?f=4&t=4731


#3

I don’t think using gcc 4.0 will be a problem, but it is always good to use newer version of gcc.


#4

I’ve not noticed any difference between compiler versions, but I do find that xcode sometimes gets itself into a stupid state when trying to compile the big amalgamated files, and starts allocating ridiculous amounts of memory, bringing the machine to a standstill for minutes.

This is easy to fix - just interrupt the build, do a ‘clean’, and try again, and it all works fine. I think they must have added some sort of incremental compilation logic that’s trying to be smart, but actually ends up making a complete mess of everything.


#5

Don’t use amalgamated files, you’ll never see this again.


#6

Funny I didn’t already know just cleaning and trying again would fix it. Still it’s an obnoxious feature of XCode (among countless others). But I am quite fond of the amalgamated juce files. It’s an easy way to keep my code revisions coupled to certain juce revisions, without needing to put all of juce under source control.


#7

Just a footnote to this - I think I tracked the problem down to “fix and continue”. If you turn that off, it all seems to work ok. I’ll make sure the option is disabled in the jucer-generated projects in future.