23 lines
444 B
Bash
Executable File
23 lines
444 B
Bash
Executable File
#!/bin/bash
|
|
|
|
REPEAT=30
|
|
CYCLES=50
|
|
|
|
function test() {
|
|
echo $@
|
|
for c in $(seq 1 $CYCLES); do
|
|
for i in $(seq 1 $REPEAT); do
|
|
echo "cycles: $((c * 100)) ($i/$REPEAT)"
|
|
$@ $((c * 100))
|
|
sleep 1
|
|
done
|
|
done
|
|
}
|
|
|
|
test ./main
|
|
cd ../intercept
|
|
test ./intercept -o -i - -- ../perf/main
|
|
test ./intercept -o -i stderr -- ../perf/main
|
|
test ./intercept -o -i file:out.log -- ../perf/main
|
|
#test ./intercept -o -i unix:/ -- ../perf/main
|