lumbda/docs/benchmark-ack.dot
russell@unturf.com 5fb1f0cb17 Add benchmark dot diagrams showing performance differences
5 new diagrams (Graphviz DOT → PNG):
  benchmark-ack.dot      — ack(3,4) across all 5 tiers
  benchmark-sumto.dot    — sum-to(50k) across all 5 tiers
  benchmark-fib.dot      — fib(35) iterative across all 5 tiers
  benchmark-speedup.dot  — JIT speedup ratios (7x-784x)
  benchmark-binary-size.dot — 13KB asm vs 171KB C vs ~30MB Python

JIT: 0.19ms ack, 7x faster than CPython, 784x faster than Python VM.
Makefile docs target now auto-discovers all docs/*.dot files.
2026-04-16 13:01:32 -04:00

19 lines
822 B
Text

// ack(3,4) benchmark — all implementations
// "A diagram is worth 10,000 words." — russell@unturf.com
digraph benchmark_ack {
rankdir=LR
node [shape=record, style=filled, fontname="Helvetica", fontsize=11]
edge [style=invis]
label="ack(3,4) — time in milliseconds (lower is better)"
labelloc=t
fontsize=14
fontname="Helvetica Bold"
jit [label="{C + JIT|0.19 ms}" fillcolor="#00b894" fontcolor=white width=0.5]
cpython [label="{CPython|1.3 ms}" fillcolor="#0984e3" fontcolor=white width=1.5]
asm [label="{Assembly|8 ms}" fillcolor="#6c5ce7" fontcolor=white width=3.0]
cinterp [label="{C interpreter|20 ms}" fillcolor="#fdcb6e" width=5.0]
pyvm [label="{Python VM|149 ms}" fillcolor="#e17055" fontcolor=white width=10.0]
jit -> cpython -> asm -> cinterp -> pyvm
}