Title: [227168] trunk/Source/_javascript_Core
Revision
227168
Author
[email protected]
Date
2018-01-18 15:53:23 -0800 (Thu, 18 Jan 2018)

Log Message

Set the minimum executable allocator size properly
https://bugs.webkit.org/show_bug.cgi?id=181816
<rdar://problem/36635533>

Reviewed by Saam Barati.

Executable allocator expects at least two page size's worth of
allocation in certain conditions, and that causes some tests to
now fail because they ask for less. Set that minimum correctly. We
were already rounding up to a page size, so having a minimum of 2
page sizes is fine.

* jit/ExecutableAllocator.cpp:
(JSC::FixedVMPoolExecutableAllocator::FixedVMPoolExecutableAllocator):

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (227167 => 227168)


--- trunk/Source/_javascript_Core/ChangeLog	2018-01-18 23:39:27 UTC (rev 227167)
+++ trunk/Source/_javascript_Core/ChangeLog	2018-01-18 23:53:23 UTC (rev 227168)
@@ -1,3 +1,20 @@
+2018-01-18  JF Bastien  <[email protected]>
+
+        Set the minimum executable allocator size properly
+        https://bugs.webkit.org/show_bug.cgi?id=181816
+        <rdar://problem/36635533>
+
+        Reviewed by Saam Barati.
+
+        Executable allocator expects at least two page size's worth of
+        allocation in certain conditions, and that causes some tests to
+        now fail because they ask for less. Set that minimum correctly. We
+        were already rounding up to a page size, so having a minimum of 2
+        page sizes is fine.
+
+        * jit/ExecutableAllocator.cpp:
+        (JSC::FixedVMPoolExecutableAllocator::FixedVMPoolExecutableAllocator):
+
 2018-01-18  Michael Saboff  <[email protected]>
 
         Unreviewed build fix for Windows

Modified: trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp (227167 => 227168)


--- trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp	2018-01-18 23:39:27 UTC (rev 227167)
+++ trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp	2018-01-18 23:53:23 UTC (rev 227168)
@@ -121,7 +121,7 @@
             reservationSize = Options::jitMemoryReservationSize();
         else
             reservationSize = fixedExecutableMemoryPoolSize;
-        reservationSize = roundUpToMultipleOf(pageSize(), reservationSize);
+        reservationSize = std::max(roundUpToMultipleOf(pageSize(), reservationSize), pageSize() * 2);
         m_reservation = PageReservation::reserveWithGuardPages(reservationSize, OSAllocator::JSJITCodePages, EXECUTABLE_POOL_WRITABLE, true);
         if (m_reservation) {
             ASSERT(m_reservation.size() == reservationSize);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to