Performnce Monitor showing wrong DOM Nodes count
Reported by
htan...@sumologic.com,
Mar 26 2018
|
|||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36 Steps to reproduce the problem: 1. Open any web page, I opened google.com 2. open developer console and performance monitor 3. edit the HTML in the developer tools (I just added the HTML, HEAD , and BODY tags) What is the expected behavior? The performance monitor should show 3 DOM Nodes, but showed a much larger number What went wrong? The DOM Node count does not show the real time DOM Nodes count in the performance monitor Did this work before? N/A Chrome version: 64.0.3282.186 Channel: n/a OS Version: OS X 10.13.2 Flash Version: For the DOM Node count it was easy to test by manually counting the DOM Nodes in the Elements tab of developer console. How can the correctness of other metrics like JS Heap size, JS Event listeners, CPU Usage etc be known?
,
Mar 27 2018
,
Mar 27 2018
First of all DOM nodes are not released immediately. They are subject to garbage collection. Please wait up to several minutes until BlinkGC kicks in and frees unused nodes. Also please note some nodes and their subtrees could still be retained by JavaScript code that is still running in the page even after you removed the most of DOM tree. The easiest way to see them is to open memory panel, take a heap snapshot, and type HTML in the filter (see the screenshot). When I start Chrome pointing to about:blank page there's only 4 nodes as expected (see another screenshot). Closing this bug as "work as intended". Please feel free to reopen if I'm missing something.
,
Mar 28 2018
The performance monitor is supposed to be a real time monitor (screenshot), so waiting for GC kills its purpose of being real time. Coming to the part where Javascript may be retaining nodes, can it be shown separately in the performance monitor? |
|||
►
Sign in to add a comment |
|||
Comment 1 by susan.boorgula@chromium.org
, Mar 26 2018