Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
stevoski
· 9y ago · 0 comments
It's amazing how performance can be much improved by profiling and fixing little things, such as optimizing a Java hashCode() method.
I had a similar experience helping with the H2 database engine.
Comments
[–]
johnou
9y ago
I didn't benchmark the difference between cache usage with precalculating the hash code in a constructor vs calculation in the hash code itself but string concatenation then taking the hash code of that was the real performance killer.