Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 9aa80df533559c2b7fc16897fabb567949647953
      
https://github.com/WebKit/WebKit/commit/9aa80df533559c2b7fc16897fabb567949647953
  Author: Matt Woodrow <[email protected]>
  Date:   2025-12-01 (Mon, 01 Dec 2025)

  Changed paths:
    M Source/WebCore/platform/graphics/cocoa/IOSurface.h
    M Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.mm
    M Source/WebKit/UIProcess/DrawingAreaProxy.h
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.h
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.mm
    M Source/WebKit/UIProcess/WebPageProxy.cpp
    M Source/WebKit/UIProcess/WebProcessProxy.cpp

  Log Message:
  -----------
  Magenta flash when loading page.
https://bugs.webkit.org/show_bug.cgi?id=303157
<rdar://163597990>

Reviewed by Simon Fraser.

WebProcess::prepareToSuspend attempts to mark all the layers in all the pages as
volatile. Add matching calls to hideContentUntilPendingUpdate on the
WebProcessProxy side to make sure we never miss a case where we try to present
these volatile layers.

WebPageProxy::dispatchActivityStateChange calls
hideContentUntilDidUpdateActivityState, which can fall back on
hideContentUntilAnyUpdate if the state change is asynchronous. Use
hideContentUntilPendingUpdate instead, which unconditionally does an IPC
roundtrip.

Finally, add some logging to ensure that a volatile IOSurface never gets sent in
a RemoteLayerTreeTransaction.

* Source/WebCore/platform/graphics/cocoa/IOSurface.h:
* Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.mm:
(WebKit::RemoteLayerBackingStoreProperties::layerContentsBufferFromBackendHandle):
(WebKit::RemoteLayerBackingStoreProperties::lookupCachedBuffer):
* Source/WebKit/UIProcess/DrawingAreaProxy.h:
(WebKit::DrawingAreaProxy::hideContentUntilPendingUpdate):
(WebKit::DrawingAreaProxy::hideContentUntilDidUpdateActivityState): Deleted.
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.h:
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.mm:
(WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):
(WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTreeTransaction):
(WebKit::RemoteLayerTreeDrawingAreaProxy::hideContentUntilDidUpdateActivityState):
 Deleted.
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::dispatchActivityStateChange):
* Source/WebKit/UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::sendPrepareToSuspend):

Canonical link: https://commits.webkit.org/303720@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to