The planner's rule: a cold first sample is compared cold against cold. The creation rows ran in
five processes that each timed both runtimes, the new runtime first, so the driver's
process-wide setup fell on the new runtime's first pipeline and the old runtime's first samples
came after it, warm. Measured on the Iris Xe (job 48650, ms01 alone, both runtimes from the
harness at cb25e3a83e, five processes each): the old runtime's create_state/first was 5265.8 us
behind the new runtime in one process and 16732.8 us in a process of its own (0.315x);
device_first 0.167x, first_call 0.099x. The one-process ratio new/old 1.302 at first was a
cold-against-warm ratio; cold against cold it is 0.410.
Of the two forms the planner allowed, each runtime's own fresh process is the cheaper: the
harness does not change, and the extra five processes a leg runs take about a second each
(create_state's processes on the Iris ran in under one second). The other form, one unrelated
pipeline before either runtime in a shared process, would need harness code and leaves the
first samples process-warm, not cold. So each of the five rounds now runs `--runtime new` and
`--runtime old` in processes of their own, each on a fresh driver cache and store, the order
alternating from round to round (new first in rounds 1, 3 and 5); the first round's two outputs
are kept whole, the later rounds' first samples as before. The records, their names and the
budget's medians do not change.
Verified: the matrix's Python tests in the job named in the landing message (the harness-runs
test now pins the processes and their order).
Its jobs reserved 16 GiB for 60 minutes. Measured on the mini: a peak of 6.7 GiB and 29 s, 4m02s
and 3m45s a run (m3-max-48387, -48266, -48124); the longest cargo build of the 50 runs the
matrix keeps took 6m45s (29 crates compiled). 10 GiB is 1.5 times the peak, and 15 minutes over
twice the longest build, for a cold one. The minutes stay the floor of the measured sizing, and
a run that wants more RAM still runs again with twice its room, up to the default.
Verified: test_matrix (the sizing and retry tests at the new defaults).
The creation rows ran in five processes per runtime, all of the old runtime's before the new
runtime's, so a node or clock that moved between them moved one runtime's samples alone, an order
effect. Each of the five processes now times both runtimes, `--runtime new,old --only
'create_*'`, on its own fresh driver cache and store: a creation's first sample on the new runtime
is cold, and the old runtime's follows it on the same cache. FIRST_KEEP takes each sample's
runtime from its line. The median of five per runtime and every row, ceiling and floor stay.
Verified: test_matrix's harness-run test (five `new,old` creation processes, both runtimes'
samples kept once each) and test_results' creation test (FIRST_KEEP keeps the old runtime's
sample beside the new's and drops a GPU line); the Linux and Windows job scripts pass `bash -n`.
Two cards showed the noise the old runtime's frozen arm measures: the Iris Xe's frame moved 2.8x
between rounds, the UHD 630's about 2x between passes of one process. The leg timed each
runtime in a process of its own, one after the other, so a clock or a co-runner that moved
between them moved one runtime's times and not the other's. Now one process times both,
`harness --runtime new,old`: each workload runs on the new runtime, then on the old, so their
passes alternate on the GPU and the node as they are at that moment. The new runtime runs first
in each workload, so its first uses, the judged cold ones, compile before the old runtime's of the
same workload, as cold as in a process of its own. The process is the leg's one suite, `harness`;
a failure still names its runtime (`M2V-FAILED harness-<runtime>/<row>`). The creation rows keep
their five fresh processes per runtime, now alternating old and new; rows over their limits are
re-timed alone as before. No row, ceiling or floor changes, and the deterministic records are
untouched. The frozen arm's column (FROZEN_DRIFT) stays the check on it.
Verified: test_matrix's new test runs the leg's timing script against a stand-in harness: one
`new,old` process, the new runtime's warm run, the creation processes alternating, one suite whose
records hold both runtimes' rows once each. The Linux and Windows job scripts render and pass
`bash -n`.
A card the lab holds on more than one node now runs on each of them when the matrix config names
its node of record (`record_nodes`, card to node). The leg on that node is the card's leg of
record, named by the card as before. Each other node's is an extra leg, `card@node`, judged like
any leg and held to the card's ceilings, floors and variance rows (results.card_of): timing rows
are judged on both. An AMD extra leg selects its device by its card.
An extra leg named in `open_records` (leg to a one-line record) has an open record against its
card. A failed test there is listed with the record and not judged only if both hold:
- it failed with wrong bytes;
- the card's leg of record ran the same suite at the same commit and the test did not fail there.
Every other failure on that leg is judged like any other.
How wrong bytes are told, from the test's captured output after nextest's summary (parse_suite's
`wrong_bytes`):
- its status is FAIL; a TIMEOUT, a signal or a leak never counts;
- its output has Rust's `assertion `left == right` failed` with both sides, `left:` and `right:`,
lists of numbers (the bytes, words or texels read against those expected), so a compare of one
value, a count, does not count;
- no line names a device loss (DEVICE_LOST, device lost) or a validation message (VUID-,
Validation Error).
Any other output, a panic of another message included, is not wrong bytes, so it is judged.
Node names stay in the config, not here. The config this needs for the 3090s:
"record_nodes": {"10de:2204": <um870's node>}, "open_records": {"10de:2204@<ms01's node>": <the
record's line>}.
Verified: scripts/matrix/test_results.py and test_matrix.py pass at this commit in a potluck job
on msi. The new tests check that only an assertion of two lists of numbers reads as wrong bytes
(not a count compare, a device loss, a validation message, an unwrap or a timeout); that an extra
leg lists a wrong-bytes failure only where it passed on the leg of record, and judges the rest;
that an extra leg takes its card's limits; and that the plan makes a leg of record plus an extra
leg from `record_nodes` (and no leg of record when that node is away).
Every instance rt's device tests open goes through one helper, crate::tests::validation. It
enables VK_LAYER_KHRONOS_validation for its own test process through the loader's and the
layer's own variables (VK_INSTANCE_LAYERS; report flags error,warn, debug action log, one log
file per process). It checks that every device of the cfg's kind lists an active validation
tool (vkGetPhysicalDeviceToolProperties), so a run whose loader found no layer fails. Once the
instance is gone, it reads the log, prints each line with the test's name and fails on any
message. The 41 sites that called Instance::new go through it; the exit-handler test reads its
child's log, since the child's instance never drops. One test makes a deliberately invalid
call (a buffer of size 0, refused by the layer) and checks that its log holds exactly
VUID-VkBufferCreateInfo-size-00912.
The product keeps no layer code and no variable read. Its one change is a visibility:
Instance's shared state is pub(crate), so the helper waits, bounded, on a weak handle of it
until the instance is gone, and only then reads the log.
scripts/validation-layer makes the layer's directory, one version (1.4.363.0) on every leg, as
a carry: Linux's copied from a node whose pacman package is that version and unaltered,
Windows's from MSYS2's clang64 packages checked against the package database's SHA-256, and
macOS's from a Homebrew install at that version. scripts/matrix carries it to every job that
runs rt's device tests (GPU legs, lavapipe, the Windows host), points VK_LAYER_PATH at it, and
puts the layer's version in the leg's note. A job without the layer says so and points the
loader at none. The harness's timing jobs run without it.
Verified: the matrix's unit tests (48, two new ones run the layer's shell for real) and the
layer carry made. Builds and legs follow.
The UHD leg of matrix e060958855 lost its Windows build twice to memory:
45442 at 3 GiB (137), then the retry 45471 at 6 GiB (rustc-LLVM out of
memory, 137), and the leg failed with no tests run. The sizing took the
last three runs' peaks, incremental builds in a kept workspace that peak
far below a build of most of the tree, and a job short of RAM ran once more
only, at twice its room.
Now a job's RAM is 1.3x the largest peak of the last three runs that
started in a fresh workspace (each run records whether it did), else the
kind's default; minutes still follow the last three runs of either form.
A job short of RAM runs again with twice its room until it reaches the
kind's default (16 GiB for winbuild).
Verified: scripts/matrix tests, 39 OK, run locally. The new test_matrix.py
fails on the old code (it sized from incremental peaks and retried once:
dispatches 4 and 8 GiB, not 4, 8 and 16).