deb: record per-phase build timings, shown by pkh deb profile
Time every Phase the build flow announces through enter_phase — the chroot bootstrap (tarball download, extraction, finalization), the apt phases, patch application, the build and binary steps and the artifact retrieval — and land the ordered profile in the record's manifest of every run, failed builds included: their profile ends at the phase the error propagated out of. Timing rides the enter_phase choke point instead of new measurement sites, so a phase added later profiles itself. The manifest field is additive (serde default, skipped when absent), so older manifests keep loading without a schema bump. The coarse timings stay the source of the deb list columns: they measure the apt transactions themselves, where the profile measures whole phases. pkh deb profile renders a record's profile through the same read-only record discovery as pkh deb log — the newest record of the tree, or an id prefix as shown by pkh deb list — so record_for_log becomes the neutral find_record. Phase keys are storage names, distinct from the display labels; Phase::from_key turns them back and a test keeps both in sync.
This commit is contained in:
@@ -174,6 +174,11 @@ pkh deb list # the records of this tree: id, outcome,
|
||||
# dep-install and build times, age
|
||||
pkh deb log [-f] [<id>] # print a record's build log; -f follows a
|
||||
# live build
|
||||
pkh deb profile [<id>] # a record's per-phase timing profile: how
|
||||
# long the chroot bootstrap, each apt phase,
|
||||
# patch application, the build and binary
|
||||
# steps and the artifact retrieval took, with
|
||||
# their shares of the total
|
||||
pkh deb --no-ccache # build without the shared compile cache
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user