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

Unified Diff: cc/resources/tile_manager.cc

Issue 23495013: Early out from CleanUpUnusedImageDecodeTasks(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/tile_manager.cc
diff --git a/cc/resources/tile_manager.cc b/cc/resources/tile_manager.cc
index 3e91167866031a18cb3c342f37f4f1fa4c9d3c1b..0606fc92653d82d000ef1252925650515d627e60 100644
--- a/cc/resources/tile_manager.cc
+++ b/cc/resources/tile_manager.cc
@@ -626,6 +626,9 @@ void TileManager::AssignGpuMemoryToTiles(
}
void TileManager::CleanUpUnusedImageDecodeTasks() {
+ if (image_decode_tasks_.empty())
+ return;
+
// Calculate a set of layers that are used by at least one tile.
base::hash_set<int> used_layers;
for (TileMap::iterator it = tiles_.begin(); it != tiles_.end(); ++it)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698