# Clbg Energy Eval

> Evaluates the runtime performance and energy efficiency of different programming language implementations. It specifically compares Lua interpreters, LuaJIT JIT compilers, and C on computationally intensive benchmark programs from the Computer Language Benchmarks Game. Use when the user wants to benchmark on CLBG (Computer Language Benchmarks Game), or asks about evaluating this task. Reports Energy Consumption.

- Skill: `qhjqhj00/clbg-energy-eval` (Agent Skill)
- Install (CLI): `npx skillmds add qhjqhj00/clbg-energy-eval`
- Raw SKILL.md: https://api.skillmd.com/api/skills/qhjqhj00/clbg-energy-eval/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: qhjqhj00 (https://skillmd.com/u/qhjqhj00)
- Updated: 2026-09-08
- Page: https://skillmd.com/skills/qhjqhj00/clbg-energy-eval

---


# clbg-energy-eval

> The Green Side of the Lua — André Brandão et al. (arXiv:2601.16670, 2026)

## What this evaluates

Evaluates the runtime performance and energy efficiency of different programming language implementations. It specifically compares Lua interpreters, LuaJIT JIT compilers, and C on computationally intensive benchmark programs from the Computer Language Benchmarks Game.

## Datasets

- **CLBG (Computer Language Benchmarks Game)** — total ?; splits: test (-1)

## Metrics

- `Energy Consumption` **(primary)** — range: other
  - Total energy measured in Joules (J) using Intel RAPL for CPU Package and DRAM domains.
- `Runtime` — range: other
  - Execution time measured in seconds.
- `Speedup` — range: other
  - Ratio of runtime of non-optimized version ($T_{\phi}$) to optimized version ($T_{o}$). Values > 1 indicate faster optimized implementation.
- `Greenup` — range: other
  - Ratio of energy consumption of non-optimized version ($E_{\phi}$) to optimized version ($E_{o}$). Values > 1 indicate reduced energy usage.
- `Powerup` — range: other
  - Ratio of power consumption of optimized version ($P_{o}$) to non-optimized version ($P_{\phi}$), calculated as Speedup / Greenup. Values < 1 indicate lower average power consumption.

## Input / output format

**Input**: CLBG benchmark programs (e.g., fannkuch-redux, spectral-norm, Fibonacci) implemented in Lua, LuaJIT, or C, executed on a laptop with Intel RAPL energy monitoring.

**Output**: Raw energy consumption (Joules for Package and DRAM domains), execution time (seconds), and derived ratios (Speedup, Greenup, Powerup) relative to a reference implementation.

## Scoring recipe

```python
def compute_green_metrics(runtime_phi, runtime_o, energy_phi, energy_o):
    speedup = runtime_phi / runtime_o
    greenup = energy_phi / energy_o
    powerup = speedup / greenup
    return {'Speedup': speedup, 'Greenup': greenup, 'Powerup': powerup}
```

## Common pitfalls

- Energy measurements rely on Intel RAPL, which may not capture all system power draw or vary across hardware.
- Comparisons across different programming language rankings use different machines/environments, making cross-study comparisons unreliable.
- Outliers are removed using the Inter-Quartile Range (IQR) method before analysis, which can skew results if not reported transparently.

## Evidence (verbatim from paper)

> Considering two different versions of a specific software, one that is optimized and one that is not, the following metrics are defined:

|  | $\textit{Speedup}\=\frac{T_{\phi}}{T_{o}}$ |  | (1) |
| --- | --- | --- | --- |

In the Speedup equation $T_{\phi}$ represents the runtime of the non-optimized version, and $T_{o}$ represents the runtime of the optimized version.
This metric quantifies the performance gain, where values above 1 indicate a faster optimized implementation.

## Citation

```bibtex
@misc{brandao2026greensideoflua,
  title={The Green Side of the Lua},
  author={André Brandão et al.},
  year={2026},
  note={arXiv:2601.16670}
}
```

- arXiv: 2601.16670

