AdBlock Plus Firefox plugin could be sucking up gigabytes of your RAM

AdBlock Plus - which purports to block the garish, distracting advertisements found on a vast multitude of websites today - has attracted quite a sizable following across the globe. Many of its users find that, on the whole, it lives up to its claims, making web browsing more enjoyable and faster, while reducing the amount of data used by hiding and disabling adverts on webpages.

However, although data consumption may well be lowered, Mozilla suggests that enabling the popular plugin could result in exceptionally large amounts of RAM being consumed by the program. They found that just enabling the plugin on a 64-bit system could result in a constant additional RAM usage of 60-70MB on top of which Mozilla normally uses.

This may not sound like much until you realize that this is just the overhead incurred by simply having the plugin enabled. Whilst browsing a website with a relatively generous helping of ads, such as TechCrunch, Mozilla found that RAM usage by Firefox increased by over 200MB with AdBlock Plus enabled (417MB of RAM usage with the plugin, versus 194MB without).

With some more intensive websites such as the VIM Color Scheme Test, the plugin ended up consuming nearly 2GB of RAM at 1960MB; without it, just 370MB was used.

The AdBlock Plus development team recently acknowledged the issue on their blog and commented that the exceptional RAM usage was caused by a number of known bugs. One issue is that the plug-in's method of blocking adverts - by injecting stylesheets into HTML iFrame containers - incurs a gradual build-up of 4MB per iFrame. The issue is exacerbated as Firefox ends up duplicating these stylesheets for each new page loaded, eventually resulting in the immense RAM usage noted by Mozilla.

Hints of a major update to AdBlock Plus were dropped as the team said it wants "to implement [its] own way to store data" as an alternative to using the memory-intensive JavaScript data structures currently implemented.

For users who have large amounts of RAM installed on their machines, such as 8GB or more, this memory consumption may not prove to be too significant. But those with devices that have far less RAM installed may see more significant slow-downs if AdBlock Plus's memory usage hits the levels that Mozilla saw in testing.

The issue has not been noted in the Internet Explorer or Google Chrome versions of AdBlock Plus.

Source: Mozilla | Image via AdBlock Plus

Report a problem with article
Previous Story

London Heathrow's fifth terminal to become 'Terminal Samsung Galaxy S5'

Next Story

Respawn Entertainment releases mobile app for Titanfall

57 Comments

Commenting is disabled on this article.

The following image show the memory use per addon in Firefox;

https://www.dropbox.com/s/9gqk...wvq/Capture.PNG?n=299347724

The key is to create a custom ad-blocking list rather then using the ones provided by the built-in subscriptions. The following shows a customized list with 5700 generic filters and around 12300 domain specific filters [which includes ad serving and tracking domains].

https://www.dropbox.com/s/f9d2...4d/Capture3.PNG?n=299347724
https://www.dropbox.com/s/ltbk...id/Capture2.PNG?n=299347724

Patterns.ini is the rule's file located in your profile's folder. You can try mine out or create your own;

https://www.dropbox.com/s/8x03...l9/patterns.ini?n=299347724

Make sure you remove any previous subscriptions and disable auto update. The list never expires.

enjoY!!

Edited by ShAsadAhmad, May 17 2014, 5:46am :

with Opera 21 and neowin open ABP takes up 178MB ram on top of opera itself big deal I have 8GB of ram do I notice the use of such a trivial amount no I don't oh and that vim link in the op uses 2.11GB on it's own and really ads nothing to ABP's memory foot print

Noticed this long ago, chocked it up to basically the cost of doing business (exchange ram for free product to limit ads) , hopefully they'll actually get around to fixing it now that it's been highlighted again. Tons of ram in a system aside it's just sloppy and needs addressing.

Edited by knighthawk, May 16 2014, 7:44pm :

I run Firefox constantly between 150 and 200 open tabs (seriously!). It eats approx. 2 Gb RAM on my 6 Gb win7 x64 PC as Adblock Plus is always enabled. MY system does swapping quite frequently (due to FF of course), flushing data to swapfile, freeing up 100-700 MB RAM, then eating it up again slowly etc. crashing at lest 2-3 times per week, but I find it still acceptable as the list of open tabs are saved, so it can recover after the crash.

I read between 100 and 150 blogs occasionally, shop online frequently, read news site (like this one) etc. etc. etc. My company has a pathetic pre-2000 kind of internet access, so I usually open a dozen of links, and while I process 1 of them, the rest still download in the background. Also I keep open some sites that I douldnt process, and those tabs are waiting until 1 day I find them again to make something with them.

Same here, I use Adguard. The Adguard extension for Chrome is way, way better than Adblock Plus and Adblock - and it uses less resources!

AD-Muncher is great but it don't support SSL currently which kind of means you need something like ABP for Youtube since many of it is SSL connections.

Saving bandwidth and ridding myself of distracting and annoying adverts is more important than saving RAM, of which I have an abundance. That being said, if the ABP guys can improve that, I'm all for it :)

I just have a squidGuard proxy that returns blank pages for a large list of domains and urls.

The benefit of this is I can configure any client that supports proxies to block ads (computer, phone, psp, etc.), it is client controlled so they can turn it off if they so choose and I can selectively allow certain elements on the same domain while blocking others.

it's Ok I have more ram than patience.

(nothing like looking something up half asleep and some ad pops up at double the volume you thought your computer was capable of outputting)

Is that what's causing the "oops we're embarrassed. send crash report" dialog. It's happening so much that I'm about to switch to Chrome.

ABP on with FF 29.0.1 looking solely at Neowin is using up 364.2MB; that's with the Japanese Tattoo theme running too btw. When I visit that VIM page on a second tab it goes up to ~ 1,522MB.

