Commit ed71ede4 authored by Sergiy Byelozyorov's avatar Sergiy Byelozyorov Committed by Commit Bot

Add ability to trigger perf bots on swarming

R=machenbach@chromium.org

Bug: chromium:616879
Change-Id: I168ec7d3dbd1a9e9c6006919bf59de1d8b40ab3b
Reviewed-on: https://chromium-review.googlesource.com/881483Reviewed-by: 's avatarMichael Achenbach <machenbach@chromium.org>
Commit-Queue: Sergiy Byelozyorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50839}
parent ed76853d
......@@ -20,6 +20,10 @@ BOTS = {
'--nexus10': 'v8_nexus10_perf_try',
}
# This list will contain builder names that should be triggered on an internal
# swarming bucket instead of internal Buildbot master.
SWARMING_BOTS = []
DEFAULT_BOTS = [
'v8_arm32_perf_try',
'v8_linux32_perf_try',
......@@ -50,6 +54,17 @@ PUBLIC_BENCHMARKS = [
V8_BASE = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
def _trigger_bots(bucket, bots, options):
cmd = ['git cl try']
cmd += ['-B', bucket]
cmd += ['-b %s' % bot for bot in bots]
if options.revision: cmd += ['-r %s' % options.revision]
benchmarks = ['"%s"' % benchmark for benchmark in options.benchmarks]
cmd += ['-p \'testfilter=[%s]\'' % ','.join(benchmarks)]
if options.extra_flags:
cmd += ['-p \'extra_flags="%s"\'' % options.extra_flags]
subprocess.check_call(' '.join(cmd), shell=True, cwd=V8_BASE)
def main():
parser = argparse.ArgumentParser(description='')
parser.add_argument('benchmarks', nargs='+', help='The benchmarks to run.')
......@@ -89,14 +104,11 @@ def main():
subprocess.check_output(
'update_depot_tools', shell=True, stderr=subprocess.STDOUT, cwd=V8_BASE)
cmd = ['git cl try -m internal.client.v8']
cmd += ['-b %s' % bot for bot in options.bots]
if options.revision: cmd += ['-r %s' % options.revision]
benchmarks = ['"%s"' % benchmark for benchmark in options.benchmarks]
cmd += ['-p \'testfilter=[%s]\'' % ','.join(benchmarks)]
if options.extra_flags:
cmd += ['-p \'extra_flags="%s"\'' % options.extra_flags]
subprocess.check_call(' '.join(cmd), shell=True, cwd=V8_BASE)
buildbot_bots = [bot for bot in options.bots if bot not in SWARMING_BOTS]
_trigger_bots('master.internal.client.v8', buildbot_bots, options)
swarming_bots = [bot for bot in options.bots if bot in SWARMING_BOTS]
_trigger_bots('luci.v8-internal', swarming_bots, options)
if __name__ == '__main__': # pragma: no cover
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment