Closed Bug 1389282 Opened 9 years ago Closed 8 years ago

Web page with a lot of GIFs make Firefox use a lot more CPU usage

Categories

(Core :: Graphics: ImageLib, defect, P3)

55 Branch
defect

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox55 --- ?
firefox56 --- affected
firefox57 --- affected

People

(Reporter: utybodev, Unassigned)

Details

(Keywords: perf, regression, regressionwindow-wanted, Whiteboard: gfx-noted)

Attachments

(2 files)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:57.0) Gecko/20100101 Firefox/57.0 Build ID: 20170809100326 Steps to reproduce: Visit https://blog.discordapp.com/were-testing-video-chat-and-screen-share-with-5-of-players-today-c8ddb108ca31 Actual results: My laptop fan suddenly got angrier, and task manager indicated a big spike in CPU usage from Firefox (Nightly, 57), sometimes up to 50%, and that's with an i7-7500! I assume that this comes from the fact the page has a lot of pretty high quality GIFs Expected results: Maybe a little spike in CPU usage but not as much.
Component: Untriaged → ImageLib
Keywords: perf
Product: Firefox → Core
It looks like a regression from Firefox 56 when playing GIFs. My CPU is i7-4790, I have done some investigation about the CPU usage rate when opening the link, https://blog.discordapp.com/were-testing-video-chat-and-screen-share-with-5-of-players-today-c8ddb108ca31, among different versions of Firfox. Firefox 54, 55: 0.6% Firefox 56: 3.0%~4.0% Firefox 57: 3.0%~4.0%
Status: UNCONFIRMED → NEW
Ever confirmed: true
Flags: needinfo?(tnikkel)
Priority: -- → P3
Whiteboard: gfx-noted
(In reply to Daosheng Mu[:daoshengmu] from comment #1) > It looks like a regression from Firefox 56 when playing GIFs. > > My CPU is i7-4790, I have done some investigation about the CPU usage rate > when opening the link, > https://blog.discordapp.com/were-testing-video-chat-and-screen-share-with-5- > of-players-today-c8ddb108ca31, among different versions of Firfox. > > Firefox 54, 55: 0.6% > > Firefox 56: 3.0%~4.0% > > Firefox 57: 3.0%~4.0% The spike itself from the initial report is not surprising. I would have expected 3-4% from my experience to handle these animations and it is similar on my machine for all of the above. For my own tests I simply loaded the page, paused briefly when scrolling on each animated image, until I reached the bottom and waited for it to reach "resting" CPU speed. Daosheng, would you mind quickly retesting and confirm that 54/55 are indeed better for you and if so, attach your about:support for the good and bad cases? I'm just speculating here that maybe you aren't getting HW compositing for some reason on 56+... The only change (to the best of my knowledge) that affected animated images in this time frame would be the allowing of discarding of animated images from the cache, but if you have the tab open, it shouldn't discard them ever.
Flags: needinfo?(tnikkel) → needinfo?(dmu)
Attached file support_ff57.txt
I have tried it in FF 55 following your way, but I still can get 0.6% CPU usage rather than 3% in FF 57. I have uploaded my about:support from FF 55 and 57. Thanks.
Flags: needinfo?(dmu)
Daosheng, since you can reproduce it, can you run mozregression and find out when this started?
Flags: needinfo?(dmu)
Version: 57 Branch → 55 Branch
I have checked it seems to be resolved at Nightly recently. I have compared it between FF 55 and FF 57. Both of them get the similar result as below: - main process: 0.32% - content process: 3.30%
Flags: needinfo?(dmu)
(In reply to Daosheng Mu[:daoshengmu] from comment #6) > I have checked it seems to be resolved at Nightly recently. I have compared > it between FF 55 and FF 57. > Both of them get the similar result as below: > - main process: 0.32% > - content process: 3.30% Resolved per above.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: