-
Notifications
You must be signed in to change notification settings - Fork 43
/
Copy pathrun_all_benchmarks.sh
executable file
·70 lines (52 loc) · 1.24 KB
/
run_all_benchmarks.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
58
59
60
61
62
63
64
65
66
67
68
69
70
#!/bin/bash
## Determines whether the experimental pash flags will be tested.
## By default they are not.
export EXPERIMENTAL=0
export DEBUG=0
for item in $@
do
if [ "--experimental" == "$item" ]; then
export EXPERIMENTAL=1
fi
if [ "--debug" == "$item" ]; then
export DEBUG=1
fi
done
## This script is necessary to ensure that sourcing happens with bash
source run.seq.sh
source run.par.sh
compare_outputs(){
dir=$1
outputs=$(ls $dir | grep "seq" | sed 's/.seq.out$//')
for out in $outputs;
do
seq_output="${dir}/${out}.seq.out"
pash_output="${dir}/${out}.par.out"
diff -q "$seq_output" "$pash_output"
done
}
if [ "$EXPERIMENTAL" -eq 1 ]; then
export PASH_FLAGS="--r_split --dgsh_tee --r_split_batch_size 1000000"
# --speculation quick_abort is not maintained at the moment
else
export PASH_FLAGS=""
fi
## Add the debug flag
if [ "$DEBUG" -eq 1 ]; then
export PASH_FLAGS="$PASH_FLAGS -d 1"
fi
oneliners
oneliners_pash
compare_outputs "oneliners/outputs"
unix50
unix50_pash
compare_outputs "unix50/outputs"
nlp
nlp_pash
compare_outputs "nlp/outputs"
web-index
web-index_pash
compare_outputs "web-index/outputs"
analytics-mts
analytics-mts_pash
compare_outputs "analytics-mts/outputs"