Re: Build slowdown with 4 processors vs. 2 or 1?
Re: Build slowdown with 4 processors vs. 2 or 1?
- Subject: Re: Build slowdown with 4 processors vs. 2 or 1?
- From: Jim Wintermyre <email@hidden>
- Date: Fri, 8 Dec 2006 09:34:51 -0800
At 12:29 AM -0600 12/8/06, Syd Polk wrote:
On Dec 7, 2006, at 11:47 PM, Jim Wintermyre wrote:
Here's a weird one. In one of my projects, when I build in XCode
on the Mac Pro, it grinds to a halt after 4 files. There is a
flurry of disk activity, and hardly any CPU activity. Top seems to
indicate a lot of swapping going on. This goes on for around a
couple minutes. What's weird is that if I set the number of
processors to 2 or 1, the problem goes away. The entire project
builds in less than 20 seconds, and the CPU load is pegged pretty
much the entire time, which is what I'd expect. Any ideas what
could be going on here? Any settings I could tweak?
Thanks,
Jim
How much RAM do you have? You need double the physical RAM for 4
compiles as your need for two.
1 GB. The weird thing is that this is only happening with *one* of
my plugin projects. All the other ones are fine w/4 processors
enabled. They all use the same precompiled header, and are all set
up the same; the only difference is the actual plugin source files.
At 10:39 PM -0800 12/7/06, Chris Espinosa wrote:
We see this sometimes with processor scaling in Mac OS X. gcc maps
in the precompiled header into each process as a private write file,
then writes to it, forcing the kernel to do a copy-on-write
operation each time. If you have 4 copies of gcc running
simultaneously all mapping in the same precompiled header file and
trying to write to private copies of it, the kernel can get
saturated with the copy-on-write requests.
So after all that work to get your precompiled headers coherent, you
may be amazed to find that that's the cause of the slowdown when
scaling up to more processors.
Would this still make sense in light of the fact that this is not
happening in any of my other plugin projects, which all use the same
precompiled header?
Thanks,
Jim
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden