diff options
author | Steven Rostedt <srostedt@redhat.com> | 2009-11-20 10:46:52 -0500 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2009-11-20 10:46:52 -0500 |
commit | a37aa2d8e1276189143c85cc79614a993ee1784b (patch) | |
tree | fc073ffd8b18bce7700992f5e46fc93e333da45d | |
parent | 9a7533f99ed008e03de9455df31075e77789a207 (diff) |
Fix up function graph time spacing
The conversion of the parse-events.c to use trace-seq, broke the spacing
of the function graph tracer timings.
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
-rw-r--r-- | parse-events.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/parse-events.c b/parse-events.c index 2bb2ad9..ab97938 100644 --- a/parse-events.c +++ b/parse-events.c | |||
@@ -2721,14 +2721,17 @@ static void print_graph_duration(struct trace_seq *s, unsigned long long duratio | |||
2721 | sprintf(msecs_str, "%lu", usecs); | 2721 | sprintf(msecs_str, "%lu", usecs); |
2722 | 2722 | ||
2723 | /* Print msecs */ | 2723 | /* Print msecs */ |
2724 | len = trace_seq_printf(s, "%lu", usecs); | 2724 | len = s->len; |
2725 | trace_seq_printf(s, "%lu", usecs); | ||
2725 | 2726 | ||
2726 | /* Print nsecs (we don't want to exceed 7 numbers) */ | 2727 | /* Print nsecs (we don't want to exceed 7 numbers) */ |
2727 | if (len < 7) { | 2728 | if ((s->len - len) < 7) { |
2728 | snprintf(nsecs_str, 8 - len, "%03lu", nsecs_rem); | 2729 | snprintf(nsecs_str, 8 - (s->len - len), "%03lu", nsecs_rem); |
2729 | len += trace_seq_printf(s, ".%s", nsecs_str); | 2730 | trace_seq_printf(s, ".%s", nsecs_str); |
2730 | } | 2731 | } |
2731 | 2732 | ||
2733 | len = s->len - len; | ||
2734 | |||
2732 | trace_seq_puts(s, " us "); | 2735 | trace_seq_puts(s, " us "); |
2733 | 2736 | ||
2734 | /* Print remaining spaces to fit the row's width */ | 2737 | /* Print remaining spaces to fit the row's width */ |