Categories

Amateur Radio (4)
Blog (33)
Calc (8)
Cars (7)
Honda Accord Hybrid (4)
Jeep (11)
Miata (21)
Coding (6)
Gadgets (231)
Sprint Ambassador (23)
Game (16)
Jokes (10)
Link Cache (36)
Misc (125)
Personal (36)
Photography (8)
Politics (1)
Tech (236)
AWS (6)
Travel (50)
Work (7)
Flickr

Social Stuff
Site Info

Sponsored Links

Laurie's Entries

« Mac Screen Auto Dimmer Is Driving Me Nuts | Main | Expendable Gerbils »

Understanding Mac OS X Memory Model

memory Running VirtualBox, like I am, reserves a whole lot of memory. If I give it 2GB, it appears to reserve that whole amount. Other VMs that I’ve seen will only allocate real system memory when the OS within the VM needs it. Since I was seeing about 10MB free on the Mac side, I figured I would reduce the VM size. I dropped it to 1GB. The free memory on the Mac side? It is essentially the same. So, I went to look up what each of the memory types meant on a Mac. It has Free, Wired, Active, Inactive, and Used.

According to the docs, Inactive memory is memory that could be paged out to disk. Active memory is memory that has been used recently. Wired memory is memory that can not be page. The implication is that Inactive memory can be used. Isn’t it already used? Wouldn’t allocating it take time since it would have to be paged first since it’s technically already allocated? Or is it? The doc says “inactive is there in case an application uses it again.” That implies that the app is done with it. It seems that for most purposes, Inactive memory can be considered available. It sounds like it’s similar to the notion of “cached” memory on Windows.

Then the process list shows memory as “Real” and “Virtual” – which translates to what type? Wired? Active? VirtualBox uses a “Real” amount equal to a bit over the VM size. But 2GB vs 1GB doesn’t change the “free” memory any. Goofy.

Posted by Shane on October 23, 2008 12:45 PM |

TrackBacks

TrackBack URL for this entry:
http://www.kf6nvr.net/mt/kf6nvr-tb.cgi/897