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

Unified Diff: PerformanceTests/Parser/query-selector-id-deep.html

Issue 14581013: Optimized querySelector(All) when selector contains #id. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fixed review issues in Patch Set 2 Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | PerformanceTests/Parser/query-selector-id-last.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: PerformanceTests/Parser/query-selector-id-deep.html
diff --git a/PerformanceTests/Parser/query-selector-deep.html b/PerformanceTests/Parser/query-selector-id-deep.html
similarity index 77%
copy from PerformanceTests/Parser/query-selector-deep.html
copy to PerformanceTests/Parser/query-selector-id-deep.html
index 605355f53762e40f7cd16e0cbc9b9d9de51b6c9b..3b9fc1aa75ab8732f238dac65af46c8e8fdd17d7 100644
--- a/PerformanceTests/Parser/query-selector-deep.html
+++ b/PerformanceTests/Parser/query-selector-id-deep.html
@@ -18,12 +18,10 @@ h1.className = "class";
parentDiv.appendChild(h1);
PerfTestRunner.measureRunsPerSecond({
- description: "This benchmark tests querySelector() for an element that appears in the depths in the document",
+ description: "This benchmark tests querySelector() for an element that appears in the depths in the document, and is a descendant of an element with a given id",
run: function() {
for (var i = 0; i < 100; i++) {
- document.querySelector("h1");
- document.querySelector("#id");
- document.querySelector(".class");
+ var res = document.querySelector("#foo998 h1");
}
}});
</script>
« no previous file with comments | « no previous file | PerformanceTests/Parser/query-selector-id-last.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698