WebKit Bugzilla
Attachment 369173 Details for
Bug 197630
: Prewarmed WebContent processes never app nap
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-197630-20190506151337.patch (text/plain), 2.94 KB, created by
Chris Dumez
on 2019-05-06 15:13:38 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Chris Dumez
Created:
2019-05-06 15:13:38 PDT
Size:
2.94 KB
patch
obsolete
>Subversion Revision: 244977 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index db17075bcfdcf6709bb1fc138555b71cbc97232a..3aacb069e7e3e8ce953f114b380007c0343c8482 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,17 @@ >+2019-05-06 Chris Dumez <cdumez@apple.com> >+ >+ Prewarmed WebContent processes never app nap >+ https://bugs.webkit.org/show_bug.cgi?id=197630 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Do not require actually having a WebPage in the WebContent process to App Nap. >+ >+ * WebProcess/WebPage/WebPage.cpp: >+ (WebKit::WebPage::updateThrottleState): >+ * WebProcess/cocoa/WebProcessCocoa.mm: >+ (WebKit::WebProcess::platformInitializeWebProcess): >+ > 2019-05-06 Daniel Bates <dabates@apple.com> > > Google Docs & Yahoo! Japan: Canât compose characters with Chinese or Japanese keyboard >diff --git a/Source/WebKit/WebProcess/WebPage/WebPage.cpp b/Source/WebKit/WebProcess/WebPage/WebPage.cpp >index 0d8a0d34cc963c48e5fa2698d85142e527bf144b..affe24a926f9aaec8aca1186da803aad4d90c1a1 100644 >--- a/Source/WebKit/WebProcess/WebPage/WebPage.cpp >+++ b/Source/WebKit/WebProcess/WebPage/WebPage.cpp >@@ -766,15 +766,6 @@ void WebPage::updateThrottleState() > bool isVisuallyIdle = m_activityState.contains(ActivityState::IsVisuallyIdle); > bool pageSuppressed = m_processSuppressionEnabled && !isActive && isVisuallyIdle; > >-#if PLATFORM(MAC) && ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING) >- if (!pageSuppressed) { >- // App nap must be manually enabled when not running the NSApplication run loop. >- static std::once_flag onceKey; >- std::call_once(onceKey, [] { >- __CFRunLoopSetOptionsReason(__CFRunLoopOptionsEnableAppNap, CFSTR("Finished checkin as application - enable app nap")); >- }); >- } >-#endif > // The UserActivity keeps the processes runnable. So if the page should be suppressed, stop the activity. > // If the page should not be supressed, start it. > if (pageSuppressed) >diff --git a/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm b/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm >index 73df75c86dda1237eaf5b9cc4d33639dbc83117d..1c5ee037f0cfca3735876c704a007c31f7abe81b 100644 >--- a/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm >+++ b/Source/WebKit/WebProcess/cocoa/WebProcessCocoa.mm >@@ -198,6 +198,11 @@ void WebProcess::platformInitializeWebProcess(WebProcessCreationParameters& para > [NSApplication _accessibilityInitialize]; > #endif > >+#if PLATFORM(MAC) && ENABLE(WEBPROCESS_WINDOWSERVER_BLOCKING) >+ // App nap must be manually enabled when not running the NSApplication run loop. >+ __CFRunLoopSetOptionsReason(__CFRunLoopOptionsEnableAppNap, CFSTR("Finished checkin as application - enable app nap")); >+#endif >+ > #if TARGET_OS_IPHONE > // Priority decay on iOS 9 is impacting page load time so we fix the priority of the WebProcess' main thread (rdar://problem/22003112). > pthread_set_fixedpriority_self();
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 197630
: 369173