# HG changeset patch # User wenzelm # Date 1133459087 -3600 # Node ID 56554bb23eda50ba365e614f74a7984693987774 # Parent 3414557c2dda81e83bc725e9f648faf32b2f6749 cpu time = user + system; diff -r 3414557c2dda -r 56554bb23eda lib/scripts/timestart.bash --- a/lib/scripts/timestart.bash Thu Dec 01 18:41:46 2005 +0100 +++ b/lib/scripts/timestart.bash Thu Dec 01 18:44:47 2005 +0100 @@ -13,9 +13,8 @@ function get_times () { local TMP="/tmp/get_times$$" times > "$TMP" # No pipe here! - TIMES_RESULT="$SECONDS $(tail -1 "$TMP" | "$AUTO_PERL" -pe 's,(\d+)m(\d+)\.\d+s, $1 * 60 + $2,ge')" + TIMES_RESULT="$SECONDS $(tail -1 "$TMP" | "$AUTO_PERL" -pe 's,(\d+)m(\d+)\.\d+s +(\d+)m(\d+)\.\d+s, $1 * 60 + $2 + $3 * 60 + $4,e')" /bin/rm -f "$TMP" } get_times # sets TIMES_RESULT - diff -r 3414557c2dda -r 56554bb23eda lib/scripts/timestop.bash --- a/lib/scripts/timestop.bash Thu Dec 01 18:41:46 2005 +0100 +++ b/lib/scripts/timestop.bash Thu Dec 01 18:44:47 2005 +0100 @@ -13,7 +13,7 @@ get_times local TIMES_STOP="$TIMES_RESULT" local KIND - for KIND in 1 2 3 + for KIND in 1 2 do local START=$(echo "$TIMES_START" | cut -d " " -f $KIND) local STOP=$(echo "$TIMES_STOP" | cut -d " " -f $KIND) @@ -27,8 +27,7 @@ local KIND_NAME [ "$KIND" = 1 ] && KIND_NAME="elapsed time" - [ "$KIND" = 2 ] && KIND_NAME="user" - [ "$KIND" = 3 ] && KIND_NAME="system" + [ "$KIND" = 2 ] && KIND_NAME="cpu time" local RESULT="${HOURS}:${MINUTES}:${SECS} ${KIND_NAME}" if [ -z "$TIMES_REPORT" ]; then