aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharles Baylis <charles.baylis@linaro.org>2017-12-12 14:21:39 +0000
committerCharles Baylis <charles.baylis@linaro.org>2017-12-12 14:21:39 +0000
commit979645dee406588d000851d2cb08891c16c73281 (patch)
tree37cc54eab70685c81faeb2c34c8e758d8ba35e4f
parenta871ab4e1ccd6d11e5a9cd2db934de5f4c2bf51e (diff)
Add time stamps to hover profile information
Change-Id: Iaea7e486c0a412cd53fc422d8fa5c5490c0475ac
-rw-r--r--perf-utilization.pl13
1 files changed, 9 insertions, 4 deletions
diff --git a/perf-utilization.pl b/perf-utilization.pl
index c929fd7..0c66451 100644
--- a/perf-utilization.pl
+++ b/perf-utilization.pl
@@ -88,7 +88,7 @@ span#hoverprofile {
z-index: 1;
}
-th {
+th.rotate {
writing-mode: vertical-lr;
transform:rotate(190deg);
}
@@ -112,20 +112,24 @@ EOF
print $fh "<tr>";
for (my $c=0; $c<=$max_cpu; $c++)
{
- print $fh "<th>CPU$c</th>";
+ print $fh "<th class=rotate>CPU$c</th>";
}
print $fh "</tr>\n";
-my $start_time=$time[0];
+my $first_time=$time[0];
+my $start_time=$first_time;
my %counts;
my %locs;
for (my $i=0;$i<$#cpu;$i++)
{
if ($time[$i] > ($start_time + $REPORT_INTERVAL))
{
- $start_time=$time[$i];
+ my $row_time=$start_time-$first_time;
+ # advance the start time for the next row.
+ $start_time+=$REPORT_INTERVAL;
my $str;
+
for (my $c=0; $c<=$max_cpu; $c++)
{
my $n = $counts{$c};
@@ -137,6 +141,7 @@ for (my $i=0;$i<$#cpu;$i++)
if ($n > 0) {
$str .= qq(<span id="hoverprofile">);
my $lochash=$locs{$c};
+ $str.="Time = ${row_time}s<p>";
$str.="<pre>";
my @loc_list = sort { $lochash->{$b} <=> $lochash->{$a} } keys %{$lochash};
foreach my $loc (@loc_list)