{"id":4051,"date":"2012-11-19T14:56:19","date_gmt":"2012-11-19T13:56:19","guid":{"rendered":"https:\/\/blogs.mentor.com\/colinwalls\/?p=4051"},"modified":"2026-03-26T16:39:09","modified_gmt":"2026-03-26T20:39:09","slug":"power-at-the-nmi","status":"publish","type":"post","link":"https:\/\/blogs.sw.siemens.com\/embedded-software\/2012\/11\/19\/power-at-the-nmi\/","title":{"rendered":"Power and compilers at the NMI"},"content":{"rendered":"<p>I recently attended an <a href=\"http:\/\/www.nmi.org.uk\/events\/event-details\/embedded_ee_2012\" target=\"_blank\" rel=\"noopener noreferrer\">event<\/a> focused on power and embedded software hosted by the NMI in the UK, where I had been invited to make a presentation. My session was titled &#8220;Power Management in a Real Time Operating System&#8221;. If you would like a copy of the slides, please <a href=\"mailto:colin_walls@mentor.com\">email<\/a>.<\/p>\n<p>Of course, apart from presenting myself, I was interested in the other sessions, in particular one about compilers and power consumption &#8230;<!--more--><\/p>\n<p>The session that caught my eye was titled &#8220;The Impact of Compiler Options on Energy Consumption in Embedded Platforms&#8221;. This was a report on some university research work, which was seeking a correlation between the use of optimization options on a GNU compiler and the energy consumption during execution of the resulting code. The approach was to build the code of a selection of [rather arbitrary] benchmarks, using a large number of combinations of compiler options, then execute the code and measure power consumption. They also used a number of different target systems or different architectures [including multicore].<\/p>\n<p>My interpretation of their conclusions is that there were no clear conclusions. I felt that the research was not well designed or thought through. The use of compiler options was not systematic &#8211; they even used one, the function of which was unclear to the researchers. To my mind, this was equivalent to randomly mixing chemicals in the hope of creating a wonder drug. Their use of multiple targets [in the first instance] just served to complicate matters.<\/p>\n<p>I do, however, feel that this is an interesting area of research, but it needs a slightly different approach, largely focused on understanding compiler optimizations, hypothesizing on their effect on power and testing that hypothesis. In general, there are 3 kind of optimizations:<\/p>\n<ol>\n<li>Speed. Faster code is often larger, but is very likely to consume more energy to perform a specific task.<\/li>\n<li>Size. Compact code is usually slower, so is likely to consume more power. However, there is likely to be the opportunity to reduce the memory size, which represents a power saving. [This possibility was not addressed in the research.]<\/li>\n<li>\u00a0Lucky. Sometimes code is smaller and faster. Obviously this combines the benefits of (1) and (2).<\/li>\n<\/ol>\n<p>Interesting research would be to find out whether fast code does offer the best overall energy consumption result. This could result in compilers being provided with a &#8220;compile for low power&#8221; option.<\/p>\n<p>Other sessions at the event were interesting in various ways. There was a very inspiring session concerning a project to encourage young people to start writing software. Another session was presented by a guy who looked and sounded exactly like the comedian David Mitchell [who is well known in the UK, at least]. A session from Intel looked at the technology that they provide to enable software to optimize system power consumption. This included the random fact that the energy in a banana is equivalent to that held in two fully-charged laptop batteries. I do not believe that Intel are announcing banana powered computing &#8230;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I recently attended an event focused on power and embedded software hosted by the NMI in the UK, where I&#8230;<\/p>\n","protected":false},"author":71677,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spanish_translation":"","french_translation":"","german_translation":"","italian_translation":"","polish_translation":"","japanese_translation":"","chinese_translation":"","footnotes":""},"categories":[1],"tags":[382,300,308,503,327,504],"industry":[],"product":[],"coauthors":[],"class_list":["post-4051","post","type-post","status-publish","format-standard","hentry","category-news","tag-compiler","tag-embedded-software","tag-low-power","tag-nmi","tag-optimization","tag-power-management"],"_links":{"self":[{"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/posts\/4051","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/users\/71677"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/comments?post=4051"}],"version-history":[{"count":1,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/posts\/4051\/revisions"}],"predecessor-version":[{"id":10120,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/posts\/4051\/revisions\/10120"}],"wp:attachment":[{"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/media?parent=4051"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/categories?post=4051"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/tags?post=4051"},{"taxonomy":"industry","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/industry?post=4051"},{"taxonomy":"product","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/product?post=4051"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/blogs.sw.siemens.com\/embedded-software\/wp-json\/wp\/v2\/coauthors?post=4051"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}