Chromium Code Reviews| Index: third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp |
| diff --git a/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp b/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp |
| index feeb006ae8260deecb1a2ac31faa9bad1f38a1fe..b18c2a16609a74d0189fa255d766f8f7e86d1a15 100644 |
| --- a/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp |
| +++ b/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp |
| @@ -365,11 +365,6 @@ void PaintController::commitNewDisplayItems(const LayoutSize& offsetFromLayoutOb |
| outOfOrderIndexContext.nextItemToIndex = currentIt; |
| } |
| -#if DCHECK_IS_ON() |
| - if (RuntimeEnabledFeatures::slimmingPaintUnderInvalidationCheckingEnabled()) |
| - checkNoRemainingCachedDisplayItems(); |
| -#endif |
|
Xianzhu
2016/06/09 22:56:02
This is removed because it doesn't apply to the ne
|
| - |
| // TODO(jbroman): When subsequence caching applies to SPv2, we'll need to |
| // merge the paint chunks as well. |
| m_currentPaintArtifact = PaintArtifact(std::move(updatedList), m_newPaintChunks.releasePaintChunks(), gpuAnalyzer.suitableForGpuRasterization()); |
| @@ -416,6 +411,14 @@ void PaintController::updateCacheGeneration() |
| #endif |
| } |
| +void PaintController::appendDebugDrawingAfterCommit(const DisplayItemClient& displayItemClient, PassRefPtr<SkPicture> picture, const LayoutSize& offsetFromLayoutObject) |
| +{ |
| + DCHECK(m_newDisplayItemList.isEmpty()); |
| + DrawingDisplayItem& displayItem = m_currentPaintArtifact.getDisplayItemList().allocateAndConstruct<DrawingDisplayItem>(displayItemClient, DisplayItem::DebugDrawing, picture); |
| + displayItem.setSkippedCache(); |
| + m_currentPaintArtifact.getDisplayItemList().appendVisualRect(visualRectForDisplayItem(displayItem, offsetFromLayoutObject)); |
| +} |
| + |
| #if DCHECK_IS_ON() |
| void PaintController::checkUnderInvalidation(DisplayItemList::iterator& newIt, DisplayItemList::iterator& currentIt) |
| @@ -503,17 +506,6 @@ void PaintController::checkCachedDisplayItemIsUnchanged(const char* messagePrefi |
| NOTREACHED(); |
| } |
| -void PaintController::checkNoRemainingCachedDisplayItems() |
| -{ |
| - DCHECK(RuntimeEnabledFeatures::slimmingPaintUnderInvalidationCheckingEnabled()); |
| - |
| - for (const auto& displayItem : m_currentPaintArtifact.getDisplayItemList()) { |
| - if (!displayItem.hasValidClient() || !displayItem.isCacheable() || !clientCacheIsValid(displayItem.client())) |
| - continue; |
| - showUnderInvalidationError("", "May be under-invalidation: no new display item", nullptr, &displayItem); |
| - } |
| -} |
| - |
| #endif // DCHECK_IS_ON() |
| #ifndef NDEBUG |