Bug 197451

Summary: REGRESSION (r244182): RenderingUpdate should not be scheduled for invisible pages
Product: WebKit Reporter: Said Abou-Hallawa <sabouhallawa>
Component: AnimationsAssignee: Said Abou-Hallawa <sabouhallawa>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, dino, simon.fraser, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=177484
Attachments:
Description Flags
Patch
none
Patch none

Description Said Abou-Hallawa 2019-04-30 18:18:54 PDT
Safari creates a blank web page when it is opened. This page will not be visible unless the user selects to open new tabs with "Empty page". The loader of this page forces Document::resolveStyle() which requires RenderLayerCompositor::scheduleLayerFlushNow().

Before r244182, this would just call scheduleCompositingLayerFlush() immediately. After r244182, RenderLayerCompositor::scheduleLayerFlushNow() has to schedule a RenderingUpdate and when it fires it calls scheduleCompositingLayerFlush().

We need to optimize this case by checking whether the page is visible or not before scheduling the RenderingUpdate.
Comment 1 Said Abou-Hallawa 2019-04-30 18:28:49 PDT
Created attachment 368642 [details]
Patch
Comment 2 Said Abou-Hallawa 2019-05-01 10:26:39 PDT
Created attachment 368684 [details]
Patch
Comment 3 Said Abou-Hallawa 2019-05-01 10:30:05 PDT
<rdar://problem/50224329>
Comment 4 WebKit Commit Bot 2019-05-01 12:31:11 PDT
Comment on attachment 368684 [details]
Patch

Clearing flags on attachment: 368684

Committed r244837: <https://trac.webkit.org/changeset/244837>
Comment 5 WebKit Commit Bot 2019-05-01 12:31:13 PDT
All reviewed patches have been landed.  Closing bug.