Commit 75674d62 authored by Philippe SWARTVAGHER's avatar Philippe SWARTVAGHER
Browse files

FilesParser: sum thread values if general values aren't available

For memset when throughput is measured. Works well for bandwidth,
probably wrong for duration.
parent ef574907
......@@ -510,8 +510,23 @@ class FilesParser:
if compute_bench_type == Stream:
alone, with_comm = self._get_stream_results(lines[nb_header_lines-1:], nb_cores)
elif compute_bench_type == Memset:
alone, with_comm = self._get_bw_time_results(lines[nb_header_lines-1:], "memset", nb_cores)
alone_per_thread, with_comm_per_thread = self._get_bw_time_per_thread_results(lines[nb_header_lines-1:], "memset", run_params['nb_workers'])
alone, with_comm = self._get_bw_time_results(lines[nb_header_lines-1:], "memset", nb_cores)
# If we measured the throughput, there is no global results in
# the output of the benchmark, but the sum of bandwidth per
# thread can be considered as the global bandwidth
if len(alone_per_thread['memset'][CompMetric.BANDWIDTH]['min']) > 0 and alone['memset'][CompMetric.BANDWIDTH]['min'] is None:
alone['memset'] = {
m: {
k: sum(alone_per_thread['memset'][m][k]) for k in alone_per_thread['memset'][m]
} for m in alone_per_thread['memset']
if len(with_comm_per_thread['memset'][CompMetric.BANDWIDTH]['min']) > 0 and with_comm['memset'][CompMetric.BANDWIDTH]['min'] is None:
with_comm['memset'] = {
m: {
k: sum(with_comm_per_thread['memset'][m][k]) for k in with_comm_per_thread['memset'][m]
} for m in with_comm_per_thread['memset']
# elif compute_bench_type == "cholesky":
# file_data["computing"] = get_cholesky_results(lines, nb_cores)
# else:
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