-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun_scenarios.bash
executable file
·53 lines (51 loc) · 1.34 KB
/
run_scenarios.bash
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
#! /bin/bash
export OUTPUTDIR="$(pwd)/x86_res/sequential/100ms_50mbps"
export UDPSIZES="1232"
export ALGS="FALCON512"
export BUILDDIR="$(pwd)/build"
export WORKINGDIR="$(pwd)"
mkdir -p $OUTPUTDIR
for ALG in $ALGS
do
echo $ALG
for UDPSIZE in $UDPSIZES
do
cd $WORKINGDIR
echo $UDPSIZE
if [[ $UDPSIZE == "notcp" ]]
then
python3 build_docker_compose.py --bypass --maxudp 1232 --alg $ALG <<< "Y"
else
if [[ $UDPSIZE == "stock" ]]
then
python3 build_docker_compose.py --bypass --maxudp 1232 --alg $ALG <<< "Y"
cp resolver/named_stock.conf build/resolver/named.conf
else
python3 build_docker_compose.py --maxudp $UDPSIZE --alg $ALG <<< "Y"
fi
fi
cd $BUILDDIR
docker compose down
docker compose build
cd $WORKINGDIR
if [[ $ALG == SPHINCS+-SHA256-128S ]]
then
echo "Being safe..."
cp tmux-run-docker-part2_sphincs+_safe.bash build/tmux-run-docker-part2.bash
fi
if [[ $ALG == DILITHIUM2 ]]
then
if [[ $UDPSIZE -eq 256 ]]
then
echo "Being safe..."
cp tmux-run-docker-part2_dilithium2_safe.bash build/tmux-run-docker-part2.bash
fi
fi
./run_exps.bash 0 1000 | tee scratch.log
echo "$ALG"_"$UDPSIZE"": " $(tail -n 1 scratch.log) >> results_summary.log
rm scratch.log
cd $BUILDDIR/dig_logs
tar -cvf "X86_64_""$ALG"_"$UDPSIZE"".tar" *
mv "X86_64_""$ALG"_"$UDPSIZE"".tar" $OUTPUTDIR
done
done