Changeset 227850 in webkit
- Timestamp:
- Jan 30, 2018 2:08:11 PM (6 years ago)
- Location:
- trunk/PerformanceTests
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/PerformanceTests/ChangeLog
r227769 r227850 1 2018-01-30 Antti Koivisto <antti@apple.com> 2 3 StyleBench: Generate more mutation steps 4 https://bugs.webkit.org/show_bug.cgi?id=182291 5 6 Reviewed by Ryosuke Niwa. 7 8 The test should be doing multiple rounds of mutations in a single document to test what is supposed to test (like it did before r227756). 9 This also makes test results more stable and less dependent on possible first-time costs. 10 11 * StyleBench/resources/benchmark-runner.js: 12 13 Adjust correctionFactor to match the new steps count. With 1.5 Firefox is ~72rpm. 14 15 * StyleBench/resources/tests.js: 16 (makeSteps): 17 18 Generate 10 rounds of class/element mutation steps. 19 Give each generated step unique name so reporting works. 20 Make individual steps do fewer mutations. 21 1 22 2018-01-29 Antti Koivisto <antti@apple.com> 2 23 -
trunk/PerformanceTests/StyleBench/resources/benchmark-runner.js
r227756 r227850 287 287 var geomean = Math.pow(product, 1 / values.length); 288 288 289 var correctionFactor = 8; // This factor makes the test score look reasonably fit within 0 to 140.289 var correctionFactor = 1.5; // This factor makes the test score look reasonably fit within 0 to 140. 290 290 this._measuredValues.total = total; 291 291 this._measuredValues.mean = total / values.length; -
trunk/PerformanceTests/StyleBench/resources/tests.js
r227756 r227850 2 2 { 3 3 const steps = []; 4 steps.push(new BenchmarkTestStep('Adding classes', (bench, contentWindow, contentDocument) => { 5 bench.addClasses(100); 6 })); 7 steps.push(new BenchmarkTestStep('Removing classes', (bench, contentWindow, contentDocument) => { 8 bench.removeClasses(100); 9 })); 10 steps.push(new BenchmarkTestStep('Adding leaf elements', (bench, contentWindow, contentDocument) => { 11 bench.addLeafElements(100); 12 })); 13 steps.push(new BenchmarkTestStep('Removing leaf elements', (bench, contentWindow, contentDocument) => { 14 bench.removeLeafElements(100); 15 })); 4 for (i = 1; i <= count; ++i) { 5 steps.push(new BenchmarkTestStep(`Adding classes - ${i}`, (bench, contentWindow, contentDocument) => { 6 bench.addClasses(25); 7 })); 8 steps.push(new BenchmarkTestStep(`Removing classes - ${i}`, (bench, contentWindow, contentDocument) => { 9 bench.removeClasses(25); 10 })); 11 steps.push(new BenchmarkTestStep(`Adding leaf elements - ${i}`, (bench, contentWindow, contentDocument) => { 12 bench.addLeafElements(25); 13 })); 14 steps.push(new BenchmarkTestStep(`Removing leaf elements - ${i}`, (bench, contentWindow, contentDocument) => { 15 bench.removeLeafElements(25); 16 })); 17 } 16 18 return steps; 17 19 } … … 27 29 }); 28 30 }, 29 tests: makeSteps( ),31 tests: makeSteps(10), 30 32 }; 31 33 }
Note: See TracChangeset
for help on using the changeset viewer.