Stefan Scherfke  committed 9a9a281

Run each benchmark in a separate process. This way, the simpy module can be reimported to allow benchmarking multiple revisions in one run.

  • Participants
  • Parent commits 721cded
  • Branches default

Comments (0)

Files changed (1)


 # Don't change anything from here.
 import cProfile
+import multiprocessing
 import subprocess
 import sys
 import timeit
     sys.path.insert(0, repo)
     print('Running benchmarks for Rev. %s ...' % rev)
     for module, args in benchmarks:
-        run_benchmark(simpy, rev, module, args)
+        proc = multiprocessing.Process(target=run_benchmark,
+                                       args=(simpy, rev, module, args))
+        proc.start()
+        proc.join()
 def main():