Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to set the amount of memory available in the iPhone Simulator?

Does anyone know if its possible to set the amount of memory available in the simulator?

I'm assuming the simulator will use as much memory as possible from the system but this makes it more difficult to recreate certain low memory crashes/bugs.

like image 282
Rob Segal Avatar asked Mar 30 '10 14:03

Rob Segal


2 Answers

No it isn't possible.

Testing things like memory consumption and performance should be done on the device, not the simulator. Even if you could limit the memory in the simulator you wouldn't get the same effect as there are very many different factors that will dictate how much available memory any given iPhone device will currently have.

You can simulate a "memory warning" to test if your responses to that warning behave correctly, but other than that, you should really be testing this kind of thing on a physical device.

like image 96
Jasarien Avatar answered Sep 21 '22 10:09

Jasarien


You can invoke the "Simulate Memory Warning" in Simulator. Go to the "Hardware" pulldown menu. That's really about as far as you can go.

like image 42
Zack Avatar answered Sep 21 '22 10:09

Zack