Re: [PATCH RFC v4 00/13] perf pmu-events: Support event aliasing for system PMUs

2020-10-08 Thread kajoljain
On 10/8/20 3:45 PM, John Garry wrote: > Currently event aliasing and metrics for only CPU and uncore PMUs is > supported. In fact, only uncore PMUs aliasing is supported for when the > uncore PMUs are fixed for a CPU, which may not always be the case for > certain architectures. > > This

Re: [PATCH] perf/core: Fix hung issue on perf stat command during cpu hotplug

2020-10-08 Thread kajoljain
On 8/27/20 12:17 PM, Kajol Jain wrote: > Commit 2ed6edd33a21 ("perf: Add cond_resched() to task_function_call()") > added assignment of ret value as -EAGAIN in case function > call to 'smp_call_function_single' fails. > For non-zero ret value, it did > 'ret = !ret ? data.ret : -EAGAIN;', which

Re: [PATCH] perf jevents: Fix event code for events referencing std arch events

2020-10-09 Thread kajoljain
On 10/8/20 8:49 PM, John Garry wrote: > The event code for events referencing std arch events is incorrectly > evaluated in json_events(). > > The issue is that je.event is evaluated properly from try_fixup(), but > later NULLified from the real_event() call, as "event" may be NULL. > > Fix

Re: [PATCH] perf vendor events: Fix typos in power8 PMU events

