How Photoshop allocates RAM
When Photoshop starts, it allocates, or sets aside, a portion of RAM, the size of which is based on the amount that is designated in the Photoshop Memory & Image Cache preferences. While this RAM is reserved for Photoshop processes, it may be used by other applications when it isn't actively in use by Photoshop, and is released when you quit Photoshop. The default RAM allocation settings are 70% for Mac OS, and 55% for Windows. These settings should be optimal for most users. To get the ideal RAM allocation setting for your system, change the RAM allocation in 5% increments and watch the performance of Photoshop in the Performance Monitor (Windows) or the Activity Monitor (Mac OS). You must quit and restart Photoshop after each change to see the change take effect.
The available RAM shown in the Memory & Image Cache preferences already deducted an amount that is reserved for the OS at any given time from the total RAM in your machine. You shouldn't set the percentage of RAM to be used by Photoshop to 100%, because other applications which run at the same time as Photoshop (for example, Adobe Bridge) need a share of the available RAM. Some applications use more RAM than you might expect. For example, web browsers can use 20-30 MB of RAM, and music players can use 20-50 MB RAM. Watch the Performance Monitor or the Activity Monitor to view the RAM allocations on your computer.
Watch your efficiency indicator while you work in Photoshop to determine the amount of RAM you'll need to keep your images in RAM. The efficiency indicator is available from the pop-up menu on the status bar of your image and from the Palette Options on the Info Palette pop-up menu. When the efficiency indicator goes below 95-100%, you are using the scratch disk. If the efficiency is around 60%, you'll see a large performance increase by changing your RAM allocation or adding RAM.
New capabilities with 64-bit processors
Photoshop CS2 is a 32-bit application. When it runs on a 32-bit operating system, such as Windows 2000, Windows XP Professional, and Mac OS v10.2.8, it can access the first 2 GB of RAM on the computer. The operating system uses some of this RAM, so the Photoshop Memory Usage preference displays only a maximum of 1.6 or 1.7 GB of total available RAM. If you are running Windows XP Professional with Service Pack 2, you can set the 3 GB switch in the boot.ini file, which allows Photoshop to use up to 3 GB of RAM.
Important: The 3GB switch is a Microsoft switch and may not work with all computers. Contact Microsoft for instructions before you set the 3 GB switch, and for troubleshooting the switch. You can search on the Microsoft support page for 3gb for information on this switch.
When you run Photoshop CS2 on a computer with a 64-bit processor (such as a G5, Intel Xeon processor with EM64T, AMD Athlon 64, or Opteron processor), and running a 64-bit version of the operating system (Mac OS v10.3 or higher, Windows XP Professional x64 Edition), that has 4 GB or more of RAM, Photoshop will use 3 GB for it's image data. You can see the actual amount of RAM Photoshop can use in the Maximum Used By Photoshop number when you set the Maximum Used by Photoshop slider in the Memory & Image Cache preference to 100%. The RAM above the 100% used by Photoshop, which is from approximately 3 GB to 3.7 GB, can be used directly by Photoshop plug-ins (some plug-ins need large chunks of contiguous RAM), filters, actions, etc. If you have more than 4 GB (to 6 GB (Windows) or 8 GB (Mac OS)), the RAM above 4 GB is used by the operating system as a cache for the Photoshop scratch disk data. Data that previously was written directly to the hard disk by Photoshop, is now cached in this high RAM before being written to the hard disk by the operating system. If you are working with files large enough to take advantage of these extra 2 GB of RAM, the RAM cache can speed performance of Photoshop.
Virtual memory and the Photoshop scratch disk
Photoshop CS2 may allocate more memory (RAM and scratch disk) to itself when starting than earlier versions of Photoshop, depending on the amount of RAM on the computer and the percentage of RAM allocated to Photoshop in the Memory Usage preference. The amount of available RAM on the system also dictates the image tile size in Photoshop (Photoshop uses tiles to redraw images in sections).
Photoshop displays RAM and scratch disk usage and allocation in the Scratch Sizes section of the image's status bar or the Info Palette. The number on the left indicates the RAM used and scratch disk space allocated to Photoshop The number on the right indicates the amount of RAM that Photoshop can use for image storage or scratch disk. Thus, the number on the left may be larger than what you are accustomed to from previous versions, but does not indicate that images use three times more RAM than they did in previous versions.
If the percentage of RAM allocated to Photoshop is too high, both the operating system and Photoshop can swap pages out of RAM, causing slow performance in Photoshop. Page swapping is a normal operating system function that only affects performance when the amount of RAM that Photoshop and the operating system are trying to use is more than the total amount of RAM on the computer.
If you have more than one hard disk, you'll get the best performance when virtual memory is on one hard disk and the Photoshop scratch disk on another, so they do not try to use the hard disk at the same time, which can slow down Photoshop and the operating system. However, if the operating system has enough RAM to not have to swap pages out of RAM, then having virtual memory and the Photoshop scratch disk on the same drive will not decrease performance.