All 57 Entries

Joule Technical Overview & Founding Story: Compile-Time Energy Budgets for Systems Software

February 4, 2026 language specification whitepapers introducing Joule: an affine-ownership systems language with static @energy_budget annotations (est_j), RAPL/ARM runtime meters (reported_j), and a Cranelift/LLVM/MLIR tri-backend compiler architecture.

David Charlot • • Addendum & Errata: Nov 25, 2026 • 6 min read • Glossary • Verification & AI-Use Disclosure
joule-lang energy-budgets compilers llvm mlir rapl historical-whitepaper

Part I: Contemporary Historical Summary (As Written in February 2026)

Historical Source Provenance (Original Date: February 4, 2026): David Jean Charlot, PhD · Open Interface Engineering. Synthesizes two companion February 4, 2026 publications: the Joule Technical Overview PDF and The Joule Story PDF (openIE-dev/joule-lang).

Origin: Naming a Systems Language After James Prescott Joule (1850)

In 1850, James Prescott Joule established with a falling weight and a paddle-wheel calorimeter that mechanical work and thermal dissipation are conserved forms of the same physical quantity, measured in joules.

Modern systems languages provide static integer widths, affine ownership lifetimes for heap memory safety, and type-checked concurrency primitives—yet lack first-class language constructs for bounding the physical energy a routine may dissipate. Motivated by Pereira et al.’s SLE 2017 benchmark comparison (CPython at 75.88x vs. C at 1.00x and Rust at 1.03x) and Pinto et al.’s measurements showing garbage collection accounting for 5–25% of managed-runtime energy, the February 4, 2026 Joule (v0.1) specification proposed elevating energy contracts into function signatures and compiler passes.

Language Primitives: Affine Ownership + @energy_budget

Joule specified Hindley–Milner local type inference and affine ownership/borrowing (deterministic RAII deallocation without stop-the-world tracing GC) alongside static and runtime energy primitives:

// Illustrative Joule v0.1 specification syntax (February 2026)
@energy_budget(250_microjoules)
@target(SIMD)
fn normalize_sensor_frame(buf: &mut [f32; 256]) -> f32 {
    let meter = energy::Meter::hardware(); // Intel RAPL / ARM Energy Probe
    let mut acc: f32 = 0.0;
    for x in buf.iter() {
        acc += (*x) * (*x);
    }
    let inv = acc.sqrt().recip();
    for x in buf.iter_mut() {
        *x *= inv;
    }
    meter.elapsed_microjoules()
}

Core language mechanisms specified in the February 4, 2026 overview included:

  • Compile-Time Energy Contracts (@energy_budget, @energy_profile): Static instruction-weight and memory-hierarchy cost tables warn or reject builds when an annotated function introduces an unbounded loop, unexpected heap allocation, or strided DRAM gather exceeding its nominal budget.
  • Structured scope Concurrency & @auto_place(optimize_for: Energy): Explicit data-movement scopes allow @kernel blocks to target CPU SIMD, @target(GPU), or NPU backends when amortization exceeds transfer cost.
  • Zero-Overhead Foreign Interop: Direct C ABI FFI and wasm32-wasi targets for incremental adoption inside existing polyglot services.

Tri-Backend Compiler Architecture Specification

To balance debug turnaround against production code generation, the Technical Overview specified a Tri-Backend Compiler lowering a shared typed IR across three backends:

Compiler BackendTarget RegimeCompilation Speed / RoleEnergy Optimization Focus
CraneliftDebug & interactive edit-test builds~10x faster compile time (vs. full LLVM -O3 release builds)Lowers developer/CI rebuild CPU time during iteration
LLVM (-Oe / -Oez)Production CPU binaries (x86_64, AArch64, RISC-V)Whole-program optimizationSIMD vectorization, L1/L2 cache loop tiling, instruction-energy cost selection
MLIRGPUs, TPUs, FPGAs, custom acceleratorsPolyhedral & linalg dialect loweringOperator fusion, scratchpad SRAM promotion, minimizing HBM/DRAM traffic

Section 6 of the February 2026 Technical Overview explicitly noted that static compile-time @energy_budget bounds—like Worst-Case Execution Time (WCET) bounds in real-time systems—cannot predict dynamic L3 cache contention, silicon bin variance, or OS DVFS p-state transitions, requiring runtime hardware-counter verification (energy::Meter::hardware()).


