re:swappiness
So this is one of the first results that I saw when I googled "mac os x swappiness" (or something like that).
A swappiness sort of feature would be awesome, but I don't know how low-level that would go.
I'm not positive, but I think that the memory manager is contained in the Mach part of the OSX kernel, outside of userland. I have no clear idea if that could pose a problem, but my guess is that it would.
My mac seems to very aggressively swap out memory. That is (and I may have used the term "aggressively" incorrectly), I have 750 MB of swap space currently being used, but I have 1.29GB of RAM free and 1.27GM of RAM inactive. I understand wanting to keep some memory free for whatever a user may want to do, but it would make more sense to me if there were some sort of moderately-difficult-to-access method of altering what the equivalent of "swappiness" is on the OSX kernel. That way people who would destroy their systems if they altered it wouldn't be able to get to the option (very easily, that is).
I understand the reasoning behind writing to swap, in terms of user-friendliness for people who don't know anything about their computers, but I would love to be able to change swappiness.
Also, I know that the iPhone OS doesn't swap out memory because swapping out to a flash drive would destroy the flash drive's lifespan. In contrast, a magnetic hard drive can put up with many more read/writes than a flash drive. Maybe the differences between the OSX kernel and the iPhone kernel could yield some sort of interesting results. However, I'm not sure if Apple offers their kernel open-source (I seriously doubt it, but I'm not positive). On the other hand, I haven't checked out alternative OSX kernels, which may offer that option.
I'll probably be back to post more about this issue.