| Thread overview | |||||||
|---|---|---|---|---|---|---|---|
|
June 11, 2015 dub : multiple dmd instances | ||||
|---|---|---|---|---|
| ||||
Hi all ! I wonder why there's no option to tell dub split files into groups of equal size and then run N instances of dmd ? I think it can greatly reduce compile time. | ||||
June 11, 2015 Re: dub : multiple dmd instances | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Temtaime | On Thursday, 11 June 2015 at 14:01:12 UTC, Temtaime wrote:
> Hi all !
> I wonder why there's no option to tell dub split files into groups of equal size and then run N instances of dmd ?
> I think it can greatly reduce compile time.
dub options are a bit hidden.
dub build --help
--build-mode=VALUE
Specifies the way the compiler and linker are invoked.
Valid values:
separate (default), allAtOnce, singleFile
--parallel Runs multiple compiler instances in parallel, if
possible.
| |||
June 11, 2015 Re: dub : multiple dmd instances | ||||
|---|---|---|---|---|
| ||||
Posted in reply to weaselcat | On Thursday, 11 June 2015 at 14:07:10 UTC, weaselcat wrote:
> On Thursday, 11 June 2015 at 14:01:12 UTC, Temtaime wrote:
>> Hi all !
>> I wonder why there's no option to tell dub split files into groups of equal size and then run N instances of dmd ?
>> I think it can greatly reduce compile time.
>
> dub options are a bit hidden.
>
> dub build --help
>
> --build-mode=VALUE
> Specifies the way the compiler and linker are invoked.
> Valid values:
> separate (default), allAtOnce, singleFile
>
>
> --parallel Runs multiple compiler instances in parallel, if
> possible.
After rereading your question, that actually isn't exactly what
you were asking for. Sorry for the noise, I need my coffee.
| |||
June 12, 2015 Re: dub : multiple dmd instances | ||||
|---|---|---|---|---|
| ||||
Posted in reply to weaselcat | On 2015-06-11 16:08, weaselcat wrote: > On Thursday, 11 June 2015 at 14:07:10 UTC, weaselcat wrote: >> --parallel Runs multiple compiler instances in parallel, if >> possible. > > After rereading your question, that actually isn't exactly what > you were asking for. Sorry for the noise, I need my coffee. Isn't that what the --parallel flag is for? -- /Jacob Carlborg | |||
June 12, 2015 Re: dub : multiple dmd instances | ||||
|---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On Friday, 12 June 2015 at 07:20:35 UTC, Jacob Carlborg wrote:
> On 2015-06-11 16:08, weaselcat wrote:
>> On Thursday, 11 June 2015 at 14:07:10 UTC, weaselcat wrote:
>
>>> --parallel Runs multiple compiler instances in parallel, if
>>> possible.
>>
>> After rereading your question, that actually isn't exactly what
>> you were asking for. Sorry for the noise, I need my coffee.
>
> Isn't that what the --parallel flag is for?
As far as I can tell he wants it broken down into equal-sized n chunks of files where n is the number of CPU cores available, and --parallel just runs each file in parallel.
I actually hadn't thought of that before, there might be a (big?) benefit from this as dmd is slow to parse per-file. Perhaps decide which files are in the chunks based on dependency analysis.
bye.
| |||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply