OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # | 2 # |
3 # Copyright 2012 the V8 project authors. All rights reserved. | 3 # Copyright 2012 the V8 project authors. All rights reserved. |
4 # Redistribution and use in source and binary forms, with or without | 4 # Redistribution and use in source and binary forms, with or without |
5 # modification, are permitted provided that the following conditions are | 5 # modification, are permitted provided that the following conditions are |
6 # met: | 6 # met: |
7 # | 7 # |
8 # * Redistributions of source code must retain the above copyright | 8 # * Redistributions of source code must retain the above copyright |
9 # notice, this list of conditions and the following disclaimer. | 9 # notice, this list of conditions and the following disclaimer. |
10 # * Redistributions in binary form must reproduce the above | 10 # * Redistributions in binary form must reproduce the above |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 result.add_option("--no-network", "--nonetwork", | 150 result.add_option("--no-network", "--nonetwork", |
151 help="Don't distribute tests on the network", | 151 help="Don't distribute tests on the network", |
152 default=(utils.GuessOS() != "linux"), | 152 default=(utils.GuessOS() != "linux"), |
153 dest="no_network", action="store_true") | 153 dest="no_network", action="store_true") |
154 result.add_option("--no-presubmit", "--nopresubmit", | 154 result.add_option("--no-presubmit", "--nopresubmit", |
155 help='Skip presubmit checks', | 155 help='Skip presubmit checks', |
156 default=False, dest="no_presubmit", action="store_true") | 156 default=False, dest="no_presubmit", action="store_true") |
157 result.add_option("--no-snap", "--nosnap", | 157 result.add_option("--no-snap", "--nosnap", |
158 help='Test a build compiled without snapshot.', | 158 help='Test a build compiled without snapshot.', |
159 default=False, dest="no_snap", action="store_true") | 159 default=False, dest="no_snap", action="store_true") |
| 160 result.add_option("--no-sorting", "--nosorting", |
| 161 help="Don't sort tests according to duration of last run.", |
| 162 default=False, dest="no_sorting", action="store_true") |
160 result.add_option("--no-stress", "--nostress", | 163 result.add_option("--no-stress", "--nostress", |
161 help="Don't run crankshaft --always-opt --stress-op test", | 164 help="Don't run crankshaft --always-opt --stress-op test", |
162 default=False, dest="no_stress", action="store_true") | 165 default=False, dest="no_stress", action="store_true") |
163 result.add_option("--no-variants", "--novariants", | 166 result.add_option("--no-variants", "--novariants", |
164 help="Don't run any testing variants", | 167 help="Don't run any testing variants", |
165 default=False, dest="no_variants", action="store_true") | 168 default=False, dest="no_variants", action="store_true") |
166 result.add_option("--variants", | 169 result.add_option("--variants", |
167 help="Comma-separated list of testing variants") | 170 help="Comma-separated list of testing variants") |
168 result.add_option("--outdir", help="Base directory with compile output", | 171 result.add_option("--outdir", help="Base directory with compile output", |
169 default="out") | 172 default="out") |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 else: | 407 else: |
405 timeout = TIMEOUT_DEFAULT; | 408 timeout = TIMEOUT_DEFAULT; |
406 | 409 |
407 timeout *= TIMEOUT_SCALEFACTOR[mode] | 410 timeout *= TIMEOUT_SCALEFACTOR[mode] |
408 ctx = context.Context(arch, mode, shell_dir, | 411 ctx = context.Context(arch, mode, shell_dir, |
409 mode_flags, options.verbose, | 412 mode_flags, options.verbose, |
410 timeout, options.isolates, | 413 timeout, options.isolates, |
411 options.command_prefix, | 414 options.command_prefix, |
412 options.extra_flags, | 415 options.extra_flags, |
413 options.no_i18n, | 416 options.no_i18n, |
414 options.random_seed) | 417 options.random_seed, |
| 418 options.no_sorting) |
415 | 419 |
416 # TODO(all): Combine "simulator" and "simulator_run". | 420 # TODO(all): Combine "simulator" and "simulator_run". |
417 simulator_run = not options.dont_skip_simulator_slow_tests and \ | 421 simulator_run = not options.dont_skip_simulator_slow_tests and \ |
418 arch in ['arm64', 'arm', 'mips'] and ARCH_GUESS and arch != ARCH_GUESS | 422 arch in ['arm64', 'arm', 'mips'] and ARCH_GUESS and arch != ARCH_GUESS |
419 # Find available test suites and read test cases from them. | 423 # Find available test suites and read test cases from them. |
420 variables = { | 424 variables = { |
421 "arch": arch, | 425 "arch": arch, |
422 "asan": options.asan, | 426 "asan": options.asan, |
423 "deopt_fuzzer": False, | 427 "deopt_fuzzer": False, |
424 "gc_stress": options.gc_stress, | 428 "gc_stress": options.gc_stress, |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
502 exit_code = runner.Run(options.j) | 506 exit_code = runner.Run(options.j) |
503 overall_duration = time.time() - start_time | 507 overall_duration = time.time() - start_time |
504 | 508 |
505 if options.time: | 509 if options.time: |
506 verbose.PrintTestDurations(suites, overall_duration) | 510 verbose.PrintTestDurations(suites, overall_duration) |
507 return exit_code | 511 return exit_code |
508 | 512 |
509 | 513 |
510 if __name__ == "__main__": | 514 if __name__ == "__main__": |
511 sys.exit(Main()) | 515 sys.exit(Main()) |
OLD | NEW |