Methods, Implementation Status & Licensing Scope Box (reported_j / est_j)

  1. Distinguishing the Feb 4, 2026 v0.1 Specification From Subsequent Bootstrap Milestones:
    • At publication on February 4, 2026, PDFs #13 and #14 constituted a forward-looking v0.1 language and compiler specification (the -Oe LLVM energy-cost pass and full MLIR polyhedral backend were architectural targets, not benchmarked production compilers in February 2026; the ~10x Cranelift compile-time ratio reflects standard Cranelift JIT/debug codegen speed in the denominator vs. optimizing LLVM -O3 release builds in the numerator).
    • Over the following four months (by June 2026), joule-lang reached a ~15.5 kloc self-hosted bootstrap lowering onto OpenIE’s unified flowG FunctionGraph IR (openIE-dev/flow-g).
  2. Epistemic Non-Mixing Across Compile-Time (est_j) vs. Runtime (reported_j):
    • Static @energy_budget checks sum analytical instruction/cache cost weights (est_j), whereas energy::Meter::hardware() reads on-chip telemetry (Intel/AMD RAPL, Apple IOReport, ARM probes = reported_j). Both remain strictly distinct from external inline DC shunt instrumentation (measured_j).
  3. Artifact & Licensing Status: Unlike Papers #01–#12 (CC BY-ND 4.0), archival PDFs #13 (Joule Technical Overview) and #14 (The Joule Story) were published under CC BY 4.0. The public language specification, grammar, and bootstrap repository at openIE-dev/joule-lang is licensed under Apache-2.0 (while early pre-flowG internal compiler experiments resided in private workspace mirrors).

Chronological Evolution Within OpenIE Research

  1. OS-Level Joule Envelopes (JouleOS): Because an energy-blind OS scheduler can invalidate process-local @energy_budget assumptions via cache thrashing and DVFS p-state shifts, subsequent work moved joule accounting and thermal budget enforcement into JouleOS.
  2. Verified Graph IR Execution (Reality Code Engine (RCE)): Paired joule-lang / flowG lowering with machine-checked execution invariants (2,221 deterministic checks in openIE-dev/rce).
  3. Calibrating Against Inline DC Shunts (The Eco-Stack): Anchored kernel-level primitives on external DC shunt benches (measured_j) across AMD Kria KV260 (11.43 nJ) and NVIDIA Jetson Thor (125–176 nJ).
  • Cohen, M., Zhu, H. S., Emgin, E. S., & Liu, Y. D. (2012). Energy Types. OOPSLA 2012, 831–850 — foundational programming-language type system modeling CPU power phases and energy-aware execution modes.
  • Sampson, A., Dietl, W., Fortuna, E., Gnanapragasam, D., Ceze, L., & Grossman, D. (2011). EnerJ: Approximate Data Types for Safe and General Low-Power Computation. PLDI 2011, 164–174.
  • Wilhelm, R., Engblom, J., Ermedahl, A., et al. (2008). The Worst-Case Execution-Time Problem—Overview of Methods and Survey of Tools. ACM Transactions on Embedded Computing Systems, 7(3), Article 36; Georgiou, K., Kerrison, S., Ziegenbein, D., & Eder, K. (2017). less: Static Energy Consumption Analysis of Embedded Programs — prior art on static WCET/WCEC instruction-energy bounds and cache/pipeline state explosion.
  • Pereira, R., et al. (2017). Energy Efficiency Across Programming Languages. SLE 2017; Pinto, G., Castor, F., & Liu, Y. D. (2014). OOPSLA 2014.
  • Jung, R., et al. (2018). RustBelt: Securing the Foundations of the Rust Programming Language. POPL 2018 — formal foundation for affine ownership and borrowing.
  • Lattner, C., et al. (2021). MLIR: Scaling Compiler Infrastructure for Domain Specific Computation. CGO 2021.

Changelog (2026-11-25)

  • Separated Part I (February 4, 2026 v0.1 language specification) from Part II (November 25, 2026 implementation timeline, epistemic separation, licensing, and related work).
  • Stated exact CC BY 4.0 licensing for PDFs #13–#14 and Apache-2.0 licensing for openIE-dev/joule-lang (noting pre-flowG internal compiler mirrors).
  • Clarified static @energy_budget (est_j) vs. runtime RAPL/IOReport (reported_j), named the LLVM -O3 vs. Cranelift compile-speed denominator, and added citations to Energy Types (Cohen et al., OOPSLA 2012), EnerJ (Sampson et al., PLDI 2011), Wilhelm et al. WCET (2008), Georgiou et al. WCEC (2017), RustBelt, and MLIR.
DC

David Charlot

Open Interface Engineering, Inc. · Signed Provenance · Self-Checked

Archival PDFs (#13 and #14) public at /papers/archive/13-Joule-Technical-Overview.pdf and /papers/archive/14-The-Joule-Story.pdf under CC BY 4.0; public language repository openIE-dev/joule-lang is licensed under Apache-2.0 (while early pre-flowG compiler prototypes were developed in private workspace mirrors). Full licensing & AI-use disclosure →

Archival v0.1 language whitepapers (#13 & #14, Feb 4, 2026); public repo & ~15.5 kloc bootstrap at openIE-dev/joule-lang (Apache-2.0); early internal compiler experiments lowered onto openIE-dev/flow-g

Check the primary artifacts or run an independent replication

Inspect signed provenance manifests, rerun our public Apache-2.0 commodity-hardware replication kits, review our November 25, 2026 outside-review errata, or browse primary manuscripts on the Research Hub.