Re: [PATCH v2 0/4] perf: Fix perf_event_attr::exclusive rotation

From: Peter Zijlstra
Date: Mon Nov 02 2020 - 09:18:13 EST


On Sun, Nov 01, 2020 at 07:52:38PM -0800, Andi Kleen wrote:
> The main motivation is actually that the "multiple groups" algorithm
> in perf doesn't work all that great: it has quite a few cases where it
> starves groups or makes the wrong decisions. That is because it is very
> difficult (likely NP complete) problem and the kernel takes a lot
> of short cuts to avoid spending too much time on it.

The event scheduling should be starvation free, except in the presence
of pinned events.

If you can show starvation without pinned events, it's a bug.

It will also always do equal or better than exclusive mode wrt PMU
utilization. Again, if it doesn't it's a bug.

Please provide concrete examples for these two cases, or stop spreading
FUD like this.