Title: [274652] trunk/Source/WebKit
Revision
274652
Author
[email protected]
Date
2021-03-18 11:14:48 -0700 (Thu, 18 Mar 2021)

Log Message

Don't delay conditional requests in resource load scheduler
https://bugs.webkit.org/show_bug.cgi?id=223450

Reviewed by Geoffrey Garen.

* NetworkProcess/NetworkLoadScheduler.cpp:
(WebKit::NetworkLoadScheduler::HostContext::schedule):

Conditional requests usually come back as 304s and don't slow other resource loads down.

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (274651 => 274652)


--- trunk/Source/WebKit/ChangeLog	2021-03-18 18:11:33 UTC (rev 274651)
+++ trunk/Source/WebKit/ChangeLog	2021-03-18 18:14:48 UTC (rev 274652)
@@ -1,3 +1,15 @@
+2021-03-18  Antti Koivisto  <[email protected]>
+
+        Don't delay conditional requests in resource load scheduler
+        https://bugs.webkit.org/show_bug.cgi?id=223450
+
+        Reviewed by Geoffrey Garen.
+
+        * NetworkProcess/NetworkLoadScheduler.cpp:
+        (WebKit::NetworkLoadScheduler::HostContext::schedule):
+
+        Conditional requests usually come back as 304s and don't slow other resource loads down.
+
 2021-03-18  Carlos Garcia Campos  <[email protected]>
 
         [WPE] Bump API version when building with libsoup3

Modified: trunk/Source/WebKit/NetworkProcess/NetworkLoadScheduler.cpp (274651 => 274652)


--- trunk/Source/WebKit/NetworkProcess/NetworkLoadScheduler.cpp	2021-03-18 18:11:33 UTC (rev 274651)
+++ trunk/Source/WebKit/NetworkProcess/NetworkLoadScheduler.cpp	2021-03-18 18:14:48 UTC (rev 274652)
@@ -43,8 +43,6 @@
     void unschedule(NetworkLoad&);
     void prioritize(NetworkLoad&);
 
-    void finishPage(WebCore::PageIdentifier);
-
 private:
     void start(NetworkLoad&);
     bool shouldDelayLowPriority() const { return m_activeLoads.size() >= maximumActiveCountForLowPriority; }
@@ -56,9 +54,12 @@
 void NetworkLoadScheduler::HostContext::schedule(NetworkLoad& load)
 {
     auto startImmediately = [&] {
-        auto priority = load.parameters().request.priority();
-        if (priority > WebCore::ResourceLoadPriority::Low)
+        auto& request = load.currentRequest();
+        if (request.priority() > WebCore::ResourceLoadPriority::Low)
             return true;
+        
+        if (request.isConditional())
+            return true;
 
         if (!shouldDelayLowPriority())
             return true;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to