Re: [PATCH v7 1/5] perf metric: Restructure struct expr_parse_ctx.

2021-01-15 Thread Jiri Olsa
On Tue, Jan 12, 2021 at 03:04:30PM -0800, Ian Rogers wrote: SNIP > diff --git a/tools/perf/tests/pmu-events.c b/tools/perf/tests/pmu-events.c > index 0ca6a5a53523..cf5afd126934 100644 > --- a/tools/perf/tests/pmu-events.c > +++ b/tools/perf/tests/pmu-events.c > @@ -478,9 +478,14 @@ static int tes

[PATCH v7 1/5] perf metric: Restructure struct expr_parse_ctx.

2021-01-12 Thread Ian Rogers
A later change to parsing the ids out (in expr__find_other) will potentially drop hashmaps and so it is more convenient to move expr_parse_ctx to have a hashmap pointer rather than a struct value. As this pointer must be freed, rather than just going out of scope, add expr__ctx_new and expr__ctx_fr