-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.sh
More file actions
executable file
·65 lines (55 loc) · 1.32 KB
/
test.sh
File metadata and controls
executable file
·65 lines (55 loc) · 1.32 KB
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
#!/bin/bash
# Sets script to exit on any error, treat unset variables as errors, and return exit status
set -euo pipefail
# Function to display usage
usage() {
echo "Usage: $0 [--part1] [--part2] [--part3] [--part4] [--part5]"
exit 1
}
# Check for at least one argument
if [ $# -eq 0 ]; then
usage
fi
# Parse flags
run_part1=false
run_part2=false
run_part3=false
run_part4=false
run_part5=false
while [[ $# -gt 0 ]]; do
case "$1" in
--part1) run_part1=true ;;
--part2) run_part2=true ;;
--part3) run_part3=true ;;
--part4) run_part4=true ;;
--part5) run_part5=true ;;
*) usage ;;
esac
shift
done
# Run parts based on flags
if [ "$run_part1" = true ]; then
echo "Running Part 1..."
cd zeroqueingdelay && ./latencytest.sh
cd ..
fi
if [ "$run_part2" = true ]; then
echo "Running Part 2..."
cd maximumbandwidth && ./memorybandwidth_test.sh
cd ..
fi
if [ "$run_part3" = true ]; then
echo "Running Part 3..."
cd latencytradeoff && ./tradeoff.sh
cd ..
fi
if [ "$run_part4" = true ]; then
echo "Running Part 4..."
cd cache-TLBmissratioperformance && ./cachemissratioperformance.sh
cd ..
fi
if [ "$run_part5" = true ]; then
echo "Running Part 5..."
cd cache-TLBmissratioperformance && ./TLBmissratioperformance.sh
cd ..
fi