cvs commit: src/etc/defaults rc.conf

Nate Lawson nate at root.org
Sat Jan 28 22:12:37 PST 2006


Kris Kennaway wrote:
> On Sun, Jan 29, 2006 at 05:51:58AM +0000, Nate Lawson wrote:
> 
>>njl         2006-01-29 05:51:58 UTC
>>
>>  FreeBSD src repository
>>
>>  Modified files:
>>    etc/defaults         rc.conf 
>>  Log:
>>  Enable the lowest Cx state by default.  This will save power and we have
>>  had enough testing of acpi_cpu to know this is stable now.
> 
> 
> On my desktop system (running RELENG_6 though), setting
> hw.acpi.cpu.cx_lowest=C0 causes atrocious performance.  Is it broken
> in 6.x?

Uh, C0 is not a real C-state.  C1 is the lowest actual one (it's the HLT 
instruction on x86).  What's probably happening is the idle thread is 
spinning instead of HLTing and the time to switch in your active thread 
is slow.

This is from acpi(4):
hw.acpi.cpu.cx_lowest
      Lowest Cx state to use for idling the CPU.  A scheduling algo-
      rithm will select states between C1 and this setting as system
      load dictates.  To enable ACPI CPU idling control,
      machdep.cpu_idle_hlt must be set to 1.

So see if setting machdep.cpu_idle_hlt=0 causes the same problem.  I'll 
also add a check to disallow setting it to C0 and tell the root user to 
use sysctl machdep.cpu_idle_hlt instead.

-- 
Nate


More information about the cvs-src mailing list