Skip to content

fix(present): pace the menu on the acquire again - #28

Merged
broslife merged 1 commit into
mainfrom
fix/menu-pacing
Nov 19, 2026
Merged

broslife merged 1 commit into
mainfrom
fix/menu-pacing

Conversation

@broslife

Copy link
Copy Markdown
Collaborator

Since #21 the menu paced on the vblank with one frame queued, like a stream. A tab change draws a few frames of 29 to 36 ms even at CPU 2091 (log 2026-11-19 01:29Z: cpu p99 ~6-7 ms, max 28.9 / 17.1 / 36.0 ms, 581 and 597 of 600 frames), and with one frame queued each of them repeats a refresh. v1.0.0 kept two frames queued and hid them.

  • Pace::set_streaming, called from Presenter::set_stream: only a stream paces on the vblank; the menu, the connect screen and a redial pace on the acquire.
  • A stream starts with the vsync event cleared and no drain or burst left from the menu's frames.
  • The stream's pacing, the late take, the GPU budget and the fila-antiga / sem-espera markers are unchanged.
  • presenter: … now says the menu goes by the acquire; the menu's present[10s] lines read on the acquire.

Tests: cargo test -p pf-nx-vk --lib pacing (new only_a_stream_paces_on_the_vblank), fmt and clippy clean.

To test on the console: switch tabs in the menu at stock clocks and with the clock raised; then a stream, checking present[10s] still reads on the vblank, taken late with 0 found a frame queued after the first window.

Lightening the tab change itself is a later change in pf-console-ui.

Paced on the vblank with one frame queued, every menu frame past the refresh repeated one: a tab change draws frames of 29 to 36 ms at CPU 2091, and the menu hitched where v1.0.0 did not. Only a stream paces on the vblank now; the menu keeps two frames queued, as v1.0.0 did. A stream starts with the vsync event cleared and no drain left from the menu's frames. The stream's pacing, the late take and the markers are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@broslife
broslife marked this pull request as ready for review November 19, 2026 02:37
@broslife
broslife merged commit cc5018d into main Nov 19, 2026
2 checks passed
@broslife
broslife deleted the fix/menu-pacing branch November 19, 2026 02:49
@broslife broslife mentioned this pull request Nov 19, 2026
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.

1 participant