benchmark silo added
[c11concurrency-benchmarks.git] / silo / benchmarks / plotter.py
diff --git a/silo/benchmarks/plotter.py b/silo/benchmarks/plotter.py
new file mode 100644 (file)
index 0000000..cf35280
--- /dev/null
@@ -0,0 +1,16 @@
+import matplotlib
+matplotlib.use('Agg')
+import pylab as plt
+
+import sys
+
+if __name__ == '__main__':
+  (_, fname, oname) = sys.argv
+  execfile(fname)
+  for name, data in zip(DBS, RESULTS):
+    plt.plot(THREADS, data)
+  plt.xlabel('num threads')
+  plt.ylabel('ops/sec')
+  plt.title('')
+  plt.legend(DBS, loc='lower right')
+  plt.savefig(oname)