4 ms·
These explicit checks are basically what I mean by "convincing the compiler" (and sometimes, it isn't quite convinced!) - Yeah. Not fun at all. Especially in J
by iscoelho 3y ago
These explicit checks are basically what I mean by "convincing the compiler" (and sometimes, it isn't quite convinced!) - Yeah. Not fun at all.
Especially in Java, because "the assembly" can change as the JIT evolves. What is optimized today may not be tomorrow.
- xxs 3y agoSome 12-13y back (time does fly) Cliff Click (hotspot architect) had a series of blogs on optimizations, incl. the lattice checks (i.e. within bounds). Was quite insightful. It was called: "Too Much Theory" [0] >What is optimized today may not be tomorrow. Exactly. (Also most developers will have exceptionally hard time maintaining such code) [0]: https://web.archive.org/web/20120328222841/http://cliffc.org/blog/2012/02/12/too-much-theory/ https://web.archive.org/web/20120328222841/http://cliffc.org...