Title: [160327] trunk/Source/WebCore
Revision
160327
Author
akl...@apple.com
Date
2013-12-09 13:15:20 -0800 (Mon, 09 Dec 2013)

Log Message

REGRESSION(r160260): Memory pressure signal causes web process to hang.
<https://webkit.org/b/125465>

Reviewed by Tim Horton.

This command caused all of my web processes to hang:

    notifyutil -p org.WebKit.lowMemory

This only happens when the cache pruning code encounters a resource
using purgeable memory.

* loader/cache/MemoryCache.cpp:
(WebCore::MemoryCache::pruneLiveResourcesToSize):

    Grab the next CachedResource pointer before continuing the loop.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (160326 => 160327)


--- trunk/Source/WebCore/ChangeLog	2013-12-09 20:38:28 UTC (rev 160326)
+++ trunk/Source/WebCore/ChangeLog	2013-12-09 21:15:20 UTC (rev 160327)
@@ -1,3 +1,22 @@
+2013-12-09  Andreas Kling  <akl...@apple.com>
+
+        REGRESSION(r160260): Memory pressure signal causes web process to hang.
+        <https://webkit.org/b/125465>
+
+        Reviewed by Tim Horton.
+
+        This command caused all of my web processes to hang:
+
+            notifyutil -p org.WebKit.lowMemory
+
+        This only happens when the cache pruning code encounters a resource
+        using purgeable memory.
+
+        * loader/cache/MemoryCache.cpp:
+        (WebCore::MemoryCache::pruneLiveResourcesToSize):
+
+            Grab the next CachedResource pointer before continuing the loop.
+
 2013-12-09  pe...@outlook.com  <pe...@outlook.com>
 
         [WinCairo] OpenGL compile error.

Modified: trunk/Source/WebCore/loader/cache/MemoryCache.cpp (160326 => 160327)


--- trunk/Source/WebCore/loader/cache/MemoryCache.cpp	2013-12-09 20:38:28 UTC (rev 160326)
+++ trunk/Source/WebCore/loader/cache/MemoryCache.cpp	2013-12-09 21:15:20 UTC (rev 160327)
@@ -266,8 +266,10 @@
             if (elapsedTime < cMinDelayBeforeLiveDecodedPrune)
                 return;
 
-            if (current->decodedDataIsPurgeable())
+            if (current->decodedDataIsPurgeable()) {
+                current = prev;
                 continue;
+            }
 
             // Destroy our decoded data. This will remove us from 
             // m_liveDecodedResources, and possibly move us to a different LRU 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to