[build2] LTO and parallelization with build2
mkrupcale at matthewkrupcale.com
Fri Aug 7 13:22:58 UTC 2020
On Fri, Aug 7, 2020 at 4:46 AM Boris Kolpackov <boris at codesynthesis.com> wrote:
> Matthew Krupcale <mkrupcale at matthewkrupcale.com> writes:
> > [...] (by default, m=32) [...]
> CPUs with more than 32 hardware threads are not that uncommon these
For some reason when I was browsing the GitHub GCC sources, it led me
to look at an older revision of gcc/params.def. lto-partitions default
was bumped to 128, and lto-partitions is now set in
In any case, I think that in addition to translating -flto=auto or
-flto=n (with n>N) to -flto=N, where N is the number of available
hardware threads, we may have to also set --param lto-partitions=m,
where m>N. I'm not entirely sure what the right value for m is
compared to the number of threads. m=N+1? m=2*N? For reference, here
is the original discussion on WHOPR partitioning.
> In any case, I've added the scheduler API to allocate extra active
Oh that was fast.
> What's left is to translate -flto=auto. Would you like to take
> a stab at it? I could give you some pointers if you are interested.
Yeah, I might give it a try this weekend, and pointers are always appreciated.
More information about the users