[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

barraclough at apple.com barraclough at apple.com
Wed Dec 22 11:33:13 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 255315ffcf90a3901aebc1dc128c3dd7d46a951b
Author: barraclough at apple.com <barraclough at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Jul 29 03:22:26 2010 +0000

    Bug 43162 - Add support for MADV_FREE to PageAllocation.
    
    Reviewed by Darin Adler.
    
    * wtf/PageAllocation.cpp:
    (WTF::PageAllocation::commit):
    (WTF::PageAllocation::decommit):
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@64261 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog
index 404746c..2e8c1d1 100644
--- a/JavaScriptCore/ChangeLog
+++ b/JavaScriptCore/ChangeLog
@@ -1,3 +1,13 @@
+2010-07-28  Gavin Barraclough  <barraclough at apple.com>
+
+        Reviewed by Darin Adler.
+
+        Bug 43162 - Add support for MADV_FREE to PageAllocation.
+
+        * wtf/PageAllocation.cpp:
+        (WTF::PageAllocation::commit):
+        (WTF::PageAllocation::decommit):
+
 2010-07-27  Kinuko Yasuda  <kinuko at chromium.org>
 
         Reviewed by Ojan Vafai.
diff --git a/JavaScriptCore/wtf/PageAllocation.cpp b/JavaScriptCore/wtf/PageAllocation.cpp
index 2e5f9cf..58a10f6 100644
--- a/JavaScriptCore/wtf/PageAllocation.cpp
+++ b/JavaScriptCore/wtf/PageAllocation.cpp
@@ -48,43 +48,30 @@ namespace WTF {
 
 #if HAVE(MMAP)
 
-#if HAVE(MADV_FREE_REUSE)
-bool PageAllocation::commit(void* start, size_t size, bool writable, bool executable) const
+bool PageAllocation::commit(void* start, size_t size, bool, bool) const
 {
-    UNUSED_PARAM(writable);
-    UNUSED_PARAM(executable);
+#if HAVE(MADV_FREE_REUSE)
     while (madvise(start, size, MADV_FREE_REUSE) == -1 && errno == EAGAIN) { }
+#else
+    UNUSED_PARAM(start);
+    UNUSED_PARAM(size);
+#endif
     return true;
 }
 
 void PageAllocation::decommit(void* start, size_t size) const
 {
+#if HAVE(MADV_FREE_REUSE)
     while (madvise(start, size, MADV_FREE_REUSABLE) == -1 && errno == EAGAIN) { }
-}
+#elif HAVE(MADV_FREE)
+    while (madvise(start, size, MADV_FREE) == -1 && errno == EAGAIN) { }
 #elif HAVE(MADV_DONTNEED)
-bool PageAllocation::commit(void* start, size_t size, bool writable, bool executable) const
-{
-    UNUSED_PARAM(writable);
-    UNUSED_PARAM(executable);
-    return true;
-}
-
-void PageAllocation::decommit(void*, size_t) const
-{
     while (madvise(start, size, MADV_DONTNEED) == -1 && errno == EAGAIN) { }
-}
 #else
-bool PageAllocation::commit(void*, size_t, bool writable, bool executable) const
-{
-    UNUSED_PARAM(writable);
-    UNUSED_PARAM(executable);
-    return true;
-}
-
-void PageAllocation::decommit(void*, size_t) const
-{
-}
+    UNUSED_PARAM(start);
+    UNUSED_PARAM(size);
 #endif
+}
 
 PageAllocation PageAllocation::allocate(size_t size, Usage usage, bool writable, bool executable)
 {

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list