Energy consumption of software applications has emerged as a critical concern for developers to contemplate in their daily development processes. Previous studies have surveyed a limited number of developers to understand their viewpoints on energy consumption. We complement these studies by analyzing a meticulously curated dataset of 1,193 Stack Overflow (SO) questions concerning energy consumption. These questions capture real-world energy-related challenges in practice. To understand practitioners' perceptions, we investigate the intentions behind these questions, semantic topics, and associated technologies (e.g., programming languages). Our results reveal that: (i) the most prevalent energy consumption topic is about balancing Positioning usage; (ii) efficiently handling data is particularly challenging, with these questions having the longest response times; (iii) practitioners primarily ask questions to understand a concept or API related to energy consumption; and (iv) practitioners are concerned about energy consumption across multiple levels-hardware, operating systems, and programming languages-during energy efficient software development. Our findings raise awareness about energy consumption's impact on software development. We also derive actionable implications for energy optimization at different levels (e.g., optimizing API usage or hardware accesses) during energy-aware software development.
翻译:软件应用的能耗已成为开发者在日常开发过程中必须考量的关键问题。先前的研究通过调查有限数量的开发者来了解他们对能耗的看法。我们通过分析一个精心整理的包含1,193个Stack Overflow(SO)上关于能耗的问题数据集来补充这些研究。这些问题捕捉了实践中真实世界的能耗相关挑战。为了理解从业者的认知,我们调查了这些问题背后的意图、语义主题以及相关技术(例如编程语言)。我们的研究结果表明:(i)最普遍的能耗主题是关于平衡定位服务的使用;(ii)高效处理数据尤其具有挑战性,这些问题拥有最长的响应时间;(iii)从业者主要提问是为了理解与能耗相关的概念或API;(iv)在节能软件开发过程中,从业者关注硬件、操作系统和编程语言等多个层面的能耗。我们的发现提高了对能耗在软件开发中影响的认识。我们还为能耗感知软件开发过程中不同层面(例如优化API使用或硬件访问)的节能优化提出了可操作的启示。