-CURRENT compilation time

From: Jeremie Le Hen <jlh_at_freebsd.org>
Date: Mon, 6 Sep 2021 10:08:30 +0200
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.  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 [1].

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.)
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.

[1] https://www.cpubenchmark.net/cpu.php?cpu=Intel+Core+i5-6260U+%40+1.80GHz&id=2671

Cheers,
-- 
Jeremie Le Hen
jlh_at_FreeBSD.org
Received on Mon Sep 06 2021 - 08:08:30 UTC

Original text of this message