Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-03 Thread Arnaldo Carvalho de Melo
Em Fri, Apr 03, 2015 at 01:11:47PM -0300, Arnaldo Carvalho de Melo escreveu: > Em Thu, Apr 02, 2015 at 01:59:34PM +0200, Peter Zijlstra escreveu: > > On Thu, Apr 02, 2015 at 12:01:53PM +0300, Adrian Hunter wrote: > > > But personally I think the "include" approach is too ugly. I would just > > > ad

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-03 Thread Arnaldo Carvalho de Melo
Em Thu, Apr 02, 2015 at 01:59:34PM +0200, Peter Zijlstra escreveu: > On Thu, Apr 02, 2015 at 12:01:53PM +0300, Adrian Hunter wrote: > > But personally I think the "include" approach is too ugly. I would just > > add a function instead. Something like: > > You've not stared at the kernel tracepoint

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Arnaldo Carvalho de Melo
Em Thu, Apr 02, 2015 at 10:12:50AM +0200, Ingo Molnar escreveu: > * Peter Zijlstra wrote: > > tools/perf/util/print_helper.h |7 + > > 6 files changed, 170 insertions(+), 174 deletions(-) > > Acked-by: Ingo Molnar I'll get this in tomorrow, just finishing a pull req now, - Arnaldo -- To u

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Adrian Hunter
On 02/04/15 14:59, Peter Zijlstra wrote: > On Thu, Apr 02, 2015 at 12:01:53PM +0300, Adrian Hunter wrote: >> But personally I think the "include" approach is too ugly. I would just >> add a function instead. Something like: > > You've not stared at the kernel tracepoint code long enough ;-) I wil

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Peter Zijlstra
On Thu, Apr 02, 2015 at 12:01:53PM +0300, Adrian Hunter wrote: > But personally I think the "include" approach is too ugly. I would just > add a function instead. Something like: You've not stared at the kernel tracepoint code long enough ;-) Something like so then? --- Subject: perf, tools: Mer

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Jiri Olsa
On Wed, Apr 01, 2015 at 06:26:38PM +0200, Peter Zijlstra wrote: SNIP > - ret += PRINT_ATTR_U32(wakeup_events); > - ret += PRINT_ATTR_U32(wakeup_watermark); > - ret += PRINT_ATTR_X32(bp_type); > - ret += PRINT_ATTR_X64(bp_addr); > - ret += PRINT_ATTR_X64(config1); > - ret +

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Adrian Hunter
On 01/04/15 19:52, Jiri Olsa wrote: > On Wed, Apr 01, 2015 at 06:26:38PM +0200, Peter Zijlstra wrote: >> >> With some feedback from Jolsa, who showed me how to trigger the actual >> outputs. > > adding Adrian to CC as he's the original author AFAIK I wanted a compact format, and the omission of n

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-02 Thread Ingo Molnar
* Peter Zijlstra wrote: > With some feedback from Jolsa, who showed me how to trigger the actual > outputs. > > --- > > Subject: perf, tools: Merge all perf_event_attr print functions > From: Peter Zijlstra > Date: Tue Mar 31 13:01:54 CEST 2015 > > Currently there's 3 (that I found) differen

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-01 Thread Jiri Olsa
On Wed, Apr 01, 2015 at 06:26:38PM +0200, Peter Zijlstra wrote: > > With some feedback from Jolsa, who showed me how to trigger the actual > outputs. adding Adrian to CC as he's the original author AFAIK jirka > > --- > > Subject: perf, tools: Merge all perf_event_attr print functions > From:

Re: [RFC][PATCH] perf tools: unify perf_event_attr printing

2015-04-01 Thread Peter Zijlstra
With some feedback from Jolsa, who showed me how to trigger the actual outputs. --- Subject: perf, tools: Merge all perf_event_attr print functions From: Peter Zijlstra Date: Tue Mar 31 13:01:54 CEST 2015 Currently there's 3 (that I found) different and incomplete implementations of printing p