feat(perf): fly scenarios N times and report median and range (#295) #306
No reviewers
Labels
No labels
agent
agent:ci
agent:done
agent:failed
agent:needs-input
agent:refined
agent:refining
agent:running
agent:shipped
agent:skip
autonomous
autopilot
driven
local
plan
proposal
qa
qa-gap
research
retro
ship
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jeroen/cartopolis!306
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/295-perf-repeat"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Requested by Jeroen
Closes #295. Built unattended overnight. Not merged; merging is up to you.
What it does
Before this,
cargo perfmeasured each scenario once. The new--repeat Noption (default 1) flies each scenario N times in one launch, taking them in turn (a b a b). The report then has one entry per scenario and phase, and each number in it is a{runs, min, median, max}range instead of a single reading. Each individual flight still appears in theperf windowlog lines, and a newperf summaryline gives frame time and fps as median (min..max).--repeat 0, and--repeatwithout--perf, are refused at startup.--repeat 1gives min = median = max and keepsperf-<name>.png. Repeated flights writeperf-<name>-r<n>.png.runssays how many. It is never counted as zero.docs/notes/performance-suite.mdrecords these choices, plus one caveat: a repeat'sloadwindow starts from a warm cache.Checked
perf.rs: median of an odd and even count, a single flight, missing numbers, window order, merging render passes, and the flight order and picture names.cargo perf --only orbit --repeat 3here, on the container's CPU renderer: 2 windows, each withruns: 3,meta.repeat: 3, and three pictures. The steady frame time came out as311.9 (305.8..359.7), which matches the threeperf windowlines. The firstloadtook 334 frames and the two repeats 33 each, which is the warm-cache caveat in the note. (These timings are from a CPU renderer and say nothing about the client itself.)cargo perf --only orbit:runs: 1and min = median = max everywhere, and it still writesperf-orbit.png.verify-branchis green one486d02: format, tests, smoke-orbit, smoke-phone, wasm and android.Heads-up
The report format changes. Nothing outside the crate reads it, but the unmerged
feat/301-perf-baseline-diffbranch (#301) compares reports in the old format, so it needs rebasing onto this before it can land.`cargo perf` measured each scenario once and reported that reading as the value. Every result docs/notes/performance-suite.md has had to withdraw was one such sample differenced against another, and the render survey recorded a within-group spread wider than every between-group difference it wanted. `--repeat N` (default 1) flies the selected scenarios N times in one launch. The report's `windows` is now one `WindowSummary` per (scenario, phase), each numeric column a `Stat { runs, min, median, max }`; the individual flights stay in the `perf window` log lines and a `perf summary` line per window gives frame time and fps as median (min..max). `meta.repeat` records N. Decisions, applying value 1 (measured beats plausible — a median with its spread beside it is the difference between a measurement and a coincidence): - Round-robin (a b a b), not blocked (a a b b): the drift worth exposing is the shared box, and blocked repeats attribute a slow patch to one scene. - Even-n median is the mean of the middle two, so a median recomputed by hand from the log lines matches the JSON. - A column absent in some flights aggregates over the rest (`Stat::runs` says how many); absent in all, it stays absent — never zero. - `--repeat 1` keeps `perf-<name>.png`; repeats write `perf-<name>-r<n>.png`. - `--repeat 0`, and `--repeat` outside `--perf`, are refused at startup. A repeat's `load` window is warm (tiles cached in memory and on disk), so its median describes a re-teleport; that caveat is in the note. The report shape changes, which nothing outside the crate reads; the unmerged feat/301-perf-baseline-diff branch diffs the old shape and will need rebasing onto this.e486d02efd4e067c0370