I have had two complaints about my favorite browser firefox. The first was that it takes up a huge amount of ram and doesn't give it back. The second was that if you minimize it for any amount of time at all it take forever to bring the window back up while it swaps the memory back in. I ran across an incredibly helpful article that addresses both of these and give other hints on maximizing the performance and usability of firefox.
Fix a memory leak in Firefox 1.0
Firefox is supposed to dynamically release memory from its RAM cache to other Windows applications as needed. Unfortunately, Firefox 1.0 seems to consume more memory than it should, which hurts performance, when set to the default of 51200 Kb (51 MB).
To solve this, Firefox power users recommend limiting the memory cache using the Configuration Console. This frees up memory for other apps, speeding up everything to a greater or a lesser extent, depending on your machine and the applications you run. Here's how the trick works:
Step 1. Type about:config into Firefox's Address Bar and press Enter.
Step 2. Right-click any row, then click New, Integer. Type or paste the following preference name into the dialog box that appears (this is a hidden preference that doesn't exist in the Configuration Console until you create it):
browser.cache.memory.capacity
Step 3. Click OK, then enter the following integer number into the next dialog box, representing 16 MB of RAM for the cache:
16000
Step 4. Click OK to close the dialog box, then close all instances of Firefox and restart it.
For a lengthy discussion of this option, see Mozillazine's forum topic 172041.
and
Speeding up the maximizing of Firefox
By default, when you minimize Firefox, it gives back to Windows most of the RAM the browser was using. It sometimes can take several seconds for the browser window to become fully loaded when you restore the window to its original size. This is one of those "version 1.0" things, in my opinion, that will become more streamlined in future bump revs of the program.
Fortunately, there's a hidden setting that can accomplish the restoration of Firefox windows much more quickly:
Step 1. Use about:config to create a new, Boolean value. Type or paste the following string into the dialog box that appears:
config.trim_on_minimize
Step 2. Click OK to close the dialog box. Change the value from "true" to "false" and restart Firefox.
This doesn't piggishly retain all of the RAM that Firefox has claimed. If Windows needs more RAM to devote to another application, Windows can take it. What the setting does is prevent Firefox from giving up most of its RAM until the memory is actually required elsewhere.
Setting this item to "false" may noticeably slow down other applications while Firefox is minimized, if your PC has less than 256 MB of RAM. If so, change the setting back to "true."
There's an extremely long discussion about the development of this trick, going back to March 2004 (and continuing up through today), in Bugzilla bug report #76831. If you're determined to delve into this, I'd recommend starting with comment 329.
Speeding up Firefox on Windows XP
You can speed up the loading of Firefox on Windows XP by adding it to the programs that XP "prefetches."
To do this, right-click the Start Menu item for Firefox, or any icon you use to start Firefox, and open the Properties dialog box. Add a space plus /Prefetch:1 to the command line and click OK. The resulting line might look as follows:
"C:\Program Files\Mozilla Firefox\firefox.exe" /Prefetch:1
A detailed explanation of XP's prefetch feature is provided by TechRepublic.