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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp

Issue 2387373002: Create retainment infos from handles, even for tracing (Closed)
Patch Set: Comments Created 4 years, 2 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp b/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp
index ba550a28e76deadff04231bc8ef97f5af452c36b..0b5e49c2c9ee1fb8589415e264a99a6f55a8fd16 100644
--- a/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp
@@ -202,8 +202,10 @@ class MajorGCWrapperVisitor : public v8::PersistentHandleVisitor {
if (m_constructRetainedObjectInfos)
m_groupsWhichNeedRetainerInfo.append(root);
} else if (classId == WrapperTypeInfo::ObjectClassId) {
- type->visitDOMWrapper(m_isolate, toScriptWrappable(wrapper),
- v8::Persistent<v8::Object>::Cast(*value));
+ if (!RuntimeEnabledFeatures::traceWrappablesEnabled()) {
+ type->visitDOMWrapper(m_isolate, toScriptWrappable(wrapper),
+ v8::Persistent<v8::Object>::Cast(*value));
+ }
} else {
NOTREACHED();
}
@@ -277,8 +279,8 @@ void objectGroupingForMajorGC(v8::Isolate* isolate,
void gcPrologueForMajorGC(v8::Isolate* isolate,
bool constructRetainedObjectInfos) {
- // TODO(hlopko): Collect retained object infos for heap profiler
- if (!RuntimeEnabledFeatures::traceWrappablesEnabled()) {
+ if (!RuntimeEnabledFeatures::traceWrappablesEnabled() ||
+ constructRetainedObjectInfos) {
objectGroupingForMajorGC(isolate, constructRetainedObjectInfos);
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698