Saltar al contenido

Is Your Elixir Code Actually Fast? Tobias Pfeiffer on Benchmarking

18 de septiembre de 2026 · 1 h 11 min

Notas del episodio

Everyone has an opinion about whether the BEAM is fast or slow. Almost nobody has actually measured it properly.

Tobias Pfeiffer -PragTob on the internet, benchmarking nerd, real-time engineer at Supabase -came to Elixir from Ruby because Ruby couldn't handle WebSockets at scale. Then he learned the language the way he learns every language: by building a benchmarking library. Ten years later, Benchee is what most of the Erlang and Elixir world reaches for when it wants a number instead of an argument.

Topics include:

  • why Tobias writes a benchmarking library every time he learns a new language -and what that discipline actually teaches about how a runtime works

  • the production scar: a benchmark that showed one query was faster, deployed it, and discovered the benchmark had been measuring the wrong input entirely

  • the single most important insight about benchmarking: most people quietly fool themselves and walk away more confident and more wrong than when they started

  • inputs as a first-class feature -the lesson José Valim taught Tobias within 17 minutes of an open GitHub issue

  • why body-recursive map is faster than tail-recursive map for small lists on the BEAM -and what that tells you about the runtime

  • what reductions are, why they're a more stable measurement than wall time, and when they diverge

  • how Benchee measures memory: spawning a monitored process, watching GC events, reporting exact bytes -and why deterministic code gives deterministic memory

  • the JSON benchmarking arms race -built-in OTP JSON, jason, Jiffy, and why comparison benchmarks usually miss the point

  • why Benchee has no macros, no DSL, and deliberately only uses functions -and why that design decision made it composable in ways nobody predicted

  • the hardest benchmarking mistake to stop making: confusing latency and throughput

  • what Toby wishes more Elixir developers understood about BEAM performance before they opened a PR claiming something was faster

Recorded August 21, 2026.

Resources mentioned:

  • Benchee on Hex: hex.pm/packages/benchee

  • Benchee HTML formatter -self-contained HTML output with downloadable graphs

  • Benchee markdown formatter

  • PragTob on GitHub: github.com/bencheeorg

Todos los episodios de BEAM There, Done That

Ajustes

Visualización

Idioma

Determina qué emisoras ves primero en la página de inicio.

Historial

Las emisoras y episodios escuchados recientemente y tus últimas búsquedas solo se guardan en este navegador.

Avisos

Un breve aviso cuando un pódcast que sigues tiene un episodio nuevo. Puedes desactivar pódcast concretos con la campana de su página.

Cuenta

Guarda tus favoritos: en la app y en la web.

Atajos de teclado

/
Abrir búsqueda
Espacio
Reproducir o pausar
← →
En el reproductor: 15 s atrás, 30 s adelante (episodios) · en una fila: siguiente tarjeta
↑ ↓
En una fila: destino dentro de la tarjeta
Inicio / Fin
En una fila: primera o última tarjeta
Esc
Cerrar ventana o menú
?
Este resumen
Reproduciendo ahora

Ir a la emisora

A continuación

    Añade episodios con «A continuación»: sonarán después del episodio actual.