Pages

Tuesday, March 08, 2011

Java Performance...

Java virtual machines are weird things. They can optimize code on the fly, tuning how it runs the code, depending on the data it processes. That is why it can be faster than C and C++, or even faster then Fortran. Those are all pre-optimized based on the code, not based on the workload. But, at the same time, performance is tricky, and your best friend is a good profiler (like YourKit, which is free for Open Source use).

Reading about Java performance now and then is useful. It's keep you aware of the things that matter and that don't. Via Planet Eclipse, I read a couple of posts from the Java Persistence Performance blog. And today I learned that the JIT compiler can in fact remove the threading support in Hashtable when only one thread is used.