Three occasions when you might use your own autorelease pools Anonymous User187207-Sep-2015iphoneiphone ios objective c Updated on 19-Sep-2020
Anonymous User
07-Sep-2015If you are writing a program that is not based on a UI framework, such as a command-line tool.
If you write a loop that creates many temporary objects.You may create an autorelease pool inside the loop to dispose of those objects
before the next iteration. Using an autorelease pool in the loop helps to reduce the maximum memory footprint of the application.
If you spawn a secondary thread.