Skip to content

present: measure latency only for observed frame origins - #1263

Open
Kadamitas wants to merge 1 commit into
ProjectLeonida:mainfrom
Kadamitas:fix/frame-origin-latency
Open

Kadamitas wants to merge 1 commit into
ProjectLeonida:mainfrom
Kadamitas:fix/frame-origin-latency

Conversation

@Kadamitas

@Kadamitas Kadamitas commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

Claimed in the coordination issue as: frame-origin latency

Depends on: #1198 touches the same frame timing function. Either change can land first.

What and why

A timeout can return a frame token with no observed origin event. Carry that distinction into presentation statistics so the frame still contributes to the interval and frame counts while origin latency includes only observed origins.

Tested

  • Built and ran the native frame pacer suite on Windows 11 x64 with GCC.
  • The timeout regression keeps both presentations and measures only the observed origin. A new test polls before the first origin, presents after it, and verifies that the early token does not enter the latency ring. The frame pacer suite passed on the Nov 27 rebase.

GPUs tested: n/a (CPU-only tests)

AI-assisted: yes

  • One topic with synthetic inputs and no game data.

@github-actions github-actions Bot added the needs rebase Conflicts with the base branch: rebase it on main label Nov 25, 2026
@PierreEbele

Copy link
Copy Markdown
Contributor

Reviewed 32fd2ea: built and ran frame_pacer_test on the branch and on main (Linux, g++); the extended scenario fails on main without the fix — it tests the right thing. Probed timeout-issued consecutive tokens (mixed, repeated, uncapped, stale out-of-order) on both trees: only the latency ring changes; token numbering, tick grid, interval stats and uncapped mode are unchanged. The branch conflicts with current main (merge-tree: issue_token_locked, one region) — main moved issuance to the shared FrameTokenSource and added the current_token_locked poll path, whose origin also needs an observed/unobserved decision when this is rebased. AI-assisted review.

Recommendation: Fix first

@Kadamitas
Kadamitas force-pushed the fix/frame-origin-latency branch from 32fd2ea to 5321de9 Compare November 27, 2026 18:56
@github-actions github-actions Bot removed the needs rebase Conflicts with the base branch: rebase it on main label Nov 27, 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.

2 participants