~/talk

Micro Benchmarking - The Art of Realizing One is Wrong

Talkat Devoxx Belgium 2024 · 2024-10-07..10-11· [testing]
links:none on file
slides:none on file

Uses JMH to show that tiny Java benchmarks lie: system arraycopy vs manual copy flips winners across JDKs and CPUs, measuring clock resolution and seeing 20–100 ns timer noise, dead‑code elimination removes work unless results are returned or blackhole consume is used, loop unrolling and inlining hide costs, cache misses (L1/L2/L3) blow times from tens to hundreds of ns, allocation churn dominates some results, and warmup/tiers produce different compiled code — use JMH, perf and async‑profiler and validate with real production data and escape analysis.

AI-written summary · about

  1. 0:00Introduction and setup
  2. 10:16What is micro benchmarking
  3. 27:59First benchmark and warmup confusion
  4. 44:43Dead code elimination and inlining
  5. 1:06:43Common benchmarking mistakes
  6. 1:24:36Break and hardware insights
  7. 1:43:42Warmup and JIT unpredictability
  8. 2:03:19Threads and CPU scaling
  9. 2:20:54String concatenation myths
  10. 2:31:10When to use micro benchmarks
  11. 2:40:20Q&A and summary
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.