Appendix B. Profiling Tips and Tricks Example Source Code

This appendix contains the source code used in the examples for reducing lock contention, resizing Java collections, and increasing parallelism presented in Chapter 6, “Java Application Profiling Tips and Tricks.”

The examples found in this appendix illustrate scalability issues. Since desktop systems are rarely configured with a large number of virtual processors, scalability issues may not be observed when attempting to run them on desktop systems. In addition, these example programs require at least two gigabyte of Java heap to execute reasonably well without experiencing a lot of garbage collections. Hence, to observe scalability issues with these examples, they should be run on a ...

Get Java™ Performance now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.