Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(485)

Unified Diff: src/heap/heap.cc

Issue 604373008: Serialize all external strings except for native source code strings. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/heap/heap.h ('k') | src/serialize.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap.cc
diff --git a/src/heap/heap.cc b/src/heap/heap.cc
index 61152ad477c91f56fee3437b02cc5913ab2f8e1c..0ccd0ab2f2b86ddab87573070841954d5f53c548 100644
--- a/src/heap/heap.cc
+++ b/src/heap/heap.cc
@@ -2522,6 +2522,13 @@ bool Heap::CreateInitialMaps() {
roots_[entry.index] = map;
}
+ { // Create a separate external one byte string map for native sources.
+ AllocationResult allocation = AllocateMap(EXTERNAL_ONE_BYTE_STRING_TYPE,
+ ExternalOneByteString::kSize);
+ if (!allocation.To(&obj)) return false;
+ set_native_source_string_map(Map::cast(obj));
+ }
+
ALLOCATE_VARSIZE_MAP(STRING_TYPE, undetectable_string)
undetectable_string_map()->set_is_undetectable();
« no previous file with comments | « src/heap/heap.h ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698