-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Perf] HTMLVideoElement is performing synchronous paints; causing mai…
…n thread hangs https://bugs.webkit.org/show_bug.cgi?id=238707 <rdar://91025299> Reviewed by Eric Carlson. Spin trace diagnostics show that the main thread of the WebContent process is often hung, blocked on a synchronous Paint message to the GPU process; in turn, the GPU process is often busy performing media-related work, but in each of the cases found, painting is unnecessary. The media player in question is accelerated, and should only be painted during layer snapshotting or during a print operation. Only paint if the renderer is not accelerated, the media element is not accelerated, or if the paint operation isn't flattening or snapshotting. HTMLMediaElement inappropriately caches the value of MediaPlayer::supportsAcceleratedRendering(), under the (incorrect) assumption that the value cannot change during the lifetime of the MediaPlayer, so remove this caching layer. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::mediaEngineWasUpdated): (WebCore::HTMLMediaElement::clearMediaPlayer): * html/HTMLMediaElement.h: (WebCore::HTMLMediaElement::supportsAcceleratedRendering const): * rendering/RenderVideo.cpp: (WebCore::RenderVideo::paintReplaced): Canonical link: https://commits.webkit.org/249188@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@292290 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
4 changed files
with
49 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters