We shouldn't make a ScrollingThread on iOS.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 18 May 2014 02:05:24 +0000 (02:05 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 18 May 2014 02:05:24 +0000 (02:05 +0000)
<https://webkit.org/b/133038>
<rdar://problem/16947589>

Don't call ScrollingThred::dispatch() from the pressure relief
code on iOS since that will end up instantiating a scrolling thread
which we'd otherwise never have.

Reviewed by Sam Weinig.

* platform/MemoryPressureHandler.cpp:
(WebCore::MemoryPressureHandler::releaseMemory):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@169004 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/MemoryPressureHandler.cpp

index fe8ca16..6456f6a 100644 (file)
@@ -1,3 +1,18 @@
+2014-05-17  Andreas Kling  <akling@apple.com>
+
+        We shouldn't make a ScrollingThread on iOS.
+        <https://webkit.org/b/133038>
+        <rdar://problem/16947589>
+
+        Don't call ScrollingThred::dispatch() from the pressure relief
+        code on iOS since that will end up instantiating a scrolling thread
+        which we'd otherwise never have.
+
+        Reviewed by Sam Weinig.
+
+        * platform/MemoryPressureHandler.cpp:
+        (WebCore::MemoryPressureHandler::releaseMemory):
+
 2014-05-17  Piotr Grad  <p.grad@samsung.com>
 
         Setting playback rate on video with media controller is not ignored.
index 177c05d..dce0d38 100644 (file)
@@ -124,7 +124,7 @@ void MemoryPressureHandler::releaseMemory(bool critical)
         // FastMalloc has lock-free thread specific caches that can only be cleared from the thread itself.
         StorageThread::releaseFastMallocFreeMemoryInAllThreads();
         WorkerThread::releaseFastMallocFreeMemoryInAllThreads();
-#if ENABLE(ASYNC_SCROLLING)
+#if ENABLE(ASYNC_SCROLLING) && !PLATFORM(IOS)
         ScrollingThread::dispatch(bind(WTF::releaseFastMallocFreeMemory));
 #endif
         WTF::releaseFastMallocFreeMemory();