Impact of Adblock Plus on startup time - revisited · 2010-06-10 02:31 by Wladimir Palant
A few months ago Taras Glek blogged about extensions having a significant impact on browser’s startup time. One of the extensions he measured was Adblock Plus 1.1.3 and it didn’t make a good figure. Originally I thought that significantly optimizing Adblock Plus initialization wasn’t possible but I then found that using lazy evaluation for some values improved the performance of Adblock Plus 1.2 quite significantly. So I decided to check what things look like now.
Taras measured cold startup in his post which makes sense seeing his interest in file reading patterns. However, measuring cold startup times is much harder than measuring warm startup. Also, the difference between the two startup times usually isn’t something an extension developer can control (there isn’t much you can do once your extension is packaged properly). So I measured warm startup times using the method Vladimir Vukićević described in his blog. The table below sums up the results for a current Firefox nightly (build 20100609) on Windows 7. Each line represents 10 runs, two runs that took the most time were removed before calculating the average:
|Adblock Plus 1.1.3 (no filters)||793ms|
|Adblock Plus 1.1.3 (EasyList)||2349ms|
|Adblock Plus 1.2 (no filters)||782ms|
|Adblock Plus 1.2 (EasyList)||1201ms|
|Adblock Plus 1.3a (no filters)||796ms|
|Adblock Plus 1.3a (EasyList)||1334ms|
|Adblock Plus 1.3a (en-US only, no filters)||803ms|
One thing is clear: Adblock Plus 1.2 was indeed a huge improvement reducing the time to process filters to almost one-forth of the old value. All the other overhead of the Adblock Plus initialization is still pretty small in comparison (40ms to 400 ms). It also seems that the number of locales included doesn’t have an effect on the warm startup time — a regular Adblock Plus 1.3a build (43 locales included) and an en-US-only build didn’t perform significantly different (7ms difference isn’t meaningful on my laptop despite all the averaging). The locales might still influence cold startup time but I somehow doubt that.
It is somewhat disturbing that the filter processing time went up again for Adblock Plus 1.3a (which wasn’t a regular development build by the way, those are somewhat slower due to time measurement code — I had to create a release build to get comparable times). This change didn’t show up in any of the performance tests that measure various aspects of the initialization and I am not aware of any changes that might have caused this, will need to find the regression window. Other than that I expected the initialization of Adblock Plus 1.3a to be somewhat faster due to much more code being loaded from startup cache, however the impact of this change is apparently too small to show up here.
Commenting is closed for this article.