Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 79d48cd76aca9a259093fc8df53abe972a7b382d
https://github.com/WebKit/WebKit/commit/79d48cd76aca9a259093fc8df53abe972a7b382d
Author: Ben Nham <[email protected]>
Date: 2026-06-06 (Sat, 06 Jun 2026)
Changed paths:
M Source/WebCore/platform/PlatformScreen.cpp
M Source/WebCore/platform/PlatformScreen.h
M Source/WebCore/platform/ScreenProperties.h
M Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm
M Source/WebKit/UIProcess/WebPageProxy.cpp
M Source/WebKit/UIProcess/WebProcessPool.cpp
M Source/WebKit/UIProcess/WebProcessPool.h
M Source/WebKit/UIProcess/mac/WebViewImpl.mm
Log Message:
-----------
Debounce screen properties updates
https://bugs.webkit.org/show_bug.cgi?id=316316
rdar://177953568
Reviewed by Per Arne Vollan.
We've seen instances in logs where we are IPC'ing a large number of screen
properties updates (more
than 2000 in a minute). This is surprising because we don't expect screen
properties to change
frequently.
Debounce screen properties updates to at most one per second. Additionally, add
logging to help
better understand why there are sometimes an excessive number of screen updates
(in this patch, we
log if we get more than 600 updates per minute).
* Source/WebCore/platform/PlatformScreen.cpp:
* Source/WebCore/platform/PlatformScreen.h:
* Source/WebCore/platform/ScreenProperties.h:
* Source/WebKit/UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::registerNotificationObservers):
(WebKit::WebProcessPool::sendScreenPropertiesChangedToAllProcesses):
(WebKit::WebProcessPool::logScreenPropertiesUpdateReasonsTimerFired):
(WebKit::WebProcessPool::screenPropertiesUpdateTimerFired):
(WebKit::WebProcessPool::dispatchScreenPropertiesChangedToAllProcesses):
(WebKit::WebProcessPool::screenPropertiesChanged):
(WebKit::WebProcessPool::displayPropertiesChanged):
(WebKit::webProcessPoolHighDynamicRangeDidChangeCallback):
(WebKit::WebProcessPool::registerHighDynamicRangeChangeCallback):
(WebKit::WebProcessPool::didRefreshDisplay):
(WebKit::WebProcessPool::suppressEDR):
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::accessibilitySettingsDidChange):
* Source/WebKit/UIProcess/WebProcessPool.cpp:
* Source/WebKit/UIProcess/WebProcessPool.h:
* Source/WebKit/UIProcess/mac/WebViewImpl.mm:
(WebKit::WebViewImpl::screenDidChangeColorSpace):
Canonical link: https://commits.webkit.org/314702@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications