This CL adds a UMA Document.OutliveTimeAfterShutdown.DestroyedBeforeProcessDies indicating the lifetime of document after shut down (Document::Shutdown that is called when detaching). The value is GC count between the time when the document is shut down and the time when the document is actually destroyed.
With these values, we can know the tendency of document lifetimes in the real world. In general, a document should be destroyed as soon as possible after shut down not to consume memory unnecessarily. We can't still tell if the memory leak happens because a document can remain after shut down e.g. when other frames holds it.
Change-Id: I94dae0f274855a37f51d74fb47acd79e29938327 Reviewed-on: https://chromium-review.googlesource.com/600149 Commit-Queue: Hajime Hoshi
94d7eed Add a UMA Document.OutliveTimeAfterShutdown.DestroyedBeforeProcessDies
third_party/WebKit/Source/core/dom/Document.cpp | 16 ++++++++++++++++
third_party/WebKit/Source/core/dom/Document.h | 2 ++
third_party/WebKit/Source/platform/heap/ThreadState.cpp | 2 ++
third_party/WebKit/Source/platform/heap/ThreadState.h | 4 ++++
tools/metrics/histograms/histograms.xml | 10 ++++++++++
5 files changed, 34 insertions(+)