Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

The settings menu in CM6 lets you change the maximum per-process heap size (internally, that’s the dalvik.vm.heapsize property). What are the practical effects of raising or lowering that setting? On my G1, I changed it to 12m from the default of 16m, and I noticed that switching applications feels faster, but I wonder if it will cause some applications to run out of memory sooner.

share|improve this question
add comment

3 Answers

up vote 8 down vote accepted

Here's a great article someone wrote on the effect of changing it, very detailed: http://ryanolson.wordpress.com/2010/07/13/test-how-changing-the-max-amount-of-memory-per-vm-heap-can-effect-your-rom-cyanogen/

In short, with the G1, it can cause bigger applications to crash. I would just recommend you keep it default or find a value that you do not see any crashes in applications with.

As far as anything else goes, in the short period of time searching else where and reading over different posts. Could not personally find any other effects, other than possibly battery life.

share|improve this answer
    
That sounds good. I think I’ll keep it since nothing is crashing (although the greediest thing I tried was Maps), and the launcher seems to be staying in memory much more often. –  Josh Lee Oct 13 '10 at 4:39
add comment

If you have a phone with low memory (like the G1) and spend your day switching between a couple little applications, then lowering this number will speed up your system and allow more programs to stay loaded up, making switching faster.

If you have heavy weight applications (such as the FB app!) that can't get their jobs done inside the limit you set, they will crash and die for no apparent reason until you increase the number enough that they can survive. I usually find this preferable. Switching apps on my phone is slower, but the big jobs don't randomly crash.

share|improve this answer
add comment

In addition to the above answers, note that different devices have different defaults. For example, on the Motorola Xoom the default is 256MB. As a developer, it may be worth testing apps with lower than default settings to make sure they will work on as wide a range of devices as possible...

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.