Re: powerd and multicore

From: Gavin Atkinson <gavin_at_FreeBSD.org>
Date: Wed, 3 Sep 2008 20:11:56 +0100 (BST)
On Mon, 1 Sep 2008, David Naylor wrote:
> The way I understand powerd works by default is that it monitors the CPU usage
> (or idleness) and changes the CPU frequency accordingly.  The default values
> are >95% idle => decrease frequency; <65% idle => increase frequency.
>
> The problem arises when you have a system with 4 or more 'cores'.  In this
> case the first CPU can be running flat out but still report an overall
> idleness of 75% and thus the frequency is not increased even though the first
> core could easily be stuck, at say 200 when capable of 2400.
>
> Should powerd be changed to look at CPU specific usage and adjust accordingly
> or scale the above defaults according to the number of CPU's.

There are a handful of PRs discussing this exact issue, and it is 
something I was hoping to look into at some point.  Have a search for 
powerd PRs, especially http://www.freebsd.org/cgi/query-pr.cgi?pr=119589 
(which contains patches).  You may well also be better off discussing this 
on the -acpi mailing list, which (although this is not strictly related to 
ACPI) may be the best place to find people ihnterested in power 
management.

> Furthermore, currently (with core 2) all CPU's are controlled using a single
> value however (I think) it is possible to have each CPU running on a
> different frequency (and at least with some other architectures).  Does
> powerd handle these cases?

I don't believe so, no.  I also don't know if the kernel would be ok with 
CPUs running at different speeds, even if things like timecounters work 
correctly the scheduler may need to grow some more knowledge of this.

Gavin
Received on Wed Sep 03 2008 - 17:42:31 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:34 UTC