"Clean" Code, Horrible Performance

Programmers are fighting over whether pretty code secretly makes apps slower

TLDR: A programming video argues that popular “clean code” habits can make software slower, challenging advice many beginners are taught. In the comments, that sparked a mini civil war: some called the style actively harmful, while others said it only becomes a problem when people treat it like religion.

A programming video about so-called “clean code” has turned into catnip for internet drama. The basic claim is spicy enough on its own: some popular coding rules meant to make programs look neat and organized can also make them run worse in the real world. The example is simple even for non-coders: instead of one direct path, the “clean” version splits behavior into lots of tiny pieces and layers of abstraction. The author argues that this elegance can come with a speed bill.

But the real fireworks are in the comments, where people are treating this less like a lesson and more like a culture war. One camp is basically yelling, “We’ve been saying this for years!” with commenters flatly declaring that Clean Code teaches “many bad-practices.” Another group is more measured but still shady, saying the style is useful for beginners—right up until someone becomes a “Clean Code zealot” who nitpicks every pull request like it’s a moral failure. Ouch.

And then there’s the blockbuster backstory: commenters immediately pulled receipts, linking a giant Hacker News discussion with hundreds of comments, plus a direct public debate between the video’s creator and Uncle Bob, the author most associated with Clean Code. That turned this from “helpful coding advice” into full-on programming fandom beef. Even the calmer replies had sequel energy, pointing people to a follow-up video as if this were the next episode in a prestige drama: Simple Code, High Performance. In other words, the code may be clean, but the comment section is gloriously messy

Key Points

  • The article is a bonus video and transcript from the Performance-Aware Programming series focused on measuring the runtime costs of “clean code” rules.
  • It distinguishes between clean-code rules that are arbitrary stylistic guidance and rules that affect runtime behavior and can therefore be objectively measured.
  • The article highlights five structural rules for examination: preferring polymorphism, hiding object internals, keeping functions small, making functions do one thing, and following DRY.
  • To avoid constructing a biased example, the article states that it uses code examples taken from existing clean-code literature.
  • The provided example uses a shape class hierarchy with virtual `Area()` methods and a `TotalAreaVTBL` loop that sums areas through virtual dispatch.

Hottest takes

"Clean Code is teaching many bad-practices" — flossly
"harmful to late-stage developers who adopt it as dogma" — Aurornis
"one Clean Code zealot who carries an air of superiority" — Aurornis
Made with <3 by @siedrix and @shesho from CDMX. Powered by Forge&Hive.