possible to include sampling_down_factor in Ubuntu?
danielhollocher at gmail.com
Mon Nov 18 20:21:49 UTC 2013
sampling_down_factor is a tunable for the ondemand frequency governor.
Intuitively, higher values of sampling_down_factor make ondemand act more
like performance. For those computers where ondemand has a performance
penalty compared to performance, this is good, with the obvious downside of
higher power consumption.
Where does this performance penalty come from? Some of it is from the
basic operation of ondemand, the checks that it does, and the lag between
when a heavy cpu load hits and when ondemand actually turns up the clock
frequency. Another, larger, performance penalty can come when (under load)
ondemand seems to resonate the cpu frequency instead of keeping it high.
My theory is that there is some insidious issue where the logic of
ondemand sets up resonance with certain hardware specific setups instead of
properly detecting the system as being under load.
Question of this email: If the best value for sampling_down_factor is
hardware specific, how would it be included into Ubuntu? Is it a kernel
issue? distro issue? upstart issue? or something else?
A few years ago, when I first noticed this issue, I tested a performance
drop of about %30. Today it seems to be around %10. I found a value of
about 400 for sampling_down_factor wiped out the performance penalty of
ondemand for me.
Here is an old bug report (
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/862785) from someone
else who had significant performance issues.
Here is a relatively recent analysis that takes into account power usage (
There, a value of 7 was determined to be the sweet spot.
On a different webpage that I don't have in front of me, I saw a comment
saying that a value of 200 caused a performance issue, which leads me to
believe that intermediate values could cause other unforeseen resonance
issues on certain hardware setups.
So again, how could this be "fixed" in Ubuntu? If there are hardware
specific optimal values for sampling_down_factor, how would that get
included into Ubuntu?
One thought I had would be to just have some conservative values tied to
the powersaving: a relatively low one for anything on battery mode, and a
relatively high one for everything else, where power usage is not a concern.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Ubuntu-devel-discuss