diff options
author | Birte Kristina Friesel <birte.friesel@uos.de> | 2025-05-16 14:15:10 +0200 |
---|---|---|
committer | Birte Kristina Friesel <birte.friesel@uos.de> | 2025-05-16 14:15:39 +0200 |
commit | 3e9a46a8b16668ed69f2b8a155246e8878e1ca2a (patch) | |
tree | c44677aa5945458463a80348f9129d821d293d7f /Microbenchmarks/CPU-DPU/benchmark-scripts | |
parent | 20f20b7bd24a70fde8074af42bb5d1c18996081c (diff) |
CPU-DPU: determine overhead of data transformation
Diffstat (limited to 'Microbenchmarks/CPU-DPU/benchmark-scripts')
-rwxr-xr-x | Microbenchmarks/CPU-DPU/benchmark-scripts/upvec-transformation.sh | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/Microbenchmarks/CPU-DPU/benchmark-scripts/upvec-transformation.sh b/Microbenchmarks/CPU-DPU/benchmark-scripts/upvec-transformation.sh new file mode 100755 index 0000000..ee5ee99 --- /dev/null +++ b/Microbenchmarks/CPU-DPU/benchmark-scripts/upvec-transformation.sh @@ -0,0 +1,35 @@ +#!/bin/bash + +mkdir -p log/$(hostname) + +./make-size.sh 0 + +run_benchmark_nmc() { + local "$@" + set -e + sudo limit_ranks_to_numa_node ${numa_rank} + make -B NR_RANKS=${nr_ranks} NR_TASKLETS=1 BL=10 TRANSFER=PUSH NUMA=1 + bin/host_code -a $numa_in -b $numa_out -c $numa_cpu -w 0 -e 20 -x 0 -N 0 -I $(size -A bin/dpu_code | awk '($1 == ".text") {print $2/8}') -i ${input_size} + return $? +} + +export -f run_benchmark_nmc + +# The benchmark allocates 3 * 64 * nr_ranks * 8B * input_size (one array for input, one array for output). +# With 1048576 elements (8 MiB per DPU), this gives a maximum allocation of 60 GiB, which will fit comfortably into system memory (128 GiB). +# With 2097152 elements (16 MiB per DPU), we may encounter OoM conditions, since the UPMEM SDK also allocates some memory. + +for sdk in 2025.1.0-orig 2025.1.0-notransform; do + source /opt/upmem/transformation-benchmarks/${sdk}/upmem_env.sh + fn=log/$(hostname)/upvec-${sdk} + + parallel -j1 --eta --joblog ${fn}.joblog --resume --header : \ + run_benchmark_nmc nr_ranks={nr_ranks} numa_rank={numa_rank} numa_in={numa_in} numa_out={numa_out} numa_cpu={numa_cpu} input_size={input_size} \ + ::: numa_rank any \ + ::: numa_in 1 \ + ::: numa_out 1 \ + ::: numa_cpu 1 \ + ::: nr_ranks $(seq 1 40) \ + ::: input_size 1048576 \ + >> ${fn}.txt +done |