tasks_size_overhead.gp 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #!/bin/sh
  2. # StarPU --- Runtime system for heterogeneous multicore architectures.
  3. #
  4. # Copyright (C) 2009, 2010, 2016 Université de Bordeaux
  5. # Copyright (C) 2010, 2011 CNRS
  6. #
  7. # StarPU is free software; you can redistribute it and/or modify
  8. # it under the terms of the GNU Lesser General Public License as published by
  9. # the Free Software Foundation; either version 2.1 of the License, or (at
  10. # your option) any later version.
  11. #
  12. # StarPU is distributed in the hope that it will be useful, but
  13. # WITHOUT ANY WARRANTY; without even the implied warranty of
  14. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  15. #
  16. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  17. OUTPUT=tasks_size_overhead.output
  18. VALS=$(sed -n -e '3p' < $OUTPUT)
  19. VAL1=$(echo "$VALS" | cut -d ' ' -f 3)
  20. VAL2=$(echo "$VALS" | cut -d ' ' -f 5)
  21. VAL3=$(echo "$VALS" | cut -d ' ' -f 7)
  22. VAL4=$(echo "$VALS" | cut -d ' ' -f 9)
  23. VAL5=$(echo "$VALS" | cut -d ' ' -f 11)
  24. VAL6=$(echo "$VALS" | cut -d ' ' -f 13)
  25. VAL7=$(echo "$VALS" | cut -d ' ' -f 15)
  26. VAL8=$(echo "$VALS" | cut -d ' ' -f 17)
  27. VAL9=$(echo "$VALS" | cut -d ' ' -f 19)
  28. VAL10=$(echo "$VALS" | cut -d ' ' -f 21)
  29. VAL11=$(echo "$VALS" | cut -d ' ' -f 23)
  30. [ -n "$TERMINAL" ] || TERMINAL=eps
  31. [ -n "$OUTFILE" ] || OUTFILE=tasks_size_overhead.eps
  32. gnuplot << EOF
  33. set terminal $TERMINAL
  34. set output "$OUTFILE"
  35. set key top left
  36. set xlabel "number of cores"
  37. set ylabel "speedup"
  38. plot \
  39. x title "linear", \
  40. "$OUTPUT" using 1:($VAL11)/(\$23) with linespoints title columnheader(22), \
  41. "$OUTPUT" using 1:($VAL10)/(\$21) with linespoints title columnheader(20), \
  42. "$OUTPUT" using 1:($VAL9)/(\$19) with linespoints title columnheader(18), \
  43. "$OUTPUT" using 1:($VAL8)/(\$17) with linespoints title columnheader(16), \
  44. "$OUTPUT" using 1:($VAL7)/(\$15) with linespoints title columnheader(14), \
  45. "$OUTPUT" using 1:($VAL6)/(\$13) with linespoints title columnheader(12), \
  46. "$OUTPUT" using 1:($VAL5)/(\$11) with linespoints title columnheader(10), \
  47. "$OUTPUT" using 1:($VAL4)/(\$9) with linespoints title columnheader(8), \
  48. "$OUTPUT" using 1:($VAL3)/(\$7) with linespoints title columnheader(6), \
  49. "$OUTPUT" using 1:($VAL2)/(\$5) with linespoints title columnheader(4), \
  50. "$OUTPUT" using 1:($VAL1)/(\$3) with linespoints title columnheader(2)
  51. EOF