Boost logo

Boost-Build :

From: Juergen Hunold (juergen.hunold_at_[hidden])
Date: 2006-12-22 14:00:45


Hi Noel !

On Friday 22 December 2006 19:31, K. Noel Belcourt wrote:
> Hi,
>
> Does anyone know why bjam ignores the -jN option if the only targets
> to build are executables to link?

Yes.

> it serializes all the links even  
> though I asked for a parallel (-j2) build.

Well, -j2 is just mild parallel ;-))

> Has anyone seen this before or is this a known feature?

It is a feature, definetely.

A look at gcc.jam at line 535 reveals:

---
    # Serialize execution of the 'link' action, since
    # running N links in parallel is just slower.
    # For now, serialize only gcc links, it might be a good
    # idea to serialize all links.
    JAM_SEMAPHORE on $(targets) = <s>gcc-link-semaphore ;
---
which should make things clearer. 
This statement is especially true when doing -j10 and higher ;-))
Using our compile farm, I can use -j17 and believe me, having 17 linker 
instances  trying to link 17 different executable is no fun :-((. Been 
there the semaphore was added.  But you can try and remove it and 
measure if things go faster for you.
I think that running #number of processor linker instances on modern 
multi -core systems might be better, though. But not more, definetely.
But I think this is for 1.35. 
Yours,
Jürgen 
-- 
* Dipl.-Math. Jürgen Hunold  ! Ingenieurgesellschaft für 
* voice: ++49 511 262926 57  ! Verkehrs- und Eisenbahnwesen mbH  
* fax  : ++49 511 262926 99  ! Lister Straße 15
* juergen.hunold_at_[hidden]   ! www.ivembh.de

Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk