Web Inspector: count RenderStyle objects in the native memory profiler
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Aug 2012 14:14:58 +0000 (14:14 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Aug 2012 14:14:58 +0000 (14:14 +0000)
commitb2f3e7ffa03d2e266fed4e0e6df4ffa22117ebe5
tree1c4e00510b8230132fcc227e45e623ef0e4dbb5e
parentdd61de5417cb6bebaf4cb466c85680474d956e45
Web Inspector: count RenderStyle objects in the native memory profiler
https://bugs.webkit.org/show_bug.cgi?id=91759

Patch by Alexei Filippov <alexeif@chromium.org> on 2012-08-02
Reviewed by Yury Semikhatsky.

Source/WebCore:

The patch adds instrumentation to the following classes:
  - RenderStyle
  - StyleRareInheritedData
  - StyleRareNonInheritedData

* bindings/js/ScriptWrappable.h:
* bindings/v8/ScriptWrappable.h:
* dom/MemoryInstrumentation.h:
(WebCore):
(WebCore::MemoryInstrumentation::OwningTraits::addObject):
(WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
(WebCore::MemoryInstrumentation::addObjectImpl):
* dom/Node.cpp:
(WebCore::Node::reportMemoryUsage):
* dom/Node.h:
(WebCore):
* rendering/style/RenderStyle.cpp:
(WebCore::RenderStyle::reportMemoryUsage):
(WebCore):
* rendering/style/RenderStyle.h:
(WebCore):
* rendering/style/StyleRareInheritedData.cpp:
(WebCore::StyleRareInheritedData::reportMemoryUsage):
(WebCore):
* rendering/style/StyleRareInheritedData.h:
(WebCore):
(StyleRareInheritedData):
* rendering/style/StyleRareNonInheritedData.cpp:
(WebCore::StyleRareNonInheritedData::reportMemoryUsage):
(WebCore):
* rendering/style/StyleRareNonInheritedData.h:
(WebCore):
(StyleRareNonInheritedData):

Source/WebKit/chromium:

Add a test for DataRef<T> wrapped member instrumentation.

* tests/MemoryInstrumentationTest.cpp:
(WebCore::InstrumentedRefPtr::create):
(WebCore::TEST):
(WebCore):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@124452 268f45cc-cd09-0410-ab3c-d52691b4dbfc
14 files changed:
Source/WebCore/ChangeLog
Source/WebCore/bindings/js/ScriptWrappable.h
Source/WebCore/bindings/v8/ScriptWrappable.h
Source/WebCore/dom/MemoryInstrumentation.h
Source/WebCore/dom/Node.cpp
Source/WebCore/dom/Node.h
Source/WebCore/rendering/style/RenderStyle.cpp
Source/WebCore/rendering/style/RenderStyle.h
Source/WebCore/rendering/style/StyleRareInheritedData.cpp
Source/WebCore/rendering/style/StyleRareInheritedData.h
Source/WebCore/rendering/style/StyleRareNonInheritedData.cpp
Source/WebCore/rendering/style/StyleRareNonInheritedData.h
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/tests/MemoryInstrumentationTest.cpp