Windows Vista Beta | WinVistaBeta.com - Message | Multi-Core Build and File-to-Build-Tool Dependency - VS2008

July 04, 2008  
Subject: Multi-Core Build and File-to-Build-Tool Dependency - VS2008
Group: microsoft.public.vstudio.general
Date: 4/30/2008 9:09:05 PM
From: "Kevin Frey" [Email Address Protection]

I have a problem with getting a correct multi-core build under VS2008 on a
Quad Core machine, using the IDE.

We have 40 projects in our solution. 2 of these projects are for *Build
Tools*. All the necessary *project-level* dependencies are in place.

We have some files .tms, .tts, .tcs that are compiled by a Custom Build
Rule. These files generate header files .tmh, .tth, .tch. The TOOL which is
used to compile these files is PART OF THE SOLUTION. And therein lies my
problem.

When I start a full rebuild I can see multiple "nodes" of execution starting
up. Invariably one of the other projects tries to compile one of the .tms,
..tts, or .tcs files BEFORE the TOOL has been built (since they must come
early in the build order, as the .cpp files depend on them).

With a single thread, the build tool will be built before the other project
that depends on it, because the dependencies are at the project level and
the builds are granular to the project level (ie. with one thread the build
environment won't "interleave" building files between two projects), so we
get the right result.

With multiple threads, the project-level dependency on the build tool is
seemingly interpreted as a "link-time" dependency rather than an :"up-front"
project dependency.

Is there any way to get the right result?




Back