Program/utility Freeing up RAM

Posted:
in macOS edited January 2014
I'm pushing my iMac to the limit. I've maxed out the RAM (3 gig) and am using Logic Pro. Things are mostly fine, but every now and then I have to reboot to free up the RAM. It occured to me that perhaps there are good programs or utilities that could free up RAM without having to reboot. Anyone familiar with any such thing/could recommend one? thanks!

Comments

  • Reply 1 of 14
    1337_5l4xx0r1337_5l4xx0r Posts: 1,558member
    open the Terminal.app and type purge
  • Reply 2 of 14
    I'm terrible with any kind of programming stuff, no matter how simple. Someone must make a utility for this, no?



    Quote:
    Originally Posted by 1337_5L4Xx0R View Post


    open the Terminal.app and type purge



  • Reply 3 of 14
    hirohiro Posts: 2,663member
    Quote:
    Originally Posted by 1337_5L4Xx0R View Post


    open the Terminal.app and type purge



    That has absolutely nothing to do with his question. The answer borders on negligence.



    The answer is to close programs. The OS will manage RAM in the most efficient manner from there. Even if you have a program that ends up leaking a lot of memory this should be enough.



    The only thing you could reclaim by rebooting is RAM allocations leaked by the OS. While there is some of that in places, it's minuscule compared to 3GB of usable RAM. So rebooting is just wasting more of your time than necessary.



    For reference, in Activity Monitor and Top free+inactive memory is what is available for a programs use, not just free. Inactive memory has been released, but until it is reassigned it remains on the inactive list in case you re-launch the program that used it previously.
  • Reply 4 of 14
    Whether it's possible or not, I can assure you that rebooting the mac gains me far more usable RAM than closing, logic, closing all applications, and then opening Logic again. Honest!



    Quote:
    Originally Posted by Hiro View Post


    That has absolutely nothing to do with his question. The answer borders on negligence.



    The answer is to close programs. The OS will manage RAM in the most efficient manner from there. Even if you have a program that ends up leaking a lot of memory this should be enough.



    The only thing you could reclaim by rebooting is RAM allocations leaked by the OS. While there is some of that in places, it's minuscule compared to 3GB of usable RAM. So rebooting is just wasting more of your time than necessary.



    For reference, in Activity Monitor and Top free+inactive memory is what is available for a programs use, not just free. Inactive memory has been released, but until it is reassigned it remains on the inactive list in case you re-launch the program that used it previously.



  • Reply 5 of 14
    http://www.activata.co.uk/ifreemem/



    It does cost money, however.



    iFreeMem free's memory from the in-memory cache that accumulates with every file or application read from hard-disk.



    The cache is good, but it can become cluttered with files you don't even need cached anymore that take up precious RAM.



    Maximum free memory can sometimes be better than half your memory filled with old cached files.
  • Reply 6 of 14
    Thanks! Someone on another site recommended that as well. Hopefully just what I was looking for! Will try it straight away.





    Quote:
    Originally Posted by dataquent View Post


    http://www.activata.co.uk/ifreemem/



    It does cost money, however.



    iFreeMem free's memory from the in-memory cache that accumulates with every file or application read from hard-disk.



    The cache is good, but it can become cluttered with files you don't even need cached anymore that take up precious RAM.



    Maximum free memory can sometimes be better than half your memory filled with old cached files.



  • Reply 7 of 14
    talksense101talksense101 Posts: 1,738member
    Ever consider buying more RAM?
  • Reply 8 of 14
    my imac is maxed out.



    Quote:
    Originally Posted by talksense101 View Post


    Ever consider buying more RAM?



  • Reply 9 of 14
    1337_5l4xx0r1337_5l4xx0r Posts: 1,558member
    Quote:

    That has absolutely nothing to do with his question. The answer borders on negligence.



    Not only does it have everything to do with his question, he just bought an app that does exactly the same thing as the free utility in OSX I mentioned. Am I missing something?
  • Reply 10 of 14
    hirohiro Posts: 2,663member
    Quote:
    Originally Posted by 1337_5L4Xx0R View Post


    Not only does it have everything to do with his question, he just bought an app that does exactly the same thing as the free utility in OSX I mentioned. Am I missing something?



    Yes, you are missing something. Purge empties the disk cache, it doesn't do RAM. From the man entry.



    Quote:

    Purge can be used to approximate initial boot conditions with a cold disk

    buffer cache for performance analysis. It does not affect anonymous mem-

    ory that has been allocated through malloc, vm_allocate, etc.




    Researchers use it for file system testing. It doesn't free up any more RAM at all, see that little bolded section?



    It might make somebody feel good because as a side effect it resets the inactive list into the free list. But as I posted previously inactive already is free, so it does nothing useful except make it take longer to load new programs.



    Those old cached files are just in the inactive list. The memory map is merely keeping a cross reference to the page where it sits in RAM. Since the page table is a fixed size, dumping the mapping to bump up the free mem list actually does nothing except replace a valid pointer with a null pointer and set the used bit to zero. The memory map will always be there the same size no matter what, so there isn't anything real to gain. It's pure placebo effect.
  • Reply 11 of 14
    I got iFreemem, and so far so good. Thanks! I've been playing it safe and quitting Logic before running iFreemem. Do you know if it's safe to run it while Logic is up and running?





    Quote:
    Originally Posted by dataquent View Post


    http://www.activata.co.uk/ifreemem/



    It does cost money, however.



    iFreeMem free's memory from the in-memory cache that accumulates with every file or application read from hard-disk.



    The cache is good, but it can become cluttered with files you don't even need cached anymore that take up precious RAM.



    Maximum free memory can sometimes be better than half your memory filled with old cached files.



  • Reply 12 of 14
    hirohiro Posts: 2,663member
    Quote:
    Originally Posted by Soundhound View Post


    I got iFreemem, and so far so good. Thanks! I've been playing it safe and quitting Logic before running iFreemem. Do you know if it's safe to run it while Logic is up and running?



    Yes, it's safe, but it may make Logic run slower if a file logic has mapped, but currently isn't accessing, but may access again, becomes unmapped because purge gets run.



    I can't stress strongly enough that this is all placebo.
  • Reply 13 of 14
    soundhoundsoundhound Posts: 134member
    Hiro, what do you mean, this is all placebo? It's not really doing anything??





    Quote:
    Originally Posted by Hiro View Post


    Yes, it's safe, but it may make Logic run slower if a file logic has mapped, but currently isn't accessing, but may access again, becomes unmapped because purge gets run.



    I can't stress strongly enough that this is all placebo.



  • Reply 14 of 14
    hirohiro Posts: 2,663member
    Quote:
    Originally Posted by Soundhound View Post


    Hiro, what do you mean, this is all placebo? It's not really doing anything??



    Yup. Nothing of any performance enhancing significance.



    The inactive memory simply gets dumped into the free list. An operation that takes all of a couple microseconds. And it doesn't even change the human-timescale actual availability of the memory, because the inactive-to-free memory relabeling only took a couple microseconds to do. The same amount of time it would take to do if you needed the memory on the fly. Try to notice anything on a scale less than 50 milliseconds (10,000x longer than that list relabeling took), you really can't unless you are noticing the difference as a mis-synchronization like audio and lip movements being out of synch. Memory accesses don't fit that, quite obviously there aren't two things to compare time-wise.



    Then the actual drive cache tables are destroyed, something that takes a handful of milliseconds. You can usually hear the drive as some of the cached blocks are forced to be written. That second operation is actually a performance de-enhancer, because now the caching that could help avoid HD access latency is gone.





    Allocated memory including anything that was leaked isn't touched at all. Nothing more is reclaimed than was already available in the first place, just in two lists, not one.
Sign In or Register to comment.