Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2014 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2014 The Chromium Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 | 5 |
| 6 """Run the Skia benchmarking executable.""" | 6 """Run the Skia benchmarking executable.""" |
| 7 | 7 |
| 8 import os | 8 import os |
| 9 import sys | 9 import sys |
| 10 | 10 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 53 'nanobench_%s_%s.json' % ( self._got_revision, git_timestamp)) | 53 'nanobench_%s_%s.json' % ( self._got_revision, git_timestamp)) |
| 54 | 54 |
| 55 def _AnyMatch(self, *args): | 55 def _AnyMatch(self, *args): |
| 56 return any(arg in self._builder_name for arg in args) | 56 return any(arg in self._builder_name for arg in args) |
| 57 | 57 |
| 58 def _Run(self): | 58 def _Run(self): |
| 59 args = ['-i', self._device_dirs.ResourceDir(), | 59 args = ['-i', self._device_dirs.ResourceDir(), |
| 60 '--skps', self._device_dirs.SKPDir(), | 60 '--skps', self._device_dirs.SKPDir(), |
| 61 '--scales', '1.0', '1.1'] | 61 '--scales', '1.0', '1.1'] |
| 62 if self._AnyMatch('Valgrind'): | 62 if self._AnyMatch('Valgrind'): |
| 63 args.append('--runOnce') # Don't care about performance on Valgrind. | 63 args.append('--loops 1') # Don't care about performance on Valgrind. |
|
borenet
2014/08/07 20:18:54
Should be:
args.extend(['--loops', '1'])
mtklein
2014/08/07 20:20:42
Done.
| |
| 64 elif self._perf_data_dir: | 64 elif self._perf_data_dir: |
| 65 args.extend([ | 65 args.extend([ |
| 66 '--outResultsFile', self._JSONPath(), | 66 '--outResultsFile', self._JSONPath(), |
| 67 '--gitHash', self._got_revision, | 67 '--gitHash', self._got_revision, |
| 68 ]) | 68 ]) |
| 69 args.append('--key') | 69 args.append('--key') |
| 70 args.extend(self._KeyParams()) | 70 args.extend(self._KeyParams()) |
| 71 | 71 |
| 72 match = [] | 72 match = [] |
| 73 # Disable known problems. | 73 # Disable known problems. |
| (...skipping 20 matching lines...) Expand all Loading... | |
| 94 # See skia:2789 | 94 # See skia:2789 |
| 95 if self._AnyMatch('Valgrind'): | 95 if self._AnyMatch('Valgrind'): |
| 96 abandonGpuContext = list(args) | 96 abandonGpuContext = list(args) |
| 97 abandonGpuContext.append('--abandonGpuContext') | 97 abandonGpuContext.append('--abandonGpuContext') |
| 98 abandonGpuContext.append('--nocpu') | 98 abandonGpuContext.append('--nocpu') |
| 99 self._flavor_utils.RunFlavoredCmd('nanobench', abandonGpuContext) | 99 self._flavor_utils.RunFlavoredCmd('nanobench', abandonGpuContext) |
| 100 | 100 |
| 101 | 101 |
| 102 if '__main__' == __name__: | 102 if '__main__' == __name__: |
| 103 sys.exit(BuildStep.RunBuildStep(RunNanobench)) | 103 sys.exit(BuildStep.RunBuildStep(RunNanobench)) |
| OLD | NEW |