Use shell to redirect a few big files

pull/9699/head
Craig Tiller 8 years ago
parent 4e8b136faf
commit a48e690498
  1. 8
      tools/run_tests/run_microbenchmark.py

@ -133,11 +133,9 @@ def collect_perf(bm_name, args):
'bins/mutrace/%s' % bm_name, 'bins/mutrace/%s' % bm_name,
'--benchmark_filter=^%s$' % line, '--benchmark_filter=^%s$' % line,
'--benchmark_min_time=20']) '--benchmark_min_time=20'])
with open('bm.perf', 'w') as f: subprocess.check_call(['sudo', 'perf', 'script', '-i', 'perf.data', '>', 'bm.perf'], shell=True)
f.write(subprocess.check_output(['sudo', 'perf', 'script', '-i', 'perf.data'])) subprocess.check_call([
with open('bm.folded', 'w') as f: '%s/stackcollapse-perf.pl' % flamegraph_dir, 'bm.perf', '>', 'bm.folded'], shell=True)
f.write(subprocess.check_output([
'%s/stackcollapse-perf.pl' % flamegraph_dir, 'bm.perf']))
link(line, '%s.svg' % fnize(line)) link(line, '%s.svg' % fnize(line))
with open('reports/%s.svg' % fnize(line), 'w') as f: with open('reports/%s.svg' % fnize(line), 'w') as f:
f.write(subprocess.check_output([ f.write(subprocess.check_output([

Loading…
Cancel
Save