| Index: third_party/WebKit/Source/platform/graphics/paint/PaintController.h
|
| diff --git a/third_party/WebKit/Source/platform/graphics/paint/PaintController.h b/third_party/WebKit/Source/platform/graphics/paint/PaintController.h
|
| index d4fbb3dac56e7868839c0e098344c6d6f5a011c0..607d54f63a48efff515e897e5179f4813487c327 100644
|
| --- a/third_party/WebKit/Source/platform/graphics/paint/PaintController.h
|
| +++ b/third_party/WebKit/Source/platform/graphics/paint/PaintController.h
|
| @@ -79,7 +79,7 @@ public:
|
|
|
| ensureNewDisplayItemListInitialCapacity();
|
| DisplayItemClass& displayItem = m_newDisplayItemList.allocateAndConstruct<DisplayItemClass>(std::forward<Args>(args)...);
|
| - processNewItem(displayItem, NewPainting);
|
| + processNewItem(displayItem);
|
| }
|
|
|
| // Creates and appends an ending display item to pair with a preceding
|
| @@ -165,7 +165,7 @@ protected:
|
| , m_imagePainted(false)
|
| , m_skippingCacheCount(0)
|
| , m_numCachedNewItems(0)
|
| - , m_currentChunkIsFromCachedSubsequence(true)
|
| + , m_currentCachedSubsequenceBeginIndexInNewList(kNotFound)
|
| #ifndef NDEBUG
|
| , m_numSequentialMatches(0)
|
| , m_numOutOfOrderMatches(0)
|
| @@ -188,8 +188,8 @@ private:
|
| }
|
|
|
| // Set new item state (cache skipping, etc) for a new item.
|
| - enum NewItemSource { FromCachedItem, FromCachedSubsequence, NewPainting };
|
| - void processNewItem(DisplayItem&, NewItemSource);
|
| + void processNewItem(DisplayItem&);
|
| + DisplayItem& moveItemFromCurrentListToNewList(size_t);
|
|
|
| String displayItemListAsDebugString(const DisplayItemList&) const;
|
|
|
| @@ -210,6 +210,8 @@ private:
|
|
|
| void generateChunkRasterInvalidationRects(PaintChunk& newChunk);
|
| void generateChunkRasterInvalidationRectsComparingOldChunk(PaintChunk& newChunk, const PaintChunk& oldChunk);
|
| + void generateChunkRasterInvalidationRectsForReorderedItems(PaintChunk& newChunk, const PaintChunk& oldChunk,
|
| + Vector<size_t>::const_iterator, Vector<size_t>::const_iterator, Vector<size_t>::const_iterator, Vector<size_t>::const_iterator);
|
|
|
| // The following two methods are for checking under-invalidations
|
| // (when RuntimeEnabledFeatures::paintUnderInvalidationCheckingEnabled).
|
| @@ -225,6 +227,11 @@ private:
|
| DisplayItemList m_newDisplayItemList;
|
| PaintChunker m_newPaintChunks;
|
|
|
| + // Stores indices into m_newDisplayItemList for display items that have been moved from
|
| + // m_currentPaintArtifact.getDisplayItemList(), indexed by the positions of the display
|
| + // items before move. The values are undefined for display items that are not moved.
|
| + Vector<size_t> m_itemsMovedIntoNewList;
|
| +
|
| // Allow display item construction to be disabled to isolate the costs of construction
|
| // in performance metrics.
|
| bool m_constructionDisabled;
|
| @@ -260,7 +267,7 @@ private:
|
| // - chunks are matched not only for requests of cached display items, but also non-cached display items.
|
| IndicesByClientMap m_outOfOrderChunkIndices;
|
|
|
| - bool m_currentChunkIsFromCachedSubsequence;
|
| + size_t m_currentCachedSubsequenceBeginIndexInNewList;
|
| size_t m_nextChunkToMatch;
|
|
|
| DisplayItemClient::CacheGenerationOrInvalidationReason m_currentCacheGeneration;
|
|
|