Re: a way to clear inactive RAM
Re: a way to clear inactive RAM
- Subject: Re: a way to clear inactive RAM
- From: Nick Rogers <email@hidden>
- Date: Tue, 06 Nov 2012 16:31:30 +0530
Hi,
Thanks for the replies.
I was trying to achieve what essentially "free memory" apps on the Mac AppStore do.
The RAM usage can be divided into four parts as shown in Activity Monitor.
1. Free
2. In-active
3. Active
4. Wired
When I used my earlier app to allocate memory equal to free + inactive bytes, for the execution of the program it used to make the system less responsive for a few seconds and on release and quitting the app, most of the inactive memory would shift under free.
e.g. if free is 1GB and inactive is 1.5GB, then after run, free would be 2.45GB and inactive just 50MB.
Thanks again,
Nick
On 06-Nov-2012, at 2:29 AM, Alex Zavatone <email@hidden> wrote:
> Not sure what RAM "clearing" means but if you want to purge the disk cache, check out man purge in the terminal.
>
> On Nov 5, 2012, at 1:54 PM, Nick Rogers wrote:
>
>> Hi,
>>
>> I am assigned this small utility which should clear inactive RAM.
>> I know Mac OS X manages memory quite efficiently and inactive RAM also has a purpose.
>> But I have to make this.
>>
>> Prior to Mountain Lion I was allocating memory in my app that was roughly equivalent to free + inactive RAM.
>> And it used to work perfectly, i.e. most inactive RAM used to become free.
>>
>> But in Mountain Lion, aggressive allocations are not affecting RAM at all.
>>
>> I want this util to also work on systems that don't have Xcode installed.
>>
>> I saw the post where someone posted notes of purge disassembly. But that isn't leading anywhere. Also purge comes with Xcode only.
>>
>> There are apps on Mac App Store that do this kind of thing.
>>
>> How to go about it? Any pointers would be really appreciated.
>>
>> Wishes,
>> Nick
>>
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> Please do not post admin requests or moderator comments to the list.
>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>>
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden