mirror of
https://github.com/ARMSX2/ARMSX2.git
synced 2026-08-24 16:50:16 -07:00
gsrunner's textual output was run-aggregate only: totals for the whole run plus min/avg/max frame time. A single spiky frame was invisible, and nothing was machine-readable. The -perf block is also useless on short runs, because PerformanceMetrics only updates about once a second -- an 8-frame replay reports nan/inf for every field. -stats-json <path> writes a per-frame series plus a run summary. Counters are exact per-frame deltas (update_stat now returns the delta it accumulates, so the series and the totals stay derived from one source), and frame_ms is measured directly rather than taken from PerformanceMetrics' window averages. Adds PerformanceMetrics::GetLastGPUTime for the same reason: OnGPUPresent already receives a per-frame GPU time but only accumulated it, and an averaged value hides the spike we are looking for. Percentiles (p50/p95/p99) and the worst-frame index are reported over drawn frames only; idle frames are present-only and would drag the distribution down. -set <Section/Key>=<value> overrides any setting generically. Every experiment previously needed a bespoke flag -- -accblend, -no-fb-fetch, -no-tex-barriers, -no-vs-expand, -backthread -- which is a flag per question and makes a sweep driver impossible. Verified equivalent: -accblend 3 and -set EmuCore/GS/accurate_blending_unit=3 produce identical counters, and the override demonstrably bites (accblend 0 -> 4 barriers, accblend 5 -> 365). Also prints the previously-accumulated-but-never-printed PS2-level draw count, adds prim accounting, and surfaces the new texture-cache hit/miss counters.