2020-10-12 Thread kajoljain
On 10/12/20 10:32 AM, Sandipan Das wrote: > This replaces the incorrectly spelled word "localtion" > with "location" in some power8 PMU event descriptions. Patch looks good to me, Thanks for correcting it. Reviewed-By: Kajol Jain Thanks, Kajol Jain > > Fixes: 2a81fa3bb5ed ("perf vendor

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-26 Thread kajoljain
On 8/26/20 4:27 PM, Jiri Olsa wrote: > On Tue, Aug 25, 2020 at 01:10:41PM +0530, Kajol Jain wrote: > > SNIP > >> diff --git a/tools/perf/pmu-events/jevents.h >> b/tools/perf/pmu-events/jevents.h >> index 2afc8304529e..e696edf70e9a 100644 >> --- a/tools/perf/pmu-events/jevents.h >> +++

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-26 Thread kajoljain
On 8/25/20 9:17 PM, Andi Kleen wrote: > On Tue, Aug 25, 2020 at 01:10:41PM +0530, Kajol Jain wrote: >> This patch adds new structure called 'json_event' inside jevents.h >> file to improve the callback prototype inside jevent files. >> Initially, whenever user want to add new field, they need

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-26 Thread kajoljain
On 8/26/20 4:26 PM, Jiri Olsa wrote: > On Tue, Aug 25, 2020 at 01:10:41PM +0530, Kajol Jain wrote: > > SNIP > >> { >> /* try to find matching event from arch standard values */ >> struct event_struct *es; >> @@ -498,8 +486,7 @@ try_fixup(const char *fn, char *arch_std, char

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-26 Thread kajoljain
On 8/26/20 4:27 PM, Jiri Olsa wrote: > On Tue, Aug 25, 2020 at 01:10:41PM +0530, Kajol Jain wrote: > > SNIP > >> } >> } >> >> -static int save_arch_std_events(void *data, char *name, char *event, >> -char *desc, char *long_desc, char *pmu, >> -

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-26 Thread kajoljain
On 8/26/20 4:30 PM, Jiri Olsa wrote: > On Tue, Aug 25, 2020 at 09:14:11AM +0100, John Garry wrote: > > SNIP > >>> goto free_strings; >>> } >>> - err = func(data, name, real_event(name, event), desc, long_desc, >>> - pmu,

Re: [RFC] perf/core: Fixes hung issue on perf stat command during cpu hotplug

2020-08-26 Thread kajoljain
On 8/26/20 6:51 PM, Arnaldo Carvalho de Melo wrote: > Em Wed, Aug 26, 2020 at 03:02:36PM +0530, Kajol Jain escreveu: >> Commit 2ed6edd33a21 ("perf: Add cond_resched() to task_function_call()") >> added assignment of ret value as -EAGAIN in case function >> call to 'smp_call_function_single'

Re: [PATCH v2] perf expr: Force encapsulation on expr_id_data

2020-08-27 Thread kajoljain
On 8/26/20 9:27 PM, Jiri Olsa wrote: > On Wed, Aug 26, 2020 at 08:30:55AM -0700, Ian Rogers wrote: >> This patch resolves some undefined behavior where variables in >> expr_id_data were accessed (for debugging) without being defined. To >> better enforce the tagged union behavior, the struct is

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-27 Thread kajoljain
On 8/26/20 5:03 PM, John Garry wrote: > On 26/08/2020 12:24, kajoljain wrote: >> >> >> On 8/26/20 4:30 PM, Jiri Olsa wrote: >>> On Tue, Aug 25, 2020 at 09:14:11AM +0100, John Garry wrote: >>> >>> SNIP >>> >>>>>   

Re: [RFC] perf/jevents: Add new structure to pass json fields.

2020-08-27 Thread kajoljain
On 8/26/20 5:29 PM, Jiri Olsa wrote: > On Wed, Aug 26, 2020 at 05:02:04PM +0530, kajoljain wrote: >> >> >> On 8/26/20 4:26 PM, Jiri Olsa wrote: >>> On Tue, Aug 25, 2020 at 01:10:41PM +0530, Kajol Jain wrote: >>> >>> SNIP >>> >>

Re: [perf/core] 16fb162e78: WARNING:at_kernel/events/core.c:#list_add_event

2020-08-27 Thread kajoljain
On 8/27/20 2:07 PM, kernel test robot wrote: > Greeting, > > FYI, we noticed the following commit (built with gcc-9): > > commit: 16fb162e7868b8f3c1fc09ef0d683c9554cb6404 ("[RFC] perf/core: Fixes > hung issue on perf stat command during cpu hotplug") > url: >

Re: [PATCH] perf stat: update POWER9 metrics to utilize other metrics

2020-08-13 Thread kajoljain
On 8/14/20 9:13 AM, Ian Rogers wrote: > On Thu, Aug 13, 2020 at 3:21 PM Paul A. Clarke wrote: >> >> These changes take advantage of the new capability added in >> merge commit 00e4db51259a5f936fec1424b884f029479d3981 >> "Allow using computed metrics in calculating other metrics". >> >> The net

Re: [PATCH v6 1/5] perf/jevents: Remove jevents.h file

2020-08-31 Thread kajoljain
On 8/31/20 2:13 PM, Jiri Olsa wrote: > On Thu, Aug 27, 2020 at 06:39:54PM +0530, Kajol Jain wrote: >> This patch removes jevents.h file and add its data inside >> jevents.c as this file is only included there. >> >> Signed-off-by: Kajol Jain >> --- >> tools/perf/pmu-events/jevents.c | 9

Re: [PATCH v6 1/5] perf/jevents: Remove jevents.h file

2020-08-31 Thread kajoljain
On 8/31/20 2:31 PM, John Garry wrote: > On 31/08/2020 09:43, Jiri Olsa wrote: >> On Thu, Aug 27, 2020 at 06:39:54PM +0530, Kajol Jain wrote: >>> This patch removes jevents.h file and add its data inside >>> jevents.c as this file is only included there. >>> >>> Signed-off-by: Kajol Jain >>>

Re: [PATCH v6 2/5] perf/jevents: Add new structure to pass json fields.

2020-09-01 Thread kajoljain
On 8/31/20 2:13 PM, Jiri Olsa wrote: > On Thu, Aug 27, 2020 at 06:39:55PM +0530, Kajol Jain wrote: > > SNIP > >> -if (!*field)\ >> +#define TRY_FIXUP_FIELD(field) do { if (es->field && !je->field) {\ >> +je->field = strdup(es->field);

Re: [PATCH v6 3/5] perf jevents: Add support for parsing perchip/percore events

2020-09-01 Thread kajoljain
On 8/31/20 2:14 PM, Jiri Olsa wrote: > On Thu, Aug 27, 2020 at 06:39:56PM +0530, Kajol Jain wrote: >> Initially, every time we want to add new terms like chip, core thread etc, >> we need to create corrsponding fields in pmu_events and event struct. >> This patch adds an enum called

Re: [PATCH v2 1/2] perf jevents: Tidy error handling

2020-10-23 Thread kajoljain
On 10/22/20 4:32 PM, John Garry wrote: > There is much duplication in the error handling for directory transvering > for prcessing JSONs. > > Factor out the common code to tidy a bit. > Patch looks good to me. Reviewed-By: Kajol Jain Thanks, Kajol Jain > Signed-off-by: John Garry > --- >

Re: [PATCH v2 2/2] perf jevents: Add test for arch std events

2020-10-23 Thread kajoljain
On 10/22/20 4:32 PM, John Garry wrote: > Recently there was an undetected breakage for std arch event support. > > Add support in "PMU events" testcase to detect such breakages. > > For this, the "test" arch needs has support added to process std arch > events. And a test event is added for

Re: [PATCH] perf test: Omit test 68 for s390.

2020-11-19 Thread kajoljain
On 11/4/20 1:59 PM, Thomas Richter wrote: > Commit ed21d6d7c48e6e ("perf tests: Add test for PE binary format support") > adds a WINDOWS EXE file named tests/pe-file.exe, which is > examined by the test case 'PE file support'. > > This test reads the buildid from the file tests/pe-file.exe, >

Re: [PATCH RFC v5 01/13] perf jevents: Add support for an extra directory level

2020-11-13 Thread kajoljain
On 11/6/20 6:05 PM, John Garry wrote: > Currently only upto a level 2 directory is supported, in form > vendor/platform. Hi John, Just want to check in case of sub directories, Will it be good add on/feasible to be able to include events of particular sub-directory for a platform?

Re: [PATCH 1/2] perf jevents: Tidy error handling

2020-10-21 Thread kajoljain
On 10/20/20 2:05 PM, John Garry wrote: > On 20/10/2020 09:14, kajoljain wrote: >> >> >> On 10/20/20 11:13 AM, Namhyung Kim wrote: >>> Hello, >>> >>> On Tue, Oct 20, 2020 at 12:42 AM John Garry wrote: >>>> >>>>

Re: [PATCH RFC v5 01/13] perf jevents: Add support for an extra directory level

2020-11-17 Thread kajoljain
On 11/13/20 2:54 PM, John Garry wrote: > On 13/11/2020 08:48, kajoljain wrote: >> >> On 11/6/20 6:05 PM, John Garry wrote: >>> Currently only upto a level 2 directory is supported, in form >>> vendor/platform. >> Hi John, >> Just want to check i

Re: [PATCH RFC v5 00/13] perf pmu-events: Support event aliasing for system PMUs

2020-11-28 Thread kajoljain
On 11/6/20 6:05 PM, John Garry wrote: > Currently event aliasing and metrics for only CPU and uncore PMUs is > supported. In fact, only uncore PMUs aliasing is supported for when the > uncore PMUs are fixed for a CPU, which may not always be the case for > certain architectures. > > This

Re: [PATCH v7 2/5] perf/jevents: Add new structure to pass json fields.

2020-09-04 Thread kajoljain
On 9/2/20 10:35 PM, John Garry wrote: > On 02/09/2020 17:04, Kajol Jain wrote: >> This patch adds new structure called 'json_event' inside jevents.h >> file to improve the callback prototype inside jevent files. >> Initially, whenever user want to add new field, they need to update >> in all

Re: [PATCH v7 2/5] perf/jevents: Add new structure to pass json fields.

2020-09-04 Thread kajoljain
On 9/3/20 8:24 PM, Namhyung Kim wrote: > Hello, > > On Thu, Sep 3, 2020 at 1:05 AM Kajol Jain wrote: >> >> This patch adds new structure called 'json_event' inside jevents.h > > jevents.c ? Hi Namhyung, Right, I will update it. Thanks, Kajol Jain > > Thanks > Namhyung > >> file to

Re: [PATCH] perf/core: Fix hung issue on perf stat command during cpu hotplug

2020-09-02 Thread kajoljain
On 9/2/20 8:35 PM, Arnaldo Carvalho de Melo wrote: > Em Thu, Aug 27, 2020 at 12:17:32PM +0530, Kajol Jain escreveu: >> Commit 2ed6edd33a21 ("perf: Add cond_resched() to task_function_call()") >> added assignment of ret value as -EAGAIN in case function >> call to 'smp_call_function_single'

Re: [PATCH v5 1/3] perf jevents: Add support for parsing perchip/percore events

2020-08-18 Thread kajoljain
On 8/16/20 10:05 PM, Andi Kleen wrote: >> @@ -321,7 +331,7 @@ static void print_events_table_prefix(FILE *fp, const >> char *tblname) >> static int print_events_table_entry(void *data, char *name, char *event, >> char *desc, char *long_desc, >>

Re: [PATCH v8 3/5] perf jevents: Add support for parsing perchip/percore events

2020-09-07 Thread kajoljain
On 9/6/20 6:25 PM, Jiri Olsa wrote: > On Sun, Sep 06, 2020 at 04:50:02PM +0530, Kajol Jain wrote: > > SNIP > >> typedef int (*func)(void *data, struct json_event *je); >> >> int eprintf(int level, int var, const char *fmt, ...) >> @@ -355,6 +368,8 @@ static int

Re: [perf metricgroup] fcc9c5243c: perf-sanity-tests.Parse_and_process_metrics.fail

2020-11-03 Thread kajoljain
On 11/3/20 10:24 PM, John Garry wrote: > On 03/11/2020 16:05, Ian Rogers wrote: >> On Tue, Nov 3, 2020 at 6:43 AM John Garry  wrote: >>> On 20/10/2020 17:53, Ian Rogers wrote: >> Thanks for taking a look John. If you want help you can send the >> output of "perf test 67 -vvv" to me. It

Re: [PATCH] memstick: mspro_block: remove unneeded semicolon

2020-11-01 Thread kajoljain
On 10/31/20 7:18 PM, t...@redhat.com wrote: > From: Tom Rix > > A semicolon is not needed after a switch statement. Hi Tom, I was checking this patch. Not sure if it will come under as fix patch. Since this is not fixing any logical issue do we still need to add fix tag? Thanks, Kajol

Re: [PATCH] memstick: mspro_block: remove unneeded semicolon

2020-11-02 Thread kajoljain
On 11/2/20 7:12 PM, Tom Rix wrote: > > On 11/1/20 10:51 PM, kajoljain wrote: >> >> On 10/31/20 7:18 PM, t...@redhat.com wrote: >>> From: Tom Rix >>> >>> A semicolon is not needed after a switch statement. >> Hi Tom, >>I was checkin

Re: [PATCH v4 01/12] perf expr: unlimited escaped characters in a symbol

2020-05-04 Thread kajoljain
On 5/1/20 11:03 PM, Ian Rogers wrote: > Current expression allows 2 escaped '-,=' characters. However, some > metrics require more, for example Haswell DRAM_BW_Use. > > Fixes: 26226a97724d (perf expr: Move expr lexer to flex) > Signed-off-by: Ian Rogers > --- > tools/perf/util/expr.l | 2 +-

Re: [PATCH v4 06/12] perf expr: parse numbers as doubles

2020-05-04 Thread kajoljain
On 5/1/20 11:03 PM, Ian Rogers wrote: > This is expected in expr.y and metrics use floating point values such as > x86 broadwell IFetch_Line_Utilization. > > Fixes: 26226a97724d (perf expr: Move expr lexer to flex) > Signed-off-by: Ian Rogers > --- > tools/perf/util/expr.l | 14

Re: [PATCHv2 0/3] perf tools: Add support for user defined metric

2020-04-30 Thread kajoljain
On 4/21/20 11:43 PM, Jiri Olsa wrote: > hi, > Joe asked for possibility to add user defined metrics. Given that > we already have metrics support, I added --metrics-file option that > allows to specify custom metrics. > > $ cat metrics > # IPC > mine1 = instructions / cycles; > /*

Re: [PATCHv3 00/19] perf metric: Add support to reuse metric

2020-07-26 Thread kajoljain
On 7/25/20 5:21 PM, Jiri Olsa wrote: > On Fri, Jul 24, 2020 at 11:22:28AM +0530, kajoljain wrote: > > SNIP > >> >> Hi Jiri, >>The change looks good to me. I tried with adding this patch on top of >> your perf/metric branch. It did resolve the iss

Re: [PATCH 03/19] perf metric: Change expr__get_id to return struct expr_id_data

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Changing expr__get_id to use and return struct expr_id_data > pointer as value for the ID. This way we can access data other > than value for given ID in following changes. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa > --- Reviewed-By : Kajol

Re: [PATCH 04/19] perf metric: Add expr__del_id function

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding expr__del_id function to remove ID from hashmap. > It will save us few lines in following changes. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa Reviewed-By : Kajol Jain Thanks, Kajol Jain > --- > tools/perf/util/expr.c | 21

Re: [PATCH 02/19] perf metric: Add expr__add_id function

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding expr__add_id function to data for ID > with zero value, which is used when scanning > the expression for IDs. > Reviewed-By : Kajol Jain Thanks, Kajol Jain > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa > --- > tools/perf/util/expr.c | 31

Re: [PATCH 05/19] perf metric: Add macros for iterating map events

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding following macros to iterate events and metric: > map_for_each_event(__pe, __idx, __map) > - iterates over all pmu_events_map events > map_for_each_metric(__pe, __idx, __map, __metric) > - iterates over all metrics that match __metric

Re: [PATCH 08/19] perf metric: Collect referenced metrics in struct metric_ref_node

2020-07-26 Thread kajoljain
On 7/20/20 3:48 AM, Ian Rogers wrote: > On Sun, Jul 19, 2020 at 11:13 AM Jiri Olsa wrote: >> >> Collecting referenced metrics in struct metric_ref_node object, >> so we can process them later on. >> >> The change will parse nested metric names out of expression and >> 'resolve' them. >> >> All

Re: [PATCH 06/19] perf metric: Add add_metric function

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Decouple metric adding logging into add_metric function, > so it can be used from other places in following changes. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa > --- Reviewed-By : Kajol Jain Thanks, Kajol Jain >

Re: [PATCH 09/19] perf metric: Collect referenced metrics in struct metric_expr

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Add referenced metrics into struct metric_expr object, > so they are accessible when computing the metric. > > Storing just name and expression itself, so the metric > can be resolved and computed. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa

Re: [PATCH 13/19] perf metric: Add cache_miss_cycles to metric parse test

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding test that compute metric with other metrics in it. > > cache_miss_cycles = metric:dcache_miss_cpi + metric:icache_miss_cycles > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa Reviewed-By : Kajol Jain Thanks, Kajol Jain > --- >

Re: [PATCH 14/19] perf metric: Add DCache_L2 to metric parse test

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding test that compute DCache_L2 metrics with other related metrics in it. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa Reviewed-By : Kajol Jain Thanks, Kajol Jain > --- > tools/perf/tests/parse-metric.c | 71

Re: [PATCH 10/19] perf metric: Add referenced metrics to hash data

2020-07-26 Thread kajoljain
On 7/20/20 4:02 AM, Ian Rogers wrote: > On Sun, Jul 19, 2020 at 11:14 AM Jiri Olsa wrote: >> >> Adding referenced metrics to the parsing context so they >> can be resolved during the metric processing. >> >> Adding expr__add_ref function to store referenced metrics >> into parse context. >> >>

Re: [PATCH 07/19] perf metric: Rename __metricgroup__add_metric to __add_metric

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Renaming __metricgroup__add_metric to __add_metric > to fit in the current function names. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa Reviewed-By : Kajol Jain Thanks, Kajol Jain > --- > tools/perf/util/metricgroup.c | 17 ++--- >

Re: [PATCH 12/19] perf metric: Add events for the current list

2020-07-26 Thread kajoljain
On 7/20/20 4:04 AM, Ian Rogers wrote: > On Sun, Jul 19, 2020 at 11:14 AM Jiri Olsa wrote: >> >> There's no need to iterate the whole list of groups, >> when adding new events. The currently created groups >> are the ones we want to add. >> >> Signed-off-by: Jiri Olsa > > Acked-by: Ian Rogers

Re: [PATCH 11/19] perf metric: Compute referenced metrics

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Adding computation (expr__parse call) of referenced metric at > the point when it needs to be resolved during the parent metric > computation. > > Once the inner metric is computed, the result is stored and > used if there's another usage of that metric.

Re: [PATCH 17/19] perf metric: Add metric group test

2020-07-26 Thread kajoljain
On 7/20/20 4:11 AM, Ian Rogers wrote: > On Sun, Jul 19, 2020 at 11:14 AM Jiri Olsa wrote: >> >> Adding test for metric group plus compute_metric_group >> function to get metrics values within the group. >> >> Signed-off-by: Jiri Olsa > > Acked-by: Ian Rogers Reviewed-By : Kajol Jain

Re: [PATCH 15/19] perf metric: Add recursion check when processing nested metrics

2020-07-26 Thread kajoljain
On 7/20/20 4:10 AM, Ian Rogers wrote: > On Sun, Jul 19, 2020 at 11:14 AM Jiri Olsa wrote: >> >> Keeping the stack of nested metrics via 'struct expr_id' objects >> and checking if we are in recursion via already processed metric. >> >> The stack is implemented as static array within the struct

Re: [PATCH 19/19] perf metric: Rename group_list to metric_list

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Following the previous change that rename egroup > to metric, there's no reason to call the list > 'group_list' anymore, renaming it to metric_list. > > Signed-off-by: Jiri Olsa Reviewed-By : Kajol Jain Thanks, Kajol Jain > --- >

Re: [PATCH 18/19] perf metric: Rename struct egroup to metric

2020-07-26 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > Renaming struct egroup to metric, because it seems > to make more sense. Plus renaming all the variables > that hold egroup to appropriate names. > > Acked-by: Ian Rogers > Signed-off-by: Jiri Olsa > --- Reviewed-By : Kajol Jain Thanks, Kajol Jain >

Re: [PATCH v4 0/5] powerpc/perf: Add json file support for hv_24x7 core level events

2020-07-26 Thread kajoljain
On 7/21/20 1:01 AM, Arnaldo Carvalho de Melo wrote: > Em Mon, Jul 20, 2020 at 09:21:33PM +0200, Jiri Olsa escreveu: >> On Mon, Jul 20, 2020 at 12:31:22PM +0530, Kajol Jain wrote: >>> Patchset enhance current runtime parameter support. It introduces new >>> fields like "PerChip" and "PerCore"

Re: [PATCH 16/19] perf metric: Make compute_single function more precise

2020-07-28 Thread kajoljain
On 7/28/20 10:56 PM, Ian Rogers wrote: > On Tue, Jul 28, 2020 at 5:36 AM Arnaldo Carvalho de Melo > wrote: >> >> Em Sun, Jul 19, 2020 at 08:13:17PM +0200, Jiri Olsa escreveu: >>> So far compute_single function relies on the fact, that >>> there's only single metric defined within evlist in all

Re: [PATCHv3 00/19] perf metric: Add support to reuse metric

2020-07-20 Thread kajoljain
On 7/19/20 11:43 PM, Jiri Olsa wrote: > hi, > this patchset is adding the support to reused metric in > another metric. > > For example, to define IPC by using CPI with change like: > > { > "BriefDescription": "Instructions Per Cycle (per Logical Processor)", > -

Re: [PATCHv3 00/19] perf metric: Add support to reuse metric

2020-07-20 Thread kajoljain
On 7/20/20 12:52 PM, Jiri Olsa wrote: > On Mon, Jul 20, 2020 at 12:14:00PM +0530, kajoljain wrote: >> >> >> On 7/19/20 11:43 PM, Jiri Olsa wrote: >>> hi, >>> this patchset is adding the support to reused metric in >>> another metric. >>>

Re: [PATCHv3 00/19] perf metric: Add support to reuse metric

2020-07-20 Thread kajoljain
On 7/20/20 1:49 PM, Jiri Olsa wrote: > On Mon, Jul 20, 2020 at 01:39:24PM +0530, kajoljain wrote: > > SNIP > >> This is with your perf/metric branch: >> command# ./perf stat -M PowerBUS_Frequency -C 0 -I 1000 >> assertion failed at util/metricgroup.c:709 >>

Re: [PATCHv3 00/19] perf metric: Add support to reuse metric

2020-07-23 Thread kajoljain
On 7/21/20 12:46 AM, Jiri Olsa wrote: > On Mon, Jul 20, 2020 at 02:32:40PM +0530, kajoljain wrote: >> >> >> On 7/20/20 1:49 PM, Jiri Olsa wrote: >>> On Mon, Jul 20, 2020 at 01:39:24PM +0530, kajoljain wrote: >>> >>> SNIP >>> >>>

Re: [PATCH v3 0/5] powerpc/perf: Add json file support for hv_24x7 core level events

2020-07-17 Thread kajoljain
On 7/16/20 8:52 PM, Arnaldo Carvalho de Melo wrote: > Em Thu, Jul 16, 2020 at 03:12:11PM +0530, Kajol Jain escreveu: >> Patchset enhance current runtime parameter support. It introduces new >> fields like "PerChip" and "PerCore" similar to the field "PerPkg" which is >> used to specify perpkg

Re: [PATCH v7 5/5] powerpc/hv-24x7: Update post_mobility_fixup() to handle migration

2020-05-05 Thread kajoljain
On 4/29/20 5:07 PM, Michael Ellerman wrote: > Kajol Jain writes: >> Function 'read_sys_info_pseries()' is added to get system parameter >> values like number of sockets and chips per socket. >> and it gets these details via rtas_call with token >> "PROCESSOR_MODULE_INFO". >> >> Incase lpar

Re: [PATCH v5 0/5] perf stat: Support overall statistics for interval mode

2020-05-14 Thread kajoljain
On 5/14/20 11:06 AM, Jin Yao wrote: > Currently perf-stat supports to print counts at regular interval (-I), > but it's not very easy for user to get the overall statistics. > > With this patchset, it supports to report the summary at the end of > interval output. > > For example, > >

Re: [PATCH v7 2/5] powerpc/hv-24x7: Add rtas call in hv-24x7 driver to get processor details

2020-05-06 Thread kajoljain
On 4/29/20 5:01 PM, Michael Ellerman wrote: > Hi Kajol, > > Some comments inline ... > > Kajol Jain writes: >> For hv_24x7 socket/chip level events, specific chip-id to which >> the data requested should be added as part of pmu events. >> But number of chips/socket in the system details are

Re: [PATCH 1/2] perf: Fix POWER9 metric 'lsu_other_stall_cpi'

2020-05-08 Thread kajoljain
On 5/7/20 9:58 PM, Paul A. Clarke wrote: > From: "Paul A. Clarke" > > The metric definition is too long for the current value of EXPR_MAX_OTHER. > Increase the value EXPR_MAX_OTHER sufficiently to allow > 'lsu_other_stall_cpi' to build properly. > > Before: > -- > $ perf list | grep

Re: [PATCH 1/2] perf: Fix POWER9 metric 'lsu_other_stall_cpi'

2020-05-08 Thread kajoljain
On 5/8/20 12:01 PM, kajoljain wrote: > > > On 5/7/20 9:58 PM, Paul A. Clarke wrote: >> From: "Paul A. Clarke" >> >> The metric definition is too long for the current value of EXPR_MAX_OTHER. >> Increase the value EXPR_MAX_OTHER sufficiently to allow

Re: [PATCH 2/2] perf: Add missing metrics to POWER9 'cpi_breakdown'

2020-05-08 Thread kajoljain
On 5/7/20 9:58 PM, Paul A. Clarke wrote: > From: "Paul A. Clarke" > > Add the following metrics to the POWER9 'cpi_breakdown' metricgroup: > - ict_noslot_br_mpred_cpi > - ict_noslot_br_mpred_icmiss_cpi > - ict_noslot_cyc_other_cpi > - ict_noslot_disp_held_cpi > -

Re: [RFC 1/3] perf jevents: Add support for parsing perchip/percore events

2020-07-03 Thread kajoljain
On 6/25/20 7:38 PM, Ian Rogers wrote: > On Thu, Jun 25, 2020 at 4:47 AM Kajol Jain wrote: >> >> Set up the "PerChip" field so that perf knows they are >> per chip events. >> >> Set up the "PerCore" field so that perf knows they are >> per core events and add these fields to pmu_event

Re: [RFC v2 1/5] perf/pmu-events/jevents: Add enum to store aggregation like PerPkg

2020-07-14 Thread kajoljain
On 7/13/20 12:25 AM, Jiri Olsa wrote: > On Tue, Jul 07, 2020 at 05:53:10PM +0530, Kajol Jain wrote: > > SNIP > >> } >> >> diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c >> index 93fe72a9dc0b..3cafbb320d68 100644 >> --- a/tools/perf/util/pmu.c >> +++

Re: [RFC v2 3/5] perf jevents: Add support for parsing perchip/percore events

2020-07-14 Thread kajoljain
On 7/13/20 12:25 AM, Jiri Olsa wrote: > On Tue, Jul 07, 2020 at 05:53:12PM +0530, Kajol Jain wrote: >> Added the "PerChip" field in enum so that perf knows they are >> per chip events. >> >> Added the "PerCore" field in enum so that perf knows they are >> per core events and add these fields

Re: [RFC 1/3] perf jevents: Add support for parsing perchip/percore events

2020-07-07 Thread kajoljain
On 7/6/20 6:27 PM, Jiri Olsa wrote: > On Fri, Jul 03, 2020 at 11:50:28AM +0530, kajoljain wrote: > > SNIP > >> ] >> diff --git a/tools/perf/pmu-events/jevents.c >> b/tools/perf/pmu-events/jevents.c >> index fa86c5f997cc..dd2b14cc147c 100644 >> ---

Re: [PATCH v2 0/7] Share events between metrics

2020-05-22 Thread kajoljain
On 5/20/20 11:50 PM, Ian Rogers wrote: > Metric groups contain metrics. Metrics create groups of events to > ideally be scheduled together. Often metrics refer to the same events, > for example, a cache hit and cache miss rate. Using separate event > groups means these metrics are multiplexed

Re: [PATCH 1/2] perf jevents: Tidy error handling

2020-10-20 Thread kajoljain
On 10/20/20 11:13 AM, Namhyung Kim wrote: > Hello, > > On Tue, Oct 20, 2020 at 12:42 AM John Garry wrote: >> >> There is much duplication in the error handling for directory traversing >> for processing JSONs. >> >> Factor out the common code to tidy a bit. >> >> Signed-off-by: John Garry >>

Re: [perf metricgroup] fcc9c5243c: perf-sanity-tests.Parse_and_process_metrics.fail

2020-10-20 Thread kajoljain
On 10/19/20 9:50 PM, Ian Rogers wrote: > On Mon, Oct 19, 2020 at 2:51 AM John Garry wrote: >> >> On 19/10/2020 00:30, Ian Rogers wrote: >>> On Sun, Oct 18, 2020 at 1:51 AM kernel test robot >>> wrote: Greeting, FYI, we noticed the following commit (built with gcc-9):

Re: [PATCH v2 0/6] perf arm64 metricgroup support

2021-03-30 Thread kajoljain
On 3/30/21 2:37 AM, Paul A. Clarke wrote: > On Fri, Mar 26, 2021 at 10:57:40AM +, John Garry wrote: >> On 25/03/2021 20:39, Paul A. Clarke wrote: >>> On Thu, Mar 25, 2021 at 06:33:12PM +0800, John Garry wrote: Metric reuse support is added for pmu-events parse metric testcase.

Re: [PATCH v2 0/6] perf arm64 metricgroup support

2021-04-07 Thread kajoljain
On 3/25/21 4:03 PM, John Garry wrote: > This series contains support to get basic metricgroups working for > arm64 CPUs. > > Initial support is added for HiSilicon hip08 platform. > > Some sample usage on Huawei D06 board: > > $ ./perf list metric > > List of pre-defined events (to be

Re: [PATCH v2 1/6] perf metricgroup: Make find_metric() public with name change

2021-04-06 Thread kajoljain
On 4/6/21 3:24 PM, John Garry wrote: > On 02/04/2021 00:16, Ian Rogers wrote: >> On Thu, Mar 25, 2021 at 3:38 AM John Garry wrote: >>> >>> Function find_metric() is required for the metric processing in the >>> pmu-events testcase, so make it public. Also change the name to include >>>

Re: [PATCH] perf tools: Remove redundant code

2021-03-11 Thread kajoljain
On 3/10/21 8:48 AM, Jiapeng Chong wrote: > Fix the following coccicheck warnings: > > ./tools/perf/util/evlist.c:1315:5-8: Unneeded variable: "err". Return "- > ENOMEM" on line 1340. > > Reported-by: Abaci Robot > Signed-off-by: Jiapeng Chong > --- > tools/perf/util/evlist.c | 3 +-- > 1

Re: [PATCH] perf stat: improve readability of shadow stats

2021-03-02 Thread kajoljain
On 3/1/21 10:54 PM, Changbin Du wrote: > This does follow two changes: > 1) Select appropriate unit between K/M/G. > 2) Use 'cpu-sec' instead of 'sec' to state this is not the wall-time. > > $ sudo ./perf stat -a -- sleep 1 > > Before: Unit 'M' is selected even the number is very small. >

Re: [PATCH] [perf] powerpc: Remove unsupported metrics

2021-02-25 Thread kajoljain
On 2/24/21 11:44 PM, Paul A. Clarke wrote: > Several metrics are defined based on unsupported / non-existent > events, and silently discarded. Remove them for good code hygiene > and to avoid confusion. > Hi Paul, Thanks for the patch. Changes looks good to me. Reviewed-by: Kajol Jain

Re: [PATCH v3 1/2] powerpc/perf: Use PVR rather than oprofile field to determine CPU version

2021-03-03 Thread kajoljain
On 3/1/21 5:39 PM, Christophe Leroy wrote: > From: Rashmica Gupta > > Currently the perf CPU backend drivers detect what CPU they're on using > cur_cpu_spec->oprofile_cpu_type. > > Although that works, it's a bit crufty to be using oprofile related fields, > especially seeing as oprofile is

Re: [PATCH -next] powerpc/perf/hv-24x7: Make some symbols static

2021-04-12 Thread kajoljain
On 4/9/21 2:31 PM, Bixuan Cui wrote: > The sparse tool complains as follows: > > arch/powerpc/perf/hv-24x7.c:229:1: warning: > symbol '__pcpu_scope_hv_24x7_txn_flags' was not declared. Should it be > static? > arch/powerpc/perf/hv-24x7.c:230:1: warning: > symbol

Re: [PATCH -next] powerpc/perf: Make symbol 'isa207_pmu_format_attr' static

2021-04-12 Thread kajoljain
On 4/9/21 2:31 PM, Bixuan Cui wrote: > The sparse tool complains as follows: > > arch/powerpc/perf/isa207-common.c:24:18: warning: > symbol 'isa207_pmu_format_attr' was not declared. Should it be static? > > This symbol is not used outside of isa207-common.c, so this > commit marks it

Re: [PATCH] perf vendor events: Initial json/events list for power10 platform

2021-04-19 Thread kajoljain
On 4/19/21 2:38 AM, Paul A. Clarke wrote: > On Sat, Apr 17, 2021 at 02:48:50PM +0530, Kajol Jain wrote: >> Patch adds initial json/events for POWER10. > > I was able to apply, build, and run perf with these changes, > and every new event at least ran successfully with > `perf stat`. > >

Re: [PATCH] perf machine: Use true and false for bool variable

2021-02-18 Thread kajoljain
On 2/18/21 2:54 PM, Jiapeng Chong wrote: > Fix the following coccicheck warnings: > > ./tools/perf/util/machine.c:2000:9-10: WARNING: return of 0/1 in > function 'symbol__match_regex' with return type bool. > > Reported-by: Abaci Robot > Signed-off-by: Jiapeng Chong > --- >

Re: [RESEND PATCH v4 2/4] drivers/nvdimm: Add perf interface to expose nvdimm performance stats

2021-09-04 Thread kajoljain
On 9/3/21 8:49 PM, kernel test robot wrote: > Hi Kajol, > > Thank you for the patch! Perhaps something to improve: > > [auto build test WARNING on linux-nvdimm/libnvdimm-for-next] > [also build test WARNING on powerpc/next linus/master v5.14 next-20210903] > [If your patch is applied to the

Re: [RFC PATCH] drivers/nvdimm: nvdimm_pmu_free_hotplug_memory() can be static

2021-09-04 Thread kajoljain
On 9/3/21 8:49 PM, kernel test robot wrote: > drivers/nvdimm/nd_perf.c:159:6: warning: symbol > 'nvdimm_pmu_free_hotplug_memory' was not declared. Should it be static? > > Reported-by: kernel test robot > Signed-off-by: kernel test robot > --- > nd_perf.c |2 +- > 1 file changed, 1

Re: [RESEND PATCH v4 4/4] powerpc/papr_scm: Document papr_scm sysfs event format entries

2021-09-09 Thread kajoljain
On 9/8/21 6:33 AM, Dan Williams wrote: > On Thu, Sep 2, 2021 at 10:11 PM Kajol Jain wrote: >> >> Details is added for the event, cpumask and format attributes >> in the ABI documentation. >> >> Acked-by: Peter Zijlstra (Intel) >> Reviewed-by: Madhavan Srinivasan >> Tested-by: Nageswara R

Re: [RESEND PATCH v4 1/4] drivers/nvdimm: Add nvdimm pmu structure

2021-09-09 Thread kajoljain
On 9/8/21 3:29 AM, Dan Williams wrote: > Hi Kajol, > > Apologies for the delay in responding to this series, some comments below: Hi Dan, No issues, thanks for reviewing the patches. > > On Thu, Sep 2, 2021 at 10:10 PM Kajol Jain wrote: >> >> A structure is added, called nvdimm_pmu,

Re: [PATCH v5 0/4] Add perf interface to expose nvdimm

2021-10-13 Thread kajoljain
Hi Dan, Any comments on this patch-set? Thanks, Kajol Jain On 9/28/21 6:11 PM, Kajol Jain wrote: > Patchset adds performance stats reporting support for nvdimm. > Added interface includes support for pmu register/unregister > functions. A structure is added called nvdimm_pmu to be used for >

Re: [RESEND PATCH v5 0/4] Add perf interface to expose nvdimm

2021-11-16 Thread kajoljain
On 11/16/21 8:29 PM, LEROY Christophe wrote: > Hi > > Le 16/11/2021 à 05:49, Kajol Jain a écrit : >> Patchset adds performance stats reporting support for nvdimm. >> Added interface includes support for pmu register/unregister >> functions. A structure is added called nvdimm_pmu to be used for

Re: [PATCH v7 0/4] Add perf interface to expose nvdimm

2022-03-07 Thread kajoljain
Hi Dan, Can you take this patch-set if it looks fine to you. Thanks, Kajol Jain On 2/25/22 20:00, Kajol Jain wrote: > Patchset adds performance stats reporting support for nvdimm. > Added interface includes support for pmu register/unregister > functions. A structure is added called

Re: [PATCH v6 0/4] Add perf interface to expose nvdimm

2022-02-25 Thread kajoljain
On 2/25/22 13:17, Aneesh Kumar K V wrote: > On Fri, 2022-02-25 at 12:08 +0530, kajoljain wrote: >> >> >> On 2/25/22 11:25, Nageswara Sastry wrote: >>> >>> >>> On 17/02/22 10:03 pm, Kajol Jain wrote: >>>> > >>&g

Re: [PATCH v6 0/4] Add perf interface to expose nvdimm

2022-02-24 Thread kajoljain
On 2/25/22 11:25, Nageswara Sastry wrote: > > > On 17/02/22 10:03 pm, Kajol Jain wrote: >> Patchset adds performance stats reporting support for nvdimm. >> Added interface includes support for pmu register/unregister >> functions. A structure is added called nvdimm_pmu to be used for >>

Re: [PATCH v6 0/4] Add perf interface to expose nvdimm

2022-02-25 Thread kajoljain
On 2/25/22 16:41, Nageswara Sastry wrote: > > > On 25/02/22 12:08 pm, kajoljain wrote: >> >> >> On 2/25/22 11:25, Nageswara Sastry wrote: >>> >>> >>> On 17/02/22 10:03 pm, Kajol Jain wrote: >>>> Patchset adds performance

Re: [PATCH 1/2] drivers/nvdimm: Fix build failure when CONFIG_PERF_EVENTS is not set

2022-03-23 Thread kajoljain
On 3/22/22 07:40, Dan Williams wrote: > On Fri, Mar 18, 2022 at 4:42 AM Kajol Jain wrote: >> >> The following build failure occures when CONFIG_PERF_EVENTS is not set >> as generic pmu functions are not visible in that scenario. >> >> |-- s390-randconfig-r044-20220313 >> | |--

Re: [PATCH 2/2] powerpc/papr_scm: Fix build failure when CONFIG_PERF_EVENTS is not set

2022-03-23 Thread kajoljain
On 3/23/22 21:02, Dan Williams wrote: > On Wed, Mar 23, 2022 at 3:05 AM Michael Ellerman wrote: >> >> Dan Williams writes: >>> On Tue, Mar 22, 2022 at 7:30 AM kajoljain wrote: >>>> On 3/22/22 03:09, Dan Williams wrote: >>>>>

Re: [PATCH 2/2] powerpc/papr_scm: Fix build failure when CONFIG_PERF_EVENTS is not set

2022-03-22 Thread kajoljain
On 3/22/22 03:09, Dan Williams wrote: > On Fri, Mar 18, 2022 at 4:42 AM Kajol Jain wrote: >> >> The following build failure occures when CONFIG_PERF_EVENTS is not set >> as generic pmu functions are not visible in that scenario. >> >> arch/powerpc/platforms/pseries/papr_scm.c:372:35: error:

Re: [PATCH 2/2] powerpc/papr_scm: Fix build failure when CONFIG_PERF_EVENTS is not set

2022-03-22 Thread kajoljain
On 3/22/22 07:15, Dan Williams wrote: > On Mon, Mar 21, 2022 at 2:39 PM Dan Williams wrote: >> >> On Fri, Mar 18, 2022 at 4:42 AM Kajol Jain wrote: >>> >>> The following build failure occures when CONFIG_PERF_EVENTS is not set >>> as generic pmu functions are not visible in that scenario. >>>

  1   2   >