Title: [276858] trunk/Source/_javascript_Core
Revision
276858
Author
fpi...@apple.com
Date
2021-04-30 15:48:43 -0700 (Fri, 30 Apr 2021)

Log Message

Make small JIT pool tests pass on AS
https://bugs.webkit.org/show_bug.cgi?id=225256

Reviewed by Mark Lam.

If we ask for a JIT pool that is smaller than the smallest possible "region" (thing with jump
island) that we can create -- i.e. smaller than a jump region, then assume that the user is
asking us to create a pool that has that much usable space plus a jump region.

I think that this makes the option easier to use when you're testing ridiculously small JIT
pools, which we happen to do in our test suite.

Also remove some dead options I didn't mean to commit.

* jit/ExecutableAllocator.cpp:
(JSC::initializeJITPageReservation):
* runtime/OptionsList.h:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (276857 => 276858)


--- trunk/Source/_javascript_Core/ChangeLog	2021-04-30 22:25:33 UTC (rev 276857)
+++ trunk/Source/_javascript_Core/ChangeLog	2021-04-30 22:48:43 UTC (rev 276858)
@@ -1,5 +1,25 @@
 2021-04-30  Filip Pizlo  <fpi...@apple.com>
 
+        Make small JIT pool tests pass on AS
+        https://bugs.webkit.org/show_bug.cgi?id=225256
+
+        Reviewed by Mark Lam.
+
+        If we ask for a JIT pool that is smaller than the smallest possible "region" (thing with jump
+        island) that we can create -- i.e. smaller than a jump region, then assume that the user is
+        asking us to create a pool that has that much usable space plus a jump region.
+
+        I think that this makes the option easier to use when you're testing ridiculously small JIT
+        pools, which we happen to do in our test suite.
+
+        Also remove some dead options I didn't mean to commit.
+
+        * jit/ExecutableAllocator.cpp:
+        (JSC::initializeJITPageReservation):
+        * runtime/OptionsList.h:
+
+2021-04-30  Filip Pizlo  <fpi...@apple.com>
+
         Make the JIT pool smaller on AS
         https://bugs.webkit.org/show_bug.cgi?id=225249
 

Modified: trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp (276857 => 276858)


--- trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp	2021-04-30 22:25:33 UTC (rev 276857)
+++ trunk/Source/_javascript_Core/jit/ExecutableAllocator.cpp	2021-04-30 22:48:43 UTC (rev 276858)
@@ -332,9 +332,20 @@
 
     reservation.size = fixedExecutableMemoryPoolSize;
 
-    if (Options::jitMemoryReservationSize())
+    if (Options::jitMemoryReservationSize()) {
         reservation.size = Options::jitMemoryReservationSize();
 
+#if ENABLE(JUMP_ISLANDS)
+        // If asked for a reservation smaller than island size, assume that we want that size allocation
+        // plus an island. The alternative would be to turn off jump islands, but since we only use
+        // this for testing, this is probably the easier way to do it.
+        //
+        // The main reason for this is that some JSC stress tests run with a 50KB pool. This hack means
+        // we don't have to change anything about those tests.
+        if (reservation.size < islandRegionSize)
+            reservation.size += islandRegionSize;
+#endif // ENABLE(JUMP_ISLANDS)
+    }
     reservation.size = std::max(roundUpToMultipleOf(pageSize(), reservation.size), pageSize() * 2);
 
     auto tryCreatePageReservation = [] (size_t reservationSize) {

Modified: trunk/Source/_javascript_Core/runtime/OptionsList.h (276857 => 276858)


--- trunk/Source/_javascript_Core/runtime/OptionsList.h	2021-04-30 22:25:33 UTC (rev 276857)
+++ trunk/Source/_javascript_Core/runtime/OptionsList.h	2021-04-30 22:48:43 UTC (rev 276858)
@@ -532,8 +532,6 @@
     v(Bool, useErrorCause, true, Normal, "Allow a cause to be provided when constructing an Error, _NativeError_, or AggregateError.") \
     v(Bool, useSharedArrayBuffer, false, Normal, nullptr) \
     v(Bool, useTopLevelAwait, true, Normal, "allow the await keyword at the top level of a module.") \
-    v(Bool, dumpLinking, false, Normal, nullptr) \
-    v(Bool, verifySame4GBLink, false, Normal, nullptr) \
     v(Bool, verboseExecutablePoolAllocation, false, Normal, nullptr) \
 
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to