From: sterni <sternenseemann@systemli•org>
To: "depot@tvl.su" <depot@tvl.su>
Subject: Performance of 🦙 with C++ Nix and Lix
Date: Sat, 27 Dec 2025 17:06:56 +0100 [thread overview]
Message-ID: <a33e5366-bd9b-43a3-a3c9-ea34514bb85a@systemli.org> (raw)
Hello everyone,
I performed some benchmarks of various (versions of) Nix implementations
calculating the .drv path of //ops/pipelines/depot on nevsky. All IFD
store paths were prepopulated in the store and the Nix daemon was the
same in each case.
Hyperfine did 2 warmup runs and followed by 5 actual benchmark runs of
nix-instantiate -I depot=. -I store=/nix/store --show-trace \
--option restrict-eval true --option allowed-uris https:// \
-A ops.pipelines.depot
on depot r/9761. The results are as follows.
//3p/cppnix (r/9761) (~ C++ Nix 2.3)
Time (mean ± σ): 310.226 s ± 6.187 s [User: 257.286 s,
System: 42.878 s]
Range (min … max): 300.664 s … 316.956 s 5 runs
C++ Nix 2.31.2
Time (mean ± σ): 197.645 s ± 7.784 s [User: 212.113 s,
System: 36.639 s]
Range (min … max): 189.609 s … 208.111 s 5 runs
C++ Nix 2.32.3
Time (mean ± σ): 204.543 s ± 1.365 s [User: 192.059 s,
System: 39.068 s]
Range (min … max): 203.058 s … 206.042 s 5 runs
Lix 2.93.3
Time (mean ± σ): 209.785 s ± 15.477 s [User: 159.669 s,
System: 38.836 s]
Range (min … max): 188.076 s … 231.488 s 5 runs
As you can see, performance has improved a lot since Nix 2.3.18, at
least for our workload. Switching to Lix would probably make the most
sense if we were to switch as their goals are most aligned with our desires.
In general, performance between Lix and C++ Nix >= 2.31 is pretty much a
wash (at least it's not really possible to conclude much with just 5
runs). C++ Nix 2.31 outperforming 2.32 is sort of expected at the moment
(though according to Raito, we can expect this to be resolved in the
future). 2.32 should in theory use less memory which I haven't measured
at all, but would also be interesting to us as we recently (r/9688) had
to reduce pipeline eval parallelism due to memory demands.
~sterni
reply other threads:[~2025-12-27 16:07 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a33e5366-bd9b-43a3-a3c9-ea34514bb85a@systemli.org \
--to=sternenseemann@systemli$(echo .)org \
--cc=depot@tvl.su \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://code.tvl.fyi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).