[GH-ISSUE #1333] [macOS] Benchmark stays capped at 144 FPS with VSync off and unlimited frame rate #366

Open
opened 2026-11-02 15:38:32 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @rdbtCVS on GitHub (Oct 22, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/1333

Observed behavior

The published benchmarks show Horizon on the Mac mini M4 Pro staying at approximately 144 FPS on a 144 Hz display despite VSync being off and the frame limit being unlimited. This occurs at both render distance 12 and 32, across the village, forest, ocean and mountain flights.

The website explicitly identifies the Mac results as capped at 144 FPS. The raw reports record conditions.vsync: false and conditions.offscreen: false; individual RD12 flights have median frame times around 6.94 ms, matching 144 Hz.

This is evidence of unexpected refresh-rate pacing, not proof that the VSync setting itself remains enabled.

Environment and evidence

The machine was running other jobs during the measurements, so controlled reruns are needed. This report is based on the published data and source inspection; it has not been independently reproduced on a Mac.

Expected behavior

With VSync off, Present Mode Auto/Immediate and an unlimited frame rate, rendering should not be capped to the display refresh rate when the backend supports immediate presentation.

Investigation so far

In the measured build:

The exact blocking point remains unknown. Check the actual selected present mode and layer state at runtime, then profile event-loop/redraw scheduling, drawable acquisition and presentation waits before choosing a fix.

Suggested verification

  1. On a visible, unlocked macOS session, use VSync off, unlimited frame rate and Present Mode Auto or Immediate in a 1280×720 window.
  2. Repeat the published benchmark at RD12 and RD32 with background jobs stopped.
  3. Compare VSync on/off and windowed/fullscreen; record the effective present mode and time spent acquiring/presenting frames. Testing another display refresh rate would help establish whether the ceiling follows it.
  4. After fixing or explaining the pacing, rerun the Mac benchmarks. The current cap limits throughput comparisons and can also affect frame-time and 1% low comparisons.

Related: #441 is a closed Wayland-specific refresh-rate cap fixed via frame-callback handling; #684 concerned the opposite symptom (VSync on failing to cap). Neither tracks this macOS benchmark case.

Originally created by @rdbtCVS on GitHub (Oct 22, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/1333 ## Observed behavior The published [benchmarks](https://playhorizon.dev/benchmarks) show Horizon on the Mac mini M4 Pro staying at approximately **144 FPS on a 144 Hz display despite VSync being off and the frame limit being unlimited**. This occurs at both render distance 12 and 32, across the village, forest, ocean and mountain flights. The website explicitly identifies the Mac results as capped at 144 FPS. The raw reports record `conditions.vsync: false` and `conditions.offscreen: false`; individual RD12 flights have median frame times around 6.94 ms, matching 144 Hz. This is evidence of unexpected refresh-rate pacing, not proof that the VSync setting itself remains enabled. ## Environment and evidence - Horizon **v2026.10.22.04**, report commit `02260048`; measurements from 2026-10-22. - Mac mini, Apple M4 Pro, 14 CPU threads, 64 GiB RAM. - macOS **27.0.1**, Metal backend. - Windowed, 1280×720; simulation distance 12; render distance 12 or 32; three repeats. - [RD12 raw report](https://github.com/ludovic111/horizon/blob/92b0ee1347b82d80e8a8faf6fe2206ad52fcd5d6/website/data/benchmarks/macmini/horizon-macmini-rd12.json). - [RD32 raw report](https://github.com/ludovic111/horizon/blob/92b0ee1347b82d80e8a8faf6fe2206ad52fcd5d6/website/data/benchmarks/macmini/horizon-macmini-rd32.json). - [Fleet metadata documenting the 144 FPS cap](https://github.com/ludovic111/horizon/blob/92b0ee1347b82d80e8a8faf6fe2206ad52fcd5d6/website/data/benchmarks/fleet.json). The machine was running other jobs during the measurements, so controlled reruns are needed. This report is based on the published data and source inspection; it has not been independently reproduced on a Mac. ## Expected behavior With VSync off, Present Mode Auto/Immediate and an unlimited frame rate, rendering should not be capped to the display refresh rate when the backend supports immediate presentation. ## Investigation so far In the measured build: - [Present-mode selection](https://github.com/ludovic111/horizon/blob/022600481e5a135e9634121e76bac5e213a0a994/crates/horizon-client/src/window.rs) prefers Immediate with VSync off; VSync on selects Fifo. - [Renderer settings](https://github.com/ludovic111/horizon/blob/022600481e5a135e9634121e76bac5e213a0a994/crates/horizon-client/src/gfx.rs) apply that choice and reconfigure the surface. - [The Metal backend](https://github.com/ludovic111/horizon/blob/022600481e5a135e9634121e76bac5e213a0a994/third_party/wgpu-hal/src/metal/surface.rs) maps Immediate to `CAMetalLayer.setDisplaySyncEnabled(false)`. The exact blocking point remains unknown. Check the actual selected present mode and layer state at runtime, then profile event-loop/redraw scheduling, drawable acquisition and presentation waits before choosing a fix. ## Suggested verification 1. On a visible, unlocked macOS session, use VSync off, unlimited frame rate and Present Mode Auto or Immediate in a 1280×720 window. 2. Repeat the published benchmark at RD12 and RD32 with background jobs stopped. 3. Compare VSync on/off and windowed/fullscreen; record the effective present mode and time spent acquiring/presenting frames. Testing another display refresh rate would help establish whether the ceiling follows it. 4. After fixing or explaining the pacing, rerun the Mac benchmarks. The current cap limits throughput comparisons and can also affect frame-time and 1% low comparisons. Related: #441 is a closed Wayland-specific refresh-rate cap fixed via frame-callback handling; #684 concerned the opposite symptom (VSync on failing to cap). Neither tracks this macOS benchmark case.
Author
Owner

@rdbtCVS commented on GitHub (Oct 26, 2026):

🤖 Agent: rdbtCVS’s AI agent (OpenAI Codex), triage follow-up. Open PR #1415 explicitly targets the macOS display-refresh cap described here, including the drawable-acquisition bottleneck. Recommend keeping this issue open until that PR merges and an uncapped visible-window run verifies the result on macOS.

<!-- gh-comment-id:6418399909 --> @rdbtCVS commented on GitHub (Oct 26, 2026): 🤖 Agent: rdbtCVS’s AI agent (OpenAI Codex), triage follow-up. Open PR #1415 explicitly targets the macOS display-refresh cap described here, including the drawable-acquisition bottleneck. Recommend keeping this issue open until that PR merges and an uncapped visible-window run verifies the result on macOS.
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#366
No description provided.