Increase code space allowance for first page size.
authoryangguo <yangguo@chromium.org>
Tue, 30 Jun 2015 07:48:23 +0000 (00:48 -0700)
committerCommit bot <commit-bot@chromium.org>
Tue, 30 Jun 2015 07:48:34 +0000 (07:48 +0000)
This has become necessary as we have more experimental natives
that run after deserializing from the snapshot.

R=hpayer@chromium.org
BUG=v8:4200
LOG=N

Review URL: https://codereview.chromium.org/1218973002

Cr-Commit-Position: refs/heads/master@{#29367}

src/snapshot/snapshot-common.cc
test/cctest/cctest.status
test/cctest/test-spaces.cc

index 89fe8af..ab8a884 100644 (file)
@@ -137,7 +137,7 @@ void CalculateFirstPageSizes(bool is_default_snapshot,
                   2 * context_reservations[context_index].chunk_size()) +
                  Page::kObjectStartOffset;
       // Add a small allowance to the code space for small scripts.
-      if (space == CODE_SPACE) required += 32 * KB;
+      if (space == CODE_SPACE) required += 64 * KB;
     } else {
       // We expect the vanilla snapshot to only require on page per space.
       DCHECK(!is_default_snapshot);
index 2ef8296..0686205 100644 (file)
 
   # BUG(v8:3434).
   ' test-api/LoadICFastApi_DirectCall_GCMoveStubWithProfiler': [SKIP],
-
-  # BUG(v8:4200).
-  'test-spaces/SizeOfFirstPageIsLargeEnough': [PASS, FAIL],
 }],  # 'arch == arm64'
 
 ['arch == arm64 and simulator_run == True', {
   'test-serialize/DeserializeFromSecondSerializationAndRunScript2': [SKIP],
   'test-serialize/DeserializeAndRunScript2': [SKIP],
   'test-serialize/DeserializeFromSecondSerialization': [SKIP],
-
-  # BUG(v8:4200).
-  'test-spaces/SizeOfFirstPageIsLargeEnough': [PASS, FAIL],
 }],  # 'arch == mips64el'
 
 ##############################################################################
index 85b33c9..3f5e437 100644 (file)
@@ -439,6 +439,9 @@ TEST(SizeOfFirstPageIsLargeEnough) {
   if (!isolate->snapshot_available()) return;
   if (Snapshot::EmbedsScript(isolate)) return;
 
+  // If this test fails due to enabling experimental natives that are not part
+  // of the snapshot, we may need to adjust CalculateFirstPageSizes.
+
   // Freshly initialized VM gets by with one page per space.
   for (int i = FIRST_PAGED_SPACE; i <= LAST_PAGED_SPACE; i++) {
     // Debug code can be very large, so skip CODE_SPACE if we are generating it.