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

Side by Side Diff: cc/resources/eviction_tile_priority_queue.h

Issue 430053003: cc: Heapify pointers instead of objects in eviction tile priority queue. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update 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 unified diff | Download patch
« no previous file with comments | « no previous file | cc/resources/eviction_tile_priority_queue.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 5 #ifndef CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
6 #define CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 6 #define CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
7 7
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 29 matching lines...) Expand all
40 40
41 void Build(const std::vector<PictureLayerImpl::Pair>& paired_layers, 41 void Build(const std::vector<PictureLayerImpl::Pair>& paired_layers,
42 TreePriority tree_priority); 42 TreePriority tree_priority);
43 void Reset(); 43 void Reset();
44 44
45 bool IsEmpty() const; 45 bool IsEmpty() const;
46 Tile* Top(); 46 Tile* Top();
47 void Pop(); 47 void Pop();
48 48
49 private: 49 private:
50 std::vector<PairedPictureLayerQueue> paired_queues_; 50 // TODO(vmpstr): This is potentially unnecessary if it becomes the case that
51 // PairedPictureLayerQueue is fast enough to copy. In that case, we can use
52 // objects directly (ie std::vector<PairedPictureLayerQueue>).
53 ScopedPtrVector<PairedPictureLayerQueue> paired_queues_heap_;
reveman 2014/08/06 01:37:42 nit: not sure it's necessary to add the "heap_" su
vmpstr 2014/08/06 15:54:19 Done.
51 TreePriority tree_priority_; 54 TreePriority tree_priority_;
52 55
53 DISALLOW_COPY_AND_ASSIGN(EvictionTilePriorityQueue); 56 DISALLOW_COPY_AND_ASSIGN(EvictionTilePriorityQueue);
54 }; 57 };
55 58
56 } // namespace cc 59 } // namespace cc
57 60
58 #endif // CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 61 #endif // CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
OLDNEW
« no previous file with comments | « no previous file | cc/resources/eviction_tile_priority_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698