From d22ab3d97a30780a930063b120ef3386aad8578e Mon Sep 17 00:00:00 2001 From: Florian Fischer Date: Wed, 16 Oct 2019 14:46:03 +0200 Subject: increase workload size for bigger max speedup with the current workload size of 100K allocations the parallel part (worker) takes on my development laptop 96% of the single threaded execution time resulting in a maximal speedup of 25. (Amdahl: 1/(1-0.96) ~= 25) Increasing the the workload to 1M allocations ups the parallel portion to ~99% which gives us a max speedup of ~295 enough for all our test machines. With the new workload the single threaded execution time is ~100s on my laptop and ~30s on one of the test servers which is tolerable in my opinion. --- src/benchmarks/falsesharing.py | 6 ++++-- src/benchmarks/falsesharing/Makefile | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/benchmarks/falsesharing.py b/src/benchmarks/falsesharing.py index 5debd94..a9c72b5 100644 --- a/src/benchmarks/falsesharing.py +++ b/src/benchmarks/falsesharing.py @@ -38,10 +38,10 @@ class BenchmarkFalsesharing(Benchmark): def __init__(self): name = "falsesharing" - self.cmd = "cache-{bench}{binary_suffix} {threads} 100 8 1000000" + self.cmd = "cache-{bench}{binary_suffix} {threads} 100 8 10000000" self.args = {"bench": ["thrash", "scratch"], - "threads": Benchmark.scale_threads_for_cpus(2)} + "threads": Benchmark.scale_threads_for_cpus(1)} self.requirements = ["cache-thrash", "cache-scratch"] super().__init__(name) @@ -84,12 +84,14 @@ class BenchmarkFalsesharing(Benchmark): ylabel="'l1 cache misses in %'", title="'cache misses: ' + arg + ' ' + str(arg_value)", filepostfix="l1-misses", + autoticks=False, fixed=["bench"]) self.plot_fixed_arg("({LLC-load-misses}/{LLC-loads})*100", ylabel="'llc cache misses in %'", title="'LLC misses: ' + arg + ' ' + str(arg_value)", filepostfix="llc-misses", + autoticks=False, fixed=["bench"]) diff --git a/src/benchmarks/falsesharing/Makefile b/src/benchmarks/falsesharing/Makefile index 763864a..2058b05 100644 --- a/src/benchmarks/falsesharing/Makefile +++ b/src/benchmarks/falsesharing/Makefile @@ -3,8 +3,8 @@ OBJDIR ?= obj CXX ?= g++ WARNFLAGS ?= -Wall -Wextra -COMMONFLAGS ?= -fno-builtin -fPIC -DPIC -pthread -OPTFLAGS ?= -O3 -DNDEBUG +COMMONFLAGS ?= -fno-builtin -fPIC -DPIC -pthread -g +OPTFLAGS ?= -O0 CXXFLAGS ?= $(OPTFLAGS) $(WARNFLAGS) $(COMMONFLAGS) -- cgit v1.2.3