Re: [PATCH v2 2/2] perf: script: add new output field 'dsoff' to print dso offset

From: Changbin Du
Date: Mon Apr 10 2023 - 02:35:06 EST


On Fri, Apr 07, 2023 at 02:24:48PM -0700, Namhyung Kim wrote:
> Hello Changbin,
>
> On Thu, Apr 6, 2023 at 10:53 PM Changbin Du <changbin.du@xxxxxxxxxx> wrote:
[snip]
> > @@ -574,6 +576,9 @@ static void set_print_ip_opts(struct perf_event_attr *attr)
> > if (PRINT_FIELD(DSO))
> > output[type].print_ip_opts |= EVSEL__PRINT_DSO;
> >
> > + if (PRINT_FIELD(DSOFF))
> > + output[type].print_ip_opts |= EVSEL__PRINT_DSOFF;
>
> What if the user gives 'dsoff' without 'dso'. Better to set the
> EVSEL__PRINT_DSO as well?
>
It will be dropped currently. I will make 'dsoff' implicitly add 'dso' field
later.

> Thanks,
> Namhyung
>


--
Cheers,
Changbin Du