New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 749490 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocked on:
issue 802273



Sign in to add a comment

DevTools: false retaining path from Document DOM tree

Project Member Reported by u...@chromium.org, Jul 27 2017

Issue description

This is a continuation of  crbug.com/747382 . Now that  crbug.com/747382  is fixed, this issue is the main blocker for using DevTools to investigate real world iframe leaks.

Setup:
The attached html file leaks iframes by saving them in
window.retaining_path.child1.child2.child3.child4.leaking_frames array.

That is the only real retaining path. All other retaining paths should contain it as a prefix. DevTools, however, shows a retaining path from Document DOM tree that is shorter than the real retaining path.

Steps to reproduce:
1) Open the attached html file. Wait until it leaks at least 1 iframe.
2) Open DevTools and take a heap snapshot.
3) Looks for the retainers of "Window" objects corresponding to the leaking iframes.

Expected:
- The topmost retaining path is window.retaining_path.child1.child2.child3.child4.leaking_frames.
- All other retaining paths contain the real retaining path as prefix.

What happens actually:
- The topmost retaining path originates from Document DOM tree (see screenshot) and is shorter than the real retaining path.

 
false-dom-retaining-path.html
1.4 KB View Download
false-dom-retaining-path.png
55.2 KB View Download

Comment 1 by u...@chromium.org, Jul 27 2017

The issue is in treatment of the native object groups. If I comment out processing of the native groups, then the retaining path looks exactly like I would expect.

bool HeapSnapshotGenerator::FillReferences() {
  SnapshotFiller filler(snapshot_, &entries_);
  return v8_heap_explorer_.IterateAndExtractReferences(&filler);
      // && dom_explorer_.IterateAndExtractReferences(&filler);
}


Looks like objects in native object groups are simply added as strong roots in the heap snapshot.

They should instead be treated similar to ephemerons:
1) If any object in a group is reachable, then the whole group is reachable.
2) If all objects in a group are unreachable, then the group is unreachable.

This is how V8 GC treated objects groups before we switched to more precise wrapper tracing.

I don't see a quick fix for this issue. There two options:
1) For dom wrappers somehow get retainer info from V8 GC by instrumenting it.
2) Add a notion of object group in heap snapshot and implement ephemeron handling in the frontend.




Owner: alph@chromium.org
Status: Assigned (was: Untriaged)

Comment 3 by u...@chromium.org, Nov 24 2017

Owner: u...@chromium.org
Cc: hablich@chromium.org
Blockedon: 802273
Project Member

Comment 6 by bugdroid1@chromium.org, Jan 29 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/90356b5fa5853e5d78843da42213f5b1c4ee48a0

commit 90356b5fa5853e5d78843da42213f5b1c4ee48a0
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Mon Jan 29 15:14:32 2018

[bindings] Add a method to query the name of a node for heap snapshot.

The heap snapshot generator will use ScriptWrappableVisitor to capture
all DOM nodes that are reachable from V8.
The generator needs human-readable textual representation of a node to
show the node in UI.

This patch adds NameInHeapSnapshot method in TraceWrapperBase.
Derived classes can override it to provide specific names.

Bug:  749490 
Change-Id: Ieea8fb8c4265d9b3441f36e326b7ada0b012b4e8
Reviewed-on: https://chromium-review.googlesource.com/890180
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#532432}
[modify] https://crrev.com/90356b5fa5853e5d78843da42213f5b1c4ee48a0/third_party/WebKit/Source/core/dom/events/EventListener.h
[modify] https://crrev.com/90356b5fa5853e5d78843da42213f5b1c4ee48a0/third_party/WebKit/Source/platform/bindings/ScriptWrappable.cpp
[modify] https://crrev.com/90356b5fa5853e5d78843da42213f5b1c4ee48a0/third_party/WebKit/Source/platform/bindings/ScriptWrappable.h
[modify] https://crrev.com/90356b5fa5853e5d78843da42213f5b1c4ee48a0/third_party/WebKit/Source/platform/bindings/ScriptWrappableVisitor.h
[modify] https://crrev.com/90356b5fa5853e5d78843da42213f5b1c4ee48a0/third_party/WebKit/Source/platform/bindings/TraceWrapperBase.h

Project Member

Comment 7 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/v8/v8.git/+/239dd8124b9afea52f2983d37c7ac63262a9329f

commit 239dd8124b9afea52f2983d37c7ac63262a9329f
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Thu Feb 01 08:05:14 2018

New API for capturing embedder object graph in heap snapshot.

That patch introduces EmbedderGraph interface that embedders can use to
represent C++ objects that retain or are retained by V8 JS objects.

The heap snapshot generator adds nodes and edges of the EmbedderGraph to
the heap snapshot, allowing arbitrarily complex retaining paths that
cross V8/Embedder boundary.

The new functionality is enabled only if the embedder sets the
BuildEmbedderGraph callback.


Bug:  chromium:749490 

