Jul 032008

PowerTOP is a free opensource tool from intel to show whats causing the computer to use more power. PowerTOP is a Linux tool that helps you find those programs that are misbehaving while your computer is idle. The application that misbehaved the most was the Linux kernel. However, as of version 2.6.21, the Linux kernel went tickless, and no longer has a fixed 1000Hz timer tick. The result is huge power savings because the CPU stays in low power mode for longer periods during system idle.

There are many things that can ruin the party, both inside the kernel and in userspace. PowerTOP combines various sources of information from the kernel into one convenient screen so that you can see how well your system is doing at saving power, and which components are the biggest problems.

PowerTOP has these four basic goals:

  • Show how well your system is using the various hardware power-saving features

  • Show you the culprit software components that are preventing optimal usage of your hardware power savings

  • Help Linux developers test their application and achieve optimal behavior

  • Provide you with tuning suggestions to achieve low power consumption

For PowerTOP to work best, use a Linux kernel with the tickless idle (NO_HZ) feature enabled (version 2.6.21 or later). Currently, only 32-bit kernels have support for tickless idle; 64-bit kernels are expected to gain this feature in version 2.6.23.

PowerTOP works best on a laptop computer, or at least a computer with an Intel mobile processor (certain small non-laptop devices also contain a mobile processor). When using PowerTOP on a laptop, do so when running on battery.

PowerTOP can be installed in SUSE and openSUSE from the YaST repositories.

Opensuse11:~ # yast2 –install powertop

This should install the software on your PC or laptop.

Once installed, run the software as

opensuse11:~ # powertop

This starts the application and updates the status every 5 seconds give clear idea of what the DP us doing and what is causing the CPU to operate at various power utilization levels.

In the screenshot attached

PowerTOP - Opensource tool to measure power

C state information

C-states are operating modes of the CPU when it’s idle. The higher the C-state number, the less power is used by the CPU; however the longer it will take to get the CPU back to executing instructions.
C0 is special–in C0, the CPU is actually executing instructions. In all other C-states, the CPU is idle and not executing instructions.

To get decent power savings during idle, the CPU should be in C3 or C4 most of the time. In addition, the longer the average time in these C-states, the more power is saved. Ideally, your CPU spends at least 95% of its time in C4, for an average of 50 or more milliseconds.

Wakeups per second

The “Wakeups per second” line is another indicator for how well your laptop is doing in terms of getting power savings: the lower the number the better. When running a full GNOME desktop, 3 wakeups per second is achievable.

Power usage

When your laptop is running on battery, PowerTOP uses ACPI to collect information on how much power you are currently using. In addition, PowerTOP calculates an estimate for how many hours of battery you have left.

Note: If you’re not running on battery, or not running PowerTOP on a laptop, this information will not be available.

For more information and tips and tricks, click here