lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 14 Jul 2009 16:37:32 +0200
From:	Corrado Zoccolo <czoccolo@...il.com>
To:	Matthew Garrett <mjg@...hat.com>
Cc:	Dave Jones <davej@...hat.com>, linux-kernel@...r.kernel.org,
	cpufreq@...r.kernel.org
Subject: Re: [PATCH] cpufreq: ondemand: Introduces stepped frequency increase

On Wed, Jul 8, 2009 at 7:47 PM, Matthew Garrett<mjg@...hat.com> wrote:
> On Wed, Jul 08, 2009 at 07:41:23PM +0200, Corrado Zoccolo wrote:
>> Hi Matthew,
>> > Is this a measured powersaving? The ondemand model is based on the
>> > assumption that the idle state is disproportionately lower in power than
>> > any running state, and therefore it's more sensible to run flat out for
>> > short periods of time than run at half speed for longer. Is this
>> > inherently flawed, or is it an artifact of differences in your processor
>> > design?
>>
>> The flawed assumption is that running at doubled frequency halves the
>> completion time.
>> On cpus that can change the core speed without impacting the
>> memory-cache bandwidth
>> (i.e. the Pentium M), workloads that access lot of memory go at the
>> same speed at
>> maximum and minimum frequency.
>> Now I see new CPUs that can flush their cache during deep idle states (Atoms),
>> this aggravates the aforementioned problem, rendering the high
>> frequency state much less appetible.
>
> Do you have numbers to support this? What effect does the ramping up
> have on user-visible latency?
I have the numbers now (see attached).
On my Pentium M machine, I run twice the following test, one with
freq_step = 100, and one with 5, sampling the remaining capacity every
20 minutes, for 12 samples.
* booted from battery after full discharge and full recharge.
* started firefox (with empty page)
* run the script:
for cpu in /sys/devices/system/cpu/cpu[0]/; do
    # reset to defaults for my system
    cat $cpu/cpufreq/phc_default_vids > $cpu/cpufreq/phc_vids
    echo ondemand > $cpu/cpufreq/scaling_governor
    echo 0 > $cpu/cpufreq/ondemand/ignore_nice_load
    echo 20000 > $cpu/cpufreq/ondemand/sampling_rate
done

for cpu in /sys/devices/system/cpu/cpu[0]/; do
    echo $1 > $cpu/cpufreq/ondemand/freq_step;
done

killall xscreensaver
sync
xrandr --output LVDS --off
for i in `seq 0 11`; do
    cat /proc/acpi/battery/BAT*/state > test.$1.$i.bat
    sleep 1200
done
xrandr --output LVDS --auto
shutdown -h now

The attached tsv shows that freq_step=5 saves around 1%-2% of power
with respect to freq_step=100 (default cpufreq behaviour).
>
> --
> Matthew Garrett | mjg59@...f.ucam.org
>



-- 
__________________________________________________________________________

dott. Corrado Zoccolo                          mailto:czoccolo@...il.com
PhD - Department of Computer Science - University of Pisa, Italy
--------------------------------------------------------------------------

View attachment "result.tsv" of type "text/tab-separated-values" (202 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