2 ms·
There are several assumptions that are far from a given with premature optimization. 1. Adding the optimization didn’t make the code more complicated. 2. Addi
by tjalfi 6y ago
There are several assumptions that are far from a given with premature optimization.
1. Adding the optimization didn’t make the code more complicated.
2. Adding the optimization didn’t introduce a bug.
3. This part of the code will be a bottleneck in the future. The time spent optimizing is a write-off if the project is canceled or that portion is replaced.
- peteradio 6y agoAll, true, but if you have a time budget and you know this thing will prevent you from meeting it AND making this change now will inform the architecture then its the right optimization to make.