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

Unified Diff: include/core/SkGraphics.h

Issue 554263005: add PurgeResourceCache to track leaks (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « no previous file | src/core/SkGraphics.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkGraphics.h
diff --git a/include/core/SkGraphics.h b/include/core/SkGraphics.h
index a796a671e73f32a1f08b941f0185871de7458b6d..c154df1e404596a8dc4575136ce4ffab23e78af7 100644
--- a/include/core/SkGraphics.h
+++ b/include/core/SkGraphics.h
@@ -97,6 +97,12 @@ public:
static size_t SetResourceCacheTotalByteLimit(size_t newLimit);
/**
+ * For debugging purposes, this will attempt to purge the resource cache. It
+ * does not change the limit.
+ */
+ static void PurgeResourceCache();
+
+ /**
* When the cachable entry is very lage (e.g. a large scaled bitmap), adding it to the cache
* can cause most/all of the existing entries to be purged. To avoid the, the client can set
* a limit for a single allocation. If a cacheable entry would have been cached, but its size
« no previous file with comments | « no previous file | src/core/SkGraphics.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698