Author: Remi Meier <[email protected]>
Branch: multithread-runner
Changeset: r367:8b3d8eca2c1b
Date: 2016-06-02 15:56 +0200
http://bitbucket.org/pypy/benchmarks/changeset/8b3d8eca2c1b/
Log: add retrying to runner.py
diff --git a/multithread/runner.py b/multithread/runner.py
--- a/multithread/runner.py
+++ b/multithread/runner.py
@@ -10,6 +10,7 @@
from subprocess import Popen, PIPE
WITH_NUMACTL = True
+MAX_RETRY = 100 # per bench
def extract_iter_times(stdout):
for line in stdout.split('\n'):
@@ -26,8 +27,10 @@
failures = []
timings = []
+ retries = 0
for ts in threads:
- for vm in range(vmstarts):
+ vm = 0
+ while vm < vmstarts:
print "threads: %s, vm: %s" % (ts, vm)
bench_file = os.path.abspath(bench_config['file'])
@@ -68,6 +71,10 @@
}
failures.append(failure)
print "failure:", failure
+ if retries < MAX_RETRY:
+ print "RETRY"
+ retries += 1
+ continue # w/o incrementing 'vm'
else:
stdout, stderr = p.stdout.read(), p.stderr.read()
print stdout
@@ -89,6 +96,7 @@
failures.append({
'cmd': cmd_str, 'exception': 'KeyboardInterrupt'})
return failures, timings
+ vm += 1
return failures, timings
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit