Skip to content

Instantly share code, notes, and snippets.

@mgiacomini
Created November 18, 2017 19:32
Show Gist options
  • Save mgiacomini/a8c50041d1312e8789cd73c964089d46 to your computer and use it in GitHub Desktop.
Save mgiacomini/a8c50041d1312e8789cd73c964089d46 to your computer and use it in GitHub Desktop.
results
#!/bin/bash
echo "#####" >> result.txt
echo "L3 Bandwidth" >> result.txt
for i in 32 33 64 65 128 129 256 257 512 1000 2000
do
echo $i >> result.txt
likwid-perfctr -f -C 0 -g L3 -m ./invmat -i 10 -r $i -o saida.txt | grep "L3 bandwidth" >> result.txt
#likwid-perfctr -f -C 0 -g L3 ./cgSolver $num 7 -i 10 -o saida.txt
# head -n10 saida.txt | grep Tempo >> timer.txt
done
echo "#####" >> result.txt
echo "L2 CACHE" >> result.txt
for i in 32 33 64 65 128 129 256 257 512 1000 2000
do
echo $i >> result.txt
likwid-perfctr -f -C 0 -g L2CACHE -m ./invmat -i 10 -r $i -o saida.txt | grep "ratio" >> result.txt
#likwid-perfctr -f -C 0 -g L2CACHE ./cgSolver $num 7 -i 10 -o saida.txt
# head -n10 saida.txt | grep Tempo >> timer.txt
done
echo "#####" >> result.txt
echo "FLOPS_AVX" >> result.txt
for i in 32 33 64 65 128 129 256 257 512 1000 2000
do
echo $i >> result.txt
likwid-perfctr -f -C 0 -g FLOPS_AVX -m ./invmat -i 10 -r $i -o saida.txt | grep "MFLOP/s" >> result.txt
#likwid-perfctr -f -C 0 -g FLOPS_DP ./cgSolver $num 7 -i 10 -o saida.txt
# head -n10 saida.txt | grep Tempo >> timer.txt
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment