Re: [PATCH v2] perf/core: Optimize event reschedule for a PMU

From: Peter Zijlstra
Date: Mon Aug 05 2024 - 05:16:08 EST


On Sun, Aug 04, 2024 at 11:39:18PM -0700, Namhyung Kim wrote:
> On Sat, Aug 3, 2024 at 10:08 AM Namhyung Kim <namhyung@xxxxxxxxxx> wrote:
> >
> > On Sat, Aug 3, 2024 at 3:32 AM Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:
> > >
> > > On Fri, Aug 02, 2024 at 09:11:23PM +0200, Peter Zijlstra wrote:
> > >
> > > > But I'll have to continue staring at this later.
> > >
> > > OK, I have the below, which boots and seems able to do:
> > >
> > > perf stat -ae power/energy-pkg/ -- sleep 1
> > >
> > > and
> > >
> > > perf top
> > >
> > > also still works, so it must be perfect, right, right?
> >
> > I really hope so. :) I'll test it over the weekend.
>
> I found a failing test about the context time - it complained about
> difference in enabled vs running time of a software event.

Yeah, it's that ctx_scheD_out(EVENT_TIME) thing, that's really needed.

I'll make those changes go away when I split it all up.