Commit e4b6e02c authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Merge pull request #25 from dbrabera/extended_benchmark_summary

Strip binaries in benchmarks
parents 164cd109 4eed812e
......@@ -41,8 +41,8 @@ def benchmark(testfolder):
result = {
"name": testfolder[:-1],
"size": {
"ada": os.path.getsize(llvm_bin),
"llvm": os.path.getsize(ada_bin),
"ada": size(llvm_bin),
"llvm": size(ada_bin),
},
"time": {
"ada": time(ada_bin),
......@@ -53,6 +53,11 @@ def benchmark(testfolder):
return result
def size(file):
call(["strip", os.path.abspath(file)])
return os.path.getsize(file)
def time(file, iters=1000):
start = t.time()
call(["/bin/bash", "-c", "for i in {1..%s} ; do %s ; done" % (iters, file)])
......
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