-
Notifications
You must be signed in to change notification settings - Fork 0
/
regression.sh
executable file
·57 lines (54 loc) · 1.09 KB
/
regression.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/bin/bash
set -e
TOP_DIR=$(dirname $(realpath $0))
if [ $# -lt 1 ]; then
echo "[Usage]: regression.sh build/rebuild/validation/benchmark/clean [options]"
elif [ $1 == "build" ]; then
if [ ! -d "build" ]; then
mkdir build; cd build;
shift
cmake $* ..
make -j 4
cd ..
fi
cd build
make -j 4
cd ..
elif [ $1 == "rebuild" ]; then
if [ -d "build" ]; then
rm -rf build
fi
mkdir build; cd build;
shift
cmake $* ..
make -j 4
cd ..
elif [ $1 == "validation" ]; then
if [ -d "build" ]; then
rm -rf build
fi
mkdir build; cd build;
shift
cmake $* ..
make -j 4
cd ..
build/winograd small.conf 1
build/winograd smallrealworld.conf 1
elif [ $1 == "benchmark" ]; then
if [ -d "build" ]; then
rm -rf build
fi
mkdir build; cd build;
shift
cmake $* ..
make -j 4
cd ..
build/winograd realworld.conf 0
elif [ $1 == "clean" ]; then
if [ -d "build" ]; then
rm -rf build
fi
if [ -f "winograd" ]; then
rm winograd
fi
fi