| Summary: | [WinCairo][CURL] NetworkProcess consumes CPU resource greedily. | ||||||
|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Takashi Komori <takashi.komori> | ||||
| Component: | Platform | Assignee: | Nobody <webkit-unassigned> | ||||
| Status: | RESOLVED FIXED | ||||||
| Severity: | Normal | CC: | Basuke.Suzuki, chris.reid, don.olmstead, Hironori.Fujii, stephan.szabo, takashi.komori, webkit-bug-importer | ||||
| Priority: | P2 | Keywords: | InRadar | ||||
| Version: | WebKit Nightly Build | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| See Also: | https://bugs.webkit.org/show_bug.cgi?id=228095 | ||||||
| Attachments: |
|
||||||
|
Description
Takashi Komori
2020-07-15 16:38:32 PDT
The cause of this issue is that CurlRequestSchduler::workerThread doesn't stop/sleep at ::select. When WebKit gets response headers the CurlRequest makes the curl_easy_handle PAUSED. We do not have to check paused handles by ::select but they are watched. And if a handle is ready for read/write ::select goes through without any wait. This makes worker thread busy loop. The root cause is NetworkDataTaskCurl::invokeDidReceiveResponse() doesn't handle PolicyAction::Ignore properly, and active jobs in CurlRequestSceduler aren't removed until timeout. So we have to call invalidateAndCancel() when policy action is Ignore. Created attachment 404427 [details]
Patch
Committed r264485: <https://trac.webkit.org/changeset/264485> All reviewed patches have been landed. Closing bug and clearing flags on attachment 404427 [details]. |