Currently, the WebContent and Networking process is calling CFBundleGetValueForInfoDictionaryKey on startup to get the entry point function name into the WebKit bundle. This causes a mach lookup to cfprefsd which should be avoided. Instead, we can send the service name as part of the bootstrap message when the UI process is starting the process, and have the new process read this value from the message on startup to determine the name of the entry point. This is possibly also an improvement in launch time, since we avoid reading a value from Info.plist.
<rdar://problem/56204321>
Created attachment 380789 [details] Patch
Created attachment 380900 [details] Patch
Comment on attachment 380900 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=380900&action=review > Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:61 > + if (!strcmp(serviceName, "com.apple.WebKit.WebContent")) Does this work for our Development builds? (com.apple.WebKit.WebContent.Development", etc.)? > Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:66 > + entryPointFunctionName = CFSTR("PluginServiceInitializer"); It's a shame that we can't define this in the relevant bundle somewhere, so that someone changing the service could easily keep the two in sync. Still, I suppose we really never change the names of these initialization functions.
Created attachment 380908 [details] Patch
(In reply to Brent Fulgham from comment #4) > Comment on attachment 380900 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=380900&action=review > > > Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:61 > > + if (!strcmp(serviceName, "com.apple.WebKit.WebContent")) > > Does this work for our Development builds? > (com.apple.WebKit.WebContent.Development", etc.)? > Good catch! I have updated the patch. > > Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:66 > > + entryPointFunctionName = CFSTR("PluginServiceInitializer"); > > It's a shame that we can't define this in the relevant bundle somewhere, so > that someone changing the service could easily keep the two in sync. Still, > I suppose we really never change the names of these initialization functions. Thanks for reviewing!
Created attachment 382193 [details] Patch
Comment on attachment 382193 [details] Patch Attachment 382193 [details] did not pass win-ews (win): Output: https://webkit-queues.webkit.org/results/13188851 New failing tests: http/tests/misc/repeat-open-cancel.html
Created attachment 382205 [details] Archive of layout-test-results from ews213 for win-future The attached test failures were seen while running run-webkit-tests on the win-ews. Bot: ews213 Port: win-future Platform: CYGWIN_NT-10.0-17763-3.0.5-338.x86_64-x86_64-64bit
The Win EWS failure should be unrelated, since AppleWin is not compiling this.
Comment on attachment 382193 [details] Patch r=me
(In reply to Geoffrey Garen from comment #11) > Comment on attachment 382193 [details] > Patch > > r=me Thanks for reviewing!
Comment on attachment 382193 [details] Patch Rejecting attachment 382193 [details] from commit-queue. Failed to run "['/Volumes/Data/EWS/WebKit/Tools/Scripts/webkit-patch', '--status-host=webkit-queues.webkit.org', '--bot-id=webkit-cq-03', 'land-attachment', '--force-clean', '--non-interactive', '--parent-command=commit-queue', 382193, '--port=mac']" exit_code: 2 cwd: /Volumes/Data/EWS/WebKit Logging in as commit-queue@webkit.org... Fetching: https://bugs.webkit.org/attachment.cgi?id=382193&action=edit Fetching: https://bugs.webkit.org/show_bug.cgi?id=202866&ctype=xml&excludefield=attachmentdata Processing 1 patch from 1 bug. Updating working directory Processing patch 382193 from bug 202866. Fetching: https://bugs.webkit.org/attachment.cgi?id=382193 Failed to run "['git', 'svn', 'dcommit', '--rmdir']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit Committing to http://svn.webkit.org/repository/webkit/trunk ... M Source/WebKit/ChangeLog ERROR from SVN: Item is out of date: File '/trunk/Source/WebKit/ChangeLog' is out of date W: 1ea2773e5b54fe670d6ae0438cad0fb4d82ea57b and refs/remotes/origin/master differ, using rebase: :040000 040000 bff00d918e400d73c0067782eaaa597a330640c0 2c474c7a6cfd7c7f9686e6db48258df57f8677a3 M Source Current branch master is up to date. ERROR: Not all changes have been committed into SVN, however the committed ones (if any) seem to be successfully integrated into the working tree. Please see the above messages for details. Failed to run "['git', 'svn', 'dcommit', '--rmdir']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit Committing to http://svn.webkit.org/repository/webkit/trunk ... M Source/WebKit/ChangeLog ERROR from SVN: Item is out of date: File '/trunk/Source/WebKit/ChangeLog' is out of date W: 1ea2773e5b54fe670d6ae0438cad0fb4d82ea57b and refs/remotes/origin/master differ, using rebase: :040000 040000 bff00d918e400d73c0067782eaaa597a330640c0 2c474c7a6cfd7c7f9686e6db48258df57f8677a3 M Source Current branch master is up to date. ERROR: Not all changes have been committed into SVN, however the committed ones (if any) seem to be successfully integrated into the working tree. Please see the above messages for details. Failed to run "['git', 'svn', 'dcommit', '--rmdir']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit Updating OpenSource From https://git.webkit.org/git/WebKit 4641b5233e5..f84097b8fe5 master -> origin/master Partial-rebuilding .git/svn/refs/remotes/origin/master/.rev_map.268f45cc-cd09-0410-ab3c-d52691b4dbfc ... Currently at 252063 = 4641b5233e5e69039e71d0c02870b54b77a2b157 r252064 = f84097b8fe580f62c3145e62150f3ad7f7f3b567 Done rebuilding .git/svn/refs/remotes/origin/master/.rev_map.268f45cc-cd09-0410-ab3c-d52691b4dbfc First, rewinding head to replay your work on top of it... Fast-forwarded master to refs/remotes/origin/master. Full output: https://webkit-queues.webkit.org/results/13215903
Created attachment 382842 [details] Patch
Comment on attachment 382842 [details] Patch Clearing flags on attachment: 382842 Committed r252083: <https://trac.webkit.org/changeset/252083>