Index: src/heap-snapshot-generator.cc |
diff --git a/src/heap-snapshot-generator.cc b/src/heap-snapshot-generator.cc |
index f39ac1db2abe1720e5af6c71929516944ab5d302..6229386804b0361109178c73c482996dbd002d4e 100644 |
--- a/src/heap-snapshot-generator.cc |
+++ b/src/heap-snapshot-generator.cc |
@@ -1097,11 +1097,16 @@ bool V8HeapExplorer::ExtractReferencesPass1(int entry, HeapObject* obj) { |
ExtractJSGlobalProxyReferences(entry, JSGlobalProxy::cast(obj)); |
} else if (obj->IsJSArrayBuffer()) { |
ExtractJSArrayBufferReferences(entry, JSArrayBuffer::cast(obj)); |
- } else if (obj->IsJSWeakSet()) { |
- ExtractJSWeakCollectionReferences(entry, JSWeakSet::cast(obj)); |
- } else if (obj->IsJSWeakMap()) { |
- ExtractJSWeakCollectionReferences(entry, JSWeakMap::cast(obj)); |
} else if (obj->IsJSObject()) { |
+ if (obj->IsJSWeakSet()) { |
+ ExtractJSWeakCollectionReferences(entry, JSWeakSet::cast(obj)); |
+ } else if (obj->IsJSWeakMap()) { |
+ ExtractJSWeakCollectionReferences(entry, JSWeakMap::cast(obj)); |
+ } else if (obj->IsJSSet()) { |
+ ExtractJSCollectionReferences(entry, JSSet::cast(obj)); |
+ } else if (obj->IsJSMap()) { |
+ ExtractJSCollectionReferences(entry, JSMap::cast(obj)); |
+ } |
ExtractJSObjectReferences(entry, JSObject::cast(obj)); |
} else if (obj->IsString()) { |
ExtractStringReferences(entry, String::cast(obj)); |
@@ -1260,6 +1265,13 @@ void V8HeapExplorer::ExtractSymbolReferences(int entry, Symbol* symbol) { |
} |
+void V8HeapExplorer::ExtractJSCollectionReferences(int entry, |
+ JSCollection* collection) { |
+ SetInternalReference(collection, entry, "table", collection->table(), |
+ JSCollection::kTableOffset); |
+} |
+ |
+ |
void V8HeapExplorer::ExtractJSWeakCollectionReferences( |
int entry, JSWeakCollection* collection) { |
MarkAsWeakContainer(collection->table()); |