0

We use instruments automation tool to test our ios app. (We use xcode 6.4.) The tests include taking many screenshots which are checked then by imagemagick. The problem I see is that memory usage of instruments application itself grows with time. It performs slower and slower and finally almost hangs. Activity Monitor shows 10 GB usage for instruments process. While physical memory is 8 GB.

I also noticed that when I uncheck option "Continuously Log Results", memory does not grow. But I need this option, since I want access to screenshot files. I don't understand why writing screenshots to disk consumes all memory.

I made a simple test to reproduce the problem:

var target = UIATarget.localTarget();

for (var i=0; i<100; i++)
    target.captureScreenWithName("scr" + i);

UIALogger.logMessage("done");

If "Continuously Log Results" is checked, then each run adds hundreds of megabytes to instruments process memory usage (I think it depends on screen resolution of device). This memory is not released even if I close window with current run. Only if I quit instruments process completely, the memory is released.

Any thoughts what could be wrong will be appreciated. Seems like a memory leak in instruments to me.

jesse
  • 650
  • 5
  • 19
  • Maybe try installing Xcode 7 beta and test this with Instruments 7.0 (you can still build with Xcode 6.4 of course) ? – Paul R Aug 20 '15 at 08:55
  • I tried instruments from xcode 7 beta 5 and see the same behaviour. ( – jesse Aug 20 '15 at 09:17
  • Oh well - worth a try - time to [file a bug report](http://bugreport.apple.com) and maybe buy some more memory then... – Paul R Aug 20 '15 at 09:19

0 Answers0