-
yurys@chromium.org authored
https://bugs.webkit.org/show_bug.cgi?id=98005 Reviewed by Pavel Feldman. Source/WebCore: Updated all call sites of MemoryInstrumentation::addHashMap to use generic method of reporting memory footprint instead. * bindings/v8/ScopedDOMDataStore.cpp: * bindings/v8/V8Binding.cpp: (WebCore::StringCache::reportMemoryUsage): * bindings/v8/V8DOMMap.h: * bindings/v8/V8PerIsolateData.cpp: (WebCore::V8PerIsolateData::reportMemoryUsage): * css/CSSImageGeneratorValue.cpp: (WebCore::CSSImageGeneratorValue::reportBaseClassMemoryUsage): * css/PropertySetCSSStyleDeclaration.cpp: (WebCore::PropertySetCSSStyleDeclaration::reportMemoryUsage): * css/StyleResolver.cpp: (WebCore::StyleResolver::collectMatchingRulesForList): * css/StyleSheetContents.cpp: (WebCore::StyleSheetContents::reportMemoryUsage): * dom/Document.cpp: (WebCore::Document::reportMemoryUsage): * loader/DocumentLoader.cpp: (WebCore::DocumentLoader::reportMemoryUsage): * loader/cache/CachedResourceLoader.cpp: (WebCore::CachedResourceLoader::reportMemoryUsage): * loader/cache/MemoryCache.cpp: (WebCore::MemoryCache::reportMemoryUsage): * platform/network/ResourceRequestBase.cpp: (WebCore::ResourceRequestBase::reportMemoryUsage): * platform/network/ResourceResponseBase.cpp: (WebCore::ResourceResponseBase::reportMemoryUsage): * rendering/style/StyleRareNonInheritedData.cpp: Source/WebKit/chromium: Added unit tests for HashMap memory instrumentation. * tests/MemoryInstrumentationTest.cpp: (WTF): Source/WTF: Extracted HashMap memory instrumentation into its own file. The map's content elements will be automatically traversed if their types are supported by the memory instrumentation. No need to call special method for hash map fields any more. * GNUmakefile.list.am: * WTF.gypi: * WTF.pro: * WTF.vcproj/WTF.vcproj: * wtf/MemoryInstrumentation.h: (MemoryInstrumentation): (WTF): * wtf/MemoryInstrumentationHashMap.h: Added. (WTF): (WTF::SequenceMemoryInstrumentationTraits::reportMemoryUsage): (WTF::reportMemoryUsage): git-svn-id: http://svn.webkit.org/repository/webkit/trunk@130048 268f45cc-cd09-0410-ab3c-d52691b4dbfc
9c990164