Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 191338
b: refs/heads/master
c: e366728
h: refs/heads/master
v: v3
  • Loading branch information
Tom Zanussi authored and Arnaldo Carvalho de Melo committed May 10, 2010
1 parent 69c0db3 commit a70e922
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e88a4bfbcda440b1c6b9d5a31a554a6ad9686182
refs/heads/master: e366728d57cb8c708f76b282ae194c6044355b5f
12 changes: 8 additions & 4 deletions trunk/tools/perf/scripts/perl/wakeup-latency.pl
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@

my $max_wakeup_latency;
my $min_wakeup_latency;
my $total_wakeup_latency;
my $total_wakeups;
my $total_wakeup_latency = 0;
my $total_wakeups = 0;

sub sched::sched_switch
{
Expand Down Expand Up @@ -67,8 +67,12 @@ sub trace_end
{
printf("wakeup_latency stats:\n\n");
print "total_wakeups: $total_wakeups\n";
printf("avg_wakeup_latency (ns): %u\n",
avg($total_wakeup_latency, $total_wakeups));
if ($total_wakeups) {
printf("avg_wakeup_latency (ns): %u\n",
avg($total_wakeup_latency, $total_wakeups));
} else {
printf("avg_wakeup_latency (ns): N/A\n");
}
printf("min_wakeup_latency (ns): %u\n", $min_wakeup_latency);
printf("max_wakeup_latency (ns): %u\n", $max_wakeup_latency);

Expand Down

0 comments on commit a70e922

Please sign in to comment.