Appendix B. Optimizing and Finding Memory Leaks

IN THIS APPENDIX

This appendix describes techniques for optimizing Cocoa applications and finding memory leaks. A Cocoa application called LotsOfWords is developed and revised several times within the appendix to demonstrate various optimizations. LotsOfWords displays strings with random positions, font sizes, and colors. The application is small but realistic. It could form the basis of a screen saver, but more importantly, the optimizations that apply to LotsOfWords also apply to larger applications. Finally, techniques for finding memory leaks are provided.

Get Cocoa® Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.