Cq-Include-Trybots: master.tryserver.chromium.linux:linux_chromium_rel_ng
Change-Id: I10a1fa000d6d4ba47fc19d84c7cfc2c619d496fc
Reviewed-on: https://chromium-review.googlesource.com/890521
Reviewed-by: Alexei Filippov <alph@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#51016}
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/include/v8-profiler.h
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/src/api.cc
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/src/profiler/heap-profiler.cc
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/src/profiler/heap-profiler.h
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/src/profiler/heap-snapshot-generator.cc
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/src/profiler/heap-snapshot-generator.h
[modify] https://crrev.com/239dd8124b9afea52f2983d37c7ac63262a9329f/test/cctest/test-heap-profiler.cc

Project Member

Comment 8 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/75edf20e769f39825d6e17fab52e16589350e7f2

commit 75edf20e769f39825d6e17fab52e16589350e7f2
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Thu Feb 01 15:15:18 2018

Capture all DOM nodes reachable from V8 in heap snapshot.

This patch uses the new EmbedderGraph API to provide the heap snapshot
generator with all DOM nodes and references reachable from V8.

Bug:  749490 
Change-Id: I26750a8b80dab4f88508e504b431d976a598c6c3
Reviewed-on: https://chromium-review.googlesource.com/890260
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Alexei Filippov <alph@chromium.org>
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533664}
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/MSANExpectations
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object-expected.txt
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object.js
[delete] https://crrev.com/f4e89250415b0f575dc7b224f53b862b91bcfc62/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree-expected.txt
[delete] https://crrev.com/f4e89250415b0f575dc7b224f53b862b91bcfc62/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree.js
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener-expected.txt
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener.js
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-iframe-expected.txt
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-iframe.js
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers-expected.txt
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers.js
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/resources/heap-snapshot-common.js
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/bindings/bindings.gni
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.cpp
[add] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.h
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/platform/bindings/ScriptWrappableVisitor.h
[modify] https://crrev.com/75edf20e769f39825d6e17fab52e16589350e7f2/third_party/WebKit/Source/platform/heap/TraceTraits.h

Project Member

Comment 9 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/v8/v8.git/+/b049ac84f2289011466f69d06b432e5b4727235d

commit b049ac84f2289011466f69d06b432e5b4727235d
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Thu Feb 01 17:42:30 2018

Add a flag for EmbedderGraph in heap snapshot.

The flag is enabled by default and provides a quick way to switch
between the old RetainerInfo and the new EmbedderGraph snapshoting
in local testing.

Bug:  chromium:749490 
Change-Id: I36406597a289090879cfa5051037c8cf35988e59
Reviewed-on: https://chromium-review.googlesource.com/897532
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#51045}
[modify] https://crrev.com/b049ac84f2289011466f69d06b432e5b4727235d/src/flag-definitions.h
[modify] https://crrev.com/b049ac84f2289011466f69d06b432e5b4727235d/src/profiler/heap-snapshot-generator.cc
[modify] https://crrev.com/b049ac84f2289011466f69d06b432e5b4727235d/test/cctest/test-heap-profiler.cc

Project Member

Comment 10 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0c2648420c80bff20154a6abd2d267a9a53cc6ad

commit 0c2648420c80bff20154a6abd2d267a9a53cc6ad
Author: Tommy Steimel <steimel@chromium.org>
Date: Thu Feb 01 17:54:06 2018

Revert "Capture all DOM nodes reachable from V8 in heap snapshot."

This reverts commit 75edf20e769f39825d6e17fab52e16589350e7f2.

Reason for revert: inspector-protocol/heap-profiler/heap-snapshot-with-iframe.js is failing on Mac bots. 

Example:
https://ci.chromium.org/buildbot/chromium.webkit/WebKit%20Mac10.12/10410

diff from failure:
https://isolateserver.appspot.com/browse?namespace=default-gzip&digest=c317416b36978b21d32382d0c64469a05a334287&as=heap-snapshot-with-iframe-diff.txt

Original change's description:
> Capture all DOM nodes reachable from V8 in heap snapshot.
> 
> This patch uses the new EmbedderGraph API to provide the heap snapshot
> generator with all DOM nodes and references reachable from V8.
> 
> Bug:  749490 
> Change-Id: I26750a8b80dab4f88508e504b431d976a598c6c3
> Reviewed-on: https://chromium-review.googlesource.com/890260
> Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
> Reviewed-by: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Kentaro Hara <haraken@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#533664}

TBR=dcheng@chromium.org,ulan@chromium.org,alph@chromium.org,haraken@chromium.org,mlippautz@chromium.org

