[PR #7615] [MERGED] tools(pacing_bench): --vsync for frames paced by the display #7719

Closed
opened 2026-11-03 07:22:40 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/7615
Author: @ludovic111
Created: 11/2/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: tools/pacing-vsync


📝 Commits (1)

  • 9094d94 tools(pacing_bench): --vsync for frames paced by the display

📊 Changes

1 file changed (+9 additions, -0 deletions)

View changed files

📝 tools/pacing_bench.py (+9 -0)

📄 Description

🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself.

pacing_bench.py runs with VSync off (enableVsync:false). --vsync writes enableVsync:true into the game's options, and like --max-fps it raises if perf_bench's options stop writing the default. Use it in a window (--size).

With vanilla's defaults (VSync on, 120 FPS cap) on a 60 Hz display, frames wait for the display's refresh, as most players' frames do, and the swapchain's acquire waits show in the slow frames' spans (r_acquire). I used it for the measurement below, on main plus #7600, RD 16/32, 1920×1080 window, Mac mini:

scenario p50 p99 p99.9 1% low
fly16 RD 32 16.66 17.22 17.43 57.7
fly64 RD 32 16.66 17.69 19.36 55.1
elytra RD 32 16.66 18.52 23.4 47.0

Frames above 20 ms are r_acquire waits of 8–15 ms with ~0.1 ms of CPU: other sessions' GPU load on this Mac, not Horizon's work.

pr_ready

pr_ready (tools/pr_ready.py --quick on ludovics-mac-mini, against origin/main at 97dc1b553, 1 min 56 s)

Check Result
Scope ✅ 1 files, +9 −0
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 614 passed (1 min 56 s)
rustfmt ➖ no Rust change
clippy ➖ no Rust change
tests ➖ no crate touched
doc tests ➖ no crate touched
content root tests ➖ content root untouched
mod API up to date ➖ native hooks untouched
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ➖ 18 affected, to run in CI (--quick): anvil_turtle_egg, armor_stand_frost, armor_stand_turtle_egg, arrow_wind_charge, boat_authority, boat_paddle_reset, boat_submerged, dragon_contacts, dragon_render, enchantment_components, fishing_hook_entities, inline_object and 6 more
Label skip-release

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/7615 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 11/2/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `tools/pacing-vsync` --- ### 📝 Commits (1) - [`9094d94`](https://github.com/horizon-rust/horizon/commit/9094d94928a52783d6be18deb04a8a935857bebe) tools(pacing_bench): --vsync for frames paced by the display ### 📊 Changes **1 file changed** (+9 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `tools/pacing_bench.py` (+9 -0) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. `pacing_bench.py` runs with VSync off (`enableVsync:false`). `--vsync` writes `enableVsync:true` into the game's options, and like `--max-fps` it raises if perf_bench's options stop writing the default. Use it in a window (`--size`). With vanilla's defaults (VSync on, 120 FPS cap) on a 60 Hz display, frames wait for the display's refresh, as most players' frames do, and the swapchain's acquire waits show in the slow frames' spans (`r_acquire`). I used it for the measurement below, on main plus #7600, RD 16/32, 1920×1080 window, Mac mini: | scenario | p50 | p99 | p99.9 | 1% low | |---|---|---|---|---| | fly16 RD 32 | 16.66 | 17.22 | 17.43 | 57.7 | | fly64 RD 32 | 16.66 | 17.69 | 19.36 | 55.1 | | elytra RD 32 | 16.66 | 18.52 | 23.4 | 47.0 | Frames above 20 ms are `r_acquire` waits of 8–15 ms with ~0.1 ms of CPU: other sessions' GPU load on this Mac, not Horizon's work. ## pr_ready **pr_ready** (`tools/pr_ready.py --quick` on ludovics-mac-mini, against origin/main at 97dc1b553, 1 min 56 s) | Check | Result | | --- | --- | | Scope | ✅ 1 files, +9 −0 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 614 passed (1 min 56 s) | | rustfmt | ➖ no Rust change | | clippy | ➖ no Rust change | | tests | ➖ no crate touched | | doc tests | ➖ no crate touched | | content root tests | ➖ content root untouched | | mod API up to date | ➖ native hooks untouched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ➖ 18 affected, to run in CI (--quick): anvil_turtle_egg, armor_stand_frost, armor_stand_turtle_egg, arrow_wind_charge, boat_authority, boat_paddle_reset, boat_submerged, dragon_contacts, dragon_render, enchantment_components, fishing_hook_entities, inline_object and 6 more | | Label | `skip-release` | 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 07:22:40 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#7719
No description provided.