tools/performance/layout/history.pl

Wed, 31 Dec 2014 06:09:35 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:09:35 +0100
changeset 0
6474c204b198
permissions
-rw-r--r--

Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.

michael@0 1 ##########################################################################################
michael@0 2 #
michael@0 3 # This Source Code Form is subject to the terms of the Mozilla Public
michael@0 4 # License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
michael@0 6
michael@0 7 #------------------------------------------------------------------------------
michael@0 8 sub debug_print {
michael@0 9 foreach $str (@_){
michael@0 10 # print( $str );
michael@0 11 }
michael@0 12 }
michael@0 13
michael@0 14
michael@0 15 #------------------------------------------------------------------------------
michael@0 16 # Variables
michael@0 17 #------------------------------------------------------------------------------
michael@0 18 $Parse_Time_Max=0;
michael@0 19 $Content_Time_Max=0;
michael@0 20 $Frame_Time_Max=0;
michael@0 21 $Style_Time_Max=0;
michael@0 22 $Reflow_Time_Max=0;
michael@0 23 $Layout_Time_Max=0;
michael@0 24 $Total_Time_Max=0;
michael@0 25
michael@0 26 @RecordList;
michael@0 27 @LineList;
michael@0 28
michael@0 29 #------------------------------------------------------------------------------
michael@0 30 # Open the history file and begin by collecting the records into the data-arrays
michael@0 31 # and set all of the max-values too
michael@0 32 #------------------------------------------------------------------------------
michael@0 33 $count=0;
michael@0 34 open( HISTORY, "History.txt" ) or die "History file could not be opened\n";
michael@0 35 while(<HISTORY>)
michael@0 36 {
michael@0 37 my $PullID;
michael@0 38 my $BuildID;
michael@0 39 # - Time variables
michael@0 40 my $Parse_Time=0;
michael@0 41 my $Content_Time=0;
michael@0 42 my $Frame_Time=0;
michael@0 43 my $Style_Time=0;
michael@0 44 my $Reflow_Time=0;
michael@0 45 my $Layout_Time=0;
michael@0 46 my $Total_Time=0;
michael@0 47 # - percentage variables
michael@0 48 my $Parse_Per=0;
michael@0 49 my $Content_Per=0;
michael@0 50 my $Frame_Per=0;
michael@0 51 my $Style_Per=0;
michael@0 52 my $Reflow_Per=0;
michael@0 53 my $Layout_Per=0;
michael@0 54
michael@0 55 $i=0;
michael@0 56 $ThisLine = $_;
michael@0 57 chop( $Thisline );
michael@0 58 @LineList = split( /,/, $ThisLine );
michael@0 59
michael@0 60 # get each value into a variable
michael@0 61 $PullID = $LineList[$i++];
michael@0 62 $RecordList[$count++] = $PullID;
michael@0 63 debug_print( "PullID : $PullID \n" );
michael@0 64 $BuildID = $LineList[$i++];
michael@0 65 $RecordList[$count++] = $BuildID;
michael@0 66 debug_print( "BuildID : $BuildID \n" );
michael@0 67
michael@0 68 $Parse_Time = $LineList[$i++];
michael@0 69 $RecordList[$count++] = $Parse_Time;
michael@0 70 debug_print( "Parse_Time : $Parse_Time \n" );
michael@0 71 $Parse_Per = $LineList[$i++];
michael@0 72 $RecordList[$count++] = $Parse_Per;
michael@0 73 debug_print( "Parse_Per : $Parse_Per \n" );
michael@0 74 $Content_Time = $LineList[$i++];
michael@0 75 $RecordList[$count++] = $Content_Time;
michael@0 76 debug_print( "Content_Time : $Content_Time \n" );
michael@0 77 $Content_Per = $LineList[$i++];
michael@0 78 $RecordList[$count++] = $Content_Per;
michael@0 79 debug_print( "Content_Per : $Content_Per \n" );
michael@0 80 $Frame_Time = $LineList[$i++];
michael@0 81 $RecordList[$count++] = $Frame_Time;
michael@0 82 debug_print( "Frame_Time : $Frame_Time \n" );
michael@0 83 $Frame_Per = $LineList[$i++];
michael@0 84 $RecordList[$count++] = $Frame_Per;
michael@0 85 debug_print( "Frame_Per : $Frame_Per \n" );
michael@0 86 $Style_Time = $LineList[$i++];
michael@0 87 $RecordList[$count++] = $Style_Time;
michael@0 88 debug_print( "Style_Time : $Style_Time \n" );
michael@0 89 $Style_Per = $LineList[$i++];
michael@0 90 $RecordList[$count++] = $Style_Per;
michael@0 91 debug_print( "Style_Per : $Style_Per \n" );
michael@0 92 $Reflow_Time = $LineList[$i++];
michael@0 93 $RecordList[$count++] = $Reflow_Time;
michael@0 94 debug_print( "Reflow_Time : $Reflow_Time \n" );
michael@0 95 $Reflow_Per = $LineList[$i++];
michael@0 96 $RecordList[$count++] = $Reflow_Per;
michael@0 97 debug_print( "Reflow_Per : $Reflow_Per \n" );
michael@0 98 $Layout_Time = $LineList[$i++];
michael@0 99 $RecordList[$count++] = $Layout_Time;
michael@0 100 debug_print( "Layout_Time : $Layout_Time \n" );
michael@0 101 $Layout_Per = $LineList[$i++];
michael@0 102 $RecordList[$count++] = $Layout_Per;
michael@0 103 debug_print( "Layout_Per : $Layout_Per \n" );
michael@0 104 $Total_Time = $LineList[$i++];
michael@0 105 $RecordList[$count++] = $Total_Time;
michael@0 106 debug_print( "Total_Time : $Total_Time \n" );
michael@0 107
michael@0 108 # Now check for max values
michael@0 109 if( $Parse_Time > $Parse_Time_Max ){
michael@0 110 $Parse_Time_Max = $Parse_Time;
michael@0 111 debug_print( "ParseTimeMax: .$Parse_Time_Max\n");
michael@0 112 }
michael@0 113 if( $Content_Time > $Content_Time_Max ){
michael@0 114 $Content_Time_Max = $Content_Time;
michael@0 115 debug_print( "Content_Time_Max: $Content_Time_Max\n");
michael@0 116 }
michael@0 117 if( $Frame_Time > $Frame_Time_Max ){
michael@0 118 $Frame_Time_Max = $Frame_Time;
michael@0 119 debug_print( "Frame_Time_Max: $Frame_Time_Max\n");
michael@0 120 }
michael@0 121 if( $Style_Time > $Style_Time_Max ){
michael@0 122 $Style_Time_Max = $Style_Time;
michael@0 123 debug_print( "Style_Time_Max: $Style_Time_Max\n");
michael@0 124 }
michael@0 125 if( $Reflow_Time > $Reflow_Time_Max ){
michael@0 126 $Reflow_Time_Max = $Reflow_Time;
michael@0 127 debug_print( "Reflow_Time_Max: $Reflow_Time_Max\n");
michael@0 128 }
michael@0 129 if( $Layout_Time > $Layout_Time_Max ){
michael@0 130 $Layout_Time_Max = $Layout_Time;
michael@0 131 debug_print( "Layout_Time_Max: $Layout_Time_Max\n");
michael@0 132 }
michael@0 133
michael@0 134 if( $Total_Time > $Total_Time_Max ){
michael@0 135 $Total_Time_Max = $Total_Time;
michael@0 136 debug_print( "Total_Time_Max: $Total_Time_Max\n");
michael@0 137 }
michael@0 138 }
michael@0 139 close(HISTORY);
michael@0 140
michael@0 141 for $foo (@RecordList){
michael@0 142 # print( "FOO: $foo \n" );
michael@0 143 }
michael@0 144 ProcessHeader();
michael@0 145 for($index=0; $index<($count/15); $index++)
michael@0 146 {
michael@0 147 my $start = 15*$index;
michael@0 148 my $end = $start+15;
michael@0 149 print( "Start: $start -> End: $end\n");
michael@0 150 my @entry = @RecordList[$start..$end];
michael@0 151 print( "Processing entry $index\n");
michael@0 152 ProcessEntry( @entry );
michael@0 153 }
michael@0 154 ProcessFooter();
michael@0 155
michael@0 156 #------------------------------------------------------------------------------
michael@0 157 #
michael@0 158 sub ProcessHeader {
michael@0 159 debug_print("ProcessHeader\n");
michael@0 160
michael@0 161 ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst)=localtime;
michael@0 162 %weekday= (
michael@0 163 "1", "$day",
michael@0 164 '2', 'Tuesday',
michael@0 165 '3', 'Wednesday',
michael@0 166 '4', 'Thursday',
michael@0 167 '5', 'Friday',
michael@0 168 '6', 'Saturday',
michael@0 169 '7', 'Sunday',
michael@0 170 );
michael@0 171 $mon += 1;
michael@0 172 $year += 1900;
michael@0 173
michael@0 174 open(TRENDTABLE, "> TrendTable.html") or die "Cannot open trend-table file (TrendTable.html) in ProcessHeader\n";
michael@0 175 print(TRENDTABLE "<!-- Generated by history.pl part of the Gecko PerfTools -->\n");
michael@0 176 print(TRENDTABLE "<BODY>\n" );
michael@0 177 print(TRENDTABLE "<H2 align=center><font color='maroon'>Performance History and Trending Table</font></H2><BR>\n" );
michael@0 178 print (TRENDTABLE "<center><font size=-1>");
michael@0 179 print (TRENDTABLE "$weekday{$wday} ");
michael@0 180 print (TRENDTABLE "$mon/$mday/$year ");
michael@0 181 printf (TRENDTABLE "%02d:%02d:%02d", $hour, $min, $sec);
michael@0 182 print (TRENDTABLE "</font></center>");
michael@0 183 print (TRENDTABLE "<BR>");
michael@0 184 print(TRENDTABLE "<!-- First the headings (static) -->\n" );
michael@0 185 print(TRENDTABLE "<TABLE BORDER=1 width=99% BGCOLOR='white'>\n" );
michael@0 186 print(TRENDTABLE "<TR >\n" );
michael@0 187 print(TRENDTABLE "<TD ROWSPAN=2 width=5% align=center valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 188 print(TRENDTABLE "<B>Pull-ID</B>\n" );
michael@0 189 print(TRENDTABLE "</TD>\n" );
michael@0 190 print(TRENDTABLE "<TD ROWSPAN=2 align=center width=5% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 191 print(TRENDTABLE "<B>Build-ID</B>\n" );
michael@0 192 print(TRENDTABLE "</TD>\n" );
michael@0 193 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 194 print(TRENDTABLE "<B>Parsing</B>\n" );
michael@0 195 print(TRENDTABLE "</TD>\n" );
michael@0 196 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 197 print(TRENDTABLE "<B>Content Creation</B>\n" );
michael@0 198 print(TRENDTABLE "</TD>\n" );
michael@0 199 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 200 print(TRENDTABLE "<B>Frame Creation</B>\n" );
michael@0 201 print(TRENDTABLE "</TD>\n" );
michael@0 202 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 203 print(TRENDTABLE "<B>Style Resolution</B>\n" );
michael@0 204 print(TRENDTABLE "</TD>\n" );
michael@0 205 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 206 print(TRENDTABLE "<B>Reflow</B>\n" );
michael@0 207 print(TRENDTABLE "</TD>\n" );
michael@0 208 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 209 print(TRENDTABLE "<B>Total Layout</B>\n" );
michael@0 210 print(TRENDTABLE "<TD ROWSPAN=1 align=center width=10% valign=top BGCOLOR='#E0E0E0'>\n" );
michael@0 211 print(TRENDTABLE "<B>Total Time</B>\n" );
michael@0 212 print(TRENDTABLE "</TD>\n" );
michael@0 213 print(TRENDTABLE "</TR>\n" );
michael@0 214 print(TRENDTABLE "<TD>\n" );
michael@0 215 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 216 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 217 print(TRENDTABLE "</TD>\n" );
michael@0 218 print(TRENDTABLE "<TD>\n" );
michael@0 219 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 220 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 221 print(TRENDTABLE "</TD>\n" );
michael@0 222 print(TRENDTABLE "<TD>\n" );
michael@0 223 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 224 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 225 print(TRENDTABLE "</TD>\n" );
michael@0 226 print(TRENDTABLE "<TD>\n" );
michael@0 227 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 228 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 229 print(TRENDTABLE "</TD>\n" );
michael@0 230 print(TRENDTABLE "<TD>\n" );
michael@0 231 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 232 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 233 print(TRENDTABLE "</TD>\n" );
michael@0 234 print(TRENDTABLE "<TD>\n" );
michael@0 235 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 236 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=50%>Sec</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>%</TD></TR></TABLE>\n" );
michael@0 237 print(TRENDTABLE "</TD>\n" );
michael@0 238 print(TRENDTABLE "<TD>\n" );
michael@0 239 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center BGCOLOR='#E0E0E0'>\n" );
michael@0 240 print(TRENDTABLE "<TR><TD BGCOLOR='#FFFFC6' align=left width=100%>Sec</TD></TR></TABLE>\n" );
michael@0 241 print(TRENDTABLE "</TD>\n" );
michael@0 242 close(TRENDTABLE);
michael@0 243 }
michael@0 244
michael@0 245 #------------------------------------------------------------------------------
michael@0 246 #
michael@0 247 sub ProcessEntry {
michael@0 248
michael@0 249 my $PullID;
michael@0 250 my $BuildID;
michael@0 251 # - Time variables
michael@0 252 my $Parse_Time=0;
michael@0 253 my $Content_Time=0;
michael@0 254 my $Frame_Time=0;
michael@0 255 my $Style_Time=0;
michael@0 256 my $Reflow_Time=0;
michael@0 257 my $Layout_Time=0;
michael@0 258 my $Total_Time=0;
michael@0 259 # - percentage variables
michael@0 260 my $Parse_Per=0;
michael@0 261 my $Content_Per=0;
michael@0 262 my $Frame_Per=0;
michael@0 263 my $Style_Per=0;
michael@0 264 my $Reflow_Per=0;
michael@0 265 my $Layout_Per=0;
michael@0 266 # - weight variables
michael@0 267 my $Parse_Weight=0;
michael@0 268 my $Content_Weight=0;
michael@0 269 my $Frame_Weight=0;
michael@0 270 my $Style_Weight=0;
michael@0 271 my $Reflow_Weight=0;
michael@0 272 my $Layout_Weight=0;
michael@0 273 my $Total_Weight=0;
michael@0 274
michael@0 275 debug_print( "Process Entry\n" );
michael@0 276 my @EntryLine =@_;
michael@0 277
michael@0 278 open(TRENDTABLE, ">> TrendTable.html") or die "Cannot open trend-table file (TrendTable.html) in ProcessHeader\n";
michael@0 279 $i=0;
michael@0 280 $PullID = $EntryLine[$i++];
michael@0 281 debug_print( "PullID: $PullID \n" );
michael@0 282 $BuildID = $EntryLine[$i++];
michael@0 283 debug_print( "BuildID: $BuildID \n" );
michael@0 284 $Parse_Time = $EntryLine[$i++];
michael@0 285 debug_print( "Parse_Time : $Parse_Time \n" );
michael@0 286 $Parse_Per = $EntryLine[$i++];
michael@0 287 debug_print( "Parse_Per : $Parse_Per \n" );
michael@0 288 $Content_Time = $EntryLine[$i++];
michael@0 289 debug_print( "Content_Time : $Content_Time \n" );
michael@0 290 $Content_Per = $EntryLine[$i++];
michael@0 291 debug_print( "Content_Per : $Content_Per \n" );
michael@0 292 $Frame_Time = $EntryLine[$i++];
michael@0 293 debug_print( "Frame_Time : $Frame_Time \n" );
michael@0 294 $Frame_Per = $EntryLine[$i++];
michael@0 295 debug_print( "Frame_Per : $Frame_Per \n" );
michael@0 296 $Style_Time = $EntryLine[$i++];
michael@0 297 debug_print( "Style_Time : $Style_Time \n" );
michael@0 298 $Style_Per = $EntryLine[$i++];
michael@0 299 debug_print( "Style_Per : $Style_Per \n" );
michael@0 300 $Reflow_Time = $EntryLine[$i++];
michael@0 301 debug_print( "Reflow_Time : $Reflow_Time \n" );
michael@0 302 $Reflow_Per = $EntryLine[$i++];
michael@0 303 debug_print( "Reflow_Per : $Reflow_Per \n" );
michael@0 304 $Layout_Time = $EntryLine[$i++];
michael@0 305 debug_print( "Layout_Time : $Layout_Time \n" );
michael@0 306 $Layout_Per = $EntryLine[$i++];
michael@0 307 debug_print( "Layout_Per : $Layout_Per \n" );
michael@0 308 $Total_Time = $EntryLine[$i++];
michael@0 309 debug_print( "Total_Time : $Total_Time \n" );
michael@0 310
michael@0 311 if( $Parse_Time_Max > 0 ){
michael@0 312 $ParseWeight = $Parse_Time / $Parse_Time_Max * 100;
michael@0 313 debug_print( "ParseWeight = $ParseWeight \n" );
michael@0 314 }
michael@0 315 if( $Content_Time_Max > 0 ){
michael@0 316 $ContentWeight = $Content_Time / $Content_Time_Max * 100;
michael@0 317 debug_print( "ContentWeight = $ContentWeight \n" );
michael@0 318 }
michael@0 319 if( $Frame_Time_Max > 0 ){
michael@0 320 $FrameWeight = $Frame_Time / $Frame_Time_Max * 100;
michael@0 321 debug_print( "FrameWeight = $FrameWeight \n" );
michael@0 322 }
michael@0 323 if( $Style_Time_Max > 0 ){
michael@0 324 $StyleWeight = $Style_Time / $Style_Time_Max * 100;
michael@0 325 debug_print( "StyleWeight = $StyleWeight \n" );
michael@0 326 }
michael@0 327 if( $Reflow_Time_Max > 0 ){
michael@0 328 $ReflowWeight = $Reflow_Time / $Reflow_Time_Max * 100;
michael@0 329 debug_print( "ReflowWeight = $ReflowWeight \n" );
michael@0 330 }
michael@0 331 if( $Layout_Time_Max > 0 ){
michael@0 332 $LayoutWeight = $Layout_Time / $Layout_Time_Max * 100;
michael@0 333 debug_print( "LayoutWeight = $LayoutWeight \n" );
michael@0 334 }
michael@0 335 if( $Total_Time_Max > 0 ){
michael@0 336 $TotalWeight = $Total_Time / $Total_Time_Max * 100;
michael@0 337 debug_print( "TotalWeight = $TotalWeight \n" );
michael@0 338 }
michael@0 339
michael@0 340 $bldID;
michael@0 341 @bldIDParts = split( /:/, $BuildID );
michael@0 342 $bldID = $bldIDParts[1];
michael@0 343 print(TRENDTABLE "<!-- Next entry... -->\n");
michael@0 344 print(TRENDTABLE "<TR> \n");
michael@0 345 print(TRENDTABLE "<TD ROWSPAN=1>$PullID</TD>\n");
michael@0 346 print(TRENDTABLE "<TD ROWSPAN=1>$bldID</TD>\n");
michael@0 347 print(TRENDTABLE "<!-- Parse Time -->\n");
michael@0 348 print(TRENDTABLE "<TD>\n");
michael@0 349 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 350 printf(TRENDTABLE "%4.3f", $Parse_Time);
michael@0 351 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>");
michael@0 352 printf(TRENDTABLE "%4.3f",$Parse_Per);
michael@0 353 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$ParseWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 354 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 355 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $ParseWeight);
michael@0 356 print(TRENDTABLE "</TD>\n");
michael@0 357 print(TRENDTABLE "<!-- Content Time -->\n");
michael@0 358 print(TRENDTABLE "<TD>\n");
michael@0 359 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 360 printf(TRENDTABLE "%4.3f",$Content_Time);
michael@0 361 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>");
michael@0 362 printf(TRENDTABLE "%4.3f",$Content_Per);
michael@0 363 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$ContentWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 364 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 365 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $ContentWeight);
michael@0 366 print(TRENDTABLE "</TD>\n");
michael@0 367 print(TRENDTABLE "<!-- Frames Time -->\n");
michael@0 368 print(TRENDTABLE "<TD>\n");
michael@0 369 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 370 printf(TRENDTABLE "%4.3f",$Frame_Time);
michael@0 371 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%> ");
michael@0 372 printf(TRENDTABLE "%4.3f",$Frame_Per);
michael@0 373 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$FrameWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 374 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 375 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $FrameWeight);
michael@0 376 print(TRENDTABLE "</TD>\n");
michael@0 377 print(TRENDTABLE "<!-- Style Time -->\n");
michael@0 378 print(TRENDTABLE "<TD>\n");
michael@0 379 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 380 printf(TRENDTABLE "%4.3f",$Style_Time);
michael@0 381 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>");
michael@0 382 printf(TRENDTABLE "%4.3f",$Style_Per);
michael@0 383 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$StyleWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 384 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 385 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $StyleWeight);
michael@0 386 print(TRENDTABLE "</TD>\n");
michael@0 387 print(TRENDTABLE "<!-- Reflow Time -->\n");
michael@0 388 print(TRENDTABLE "<TD>\n");
michael@0 389 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 390 printf(TRENDTABLE "%4.3f",$Reflow_Time);
michael@0 391 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>");
michael@0 392 printf(TRENDTABLE "%4.3f",$Reflow_Per);
michael@0 393 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$ReflowWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 394 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 395 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $ReflowWeight);
michael@0 396 print(TRENDTABLE "</TD>\n");
michael@0 397 print(TRENDTABLE "<!-- Layout Time -->\n");
michael@0 398 print(TRENDTABLE "<TD>\n");
michael@0 399 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=50%>");
michael@0 400 printf(TRENDTABLE "%4.3f",$Layout_Time);
michael@0 401 print(TRENDTABLE "</TD><TD BGCOLOR='#CFEEF7' align=right width=50%>");
michael@0 402 printf(TRENDTABLE "%4.3f",$Layout_Per);
michael@0 403 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$LayoutWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 404 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 405 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $LayoutWeight);
michael@0 406 print(TRENDTABLE "</TD>\n");
michael@0 407 print(TRENDTABLE "<!-- Parse Time -->\n");
michael@0 408 print(TRENDTABLE "<TD>\n");
michael@0 409 print(TRENDTABLE "<TABLE BORDER=0 width=100% align=center COLS=2><TR><TD BGCOLOR='#FFFFC6' align=left width=100%>");
michael@0 410 printf(TRENDTABLE "%4.3f",$Total_Time);
michael@0 411 print(TRENDTABLE "</TD></TR><TR><TD colspan=2><table WIDTH=$TotalWeight% bgcolor=blue><tr><td><font align=center size=-2>&nbsp;");
michael@0 412 print(TRENDTABLE "</td></font></tr></table></TD></TR></TABLE>");
michael@0 413 printf(TRENDTABLE "<font size=-1>%4.2f % </font>", $TotalWeight);
michael@0 414 print(TRENDTABLE "</TD>\n");
michael@0 415 print(TRENDTABLE "</TR>\n");
michael@0 416
michael@0 417 close(TRENDTABLE);
michael@0 418 }
michael@0 419
michael@0 420 #------------------------------------------------------------------------------
michael@0 421 #
michael@0 422 sub ProcessFooter {
michael@0 423 debug_print("ProcessHeader\n");
michael@0 424 open(TRENDTABLE, ">> TrendTable.html") or die "Cannot open trend-table file (TrendTable.html) in ProcessFooter\n";
michael@0 425
michael@0 426 print(TRENDTABLE "</TABLE>\n");
michael@0 427 print(TRENDTABLE "</BODY>\n");
michael@0 428
michael@0 429 close(TRENDTABLE);
michael@0 430 }

mercurial