Major header file rewrite and cleanup, but no new functions
[svn/Cll1h/.git] / demos / performance / test-performance2.sh
... / ...
CommitLineData
1#!/bin/bash
2echo `grep "model name" /proc/cpuinfo |cut -f 2 -d :` `grep "cpu MHz" /proc/cpuinfo |cut -f 2 -d :` Mhz ` grep "bogomips" /proc/cpuinfo |cut -f 2 -d :` bogomips
3
4echo "------------------------------------------------------------- Ruby"
5cat print2.rb
6echo -n "Running..."
7time ./print2.rb > /dev/null
8echo
9
10echo "--------------------------------------------------- Python - range"
11cat print2.py
12echo -n "Running..."
13time ./print2.py > /dev/null
14echo
15
16echo "-------------------------------------------------- Python - xrange"
17cat xrange2.py
18echo -n "Running..."
19time ./xrange2.py > /dev/null
20echo
21
22echo "------------------------------------------------------------ PHP 5"
23cat echo2.php
24echo -n "Running..."
25time -f "%E total, %U user, %S sys" ./echo2.php > /dev/null
26echo
27
28echo "-------------------------------------------------- C - gcc - write"
29cat write2.c
30echo -n "Compiling..."
31time gcc -O2 write2.c -o write2
32echo -n "Running..."
33time ./write2 > /dev/null
34echo
35
36echo "---------------------------------------------- C - g++ - std::cout"
37cat cout2.cpp
38echo -n "Compiling..."
39time g++ -O2 cout2.cpp -o cout2
40echo -n "Running..."
41time ./cout2 > /dev/null
42echo
43
44echo "------------------------------------------------------------- Perl"
45cat print2.pl
46echo -n "Running..."
47time -f "%E total, %U user, %S sys" ./print2.pl > /dev/null
48echo
49
50#echo "------------------------------------------------- C - tcc - printf"
51#cat printf2.c
52#echo -n "Compiling..."
53#time tcc -O2 printf2.c -o printf2
54#echo -n "Running..."
55#time ./printf2 > /dev/null
56#echo
57#
58#echo "------------------------------------------------- C - tcc - fwrite"
59#cat fwrite2.c
60#echo -n "Compiling..."
61#time tcc -O2 fwrite2.c -o fwrite2
62#echo -n "Running..."
63#time ./fwrite2 > /dev/null
64#echo
65#
66#echo "----------------------------------------------- C<<1 - tcc - print"
67#cat cll1-print2.c
68#echo -n "Compiling..."
69#time tcc -O2 cll1-print2.c -o cll1-print2
70#echo -n "Running..."
71#time ./cll1-print2 > /dev/null
72#echo
73#
74#echo "-------------------------------------------------- C - tcc - fputs"
75#cat fputs2.c
76#echo -n "Compiling..."
77#time tcc -O2 fputs2.c -o fputs2
78#echo -n "Running..."
79#time ./fputs2 > /dev/null
80#echo
81#
82echo "------------------------------------------------- C - gcc - printf"
83cat printf2.c
84echo -n "Compiling..."
85time gcc -O2 printf2.c -o printf2
86echo -n "Running..."
87time ./printf2 > /dev/null
88echo
89
90echo "------------------------------------------------- C - gcc - fwrite"
91cat fwrite2.c
92echo -n "Compiling..."
93time gcc -O2 fwrite2.c -o fwrite2
94echo -n "Running..."
95time ./fwrite2 > /dev/null
96echo
97
98echo "----------------------------------------------- C<<1 - gcc - print"
99cat cll1-print2.c
100echo -n "Compiling..."
101time gcc -O2 cll1-print2.c -o cll1-print2
102echo -n "Running..."
103time ./cll1-print2 > /dev/null
104echo
105
106echo "-------------------------------------------------- C - gcc - fputs"
107cat fputs2.c
108echo -n "Compiling..."
109time gcc -O2 fputs2.c -o fputs2
110echo -n "Running..."
111time ./fputs2 > /dev/null
This page took 0.102355 seconds and 4 git commands to generate.