Last Comment Bug 696205 - Consider adding an optimization for id selectors to querySelectorAll
: Consider adding an optimization for id selectors to querySelectorAll
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: DOM (show other bugs)
: Trunk
: All All
: P2 normal (vote)
: mozilla10
Assigned To: Boris Zbarsky [:bz] (Out June 25-July 6)
:
Mentors:
Depends on: 698974 738108
Blocks:
  Show dependency treegraph
 
Reported: 2011-10-20 13:51 PDT by Boris Zbarsky [:bz] (Out June 25-July 6)
Modified: 2012-03-21 19:03 PDT (History)
6 users (show)
bzbarsky: in‑testsuite?
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
part 1. Refactor querySelector and querySelectorAll so that there is only one codepath to modify. (4.06 KB, patch)
2011-10-20 13:58 PDT, Boris Zbarsky [:bz] (Out June 25-July 6)
no flags Details | Diff | Review
part 2. Add a querySelector fast-path for selectors whose rightmost sequence of simple selectors contains an id. (8.73 KB, patch)
2011-10-20 14:11 PDT, Boris Zbarsky [:bz] (Out June 25-July 6)
jonas: review+
Details | Diff | Review
part 1. Refactor querySelector and querySelectorAll so that there is only one codepath to modify. (4.06 KB, patch)
2011-10-21 10:37 PDT, Boris Zbarsky [:bz] (Out June 25-July 6)
jonas: review+
Details | Diff | Review

Description Boris Zbarsky [:bz] (Out June 25-July 6) 2011-10-20 13:51:33 PDT
It's easy to do, so might as well.  I do think the extra complexity is probably worth it....
Comment 1 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-10-20 13:58:00 PDT
Created attachment 568506 [details] [diff] [review]
part 1.  Refactor querySelector and querySelectorAll so that there is only one codepath to modify.
Comment 2 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-10-20 14:11:48 PDT
Created attachment 568512 [details] [diff] [review]
part 2.  Add a querySelector fast-path for selectors whose rightmost sequence of simple selectors contains an id.
Comment 3 Boris Zbarsky [:bz] (Out June 25-July 6) 2011-10-21 10:37:28 PDT
Created attachment 568703 [details] [diff] [review]
part 1.  Refactor querySelector and querySelectorAll so that there is only one codepath to modify.

Note You need to log in before you can comment on or make changes to this bug.