Re: [PATCH 28/30] perf evsel: Provide a new constructor for tracepoints

2012-09-25 Thread Arnaldo Carvalho de Melo
Em Tue, Sep 25, 2012 at 01:26:46PM +0900, Namhyung Kim escreveu: > On Mon, 24 Sep 2012 12:59:42 -0300, Arnaldo Carvalho de Melo wrote: > > + if (size == alloc_size) { > > + alloc_size += BUFSIZ; > > + nbf = realloc(bf, alloc_size); > > +

Re: [PATCH 28/30] perf evsel: Provide a new constructor for tracepoints

2012-09-24 Thread Namhyung Kim
On Mon, 24 Sep 2012 12:59:42 -0300, Arnaldo Carvalho de Melo wrote: > From: Arnaldo Carvalho de Melo > > The existing constructor receives a perf_event_attr filled with the > event type and the config. > > To reduce the boilerplate for tracepoints, provide a new constructor, > perf_evsel__newtp()

[PATCH 28/30] perf evsel: Provide a new constructor for tracepoints

2012-09-24 Thread Arnaldo Carvalho de Melo
From: Arnaldo Carvalho de Melo The existing constructor receives a perf_event_attr filled with the event type and the config. To reduce the boilerplate for tracepoints, provide a new constructor, perf_evsel__newtp() that receives the tracepoint name and will open the debugfs file, call into libt