Minor improvement of memory using autoreleasepool