home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-387-Vol-3of3.iso / x / x11p-13.zip / RCS / x11perffill,v < prev    next >
Text File  |  1990-01-07  |  2KB  |  76 lines

  1. head     1.2;
  2. access   ;
  3. symbols  ;
  4. locks    ; strict;
  5. comment  @# @;
  6.  
  7.  
  8. 1.2
  9. date     90.01.07.16.39.11;  author joel;  state Exp;
  10. branches ;
  11. next     1.1;
  12.  
  13. 1.1
  14. date     89.12.27.19.31.25;  author joel;  state Exp;
  15. branches ;
  16. next     ;
  17.  
  18.  
  19. desc
  20. @Replacement for fillblanks.sh
  21. @
  22.  
  23.  
  24. 1.2
  25. log
  26. @Fill in missing lines with trep rather than reps
  27. @
  28. text
  29. @#! /bin/sh
  30. # Some machines weren't able to complete the x11perf tests, or missed
  31. # some tests. Fills in lines with a 0.0 average rate for the missing lines.
  32. # Mark Moraes, University of Toronto
  33. f=$1
  34. label=$2
  35. awk '$2 == "reps" || $2 == "trep" {
  36.     print $0;
  37.     next;
  38.     }
  39. ' $f | sed 's/^.*: //' | uniq > /tmp/f1.$$
  40. diff -e /tmp/f1.$$ $label > /tmp/f2.$$
  41. others=`sed -n -e ':start' \
  42.     -e '/^[0-9]*,[0-9]*d$/b pnext' \
  43.     -e '/^[0-9]*[ac]$/b skpdot' \
  44.     -e '/^[0-9]*,[0-9]*c$/b skpdot' \
  45.     -e x -e 's/.*/bad pattern in diff output/' -e p -e n -e 'b start' \
  46.     -e :skpdot -e p -e :skip -e n -e '/^\.$/b next' -e 'b skip' \
  47.     -e :pnext -e p -e :next -e n -e 'b start' \
  48. /tmp/f2.$$ | grep -v '^[0-9]*a'`
  49. case "$others" in
  50. '')    ;;
  51. *)    echo "$0: label file $label is incomplete or out of date," >& 2
  52.     echo "   or you are trying to use old (pre-1.2) x11perf results." >& 2
  53.     exit 1
  54.     ;;
  55. esac
  56. (sed     -e :start -e '/^[0-9]*[ac]$/b skpdot' \
  57.     -e :skpdot -e :skip -e n -e '/^\.$/b next' \
  58.         -e 's,.*,     0 trep @@  0.0    msec (0.0/sec): &,' \
  59.         -e 'b skip' \
  60.     -e :next -e n -e 'b start' \
  61.     /tmp/f2.$$; echo '1,$p') | ed - $f > /tmp/f1.$$
  62. cat /tmp/f1.$$
  63. rm -f /tmp/f1.$$ /tmp/f2.$$
  64. @
  65.  
  66.  
  67. 1.1
  68. log
  69. @Initial revision
  70. @
  71. text
  72. @d30 1
  73. a30 1
  74.         -e 's,.*,     0 reps @@  0.0    msec (0.0/sec): &,' \
  75. @
  76.