Closed
Bug 766696
Opened 12 years ago
Closed 12 years ago
MessagePump's event loop doesn't wake up when idle-work is added to the queue
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox16 fixed)
RESOLVED
FIXED
Firefox 16
Tracking | Status | |
---|---|---|
firefox16 | --- | fixed |
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(1 file)
(deleted),
patch
|
blassey
:
review+
|
Details | Diff | Splinter Review |
I often see delays of ~10 seconds between two ScreenshotRunnables running, even though gecko isn't doing anything else in between. It looks like calling MessageLoop::current()->PostIdleTask doesn't wake up the message pump that may be sleeping in NS_ProcessNextEvent. This means if a whole bunch of ScreenshotRunnables get queued up, they may not get run during actual idle periods, and may only trickle out as various background timers fire.
Another related problem is that the loop in MessagePump::Run should have a "continue" statement if DoIdleWork() returns true, so that it can process multiple pieces of idle work before going back to sleep.
Assignee | ||
Comment 1•12 years ago
|
||
This fixes the second part of the problem (not processing more than one idle work in a row), and is sufficient for the screenshot code. However it would be good to also fix the other problem (that of queueing idle work not waking up the message pump).
Attachment #635048 -
Flags: review?(blassey.bugs)
Updated•12 years ago
|
Attachment #635048 -
Flags: review?(blassey.bugs) → review+
Assignee | ||
Comment 2•12 years ago
|
||
Pushed to try: https://tbpl.mozilla.org/?tree=Try&rev=7724a9f20832
Assignee | ||
Comment 3•12 years ago
|
||
Try run was pretty green, so landed on inbound:
https://hg.mozilla.org/integration/mozilla-inbound/rev/5bd5734369f7
status-firefox16:
--- → fixed
OS: Linux → Android
Hardware: x86_64 → All
Target Milestone: --- → Firefox 16
Comment 4•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•4 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•