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

Issue 834673 link

Starred by 3 users

Issue metadata

Status: Duplicate
Merged: issue 734427
Owner: ----
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

Leaking DOM-Nodes when setting focus to input-field

Reported by reh...@gmail.com, Apr 19 2018

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.117 Safari/537.36

Steps to reproduce the problem:
1. Open the attached file memory-leak.html (it has 59 Lines only)

2. click on the 2 links "Empty Page" and "Form" alternately

3. => the number of DOM-Nodes shown in the performance-Monitor gets higher and higher (clicking the "collect garbage"-button doesn't help).

If you remove the following line in function showFormTemplate() in the attached file, DOM-Nodes are not leaing anymore:

document.getElementById("textField").focus();

What is the expected behavior?

What went wrong?
The number of DOM-Nodes in the performance monitor is constantly increasing (is the browser really leaking DOM-Nodes or is it a problem with the peformance monitor?)

Did this work before? N/A 

Chrome version: 66.0.3359.117  Channel: stable
OS Version: 10.0
Flash Version:
 
memory-leak.html
1.2 KB View Download
Labels: Needs-Triage-M66
Components: -Blink Platform>DevTools>Performance
Taking a heap snapshot before and after doing some of the actions and causing a GC seems to shows no memory leak. 

So I suspect something is up with the performance pane.
Components: -Platform>DevTools>Performance Platform>DevTools
Owner: alph@chromium.org
Confirming, no leaks, but DOM counter increments.
Labels: Triaged-ET Needs-Feedback
Tested the issue on reported version 66.0.3359.117 with HTML file given in comment#0. Unable to find the DOM counter increments. Attaching screencast for reference.

@Reporter: Could you please check the video and let us know if we miss anything. Please let us know where to check "number of DOM-Nodes". Any further information on reproducing the issue would help in further triaging.

Thanks!

Comment 5 by reh...@gmail.com, Apr 25 2018

The DOM-counter is in the Chrome-Performance-Monitor (not the Windows-Performance-Monitor).

Chrome Developer-Tools => More Tools / Performance Monitor.


Project Member

Comment 6 by sheriffbot@chromium.org, Apr 25 2018

Cc: sindhu.chelamcherla@chromium.org
Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 7 by alph@chromium.org, Apr 25 2018

I still can see the leak. My experiments show that the Node constructor is called more times than ~Node. These are mostly ContainerNode's. So the perfmon node counter looks correct to me.

@dtapuska
Hmm, what kind of heap snapshot did you take? DevTools JS heap snapshots do only show V8 heap memory objects. DOM objects do not belong to V8 heap, unless there's a V8 wrapper created for a DOM node.

@pfeldman
How did you confirm there's no leak?
I was only looking at it in the allocation timeline and confirmed no JS leak. If you have reasons to believe Nodes leaked, let's assign it to the input folks.

Comment 9 by alph@chromium.org, Apr 25 2018

Cc: alph@chromium.org
Components: -Platform>DevTools Blink>HTML>Focus Blink>Input
Owner: ----
As per comment 7, could input folks please take a look what keeps Node's alive.
Labels: M-68 FoundIn-68 Target-68 OS-Linux OS-Mac
Status: Untriaged (was: Unconfirmed)
Able to reproduce this issue on Windows 10, Mac OS 10.12.6 and Ubuntu 17.10 on the latest Canary 68.0.3406.0 and reported version 66.0.3359.117 as per comment #5.

On loading the given html file, navigating to devtools -> More tools -> Performance Monitor, and on clicking on the 2 links, can observe the DOM Nodes increasing.
Attached is the screen cast for reference.

This behaviour is observed from introduction of Performance Monitor in Devtools in M64 - 64.0.3250.0 build.
Hence this is a Non-Regression issue. Marking this as Untriaged and requesting someone from Blink>Input team to look into the issue and help in further triaging.

Thanks..
834673.webm
2.0 MB View Download

Comment 11 by sno...@gmail.com, Apr 29 2018

I have the same problem. Win 10, Version 66.0.3359.139.
The following counters "DOM Nodes" and "JS event listeners" are different from the heap snapshot. Visit: https://github.com/vuejs/vue/issues/8100#issuecomment-385264028

Components: -Blink>Input Blink>DOM
Mergedinto: 734427
Status: Duplicate (was: Untriaged)

Sign in to add a comment