Systematic Detection of Energy Regressions in Java Projects and Identification of Regression Code Patterns

Evolution plot showing commit cc2363e and nearby commits.

Green software engineering is emerging as a crucial response to the rising energy impact of digital technologies, which may soon rival aviation and shipping combined. While several tools aim to help developers track energy consumption and detect regressions, they all have their own limitations. This motivated the development of EnergyTrackr, a fully modular and automated tool designed to detect statistically significant energy changes.

The main goal was to uncover energy anti-patterns as a first step toward building energy- aware linters. To achieve this, a custom pipeline was implemented: one module iterates over a repository’s history and measures energy usage per commit; another generates interactive reports enabling developers to spot energy regressions faster. Stability was improved through system setup script and statistical validation methods.

Experiments on three Java projects (Jsoup, univocity-parsers, fastexcel) confirmed the tool’s ability to identify significant energy changes and highlighted recurring anti-patterns such as missing early exits or costly dependency upgrades. EnergyTrackr is ready to integrate into developer workflows and lays the groundwork for building energy-aware linters, pending further large-scale studies.

François Bechet
Msc Student