Page MenuHomePhabricator

One condition consumed from the limit for every function parameter and every level of parentheses
Closed, ResolvedPublic

Description

Functions calls consume one condition from the limit for every function parameter. This is obviously wrong, and it means that e.g. contains_any(foo, 'a', 'b', 'c') is more expensive than 'a' in foo | 'b' in foo | 'c' in foo, even though it's faster.

Details

Related Gerrit Patches:
mediawiki/extensions/AbuseFilter : masterImprove how the number of conditions is counted

Event Timeline

matmarex created this task.Apr 8 2016, 4:16 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptApr 8 2016, 4:16 PM

I've since learned that this has gotten painstakingly documented at https://www.mediawiki.org/wiki/Extension:AbuseFilter/Conditions. I'll archive the page and document the new simpler rules later.

matmarex renamed this task from Functions calls consume one condition from the limit for every function parameter to Functions calls consume one condition from the limit for every function parameter and every level of parentheses.Apr 9 2016, 12:45 PM
Dalba added a subscriber: Dalba.Apr 9 2016, 1:34 PM

Change 282477 had a related patch set uploaded (by Bartosz Dziewoński):
Improve how the number of conditions is counted

https://gerrit.wikimedia.org/r/282477

matmarex triaged this task as High priority.Apr 9 2016, 2:26 PM

Change 282477 merged by jenkins-bot:
Improve how the number of conditions is counted

https://gerrit.wikimedia.org/r/282477

He7d3r added a subscriber: He7d3r.
matmarex renamed this task from Functions calls consume one condition from the limit for every function parameter and every level of parentheses to One condition consumed from the limit for every function parameter and every level of parentheses.Apr 16 2016, 9:08 PM
matmarex removed a project: Patch-For-Review.