Closed Bug 794631 Opened 7 years ago Closed 7 years ago

Useless WHERE clauses added to empty filter queries

Categories

(Firefox for Android :: Awesomescreen, defect)

ARM
Android
defect
Not set

Tracking

()

RESOLVED FIXED
Firefox 18

People

(Reporter: Margaret, Assigned: Margaret)

References

Details

Attachments

(1 file)

Attached patch patchSplinter Review
"".split(" ") returns [""], so we're creating adding a "WHERE (url LIKE '%%' OR title LIKE '%%')" clause to empty filter queries. Let's not do that.

I modified testBrowserProviderPerf to run with an emtpy filter string (see bug 785945 comment 9), and here are some results:

Without patch: 1344, 1341, 1356 
With patch: 1276, 1269, 1258

We'll still want to continue to work on fixing this query in bug 785945, but this is a really simple win that we could probably uplift.
Attachment #665134 - Flags: review?(lucasr.at.mozilla)
Assignee: nobody → margaret.leibovic
OS: Mac OS X → Android
Hardware: x86 → ARM
Comment on attachment 665134 [details] [diff] [review]
patch

Review of attachment 665134 [details] [diff] [review]:
-----------------------------------------------------------------

Nice catch.
Attachment #665134 - Flags: review?(lucasr.at.mozilla) → review+
https://hg.mozilla.org/mozilla-central/rev/550c5ac80046
Status: NEW → RESOLVED
Closed: 7 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.