
OS influence on power consumption
Power consumption is an issue. With portable devices this affects battery life. With mains powered equipment, power consumption is also a concern for environmental reasons. The matter of power has always been seen as a “hardware issue”, but, in the last few years, there has been an increasing interest in the role of software …
It is clear that software can take an active role in managing power consumption, if the right capabilities are provided. For example, parts of a system may be switched on and off, as required. The clock speed of a processor may be adjusted according to the amount of work it needs to do at a particular moment. The clock frequency can have a very significant effect upon power consumption.
Another, more simplistic argument is based upon selection of operating system. A traditional RTOS is likely to have a significantly smaller memory footprint than Linux, so less memory needs to be fitted. As memory consumes power, less memory means less power consumption. This argument is sound, but may be countered by the assertion that memory power consumption is really not too bad.
A while ago, I was working with a colleague who has been doing some research into these matters. He showed me that there is an even simpler perspective: the amount of power the CPU consumes, when doing a particular job, will vary depending on the OS. His experiment was conducted using a media player device. It was decoding an MP3 of a 71db 220Hz sine wave. He ran the code twice: the first time executing the application under an RTOS, the second using Linux. The power consumed was measured and plotted over time.
On the plot power consumed, when running the RTOS, is shown in pink; Linux is dark blue. The results are interesting: when running Linux the CPU was consuming nearly 25% more power than when it was doing the exact same job under the RTOS.
There is also an increase in power consumption of another 20% [about two thirds of the way through the plot] when running Linux. What caused this? We do not know. Obviously Linux was doing something in this time frame, which affected its CPU load.
This experiment set out to see whether a conventional RTOS really did benefit a design in terms of power consumption. It succeeded in this goal. It also illustrated quite graphically the non-real-time [i.e. unpredictable] behavior of Linux, which may be a problem for certain applications.

- Comments
- Write a Comment Select to add a comment
To post reply to a comment, click on the 'reply' button attached to each comment. To post a new comment (not a reply to a comment) check out the 'Write a Comment' tab at the top of the comments.
Please login (on the right) if you already have an account on this platform.
Otherwise, please use this form to register (free) an join one of the largest online community for Electrical/Embedded/DSP/FPGA/ML engineers: