summaryrefslogtreecommitdiff
path: root/deps/v8/src/heap/setup-heap-internal.cc
diff options
context:
space:
mode:
Diffstat (limited to 'deps/v8/src/heap/setup-heap-internal.cc')
-rw-r--r--deps/v8/src/heap/setup-heap-internal.cc18
1 files changed, 12 insertions, 6 deletions
diff --git a/deps/v8/src/heap/setup-heap-internal.cc b/deps/v8/src/heap/setup-heap-internal.cc
index 8831417ce2..9e2d7e6354 100644
--- a/deps/v8/src/heap/setup-heap-internal.cc
+++ b/deps/v8/src/heap/setup-heap-internal.cc
@@ -17,6 +17,7 @@
#include "src/lookup-cache.h"
#include "src/objects-inl.h"
#include "src/objects/arguments.h"
+#include "src/objects/data-handler.h"
#include "src/objects/debug-objects.h"
#include "src/objects/descriptor-array.h"
#include "src/objects/dictionary.h"
@@ -69,6 +70,11 @@ const Heap::StructTable Heap::struct_table[] = {
{NAME##_TYPE, Name::kSize, k##Name##MapRootIndex},
STRUCT_LIST(STRUCT_TABLE_ELEMENT)
#undef STRUCT_TABLE_ELEMENT
+
+#define DATA_HANDLER_ELEMENT(NAME, Name, Size, name) \
+ {NAME##_TYPE, Name::kSizeWithData##Size, k##Name##Size##MapRootIndex},
+ DATA_HANDLER_LIST(DATA_HANDLER_ELEMENT)
+#undef DATA_HANDLER_ELEMENT
};
namespace {
@@ -188,9 +194,9 @@ bool Heap::CreateInitialMaps() {
FinalizePartialMap(this, fixed_cow_array_map());
FinalizePartialMap(this, descriptor_array_map());
FinalizePartialMap(this, undefined_map());
- undefined_map()->set_is_undetectable();
+ undefined_map()->set_is_undetectable(true);
FinalizePartialMap(this, null_map());
- null_map()->set_is_undetectable();
+ null_map()->set_is_undetectable(true);
FinalizePartialMap(this, the_hole_map());
for (unsigned i = 0; i < arraysize(struct_table); ++i) {
const StructTable& entry = struct_table[i];
@@ -300,6 +306,8 @@ bool Heap::CreateInitialMaps() {
ALLOCATE_VARSIZE_MAP(HASH_TABLE_TYPE, string_table)
ALLOCATE_VARSIZE_MAP(HASH_TABLE_TYPE, weak_hash_table)
+ ALLOCATE_VARSIZE_MAP(FIXED_ARRAY_TYPE, array_list)
+
ALLOCATE_VARSIZE_MAP(FIXED_ARRAY_TYPE, function_context)
ALLOCATE_VARSIZE_MAP(FIXED_ARRAY_TYPE, catch_context)
ALLOCATE_VARSIZE_MAP(FIXED_ARRAY_TYPE, with_context)
@@ -551,9 +559,7 @@ void Heap::CreateInitialObjects() {
set_weak_object_to_code_table(*WeakHashTable::New(isolate(), 16, TENURED));
- set_weak_new_space_object_to_code_list(
- ArrayList::cast(*(factory->NewFixedArray(16, TENURED))));
- weak_new_space_object_to_code_list()->SetLength(0);
+ set_weak_new_space_object_to_code_list(*ArrayList::New(isolate(), 16));
set_feedback_vectors_for_profiling_tools(undefined_value());
@@ -632,7 +638,7 @@ void Heap::CreateInitialObjects() {
cell->set_value(Smi::FromInt(Isolate::kProtectorValid));
set_array_buffer_neutering_protector(*cell);
- set_serialized_templates(empty_fixed_array());
+ set_serialized_objects(empty_fixed_array());
set_serialized_global_proxy_sizes(empty_fixed_array());
set_weak_stack_trace_list(Smi::kZero);