Skip to content

Commit 655ddd8

Browse files
daniel-nolandclaude
andcommitted
ci: build the release test step on 8 cores
`check/release` ran on `lto_cores` (4) because its test archive's unbounded ThinLTO links could otherwise overlap past the runner's 20 GiB, and still peaked at 22 GiB locally. With the archive's links bounded, the link step split from compilation and test binaries carrying line tables, its peak no longer depends on how many links overlap. Measured building the step's whole chain cold on 8 cores, one derivation at a time as CI does, summing every process of each build: dataplane-deps 74 s 6.2 GiB dataplane-tests-deps 98 s 4.9 GiB dataplane (ships: full debug info) 252 s 6.7 GiB dataplane-cli 26 s 1.4 GiB dataplane-init 51 s 2.3 GiB tests.all 650 s 12.4 GiB `tests.all` took 929 s and peaked at 22 GiB on 4 cores before this series. Give the step its own `release_test_cores`; the other jobs on `lto_cores` (doctests, sanitizers, coverage, the model checkers) were not measured with these changes and stay on 4. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Daniel Noland <daniel@githedgehog.com>
1 parent 7dd5782 commit 655ddd8

1 file changed

Lines changed: 23 additions & 1 deletion

File tree

‎ci.just‎

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,26 @@ export NEXTEST_TEST_THREADS := cores
4747
# Changing this forks nothing: `--cores` is deliberately outside the derivation hash, and
4848
# `nix path-info --derivation` returns the same `.drv` at 10, 4 and 1. It is a scheduling knob,
4949
# not a build input.
50+
#
51+
# Those numbers predate the test archive bounding its own links; see `release_test_cores`.
5052
lto_cores := "4"
5153

54+
# The `check/release` test step. Its test archive now bounds how many of its ThinLTO links run at
55+
# once (`LINK_SLOTS` in default.nix) and carries line-table debug info, so its peak no longer
56+
# depends on how many links happen to overlap. Measured building the step's whole chain cold on 8
57+
# cores, one derivation at a time as here, summing every process of each build every two seconds:
58+
#
59+
# dataplane-deps 74 s 6.2 GiB
60+
# dataplane-tests-deps 98 s 4.9 GiB
61+
# dataplane (ships: full debug info) 252 s 6.7 GiB
62+
# dataplane-cli 26 s 1.4 GiB
63+
# dataplane-init 51 s 2.3 GiB
64+
# tests.all 650 s 12.4 GiB
65+
#
66+
# against `tests.all` alone taking 929 s and peaking at 22 GiB on `lto_cores` before. The other
67+
# jobs on `lto_cores` were not measured with these changes and stay there.
68+
release_test_cores := "8"
69+
5270
[private]
5371
_lab-common := " docker_sock=/run/docker/docker.sock" + " oci_repo=ghcr.io" + " debug_justfile=" + debug_justfile
5472

@@ -59,6 +77,10 @@ _lab := "jobs=" + jobs + " cores=" + cores + _lab-common
5977
[private]
6078
_lab-lto := "jobs=" + jobs + " cores=" + lto_cores + _lab-common
6179

80+
# See `release_test_cores`.
81+
[private]
82+
_lab-release-test := "jobs=" + jobs + " cores=" + release_test_cores + _lab-common
83+
6284
[default]
6385
[private]
6486
@default:
@@ -70,7 +92,7 @@ check-fmt:
7092
just {{ _lab }} fmt --check
7193

7294
check-test profile:
73-
just {{ if profile == "debug" { _lab } else { _lab-lto } }} profile={{ profile }} test
95+
just {{ if profile == "debug" { _lab } else if profile == "release" { _lab-release-test } else { _lab-lto } }} profile={{ profile }} test
7496

7597
check-clippy profile:
7698
just {{ _lab }} profile={{ profile }} clippy

0 commit comments

Comments
 (0)