How do code refactorings affect energy usage?

How do code refactorings affect energy usage?
复制标题

代码重构如何影响能源使用?

DOI:
10.1145/2652524.2652538
复制
发表时间:
2014
期刊:
Proceedings of the 22nd ACM SIGSOFT International Symposium on Foundations of Software Engineering
影响因子:
--
通讯作者:
J. Clause
J. Clause
中科院分区:
--
文献类型:
--
作者:
C. Sahin;L. Pollock;J. Clause

文献摘要

被引文献

相似文献

背景:代码重构对可理解性、可维护性和可扩展性的好处众所周知,重构的自动化支持现在在 IDE 中很常见。然而,目前执行此类转换的决定并未考虑重构对能源消耗的影响。这主要是由于缺乏向开发人员提供此类相关信息的信息和工具。不幸的是,对能源效率的担忧正在迅速成为许多环境中的首要问题,包括嵌入式系统、笔记本电脑、移动设备和数据中心。 目标:我们的目标是解决代码重构对能源效率影响的信息缺乏问题。 方法:我们进行了实证研究,调查 6 种常用重构的 197 种应用的能源影响。 结果:我们发现重构不仅会影响能源使用,还会增加或减少应用程序的能源使用量。此外,我们还表明,通常认为与能源使用相关的指标不太可能完全预测应用重构的影响。 结论:本研究和类似研究的结果可用于增强 IDE,帮助软件开发人员构建更节能的软件。
Context: Code refactoring's benefits to understandability, maintainability and extensibility are well known enough that automated support for refactoring is now common in IDEs. However, the decision to apply such transformations is currently performed without regard to the impacts of the refactorings on energy consumption. This is primarily due to a lack of information and tools to provide such relevant information to developers. Unfortunately, concerns about energy efficiency are rapidly becoming a high priority concern in many environments, including embedded systems, laptops, mobile devices, and data centers. Goal: We aim to address the lack of information about the energy efficiency impacts of code refactorings. Method: We conducted an empirical study to investigate the energy impacts of 197 applications of 6 commonly-used refactorings. Results: We found that refactorings can not only impact energy usage but can also increase and decrease the amount of energy used by an application. In addition, we also show that metrics commonly believed to correlate with energy usage are unlikely to be able to fully predict the impact of applying a refactoring. Conclusion: The results from this and similar studies could be used to augment IDEs to help software developers build more energy efficient software.