| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 core import perf_benchmark | 5 from core import perf_benchmark |
| 6 | 6 |
| 7 from measurements import v8_detached_context_age_in_gc | 7 from measurements import v8_detached_context_age_in_gc |
| 8 from measurements import v8_gc_times | 8 from measurements import v8_gc_times |
| 9 import page_sets | 9 import page_sets |
| 10 from telemetry import benchmark | 10 from telemetry import benchmark |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 @benchmark.Disabled('reference', 'android') # crbug.com/579546 | 56 @benchmark.Disabled('reference', 'android') # crbug.com/579546 |
| 57 class V8InfiniteScroll(perf_benchmark.PerfBenchmark): | 57 class V8InfiniteScroll(perf_benchmark.PerfBenchmark): |
| 58 """Measures V8 GC metrics and memory usage while scrolling the top web pages. | 58 """Measures V8 GC metrics and memory usage while scrolling the top web pages. |
| 59 http://www.chromium.org/developers/design-documents/rendering-benchmarks""" | 59 http://www.chromium.org/developers/design-documents/rendering-benchmarks""" |
| 60 | 60 |
| 61 def SetExtraBrowserOptions(self, options): | 61 def SetExtraBrowserOptions(self, options): |
| 62 options.AppendExtraBrowserArgs([ | 62 options.AppendExtraBrowserArgs([ |
| 63 # TODO(perezju): Temporary workaround to disable periodic memory dumps. | 63 # TODO(perezju): Temporary workaround to disable periodic memory dumps. |
| 64 # See: http://crbug.com/513692 | 64 # See: http://crbug.com/513692 |
| 65 '--enable-memory-benchmarking', | 65 '--enable-memory-benchmarking', |
| 66 # TODO(ssid): Remove this flag after fixing http://crbug.com/461788. | |
| 67 '--no-sandbox', | |
| 68 '--js-flags=--heap-growing-percent=10' | 66 '--js-flags=--heap-growing-percent=10' |
| 69 ]) | 67 ]) |
| 70 | 68 |
| 71 def CreateStorySet(self, options): | 69 def CreateStorySet(self, options): |
| 72 return page_sets.InfiniteScrollPageSet() | 70 return page_sets.InfiniteScrollPageSet() |
| 73 | 71 |
| 74 def CreateTimelineBasedMeasurementOptions(self): | 72 def CreateTimelineBasedMeasurementOptions(self): |
| 75 v8_gc_latency_categories = [ | 73 v8_gc_latency_categories = [ |
| 76 'blink.console', 'renderer.scheduler', 'v8', 'webkit.console'] | 74 'blink.console', 'renderer.scheduler', 'v8', 'webkit.console'] |
| 77 smoothness_categories = [ | 75 smoothness_categories = [ |
| (...skipping 17 matching lines...) Expand all Loading... |
| 95 @classmethod | 93 @classmethod |
| 96 def ValueCanBeAddedPredicate(cls, value, is_first_result): | 94 def ValueCanBeAddedPredicate(cls, value, is_first_result): |
| 97 if value.tir_label in ['Begin', 'End']: | 95 if value.tir_label in ['Begin', 'End']: |
| 98 return value.name.startswith('memory_') and 'v8_renderer' in value.name | 96 return value.name.startswith('memory_') and 'v8_renderer' in value.name |
| 99 else: | 97 else: |
| 100 return value.tir_label == 'Scrolling' | 98 return value.tir_label == 'Scrolling' |
| 101 | 99 |
| 102 @classmethod | 100 @classmethod |
| 103 def ShouldTearDownStateAfterEachStoryRun(cls): | 101 def ShouldTearDownStateAfterEachStoryRun(cls): |
| 104 return True | 102 return True |
| OLD | NEW |