Use per-monitor vsync on macOS (and stop using CVDisplayLinkCreateWithActiveCGDisplays)
Categories
(Core :: Widget: Cocoa, task, P1)
Tracking
()
People
(Reporter: mstange, Unassigned)
References
(Depends on 1 open bug, Blocks 5 open bugs)
Details
Firefox triggers its rendering from vsync notifications. On macOS, we have one system-wide vsync source, which is accurate for the "main" screen. If you have multiple monitors with different refresh rates, and your Firefox window is not on the main screen, then those vsync notifications happen at the wrong time.
For example, if you have a Macbook Pro with a ProMotion display (capable of 120Hz) and an external monitor capable of 60Hz, we use either 120Hz or 60Hz across all screens, depending on which screen is the "main" screen. So you might get 60Hz animations on your 120Hz monitor, or unnecessarily frequent rendering on your 60Hz monitor.
Furthermore, the API we're using at the moment (CVDisplayLinkCreateWithActiveCGDisplays
) has caused us lots of trouble in the past and is continuing to do so, see these bugs for a subset of the problems: bug 1422855, bug 1682713, bug 1735408, bug 1602842, bug 1749431.
In this bug I want to implement per-monitor vsync for macOS, so that we can stop calling CVDisplayLinkCreateWithActiveCGDisplays
.
Reporter | ||
Updated•3 years ago
|
Updated•3 years ago
|
Comment 1•2 years ago
|
||
Probably not a S2
Reminder, S2 means: (Serious) Major functionality/product severely impaired or a high impact issue and a satisfactory workaround does not exist
Reporter | ||
Comment 3•2 years ago
|
||
Unassigning myself because I ended up working on profiler things instead. I'd be happy for someone else to pick up this work, it is still needed.
Description
•