Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Bad | 13 comments | Create New Account
Click here to return to the 'Bad' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Bad
Authored by: bhines on Dec 27, '01 01:49:19AM
Here's what they said on the darwin-dev list about this idea. Sounds pretty bad. " One of the worst ideas i've ever heard of" to use his words.
From: Shantonu Sen Date: 2001-12-24 09:44:42 Subject: Re: vm and performance improvements ------------------------------------------------------------------------ > I would like to ask why relocating the vm directory (which contains the > swapfile) to another drive partition or a mounted disk image (on > startup) improves application relaunch times. Can you provide data on how much launch time improves? What about other file access performance? How much RAM do you have? Do your "improvements" work on machines with 64MB RAM? 128MB? (boot with your boot-args OF var set to maxmem=64). > Is there any specific reason why Darwin does not implement such an idea? Because they're terrible ideas, and just move the performance issues elsewhere. Putting swap on a disk image is one of the worst ideas i've ever heard of. Disk images under Mac OS X (which are not in Darwin, but I will address it anyway) are backed by user level processes using the IOKit user client API. Just imagine if your system gets low on memory and has to swap out 10 pages from hdid (the user client process). The filesystem write goes to the bsd dev to IOKit and then BACK OUT TO HDID. If critical pages were in the process of being swapped out, suddenly they're needed again immediately. Mixing VM at the mach level and disk images at the IOKit+userland level is a terrible idea. Any performance you think you're seeing is probably because the underlying disk image being cached by UBC. I'm guessing you have a lot of RAM and this works for you, great. You should try just disabling dynamic_pager and seeing if you see the same performance (I would expect you would). Check out the darwin-dev and darwinos-users archives at www.darwinfo.org and search for "swap" for some more discussions. Shantonu


[ Reply to This | # ]