4 ms·
Sorry, I must be missing something as I can't see what you're saying that's different to don't optimize prematurely.
by scrapheap 4y ago
Sorry, I must be missing something as I can't see what you're saying that's different to don't optimize prematurely.
- yen223 4y ago"Don't optimise prematurely" is not great advice, because it's tautological. "Premature" optimisation is obviously bad, otherwise it wouldn't be "premature"! The hard part is knowing when an optimisation is "premature", and that statement on its own doesn't give you anything to work with. OP's advice is a little bit better, since at least it gives you a starting point for evaluating whether a certain optimisation is worth doing, i.e. looking at it through the cost vs the benefit.
- scrapheap 4y agoI just felt that they were trying to say more than the obvious and I had missed what they were getting at. Personally I don't encounter usually encounter "Don't optimize prematurely" being used as a stand alone statement. When it's being given as advice then it's backed up with examples of when an optimization is premature and when it's a good time to optimize. The few times I do encounter it variations of it being used a statement is in code reviews, but then you've got the context of the code being commented on to help understand what the reviewer is getting at.
- deleted 4y ago[deleted]