mirror of
https://github.com/AdaCore/PolyORB.git
synced 2026-02-12 13:01:15 -08:00
[Imported from Perforce change 5878 at 2006-12-01 19:50:10] Subversion-branch: /trunk/polyorb Subversion-revision: 34109
46 lines
939 B
Bash
Executable File
46 lines
939 B
Bash
Executable File
#! /bin/sh
|
|
|
|
# This outputs elapsed = f(nmax)
|
|
|
|
# params
|
|
|
|
# nmax
|
|
# ethr
|
|
# siz
|
|
|
|
while getopts t:p: opt; do
|
|
case "$opt" in
|
|
t) tag="$OPTARG" ;;
|
|
p) param="$OPTARG" ;;
|
|
*) echo "Usage: $0 [ -t TAG ] [ -p PARAM ]"; exit 1 ;;
|
|
esac
|
|
done
|
|
|
|
case "x$param" in
|
|
x|xnmax) param=nmax ;;
|
|
xethr|xsiz) param=$param ;;
|
|
*) echo "bad param"; exit 1 ;;
|
|
esac
|
|
|
|
if [ "$tag" != "" ]; then
|
|
tag="_$tag"
|
|
fi
|
|
|
|
tr '=' ' ' | awk '
|
|
BEGIN { param = "'"$param"'" }
|
|
/^nmax/ { nmax=$2 }
|
|
/^moy/ { moy=$2 }
|
|
/^siz/ { siz=$2 }
|
|
/^coun/ { cnt=$2 }
|
|
/^evolutedp_thr/ { ethr=$2 }
|
|
/^ect/ { ect = $2;
|
|
if (ethr == 0) ethr = 4;
|
|
fn = sprintf ("data'"$tag"'_%diter", cnt);
|
|
if (param != "nmax")
|
|
fn = (fn sprintf ("_%dcli", nmax));
|
|
if (param != "ethr")
|
|
fn = (fn sprintf ("_%dthr", ethr));
|
|
if (param != "siz")
|
|
fn = (fn sprintf ("_%dbytes", siz));
|
|
printf "%.12g %.12g %.12g\n", '"$param"', moy, ect >> fn }'
|