Tell HN: Optimization is only premature when the expected profit is negative
Many optimizations are dismissed as irrelevant and &quot;premature&quot;. But, for enterprises with finite cash to throw at hardware, fewer optimizations are premature than is often assumed.<p>Use less memory, use less CPU, and you can get more instances running on a single machine.<p>RiiR, switch to a unikernel, etc. same thing.<p>But only real optimization counts---real reductions in resource usage. Not things you believe _should_ make things faster or lighter; only things that _do_.<p>But if the optimization costs you more in developer time than will be reclaimed in operations costs over the _entire lifetime of the code_... then it is premature.<p>Estimating this, though, is a challenge.<p>Just stating the obvious, I suppose.