Throttle setTimeout/Interval callbacks in content if callbacks are called too frequently (in background windows/tabs)

RESOLVED FIXED

Status

()

Core
DOM: Core & HTML
RESOLVED FIXED
10 years ago
6 years ago

People

(Reporter: Manish Singh, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.4) Gecko/20070502 Firefox/2.0.0.3 Flock/0.8.0.99
Build Identifier: 

I noticed this on http://abcnews.go.com/, they have a news ticker that is driven by animation code (http://a.abcnews.com/assets/js/animation.js), where they use a setTimeout of 10 ms to update the animation. Even while sitting in a background tab, the browser consumed 50% of CPU while idle.

To mitigate this, the browser could keep track of where and how often timeouts are scheduled, amd throttle down content that tries to schedule things too often.

Reproducible: Always

Steps to Reproduce:
1.
2.
3.

Updated

10 years ago
Summary: Throttle setTimeout/Interval callbacks in content if callbacks are called too frequently in the background → Throttle setTimeout/Interval callbacks in content if callbacks are called too frequently (in background windows/tabs)

Updated

10 years ago
Status: UNCONFIRMED → NEW
Ever confirmed: true

Updated

9 years ago
Component: DOM: Core → DOM: Core & HTML
QA Contact: ian → general
Depends on: 633421
Bug 633421 fixed this.
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED

Updated

6 years ago
Assignee: general → nobody
You need to log in before you can comment on or make changes to this bug.