Painting RenderLayers can be called from code paths which do not schedule RenderingUpdate through RenderingUpdateScheduler. This means RenderLayer::paintLayerContents() may be called while Page::updateRendering() is not on the call stack. This will make timestampForPaintFrequencyTracking() returns zero in this case. So PaintFrequencyTracker::end() will fail the assertion ASSERT(m_firstPaintTime). An example for this case is taking a snapshot of the page, or calling FrameView::paintContentsForSnapshot(). Another example is updating control tints or calling FrameView::updateControlTints().
(In reply to Said Abou-Hallawa from comment #0) > Painting RenderLayers can be called from code paths which do not schedule > RenderingUpdate through RenderingUpdateScheduler. This means > RenderLayer::paintLayerContents() may be called while > Page::updateRendering() is not on the call stack. This will make > timestampForPaintFrequencyTracking() returns zero in this case. So > PaintFrequencyTracker::end() will fail the assertion > ASSERT(m_firstPaintTime). An example for this case is taking a snapshot of > the page, or calling FrameView::paintContentsForSnapshot(). Another example > is updating control tints or calling FrameView::updateControlTints(). To clarify — `timestampForPaintFrequencyTracking()` will only return 0 if `Page::updateRendering()` has never been called (not if `RenderLayer::paintLayerContents()` is called while `Page::updateRendering()` is not on the call stack).
Created attachment 408881 [details] Patch
<rdar://problem/68635418>
Created attachment 408885 [details] Patch
Created attachment 408896 [details] Patch
Committed r267137: <https://trac.webkit.org/changeset/267137> All reviewed patches have been landed. Closing bug and clearing flags on attachment 408896 [details].