开发者

Making the most of available memory on higher end devices?

开发者 https://www.devze.com 2023-02-06 04:25 出处:网络
I\'ve noticed that e.g. the Samsung Galaxy S allows apps to allocate much more memory (>24Mb) than a Droid (<=24Mb) or a G1 (<=16Mb) before OutOfMemoryExceptions are thrown. I\'d like my app to

I've noticed that e.g. the Samsung Galaxy S allows apps to allocate much more memory (>24Mb) than a Droid (<=24Mb) or a G1 (<=16Mb) before OutOfMemoryExceptions are thrown. I'd like my app to scale to higher e开发者_运维知识库nd devices like the Galaxy and take advantage of the higher allocation limit.

Is there a reliable way to detect how much memory my app can use? Is it risky to attempt to use e.g. 70% of the maximum memory reported? Otherwise, I'd need to limit my app to what the G1 allows to guarantee my app won't crash.

0

精彩评论

暂无评论...
验证码 换一张
取 消