Title: [166400] trunk/Source/WebKit2
Revision
166400
Author
psola...@apple.com
Date
2014-03-27 23:24:14 -0700 (Thu, 27 Mar 2014)

Log Message

[iOS WebKit2] Tweak cache sizes for iOS
https://bugs.webkit.org/show_bug.cgi?id=130871

Reviewed by Sam Weinig.

Bring over the tweaks we had made to memory cache size for WebKit1 on iOS to WebKit2. These
were made per findings in <rdar://8611638>.

* Shared/CacheModel.cpp:
(WebKit::calculateCacheSizes):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (166399 => 166400)


--- trunk/Source/WebKit2/ChangeLog	2014-03-28 06:21:42 UTC (rev 166399)
+++ trunk/Source/WebKit2/ChangeLog	2014-03-28 06:24:14 UTC (rev 166400)
@@ -1,3 +1,16 @@
+2014-03-27  Pratik Solanki  <psola...@apple.com>
+
+        [iOS WebKit2] Tweak cache sizes for iOS
+        https://bugs.webkit.org/show_bug.cgi?id=130871
+
+        Reviewed by Sam Weinig.
+
+        Bring over the tweaks we had made to memory cache size for WebKit1 on iOS to WebKit2. These
+        were made per findings in <rdar://8611638>.
+
+        * Shared/CacheModel.cpp:
+        (WebKit::calculateCacheSizes):
+
 2014-03-27  Jinwoo Song  <jinwoo7.s...@samsung.com>
 
         [WK2][EFL] Fix wrong parameter name in ewk_view_user_agent_set()

Modified: trunk/Source/WebKit2/Shared/CacheModel.cpp (166399 => 166400)


--- trunk/Source/WebKit2/Shared/CacheModel.cpp	2014-03-28 06:21:42 UTC (rev 166399)
+++ trunk/Source/WebKit2/Shared/CacheModel.cpp	2014-03-28 06:24:14 UTC (rev 166400)
@@ -139,6 +139,12 @@
 
         deadDecodedDataDeletionInterval = 60;
 
+#if PLATFORM(IOS)
+        if (memorySize >= 1024)
+            urlCacheMemoryCapacity = 16 * 1024 * 1024;
+        else
+            urlCacheMemoryCapacity = 8 * 1024 * 1024;
+#else
         // Foundation memory cache capacity (in bytes)
         // (These values are small because WebCore does most caching itself.)
         if (memorySize >= 1024)
@@ -148,7 +154,8 @@
         else if (memorySize >= 256)
             urlCacheMemoryCapacity = 1 * 1024 * 1024;
         else
-            urlCacheMemoryCapacity =      512 * 1024; 
+            urlCacheMemoryCapacity =      512 * 1024;
+#endif
 
         // Foundation disk cache capacity (in bytes)
         if (diskFreeSize >= 16384)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to