Bug 220226

Summary: Audio elements block WebContent main thread, causing multi-second rendering delays scrolling a real webpage
Product: WebKit Reporter: Mish <mish>
Component: MediaAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: cdumez, eric.carlson, jer.noble, peng.liu6, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: Safari 14   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Attached is the CPU-usage when scrolling the page none

Description Mish 2021-01-02 07:33:02 PST
If there are many <audio> elements on the webpage, the webpage does not render correctly and causes lags
for example, please see: https://storage.googleapis.com/ddsp/index.html
Comment 1 Alexey Proskuryakov 2021-01-02 10:40:04 PST
I can reproduce multi-second rendering delays scrolling this page on an Apple Silicon Mac.

WebContent main thread is blocked running -[AVPlayerItemTrack isEnabled] via WebCoreAVFMovieObserver.
Comment 2 Radar WebKit Bug Importer 2021-01-02 10:40:14 PST
<rdar://problem/72770737>
Comment 3 Mish 2021-01-02 11:59:17 PST
Created attachment 416897 [details]
Attached is the CPU-usage when scrolling the page

Attached is the CPU-usage when scrolling the page