Skip to content

Commit

Permalink
Run the startup benchs 1K times per iteration, otherwise there's too …
Browse files Browse the repository at this point in the history
…little precision.
  • Loading branch information
poletti-marco committed Sep 10, 2018
1 parent f95443b commit 6e473ef
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions extras/benchmark/run_benchmarks.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,10 +301,12 @@ def run_runtime_benchmark(self):
return parse_results(results.splitlines())

def run_startup_benchmark(self):
N=1000
start = timer()
run_command(self.tmpdir + '/main', args = [])
for i in range(0, N):
run_command(self.tmpdir + '/main', args = [])
end = timer()
result = {'startup_time': end - start}
result = {'startup_time': (end - start) / N}
return result

def run_executable_size_benchmark(self):
Expand Down

0 comments on commit 6e473ef

Please sign in to comment.