Title: [148905] trunk/Source/WebKit2
- Revision
- 148905
- Author
- [email protected]
- Date
- 2013-04-22 13:01:51 -0700 (Mon, 22 Apr 2013)
Log Message
Don't kill our XPC services in response to memory pressure
https://bugs.webkit.org/show_bug.cgi?id=114985
<rdar://problem/13229217>
Reviewed by Mark Rowe.
* Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
(WebKit::XPCServiceInitializer):
Call xpc_transaction_begin() so we'll never be killed by the kernel when there's memory pressure;
we prefer to manage our own lifetime thank you very much!
* Shared/mac/ChildProcessMac.mm:
(WebKit::ChildProcess::platformInitialize):
Remove call to disable sudden termination.
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (148904 => 148905)
--- trunk/Source/WebKit2/ChangeLog 2013-04-22 19:54:53 UTC (rev 148904)
+++ trunk/Source/WebKit2/ChangeLog 2013-04-22 20:01:51 UTC (rev 148905)
@@ -1,3 +1,20 @@
+2013-04-22 Anders Carlsson <[email protected]>
+
+ Don't kill our XPC services in response to memory pressure
+ https://bugs.webkit.org/show_bug.cgi?id=114985
+ <rdar://problem/13229217>
+
+ Reviewed by Mark Rowe.
+
+ * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
+ (WebKit::XPCServiceInitializer):
+ Call xpc_transaction_begin() so we'll never be killed by the kernel when there's memory pressure;
+ we prefer to manage our own lifetime thank you very much!
+
+ * Shared/mac/ChildProcessMac.mm:
+ (WebKit::ChildProcess::platformInitialize):
+ Remove call to disable sudden termination.
+
2013-04-22 Alexey Proskuryakov <[email protected]>
<rdar://problem/13681842> [Mac] Tweak WebProcess sandbox profile to use
Modified: trunk/Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h (148904 => 148905)
--- trunk/Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h 2013-04-22 19:54:53 UTC (rev 148904)
+++ trunk/Source/WebKit2/Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h 2013-04-22 20:01:51 UTC (rev 148905)
@@ -59,6 +59,10 @@
{
XPCServiceInitializerDelegateType delegate(connection, initializerMessage);
+ // We don't want XPC to be in charge of whether the process should be terminated or not,
+ // so ensure that we have an outstanding transaction here.
+ xpc_transaction_begin();
+
InitializeWebKit2();
ChildProcessInitializationParameters parameters;
Modified: trunk/Source/WebKit2/Shared/mac/ChildProcessMac.mm (148904 => 148905)
--- trunk/Source/WebKit2/Shared/mac/ChildProcessMac.mm 2013-04-22 19:54:53 UTC (rev 148904)
+++ trunk/Source/WebKit2/Shared/mac/ChildProcessMac.mm 2013-04-22 20:01:51 UTC (rev 148905)
@@ -100,10 +100,6 @@
// Starting with process suppression disabled. The proxy for this process will enable if appropriate from didFinishLaunching().
setProcessSuppressionEnabled(false);
- // <rdar://problem/13229217> Sudden Termination is causing WebContent XPC services to be killed in response to memory pressure
- // Hence, disable it until we can identify if it is being enabled in error or not.
- [[NSProcessInfo processInfo] disableSuddenTermination];
-
[[NSFileManager defaultManager] changeCurrentDirectoryPath:[[NSBundle mainBundle] bundlePath]];
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes