nitlanguage
/
nit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
7725873
)
benchs/lang: add timeout
author
Jean Privat
<jean@pryen.org>
Fri, 12 Apr 2013 14:12:06 +0000
(10:12 -0400)
committer
Jean Privat
<jean@pryen.org>
Mon, 15 Jul 2013 18:18:22 +0000
(14:18 -0400)
benchmarks/bench_languages.sh
patch
|
blob
|
history
diff --git
a/benchmarks/bench_languages.sh
b/benchmarks/bench_languages.sh
index
8316ab9
..
c851515
100755
(executable)
--- a/
benchmarks/bench_languages.sh
+++ b/
benchmarks/bench_languages.sh
@@
-57,7
+57,7
@@
function bench_command()
# Execute the commands $count times
for i in `seq 1 "$count"`; do
# Execute the commands $count times
for i in `seq 1 "$count"`; do
- /usr/bin/time -f "%U" -o "$timeout" -a "$@" > $outputopts 2>&1 || die "$1: failed"
+ (ulimit -t 60; /usr/bin/time -f "%U" -o "$timeout" -a "$@") > $outputopts 2>&1 || die "$1: failed"
echo -n "$i. "
tail -n 1 "$timeout"
done
echo -n "$i. "
tail -n 1 "$timeout"
done
@@
-75,7
+75,7
@@
function run_command()
{
if [ "$dry_run" = "true" ]; then return; fi
echo " $ $@"
{
if [ "$dry_run" = "true" ]; then return; fi
echo " $ $@"
- "$@" || die "$@: failed"
+ (ulimit -t 180; "$@") || die "$@: failed"
}
# Check if the test should be skiped according to its name
}
# Check if the test should be skiped according to its name