Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 from telemetry import benchmark | 5 from telemetry import benchmark |
| 6 | 6 |
| 7 from measurements import startup | 7 from measurements import startup |
| 8 import page_sets | 8 import page_sets |
| 9 | 9 |
| 10 | 10 |
| 11 class _StartupCold(benchmark.Benchmark): | 11 class _StartupCold(benchmark.Benchmark): |
| 12 """Measures cold startup time with a clean profile.""" | 12 """Measures cold startup time with a clean profile.""" |
| 13 options = {'pageset_repeat': 5} | 13 options = {'pageset_repeat': 5} |
|
sullivan
2015/04/03 13:59:43
Can we lower the pageset_repeat in your LargeProfi
erikchen
2015/04/03 17:05:50
I lowered the pageset_repeat to 1 for the large pr
| |
| 14 | 14 |
| 15 @classmethod | 15 @classmethod |
| 16 def Name(cls): | 16 def Name(cls): |
| 17 return 'startup' | 17 return 'startup' |
| 18 | 18 |
| 19 def CreatePageTest(self, options): | 19 def CreatePageTest(self, options): |
| 20 return startup.Startup(cold=True) | 20 return startup.Startup(cold=True) |
| 21 | 21 |
| 22 | 22 |
| 23 class _StartupWarm(benchmark.Benchmark): | 23 class _StartupWarm(benchmark.Benchmark): |
| (...skipping 26 matching lines...) Expand all Loading... | |
| 50 | 50 |
| 51 @benchmark.Enabled('has tabs') | 51 @benchmark.Enabled('has tabs') |
| 52 class StartupWarmBlankPage(_StartupWarm): | 52 class StartupWarmBlankPage(_StartupWarm): |
| 53 """Measures warm startup time with a clean profile.""" | 53 """Measures warm startup time with a clean profile.""" |
| 54 tag = 'warm' | 54 tag = 'warm' |
| 55 page_set = page_sets.BlankPageSet | 55 page_set = page_sets.BlankPageSet |
| 56 | 56 |
| 57 @classmethod | 57 @classmethod |
| 58 def Name(cls): | 58 def Name(cls): |
| 59 return 'startup.warm.blank_page' | 59 return 'startup.warm.blank_page' |
| 60 | |
| 61 @benchmark.Enabled('has tabs') | |
| 62 @benchmark.Enabled('win', 'linux', 'mac') | |
| 63 class StartupLargeProfileColdBlankPage(_StartupCold): | |
| 64 """Measures cold startup time with a large profile.""" | |
| 65 tag = 'cold' | |
| 66 page_set = page_sets.BlankPageSet | |
| 67 | |
| 68 def __init__(self, max_failures=None): | |
| 69 super(StartupLargeProfileColdBlankPage, self).__init__(max_failures) | |
| 70 self.generated_profile_archive = "large_profile.zip" | |
| 71 | |
| 72 @classmethod | |
| 73 def Name(cls): | |
| 74 return 'startup.large_profile.cold.blank_page' | |
| 75 | |
| 76 @benchmark.Enabled('has tabs') | |
| 77 @benchmark.Enabled('win', 'linux', 'mac') | |
| 78 class StartupLargeProfileWarmBlankPage(_StartupWarm): | |
| 79 """Measures warm startup time with a large profile.""" | |
| 80 tag = 'warm' | |
| 81 page_set = page_sets.BlankPageSet | |
| 82 | |
| 83 def __init__(self, max_failures=None): | |
| 84 super(StartupLargeProfileWarmBlankPage, self).__init__(max_failures) | |
| 85 self.generated_profile_archive = "large_profile.zip" | |
| 86 | |
| 87 @classmethod | |
| 88 def Name(cls): | |
| 89 return 'startup.large_profile.warm.blank_page' | |
| OLD | NEW |