Unreviewed, rolling out r209672.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 12 Dec 2016 18:59:39 +0000 (18:59 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 12 Dec 2016 18:59:39 +0000 (18:59 +0000)
https://bugs.webkit.org/show_bug.cgi?id=165766

IndexedDB/objectstore-cursor.html perf test always times out
(Requested by ap on #webkit).

Reverted changeset:

"More IndexedDB perf tests."
https://bugs.webkit.org/show_bug.cgi?id=165634
http://trac.webkit.org/changeset/209672

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@209716 268f45cc-cd09-0410-ab3c-d52691b4dbfc

PerformanceTests/ChangeLog
PerformanceTests/IndexedDB/index-multientry.html
PerformanceTests/IndexedDB/large-number-of-inserts-responsiveness.html [deleted file]
PerformanceTests/IndexedDB/large-number-of-inserts.html [deleted file]
PerformanceTests/IndexedDB/objectstore-cursor.html [deleted file]
PerformanceTests/resources/runner.js

index 2fda555..85d6197 100644 (file)
@@ -1,3 +1,17 @@
+2016-12-12  Commit Queue  <commit-queue@webkit.org>
+
+        Unreviewed, rolling out r209672.
+        https://bugs.webkit.org/show_bug.cgi?id=165766
+
+        IndexedDB/objectstore-cursor.html perf test always times out
+        (Requested by ap on #webkit).
+
+        Reverted changeset:
+
+        "More IndexedDB perf tests."
+        https://bugs.webkit.org/show_bug.cgi?id=165634
+        http://trac.webkit.org/changeset/209672
+
 2016-12-10  Brady Eidson  <beidson@apple.com>
 
         More IndexedDB perf tests.
index aa4f2ec..5b86b02 100644 (file)
@@ -4,14 +4,12 @@
 <script src="../resources/runner.js"></script>
 <script>
 
-var iterationCount = 20;
+var iterationCount = 11;
 var numberDeleted = 0;
 
 // Delete all databases for the test ahead of time.
-var databaseNamePrefix = "index-multientry-DB-";
-for (var i = 0; i < iterationCount + 1; ++i) {
-    req = indexedDB.deleteDatabase(databaseNamePrefix + i);
-    req.onsuccess = function() {
+for (var i = 0; i < iterationCount; ++i) {
+    indexedDB.deleteDatabase("index-multientry-DB-" + i).onsuccess = function() {
         if (++numberDeleted == iterationCount)
             startIteration();
     }
@@ -46,14 +44,14 @@ function nextStep()
 }
 
 var object = { test: 'yo', indexKeys: [] };
-for (var i = 0; i < 5000; i++)
+for (var i = 0; i < 1000; i++)
     object.indexKeys.push('index_no_' + i);
 
 function *runIteration()
 {
     var startTime = PerfTestRunner.now();
 
-    var openRequest = indexedDB.open(databaseNamePrefix + currentIteration);
+    var openRequest = indexedDB.open("index-multientry-DB-" + currentIteration);
     openRequest.onupgradeneeded = function(event) {
         db = event.target.result;
         db.createObjectStore('store').createIndex('index', 'indexKeys', { multiEntry: true });
diff --git a/PerformanceTests/IndexedDB/large-number-of-inserts-responsiveness.html b/PerformanceTests/IndexedDB/large-number-of-inserts-responsiveness.html
deleted file mode 100644 (file)
index 69ff6b5..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-<!DOCTYPE html>
-<html>
-<body>
-<script src="../resources/runner.js"></script>
-<script>
-
-var iterationCount = 20;
-var numberDeleted = 0;
-
-// Delete all databases for the test ahead of time.
-var databasePrefix = "large-number-of-inserts-responsiveness-DB-";
-for (var i = 0; i < iterationCount + 1; ++i) {
-    indexedDB.deleteDatabase(databasePrefix + i).onsuccess = function() {
-        if (++numberDeleted == iterationCount)
-            startIteration();
-    }
-}
-
-var testGenerator = null;
-var db = null;
-var currentIteration = 0;
-
-PerfTestRunner.prepareToMeasureValuesAsync({
-    customIterationCount: iterationCount,
-    unit: 'ms',
-    done: function () {
-        db = null;
-        largestDelay = 0;
-        testGenerator = null;
-        PerfTestRunner.gc();
-        ++currentIteration;
-    }
-});
-
-function startIteration()
-{
-    testGenerator = runIteration();
-    nextStep();
-}
-
-function nextStep()
-{
-    testGenerator.next();
-}
-
-var numberOfObjects = 50000;
-var objectsToInsert = new Array(numberOfObjects);
-for (var i = 0; i < numberOfObjects; ++i) {
-    objectsToInsert[i] = { data: Math.random() };
-    objectsToInsert[i].id = 'object_' + i;
-}
-
-function *runIteration()
-{
-    var openRequest = indexedDB.open(databasePrefix + currentIteration);
-    openRequest.onupgradeneeded = function(event) {
-        db = event.target.result;
-        db.createObjectStore('objects', {keyPath: 'id'});
-    }
-    openRequest.onsuccess = nextStep;
-
-    yield;
-
-    var objectStore = db.transaction('objects', 'readwrite').objectStore('objects');
-    objectStore.transaction.oncomplete = nextStep;
-    for (var i = 0; i < numberOfObjects; ++i)
-        objectStore.put(objectsToInsert[i]);
-
-    PerfTestRunner.startCheckingResponsiveness();
-
-    yield;
-
-    PerfTestRunner.stopCheckingResponsiveness();
-    
-    if (!PerfTestRunner.measureValueAsync(PerfTestRunner.longestResponsivenessDelay()))
-        return;
-
-    setTimeout(startIteration, 0);
-}
-
-</script>
-</body>
-</html>
diff --git a/PerformanceTests/IndexedDB/large-number-of-inserts.html b/PerformanceTests/IndexedDB/large-number-of-inserts.html
deleted file mode 100644 (file)
index 7add728..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-<!DOCTYPE html>
-<html>
-<body>
-<script src="../resources/runner.js"></script>
-<script>
-
-var iterationCount = 20;
-var numberDeleted = 0;
-
-// Delete all databases for the test ahead of time.
-var databasePrefix = "large-number-of-inserts-DB-";
-for (var i = 0; i < iterationCount + 1; ++i) {
-    indexedDB.deleteDatabase(databasePrefix + i).onsuccess = function() {
-        if (++numberDeleted == iterationCount)
-            startIteration();
-    }
-}
-
-var testGenerator = null;
-var db = null;
-var currentIteration = 0;
-
-PerfTestRunner.prepareToMeasureValuesAsync({
-    customIterationCount: iterationCount,
-    unit: 'ms',
-    done: function () {
-        db = null;
-        testGenerator = null;
-        PerfTestRunner.gc();
-        ++currentIteration;
-    }
-});
-
-function startIteration()
-{
-    testGenerator = runIteration();
-    nextStep();
-}
-
-function nextStep()
-{
-    testGenerator.next();
-}
-
-var numberOfObjects = 100000;
-var objectsToInsert = new Array(numberOfObjects);
-for (var i = 0; i < numberOfObjects; ++i) {
-    objectsToInsert[i] = { data: Math.random() };
-    objectsToInsert[i].id = 'object_' + i;
-}
-
-function *runIteration()
-{
-    var openRequest = indexedDB.open(databasePrefix + currentIteration);
-    openRequest.onupgradeneeded = function(event) {
-        db = event.target.result;
-        db.createObjectStore('objects', {keyPath: 'id'});
-    }
-    openRequest.onsuccess = nextStep;
-
-    yield;
-
-    var startTime = PerfTestRunner.now();
-
-    var objectStore = db.transaction('objects', 'readwrite').objectStore('objects');
-    objectStore.transaction.oncomplete = nextStep;
-    for (var i = 0; i < numberOfObjects; ++i)
-        objectStore.put(objectsToInsert[i]);
-
-    yield;
-
-    if (!PerfTestRunner.measureValueAsync(PerfTestRunner.now() - startTime))
-        return;
-
-    setTimeout(startIteration, 0);
-}
-
-</script>
-</body>
-</html>
diff --git a/PerformanceTests/IndexedDB/objectstore-cursor.html b/PerformanceTests/IndexedDB/objectstore-cursor.html
deleted file mode 100644 (file)
index 96ad746..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-<!DOCTYPE html>
-<html>
-<body>
-<script src="../resources/runner.js"></script>
-<script>
-
-var iterationCount = 20;
-var numberDeleted = 0;
-// Delete all databases for the test ahead of time.
-var databaseName = "objectstore-cursor-DB";
-indexedDB.deleteDatabase(databaseName).onsuccess = function() {
-    startIteration();
-}
-
-var testGenerator = null;
-var db = null;
-var currentIteration = 0;
-
-PerfTestRunner.prepareToMeasureValuesAsync({
-    customIterationCount: iterationCount,
-    unit: 'ms',
-    done: function () {
-        db = null;
-        testGenerator = null;
-        PerfTestRunner.gc();
-        ++currentIteration;
-    }
-});
-
-function startIteration()
-{
-    testGenerator = runIteration();
-    nextStep();
-}
-
-function nextStep()
-{
-    testGenerator.next();
-}
-
-function *runIteration()
-{
-    var openRequest = indexedDB.open(databaseName);
-    openRequest.onupgradeneeded = function(event) {
-        db = event.target.result;
-        var objectStore = db.createObjectStore('store');
-        for (var i = 0; i < 50000; ++i) {
-            var suffix = ("0000000" + i).slice(-7);
-            objectStore.put("bar_value_" + suffix, "foo_key_" + suffix);
-        }
-    }
-    openRequest.onsuccess = nextStep;
-
-    yield;
-
-    var startTime = PerfTestRunner.now();
-    var cursorRequest = db.transaction('store').objectStore('store').openCursor();
-    var cursorIteration = 0;
-    cursorRequest.onsuccess = function(event) {
-        var cursor = event.target.result;
-        if (cursor) {
-            var suffix = ("0000000" + cursorIteration).slice(-7);
-            if (cursor.key != "foo_key_" + suffix)
-                alert("Incorrect value retrieved: " + cursor.key);
-            if (cursor.value != "bar_value_" + suffix)
-                alert("Incorrect value retrieved: " + cursor.key);
-            ++cursorIteration;
-            cursor.continue();
-        } else
-            nextStep();
-    };
-
-    yield;
-
-    if (!PerfTestRunner.measureValueAsync(PerfTestRunner.now() - startTime))
-        return;
-
-    setTimeout(startIteration, 0);
-}
-</script>
-</body>
-</html>
index af2e03a..eb01515 100755 (executable)
@@ -15,9 +15,6 @@ if (window.testRunner) {
     var jsHeapResults;
     var mallocHeapResults;
     var iterationCount = undefined;
-    var lastResponsivenessTimestamp = 0;
-    var _longestResponsivenessDelay = 0;
-    var continueCheckingResponsiveness = false;
 
     var PerfTestRunner = {};
 
@@ -326,32 +323,6 @@ if (window.testRunner) {
         return PerfTestRunner.now() - startTime;
     }
 
-    PerfTestRunner.startCheckingResponsiveness = function() {
-        lastResponsivenessTimestamp = PerfTestRunner.now();
-        _longestResponsivenessDelay = 0;
-        continueCheckingResponsiveness = true;
-
-        var timeoutFunction = function() {
-            var now = PerfTestRunner.now();
-            var delta = now - lastResponsivenessTimestamp;
-            if (delta > _longestResponsivenessDelay)
-                _longestResponsivenessDelay = delta;    
-
-            lastResponsivenessTimestamp = now;
-            if (continueCheckingResponsiveness)
-                setTimeout(timeoutFunction, 0);
-        }
-        
-        timeoutFunction();
-    }
-
-    PerfTestRunner.stopCheckingResponsiveness = function() {
-        continueCheckingResponsiveness = false;
-    }
-
-    PerfTestRunner.longestResponsivenessDelay = function() {
-        return _longestResponsivenessDelay;
-    }
 
     PerfTestRunner.measurePageLoadTime = function(test) {
         test.run = function() {