src/benchmark/benchmark
author alpar
Wed, 21 Jul 2004 17:38:47 +0000
changeset 721 1df9b762269b
child 723 7ded6acc2dfe
permissions -rwxr-xr-x
Indenting.
alpar@718
     1
#!/bin/bash
alpar@718
     2
alpar@718
     3
function runtest () # prefix, prog, args
alpar@718
     4
{
alpar@718
     5
    echo $1 1>&2
alpar@718
     6
    $2 $3 $4 $5 $6 $7 $8 $9|awk '{print "'$1'",$0}'
alpar@718
     7
}
alpar@718
     8
alpar@718
     9
function runalltest() #postfix, CXX, CXXFLAGS
alpar@718
    10
{
alpar@718
    11
    echo $1 1>&2
alpar@718
    12
    make clean >/dev/null
alpar@718
    13
    make CXX="$2" CXXFLAGS="$3"  >/dev/null
alpar@718
    14
    {
alpar@718
    15
	runtest HCUBE19 hcube 19
alpar@718
    16
	runtest GRBENCH graph-bench
alpar@718
    17
    } | awk "{print \$0, \"$1\"}"
alpar@718
    18
}
alpar@718
    19
alpar@718
    20
runalltest "gcc-3.3 -O2"                 g++ "-O2"
alpar@718
    21
runalltest "gcc-3.3 -O2-march=pentium-m" g++ "-O2 -march=pentium-m"
alpar@718
    22
runalltest "gcc-3.3 -O3"                 g++ "-O3"
alpar@718
    23
runalltest "gcc-3.3 -O3-march=pentium-m" g++ "-O3 -march=pentium-m"
alpar@718
    24
alpar@718
    25
runalltest "gcc-3.4 -O2"                 g++-3.4 "-O2"
alpar@718
    26
runalltest "gcc-3.4 -O2-march=pentium-m" g++-3.4 "-O2 -march=pentium-m"
alpar@718
    27
runalltest "gcc-3.4 -O3"                 g++-3.4 "-O3"
alpar@718
    28
runalltest "gcc-3.4 -O3-march=pentium-m" g++-3.4 "-O3 -march=pentium-m"
alpar@718
    29