Follow us on...
Follow us on Twitter Follow us on Facebook
Register
Results 1 to 5 of 5
  1. #1
    Austin is offline Registered User
    Join Date
    Sep 2000
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If anybody could tell me how to figure out how much (as a percentage) of my total RAM I'm using at any one time, as opposed to how much RAM each cryptically-named process in Process Viewer was using, I'd much appreciate it.

  2. #2
    ericmurphy is offline Registered User
    Join Date
    Sep 2000
    Location
    San Francisco
    Posts
    230
    Thanks
    1
    Thanked 0 Times in 0 Posts

    RAM used

    Well, just out of curiosity the other day, I added up all the percentages of memory used by the processes showing in Process viewer. The total came to about 126% :-)

    But you have to remember that Mach is running the memory show here. Every process under Mach is allocated 4 GigaBytes (yes, GigaBytes) of memory address space. If you have 20 processes running, that's 80 GB of memory! So how much total memory in use isn't really that important; Mach will page stuff out to disk to make room for stuff that needs to be running in RAM.

    But if you really want to know how much physical RAM is in use, open a terminal window and type in 'Top' at the command prompt. This will run the Unix program Top, which will show statistics on the top processes. There's a bunch of memory-related stuff there, including page-ins, page-outs, wired memory (memory that can't be paged to disk), etc. I think the last line will give you the total RAM in use. On my machine, which has 256 Meg installed, I'm usually using about 253 Meg or so of that if I have a dozen applications open. I really haven't noticed much performance difference regardless of how many processes are running, even when Bryce is rendering Animations in the background in Classic, or the Classic version of Setiathome is processing work units in the background.

    Apple wasn't kidding when they said "out of memory" messages are out of here. :-)

  3. #3
    fmalloy is offline Registered User
    Join Date
    Sep 2000
    Posts
    40
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Exclamation

    Eric,

    You have to be careful when you say that "every process is allocated 4GB of memory". In a way, that's not really true.
    Every process can use a maximum of 4GB of memory, but that isn't *allocated* per se. Memory is allocated dynamically by the OS at the request of the process. We want to make sure that folks don't think that 4GB is immediately sucked up by RAM and VM whenever you launch an app!

    When you launch your app, only required chunks of the code are paged into the RAM. The app along the way requests more memory to go about its work, and the OS grants the memory, and the RAM the app uses grows dynamically. A well-written app can also release that memory back into the system when its through with it, which the OS is free to allocate to some other process.

    When all RAM gets allocated (or a large part of it), the OS starts paging less recently used parts of that app or other apps to disk, to make room. You'll notice that if you have a lot of apps open, then go back to an application that is running, but you haven't used it in a while, you hear the disk moving as its getting paged from disk, and then some other app gets some paged from RAM to disk.

    You are correct that "out of memory messages are outa here". The only thing you'll notice as your RAM fills up is increased time to launch apps and to switch apps.

  4. #4
    ericmurphy is offline Registered User
    Join Date
    Sep 2000
    Location
    San Francisco
    Posts
    230
    Thanks
    1
    Thanked 0 Times in 0 Posts

    RAM

    Yes, you're right on the address space. This doesn't mean each app gets 4 Gig of continuous address space! If it did, you'd soon run out of disk space, let alone RAM. :-)

    But I have to say, even with 20 or 25 applications running (including things like Photoshop running in Classic), I rarely notice any lag in launching or switching apps (which might have something to do with an UltraSCSI disk slurping data off the drive at almost 30 Meg/sec). In fact, last night I had about 15 apps up, and launched another 7 more or less simultaneously while I worked on a foreground task, with almost no loss of responsiveness.

  5. #5
    fmalloy is offline Registered User
    Join Date
    Sep 2000
    Posts
    40
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Wow, lucky you, Eric!

    When my apps start swapping out, for example, I leave Mail running for a long time, when it gets swapped back in the disk on my beige G3 really starts chugging for quite a while.

    But, I have the stock disk with only 128MB RAM on a beige G3...

 

 

Similar Threads

  1. The importance of removing "bad" RAM from your Mac
    By bobw in forum Hardware & Peripherals
    Replies: 5
    Last Post: August 2nd, 2003, 08:01 PM
  2. Where is my RAM going?
    By josh3dmaker in forum Mac OS X System & Mac Software
    Replies: 6
    Last Post: July 26th, 2002, 12:31 PM
  3. RAM Disk for OS X? Yes indeedy.
    By simX in forum Apple News, Rumors & Discussion
    Replies: 0
    Last Post: May 1st, 2002, 11:01 AM
  4. B&W install blues (RAM Weirdness)
    By Cheviot in forum Mac OS X System & Mac Software
    Replies: 0
    Last Post: September 28th, 2000, 03:45 PM
  5. B&W install blues (RAM Weirdness)
    By Cheviot in forum Mac OS X System & Mac Software
    Replies: 0
    Last Post: September 28th, 2000, 03:35 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •