Memory, Paging and Swap Space on the Intel Architecture

Discussion in 'Mac Basics and Help' started by Koinu, Nov 13, 2006.

  1. Koinu macrumors newbie

    Nov 13, 2006
    (Longtime lurker, first time poster...)

    Here's a topic I haven't seen discussed... (Google doesn't find anything interesting...)

    My trusty old PowerBook G4 (TiBook - 1GHz, now four years old and still going strong) does very well with only 512 MB of RAM. Also, with Word, Excel, PowerPoint, Safari, iChat, FireFox, Fire (IM Client), MS Remote Desktop and Stickies running, it is up around 6.9 GB of Swap Space in use, and shows about 450K page in events against 65K page outs. Obviously I have pushed the machine to where it is out of physical memory and is having to page to disk to accommodate all that I am asking of it... BUT -- even so, we're still talking only 6.9 GB of swap space.

    On a fresh boot, that's more like 4 GB of swap, and perhaps 200 MB of free RAM.

    In contrast, I spent some time at an Apple Store this weekend playing with the 2.33 GHz C2D MacBook Pro, the iMacs and mac pro, and I have tinkered with my wife's MacBook as well. On a fresh boot, it is rare for these machines (with 1 or more GB of RAM installed) to show more than 100 MB free (so they are consuming almost a full GB of RAM with nothing much running), and 9+ GB of swap space. On the MBP, by running a handful of applications (similar to my list above), this ballooned to 15 GB of swap space. On a 1 GB machine, the page outs were equal to or higher than the page ins pretty soon after booting. With 2 GB of RAM, it took a little more time (and applications running) to start seeing the page outs.

    My question is: Is the Intel architecture inherently more "bloated" from a memory usage perspective? It seems bizarre that both the amount of used RAM and the required swap space for a very small application set needs to be DOUBLE OR MORE than that required on the PPC architecture. This also suggests that these things simply need at least twice as much RAM (more, really) than the PPC forebears. I can actually use my 512 MB TiBook for quite a while for several applications after booting (as long as I quit them when I'm done) without seeing any page out activity. I can't even boot a 1 GB MacBook Pro without seeing page out activity before it finishes loading the Finder...

    Any architects out there have any thoughts on this? I would think this points to a potential bottleneck in the system -- particularly if 15+ GB of swap space needs to be kept available... Not a big deal as hard disks keep increasing in size, but I don't think I could even use a 1 GB machine productively from the quick look I took at it...


  2. Sun Baked macrumors G5

    Sun Baked

    May 19, 2002
    One of the perils of going beyond a 32-bit memory space, is that the OS will allow more virtual memory, and the apps will eventually use more memory.

    Of course, you will likely still get a big swap space on the Mac Pro with the max 32GB of memory.

    Only problem on the current C2D is the chipset limits you to 3GB of memory, while you get decent performance today -- as the memory needs grow, you will start to hitting the drive more and more slowing you down.

    And if you are using Rosetta, you will see pageouts. Also, if you load 100 apps, you will see pageouts -- which isn't bad if you only get them during application switching, unless you switch apps like a monkey on meth with the remote.
  3. bousozoku Moderator emeritus

    Jun 25, 2002
    Gone but not forgotten.
    Since we've had a few of these threads already, I'd say that your experience is the norm. Page outs are greater than page ins at any time. It's not that the Intel architecture is inefficient. It's that Mac OS X on Intel is still inefficient. It's been a little over a year for Intel vs. 5+ years for PowerPC, so the virtual memory isn't likely to be tuned properly. Apple are constantly adjusting virtual memory on PowerPC, including some rather painful results as late as 10.3.6.

    You'll have to give them some time. It might be interesting to see what happens if Rosetta is disabled since it seems to be a huge drain.
  4. bearbo macrumors 68000


    Jul 20, 2006
    can someone explain to me what is the difference between page in and page out... and for some reason, on my computer, page out is much less, about 1/10 to 1/5 of page in...
  5. SmurfBoxMasta macrumors 65816


    Nov 24, 2005
    I'm only really here at night.
    page ins is your system sending files to the RAM, for fast/frequent/efficient retrieval.......nothing to worry about as this is perfectly normal.

    page outs are when your OS & app's memory requirements have exceeded the physical ram, and must be "swapped" out to the "Virtual" memory file.....which is created by using space on a hard disk drive. This is a problem because HDD's are several magnitudes slower than ram, thus creating a bottleneck and slowing down your entire machine as the swap operation takes addition to increased wear & tear on your HDD.

    So having a few pageouts here & there isnt too bad, once they climb to anything over a few 1000 or so, you will begin to notice the slowdowns very quickly.

    Dats why I always sayz "mAxDaRam" Even if you dont need it today, you WILL need it in the near future. OS X and the applications that run on it arent gonna get any smaller tomorrow, only bigger and more ram hungry as time goes on. This is especially evident in imaging/video/sound apps, but also gaming, browsing, etc etc too :)

Share This Page