Title: [279046] trunk/Source/WebCore
Revision
279046
Author
[email protected]
Date
2021-06-18 13:41:38 -0700 (Fri, 18 Jun 2021)

Log Message

[Curl] Add curl option CURLOPT_NOSIGNAL to omit numerous sigaction calls
https://bugs.webkit.org/show_bug.cgi?id=227118

Patch by Soujyu TANAKA <[email protected]> on 2021-06-18
Reviewed by Fujii Hironori.

As we increase file handles registered by curl_multi_add_handle(),
number of times of sigaction executions in Curl grows rapidly. That can
cause unignorable download speed drop.

With a curl option CURLOPT_NOSIGNAL enabled, Curl doesn't use the
syscall to ignore SIGPIPE signals. It's safe as long as we configure to
prevent SIGPIPE from being triggered.

No new tests.

* platform/network/curl/CurlContext.cpp:
(WebCore::CurlHandle::CurlHandle):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (279045 => 279046)


--- trunk/Source/WebCore/ChangeLog	2021-06-18 20:36:37 UTC (rev 279045)
+++ trunk/Source/WebCore/ChangeLog	2021-06-18 20:41:38 UTC (rev 279046)
@@ -1,3 +1,23 @@
+2021-06-18  Soujyu TANAKA  <[email protected]>
+
+        [Curl] Add curl option CURLOPT_NOSIGNAL to omit numerous sigaction calls
+        https://bugs.webkit.org/show_bug.cgi?id=227118
+
+        Reviewed by Fujii Hironori.
+
+        As we increase file handles registered by curl_multi_add_handle(),
+        number of times of sigaction executions in Curl grows rapidly. That can
+        cause unignorable download speed drop.
+
+        With a curl option CURLOPT_NOSIGNAL enabled, Curl doesn't use the
+        syscall to ignore SIGPIPE signals. It's safe as long as we configure to
+        prevent SIGPIPE from being triggered.
+
+        No new tests.
+
+        * platform/network/curl/CurlContext.cpp:
+        (WebCore::CurlHandle::CurlHandle):
+
 2021-06-18  Oriol Brufau  <[email protected]>
 
         [css-logical] Fix cssom "set a CSS declaration" for logical properties

Modified: trunk/Source/WebCore/platform/network/curl/CurlContext.cpp (279045 => 279046)


--- trunk/Source/WebCore/platform/network/curl/CurlContext.cpp	2021-06-18 20:36:37 UTC (rev 279045)
+++ trunk/Source/WebCore/platform/network/curl/CurlContext.cpp	2021-06-18 20:41:38 UTC (rev 279046)
@@ -282,6 +282,7 @@
 {
     m_handle = curl_easy_init();
     curl_easy_setopt(m_handle, CURLOPT_ERRORBUFFER, m_errorBuffer);
+    curl_easy_setopt(m_handle, CURLOPT_NOSIGNAL, 1L);
 
     enableShareHandle();
     enableAllowedProtocols();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to