blob: a95d6912a41533e1190ed5fd0b79bf34d13e5be1 [file] [log] [blame]
bartb3d0c142008-06-08 08:09:50 +00001#!/bin/bash
2
3########################
4# Function definitions #
5########################
6
7source "$(dirname $0)/measurement-functions"
8
9########################
10# Script body #
11########################
12
13DRD_SCRIPTS_DIR="$(dirname $0)"
14if [ "${DRD_SCRIPTS_DIR:0:1}" != "/" ]; then
15 DRD_SCRIPTS_DIR="$PWD/$DRD_SCRIPTS_DIR"
16fi
17
18VG="${DRD_SCRIPTS_DIR}/../../vg-in-place"
19MATINV="${DRD_SCRIPTS_DIR}/../../exp-drd/tests/matinv"
20
21
22for n in 200 400
23do
24 tmp="/tmp/test-timing.$$"
25 rm -f "${tmp}"
26
27 measure_runtime ${MATINV} $n | avgstddev > "$tmp"
28 read avg1 stddev1 < "$tmp"
29 echo "Average time: ${avg1} +/- ${stddev1} seconds"
30
bartf7fa46b2008-06-09 19:52:37 +000031 for i in 1 10
bartb3d0c142008-06-08 08:09:50 +000032 do
bartf7fa46b2008-06-09 19:52:37 +000033 print_runtime_ratio ${VG} --tool=none ${MATINV} $n -t$i
bartb3d0c142008-06-08 08:09:50 +000034 print_runtime_ratio ${VG} --tool=exp-drd ${MATINV} $n -t$i
35 done
36done