Skip to content

perf: add browser paint phase measurements#43

Merged
wolfiesch merged 2 commits into
LycaonLLC:mainfrom
wolfiesch:codex/browser-paint-measurement
Jul 18, 2026
Merged

perf: add browser paint phase measurements#43
wolfiesch merged 2 commits into
LycaonLLC:mainfrom
wolfiesch:codex/browser-paint-measurement

Conversation

@wolfiesch

@wolfiesch wolfiesch commented Jul 18, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • split the 10k-history browser benchmark into navigation, connection, transcript, real-list, and stable-paint phases
  • record renderer milestones inside the browser animation-frame loop, without Playwright polling delay
  • keep paint-only probing outside the existing mount metric and report the full instrumented scenario separately
  • document the measurement boundary and Playwright TestInfo timing trap

VPS sample

Five corrected runs on the same private Linux VPS produced medians of 520 ms from session click to transcript shell, 812 ms to the real list, and 840 ms to the stable painted tail. The original mount-assertion boundary was 2.95 s; the full instrumented scenario was 3.14 s.

Verification

  • pnpm check
  • node --test scripts/perf/perf.test.mjs
  • five-repetition VPS scripts/perf/ui.mjs run under Node 24

Copilot AI review requested due to automatic review settings July 18, 2026 11:12

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR enhances the pnpm perf:ui benchmark to emit additional, renderer-clock-based phase timings (navigation → connection → transcript visible → real list visible → stable paint) alongside the existing end-to-end Playwright test duration, and documents how to interpret the new measurements.

Changes:

  • Extend the UI perf runner to collect per-phase samples from the browser benchmark and include them as separate metrics in the perf report.
  • Instrument the @soak 10k-history mount test to record phase timestamps (including a “two RAFs after tail visible” paint-stability sample) and optionally write them to a file.
  • Update performance documentation to explain the new UI phase breakdown and the measurement boundary.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
scripts/perf/ui.mjs Collects phase JSON output per repetition, validates samples, and emits additional per-phase metrics in the UI perf report.
e2e/remote-app.spec.ts Records renderer-clock timestamps for navigation/connection/mount/paint milestones and writes phase metrics when requested by the perf runner.
docs/PERFORMANCE.md Documents the new UI phase timings and clarifies interpretation (renderer clock, not physical display latency).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread scripts/perf/ui.mjs
Comment thread e2e/remote-app.spec.ts Outdated

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 91fc85dbc3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread e2e/remote-app.spec.ts Outdated
@wolfiesch
wolfiesch merged commit b9de905 into LycaonLLC:main Jul 18, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants