Include changes memory
[ACE_TAO.git] / TAO / orbsvcs / tests / EC_Multiple / gen_overhead
blob6cf0518aa235f3c4aa5a3d10a53e18446371d9d2
1 #!/bin/sh
3 #TESTS_SOURCES="X LCL RMT1 RMT2 RPT.X RPT.LCL RPT.RMT1 RPT.RMT2"
4 TESTS_SOURCES="RPT.X RPT.LCL RPT.RMT1 RPT.RMT2"
6 #TESTS="$TEST_SOURCES RPT.RMT RMT"
7 TESTS="$TEST_SOURCES RPT.RMT"
9 for i in $TESTS_SOURCES; do
10 grep "Scavenger time" OVH.${i}.*.log |
11 sed -e "s/^OVH\.${i}\.//" -e 's/\.log:Scavenger time://' |
12 sort -n > OVH.${i}.scav.data
13 grep "Push time" OVH.${i}.*.log |
14 sed -e "s/^OVH\.${i}\.//" -e 's/\.log:Push time://' |
15 sort -n > OVH.${i}.push.data
16 # | awk '{printf ("%d %.3f\n", $1, $2/$1);}'
17 done
19 paste scav.RMT1.data scav.RMT2.data |
20 awk '{printf("%d %.3f\n", $1, ($2 + $4)/2);}' > OVH.RMT.scav.data
21 paste push.RMT1.data push.RMT2.data |
22 awk '{printf("%d %.3f\n", $1, ($2 + $4)/2);}' > OVH.RMT.push.data
24 paste scav.RPT.RMT1.data scav.RPT.RMT2.data |
25 awk '{printf("%d %.3f\n", $1, ($2 + $4)/2);}' > OVH.RPT.RMT.scav.data
26 paste push.RPT.RMT1.data push.RPT.RMT2.data |
27 awk '{printf("%d %.3f\n", $1, ($2 + $4)/2);}' > OVH.RPT.RMT.push.data
29 for i in X LCL RMT RMT1 RMT2; do
30 paste OVH.${i}.scav.data OVH.${i}.push.data |
31 awk '{
32 if (NR == 1) {
33 b = $2;
34 } else {
35 printf ("%d %.3f\n", $1, ($2 - $4 - b) / $1);
36 }}' > OVH.${i}.over.data
37 done
39 for i in RPT.X RPT.LCL RPT.RMT RPT.RMT1 RPT.RMT2; do
40 paste OVH.${i}.scav.data OVH.${i}.push.data |
41 awk '{
42 printf ("%d %.3f\n", $1, ($2 - $4));
43 }' > OVH.${i}.over.data
44 done
46 for i in $TESTS; do
47 case $i in
48 X) LABEL="Number of Messages [short circuit test]"
50 LCL) LABEL="Number of Messages [local EC test]"
52 RMT) LABEL="Number of Messages [remote EC test]"
54 RMT1) LABEL="Number of Messages [remote EC test 1]"
56 RMT2) LABEL="Number of Messages [remote EC test 2]"
58 RPT.X) LABEL="Test Number [short circuit test]"
60 RPT.LCL) LABEL="Test Number [local EC test]"
62 RPT.RMT) LABEL="Test Number [remote EC test]"
64 RPT.RMT1) LABEL="Test Number [remote EC test 1]"
66 RPT.RMT2) LABEL="Test Number [remote EC test 2]"
69 *) LABEL="Test Number [unknown test]"
71 esac
73 gnuplot <<_EOF_
74 set grid xtics ytics
75 set xlabel "$LABEL"
77 set terminal postscript eps color
78 set ylabel "Time in scavenger (usecs)"
79 set output "OVH.${i}.scav.eps"
80 plot 'OVH.${i}.scav.data' w l
81 set terminal x11
82 plot 'OVH.${i}.scav.data' w l
83 pause 2
85 set terminal postscript eps
86 set ylabel "Time in push (usecs)"
87 set output "OVH.${i}.push.eps"
88 plot 'OVH.${i}.push.data' w l
89 set terminal x11
90 plot 'OVH.${i}.push.data' w l
91 pause 2
93 set terminal postscript eps
94 set ylabel "Overhead (usecs)"
95 set output "OVH.${i}.over.eps"
96 plot 'OVH.${i}.over.data' w l
97 set terminal x11
98 plot 'OVH.${i}.over.data' w l
99 pause 2
100 _EOF_
101 done
103 for i in OVH.push OVH.scav OVH.over; do
104 for j in $TESTS; do
105 gs -sDEVICE=jpeg -g640x480 -r110x110 -sNOPAUSE \
106 -sOutputFile="${i}.${j}.jpg" ${i}.${j}.eps quit.ps
107 done
108 done
110 exit 0