4 ms·
I think it’s making a case that normally you shouldn’t even bother benchmarking it, unless you know that it’s in a critical hot path.
by layer8 8mo ago
I think it’s making a case that normally you shouldn’t even bother benchmarking it, unless you know that it’s in a critical hot path.
- eptcyka 8mo agoI must add that code is on the hot path only under two conditions: - the application is profiled well enough to prove that some piece of code is on the hot path - the developers are not doing a great job
- dblohm7 8mo agoAgreed. Nitpicking about indirection is definitely a "premature micro-optimization is the root of all evil" moment. When I worked on Firefox, we eventually had to remove a bunch of indirection (the interested can actually search bugzilla.mozilla.org for deCOMtamination for some instances of this), but that project wasn't a thing until there was clear evidence that there were problems with virtual function calls on hot paths.