[pypy-svn] r40079 - pypy/dist/pypy/translator/benchmark
mwh at codespeak.net
mwh at codespeak.net
Thu Mar 8 17:28:10 CET 2007
Author: mwh
Date: Thu Mar 8 17:28:09 2007
New Revision: 40079
Modified:
pypy/dist/pypy/translator/benchmark/bench-custom.py
Log:
save the pickle and print the table after every benchmark run, not just after
--runcount runs.
Modified: pypy/dist/pypy/translator/benchmark/bench-custom.py
==============================================================================
--- pypy/dist/pypy/translator/benchmark/bench-custom.py (original)
+++ pypy/dist/pypy/translator/benchmark/bench-custom.py Thu Mar 8 17:28:09 2007
@@ -44,24 +44,25 @@
if not options.nocpython:
exes = full_pythons + exes
- for i in range(int(options.runcount)):
- for exe in exes:
- for b in benchmarks:
- benchmark_result.result(exe, allowcreate=True).run_benchmark(b, verbose=True)
+ for i in range(int(options.runcount)) + [None]:
+ if i is not None:
+ for exe in exes:
+ for b in benchmarks:
+ benchmark_result.result(exe, allowcreate=True).run_benchmark(b, verbose=True)
- pickle.dump(benchmark_result, open(options.picklefile, 'wb'))
+ pickle.dump(benchmark_result, open(options.picklefile, 'wb'))
- stats = ['stat:st_mtime', 'exe_name', 'pypy_rev']
- for b in benchmarks:
- stats.append('bench:'+b.name)
- if options.relto:
- relto = options.relto
- else:
- relto = full_pythons[0]
- for row in benchmark_result.txt_summary(stats,
- relto=relto,
- filteron=lambda r: r.exe_name in exes):
- print row
+ stats = ['stat:st_mtime', 'exe_name', 'pypy_rev']
+ for b in benchmarks:
+ stats.append('bench:'+b.name)
+ if options.relto:
+ relto = options.relto
+ else:
+ relto = full_pythons[0]
+ for row in benchmark_result.txt_summary(stats,
+ relto=relto,
+ filteron=lambda r: r.exe_name in exes):
+ print row
if __name__ == '__main__':
from optparse import OptionParser
More information about the Pypy-commit
mailing list