Some small optimizations go a long way. There's no need to add duplicate actions to the serialized list as long as order is preserved. We can't check the whole list to see if a duplicate action has been added, because that would break ignore-previous-rules, but we can check the previous action, which is where most of the duplicate actions will be. Also, ignore-previous-rules ignores the previous rules only in that extension, but block can return early without processing other extensions.
Created attachment 247872 [details] Patch
Comment on attachment 247872 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=247872&action=review > Source/WebCore/contentextensions/ContentExtensionCompiler.cpp:58 > + if (ruleIndex && rule.action() == ruleList[ruleIndex - 1].action()) > + continue; I don't think that is right, actionLocations should point to actionLocations[ruleIndex - 1] instead of actions.size()
Created attachment 247920 [details] Patch
Comment on attachment 247920 [details] Patch Clearing flags on attachment: 247920 Committed r181065: <http://trac.webkit.org/changeset/181065>
All reviewed patches have been landed. Closing bug.