...
Rule 7: Reduce noise in your measurements. Run your benchmark on a quiet machine, and run it several times, discarding outliers. Use -Xbatch
to serialize the compiler with the application, and consider setting -XX:CICompilerCount=1
to prevent the compiler from running in parallel with itself.
Relevant links
- http://www.ibm.com/developerworks/java/library/j-jtp02225/index.html
(Brian Goetz article)
- http://www.azulsystems.com/events/javaone_2002/microbenchmarks.pdf
(Cliff Click JavaOne talk)
- http://code.google.com/p/caliper/wiki/JavaMicrobenchmarks (Google micro-benchmark tool)
- http://stackoverflow.com/questions/504103/how-do-i-write-a-correct-micro-benchmark-in-java
(crowd-sourced goodness)
Overview
Content Tools
ThemeBuilder