| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2016 The Chromium Authors. All rights reserved. | 2 # Copyright 2016 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 """Script to generate chromium.perf.json and chromium.perf.fyi.json in | 6 """Script to generate chromium.perf.json and chromium.perf.fyi.json in |
| 7 the src/testing/buildbot directory and benchmark.csv in the src/tools/perf | 7 the src/testing/buildbot directory and benchmark.csv in the src/tools/perf |
| 8 directory. Maintaining these files by hand is too unwieldy. | 8 directory. Maintaining these files by hand is too unwieldy. |
| 9 """ | 9 """ |
| 10 import argparse | 10 import argparse |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 } | 182 } |
| 183 ]) | 183 ]) |
| 184 waterfall = add_tester( | 184 waterfall = add_tester( |
| 185 waterfall, 'Android Swarming N5X Tester', | 185 waterfall, 'Android Swarming N5X Tester', |
| 186 'fyi-android-swarming-n5x', 'android', | 186 'fyi-android-swarming-n5x', 'android', |
| 187 swarming=[ | 187 swarming=[ |
| 188 { | 188 { |
| 189 'os': 'Android', | 189 'os': 'Android', |
| 190 'android_devices': '1', | 190 'android_devices': '1', |
| 191 'device_ids': [ | 191 'device_ids': [ |
| 192 'build245-m4--device1', 'build245-m4--device2', | 192 #'build245-m4--device1', offline, see http://crbug.com/705135 |
| 193 'build245-m4--device2', |
| 193 'build245-m4--device3', 'build245-m4--device4', | 194 'build245-m4--device3', 'build245-m4--device4', |
| 194 'build245-m4--device5', 'build245-m4--device6', | 195 'build245-m4--device5', 'build245-m4--device6', |
| 195 'build245-m4--device7', 'build248-m4--device1', | 196 'build245-m4--device7', 'build248-m4--device1', |
| 196 'build248-m4--device2', 'build248-m4--device3', | 197 'build248-m4--device2', 'build248-m4--device3', |
| 197 'build248-m4--device4', 'build248-m4--device5', | 198 'build248-m4--device4', 'build248-m4--device5', |
| 198 'build248-m4--device6', 'build248-m4--device7', | 199 'build248-m4--device6', 'build248-m4--device7', |
| 199 'build249-m4--device1', 'build249-m4--device2', | 200 'build249-m4--device1', 'build249-m4--device2', |
| 200 'build249-m4--device3', 'build249-m4--device4', | 201 'build249-m4--device3', 'build249-m4--device4', |
| 201 'build249-m4--device5', 'build249-m4--device6', | 202 'build249-m4--device5', 'build249-m4--device6', |
| 202 'build249-m4--device7' | 203 'build249-m4--device7' |
| (...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 753 | 754 |
| 754 all_benchmarks = current_benchmarks(False) | 755 all_benchmarks = current_benchmarks(False) |
| 755 whitelist_benchmarks = current_benchmarks(True) | 756 whitelist_benchmarks = current_benchmarks(True) |
| 756 # Get benchmark sharding according to common sharding configurations | 757 # Get benchmark sharding according to common sharding configurations |
| 757 # Currently we only have bots sharded 5 directions and 1 direction | 758 # Currently we only have bots sharded 5 directions and 1 direction |
| 758 benchmark_sharding_map = {} | 759 benchmark_sharding_map = {} |
| 759 benchmark_sharding_map['22'] = shard_benchmarks(22, all_benchmarks) | 760 benchmark_sharding_map['22'] = shard_benchmarks(22, all_benchmarks) |
| 760 benchmark_sharding_map['5'] = shard_benchmarks(5, all_benchmarks) | 761 benchmark_sharding_map['5'] = shard_benchmarks(5, all_benchmarks) |
| 761 benchmark_sharding_map['1'] = shard_benchmarks(1, all_benchmarks) | 762 benchmark_sharding_map['1'] = shard_benchmarks(1, all_benchmarks) |
| 762 benchmark_sharding_map['21'] = shard_benchmarks(21, all_benchmarks) | 763 benchmark_sharding_map['21'] = shard_benchmarks(21, all_benchmarks) |
| 764 # Added because of temporary removal of device in http://crbug.com/705135 |
| 765 benchmark_sharding_map['20'] = shard_benchmarks(20, all_benchmarks) |
| 763 | 766 |
| 764 for name, config in waterfall['testers'].iteritems(): | 767 for name, config in waterfall['testers'].iteritems(): |
| 765 use_whitelist = config['use_whitelist'] | 768 use_whitelist = config['use_whitelist'] |
| 766 benchmark_list = all_benchmarks | 769 benchmark_list = all_benchmarks |
| 767 if use_whitelist: | 770 if use_whitelist: |
| 768 benchmark_list = whitelist_benchmarks | 771 benchmark_list = whitelist_benchmarks |
| 769 if config.get('swarming', False): | 772 if config.get('swarming', False): |
| 770 # Our current configuration only ever has one set of swarming dimensions | 773 # Our current configuration only ever has one set of swarming dimensions |
| 771 # Make sure this still holds true | 774 # Make sure this still holds true |
| 772 if len(config['swarming_dimensions']) > 1: | 775 if len(config['swarming_dimensions']) > 1: |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 975 return 0 | 978 return 0 |
| 976 else: | 979 else: |
| 977 print ('The perf JSON config files are not up-to-date. Please run %s ' | 980 print ('The perf JSON config files are not up-to-date. Please run %s ' |
| 978 'without --validate-only flag to update the perf JSON ' | 981 'without --validate-only flag to update the perf JSON ' |
| 979 'configs and benchmark.csv.') % sys.argv[0] | 982 'configs and benchmark.csv.') % sys.argv[0] |
| 980 return 1 | 983 return 1 |
| 981 else: | 984 else: |
| 982 update_all_tests([fyi_waterfall, waterfall]) | 985 update_all_tests([fyi_waterfall, waterfall]) |
| 983 update_benchmark_csv() | 986 update_benchmark_csv() |
| 984 return 0 | 987 return 0 |
| OLD | NEW |