Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-28 Thread John Garry
On 28/06/2019 11:40, Jiri Olsa wrote: On Thu, Jun 27, 2019 at 05:27:32PM +0100, John Garry wrote: SNIP heya, sry for late reply if tok is NULL in here we crash As I see, tok could not be NULL. If str contains no delimiters, then we just return same as str in tok. Can you see tok being

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-28 Thread Jiri Olsa
On Thu, Jun 27, 2019 at 05:27:32PM +0100, John Garry wrote: SNIP > > > > > > heya, > > > sry for late reply > > > > > > > > > > > > if tok is NULL in here we crash > > > > > > > > > > > > > As I see, tok could not be NULL. If str contains no delimiters, then > > > > we just > > > > return sa

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-27 Thread Jiri Olsa
On Thu, Jun 27, 2019 at 05:27:32PM +0100, John Garry wrote: SNIP > > loop 2. tok=ddrc name=ddrc0 > > loop 3. tok=NULL -> breakout and return true > > > > A couple of notes: > > a. loop 1. could be omitted, but the code becomes a bit more complicated > > 2. I don't have to advance name. But then

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-27 Thread John Garry
On 21/06/2019 11:42, John Garry wrote: On 20/06/2019 19:25, Jiri Olsa wrote: On Mon, Jun 17, 2019 at 10:06:08AM +0100, John Garry wrote: On 16/06/2019 10:58, Jiri Olsa wrote: On Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry wrote: The jevent "Unit" field is used for uncore PMU alias defin

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-21 Thread John Garry
On 20/06/2019 19:25, Jiri Olsa wrote: On Mon, Jun 17, 2019 at 10:06:08AM +0100, John Garry wrote: On 16/06/2019 10:58, Jiri Olsa wrote: On Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry wrote: The jevent "Unit" field is used for uncore PMU alias definition. The form uncore_pmu_example_X is

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-20 Thread Jiri Olsa
On Mon, Jun 17, 2019 at 10:06:08AM +0100, John Garry wrote: > On 16/06/2019 10:58, Jiri Olsa wrote: > > On Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry wrote: > > > The jevent "Unit" field is used for uncore PMU alias definition. > > > > > > The form uncore_pmu_example_X is supported, where "

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-17 Thread John Garry
On 16/06/2019 10:58, Jiri Olsa wrote: On Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry wrote: The jevent "Unit" field is used for uncore PMU alias definition. The form uncore_pmu_example_X is supported, where "X" is a wildcard, to support multiple instances of the same PMU in a system. Unf

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-16 Thread Jiri Olsa
On Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry wrote: > The jevent "Unit" field is used for uncore PMU alias definition. > > The form uncore_pmu_example_X is supported, where "X" is a wildcard, > to support multiple instances of the same PMU in a system. > > Unfortunately this format not su

Re: [PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-14 Thread Arnaldo Carvalho de Melo
Em Fri, Jun 14, 2019 at 10:08:00PM +0800, John Garry escreveu: > The jevent "Unit" field is used for uncore PMU alias definition. > > The form uncore_pmu_example_X is supported, where "X" is a wildcard, > to support multiple instances of the same PMU in a system. > > Unfortunately this format not

[PATCH v2 2/5] perf pmu: Support more complex PMU event aliasing

2019-06-14 Thread John Garry
The jevent "Unit" field is used for uncore PMU alias definition. The form uncore_pmu_example_X is supported, where "X" is a wildcard, to support multiple instances of the same PMU in a system. Unfortunately this format not suitable for all uncore PMUs; take the Hisi DDRC uncore PMU for example, w