[MAC] Animated GIF inside a table-cell element causes extreme CPU usage

NEW
Unassigned

Status

()

Core
Layout: Tables
P4
normal
4 years ago
3 years ago

People

(Reporter: Evgueni Naverniouk, Unassigned)

Tracking

({perf})

28 Branch
x86
Mac OS X
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

4 years ago
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:28.0) Gecko/20100101 Firefox/28.0 (Beta/Release)
Build ID: 20140123004002

Steps to reproduce:

On my web page I have a <span> tag which has the following CSS:

background: url(my_animation.gif);
display: table-cell;

I'm using Firefox Aurora 28.0a2 (2014-01-23) on Mac OSX 10.8.4.


Actual results:

When viewing this page, my CPU usage spikes to 80-90%. If I remove either the background or the display values (via development tools), the CPU jumps down to a reasonable 5-10%.


Expected results:

Having an animated GIF inside a table-cell element should not affect the CPU as much as it does.
Evgueni,  can you attach an example page where this happens -- a reduced test case? 
Or, a link to your page would also be helpful. Thanks!
Flags: needinfo?(globexdesigns)
(Reporter)

Comment 2

4 years ago
Sure thing. Here is a test case: http://jsfiddle.net/2ZRS5/5/

Several things to note:

- Running this makes my Mac OSX CPU (firefox app) jump to around 30-60% usage.
- To further increase CPU usage you can click the button to generate some additional elements under the GIF. This will get you to 100%. For some reason having additional elements on the screens seems to increase the problem.

If you hide the GIF, or change the .table-cell element to another display type, your CPU usage will drop immediately.
Flags: needinfo?(globexdesigns)
Status: UNCONFIRMED → NEW
Component: Untriaged → Layout: Tables
Ever confirmed: true
Keywords: perf
Product: Firefox → Core

Updated

4 years ago
Priority: -- → P4
You need to log in before you can comment on or make changes to this bug.