Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(18)

Unified Diff: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h

Issue 2766943002: Do-not-commit: Count layout tree memory usage
Patch Set: Rebase, add object paint property counter Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h
diff --git a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h
index b84f52a7007bd3a65d86a98483fd17668f22d95d..f25de3be603326664ec81c24aa7371cdab219089 100644
--- a/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h
+++ b/third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceClipper.h
@@ -65,6 +65,14 @@ class LayoutSVGResourceClipper final : public LayoutSVGResourceContainer {
}
private:
+ char objectSize() const override { return sizeof(this); }
+ char approximateHeapMemoryUsage() const override {
+ int memory = LayoutSVGResourceContainer::approximateHeapMemoryUsage();
+ // TODO(pdr): Include memory from m_clipContentPath.
+ // TODO(pdr): Include memory from m_cachedPaintRecord.
+ return memory;
+ }
+
void calculateLocalClipBounds();
// Return true if the clip path was calculated or a cached value is available.

Powered by Google App Engine
This is Rietveld 408576698