By default, Firefox does not use a fixed size memory cache. Setting a fixed size memory cache can reduce memory usage. To set a fixed size memory cache, add the following pref using about:config:
browser.cache.memory.capacity
This is an integer pref, and can be set to the size you want the cache to be (in kilobytes).
To disable the memory cache entirely, set browser.cache.memory.enable to false. Note that this is not advised unless you're extremely short of memory, as it can slow things down severely, as well as causing other odd behaviour.
More tips: http://forums.mozillazine.org/viewtopic.php?t=354828
Paul