I’m developing a graphics-intensive application for Android 2.2 and above.
I know that starting with Honeycomb, bitmaps are stored on VM_HEAP instead of their native bitmap heap.
Does this influence the effective memory usage of my application? I mean, e.g., if my app for pre-Honeycomb devices uses X MB of the VM heap, and has Y MB bitmaps (stored on native heap), then I hope it won’t start using X+Y MB from the VM heap if it’s installed on a Honeycomb or newer device.
This does not sound logical. Instead, I guess that bitmap size is counted against the VM limits even prior to Honeycomb, otherwise why would “bitmap size exceeds VM budget” errors appear? So they’re stored on their native heap but still counted against VM_HEAP size maximum).
I was also worried, but I got an answer from Google in the meantime, which confirmed my following assumption:
“This does not sound logical. Instead, I guess that bitmap size is counted against the VM limits even prior to Honeycomb, otherwise why would “bitmap size exceeds VM budget” errors appear? So they’re stored on their native heap but still counted against VM_HEAP size maximum).”
Answer from Romain Guy (Android Framework engineer):
“That’s correct. Your app will use the same amount of memory pre and post Honeycomb. “