pull/5/merge
Peter Meerwald-Stadler 3 years ago committed by GitHub
commit be62a558c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,6 +1,8 @@
#!/bin/sh
if [ "$1" = "" ]; then
export TIME='real\t %e'
if [ "$1" = "" ]; then
echo "specify path to tlc binary"
exit 1
else
@ -9,7 +11,6 @@ fi
tlctest()
{
OUT=`(time $TLC $1) 2>&1 | grep real | cut -f 2 | cut -c 3-`
echo "tlc: $1 $OUT"
return 0
@ -24,7 +25,7 @@ wctest()
pythontest()
{
OUT=`(time echo "print str(sum(1 for line in open('$1'))) + ' $1'" | python) 2>&1 | grep real | cut -f 2 | cut -c 3-`
OUT=`(time python -c "print str(sum(1 for line in open('$1'))) + ' $1'") 2>&1 | grep real | cut -f 2 | cut -c 3-`
echo "python: $1 $OUT"
return 0
}
@ -36,7 +37,7 @@ tlctest test_1GB.txt
tlctest test_10GB.txt
echo Timing for 'python'
pythontest test_10MB.txt
pythontest test_10MB.txt
pythontest test_100MB.txt
pythontest test_1GB.txt
pythontest test_10GB.txt

Loading…
Cancel
Save