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

Unified Diff: cc/resources/picture_layer_tiling.h

Issue 471833002: cc: Add more eviction categories to picture layer impl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
Index: cc/resources/picture_layer_tiling.h
diff --git a/cc/resources/picture_layer_tiling.h b/cc/resources/picture_layer_tiling.h
index a252bafe82dcf8a355c8afb5a4a724169ec6ab8b..d9ae695b265e8572b9d6bb75f673a4be82a02a8c 100644
--- a/cc/resources/picture_layer_tiling.h
+++ b/cc/resources/picture_layer_tiling.h
@@ -57,10 +57,14 @@ class CC_EXPORT PictureLayerTiling {
public:
enum EvictionCategory {
EVENTUALLY,
+ EVENTUALLY_AND_REQUIRED_FOR_ACTIVATION,
SOON,
+ SOON_AND_REQUIRED_FOR_ACTIVATION,
NOW,
NOW_AND_REQUIRED_FOR_ACTIVATION
};
+ enum { NUM_EVICTION_CATEGORIES = NOW_AND_REQUIRED_FOR_ACTIVATION + 1 };
vmpstr 2014/08/14 06:23:48 I'm not sure what our style guide says about enums
reveman 2014/08/14 09:01:50 We don't have a nice consistent mechanism for this
danakj 2014/08/14 16:55:26 Security team (tsepez) has been adding a LAST_FOO_
vmpstr 2014/08/14 22:05:50 Removed this for now, added a TODO instead.
+
class CC_EXPORT TilingRasterTileIterator {
public:
TilingRasterTileIterator();
@@ -336,10 +340,7 @@ class CC_EXPORT PictureLayerTiling {
bool has_soon_border_rect_tiles_;
bool has_eventually_rect_tiles_;
- std::vector<Tile*> eventually_eviction_tiles_;
- std::vector<Tile*> soon_eviction_tiles_;
- std::vector<Tile*> now_eviction_tiles_;
- std::vector<Tile*> now_and_required_for_activation_eviction_tiles_;
+ std::vector<Tile*> eviction_tiles_[NUM_EVICTION_CATEGORIES];
bool eviction_tiles_cache_valid_;
TreePriority eviction_cache_tree_priority_;

Powered by Google App Engine
This is Rietveld 408576698