On Wed, Dec 29, 2010 at 12:40 AM, cool.manish <mannishga...@gmail.com>wrote:

>  1. I am refering to the Cache memory which is return by getCacheDir
> function. Is there any limit that per application only this much Cache
> memory could be used?
>

It is just a directory in your app's private data dir, which is on the same
partition as all of your other data, and the data of other apps.


>  2. If Cache memory is same as normal internal data storage space then
> is it dependent upon the mobile's phone memory? Is there any % amount
> of total internal memory which could be used as Cache memory.
>

Keep it reasonable.


>  3. Heap Memory: I had tried functions like Debug.getMemoryInfo which
> returns Debug.memoryInfo object and also
> ActivityManager.getProcessMemoryInfo function which returns
> ActivityManager.MemoryInfo object. Now there are different functions
> in MemoryInfo like getTotalPrivateDirty or getTotalPss(). I am unable
> to understand use of these functions. What is the meaning of Total
> Private Dirty memory or total PSS memory? Which one of them returns
> Heap memory? Is there any limit per application to use heap memory?
> Can we configure size of the heap memory?
>

Like I said, the function I previously mentioned will tell you about the
Java heap limit.

"Memory used by an app" is complicated.  You shouldn't be using
ActivityManager.getProcessMemoryInfo() for regular program logic.  However,
if you want to start to understand what these numbers mean, you can read a
post I made about it here:
http://stackoverflow.com/questions/2298208/how-to-discover-memory-usage-of-my-application-in-android/2299813#2299813

-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to