Bug 159497

Summary: [WK2][Cocoa] Disable ResourceResponse lazy initialization
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: WebKit2Assignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, beidson, commit-queue, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch achristensen: review+, achristensen: commit-queue-

Description Chris Dumez 2016-07-06 16:38:39 PDT
Disable ResponseResponse lazy initialization for WebKit2 as we always end up initializing all the fields anyway when sending the response to the WebContent process via IPC.

Even worse, we always do a partial lazy initialization (common fields only) before the IPC so we always do the initialization in 2 steps. This normally would not be an issue but the 2 steps actually have some overlap because both call CFHTTPMessageCopyAllHeaderFields(), which is expensive (See <rdar://problem/26796059>) to first get the common HTTP headers, then ALL the HTTP headers.
Comment 1 Radar WebKit Bug Importer 2016-07-06 16:39:26 PDT
<rdar://problem/27209066>
Comment 2 Chris Dumez 2016-07-06 16:54:52 PDT
Created attachment 282963 [details]
Patch
Comment 3 Alex Christensen 2016-07-06 17:14:21 PDT
Comment on attachment 282963 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=282963&action=review

> Source/WebCore/ChangeLog:3
> +        [WK2][Cocoa] Disable ResponseResponse lazy initialization

ResourceResponse.
Comment 4 Chris Dumez 2016-07-06 18:33:22 PDT
Committed r202888: <http://trac.webkit.org/changeset/202888>