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

Unified Diff: cc/layers/picture_layer_impl.cc

Issue 644313002: cc: Use reverse spiral iterator in tiling eviction. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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/layers/picture_layer_impl.cc
diff --git a/cc/layers/picture_layer_impl.cc b/cc/layers/picture_layer_impl.cc
index 14dfa52efbcbad384591d6c3f7473f46b91af9b1..fbc57d9fa93201332724a47e828a97557d84c03b 100644
--- a/cc/layers/picture_layer_impl.cc
+++ b/cc/layers/picture_layer_impl.cc
@@ -1560,17 +1560,14 @@ void PictureLayerImpl::LayerRasterTileIterator::AdvanceToNextStage() {
PictureLayerImpl::LayerEvictionTileIterator::LayerEvictionTileIterator()
: layer_(nullptr),
- tree_priority_(SAME_PRIORITY_FOR_BOTH_TREES),
current_category_(PictureLayerTiling::EVENTUALLY),
current_tiling_range_type_(PictureLayerTilingSet::HIGHER_THAN_HIGH_RES),
current_tiling_(0u) {
}
PictureLayerImpl::LayerEvictionTileIterator::LayerEvictionTileIterator(
- PictureLayerImpl* layer,
- TreePriority tree_priority)
+ PictureLayerImpl* layer)
: layer_(layer),
- tree_priority_(tree_priority),
current_category_(PictureLayerTiling::EVENTUALLY),
current_tiling_range_type_(PictureLayerTilingSet::HIGHER_THAN_HIGH_RES),
current_tiling_(CurrentTilingRange().start - 1u) {
@@ -1584,7 +1581,6 @@ PictureLayerImpl::LayerEvictionTileIterator::LayerEvictionTileIterator(
current_iterator_ = PictureLayerTiling::TilingEvictionTileIterator(
layer_->tilings_->tiling_at(CurrentTilingIndex()),
- tree_priority,
current_category_);
} while (!current_iterator_);
}
@@ -1613,7 +1609,6 @@ operator++() {
current_iterator_ = PictureLayerTiling::TilingEvictionTileIterator(
layer_->tilings_->tiling_at(CurrentTilingIndex()),
- tree_priority_,
current_category_);
}
return *this;
@@ -1626,16 +1621,9 @@ PictureLayerImpl::LayerEvictionTileIterator::operator bool() const {
bool PictureLayerImpl::LayerEvictionTileIterator::AdvanceToNextCategory() {
switch (current_category_) {
case PictureLayerTiling::EVENTUALLY:
- current_category_ =
- PictureLayerTiling::EVENTUALLY_AND_REQUIRED_FOR_ACTIVATION;
- return true;
- case PictureLayerTiling::EVENTUALLY_AND_REQUIRED_FOR_ACTIVATION:
current_category_ = PictureLayerTiling::SOON;
return true;
case PictureLayerTiling::SOON:
- current_category_ = PictureLayerTiling::SOON_AND_REQUIRED_FOR_ACTIVATION;
- return true;
- case PictureLayerTiling::SOON_AND_REQUIRED_FOR_ACTIVATION:
current_category_ = PictureLayerTiling::NOW;
return true;
case PictureLayerTiling::NOW:

Powered by Google App Engine
This is Rietveld 408576698