blob: 88d37869e53a13e0e194f8ec6d03fe77824521af [file] [log] [blame]
<!DOCTYPE html>
<body>
<script src="../resources/runner.js"></script>
<select id="container" multiple></select>
<script>
var container = document.getElementById('container');
var nodes = [];
var childCount = 500;
for (var i = 0; i < childCount; ++i) {
nodes.push(document.createElement('option'));
nodes[i].selected = !!(i % 2);
}
PerfTestRunner.measureRunsPerSecond({
description: 'Measures performance of adding option elements to a multi-selection select element.',
run: function() {
for (var i = 0; i < childCount; ++i)
container.appendChild(nodes[i]);
container.innerHTML = '';
}
});
</script>
</body>