Hacker News new | ask | show | jobs
by dist1ll 1284 days ago
Premature optimization should be avoided. It's in the name. But that wasn't really my point.

The problem is that PO is used as a catch-all, low-effort statement to dismiss performance questions and exploration. It's used by devs to antagonize curiosity.

2 comments

>Premature optimization should be avoided. It's in the name.

Right, the word premature is what makes it a bad thing. What's missing is a complementary concept, let's call it early optimisation. Sometimes you can optimise a thing early on without loss of generality, increase of code complexity (sometimes, with a judicious comment at least, optimised code might even be simpler) or incurring technical debt. The problem is, as there is no awareness of this difference, early optimisation is often misconstrued as premature, even when it really isn't.

I mostly do hobby projects like procedural generation, and I explore stuff I don't understand. As I gain knowledge I refactor and change the code to reflect the new understanding. This new understanding of the problem domain will most often result in performance gain, because the code is much more focused.