Summary: | Scrolling a Google Spreadsheet slower than Firefox (much worse on Windows) | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Peter Kasting <pkasting> | ||||
Component: | Layout and Rendering | Assignee: | Nobody <webkit-unassigned> | ||||
Status: | NEW --- | ||||||
Severity: | Normal | CC: | fishd, hyatt, jamesr, jamesr | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | PC | ||||||
OS: | All | ||||||
Attachments: |
|
Description
Peter Kasting
2009-08-17 10:14:12 PDT
I did some investigation of this and it appears that in WebKit the page's onscroll handler is causing a nontrivial amount of deferred layout to happen which causes the deferred paint to be delayed by 100+ms after the scroll happens. The sequence looks like this (WinXP in VMWare, Chromium, 500 row spreadsheet, each entry is a separate dispatch off the event loop): 0.) scroll event fires, handler set scrollTop on some element 1.) deferred layout runs for ~25ms 2.) more deferred layout, another ~25ms 3.) ... repeat 3 more times 6.) paint finally happens (~20ms) It makes sense that the hot paths in the profiler are all in layout - there's a very large table in the page that apparently has its layout invalidated by javascript. The odd thing is that FireFox doesn't exhibit this slowdown - either they aren't doing this layout, they are doing it after the paint, or the page is not invalidating layout for FFx while scrolling. |