3 ms·
How can one properly benchmark these optimizations? Obviously, an import aspect is time (the faster the better). Another one is peak heap usage. Maybe allocati
by kohlschuetter 4y ago
How can one properly benchmark these optimizations?
Obviously, an import aspect is time (the faster the better). Another one is peak heap usage. Maybe allocation fragmentation and garbage collection times may be relevant for some scenarios.
I've recently had an urge to build a library that reduces the amount of string concatenations for scenarios where the final string is anyways written to a character stream (Writer), etc: https://github.com/kohlschutter/stringhold https://github.com/kohlschutter/stringhold
I have started to benchmark it, and while I seem to get promising results, I want to make sure that it actually does better than what Java provides these days. Any ideas?