fwrite test added
[svn/Cll1h/.git] / demos / performance / test-performance2.sh
index 4b5e95181bac706e8110ddfb8f2e4397eba9f4ff..a4006d2427f91e51744bb5b8e05129be085ce3ee 100755 (executable)
@@ -1,37 +1,69 @@
 #!/bin/sh
 
 cat print2.rb
-echo "Running..."
-time ./print2.rb > /dev/null
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./print2.rb > /dev/null
+echo
 
 cat print2.py
-echo "Running..."
-time ./print2.py > /dev/null
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./print2.py > /dev/null
+echo
+
+cat xrange2.py
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./xrange2.py > /dev/null
+echo
+
+cat echo2.php
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./echo2.php > /dev/null
+echo
+
+cat write2.c
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" gcc -O2 write2.c -o write2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./write2 > /dev/null
+echo
 
 cat cout2.cpp
-echo "Compiling..."
-time g++ -O2 cout2.cpp -o cout2
-echo "Running..."
-time ./cout2 > /dev/null
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" g++ -O2 cout2.cpp -o cout2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./cout2 > /dev/null
+echo
 
 cat print2.pl
-echo "Running..."
-time ./print2.pl > /dev/null
-
-cat cll1-print2.c
-echo "Compiling..."
-time gcc -O2 cll1-print2.c -o cll1-print2
-echo "Running..."
-time ./cll1-print2 > /dev/null
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./print2.pl > /dev/null
+echo
 
 cat printf2.c
-echo "Compiling..."
-time gcc -O2 printf2.c -o printf2
-echo "Running..."
-time ./printf2 > /dev/null
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" gcc -O2 printf2.c -o printf2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./printf2 > /dev/null
+echo
+
+
+cat cll1-print2.c
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" gcc -O2 cll1-print2.c -o cll1-print2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./cll1-print2 > /dev/null
+echo
 
 cat fputs2.c
-echo "Compiling..."
-time gcc -O2 fputs2.c -o fputs2
-echo "Running..."
-time ./fputs2 > /dev/null
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" gcc -O2 fputs2.c -o fputs2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./fputs2 > /dev/null
+echo
+
+cat fwrite2.c
+echo -n "Compiling..."
+time -f  "%E total, %U user, %S sys, %F page faults" gcc -O2 fwrite2.c -o fwrite2
+echo -n "Running..."
+time -f  "%E total, %U user, %S sys, %F page faults" ./fwrite2 > /dev/null
+echo
This page took 0.135416 seconds and 4 git commands to generate.