[runtime] Add ReadOnlyRoots.empty_array_list()

- Simplify HeapObject::IsArrayList check
- Dehandlify ArrayList initialization
- Prevent auto-formatting of v8heapconst.py

Change-Id: I9849ad82dae1a2dc671433e8d5eb8ec63ed830c9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3447906
Reviewed-by: Shu-yu Guo <syg@chromium.org>
Reviewed-by: Simon Zünd <szuend@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Auto-Submit: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#79114}
This commit is contained in:
Camillo Bruni 2022-02-15 23:18:48 +01:00 committed by V8 LUCI CQ
parent c680e6d352
commit cc0a8ae4ee
13 changed files with 295 additions and 245 deletions

View File

@ -612,7 +612,8 @@ std::unique_ptr<Coverage> Coverage::CollectPrecise(Isolate* isolate) {
isolate->is_block_binary_code_coverage())) {
// We do not have to hold onto feedback vectors for invocations we already
// reported. So we can reset the list.
isolate->SetFeedbackVectorsForProfilingTools(*ArrayList::New(isolate, 0));
isolate->SetFeedbackVectorsForProfilingTools(
ReadOnlyRoots(isolate).empty_array_list());
}
return result;
}

View File

@ -570,6 +570,16 @@ void EmbedderDataArray::EmbedderDataArrayVerify(Isolate* isolate) {
}
}
void FixedArray::FixedArrayVerify(Isolate* isolate) {
TorqueGeneratedClassVerifiers::FixedArrayVerify(*this, isolate);
if (*this == ReadOnlyRoots(isolate).empty_fixed_array()) {
CHECK_EQ(length(), 0);
CHECK_EQ(map(), ReadOnlyRoots(isolate).fixed_array_map());
} else if (IsArrayList()) {
ArrayList::cast(*this).ArrayListVerify(isolate);
}
}
void WeakFixedArray::WeakFixedArrayVerify(Isolate* isolate) {
TorqueGeneratedClassVerifiers::WeakFixedArrayVerify(*this, isolate);
for (int i = 0; i < length(); i++) {
@ -577,6 +587,17 @@ void WeakFixedArray::WeakFixedArrayVerify(Isolate* isolate) {
}
}
void ArrayList::ArrayListVerify(Isolate* isolate) {
// Avoid calling the torque-generated ArrayListVerify to prevent an endlessly
// recursion verification.
CHECK(IsArrayList());
CHECK_LE(ArrayList::kLengthIndex, length());
CHECK_LE(0, Length());
if (Length() == 0 && length() == ArrayList::kLengthIndex) {
CHECK_EQ(*this, ReadOnlyRoots(isolate).empty_array_list());
}
}
void PropertyArray::PropertyArrayVerify(Isolate* isolate) {
TorqueGeneratedClassVerifiers::PropertyArrayVerify(*this, isolate);
if (length() == 0) {

View File

@ -252,9 +252,6 @@ Handle<Script> FactoryBase<Impl>::NewScriptWithId(
DCHECK(source->IsString() || source->IsUndefined());
// Create and initialize script object.
ReadOnlyRoots roots = read_only_roots();
#ifdef V8_SCRIPTORMODULE_LEGACY_LIFETIME
Handle<ArrayList> list = NewArrayList(0, AllocationType::kOld);
#endif
Handle<Script> script = handle(
NewStructInternal<Script>(SCRIPT_TYPE, AllocationType::kOld), isolate());
{
@ -276,7 +273,7 @@ Handle<Script> FactoryBase<Impl>::NewScriptWithId(
raw.set_flags(0);
raw.set_host_defined_options(roots.empty_fixed_array(), SKIP_WRITE_BARRIER);
#ifdef V8_SCRIPTORMODULE_LEGACY_LIFETIME
raw.set_script_or_modules(*list);
raw.set_script_or_modules(roots.empty_array_list());
#endif
}
@ -291,12 +288,16 @@ Handle<Script> FactoryBase<Impl>::NewScriptWithId(
template <typename Impl>
Handle<ArrayList> FactoryBase<Impl>::NewArrayList(int size,
AllocationType allocation) {
if (size == 0) return impl()->empty_array_list();
Handle<FixedArray> fixed_array =
NewFixedArray(size + ArrayList::kFirstIndex, allocation);
fixed_array->set_map_no_write_barrier(read_only_roots().array_list_map());
Handle<ArrayList> result = Handle<ArrayList>::cast(fixed_array);
result->SetLength(0);
return result;
{
DisallowGarbageCollection no_gc;
FixedArray raw = *fixed_array;
raw.set_map_no_write_barrier(read_only_roots().array_list_map());
ArrayList::cast(raw).SetLength(0);
}
return Handle<ArrayList>::cast(fixed_array);
}
template <typename Impl>

View File

@ -1488,7 +1488,6 @@ Handle<WasmTypeInfo> Factory::NewWasmTypeInfo(
// The supertypes list is constant after initialization, so we pretenure
// that too. The subtypes list, however, is expected to grow (and hence be
// replaced), so we don't pretenure it.
Handle<ArrayList> subtypes = ArrayList::New(isolate(), 0);
Handle<FixedArray> supertypes;
if (opt_parent.is_null()) {
supertypes = NewFixedArray(wasm::kMinimumSupertypeArraySize);
@ -1517,7 +1516,7 @@ Handle<WasmTypeInfo> Factory::NewWasmTypeInfo(
result.AllocateExternalPointerEntries(isolate());
result.set_foreign_address(isolate(), type_address);
result.set_supertypes(*supertypes);
result.set_subtypes(*subtypes);
result.set_subtypes(ReadOnlyRoots(isolate()).empty_array_list());
result.set_instance_size(instance_size_bytes);
result.set_instance(*instance);
return handle(result, isolate());
@ -2746,7 +2745,6 @@ Handle<SourceTextModule> Factory::NewSourceTextModule(
Handle<FixedArray> requested_modules =
requested_modules_length > 0 ? NewFixedArray(requested_modules_length)
: empty_fixed_array();
Handle<ArrayList> async_parent_modules = ArrayList::New(isolate(), 0);
ReadOnlyRoots roots(isolate());
SourceTextModule module = SourceTextModule::cast(
@ -2770,7 +2768,7 @@ Handle<SourceTextModule> Factory::NewSourceTextModule(
module.set_async(IsAsyncModule(sfi->kind()));
module.set_async_evaluating_ordinal(SourceTextModule::kNotAsyncEvaluated);
module.set_cycle_root(roots.the_hole_value(), SKIP_WRITE_BARRIER);
module.set_async_parent_modules(*async_parent_modules);
module.set_async_parent_modules(roots.empty_array_list());
module.set_pending_async_dependencies(0);
return handle(module, isolate());
}

View File

@ -250,7 +250,6 @@ bool Heap::CreateInitialMaps() {
#undef ALLOCATE_PARTIAL_MAP
}
// Allocate the empty array.
{
AllocationResult alloc =
AllocateRaw(FixedArray::SizeFor(0), AllocationType::kReadOnly);
@ -534,6 +533,15 @@ bool Heap::CreateInitialMaps() {
#undef ALLOCATE_VARSIZE_MAP
#undef ALLOCATE_MAP
}
{
AllocationResult alloc = AllocateRaw(
ArrayList::SizeFor(ArrayList::kFirstIndex), AllocationType::kReadOnly);
if (!alloc.To(&obj)) return false;
obj.set_map_after_allocation(roots.array_list_map(), SKIP_WRITE_BARRIER);
ArrayList::cast(obj).set_length(ArrayList::kFirstIndex);
ArrayList::cast(obj).SetLength(0);
}
set_empty_array_list(ArrayList::cast(obj));
{
AllocationResult alloc =
@ -785,6 +793,7 @@ void Heap::CreateInitialObjects() {
Handle<NameDictionary> empty_property_dictionary = NameDictionary::New(
isolate(), 1, AllocationType::kReadOnly, USE_CUSTOM_MINIMUM_CAPACITY);
DCHECK(!empty_property_dictionary->HasSufficientCapacityToAdd(1));
set_empty_property_dictionary(*empty_property_dictionary);
set_public_symbol_table(*empty_property_dictionary);
@ -794,7 +803,7 @@ void Heap::CreateInitialObjects() {
set_number_string_cache(*factory->NewFixedArray(
kInitialNumberStringCacheSize * 2, AllocationType::kOld));
set_basic_block_profiling_data(ArrayList::cast(roots.empty_fixed_array()));
set_basic_block_profiling_data(roots.empty_array_list());
// Allocate cache for string split and regexp-multiple.
set_string_split_cache(*factory->NewFixedArray(

View File

@ -198,6 +198,7 @@ class FixedArray
// Dispatched behavior.
DECL_PRINTER(FixedArray)
DECL_VERIFIER(FixedArray)
int AllocatedSize();
@ -383,7 +384,7 @@ class WeakArrayList
inline void CopyElements(Isolate* isolate, int dst_index, WeakArrayList src,
int src_index, int len, WriteBarrierMode mode);
V8_EXPORT_PRIVATE bool IsFull();
V8_EXPORT_PRIVATE bool IsFull() const;
int AllocatedSize();
@ -485,6 +486,8 @@ class ArrayList : public TorqueGeneratedArrayList<ArrayList, FixedArray> {
static const int kFirstIndex = 1;
STATIC_ASSERT(kHeaderFields == kFirstIndex);
DECL_VERIFIER(ArrayList)
private:
static Handle<ArrayList> EnsureSpace(Isolate* isolate,
Handle<ArrayList> array, int length);

View File

@ -303,9 +303,8 @@ bool Object::IsNumeric(PtrComprCageBase cage_base) const {
}
DEF_GETTER(HeapObject, IsArrayList, bool) {
ReadOnlyRoots roots = GetReadOnlyRoots(cage_base);
return *this == roots.empty_fixed_array() ||
map(cage_base) == roots.array_list_map();
return map(cage_base) ==
GetReadOnlyRoots(cage_base).unchecked_array_list_map();
}
DEF_GETTER(HeapObject, IsRegExpMatchInfo, bool) {

View File

@ -4056,15 +4056,11 @@ Handle<FixedArray> EnsureSpaceInFixedArray(Isolate* isolate,
// static
Handle<ArrayList> ArrayList::EnsureSpace(Isolate* isolate,
Handle<ArrayList> array, int length) {
const bool empty = (array->length() == 0);
Handle<FixedArray> ret =
EnsureSpaceInFixedArray(isolate, array, kFirstIndex + length);
if (empty) {
ret->set_map_no_write_barrier(array->GetReadOnlyRoots().array_list_map());
Handle<ArrayList>::cast(ret)->SetLength(0);
}
return Handle<ArrayList>::cast(ret);
DCHECK_LT(0, length);
auto new_array = Handle<ArrayList>::cast(
EnsureSpaceInFixedArray(isolate, array, kFirstIndex + length));
DCHECK_EQ(array->Length(), new_array->Length());
return new_array;
}
// static
@ -4073,10 +4069,14 @@ Handle<WeakArrayList> WeakArrayList::AddToEnd(Isolate* isolate,
const MaybeObjectHandle& value) {
int length = array->length();
array = EnsureSpace(isolate, array, length + 1);
// Reload length; GC might have removed elements from the array.
length = array->length();
array->Set(length, *value);
array->set_length(length + 1);
{
DisallowGarbageCollection no_gc;
WeakArrayList raw = *array;
// Reload length; GC might have removed elements from the array.
length = raw.length();
raw.Set(length, *value);
raw.set_length(length + 1);
}
return array;
}
@ -4086,11 +4086,15 @@ Handle<WeakArrayList> WeakArrayList::AddToEnd(Isolate* isolate,
const MaybeObjectHandle& value2) {
int length = array->length();
array = EnsureSpace(isolate, array, length + 2);
// Reload length; GC might have removed elements from the array.
length = array->length();
array->Set(length, *value1);
array->Set(length + 1, *value2);
array->set_length(length + 2);
{
DisallowGarbageCollection no_gc;
WeakArrayList raw = *array;
// Reload length; GC might have removed elements from the array.
length = array->length();
raw.Set(length, *value1);
raw.Set(length + 1, *value2);
raw.set_length(length + 2);
}
return array;
}
@ -4099,18 +4103,24 @@ Handle<WeakArrayList> WeakArrayList::Append(Isolate* isolate,
Handle<WeakArrayList> array,
const MaybeObjectHandle& value,
AllocationType allocation) {
int length = array->length();
int length = 0;
int new_length = 0;
{
DisallowGarbageCollection no_gc;
WeakArrayList raw = *array;
length = raw.length();
if (length < array->capacity()) {
array->Set(length, *value);
array->set_length(length + 1);
return array;
if (length < raw.capacity()) {
raw.Set(length, *value);
raw.set_length(length + 1);
return array;
}
// Not enough space in the array left, either grow, shrink or
// compact the array.
new_length = raw.CountLiveElements() + 1;
}
// Not enough space in the array left, either grow, shrink or
// compact the array.
int new_length = array->CountLiveElements() + 1;
bool shrink = new_length < length / 4;
bool grow = 3 * (length / 4) < new_length;
@ -4128,14 +4138,19 @@ Handle<WeakArrayList> WeakArrayList::Append(Isolate* isolate,
// Now append value to the array, there should always be enough space now.
DCHECK_LT(array->length(), array->capacity());
// Reload length, allocation might have killed some weak refs.
int index = array->length();
array->Set(index, *value);
array->set_length(index + 1);
{
DisallowGarbageCollection no_gc;
WeakArrayList raw = *array;
// Reload length, allocation might have killed some weak refs.
int index = raw.length();
raw.Set(index, *value);
raw.set_length(index + 1);
}
return array;
}
void WeakArrayList::Compact(Isolate* isolate) {
DisallowGarbageCollection no_gc;
int length = this->length();
int new_length = 0;
@ -4153,7 +4168,7 @@ void WeakArrayList::Compact(Isolate* isolate) {
set_length(new_length);
}
bool WeakArrayList::IsFull() { return length() == capacity(); }
bool WeakArrayList::IsFull() const { return length() == capacity(); }
// static
Handle<WeakArrayList> WeakArrayList::EnsureSpace(Isolate* isolate,

View File

@ -1038,8 +1038,7 @@ MaybeHandle<Object> SourceTextModule::InnerModuleEvaluation(
DCHECK(!module->HasPendingAsyncDependencies());
// 9. Set module.[[AsyncParentModules]] to a new empty List.
Handle<ArrayList> async_parent_modules = ArrayList::New(isolate, 0);
module->set_async_parent_modules(*async_parent_modules);
module->set_async_parent_modules(ReadOnlyRoots(isolate).empty_array_list());
// 10. Set index to index + 1.
(*dfs_index)++;

View File

@ -187,6 +187,7 @@ class Symbol;
V(SwissNameDictionary, empty_swiss_property_dictionary, \
EmptySwissPropertyDictionary) \
V(InterceptorInfo, noop_interceptor_info, NoOpInterceptorInfo) \
V(ArrayList, empty_array_list, EmptyArrayList) \
V(WeakFixedArray, empty_weak_fixed_array, EmptyWeakFixedArray) \
V(WeakArrayList, empty_weak_array_list, EmptyWeakArrayList) \
/* Special numbers */ \

View File

@ -15,8 +15,7 @@ TEST(ArrayList) {
LocalContext context;
Isolate* isolate = CcTest::i_isolate();
HandleScope scope(isolate);
Handle<ArrayList> array(
ArrayList::cast(ReadOnlyRoots(isolate).empty_fixed_array()), isolate);
Handle<ArrayList> array = ReadOnlyRoots(isolate).empty_array_list_handle();
CHECK_EQ(0, array->Length());
array = ArrayList::Add(isolate, array, handle(Smi::FromInt(100), isolate));
CHECK_EQ(1, array->Length());

View File

@ -26,7 +26,8 @@ static const char* kHeader =
"# This file is automatically generated by mkgrokdump and should not\n"
"# be modified manually.\n"
"\n"
"# List of known V8 instance types.\n";
"# List of known V8 instance types.\n"
"# yapf: disable\n\n";
// Debug builds emit debug code, affecting code object sizes.
#ifndef DEBUG
@ -59,8 +60,8 @@ static void DumpKnownMap(FILE* out, i::Heap* heap, const char* space_name,
MUTABLE_ROOT_LIST(MUTABLE_ROOT_LIST_CASE)
if (root_name == nullptr) return;
i::PrintF(out, " (\"%s\", 0x%05" V8PRIxPTR "): (%d, \"%s\"),\n", space_name,
root_ptr, map.instance_type(), root_name);
i::PrintF(out, " (\"%s\", 0x%05" V8PRIxPTR "): (%d, \"%s\"),\n",
space_name, root_ptr, map.instance_type(), root_name);
#undef MUTABLE_ROOT_LIST_CASE
#undef RO_ROOT_LIST_CASE

View File

@ -6,6 +6,8 @@
# be modified manually.
# List of known V8 instance types.
# yapf: disable
INSTANCE_TYPES = {
0: "INTERNALIZED_STRING_TYPE",
2: "EXTERNAL_INTERNALIZED_STRING_TYPE",
@ -267,182 +269,182 @@ INSTANCE_TYPES = {
# List of known V8 maps.
KNOWN_MAPS = {
("read_only_space", 0x02149): (248, "MetaMap"),
("read_only_space", 0x02171): (131, "NullMap"),
("read_only_space", 0x02199): (232, "StrongDescriptorArrayMap"),
("read_only_space", 0x021c1): (262, "WeakArrayListMap"),
("read_only_space", 0x02205): (157, "EnumCacheMap"),
("read_only_space", 0x02239): (178, "FixedArrayMap"),
("read_only_space", 0x02285): (8, "OneByteInternalizedStringMap"),
("read_only_space", 0x022d1): (245, "FreeSpaceMap"),
("read_only_space", 0x022f9): (244, "OnePointerFillerMap"),
("read_only_space", 0x02321): (244, "TwoPointerFillerMap"),
("read_only_space", 0x02349): (131, "UninitializedMap"),
("read_only_space", 0x023c1): (131, "UndefinedMap"),
("read_only_space", 0x02405): (130, "HeapNumberMap"),
("read_only_space", 0x02439): (131, "TheHoleMap"),
("read_only_space", 0x02499): (131, "BooleanMap"),
("read_only_space", 0x0253d): (192, "ByteArrayMap"),
("read_only_space", 0x02565): (178, "FixedCOWArrayMap"),
("read_only_space", 0x0258d): (179, "HashTableMap"),
("read_only_space", 0x025b5): (128, "SymbolMap"),
("read_only_space", 0x025dd): (40, "OneByteStringMap"),
("read_only_space", 0x02605): (254, "ScopeInfoMap"),
("read_only_space", 0x0262d): (255, "SharedFunctionInfoMap"),
("read_only_space", 0x02655): (238, "CodeMap"),
("read_only_space", 0x0267d): (237, "CellMap"),
("read_only_space", 0x026a5): (253, "GlobalPropertyCellMap"),
("read_only_space", 0x026cd): (204, "ForeignMap"),
("read_only_space", 0x026f5): (236, "TransitionArrayMap"),
("read_only_space", 0x0271d): (45, "ThinOneByteStringMap"),
("read_only_space", 0x02745): (243, "FeedbackVectorMap"),
("read_only_space", 0x0277d): (131, "ArgumentsMarkerMap"),
("read_only_space", 0x027dd): (131, "ExceptionMap"),
("read_only_space", 0x02839): (131, "TerminationExceptionMap"),
("read_only_space", 0x028a1): (131, "OptimizedOutMap"),
("read_only_space", 0x02901): (131, "StaleRegisterMap"),
("read_only_space", 0x02961): (191, "ScriptContextTableMap"),
("read_only_space", 0x02989): (189, "ClosureFeedbackCellArrayMap"),
("read_only_space", 0x029b1): (242, "FeedbackMetadataArrayMap"),
("read_only_space", 0x029d9): (178, "ArrayListMap"),
("read_only_space", 0x02a01): (129, "BigIntMap"),
("read_only_space", 0x02a29): (190, "ObjectBoilerplateDescriptionMap"),
("read_only_space", 0x02a51): (193, "BytecodeArrayMap"),
("read_only_space", 0x02a79): (239, "CodeDataContainerMap"),
("read_only_space", 0x02aa1): (240, "CoverageInfoMap"),
("read_only_space", 0x02ac9): (194, "FixedDoubleArrayMap"),
("read_only_space", 0x02af1): (181, "GlobalDictionaryMap"),
("read_only_space", 0x02b19): (159, "ManyClosuresCellMap"),
("read_only_space", 0x02b41): (249, "MegaDomHandlerMap"),
("read_only_space", 0x02b69): (178, "ModuleInfoMap"),
("read_only_space", 0x02b91): (182, "NameDictionaryMap"),
("read_only_space", 0x02bb9): (159, "NoClosuresCellMap"),
("read_only_space", 0x02be1): (184, "NumberDictionaryMap"),
("read_only_space", 0x02c09): (159, "OneClosureCellMap"),
("read_only_space", 0x02c31): (185, "OrderedHashMapMap"),
("read_only_space", 0x02c59): (186, "OrderedHashSetMap"),
("read_only_space", 0x02c81): (183, "NameToIndexHashTableMap"),
("read_only_space", 0x02ca9): (187, "OrderedNameDictionaryMap"),
("read_only_space", 0x02cd1): (251, "PreparseDataMap"),
("read_only_space", 0x02cf9): (252, "PropertyArrayMap"),
("read_only_space", 0x02d21): (153, "SideEffectCallHandlerInfoMap"),
("read_only_space", 0x02d49): (153, "SideEffectFreeCallHandlerInfoMap"),
("read_only_space", 0x02d71): (153, "NextCallSideEffectFreeCallHandlerInfoMap"),
("read_only_space", 0x02d99): (188, "SimpleNumberDictionaryMap"),
("read_only_space", 0x02dc1): (228, "SmallOrderedHashMapMap"),
("read_only_space", 0x02de9): (229, "SmallOrderedHashSetMap"),
("read_only_space", 0x02e11): (230, "SmallOrderedNameDictionaryMap"),
("read_only_space", 0x02e39): (233, "SourceTextModuleMap"),
("read_only_space", 0x02e61): (259, "SwissNameDictionaryMap"),
("read_only_space", 0x02e89): (234, "SyntheticModuleMap"),
("read_only_space", 0x02eb1): (260, "WasmApiFunctionRefMap"),
("read_only_space", 0x02ed9): (222, "WasmCapiFunctionDataMap"),
("read_only_space", 0x02f01): (223, "WasmExportedFunctionDataMap"),
("read_only_space", 0x02f29): (205, "WasmInternalFunctionMap"),
("read_only_space", 0x02f51): (224, "WasmJSFunctionDataMap"),
("read_only_space", 0x02f79): (261, "WasmOnFulfilledDataMap"),
("read_only_space", 0x02fa1): (206, "WasmTypeInfoMap"),
("read_only_space", 0x02fc9): (235, "WeakFixedArrayMap"),
("read_only_space", 0x02ff1): (180, "EphemeronHashTableMap"),
("read_only_space", 0x03019): (241, "EmbedderDataArrayMap"),
("read_only_space", 0x03041): (263, "WeakCellMap"),
("read_only_space", 0x03069): (32, "StringMap"),
("read_only_space", 0x03091): (41, "ConsOneByteStringMap"),
("read_only_space", 0x030b9): (33, "ConsStringMap"),
("read_only_space", 0x030e1): (37, "ThinStringMap"),
("read_only_space", 0x03109): (35, "SlicedStringMap"),
("read_only_space", 0x03131): (43, "SlicedOneByteStringMap"),
("read_only_space", 0x03159): (34, "ExternalStringMap"),
("read_only_space", 0x03181): (42, "ExternalOneByteStringMap"),
("read_only_space", 0x031a9): (50, "UncachedExternalStringMap"),
("read_only_space", 0x031d1): (0, "InternalizedStringMap"),
("read_only_space", 0x031f9): (2, "ExternalInternalizedStringMap"),
("read_only_space", 0x03221): (10, "ExternalOneByteInternalizedStringMap"),
("read_only_space", 0x03249): (18, "UncachedExternalInternalizedStringMap"),
("read_only_space", 0x03271): (26, "UncachedExternalOneByteInternalizedStringMap"),
("read_only_space", 0x03299): (58, "UncachedExternalOneByteStringMap"),
("read_only_space", 0x032c1): (104, "SharedOneByteStringMap"),
("read_only_space", 0x032e9): (96, "SharedStringMap"),
("read_only_space", 0x03311): (109, "SharedThinOneByteStringMap"),
("read_only_space", 0x03339): (101, "SharedThinStringMap"),
("read_only_space", 0x03361): (96, "TwoByteSeqStringMigrationSentinelMap"),
("read_only_space", 0x03389): (104, "OneByteSeqStringMigrationSentinelMap"),
("read_only_space", 0x033b1): (131, "SelfReferenceMarkerMap"),
("read_only_space", 0x033d9): (131, "BasicBlockCountersMarkerMap"),
("read_only_space", 0x0341d): (147, "ArrayBoilerplateDescriptionMap"),
("read_only_space", 0x0351d): (161, "InterceptorInfoMap"),
("read_only_space", 0x05e5d): (132, "PromiseFulfillReactionJobTaskMap"),
("read_only_space", 0x05e85): (133, "PromiseRejectReactionJobTaskMap"),
("read_only_space", 0x05ead): (134, "CallableTaskMap"),
("read_only_space", 0x05ed5): (135, "CallbackTaskMap"),
("read_only_space", 0x05efd): (136, "PromiseResolveThenableJobTaskMap"),
("read_only_space", 0x05f25): (139, "FunctionTemplateInfoMap"),
("read_only_space", 0x05f4d): (140, "ObjectTemplateInfoMap"),
("read_only_space", 0x05f75): (141, "AccessCheckInfoMap"),
("read_only_space", 0x05f9d): (142, "AccessorInfoMap"),
("read_only_space", 0x05fc5): (143, "AccessorPairMap"),
("read_only_space", 0x05fed): (144, "AliasedArgumentsEntryMap"),
("read_only_space", 0x06015): (145, "AllocationMementoMap"),
("read_only_space", 0x0603d): (148, "AsmWasmDataMap"),
("read_only_space", 0x06065): (149, "AsyncGeneratorRequestMap"),
("read_only_space", 0x0608d): (150, "BreakPointMap"),
("read_only_space", 0x060b5): (151, "BreakPointInfoMap"),
("read_only_space", 0x060dd): (152, "CachedTemplateObjectMap"),
("read_only_space", 0x06105): (154, "CallSiteInfoMap"),
("read_only_space", 0x0612d): (155, "ClassPositionsMap"),
("read_only_space", 0x06155): (156, "DebugInfoMap"),
("read_only_space", 0x0617d): (158, "ErrorStackDataMap"),
("read_only_space", 0x061a5): (160, "FunctionTemplateRareDataMap"),
("read_only_space", 0x061cd): (162, "InterpreterDataMap"),
("read_only_space", 0x061f5): (163, "ModuleRequestMap"),
("read_only_space", 0x0621d): (164, "PromiseCapabilityMap"),
("read_only_space", 0x06245): (165, "PromiseReactionMap"),
("read_only_space", 0x0626d): (166, "PropertyDescriptorObjectMap"),
("read_only_space", 0x06295): (167, "PrototypeInfoMap"),
("read_only_space", 0x062bd): (168, "RegExpBoilerplateDescriptionMap"),
("read_only_space", 0x062e5): (169, "ScriptMap"),
("read_only_space", 0x0630d): (170, "ScriptOrModuleMap"),
("read_only_space", 0x06335): (171, "SourceTextModuleInfoEntryMap"),
("read_only_space", 0x0635d): (172, "StackFrameInfoMap"),
("read_only_space", 0x06385): (173, "TemplateObjectDescriptionMap"),
("read_only_space", 0x063ad): (174, "Tuple2Map"),
("read_only_space", 0x063d5): (175, "WasmContinuationObjectMap"),
("read_only_space", 0x063fd): (176, "WasmExceptionTagMap"),
("read_only_space", 0x06425): (177, "WasmIndirectFunctionTableMap"),
("read_only_space", 0x0644d): (196, "SloppyArgumentsElementsMap"),
("read_only_space", 0x06475): (231, "DescriptorArrayMap"),
("read_only_space", 0x0649d): (219, "UncompiledDataWithoutPreparseDataMap"),
("read_only_space", 0x064c5): (217, "UncompiledDataWithPreparseDataMap"),
("read_only_space", 0x064ed): (220, "UncompiledDataWithoutPreparseDataWithJobMap"),
("read_only_space", 0x06515): (218, "UncompiledDataWithPreparseDataAndJobMap"),
("read_only_space", 0x0653d): (250, "OnHeapBasicBlockProfilerDataMap"),
("read_only_space", 0x06565): (197, "TurbofanBitsetTypeMap"),
("read_only_space", 0x0658d): (201, "TurbofanUnionTypeMap"),
("read_only_space", 0x065b5): (200, "TurbofanRangeTypeMap"),
("read_only_space", 0x065dd): (198, "TurbofanHeapConstantTypeMap"),
("read_only_space", 0x06605): (199, "TurbofanOtherNumberConstantTypeMap"),
("read_only_space", 0x0662d): (246, "InternalClassMap"),
("read_only_space", 0x06655): (257, "SmiPairMap"),
("read_only_space", 0x0667d): (256, "SmiBoxMap"),
("read_only_space", 0x066a5): (225, "ExportedSubClassBaseMap"),
("read_only_space", 0x066cd): (226, "ExportedSubClassMap"),
("read_only_space", 0x066f5): (202, "AbstractInternalClassSubclass1Map"),
("read_only_space", 0x0671d): (203, "AbstractInternalClassSubclass2Map"),
("read_only_space", 0x06745): (195, "InternalClassWithSmiElementsMap"),
("read_only_space", 0x0676d): (247, "InternalClassWithStructElementsMap"),
("read_only_space", 0x06795): (227, "ExportedSubClass2Map"),
("read_only_space", 0x067bd): (258, "SortStateMap"),
("read_only_space", 0x067e5): (146, "AllocationSiteWithWeakNextMap"),
("read_only_space", 0x0680d): (146, "AllocationSiteWithoutWeakNextMap"),
("read_only_space", 0x06835): (137, "LoadHandler1Map"),
("read_only_space", 0x0685d): (137, "LoadHandler2Map"),
("read_only_space", 0x06885): (137, "LoadHandler3Map"),
("read_only_space", 0x068ad): (138, "StoreHandler0Map"),
("read_only_space", 0x068d5): (138, "StoreHandler1Map"),
("read_only_space", 0x068fd): (138, "StoreHandler2Map"),
("read_only_space", 0x06925): (138, "StoreHandler3Map"),
("map_space", 0x02149): (1057, "ExternalMap"),
("map_space", 0x02171): (2114, "JSMessageObjectMap"),
("read_only_space", 0x02149): (248, "MetaMap"),
("read_only_space", 0x02171): (131, "NullMap"),
("read_only_space", 0x02199): (232, "StrongDescriptorArrayMap"),
("read_only_space", 0x021c1): (262, "WeakArrayListMap"),
("read_only_space", 0x02205): (157, "EnumCacheMap"),
("read_only_space", 0x02239): (178, "FixedArrayMap"),
("read_only_space", 0x02285): (8, "OneByteInternalizedStringMap"),
("read_only_space", 0x022d1): (245, "FreeSpaceMap"),
("read_only_space", 0x022f9): (244, "OnePointerFillerMap"),
("read_only_space", 0x02321): (244, "TwoPointerFillerMap"),
("read_only_space", 0x02349): (131, "UninitializedMap"),
("read_only_space", 0x023c1): (131, "UndefinedMap"),
("read_only_space", 0x02405): (130, "HeapNumberMap"),
("read_only_space", 0x02439): (131, "TheHoleMap"),
("read_only_space", 0x02499): (131, "BooleanMap"),
("read_only_space", 0x0253d): (192, "ByteArrayMap"),
("read_only_space", 0x02565): (178, "FixedCOWArrayMap"),
("read_only_space", 0x0258d): (179, "HashTableMap"),
("read_only_space", 0x025b5): (128, "SymbolMap"),
("read_only_space", 0x025dd): (40, "OneByteStringMap"),
("read_only_space", 0x02605): (254, "ScopeInfoMap"),
("read_only_space", 0x0262d): (255, "SharedFunctionInfoMap"),
("read_only_space", 0x02655): (238, "CodeMap"),
("read_only_space", 0x0267d): (237, "CellMap"),
("read_only_space", 0x026a5): (253, "GlobalPropertyCellMap"),
("read_only_space", 0x026cd): (204, "ForeignMap"),
("read_only_space", 0x026f5): (236, "TransitionArrayMap"),
("read_only_space", 0x0271d): (45, "ThinOneByteStringMap"),
("read_only_space", 0x02745): (243, "FeedbackVectorMap"),
("read_only_space", 0x0277d): (131, "ArgumentsMarkerMap"),
("read_only_space", 0x027dd): (131, "ExceptionMap"),
("read_only_space", 0x02839): (131, "TerminationExceptionMap"),
("read_only_space", 0x028a1): (131, "OptimizedOutMap"),
("read_only_space", 0x02901): (131, "StaleRegisterMap"),
("read_only_space", 0x02961): (191, "ScriptContextTableMap"),
("read_only_space", 0x02989): (189, "ClosureFeedbackCellArrayMap"),
("read_only_space", 0x029b1): (242, "FeedbackMetadataArrayMap"),
("read_only_space", 0x029d9): (178, "ArrayListMap"),
("read_only_space", 0x02a01): (129, "BigIntMap"),
("read_only_space", 0x02a29): (190, "ObjectBoilerplateDescriptionMap"),
("read_only_space", 0x02a51): (193, "BytecodeArrayMap"),
("read_only_space", 0x02a79): (239, "CodeDataContainerMap"),
("read_only_space", 0x02aa1): (240, "CoverageInfoMap"),
("read_only_space", 0x02ac9): (194, "FixedDoubleArrayMap"),
("read_only_space", 0x02af1): (181, "GlobalDictionaryMap"),
("read_only_space", 0x02b19): (159, "ManyClosuresCellMap"),
("read_only_space", 0x02b41): (249, "MegaDomHandlerMap"),
("read_only_space", 0x02b69): (178, "ModuleInfoMap"),
("read_only_space", 0x02b91): (182, "NameDictionaryMap"),
("read_only_space", 0x02bb9): (159, "NoClosuresCellMap"),
("read_only_space", 0x02be1): (184, "NumberDictionaryMap"),
("read_only_space", 0x02c09): (159, "OneClosureCellMap"),
("read_only_space", 0x02c31): (185, "OrderedHashMapMap"),
("read_only_space", 0x02c59): (186, "OrderedHashSetMap"),
("read_only_space", 0x02c81): (183, "NameToIndexHashTableMap"),
("read_only_space", 0x02ca9): (187, "OrderedNameDictionaryMap"),
("read_only_space", 0x02cd1): (251, "PreparseDataMap"),
("read_only_space", 0x02cf9): (252, "PropertyArrayMap"),
("read_only_space", 0x02d21): (153, "SideEffectCallHandlerInfoMap"),
("read_only_space", 0x02d49): (153, "SideEffectFreeCallHandlerInfoMap"),
("read_only_space", 0x02d71): (153, "NextCallSideEffectFreeCallHandlerInfoMap"),
("read_only_space", 0x02d99): (188, "SimpleNumberDictionaryMap"),
("read_only_space", 0x02dc1): (228, "SmallOrderedHashMapMap"),
("read_only_space", 0x02de9): (229, "SmallOrderedHashSetMap"),
("read_only_space", 0x02e11): (230, "SmallOrderedNameDictionaryMap"),
("read_only_space", 0x02e39): (233, "SourceTextModuleMap"),
("read_only_space", 0x02e61): (259, "SwissNameDictionaryMap"),
("read_only_space", 0x02e89): (234, "SyntheticModuleMap"),
("read_only_space", 0x02eb1): (260, "WasmApiFunctionRefMap"),
("read_only_space", 0x02ed9): (222, "WasmCapiFunctionDataMap"),
("read_only_space", 0x02f01): (223, "WasmExportedFunctionDataMap"),
("read_only_space", 0x02f29): (205, "WasmInternalFunctionMap"),
("read_only_space", 0x02f51): (224, "WasmJSFunctionDataMap"),
("read_only_space", 0x02f79): (261, "WasmOnFulfilledDataMap"),
("read_only_space", 0x02fa1): (206, "WasmTypeInfoMap"),
("read_only_space", 0x02fc9): (235, "WeakFixedArrayMap"),
("read_only_space", 0x02ff1): (180, "EphemeronHashTableMap"),
("read_only_space", 0x03019): (241, "EmbedderDataArrayMap"),
("read_only_space", 0x03041): (263, "WeakCellMap"),
("read_only_space", 0x03069): (32, "StringMap"),
("read_only_space", 0x03091): (41, "ConsOneByteStringMap"),
("read_only_space", 0x030b9): (33, "ConsStringMap"),
("read_only_space", 0x030e1): (37, "ThinStringMap"),
("read_only_space", 0x03109): (35, "SlicedStringMap"),
("read_only_space", 0x03131): (43, "SlicedOneByteStringMap"),
("read_only_space", 0x03159): (34, "ExternalStringMap"),
("read_only_space", 0x03181): (42, "ExternalOneByteStringMap"),
("read_only_space", 0x031a9): (50, "UncachedExternalStringMap"),
("read_only_space", 0x031d1): (0, "InternalizedStringMap"),
("read_only_space", 0x031f9): (2, "ExternalInternalizedStringMap"),
("read_only_space", 0x03221): (10, "ExternalOneByteInternalizedStringMap"),
("read_only_space", 0x03249): (18, "UncachedExternalInternalizedStringMap"),
("read_only_space", 0x03271): (26, "UncachedExternalOneByteInternalizedStringMap"),
("read_only_space", 0x03299): (58, "UncachedExternalOneByteStringMap"),
("read_only_space", 0x032c1): (104, "SharedOneByteStringMap"),
("read_only_space", 0x032e9): (96, "SharedStringMap"),
("read_only_space", 0x03311): (109, "SharedThinOneByteStringMap"),
("read_only_space", 0x03339): (101, "SharedThinStringMap"),
("read_only_space", 0x03361): (96, "TwoByteSeqStringMigrationSentinelMap"),
("read_only_space", 0x03389): (104, "OneByteSeqStringMigrationSentinelMap"),
("read_only_space", 0x033b1): (131, "SelfReferenceMarkerMap"),
("read_only_space", 0x033d9): (131, "BasicBlockCountersMarkerMap"),
("read_only_space", 0x0341d): (147, "ArrayBoilerplateDescriptionMap"),
("read_only_space", 0x0351d): (161, "InterceptorInfoMap"),
("read_only_space", 0x05e69): (132, "PromiseFulfillReactionJobTaskMap"),
("read_only_space", 0x05e91): (133, "PromiseRejectReactionJobTaskMap"),
("read_only_space", 0x05eb9): (134, "CallableTaskMap"),
("read_only_space", 0x05ee1): (135, "CallbackTaskMap"),
("read_only_space", 0x05f09): (136, "PromiseResolveThenableJobTaskMap"),
("read_only_space", 0x05f31): (139, "FunctionTemplateInfoMap"),
("read_only_space", 0x05f59): (140, "ObjectTemplateInfoMap"),
("read_only_space", 0x05f81): (141, "AccessCheckInfoMap"),
("read_only_space", 0x05fa9): (142, "AccessorInfoMap"),
("read_only_space", 0x05fd1): (143, "AccessorPairMap"),
("read_only_space", 0x05ff9): (144, "AliasedArgumentsEntryMap"),
("read_only_space", 0x06021): (145, "AllocationMementoMap"),
("read_only_space", 0x06049): (148, "AsmWasmDataMap"),
("read_only_space", 0x06071): (149, "AsyncGeneratorRequestMap"),
("read_only_space", 0x06099): (150, "BreakPointMap"),
("read_only_space", 0x060c1): (151, "BreakPointInfoMap"),
("read_only_space", 0x060e9): (152, "CachedTemplateObjectMap"),
("read_only_space", 0x06111): (154, "CallSiteInfoMap"),
("read_only_space", 0x06139): (155, "ClassPositionsMap"),
("read_only_space", 0x06161): (156, "DebugInfoMap"),
("read_only_space", 0x06189): (158, "ErrorStackDataMap"),
("read_only_space", 0x061b1): (160, "FunctionTemplateRareDataMap"),
("read_only_space", 0x061d9): (162, "InterpreterDataMap"),
("read_only_space", 0x06201): (163, "ModuleRequestMap"),
("read_only_space", 0x06229): (164, "PromiseCapabilityMap"),
("read_only_space", 0x06251): (165, "PromiseReactionMap"),
("read_only_space", 0x06279): (166, "PropertyDescriptorObjectMap"),
("read_only_space", 0x062a1): (167, "PrototypeInfoMap"),
("read_only_space", 0x062c9): (168, "RegExpBoilerplateDescriptionMap"),
("read_only_space", 0x062f1): (169, "ScriptMap"),
("read_only_space", 0x06319): (170, "ScriptOrModuleMap"),
("read_only_space", 0x06341): (171, "SourceTextModuleInfoEntryMap"),
("read_only_space", 0x06369): (172, "StackFrameInfoMap"),
("read_only_space", 0x06391): (173, "TemplateObjectDescriptionMap"),
("read_only_space", 0x063b9): (174, "Tuple2Map"),
("read_only_space", 0x063e1): (175, "WasmContinuationObjectMap"),
("read_only_space", 0x06409): (176, "WasmExceptionTagMap"),
("read_only_space", 0x06431): (177, "WasmIndirectFunctionTableMap"),
("read_only_space", 0x06459): (196, "SloppyArgumentsElementsMap"),
("read_only_space", 0x06481): (231, "DescriptorArrayMap"),
("read_only_space", 0x064a9): (219, "UncompiledDataWithoutPreparseDataMap"),
("read_only_space", 0x064d1): (217, "UncompiledDataWithPreparseDataMap"),
("read_only_space", 0x064f9): (220, "UncompiledDataWithoutPreparseDataWithJobMap"),
("read_only_space", 0x06521): (218, "UncompiledDataWithPreparseDataAndJobMap"),
("read_only_space", 0x06549): (250, "OnHeapBasicBlockProfilerDataMap"),
("read_only_space", 0x06571): (197, "TurbofanBitsetTypeMap"),
("read_only_space", 0x06599): (201, "TurbofanUnionTypeMap"),
("read_only_space", 0x065c1): (200, "TurbofanRangeTypeMap"),
("read_only_space", 0x065e9): (198, "TurbofanHeapConstantTypeMap"),
("read_only_space", 0x06611): (199, "TurbofanOtherNumberConstantTypeMap"),
("read_only_space", 0x06639): (246, "InternalClassMap"),
("read_only_space", 0x06661): (257, "SmiPairMap"),
("read_only_space", 0x06689): (256, "SmiBoxMap"),
("read_only_space", 0x066b1): (225, "ExportedSubClassBaseMap"),
("read_only_space", 0x066d9): (226, "ExportedSubClassMap"),
("read_only_space", 0x06701): (202, "AbstractInternalClassSubclass1Map"),
("read_only_space", 0x06729): (203, "AbstractInternalClassSubclass2Map"),
("read_only_space", 0x06751): (195, "InternalClassWithSmiElementsMap"),
("read_only_space", 0x06779): (247, "InternalClassWithStructElementsMap"),
("read_only_space", 0x067a1): (227, "ExportedSubClass2Map"),
("read_only_space", 0x067c9): (258, "SortStateMap"),
("read_only_space", 0x067f1): (146, "AllocationSiteWithWeakNextMap"),
("read_only_space", 0x06819): (146, "AllocationSiteWithoutWeakNextMap"),
("read_only_space", 0x06841): (137, "LoadHandler1Map"),
("read_only_space", 0x06869): (137, "LoadHandler2Map"),
("read_only_space", 0x06891): (137, "LoadHandler3Map"),
("read_only_space", 0x068b9): (138, "StoreHandler0Map"),
("read_only_space", 0x068e1): (138, "StoreHandler1Map"),
("read_only_space", 0x06909): (138, "StoreHandler2Map"),
("read_only_space", 0x06931): (138, "StoreHandler3Map"),
("map_space", 0x02149): (1057, "ExternalMap"),
("map_space", 0x02171): (2114, "JSMessageObjectMap"),
}
# List of known V8 objects.
@ -479,17 +481,18 @@ KNOWN_OBJECTS = {
("read_only_space", 0x034d9): "EmptyOrderedPropertyDictionary",
("read_only_space", 0x034f1): "EmptySwissPropertyDictionary",
("read_only_space", 0x03545): "NoOpInterceptorInfo",
("read_only_space", 0x0356d): "EmptyWeakFixedArray",
("read_only_space", 0x03575): "InfinityValue",
("read_only_space", 0x03581): "MinusZeroValue",
("read_only_space", 0x0358d): "MinusInfinityValue",
("read_only_space", 0x03599): "SelfReferenceMarker",
("read_only_space", 0x035d9): "BasicBlockCountersMarker",
("read_only_space", 0x0361d): "OffHeapTrampolineRelocationInfo",
("read_only_space", 0x03629): "GlobalThisBindingScopeInfo",
("read_only_space", 0x03659): "EmptyFunctionScopeInfo",
("read_only_space", 0x0367d): "NativeScopeInfo",
("read_only_space", 0x03695): "HashSeed",
("read_only_space", 0x0356d): "EmptyArrayList",
("read_only_space", 0x03579): "EmptyWeakFixedArray",
("read_only_space", 0x03581): "InfinityValue",
("read_only_space", 0x0358d): "MinusZeroValue",
("read_only_space", 0x03599): "MinusInfinityValue",
("read_only_space", 0x035a5): "SelfReferenceMarker",
("read_only_space", 0x035e5): "BasicBlockCountersMarker",
("read_only_space", 0x03629): "OffHeapTrampolineRelocationInfo",
("read_only_space", 0x03635): "GlobalThisBindingScopeInfo",
("read_only_space", 0x03665): "EmptyFunctionScopeInfo",
("read_only_space", 0x03689): "NativeScopeInfo",
("read_only_space", 0x036a1): "HashSeed",
("old_space", 0x0422d): "ArgumentsIteratorAccessor",
("old_space", 0x04271): "ArrayLengthAccessor",
("old_space", 0x042b5): "BoundFunctionLengthAccessor",