How To
by "Cajun" David Richard
In this month's How To, we will be taking a look at the magical mystery extension from Connectix called RAM Doubler. Yes, we've all heard about it, we've loved it, we've hated it, we've had it work, and had it not work. But because of it's operation, there is a lot of mystery surrounding it. I hope to shed a little light on how RAM Doubler works, how you can use it safely and how you can judge when not to use it.
This article is not meant to be an endorsement for the product, nor is it meant to be a bashing session. I think what RAM Doubler does is pretty neat. But I fear that the package is prettier than the product, and I feel that many users are depending on RAM Doubler because of the rave
reviews, and because it appears as an easy way to get out of buying more RAM for your machine.
The facts of this situation are simple. RAM Doubler does not double your RAM. No matter what your computer says, and no matter what you can do when RAM Doubler is installed, if you have 8mb, you have 8mb and that's all there is to it. That is all the RAM space you have to work in. You can only get more space by buying more RAM.
RAM Doubler is an extended memory scheme similiar to Virtual Memory. Yes, that little extension that you have in the Memory control panel is essentially the same thing as RAM Doubler. But RAM Doubler is doing something different than what the Virtual Memory extension does. To begin to understand what RAM Doubler does, lets take a look at what Virtual Memory (VM) does when active.
RAM is your work space and the hard drive is your storage. When you activate VM, you tell the
System that you have space on your hard drive reserved for RAM (the space where an application will be loaded into for operation). This space will be known as RAM, and not hard drive space, and the System will treat it as such.
Take a look a Fig. 1. This is what 8mb of RAM looks like. Fig 2. depicts 8mb of RAM with 8mb more allocated using VM, for a total of 16mb. Physical RAM can be accessed much faster than the hard drive, which is why you will notice a very obvious performance degradation when you are using the VM option. You will have the 16mb of RAM to work in, but your operation may be a little slow.
Note: PowerMac users should have VM turned on if you are using native applications. The reasons and details for this cannot be explained here, but if you are getting the impression that VM is a bad thing, you should be aware that it helps the operation of native PowerMac programs.
Now, let's take a look at RAM Doubler (RD). RD uses a method called RAM Sharing. (This is not an official term, and if it is incorrect, please forgive me. I made it up for this article.) What this means is that RD uses memory that is actually given to other applications, but memory that may not be used at the particular moment. In order to explain this better, open your About This
Macintosh... window under the Apple Menu when you are in the Finder. You should see something like the following:
Notice that each program running has its own memory space. This amount is set from the Get Info... window. Generally, there will be a recommendation for how much a program needs and what it prefers. You can change this, but going below the recommendations can cause problems.
The above window also shows how much of the allocated memory is actually being used. This is indicated by the darker area of the bar. Usually, the entire bar will not be used, since it is a good idea to give a program a little breathing room. Even the Finder allows for a little breathing room. The areas where the bar is not darkened is where RAM Doubler works its magic. In order to understand this better, we need another graphic.
Notice how Fig 4. is an altered version of the previous Fig. 3. I have added a new application that needs 2mb of space (in red), but I have used the same amount of RAM. This has been done using a basic version of the technique that RAM Doubler uses. RD assumes that there will only be one active application, and the the applications that are running in the background don't really need the extra memory that they have been given. In Fig. 4, the application that I have added is the active application (ie: in the foreground).
RAM Doubler uses two other techniques when it does its job. First, it compresses least recently used RAM, such as information used to boot a particular program. By compressing some of this information, RD can gain a little more space.
If this doesn't quite double the built-in RAM, RD takes this compressed information a writes it to disk. Usually, since this information is not used too much, performance does not suffer. But if a program needs this information, RD will have to access the disk causing a performance drop.
Now, as long as RAM Doubler keeps track of everything, the worst thing that can happen is you may see a little slow down as you switch applications. This is the time when RD does all its RAM switching and restoring so the application you are switching to has everything in order. Not too bad, as long as one of the programs doesn't crash, or doesn't do much work in the background.
This brings up the advantages of RAM Doubler. The most useful scenario to be in is when you run many applications that use small amounts of memory. This allows you to have many apps open (since you have much more RAM, so to speak), and to switch between them without too much of a slowdown. In this situation, RAM Doubler should be most efficient.
But, as your allocation block sizes increase, and you are running only one or two applications, you will probably have some trouble. The system has to use some real RAM, and each application needs to use the real RAM. Eventually, as the system reaches the upper limit of virtual RAM, it will fill up the real RAM and start using a scheme similar to what was described earlier with VM. This will cause the computer to slow down considerably.
Another thing that can happen is if one of the applications in the background tries to use the memory that rightfully belongs to it, but memory that RAM Doubler might have temporarily given to another application. What happens can be catastrophic in the worst case; you can run into the possibility of having the memory block corrupted, or have the program read another program's information.
In the case of games and other programs that need large blocks of memory, it is generally a good idea to turn off any extended memory schemes that may be running. The reason is that games, in particular, need to access real RAM quickly. You will see a stutter in the animation, or a general performance drop overall, if you are using an extended memory scheme.
So, in conclusion, RAM Doubler is useful, but not for all circumstances. If you find yourself using more than 40 - 50% of your RAM for a program -- while RAM Doubler is loaded -- you may want to consider a RAM Upgrade. But if you are using several small programs at once, and are not real concerned about speed (ie: not playing a lot of games or doing major work in Photoshop or another number crunching program), them RAM Doubler may be a solution for you. But, however you look at it, there truly is no substitute for real RAM.