Opened on 03/19/2015 at 05:42:34 PM
Closed on 03/19/2015 at 06:58:55 PM
#2177 closed change (fixed)
Optimize filter matching performance by performing regexp match last
Reported by: | sebastian | Assignee: | sebastian |
---|---|---|---|
Priority: | P3 | Milestone: | Adblock-Plus-2.6.9-for-Firefox |
Module: | Core | Keywords: | |
Cc: | trev | Blocked By: | |
Blocking: | Platform: | Unknown | |
Ready: | yes | Confidential: | no |
Tester: | Verified working: | ||
Review URL(s): |
Description
Background
Slow regular expressions can easily kill the filter matching performance, even if the request type or document domain doesn't match. Hence we should change the order of checks when matching filters, perfoming the less expensive checks first.
What to change
Change the implementation of Filter.matches(), to first match request type, third party and document domain. And perform the the regexp match last only if all other tests passed.
Attachments (0)
Change History (4)
comment:1 Changed on 03/19/2015 at 05:43:04 PM by sebastian
- Summary changed from Optimize filter matching by performing regexp match last to Optimize filter matching performance by performing regexp match last
comment:2 Changed on 03/19/2015 at 05:44:41 PM by trev
- Cc trev added
- Priority changed from Unknown to P3
- Ready set
comment:3 Changed on 03/19/2015 at 05:46:14 PM by sebastian
- Review URL(s) modified (diff)
- Status changed from new to reviewing
comment:4 Changed on 03/19/2015 at 06:58:55 PM by sebastian
- Milestone set to Adblock-Plus-for-Firefox-next
- Resolution set to fixed
- Status changed from reviewing to closed
Note: See
TracTickets for help on using
tickets.
https://hg.adblockplus.org/adblockplus/rev/28dc0dd097c6