Counter Site Statistics

How does CpuIdle work?

Why CPUs Produce Heat

Due to CMOS technology modern microprocessors are manufactured not only with transistors but also capacitors and resistors. The resistors create heat that must be conducted away from the processor.

Classic Cooling Methods

Removing the heat from the CPU core is easier with higher temperature gradients. For this reason microprocessors are not only equipped with large heat sinks but also actively cooled with fans or Peltier cooling elements. Higher temperatures worsen parasitic effects like electromigration or oxide breakdown that might eventually lead to failure. A temperature increase of 10 degrees centigrade means a halfed lifetime for chips. This holds true for the microprocessor and for the voltage regulation module (VRM) that supplies the I/O and core voltages. Many outdated or cheap motherboard designs employ passive VRMs that generate additional heat in the PC.

The CpuIdle Approach

Under normal circumstances the CPU isn't always active but spends much time waiting for the keyboard, harddisk or CD-ROM. What would be more logical than to turn off the CPU for that period? That's exactly what the HLT machine instruction (Opcode F4) does. Whenever the CPU encounters a HLT instruction the clock is halted and the CPU enters suspend mode until an interrupt, NMI, or reset happens. With the advent of power saving microprocessors like the Cyrix Cx486S the HLT instruction elicits an additional benefit. When "Suspend on HLT" is enabled in the configuration register the processor not only stops on HLT but also enters the power saving suspend mode.

Why Doesn't Windows Do That?

Modern operating systems like Linux execute the HLT instruction in an idle priority thread. This thread is always executed when the CPU is otherwise idle. No additional execution time for HLTing is needed, the CPU will not run slower.

While other operating systems like Linux always used this mechanism, Windows only learned it with NT. But even with NT and following versions it is only enabled when the BIOS and ACPI implementation is recognized by the OS.

The Chipset Part

With modern chipsets like VIA KX or SiS 7x5 an additional variable enters the equation. These chipsets need to be specifically programmed to allow the CPU entering the HLT state. Windows itself does not perform this programming (chipset optimization in CpuIdle), the BIOS must handle it- which many, even modern, BIOS implementations don't do.