increasing cpu overhead after playing for a long time
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Exaile |
Fix Released
|
Low
|
Unassigned |
Bug Description
Exaile version 3.0.1 from Karmic and version 3.0.2 from PPA
Ubuntu Karmic
The Problem.
Running a playlist in repeat mode will eventually cause the cpu load to increase to 100%.
This more noticeable on slower cpu's i.e. I have a 900Mhz P3 as a test machine which starts off at 8% cpu usage for exaile, this increases by approx 8% per hour so that after 12hrs exaile is using 100% of cpu time. In contrast to this, another test machine 3Ghz dual P4 starts out at <1% but this still increases, albeit at a slower pace.
So far I have been able to determine that the problem lies with the progress bar. (xlgui/main.py)
In timer_update the following calls are made
self.
track.
self.
all of these call seem to contribute to the increase in cpu time.
I can alleviate part of the problem by modifying how track.get_duration is used (it really only needs to called once at the start of playing a track) by declaring a global variable
self.
and using it in playback_start by adding
track = self.player.current
self.
then referencing this in timer_update as
self.
I am at the moment stuck on why these calls should cause this behaviour.
More investigation is called for but the long test times required, at least an hour on a slow machine, make it a time consuming exercise.
Note. Slow cpu's also include intel atom's which run at 1.5Ghz and intel celeron N220 as these cpu's are used in netbooks and nettops this could be a major issue for a lot of other users.
Regards
David
Related branches
Changed in exaile: | |
milestone: | 0.3.0.3 → 0.3.1 |
Changed in exaile: | |
status: | Fix Committed → Fix Released |
repeat calls to those funcs really should not increase cpu overhead continually. All three do very simple tasks that don't have any persistent effect. Without more data on why this happens, there really isn't much we can do about this bug, and an easy workaround is to just quit Exaile every so often, which with playlist and playback resume enabled is not hugely intrusive.