Change-Id: I8fc35e1c2638bb8ef77b3b19053a7bcbe74a347a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug:  749490 
Reviewed-on: https://chromium-review.googlesource.com/896686
Reviewed-by: Tommy Steimel <steimel@chromium.org>
Commit-Queue: Tommy Steimel <steimel@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533725}
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/MSANExpectations
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object-expected.txt
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object.js
[add] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree-expected.txt
[add] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree.js
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener-expected.txt
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener.js
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-iframe-expected.txt
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-iframe.js
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers-expected.txt
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers.js
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/resources/heap-snapshot-common.js
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/Source/bindings/bindings.gni
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.cpp
[delete] https://crrev.com/4f8a3b6bcb5ad2e88ec0e578e52e92e7e1db54bb/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.h
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/Source/platform/bindings/ScriptWrappableVisitor.h
[modify] https://crrev.com/0c2648420c80bff20154a6abd2d267a9a53cc6ad/third_party/WebKit/Source/platform/heap/TraceTraits.h

Project Member

Comment 11 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b38855a87e13685eeb64c54e0781903a69b41724

commit b38855a87e13685eeb64c54e0781903a69b41724
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Thu Feb 01 22:13:41 2018

Reland "Capture all DOM nodes reachable from V8 in heap snapshot."

This reverts commit 0c2648420c80bff20154a6abd2d267a9a53cc6ad.

The new iframe test is fragile and is not properly waiting for the
iframe onload event. Since the problem is in the test, relanding
without the test for now to unblock other changes.

Original change's description:
> Capture all DOM nodes reachable from V8 in heap snapshot.
>
> This patch uses the new EmbedderGraph API to provide the heap snapshot
> generator with all DOM nodes and references reachable from V8.
>
> Bug:  749490 
> Change-Id: I26750a8b80dab4f88508e504b431d976a598c6c3
> Reviewed-on: https://chromium-review.googlesource.com/890260
> Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
> Reviewed-by: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Kentaro Hara <haraken@chromium.org>

Change-Id: I1d736a74b2f39443c490aecbfe7f6d305a669711

TBR=haraken@chromium.org,alph@chromium.org

Change-Id: I1d736a74b2f39443c490aecbfe7f6d305a669711
Reviewed-on: https://chromium-review.googlesource.com/897644
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533831}
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/MSANExpectations
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object-expected.txt
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-active-dom-object.js
[delete] https://crrev.com/d9e95344fb0ec1680fc3416a1cbdbc5272ab97be/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree-expected.txt
[delete] https://crrev.com/d9e95344fb0ec1680fc3416a1cbdbc5272ab97be/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-detached-dom-tree.js
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener-expected.txt
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-event-listener.js
[add] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers-expected.txt
[add] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/heap-snapshot-with-multiple-retainers.js
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/LayoutTests/inspector-protocol/heap-profiler/resources/heap-snapshot-common.js
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/bindings/bindings.gni
[add] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.cpp
[add] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/bindings/core/v8/V8EmbedderGraphBuilder.h
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/platform/bindings/ScriptWrappableVisitor.h
[modify] https://crrev.com/b38855a87e13685eeb64c54e0781903a69b41724/third_party/WebKit/Source/platform/heap/TraceTraits.h

Comment 12 by u...@chromium.org, Feb 13 2018

Status: Fixed (was: Assigned)
Project Member

Comment 14 by bugdroid1@chromium.org, Mar 20 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/v8/v8.git/+/747d198cad7471e3a007a4acf4fe1b962856802f

commit 747d198cad7471e3a007a4acf4fe1b962856802f
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Tue Mar 20 12:26:43 2018

[api] Deprecate HeapProfiler::SetGetRetainerInfosCallback.

The embedders should use the new EmbedderGraph API to provide retainer
info.

Bug:  chromium:749490 
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Iac8dc1e749ef14277b027f43e799357c5bd413ea
Reviewed-on: https://chromium-review.googlesource.com/948489
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52059}
[modify] https://crrev.com/747d198cad7471e3a007a4acf4fe1b962856802f/include/v8-profiler.h

Project Member

Comment 15 by bugdroid1@chromium.org, Mar 20 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/v8/v8.git/+/23a593b9d86a32b6a72094b36080baa29cde7526

commit 23a593b9d86a32b6a72094b36080baa29cde7526
Author: Ulan Degenbaev <ulan@chromium.org>
Date: Tue Mar 20 13:53:43 2018

[api] Deprecate HeapProfiler::SetWrapperClassInfoProvider.

The embedders should use the EmbedderGraph API. The similar structure
can be created with the following steps:
1) Create a root node for each retainer info group.
2) Iterate all handles using Isolate::VisitHandlesWithClassIds.
3) Add an edge from the retainer info node to the v8 wrapper node.
4) Add an edge from the v8 wrapper node to the retainer info node.

See how HeapSnapshotRetainedObjectInfo is converted to the new API.

Bug:  chromium:749490 
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: I124ae3853354863b4f888e6aa2ea13777dcaa37d
Reviewed-on: https://chromium-review.googlesource.com/948842
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52067}
[modify] https://crrev.com/23a593b9d86a32b6a72094b36080baa29cde7526/include/v8-profiler.h
[modify] https://crrev.com/23a593b9d86a32b6a72094b36080baa29cde7526/test/cctest/test-heap-profiler.cc

Sign in to add a comment