summaryrefslogtreecommitdiff
path: root/SpMV/baselines/cpu/Makefile
diff options
context:
space:
mode:
authorDaniel Friesel <daniel.friesel@uos.de>2023-06-02 15:29:25 +0200
committerDaniel Friesel <daniel.friesel@uos.de>2023-06-02 15:29:25 +0200
commit39d1c972dcea37beca6e20be152a3da78143a7d3 (patch)
tree7ed0fbde0088a9d330da26db1f6890d903645529 /SpMV/baselines/cpu/Makefile
parentff9304370fdd94e9b7e4c4262c59ac734f1a28fd (diff)
port SpMV to dfatool; add benchmark scripts
Diffstat (limited to 'SpMV/baselines/cpu/Makefile')
-rw-r--r--SpMV/baselines/cpu/Makefile25
1 files changed, 21 insertions, 4 deletions
diff --git a/SpMV/baselines/cpu/Makefile b/SpMV/baselines/cpu/Makefile
index 9c63605..64b20db 100644
--- a/SpMV/baselines/cpu/Makefile
+++ b/SpMV/baselines/cpu/Makefile
@@ -1,7 +1,24 @@
-all:
- gcc -o spmv -fopenmp app.c
+all: spmv
-clean:
- rm spmv
+spmv: app.c
+ gcc -O2 -o spmv -fopenmp app.c
+
+spmv_O0: app.c
+ gcc -o spmv_O0 -fopenmp app.c
+
+spmv_O2: app.c
+ gcc -O2 -o spmv_O2 -fopenmp app.c
+
+run: spmv
+ OMP_NUM_THREADS=4 ./spmv -f ../../data/bcsstk30.mtx -v 0
+run_O0: spmv_O0
+ OMP_NUM_THREADS=4 ./spmv_O0 -f ../../data/bcsstk30.mtx -v 0
+
+run_O2: spmv_O2
+ OMP_NUM_THREADS=4 ./spmv_O2 -f ../../data/bcsstk30.mtx -v 0
+
+clean:
+ rm -f spmv spmv_O0 spmv_O2
+.PHONY: all run run_O0 run_O2 clean