Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 8d026d2b3d9578d76e8fa10bf76fbad8ac557067
      
https://github.com/WebKit/WebKit/commit/8d026d2b3d9578d76e8fa10bf76fbad8ac557067
  Author: Ada Chan <[email protected]>
  Date:   2025-05-27 (Tue, 27 May 2025)

  Changed paths:
    M Source/WebKit/UIProcess/WebProcessPool.cpp
    M Source/WebKit/UIProcess/WebProcessPool.h
    M Source/WebKit/UIProcess/WebProcessPool.messages.in
    M Source/WebKit/WebProcess/Model/ModelProcessModelPlayerManager.cpp

  Log Message:
  -----------
  Terminate only the web processes using models after the model process has 
repeatedly crashed
https://bugs.webkit.org/show_bug.cgi?id=293495
rdar://150495867

Reviewed by Mike Wyrzykowski.

Track the web processes using models in 
WebProcessPool::m_processesWithModelPlayers.
When we detect the model process has crashed multiple times within a short 
period of
time, we terminate the web processes that are actively showing models.

* Source/WebKit/UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::modelProcessExited):
Clear out m_processesWithModelPlayers when the model process exits.
(WebKit::WebProcessPool::startedPlayingModels):
Start tracking the web process in m_processesWithModelPlayers.
(WebKit::WebProcessPool::stoppedPlayingModels):
Stop tracking the web process in m_processesWithModelPlayers.
(WebKit::WebProcessPool::terminateAllWebContentProcessesWithModelPlayers):
Go through all the web processes with existing model players and
terminate them.
(WebKit::WebProcessPool::disconnectProcess):
Stop tracking the web process in m_processesWithModelPlayers when
the web process has exited.
* Source/WebKit/UIProcess/WebProcessPool.h:
* Source/WebKit/UIProcess/WebProcessPool.messages.in:
* Source/WebKit/WebProcess/Model/ModelProcessModelPlayerManager.cpp:
(WebKit::ModelProcessModelPlayerManager::createModelProcessModelPlayer):
Notify WebProcessPool in the UI process if the web process has
created its first model player.
(WebKit::ModelProcessModelPlayerManager::deleteModelProcessModelPlayer):
Notify WebProcessPool in the UI process if the web process has
removed its last model player.
(WebKit::ModelProcessModelPlayerManager::didUnloadModelProcessModelPlayer):
Notify WebProcessPool in the UI process if the web process has
removed its last model player.

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to