WebContent processes do not exit promptly, they hang around for 10 seconds until the watchdog forcefully calls exit().
<rdar://problem/26965488>
Created attachment 282445 [details] WIP Patch
Comment on attachment 282445 [details] WIP Patch View in context: https://bugs.webkit.org/attachment.cgi?id=282445&action=review > Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:76 > + xpc_object_t leakedReplyForBoosting = xpc_dictionary_create_reply(event); Sadly, this does not appear to work in practice. While it no longer prevents XPC exit, the WebContent process no longer gets boosted either :/
Created attachment 282465 [details] Patch
Created attachment 282474 [details] Patch
Updated based on offline review feedback from Anders. It fixes the issue and is a bit nicer now.
Created attachment 282482 [details] Patch
Created attachment 282488 [details] Patch
Comment on attachment 282488 [details] Patch Attachment 282488 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/1603188 Number of test failures exceeded the failure limit.
Created attachment 282490 [details] Archive of layout-test-results from ews106 for mac-yosemite-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews106 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Created attachment 282491 [details] Patch
Comment on attachment 282491 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=282491&action=review > Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:84 > + parameters.priorityBoostMessage = priorityBoostMessage ? adoptOSObject(xpc_retain(priorityBoostMessage)) : nullptr; The crashes on the Mac bots were because we only use priority boosting for the NetworkProcess on Mac. Therefore, for other processes would have a null priorityBoostMessage and calling xpc_retain() on nullptr crashes. I added a null check here. > Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:74 > + if (priorityBoostMessage) Also added a null check to avoid calling xlc_release() on null.
Created attachment 282495 [details] Patch
Comment on attachment 282495 [details] Patch Clearing flags on attachment: 282495 Committed r202723: <http://trac.webkit.org/changeset/202723>
All reviewed patches have been landed. Closing bug.