DUB build questions
Russel Winder via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sat Dec 20 00:36:03 PST 2014
On Sat, 2014-12-20 at 05:46 +0000, Dicebot via Digitalmars-d-learn wrote:
> On Saturday, 20 December 2014 at 04:15:00 UTC, Rikki Cattermole
> wrote:
> > > b) Can I do parallel builds with dub. CMake gives me Makefiles
> > > so I can
> > > make -j does dub have a similar option?
> >
> > No
>
> Worth noting that it is not actually a dub problem as much, it is
> simply not worth adding parallel builds because separate
> compilation is much much slower with existing D front-end
> implementation and even doing it in parallel is sub-optimal
> compared to "dump-it-all-at-once".
>From previous rounds of this sort of question (for the SCons D
tooling), the consensus of the community appeared to be that the only
time separate module compilation was really useful was for mixed D, C,
C++, Fortran systems. For pure D systems, single call of the compiler
is deemed far better than traditional C, C++, Fortran compilation
strategy. This means the whole "make -j" thing is not an issue, it
just means that Dub is only really dealing with the "all D" situation.
The corollary to this is that DMD, LDC and GDC really need to make use
of all parallelism they can, which I suspect is more or less none.
Chapel has also gone the "compile all modules with a single compiler
call" strategy as this enables global optimization from source to
executable.
--
Russel.
=============================================================================
Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder at ekiga.net
41 Buckmaster Road m: +44 7770 465 077 xmpp: russel at winder.org.uk
London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
More information about the Digitalmars-d-learn
mailing list