
Clean Code, Horrible Performance

Why performant code matters (but gets widely ignored), with Casey Muratori
Topic 12 of 18
Published Aug 26, 2026 · Clip 1:16:58–1:21:44 (4:46)
Casey discusses the reception and substance of his video showing Uncle Bob-style polymorphism refactoring running 1.5–15x slower than a table-switch version. He argues the specific Clean Code rules (tiny functions, always polymorphism, don't know type at runtime) block compilers from inlining, collapsing redundant code, and vectorizing. The real cost isn't virtual calls per se but the compiler's inability to optimize when runtime types are unknowable. Small statically-known functions are fine because the compiler can reassemble them.