ABP off with the same FF version looking at Neowin is using up 138MB but the home page took 5 or 6 times as long to load (I'm behind a poxy @ work). With VIM loaded on a second tab my memory usage goes up to 315MB. On a system that has 6GB of RAM, a few hundred MB really isn't going to break the bank.

It's not the ram that the issue it was the startup time until recently. It made me switch to Chrome. Chrome starts instantly no matter how many extensions used or how many Adblock Plus subscriptions one uses.
It's gotten better due to a recent change in ABP but Chrome still launches a lot faster than FF for me.

xdot.tk said,
It's not the ram that the issue it was the startup time until recently.

I'll give it startup time but Chrome's version of ABP is still far behind the Firefox version in usability, a lot of the options just aren't available and it just doesn't work as well.. doesn't always actually remove elements properly, etc etc. Until they get caught up with functionality I'll personally take those few extra milliseconds.

I've had no issues removing elements but what I have to do is use an open with FF extension on Chrome. On that particular copy of FF that Chrome launches, I just have ABP and Element Hider Helper installed. No filter subscriptions.

I use the EHH to get the filter then just right click an image in Chrome, "Block Element" and then paste the filter the box. Extra work but it works great.

ive been using this instance of Firefox, heavily, for 4-5 days now. It's consuming 1.2GB of RAM at this moment, ABP installed.

I know ABP does add some overhead (lots of rules out of the box it has to store, not exactly a surprise) but personally never seen it go that high, with a few tabs open I'm typically sitting at ~450ish MB, and that's with 25 or so addons not including ABP, still a lot lighter than a comparably configured Chrome setup which can push a gig or two easy with just a couple of tabs. That said, for what it does plus the added security from rogue ads, I'll gladly take the hit any day.

Yeah, in terms of overall RAM use it's pretty clear Chrome is worse than Firefox. i tend to have many tabs open (i use Pale Moon x64 which is basically 64bit Firefox. i have about 15-40tabs open typically) and i usually don't exceed about 1GB of RAM (maybe 1.1-1.2GB tops) in use and that's after the browser is running for many days it tends to top out in that general area. do that with Chrome and i am sure it will burn quite a bit more than that.

p.s. i got ABP installed with four other extensions to. so five extensions total.

Edited by ThaCrip, May 17 2014, 2:16am :

Yes! Ads are the greatest scourge of the internets! They and their unscrupulous owners' profit lines must be removed and eradicated, by any means necessary.

Ads are annoying and occasionally deceptive but there's a stark reality most general users are unaware of or simply ignore. They're part of why so many of us view the Internet as 'free' -- most web sites do not charge anything to allow people to access them but hosting any site does have a cost. Selling ad space is how a lot of sites fund themselves. If every web browser included an ad blocker that would cripple the Web as we know it, the result being companies would simply stop buying ad space since there would be no one viewing them. The situation now being they know most users do not install extensions, with more advanced users who do actively block ads being a negligible and acceptable loss. So yes, online ads suck but they also serve a very vital role in keeping the Web alive.

Interesting to note, although I have yet to incur a problem on my computers (or even noticed a problem) I don't think it will make much of an impact for many people however It should be fixed in an effort to minimise impact on older systems as well as improve efficiency.

Out of interest, has anyone actually had an issue with ABP due to excessive RAM usage? In the last 3x years I've not used a machine with less than 8gb (phone/tablet aside) so I've never actually realised it was even consuming so much!

to me 16GB+ is pretty much overkill for most people in most situations.

8GB is the sweet spot as it should be good enough into the foreseeable future as going over that and the gains you see are generally minimal and are just tossing $$$ in the trashcan, pretty much. i would rather put that extra $$$ towards more hard drive space etc.

ThaCrip said,
to me 16GB+ is pretty much overkill for most people in most situations.

8GB is the sweet spot as it should be good enough into the foreseeable future as going over that and the gains you see are generally minimal and are just tossing $$$ in the trashcan, pretty much. i would rather put that extra $$$ towards more hard drive space etc.

one sentence: photography, timelapse and video editing machine

Yeah, i am not saying there is no use for that much RAM but for most people it's overkill since most of us just use the PC for general use and maybe some video games is about as much power as most people would need in which case 8GB of RAM is sufficient.

ThaCrip said,
to me 16GB+ is pretty much overkill for most people in most situations.

8GB is the sweet spot as it should be good enough into the foreseeable future as going over that and the gains you see are generally minimal and are just tossing $$$ in the trashcan, pretty much. i would rather put that extra $$$ towards more hard drive space etc.


It's not overkill for most Neowin members since there are a memory intensive tasks that we need it for. Also, RAM is really cheap nowadays. :)

LimeMaster92 said,
When you have 16GBs of RAM, I doubt you would notice it. :laugh:
This is incorrect. I have 16GB, and due to the vast number of other apps I have open (required for work), 16GB is not enough when dealing with the memory leaks in Firefox itself as well as (now revealed) the ABP plugin.

Firefox seems to have gotten its memory usage in check in later versions, though it is still only my development browser and not my full-time browser.

It's not overkill for most Neowin members since there are a memory intensive tasks that we need it for.

besides video editing and the like... there really ain't much that could burn up 16GB of RAM as even filling 8GB would be difficult as i can run more than enough stuff and still not come close to filling the 8GB. even if you could fill 8GB+ of RAM with general apps, my guess is it's one of those 'just because you can' sort of things and not because you really want/need that much stuff running.

because say leaving your browser (or maybe even two browsers) running for days and then some apps along with a decent game still won't use 8GB. how much else can people really run that burns up a ton of RAM that's not video editing related?

Also, RAM is really cheap nowadays.

even if it's around $100 i would rather put that money towards more hard drive space myself since that i would actually see a real benefit.