tobogganSe connecter

louise

Clone avec HTTPS, un jeton personnel en mot de passe, ou avec SSH, une clé ajoutée dans vos paramètres.

67 lignes · 5191 octetsBrut · Historique

Performance

Four small programs, written idiomatically in each language (tests/compare, run by scripts/compare.sh; every toolchain is pinned by tests/compare/Containerfile). Each prints the same number. Instructions are the stable signal where wall clock varies on a shared machine; wall clock is best of 5 runs.

lists: a map/filter/fold pipeline over a million integers, ten times

languagewallinstructionspeak memoryexecutable (stripped)
Haskell (GHC)0.05 s0.22G3 MB956 KB
Louise0.05 s0.47G6 MB466 KB
Go0.08 s0.27G34 MB1.5 MB
Rust0.09 s0.15G17 MB337 KB
Java0.90 s12.49G449 MBruntime
Node1.36 s10.37G162 MBruntime
Python1.54 s10.46G130 MBruntime
Gleam (on node)19.96 s122.56G704 MBruntime

fib: calls and integer arithmetic (naive Fibonacci of 35)

languagewallinstructionspeak memoryexecutable (stripped)
Rust0.04 s0.29G1 MB337 KB
Haskell (GHC)0.07 s0.42G3 MB956 KB
Go0.07 s0.43G2 MB1.5 MB
Java0.10 s0.45G36 MBruntime
Louise0.12 s0.95G6 MB459 KB
Node0.32 s1.90G55 MBruntime
Gleam (on node)0.35 s2.05G58 MBruntime
Python1.56 s15.81G8 MBruntime

trees: build and walk binary trees (allocation)

languagewallinstructionspeak memoryexecutable (stripped)
Haskell (GHC)0.15 s0.99G7 MB957 KB
Java0.26 s1.05G148 MBruntime
Louise0.30 s2.34G8 MB468 KB
Node0.44 s2.62G85 MBruntime
Rust0.68 s5.69G5 MB337 KB
Go0.79 s6.00G11 MB1.5 MB
Python2.46 s22.82G12 MBruntime
Gleam (on node)5.22 s39.14G196 MBruntime

floats: arithmetic in a loop, three million times

languagewallinstructionspeak memoryexecutable (stripped)
Rust0.00 s0.02G1 MB357 KB
Go0.00 s0.02G2 MB1.5 MB
Haskell (GHC)0.00 s0.02G4 MB2.3 MB
Louise0.00 s0.03G6 MB410 KB
Java0.10 s0.38G42 MBruntime
Node0.16 s0.44G58 MBruntime
Gleam (on node)0.19 s0.53G60 MBruntime
Python0.52 s4.99G8 MBruntime

Before the unboxing milestone (#190) the same loop took 653M instructions and 83 ms: every + allocated a heap block.

A release build of hello world is 387 KB: a static executable with the actor scheduler, the allocator and the runtime (ADR 0042).

What the numbers say:

  • Calls and arithmetic: Int-heavy functions now run on unboxed machine integers (ADR 0045 Revision 2): a worker keeps raw int64s in registers and tags only at the boundary, bailing to the boxed path on overflow so promote-to-bigint semantics are exact. fib's instructions fell by a third (1.40G → 0.95G): Louise is now about 3× Rust and 2.3× GHC on a call-heavy loop, and nearly 3× faster than Node. The remaining gap is per-call preemption and yield checks (#193) and devirtualising trait calls (#192) is next.
  • Float arithmetic: a float loop's arithmetic runs on raw doubles, allocating nothing: 31M instructions, about twice Rust's (15M) and 1.3–1.4× Go's and GHC's, and an order of magnitude fewer than Node or Java. Until #190 every + allocated a heap block (the same loop: 653M instructions, 83 ms).
  • List pipelines: the Core optimiser (#195–#200) fuses range |> map |> filter |> fold into one loop that allocates nothing per element — and now does so inside if/match arms too, which the benchmark's own pipeline had been missing (it built both intermediate lists: 2.66G instructions). Fused, the pipeline is 0.47G instructions (−82%) and 6 MB peak (−83%): Louise ties GHC's list fusion on wall clock and is ahead of Rust's collecting iterators, though Rust's unboxed Vec still leads on instructions (0.15G). std/iter's lazy iterators fuse without rewrite rules (#199).
  • Allocation-heavy code: reference counting with in-place reuse (Perceus) is faster than Rust's Box with the system allocator and close to GHC's garbage collector, in a fraction of Node's memory — and with a fraction of the instructions of everything but Haskell.

Measured in the pinned container (tests/compare/Containerfile), on one machine: Intel Core Ultra 7 155H, with rustc 1.99, GHC, Go, OpenJDK, Node and Python from Fedora 44. The other languages are from 2026-10-15; the Louise rows are re-measured on 2026-10-19 (their instruction counts on the host — rootless containers cannot open perf events on this kernel — with the same binaries and the same user-space event). Instructions are user-space, counted once per program; wall clock is best of 5. Small programs show orders of magnitude, not a ranking.