Skip to content

Fix: Drive Windows frame time from the monotonic clock (PR-3, #69) - #588

Merged
b-re-w merged 1 commit into
developfrom
feat/69-kn-windows-frame-clock
Nov 12, 2026
Merged

b-re-w merged 1 commit into
developfrom
feat/69-kn-windows-frame-clock

Conversation

@b-re-w

@b-re-w b-re-w commented Nov 12, 2026 •

Copy link
Copy Markdown
Member

Refs #69

Both Windows renderers take each frame's time from the monotonic clock (shared WindowFrameTime helper) instead of adding 16 ms per painted frame, so animations run at real speed at 120/144 Hz.

Verified: ./kotlin test -m desktop WindowFrameTimeTest 4/4 (local builder); Windows x64 Kotlin/Native static renderer and the GraalVM Windows smoke test built and ran with it in dispatched run 43315954332 (batch with #590/#598). The GraalVM Win32 window moves to the fork's graalvm-windows module in #614, which closes #69.

Both Windows renderers stepped a 16 ms counter per frame, so animations
ran ahead of real time at 120/144 Hz. The native image window
(desktop/src/Win32Window.kt) and the Kotlin/Native window and backend
(windows/src) now share WindowFrameTime, which reads the monotonic
clock and stays strictly increasing. Covers the PR-3 criterion that
frame_time_nanos is the monotonic nanosecond clock.
@b-re-w
b-re-w marked this pull request as ready for review November 12, 2026 23:46
@b-re-w
b-re-w merged commit 3aab6ae into develop Nov 12, 2026
10 of 19 checks passed
@b-re-w
b-re-w deleted the feat/69-kn-windows-frame-clock branch November 12, 2026 23:46
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