it was just a hunch that i’ve been meaning to dive into for a couple of days now. when i’m on facebook, the memory footprint of firefox gets larger and larger until i reach that point where i am forced to close firefox (or kill the process). i do have several tabs open at the same time–besides facebook i am also accessing my mail, this blog, slashdot, a news site, a bike forum, flickr and ubuntu forums, just to name a handful. so it was hard to pin down the culprit to just one site.
this morning i decided to experiment. from a fresh boot:
- start firefox
- log on to facebook only (defaults to my profile)
- click on home
- click on a friend’s profile
- click on home
- click on another friend’s profile
- click on home
- click on a third friend’s profile
- click on home

in the memory and swap history section, each step corresponds to each visit to my 'home' page in facebook
i waited for the browser to finish loading each page before moving on and clicking on the next. by the fourth visit to my home page the browser started to get sluggish and it popped a warning (second image) saying that there is an unresponsive script on the page and it is offering either to let the script continue or to stop it. i opted to stop the script and close the browser. the first image shows an increase in memory usage each time the home page in facebook is revisited. by the fourth visit the swap memory has started to increase as well.
i also found out that closing the browser tab where facebook is assigned does not free the memory it used. that can only be accomlished by closing the browser itself.

this may be the script that's allocating all that memory.
i’m not sure which is really the culprit but i’m leaning more on firefox’s memory handling. i do not remember the previous versions being this bad at handling memory. but then again facebook may be using a new script for the user’s home page.
i’m just hoping it gets fixed. soon.