Date: Mon, 06 Sep 2021 08:16:14 UTC
Jeremie, a few observations (from the POV of someone who builds current ~ once a month) On Mon, Sep 6, 2021 at 10:09 AM Jeremie Le Hen <firstname.lastname@example.org> wrote: > Hey, > > I want to build -CURRENT again from sources. It's been a long time > since I hadn't done that. I'm shocked by the compilation time. > > I started the whole thing on Friday night and Monday morning it's > still in stage 4.2 (building libraries). Through occasional glancing > at the screen over the weekend, it seems obvious to me that the > compilation time is utterly dominated by LLVM. Do you actually measure anything? have you looked into what your I/O is doing? How about swap? Compiling C++ seems > extremely CPU heavy and this is made worse by the fact LLVM is built > twice (once for build/cross tools, once for the actual world). > > So OK, my CPU is not the most powerful out there but it's still decent . > I didn't check the specs: how many cores does your box have, and how many are you actually using (-j N)? IME, htop gives a good idea of how busy the CPUs really are. > So I have a couple of questions coming to my mind: > 1. Is there any optimization I could benefit from? (I'm sure there's a > knob to use the existing compiler instead of building a > cross-compiler.) > look at the build man page (https://www.freebsd.org/cgi/man.cgi?build(7)) for some tips on how to configure your environment. 2. More generally, isn't this compilation time not considered as a > problem for developers? This seems to terribly slow down the iteration > time for people working on the build system. I wouldn't be surprised > if this drove people away from working on/improving that area. > >  > https://www.cpubenchmark.net/cpu.php?cpu=Intel+Core+i5-6260U+%40+1.80GHz&id=2671 > > Cheers, > -- > Jeremie Le Hen > jlh@FreeBSD.org > > regards Michael -- Michael Schuster http://recursiveramblings.wordpress.com/ recursion, n: see 'recursion'