8 messages in com.perforce.jammingSMP (was [jamming] xxx already define...
FromSent OnAttachments
Paul Forgey11 Feb 2004 15:41 
Marco Pappalardo11 Feb 2004 19:26 
Alen Ladavac13 Feb 2004 00:11 
Paul Forgey16 Feb 2004 17:01 
Paul Forgey16 Feb 2004 17:19 
Alen Ladavac17 Feb 2004 09:18 
Alen Ladavac17 Feb 2004 09:21 
Anthony Heading22 Feb 2004 20:44 
Subject:SMP (was [jamming] xxx already defined in lib, ignoring second definition)
From:Paul Forgey (pau@metainfo.com)
Date:02/16/2004 05:19:34 PM
List:com.perforce.jamming

This has been known to unix developers for a long time, but there are no MS supplied development tools for NT that take advantage of this. On NT machines, we have noticed you can get around 15% faster builds (at least with our code) using -j2 on a single CPU, non hyperthreaded machine. Using -j3 cuts another 30-40% off the build time on a hyperthreaded machine. In fact, using number of CPU's (both real and hyperthreaded, or the product on SMP hyperthreaded machines) +1 seems to be about optimal. Unfortunately, the NT console doesn't deal well with multiple processes writing to it, so you may be able to read any errors that occur. And you can't redirect Jam's output from the compiler messages because as of MSVC 7.0, nothing is ever written to stderr. Probably best to use -d to turn off all of Jam's output and -q to keep Jam from continuing if there is an error. Then hope you aren't unlucky enough for more than one process to simultaneously have something say. But then you can't watch the progress. But then again writing server code on NT is always a compromise anyway.

Even on unix, Jam is superior to make in this area because Jam looks at everything as a whole. A make process, for example, could recurse into a subdirectory providing a dependency, all cpu's blazing, to take care of maybe one file while the entire build process waits for this. In Jam, the entire dependency tree is known ahead of time so all the cpu's are better tasked for the entire project. Sometimes you'll see different subprojects being built at the same time!

On Feb 13, 2004, at 12:11 AM, Alen Ladavac wrote:

From: "Paul Forgey" <pau@metainfo.com>

Add it to the very long list of stupid MS behaviors in their tools. (You should see the tricks I had to do just to get parallel builds working properly)

Do you use the parallel build on an SMP machine, or across different machines? I'm interested in making this work, on MS as well.

Thanks, Alen