Changeset 208048 in webkit


Ignore:
Timestamp:
Oct 28, 2016, 8:11:21 AM (8 years ago)
Author:
Antti Koivisto
Message:

Enable CFNetwork connection cache fast lane for WebKit2
https://bugs.webkit.org/show_bug.cgi?id=164129

Reviewed by Andreas Kling.

The idea of this feature is keep a connection free for higher priority requests so low-priority
image loads can't take all the available connections.

We have this enabled on WK1 but not on WK2. See what enabling it does for performance in bots.

  • NetworkProcess/cocoa/NetworkProcessCocoa.mm:

(WebKit::initializeNetworkSettings):

Based on code inspection setting kHTTPMinimumFastLanePriority is not sufficient to enable this feature,
kHTTPNumFastLanes needs also be set to a non-zero value. Use the same constants as WK1.
Also enable this on Mac to unify behavior.

Location:
trunk/Source/WebKit2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r208035 r208048  
     12016-10-28  Antti Koivisto  <antti@apple.com>
     2
     3        Enable CFNetwork connection cache fast lane for WebKit2
     4        https://bugs.webkit.org/show_bug.cgi?id=164129
     5
     6        Reviewed by Andreas Kling.
     7
     8        The idea of this feature is keep a connection free for higher priority requests so low-priority
     9        image loads can't take all the available connections.
     10
     11        We have this enabled on WK1 but not on WK2. See what enabling it does for performance in bots.
     12
     13        * NetworkProcess/cocoa/NetworkProcessCocoa.mm:
     14        (WebKit::initializeNetworkSettings):
     15
     16            Based on code inspection setting kHTTPMinimumFastLanePriority is not sufficient to enable this feature,
     17            kHTTPNumFastLanes needs also be set to a non-zero value. Use the same constants as WK1.
     18            Also enable this on Mac to unify behavior.
     19
    1202016-10-27  Michael Catanzaro  <mcatanzaro@igalia.com>
    221
  • trunk/Source/WebKit2/NetworkProcess/cocoa/NetworkProcessCocoa.mm

    r207813 r208048  
    6161
    6262    if (WebCore::ResourceRequest::resourcePrioritiesEnabled()) {
     63        const unsigned fastLaneConnectionCount = 1;
     64
    6365        _CFNetworkHTTPConnectionCacheSetLimit(kHTTPPriorityNumLevels, toPlatformRequestPriority(WebCore::ResourceLoadPriority::Highest));
    64 #if PLATFORM(IOS)
    6566        _CFNetworkHTTPConnectionCacheSetLimit(kHTTPMinimumFastLanePriority, toPlatformRequestPriority(WebCore::ResourceLoadPriority::Medium));
    66 #endif
     67        _CFNetworkHTTPConnectionCacheSetLimit(kHTTPNumFastLanes, fastLaneConnectionCount);
    6768    }
    6869}
Note: See TracChangeset for help on using the changeset viewer.