aboutsummaryrefslogtreecommitdiff
path: root/src/benchmarks
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fl.fischer@fau.de>2020-04-07 15:54:25 +0200
committerFlorian Fischer <florian.fl.fischer@fau.de>2020-04-07 15:54:25 +0200
commitfe26e05dfba7b6c4a3e28b2be6dc369426277790 (patch)
treee724a1264ea3e1f07f327d6d27e0c5afafa09d23 /src/benchmarks
parent57d94cd47a4a5c187aed2245b0f213ba520f2405 (diff)
downloadallocbench-fe26e05dfba7b6c4a3e28b2be6dc369426277790.tar.gz
allocbench-fe26e05dfba7b6c4a3e28b2be6dc369426277790.zip
unify plotting code
Now there is only a single plot function which takes a plot type as well as some plot and figure options.
Diffstat (limited to 'src/benchmarks')
-rw-r--r--src/benchmarks/blowup.py13
-rw-r--r--src/benchmarks/cfrac.py39
-rw-r--r--src/benchmarks/dj_trace.py51
-rw-r--r--src/benchmarks/espresso.py40
-rw-r--r--src/benchmarks/falsesharing.py48
-rw-r--r--src/benchmarks/fd.py26
-rw-r--r--src/benchmarks/httpd.py48
-rw-r--r--src/benchmarks/keydb.py24
-rw-r--r--src/benchmarks/larson.py27
-rw-r--r--src/benchmarks/loop.py38
-rw-r--r--src/benchmarks/mysql.py72
-rw-r--r--src/benchmarks/raxmlng.py26
-rw-r--r--src/benchmarks/realloc.py12
-rw-r--r--src/benchmarks/redis.py26
-rw-r--r--src/benchmarks/t_test1.py27
15 files changed, 288 insertions, 229 deletions
diff --git a/src/benchmarks/blowup.py b/src/benchmarks/blowup.py
index 28692d6..a4e65ea 100644
--- a/src/benchmarks/blowup.py
+++ b/src/benchmarks/blowup.py
@@ -54,11 +54,14 @@ class BenchmarkBlowup(Benchmark):
}
}
- plt.barplot_single_arg(self,
- "{VmHWM}/1000",
- ylabel="VmHWM in MB",
- title="blowup test",
- file_postfix="vmhwm")
+ plt.plot(self,
+ "{VmHWM}/1000",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "VmHWM in MB",
+ 'title': "blowup test"
+ },
+ file_postfix="vmhwm")
plt.pgfplot(self,
self.iterate_args(self.results["args"]),
diff --git a/src/benchmarks/cfrac.py b/src/benchmarks/cfrac.py
index 9b4bc64..1f495e6 100644
--- a/src/benchmarks/cfrac.py
+++ b/src/benchmarks/cfrac.py
@@ -76,27 +76,36 @@ class BenchmarkCfrac(Benchmark):
def summary(self):
# Speed
- plt.barplot_single_arg(self,
- "{task-clock}/1000",
- ylabel='"cpu-second"',
- title='"Cfrac: runtime"',
- file_postfix="time")
+ plt.plot(self,
+ "{task-clock}/1000",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': 'cpu-second',
+ 'title': 'Cfrac: runtime',
+ },
+ file_postfix="time")
# L1 cache misses
- plt.barplot_single_arg(
+ plt.plot(
self,
"({L1-dcache-load-misses}/{L1-dcache-loads})*100",
- ylabel="L1 misses in %",
- title="Cfrac l1 cache misses",
- file_postfix="l1misses",
- yerr=False)
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "L1 misses in %",
+ 'title': "Cfrac l1 cache misses",
+ 'yerr': False
+ },
+ file_postfix="l1misses")
# Memusage
- plt.barplot_single_arg(self,
- "{VmHWM}",
- ylabel="VmHWM in KB",
- title="Cfrac VmHWM",
- file_postfix="vmhwm")
+ plt.plot(self,
+ "{VmHWM}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "VmHWM in KB",
+ 'title': "Cfrac VmHWM",
+ },
+ file_postfix="vmhwm")
plt.write_tex_table(self, [{
"label": "Runtime [ms]",
diff --git a/src/benchmarks/dj_trace.py b/src/benchmarks/dj_trace.py
index b6ae83d..1b1c65e 100644
--- a/src/benchmarks/dj_trace.py
+++ b/src/benchmarks/dj_trace.py
@@ -173,34 +173,14 @@ class BenchmarkDJTrace(Benchmark):
args = self.results["args"]
allocators = self.results["allocators"]
- cpu_time_means = {allocator: {} for allocator in allocators}
- cycles_means = {allocator: {} for allocator in allocators}
- for perm in self.iterate_args(args=args):
- for i, allocator in enumerate(allocators):
- data = [x["cputime"] for x in self.results[allocator][perm]]
- # data is in milliseconds
- cpu_time_means[allocator][perm] = np.mean(data) / 1000
-
- data = [x["cycles"] for x in self.results[allocator][perm]]
- cycles_means[allocator][perm] = np.mean(data)
-
- plt.bar([i],
- cpu_time_means[allocator][perm],
- label=allocator,
- color=allocators[allocator]["color"])
-
- plt.legend(loc="best")
- plt.ylabel("time in ms")
- plt.title(f"Runtime {perm.workload}")
- plt.savefig(".".join(
- [self.name, perm.workload, "runtime", summary_file_ext]))
- plt.clf()
-
- abplt.barplot_single_arg(self,
- "{cputime}/1000",
- ylabel="time in ms",
- title="total runtime",
- file_postfix="runtime")
+ abplt.plot(self,
+ "{cputime}/1000",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "time in ms",
+ 'title': "total runtime",
+ },
+ file_postfix="runtime")
# Function Times
func_times_means = {allocator: {} for allocator in allocators}
@@ -258,11 +238,14 @@ class BenchmarkDJTrace(Benchmark):
}
}
- abplt.barplot_single_arg(self,
- "{Max_RSS}/1000",
- ylabel="Max RSS in MB",
- title="Max RSS (VmHWM)",
- file_postfix="newrss")
+ abplt.plot(self,
+ "{Max_RSS}/1000",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "Max RSS in MB",
+ 'title': "Max RSS (VmHWM)",
+ }
+ file_postfix="newrss")
# self.barplot_fixed_arg("{Max_RSS}/1000",
# ylabel='"Max RSS in MB"',
@@ -394,7 +377,7 @@ class BenchmarkDJTrace(Benchmark):
file=f)
for perm in self.iterate_args(args=args):
- cycles = cycles_means[allocator][perm]
+ cycles = abplt._get_y_data(self, "{cycles}", allocator, perm)[0]
times = [t for t in func_times_means[allocator][perm]]
rss = rss_means[allocator][perm]
print(fmt.format(perm.workload, cycles, times[0], times[1],
diff --git a/src/benchmarks/espresso.py b/src/benchmarks/espresso.py
index 6012d02..b0b9c09 100644
--- a/src/benchmarks/espresso.py
+++ b/src/benchmarks/espresso.py
@@ -80,27 +80,33 @@ class BenchmarkEspresso(Benchmark):
def summary(self):
# Speed
- plt.barplot_single_arg(self,
- "{task-clock}/1000",
- ylabel="cpu-second",
- title="Espresso: runtime",
- file_postfix="time")
+ plt.plot(self,
+ "{task-clock}/1000",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "cpu-second",
+ 'title': "Espresso: runtime",
+ },
+ file_postfix="time")
# L1 cache misses
- plt.barplot_single_arg(
- self,
- "({L1-dcache-load-misses}/{L1-dcache-loads})*100",
- ylabel="L1 misses in %",
- title="Espresso l1 cache misses",
- file_postfix="l1misses",
- yerr=False)
+ plt.plot(self,
+ "({L1-dcache-load-misses}/{L1-dcache-loads})*100",
+ fig_options={
+ 'ylabel': "L1 misses in %",
+ 'title': "Espresso l1 cache misses",
+ 'yerr': False
+ },
+ file_postfix="l1misses")
# Memusage
- plt.barplot_single_arg(self,
- "{VmHWM}",
- ylabel="VmHWM in KB",
- title="Espresso VmHWM",
- file_postfix="vmhwm")
+ plt.plot(self,
+ "{VmHWM}",
+ fig_options={
+ 'ylabel': "VmHWM in KB",
+ 'title': "Espresso VmHWM",
+ }
+ file_postfix="vmhwm")
plt.write_tex_table(self, [{
"label": "Runtime [ms]",
diff --git a/src/benchmarks/falsesharing.py b/src/benchmarks/falsesharing.py
index 5c18367..6735aa4 100644
--- a/src/benchmarks/falsesharing.py
+++ b/src/benchmarks/falsesharing.py
@@ -62,8 +62,7 @@ class BenchmarkFalsesharing(Benchmark):
for allocator in allocators:
sequential_perm = self.Perm(bench=bench, threads=1)
- for perm in self.iterate_args_fixed({"bench": bench},
- args=args):
+ for perm in self.iterate_args({"bench": bench}, args=args):
speedup = []
l1chache_misses = []
for i, measure in enumerate(self.results[allocator][perm]):
@@ -79,30 +78,25 @@ class BenchmarkFalsesharing(Benchmark):
del self.results["stats"]
self.calc_desc_statistics()
- plt.plot_fixed_arg(self,
- "{speedup}",
- ylabel="Speedup",
- title="Speedup: {arg} {arg_value}",
- file_postfix="speedup",
- autoticks=False,
- fixed=["bench"])
-
- plt.plot_fixed_arg(
- self,
- "{l1chache_misses}",
- ylabel="l1 cache misses in %",
- title="cache misses: {arg} {arg_value}",
- file_postfix="l1-misses",
- autoticks=False,
- fixed=["bench"])
-
- # plt.plot_fixed_arg(self,
- # "({LLC-load-misses}/{LLC-loads})*100",
- # ylabel="llc cache misses in %",
- # title="LLC misses: {arg} {arg_value}",
- # file_postfix="llc-misses",
- # autoticks=False,
- # fixed=["bench"])
+ plt.plot(self,
+ "{speedup}",
+ x_args=["bench"],
+ fig_options={
+ 'ylabel': "Speedup",
+ 'title': "Speedup: {arg} {arg_value}",
+ 'autoticks': False,
+ },
+ file_postfix="speedup")
+
+ plt.plot(self,
+ "{l1chache_misses}",
+ x_args=["bench"]
+ fig_options={
+ 'ylabel': "l1 cache misses in %",
+ 'title': "cache misses: {arg} {arg_value}",
+ 'autoticks': False,
+ },
+ file_postfix="l1-misses")
plt.write_tex_table(self, [{
"label": "Speedup",
@@ -117,7 +111,7 @@ class BenchmarkFalsesharing(Benchmark):
# pgfplots
for bench in args["bench"]:
plt.pgfplot(self,
- self.iterate_args_fixed({"bench": bench}, args=args),
+ self.iterate_args({"bench": bench}, args=args),
"int(perm.threads)",
"{speedup}",
xlabel="Threads",
diff --git a/src/benchmarks/fd.py b/src/benchmarks/fd.py
index 6f88878..1fdd96a 100644
--- a/src/benchmarks/fd.py
+++ b/src/benchmarks/fd.py
@@ -67,19 +67,25 @@ class BenchmarkFd(Benchmark):
os.link(src, dest)
def summary(self):
- plt.barplot_single_arg(self,
- "{task-clock}",
- ylabel="runtime in ms",
- title="fd runtime",
- file_postfix="runtime")
+ plt.plot(self,
+ "{task-clock}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "runtime in ms",
+ 'title': "fd runtime",
+ },
+ file_postfix="runtime")
plt.export_stats_to_dataref(self, "task-clock")
- plt.barplot_single_arg(self,
- "{VmHWM}",
- ylabel="VmHWM in KB",
- title="fd memusage",
- file_postfix="memusage")
+ plt.plot(self,
+ "{VmHWM}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': "VmHWM in KB",
+ 'title': "fd memusage"
+ },
+ file_postfix="memusage")
plt.export_stats_to_dataref(self, "VmHWM")
diff --git a/src/benchmarks/httpd.py b/src/benchmarks/httpd.py
index 8332f27..c46461f 100644
--- a/src/benchmarks/httpd.py
+++ b/src/benchmarks/httpd.py
@@ -60,29 +60,35 @@ class BenchmarkHTTPD(Benchmark):
"Requests per second:\\s*(\\d*\\.\\d*) .*", stdout).group(1)
def summary(self):
- plt.plot_fixed_arg(self,
- "{requests}",
- xlabel="threads",
- ylabel="requests/s",
- autoticks=False,
- file_postfix="requests",
- title="{perm.site}: requests/s")
+ plt.plot(self,
+ "{requests}",
+ fig_options={
+ 'xlabel': "threads",
+ 'ylabel': "requests/s",
+ 'title': "{perm.site}: requests/s"
+ 'autoticks': False,
+ },
+ file_postfix="requests")
- plt.plot_fixed_arg(self,
- "{nginx_vmhwm}",
- xlabel="threads",
- ylabel="VmHWM in KB",
- title="{perm.site}: nginx memory usage",
- file_postfix="httpd_vmhwm",
- autoticks=False)
+ plt.plot(self,
+ "{nginx_vmhwm}",
+ fig_options={
+ 'xlabel': "threads",
+ 'ylabel': "VmHWM in KB",
+ 'title': "{perm.site}: nginx memory usage",
+ 'autoticks': False,
+ },
+ file_postfix="httpd_vmhwm")
- plt.plot_fixed_arg(self,
- "{php-fpm_vmhwm}",
- xlabel="threads",
- ylabel="VmHWM in KB",
- title="{perm.site}: php-fpm memory usage",
- file_postfix="php-fpm_vmhwm",
- autoticks=False)
+ plt.plot(self,
+ "{php-fpm_vmhwm}",
+ fig_options={
+ 'xlabel': "threads",
+ 'ylabel': "VmHWM in KB",
+ 'title': "{perm.site}: php-fpm memory usage",
+ 'autoticks': False,
+ },
+ file_postfix="php-fpm_vmhwm")
httpd = BenchmarkHTTPD()
diff --git a/src/benchmarks/keydb.py b/src/benchmarks/keydb.py
index 343d356..8502e21 100644
--- a/src/benchmarks/keydb.py
+++ b/src/benchmarks/keydb.py
@@ -110,14 +110,20 @@ class BenchmarkKeyDB(Benchmark):
os.remove("dump.rdb")
def summary(self):
- plt.plot_fixed_arg(self, "{totals_ops}",
- ylabel="'OPS/second'",
- title="KeyDB Operations - {arg}: {arg_value}",
- file_postfix="total_ops")
-
- plt.plot_fixed_arg(self, "{keydb_vmhwm}",
- ylabel="'VmHWM [KB]'",
- title="KeyDB Memusage - {arg}: {arg_value}",
- file_postfix="vmhwm")
+ plt.plot(self,
+ "{totals_ops}",
+ fig_options={
+ 'ylabel': "'OPS/second'",
+ 'title': "KeyDB Operations - {arg}: {arg_value}",
+ },
+ file_postfix="total_ops")
+
+ plt.plot(self,
+ "{keydb_vmhwm}",
+ fig_options={
+ 'ylabel': "'VmHWM [KB]'",
+ 'title': "KeyDB Memusage - {arg}: {arg_value}",
+ },
+ file_postfix="vmhwm")
keydb = BenchmarkKeyDB()
diff --git a/src/benchmarks/larson.py b/src/benchmarks/larson.py
index d2e9286..db38789 100644
--- a/src/benchmarks/larson.py
+++ b/src/benchmarks/larson.py
@@ -81,18 +81,21 @@ class BenchmarkLarson(Benchmark):
def summary(self):
# Plot threads->throughput and maxsize->throughput
- plt.plot_fixed_arg(self,
- "{throughput}/1000000",
- ylabel="MOPS/s",
- title="Larson: {arg} {arg_value}",
- file_postfix="throughput")
-
- plt.plot_fixed_arg(
- self,
- "({L1-dcache-load-misses}/{L1-dcache-loads})*100",
- ylabel="l1 cache misses in %",
- title="Larson cache misses: {arg} {arg_value}",
- file_postfix="cachemisses")
+ plt.plot(self,
+ "{throughput}/1000000",
+ fig_options={
+ 'ylabel': "MOPS/s",
+ 'title': "Larson: {arg} {arg_value}",
+ },
+ file_postfix="throughput")
+
+ plt.plot(self,
+ "({L1-dcache-load-misses}/{L1-dcache-loads})*100",
+ fig_options={
+ 'ylabel': "l1 cache misses in %",
+ 'title': "Larson cache misses: {arg} {arg_value}",
+ },
+ file_postfix="cachemisses")
larson = BenchmarkLarson()
diff --git a/src/benchmarks/loop.py b/src/benchmarks/loop.py
index 81d55cb..3c9bbac 100644
--- a/src/benchmarks/loop.py
+++ b/src/benchmarks/loop.py
@@ -61,19 +61,20 @@ class BenchmarkLoop(Benchmark):
def summary(self):
# Speed
- plt.plot_fixed_arg(self,
- "{mops}",
- ylabel="MOPS/cpu-second",
- title="Loop: {arg} {arg_value}",
- file_postfix="time",
- autoticks=False)
+ plt.plot(
+ self,
+ "{mops}",
+ ylabel="MOPS/cpu-second",
+ title="Loop: {fixed_part_str}",
+ file_postfix="time",
+ autoticks=False)
# L1 cache misses
- plt.plot_fixed_arg(
+ plt.plot(
self,
"({L1-dcache-load-misses}/{L1-dcache-loads})*100",
ylabel="L1 misses in %",
- title="Loop l1 cache misses: {arg} {arg_value}",
+ title="Loop l1 cache misses: {fixed_part_str}",
file_postfix="l1misses",
autoticks=False)
@@ -83,20 +84,21 @@ class BenchmarkLoop(Benchmark):
"{mops}",
file_postfix="time.matrix")
- plt.write_tex_table(self, [{
- "label": "MOPS/s",
- "expression": "{mops}",
- "sort": ">"
- }],
- file_postfix="mops.table")
+ plt.write_tex_table(
+ self,
+ [{
+ "label": "MOPS/s",
+ "expression": "{mops}",
+ "sort": ">"
+ }],
+ file_postfix="mops.table")
- # plt.export_stats_to_csv(self, "task-clock")
- # plt.export_stats_to_dataref(self, "task-clock")
+ plt.export_stats_to_csv(self, "task-clock")
+ plt.export_stats_to_dataref(self, "task-clock")
# pgfplot test
plt.pgfplot(self,
- self.iterate_args_fixed({"maxsize": 1024},
- args=self.results["args"]),
+ self.iterate_args({"maxsize": 1024}, self.results["args"]),
"int(perm.threads)",
"{mops}",
xlabel="Threads",
diff --git a/src/benchmarks/mysql.py b/src/benchmarks/mysql.py
index a5b215c..0df85d2 100644
--- a/src/benchmarks/mysql.py
+++ b/src/benchmarks/mysql.py
@@ -201,42 +201,60 @@ class BenchmarkMYSQL(Benchmark):
args = self.results["args"]
# linear plot
- plt.plot_single_arg(self, "{transactions}",
- xlabel='"threads"',
- ylabel='"transactions"',
- title='"sysbench oltp read only"',
- file_postfix="l")
+ plt.plot(self,
+ "{transactions}",
+ fig_options={
+ 'xlabel': 'threads',
+ 'ylabel': 'transactions',
+ 'title': 'sysbench oltp read only',
+ },
+ file_postfix="l")
# normalized linear plot
ref_alloc = list(allocators)[0]
- plt.plot_single_arg(self, "{transactions}",
- xlabel='"threads"',
- ylabel='"transactions scaled at " + scale',
- title='"sysbench oltp read only"',
- file_postfix="norm.l",
- scale=ref_alloc)
+ plt.plot(self,
+ "{transactions}",
+ fig_options={
+ 'xlabel': 'threads',
+ 'ylabel': 'transactions scaled at {scale}',
+ 'title': 'sysbench oltp read only',
+ },
+ file_postfix="norm.l",
+ scale=ref_alloc)
# bar plot
- plt.barplot_single_arg(self, "{transactions}",
- xlabel='"threads"',
- ylabel='"transactions"',
- title='"sysbench oltp read only"',
- file_postfix="b")
+ plt.plot(self,
+ "{transactions}",
+ plot_type='bar',
+ fig_options={
+ 'xlabel': 'threads',
+ 'ylabel': 'transactions',
+ 'title': 'sysbench oltp read only',
+ },
+ file_postfix="b")
# normalized bar plot
- plt.barplot_single_arg(self, "{transactions}",
- xlabel='"threads"',
- ylabel='"transactions scaled at " + scale',
- title='"sysbench oltp read only"',
- file_postfix="norm.b",
- scale=ref_alloc)
+ plt.plot(self,
+ "{transactions}",
+ plot_type='bar',
+ fig_options={
+ 'xlabel': 'threads',
+ 'ylabel': 'transactions scaled at {scale}',
+ 'title': 'sysbench oltp read only',
+ },
+ file_postfix="norm.b",
+ scale=ref_alloc)
# Memusage
- plt.barplot_single_arg(self, "{mysqld_vmhwm}",
- xlabel='"threads"',
- ylabel='"VmHWM in kB"',
- title='"Memusage sysbench oltp read only"',
- file_postfix="mem")
+ plt.plot(self,
+ "{mysqld_vmhwm}",
+ plot_type='bar',
+ fig_options={
+ 'xlabel': 'threads',
+ 'ylabel': 'VmHWM in kB',
+ 'title': 'Memusage sysbench oltp read only',
+ },
+ file_postfix="mem")
plt.write_tex_table(self, [{
"label": "Transactions",
diff --git a/src/benchmarks/raxmlng.py b/src/benchmarks/raxmlng.py
index 8c8b878..ef77d2d 100644
--- a/src/benchmarks/raxmlng.py
+++ b/src/benchmarks/raxmlng.py
@@ -82,19 +82,25 @@ class BenchmarkRaxmlng(Benchmark):
result["runtime"] = RUNTIME_RE.search(stdout).group("runtime")
def summary(self):
- plt.barplot_single_arg(self,
- "{runtime}",
- ylabel='"runtime in s"',
- title='"raxml-ng tree inference benchmark"',
- file_postfix="runtime")
+ plt.plot(self,
+ "{runtime}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': 'runtime in s',
+ 'title': 'raxml-ng tree inference benchmark',
+ },
+ file_postfix="runtime")
plt.export_stats_to_dataref(self, "runtime")
- plt.barplot_single_arg(self,
- "{VmHWM}",
- ylabel='"VmHWM in KB"',
- title='"raxml-ng memusage"',
- file_postfix="memusage")
+ plt.plot(self,
+ "{VmHWM}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': 'VmHWM in KB',
+ 'title': 'raxml-ng memusage',
+ },
+ file_postfix="memusage")
plt.export_stats_to_dataref(self, "VmHWM")
diff --git a/src/benchmarks/realloc.py b/src/benchmarks/realloc.py
index bd8f801..d3375ff 100644
--- a/src/benchmarks/realloc.py
+++ b/src/benchmarks/realloc.py
@@ -34,10 +34,14 @@ class BenchmarkRealloc(Benchmark):
super().__init__(name)
def summary(self):
- plt.barplot_single_arg(self, "{task-clock}",
- ylabel='"task-clock in ms"',
- title='"realloc micro benchmark"',
- file_postfix="time")
+ plt.plot(self,
+ "{task-clock}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': 'task-clock in ms',
+ 'title': 'realloc micro benchmark',
+ },
+ file_postfix="time")
plt.export_stats_to_csv(self, "task-clock")
plt.export_stats_to_dataref(self, "task-clock")
diff --git a/src/benchmarks/redis.py b/src/benchmarks/redis.py
index cfad489..265d825 100644
--- a/src/benchmarks/redis.py
+++ b/src/benchmarks/redis.py
@@ -81,15 +81,23 @@ class BenchmarkRedis(Benchmark):
os.remove("dump.rdb")
def summary(self):
- plt.barplot_single_arg(self, "{requests}",
- ylabel='"requests per s"',
- title='"redis throughput"',
- file_postfix="requests")
-
- plt.barplot_single_arg(self, "{redis_vmhwm}",
- ylabel='"VmHWM in KB"',
- title='"redis memusage"',
- file_postfix="vmhwm")
+ plt.plot(self,
+ "{requests}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': 'requests per s',
+ 'title': 'redis throughput',
+ },
+ file_postfix="requests")
+
+ plt.plot(self,
+ "{redis_vmhwm}",
+ plot_type='bar',
+ fig_options={
+ 'ylabel': '"VmHWM in KB"',
+ 'title': '"redis memusage"',
+ },
+ file_postfix="vmhwm")
plt.export_stats_to_dataref(self, "requests")
diff --git a/src/benchmarks/t_test1.py b/src/benchmarks/t_test1.py
index f0856f6..2d86bdc 100644
--- a/src/benchmarks/t_test1.py
+++ b/src/benchmarks/t_test1.py
@@ -42,19 +42,24 @@ class BenchmarkTTest1(Benchmark):
# mops / per second
yval = "perm.nthreads / ({task-clock}/1000)"
# Speed
- plt.plot_fixed_arg(self, yval,
- ylabel='"Mops / CPU second"',
- title='"T-Ttest1: " + arg + " " + str(arg_value)',
- file_postfix="time",
- autoticks=False)
+ plt.plot(self,
+ yval,
+ fig_options={
+ 'ylabel': 'Mops / CPU second',
+ 'title': 't-test1: {fixed_part_str}',
+ 'autoticks': False,
+ },
+ file_postfix="time")
# L1 cache misses
- plt.plot_fixed_arg(self,
+ plt.plot(self,
"({L1-dcache-load-misses}/{L1-dcache-loads})*100",
- ylabel='"L1 misses in %"',
- title='"T-Test1 l1 cache misses: " + arg + " " + str(arg_value)',
- file_postfix="l1misses",
- autoticks=False)
+ fig_options={
+ 'ylabel': 'L1 misses in %',
+ 'title': 't-test1 l1 cache misses: {fixed_part_str}',
+ 'autoticks': False,
+ },
+ file_postfix="l1misses")
# Speed Matrix
plt.write_best_doublearg_tex_table(self, yval, file_postfix="mops.matrix")
@@ -64,7 +69,7 @@ class BenchmarkTTest1(Benchmark):
"expression": yval,
"sort": ">"
}],
- file_postfix="mops.table")
+ file_postfix="mops.table")
plt.export_stats_to_csv(self, "task-clock")