Couldn't disagree more, personally...Windows does a generally good job of caching reads and writes using RAM, but a RAMdisk goes way beyond that.
That's only half of it.
When were RAMDisk's Viable? Back with the XT and Early AT PCs. Most applications used maybe 100K of Conventional Memory. VDISK.SYS could be used to turn part of that memory into a RAM Drive. Floppy's were the vogue and floppies are slow; next was Hard disks which were expensive and though much faster than a floppy still slow. Using a RAM Drive helped remove any I/O bottleneck from the system.
So, what about now?
Well, first, you've got two huge problems. The first is that a RAM drive will always be blank when you create it by definition; and the second is that everything on a RAM drive is lost the second power is cut from the system. No backups, no recovery- they just dribble away. In terms of Running Programs off an SSD, this means that you will usually need to install or at least copy the installation of the program from a hard disk before you run it from the RAM Drive. if you change configuration options, That application better be saving it's configuration onto the hard drive. In fact it ought to be storing most of it's persistent data on the hard drive. The only benefit you get from a RAM drive is that code and data segments load from the Executable and any Libraries it uses, except for Windows Libraries.
You get very little benefit from this.
- When an Executable is loaded, the entire file is not read and mapped into memory at once. A Virtual Address space is reserved and the Executable is memory mapped into the address space. What this means is that pages of virtual memory are allocated, and as code and data is accessed in the executable, that data is read from disk.
The executable data for a game or program is never large enough for this to matter in terms of RAMDrive Access speed.
The only gain would be if the Actual Data that said application loads; for example, levels, textures, etc. from Disk, were on said RAM drive.
Now the problem is two:
First, you need ALL that data to be on the RAM drive. You cannot only put a part of it on there because you would need to move the entire installation folder over. using Crysis as an Example, that's a little under 8GB of Data you would need; which means you would need at least a 8GB RAM Drive. 4GB would be useless, because you couldn't fit the entire installation on it; and if you didn't use a full install, it would be accessing the DVD for that data making the parts you use the RAM drive for entirely offset by the slow Optical Drive access times. Also, Because of the way most games work, you will need to actually Install them to that RAM drive, or at least install them once, make an image of that RAM drive, and restore it each time you start the system.
RAM Drives can only 'properly' be created once, at system startup time. They should be created by a Kernel level startup driver that allocated Physical Memory directly and prevents the rest of the System from ever using it; giving it one large contiguous chunk of RAM to use.
Thing is, Looking at some of the free offerings available for creating RAM Drives, it seems that few of them take this approach; the system total memroy is unchanged, and what these "RAM Drive" programs actually do is
perform virtual allocations of memory to create their RAM disk.
What this means is that the RAM pages occupied by the RAM drive are discardable- and can get swapped to the pagefile! That completely defeats the purpose, and basically just turns the RAM Drive into a special superfetch cache that only works for some files and only when you access them on a specific not-real drive letter.
One common usage for RAM drives is to make a RAM drive of some size, and them redirect %TEMP% and %TMP% there. Hooray! Super speedy temporary file access.
Of course, until you install an application that needs to reboot half-way; installers will use the temporary folder to put prerequisite files, then configure the system startup to continue the installation from that temporary directory after rebooting. Of course with a RAM Drive being used for the temporary folder, this doesn't work since those files dribble away when the system reboots. Now you have a sorta half installed program that is in a constant state of limbo because the last satage of installation requirements weren't run. It may or may not work and you may or may not have problems. But in general this is why using %TMP or %TEMP% on a RAM drive would be a bad idea. So that is out.
So returning to the previous note. Let's consider a System that has say 16GB of RAM. Now, for my system, an Upgrade from 8GB to 16GB would cost me around 400$, last I checked; (DDR2 is more expensive than DDR3 these days). DDR3 would be more affordable and for a new build this probably wouldn't be a bad idea. Anyway: RAM Drive Size.
Well, first, what are we going to use it for? For most folks, particularly gaming types, I imagine the aim would be to play games at a faster speed. One could argue for a business case dealing with databases- however, this is unlikely to be a common purpose since the purposes for which databases are usually used don't lend themselves well to the database dissappearing after commited transactions (Besides, most Database systems have a reliable and accurate Memory caching method that prevents data loss while also reducing Disk I/O).
Now we have a problem. Your typical modern game is about 6GB in size. even with a 8GB RAM Drive, we cannot have more than one on the RAM Drive at a time. I just wonder how that would work and how anybody could consider it worth the hassle. If you want to play Crysis, or some other game, it changes from you clicking the Crysis Icon on your desktop to now having to go into your Program Files Folder and copy the installation to the RAM drive, or, equally likely restore the Image you made after installing it to your RAM Drive and run it from there. If you do a direct copy, you might think it's faster but most games have settings that willcontain paths indicating where Data files are; and if you installed to Program Files, that would point at Program files, so even if you moved all the Data to a RAM drive it might still be accessing the source folders. So you would have to uninstall it from your system, install it to your AM drive, and then make a Disk Image of that Game. Then when you want to play it, you restore that image to the RAM drive and play it.
IMO this is a massive hassle, if nothing else. Not to mention you've halved the available memory to every single other application; and that's assuming you used RAMDrive software that did it properly (by reserving the RAM at system boot time and reducing the total physical address space available to the Rest of the Kernel). Most are user-mode drivers that use Virtual Allocations, which basically just adds another layer of indirection and causes the same thing you would expect, which is disk swapping to and from the pagefile as a result of pages being discarded.
If somebody is serious about using a RAM Drive, they shouldn't be using a software solution anyway; there are various hardware peripherals that let you install DDR2 and DDR3 RAM sticks into them and then connect and use those devices as standard SATA hard disks. This could be useful, but I still don't see how they could be much use. Unless you get a lot of Memory you are still going to just end up swapping disk images as you use different software. And if you use the RAM disk for storing User data- more fool you. I see it suggested often that a way to speed up, in particular, Minecraft, is to move the Worlds and user data to a RAM Drive. Which makes sense, since the biggest Performance bottleneck is the I/O from loading and saving the data from the Game World. Of course now you need to either remember or schedule some system to prevent that data from being lost. Power goes out after you finished building that giant Creeper Statue? Oh well, too bad. I've also seen it recommended for Photoshop work, which I find equally hard to fathom: Do you really want hours upon hours of work to create those hundred+ gigabyte files and data to simply dribble away because you wanted to load them in 2 seconds instead of 10? This is especially something I don't understand since sometimes dealing with graphics is not something where you can just repeat a series of steps and get the same result; you tweak and mess about with filters and various tools aiming for a specific look, but you don't keep a meticulous record of every single step you took to arrive at it, so if that finished Poster is lost due to a power outage, it will be gone forever and you can never make it again- you can try, but the result will never be the same thing. It might be better- but I hardly see that as something that would make RAM Disks seem appealing. "Causes you to lose hours of work and do the same thing twice- but the second time you got practice so it's usually better... ORDER NOW!"
Doing some googling on the subject and the sheer amount of complete misunderstandings of how Windows manages memory is mind boggling. I like the one that says Windows only ever uses the Pagefile when the system is running low on RAM. The pagefile is not swap space; it's used for discardable memory pages, Memory does not stay allocated until that same space is needed, if you leave an application in the background and do nothing, eventually it's memory pages will be swapped to the pagefile, even though nothing else required that memory.
Even with a decent SSD, loading files or programs from a RAMdisk at say 8GB/sec speeds is a vast improvement.
Except you need to copy those files and programs to the RAM disk and back off of it, and your RAM Disk is going to be smaller than your Hard disk or SSD, so it will always be a subset.