add The Big Benchmark as a shell script
[xonotic/xonotic.git] / the-big-benchmark.sh
1 #!/bin/sh
2
3 set -e
4
5 echo "The Big Benchmark"
6 echo " ================="
7 echo
8 echo "WARNING: running this script will destroy ANY local changes you"
9 echo "might have on the repository."
10 echo
11 echo "Are you absolutely sure you want to run this?"
12 echo
13 while :; do
14         echo -n "y/n: "
15         read -r yesno
16         case "$yesno" in
17                 y)
18                         break
19                         ;;
20                 n)
21                         echo "Aborted."
22                         exit 1
23                         ;;
24         esac
25 done
26
27 set -x
28 ./all clean --reclone
29 ./all compile -r
30 ./all run -nohome -benchmarkruns 3 -benchmark demos/the-big-keybench.dem +//div0-stable
31 ./all clean --reclone
32 (
33         cd darkplaces
34         git checkout master || git checkout -t origin/master || exit 1
35 )
36 ./all compile -r
37 ./all run -nohome -benchmarkruns 3 -benchmark demos/the-big-keybench.dem +//master
38 ./all clean --reclone
39
40 echo
41 echo "Please provide the the following info to the Xonotic developers:"
42 echo " - CPU speed"
43 echo " - memory size"
44 echo " - graphics card (which vendor, which model)"
45 echo " - operating system (including whether it is 32bit or 64bit)"
46 echo " - graphics driver version"
47 echo " - the following info:"
48 tail -n 6 data/benchmark.log
49 echo
50 echo "Thank you"