Bug 109395 - Poor animated gif performance
Summary: Poor animated gif performance
Status: RESOLVED DUPLICATE of bug 161566
Alias: None
Product: WebKit
Classification: Unclassified
Component: Images (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on: 112327
Blocks:
  Show dependency treegraph
 
Reported: 2013-02-10 19:48 PST by Philip Rogers
Modified: 2017-08-24 16:21 PDT (History)
15 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philip Rogers 2013-02-10 19:48:19 PST
We currently block while decoding images. This isn't a problem for small images, but large animated gifs (like those found on tumblr) destroy scroll performance.

Repro case:
1) visit http://philbit.com/animatedgiftest.html
2) resize the browser window so you can scroll
3) scroll (or, try to)

For serious sadness, try this on a mobile device.

A profile shows most our time is being spent in GIFImageDecoder and GIFImageReader. We share Gecko's gif decoder and Firefox is able to scroll fairly smoothly on the repro page above, so I think there may be low hanging fruit here outside the decoding infrastructure.
Comment 1 Philip Rogers 2013-02-10 20:28:36 PST
I learned on IRC that some of these issues are lessened with impl-side painting.

For the tumblr usecase, off-thread decoding may still be worth looking at in parallel because it would prevent large images from blocking the composite.
Comment 2 noel gordon 2013-02-10 20:42:28 PST
(In reply to comment #0)
> We currently block while decoding images. This isn't a problem for small images, but large animated gifs (like those found on tumblr) destroy scroll performance.

1) about:flags

2) Enable : Threaded compositing Mac, Windows, Linux
Uses a secondary thread to perform web page compositing. This allows smooth scrolling, even when the main thread is unresponsive.

3) load http://gcfly.org/viewthread.php?tid=5721

can you scroll?
Comment 3 Tom Hudson 2013-02-10 23:36:16 PST
I don't know if it's the case here yet, but historically we've frequently had this kind of behavior when we ran out of image cache; it's something to check for for.
Comment 4 Allan Sandfeld Jensen 2013-04-11 05:53:24 PDT
We start gif animations when they move into the viewport but we never stop them again, which leads to more and more git animations running. This is fixed in bug 112327
Comment 5 Said Abou-Hallawa 2017-08-24 16:21:59 PDT
This is the same as https://bugs.webkit.org/show_bug.cgi?id=161566.

*** This bug has been marked as a duplicate of bug 161566 ***