Commit | Line | Data |
---|---|---|
ad460058 MD |
1 | #!/bin/bash |
2 | ||
3 | source ../utils/tap.sh | |
4 | ||
5 | NUM_TESTS=15 | |
6 | ||
7 | plan_tests ${NUM_TESTS} | |
5a4dc6a8 | 8 | |
fce9a534 SM |
9 | . ./common.sh |
10 | ||
ad460058 MD |
11 | function cleanup() |
12 | { | |
13 | if [ x"$tmpfile" != x"" ]; then | |
14 | rm -f $tmpfile | |
15 | fi | |
16 | } | |
17 | ||
18 | tmpfile= | |
19 | trap cleanup SIGINT SIGTERM EXIT | |
20 | tmpfile=$(mktemp) | |
fce9a534 SM |
21 | |
22 | # Check if time bin is non-empty | |
23 | if [ -n "$test_time_bin" ]; then | |
8d11f7cd | 24 | time_command="$test_time_bin" |
fce9a534 SM |
25 | else |
26 | time_command="" | |
27 | fi | |
28 | ||
f8cbb9da LJ |
29 | for a in test_urcu_gc test_urcu_signal_gc test_urcu_mb_gc test_urcu_qsbr_gc \ |
30 | test_urcu_lgc test_urcu_signal_lgc test_urcu_mb_lgc test_urcu_qsbr_lgc \ | |
31 | test_urcu test_urcu_signal test_urcu_mb test_urcu_qsbr \ | |
31b598e0 | 32 | test_rwlock test_perthreadlock test_mutex; do |
ad460058 MD |
33 | okx $time_command -o $tmpfile ./${a} $* |
34 | diag "time: $(cat $tmpfile)" | |
5a4dc6a8 | 35 | done |