-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest.sh
executable file
·48 lines (38 loc) · 1.09 KB
/
test.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
PERMUTATION_FILE="permutations.txt"
permutations=""
for times in $( seq 1 $1 ); do
permutations="$permutations $PERMUTATION_FILE"
done
echo "Starting test with 10 repetitions of $PERMUTATION_FILE"
echo "Ruby naive"
date +%H:%M:%S:%N
cat $permutations | solutions/naive.rb > /dev/null
date +%H:%M:%S:%N
echo "Ruby naive unlooped"
date +%H:%M:%S:%N
cat $permutations | solutions/naive_unlooped.rb > /dev/null
date +%H:%M:%S:%N
echo "Java naive"
date +%H:%M:%S:%N
cat $permutations | java solutions.Naive > /dev/null
date +%H:%M:%S:%N
echo "Java naive unlooped"
date +%H:%M:%S:%N
cat $permutations | java solutions.Naive > /dev/null
date +%H:%M:%S:%N
echo "C naive"
date +%H:%M:%S:%N
cat $permutations | solutions/naive.exe > /dev/null
date +%H:%M:%S:%N
echo "C naive unlooped"
date +%H:%M:%S:%N
cat $permutations | solutions/naive_unlooped.exe > /dev/null
date +%H:%M:%S:%N
echo "C naive O2"
date +%H:%M:%S:%N
cat $permutations | solutions/naive_O2.exe > /dev/null
date +%H:%M:%S:%N
echo "C naive unlooped O2"
date +%H:%M:%S:%N
cat $permutations | solutions/naive_unlooped_O2.exe > /dev/null
date +%H:%M:%S:%N