gwibber-service has a child that polls at 10Hz which is causing a lot of wakeup events
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gwibber (Ubuntu) |
Fix Released
|
High
|
Unassigned |
Bug Description
The gwibber-service forks off a child process that runs a polling loop constantly at 10Hz which causes a lot of wakeups on an idle system. On my Lenovo X220i this constitutes 7% of the wakeups on a cleanly installed system when running idle. Extraneous wakeups waste power and reduce battery life.
You can see the offending task using strace:
sudo strace -f /usr/bin/
and after about 8 or so seconds you can then observe the select(), wait() polling loop:
...
[pid 11711] select(0, NULL, NULL, NULL, {0, 100000}) = 0 (Timeout)
[pid 11711] wait4(11710, 0x7f3991defb8c, WNOHANG, NULL) = 0
[pid 11711] wait4(11709, 0x7f3991defb8c, WNOHANG, NULL) = 0
[pid 11711] select(0, NULL, NULL, NULL, {0, 100000}) = 0 (Timeout)
[pid 11711] wait4(11710, 0x7f3991defb8c, WNOHANG, NULL) = 0
[pid 11711] wait4(11709, 0x7f3991defb8c, WNOHANG, NULL) = 0
[pid 11711] select(0, NULL, NULL, NULL, {0, 100000}) = 0 (Timeout)
This is overkill in my opinion and any code that sits in a tight polling loop like this need re-engineering to be more power friendly.
ProblemType: Bug
DistroRelease: Ubuntu 11.10
Package: gwibber-service 3.2.1-0ubuntu1.3
ProcVersionSign
Uname: Linux 3.0.0-14-generic x86_64
ApportVersion: 1.23-0ubuntu4
Architecture: amd64
Date: Tue Dec 20 14:40:04 2011
EcryptfsInUse: Yes
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
PackageArchitec
SourcePackage: gwibber
UpgradeStatus: No upgrade log present (probably fresh install)
Related branches
- Michael Terry (community): Approve
-
Diff: 77 lines (+12/-25)1 file modifiedgwibber/microblog/dispatcher.py (+12/-25)
tags: | added: battery-power-consumption |
Changed in gwibber (Ubuntu): | |
importance: | Undecided → High |
Changed in gwibber (Ubuntu): | |
assignee: | nobody → Ken VanDine (ken-vandine) |
status: | New → Triaged |
Changed in gwibber (Ubuntu): | |
assignee: | Ken VanDine (ken-vandine) → nobody |
This bug was fixed in the package gwibber - 3.3.2-0ubuntu1
---------------
gwibber (3.3.2-0ubuntu1) precise; urgency=low
* New upstream release .Pool gwibber- service. pyinstall, debian/ gwibber- service. install
- Drop the usage of threading.Thread and ensure the multiprocessing
is closed after the job is complete, this greatly reduces the system
load and stops the aggressive polling multiprocessing worker pools
used (LP: #906916)
- ported to libdee API changes
- ported to libunity API changes
* debian/
- Use a .pyinstall file to handle instaling stuff so we don't have to
copy custom.py
* debian/rules
- drop the copy of custom.py, it gets installed with .pyinstall file now
* debian/control
- bump build depends for libunity-dev and libdee-dev
- renamed build dep to gtkspell-3-dev
-- Ken VanDine <email address hidden> Fri, 13 Jan 2012 12:38:23 +0100