From: Ingo Molnar <mingo@elte.hu>
To: Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp>
Cc: linux-kernel@vger.kernel.org,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Paul Mackerras <paulus@samba.org>
Subject: Re: [PATCH v2 0/4] perf bench: Common option for specifying style formatting
Date: Tue, 10 Nov 2009 04:58:12 +0100 [thread overview]
Message-ID: <20091110035812.GB29454@elte.hu> (raw)
In-Reply-To: <1257808802-9420-1-git-send-email-mitake@dcl.info.waseda.ac.jp>
* Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp> wrote:
> This patch series adds new option "--format" to
> bench subcommand of perf.
>
> Users of perf bench will be able to specify
> style formatting with this option in common way.
>
> Hitoshi Mitake (4):
> perf bench: Add stuffs to bench.h for unified output formatting
> perf bench: Modify builtin-bench.c for processing common options
> perf bench: Modified bench/bench-messaging.c to adopt unified output
> formatting
> perf bench: Modify builtin-pipe.c for processing common options
>
> tools/perf/bench/bench.h | 9 ++++
> tools/perf/bench/sched-messaging.c | 18 +++++---
> tools/perf/bench/sched-pipe.c | 22 ++++++----
> tools/perf/builtin-bench.c | 79 +++++++++++++++++++++++++++++------
> 4 files changed, 99 insertions(+), 29 deletions(-)
Very nice, applied to tip:perf/bench, thanks!
A (very) small detail about initializers in bench.h:
- No need to break the line for function prototypes, they are more
readable in a single line. (even if checkpatch complains about it)
- We try to align definitions / structure fields vertically, to make it
all a bit more readable.
Something like the (untested) cleanup patch below. (Just put it into
your next batch of commits.)
Thanks,
Ingo
---
tools/perf/bench/bench.h | 16 +++++++---------
1 file changed, 7 insertions(+), 9 deletions(-)
Index: tip/tools/perf/bench/bench.h
===================================================================
--- tip.orig/tools/perf/bench/bench.h
+++ tip/tools/perf/bench/bench.h
@@ -1,17 +1,15 @@
#ifndef BENCH_H
#define BENCH_H
-extern int bench_sched_messaging(int argc, const char **argv,
- const char *prefix);
-extern int bench_sched_pipe(int argc, const char **argv,
- const char *prefix);
+extern int bench_sched_messaging(int argc, const char **argv, const char *prefix);
+extern int bench_sched_pipe(int argc, const char **argv, const char *prefix);
-#define BENCH_FORMAT_DEFAULT_STR "default"
-#define BENCH_FORMAT_DEFAULT 0
-#define BENCH_FORMAT_SIMPLE_STR "simple"
-#define BENCH_FORMAT_SIMPLE 1
+#define BENCH_FORMAT_DEFAULT_STR "default"
+#define BENCH_FORMAT_DEFAULT 0
+#define BENCH_FORMAT_SIMPLE_STR "simple"
+#define BENCH_FORMAT_SIMPLE 1
-#define BENCH_FORMAT_UNKNOWN -1
+#define BENCH_FORMAT_UNKNOWN -1
extern int bench_format;
next prev parent reply other threads:[~2009-11-10 3:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-09 23:19 Hitoshi Mitake
2009-11-09 23:19 ` [PATCH v2 1/4] perf bench: Add stuffs to bench.h for unified output formatting Hitoshi Mitake
2009-11-10 4:22 ` [tip:perf/bench] perf bench: Add format constants " tip-bot for Hitoshi Mitake
2009-11-09 23:20 ` [PATCH v2 2/4] perf bench: Modify builtin-bench.c for processing common options Hitoshi Mitake
2009-11-10 4:22 ` [tip:perf/bench] " tip-bot for Hitoshi Mitake
2009-11-09 23:20 ` [PATCH v2 3/4] perf bench: Modified bench/bench-messaging.c to adopt unified output formatting Hitoshi Mitake
2009-11-10 4:22 ` [tip:perf/bench] perf bench: Modify " tip-bot for Hitoshi Mitake
2009-11-09 23:20 ` [PATCH v2 4/4] perf bench: Modify builtin-pipe.c for processing common options Hitoshi Mitake
2009-11-10 4:22 ` [tip:perf/bench] " tip-bot for Hitoshi Mitake
2009-11-10 3:58 ` Ingo Molnar [this message]
2009-11-10 7:51 ` [PATCH v2 0/4] perf bench: Common option for specifying style formatting Hitoshi Mitake
2009-11-10 8:01 ` Ingo Molnar
2009-11-10 8:23 ` Hitoshi Mitake
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091110035812.GB29454@elte.hu \
--to=mingo@elte.hu \
--cc=a.p.zijlstra@chello.nl \
--cc=linux-kernel@vger.kernel.org \
--cc=mitake@dcl.info.waseda.ac.jp \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®