OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2013 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 Performance Test Bisect Tool | 6 """Run Performance Test Bisect Tool |
7 | 7 |
8 This script is used by a try bot to run the bisect script with the parameters | 8 This script is used by a try bot to run the bisect script with the parameters |
9 specified in the bisect config file. It checks out a copy of the depot in | 9 specified in the bisect config file. It checks out a copy of the depot in |
10 a subdirectory 'bisect' of the working directory provided, annd runs the | 10 a subdirectory 'bisect' of the working directory provided, annd runs the |
11 bisect scrip there. | 11 bisect scrip there. |
12 """ | 12 """ |
13 | 13 |
14 import optparse | 14 import optparse |
15 import os | 15 import os |
16 import platform | 16 import platform |
17 import subprocess | 17 import subprocess |
18 import sys | 18 import sys |
19 import traceback | 19 import traceback |
20 | 20 |
21 from auto_bisect import bisect_perf_regression | 21 from auto_bisect import bisect_perf_regression |
22 from auto_bisect import bisect_utils | 22 from auto_bisect import bisect_utils |
23 from auto_bisect import math_utils | 23 from auto_bisect import math_utils |
24 | 24 |
25 CROS_BOARD_ENV = 'BISECT_CROS_BOARD' | 25 CROS_BOARD_ENV = 'BISECT_CROS_BOARD' |
26 CROS_IP_ENV = 'BISECT_CROS_IP' | 26 CROS_IP_ENV = 'BISECT_CROS_IP' |
27 | 27 |
28 SCRIPT_DIR = os.path.dirname(__file__) | 28 SCRIPT_DIR = os.path.abspath(os.path.dirname(__file__)) |
29 SRC_DIR = os.path.join(SCRIPT_DIR, os.path.pardir) | 29 SRC_DIR = os.path.join(SCRIPT_DIR, os.path.pardir) |
30 BISECT_CONFIG_PATH = os.path.join(SCRIPT_DIR, 'auto_bisect', 'bisect.cfg') | 30 BISECT_CONFIG_PATH = os.path.join(SCRIPT_DIR, 'auto_bisect', 'bisect.cfg') |
31 RUN_TEST_CONFIG_PATH = os.path.join(SCRIPT_DIR, 'run-perf-test.cfg') | 31 RUN_TEST_CONFIG_PATH = os.path.join(SCRIPT_DIR, 'run-perf-test.cfg') |
32 WEBKIT_RUN_TEST_CONFIG_PATH = os.path.join( | 32 WEBKIT_RUN_TEST_CONFIG_PATH = os.path.join( |
33 SRC_DIR, 'third_party', 'WebKit', 'Tools', 'run-perf-test.cfg') | 33 SRC_DIR, 'third_party', 'WebKit', 'Tools', 'run-perf-test.cfg') |
34 BISECT_SCRIPT_DIR = os.path.join(SCRIPT_DIR, 'auto_bisect') | 34 BISECT_SCRIPT_DIR = os.path.join(SCRIPT_DIR, 'auto_bisect') |
35 | 35 |
36 | 36 |
37 class Goma(object): | 37 class Goma(object): |
38 | 38 |
(...skipping 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
557 if config and config_is_valid: | 557 if config and config_is_valid: |
558 return _SetupAndRunPerformanceTest(config, opts.path_to_goma) | 558 return _SetupAndRunPerformanceTest(config, opts.path_to_goma) |
559 | 559 |
560 print ('Error: Could not load config file. Double check your changes to ' | 560 print ('Error: Could not load config file. Double check your changes to ' |
561 'auto_bisect/bisect.cfg or run-perf-test.cfg for syntax errors.\n') | 561 'auto_bisect/bisect.cfg or run-perf-test.cfg for syntax errors.\n') |
562 return 1 | 562 return 1 |
563 | 563 |
564 | 564 |
565 if __name__ == '__main__': | 565 if __name__ == '__main__': |
566 sys.exit(main()) | 566 sys.exit(main()) |
OLD | NEW |