Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Issue 2797083002: Test cases for querySelector fast paths. (Closed)

Created:
3 years, 8 months ago by esprehn
Modified:
3 years, 8 months ago
Reviewers:
meade_UTC10, dglazkov, rune
CC:
blink-reviews, blink-reviews-dom_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, rwlbuis, sof
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Test cases for querySelector fast paths. Historically we only had perf tests for the various fast paths but that makes it hard to know what's really happening and if a change in the SelectorQuery code changed behavior (ex. Searching too many elements but still finding the right answer). This patch introduces a system that tracks counters inside SelectorQuery (only enabled with dchecks) that let us write tests to verify the fast paths. I then wrote a bunch of tests and added comments about edge cases that are handled poorly by the fast paths today. BUG=703900 Review-Url: https://codereview.chromium.org/2797083002 Cr-Commit-Position: refs/heads/master@{#462526} Committed: https://chromium.googlesource.com/chromium/src/+/c00d9dec2a75f7ab0ca2220066c93f7749b797f2

Patch Set 1 #

Patch Set 2 : Make the tests work. #

Patch Set 3 : Working tests. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+198 lines, -2 lines) Patch
M third_party/WebKit/Source/core/dom/ContainerNode.h View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/dom/SelectorQuery.h View 1 2 1 chunk +14 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/SelectorQuery.cpp View 1 2 11 chunks +32 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/SelectorQueryTest.cpp View 1 2 2 chunks +151 lines, -1 line 0 comments Download

Messages

Total messages: 15 (11 generated)
esprehn
3 years, 8 months ago (2017-04-06 08:40:11 UTC) #9
rune
lgtm
3 years, 8 months ago (2017-04-06 11:02:33 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2797083002/40001
3 years, 8 months ago (2017-04-06 16:46:56 UTC) #12
commit-bot: I haz the power
3 years, 8 months ago (2017-04-06 17:23:53 UTC) #15
Message was sent while issue was closed.
Committed patchset #3 (id:40001) as
https://chromium.googlesource.com/chromium/src/+/c00d9dec2a75f7ab0ca2220066c9...

Powered by Google App Engine
This is Rietveld 408576698