On Fri, Oct 10, 2025 at 5:54 AM Jinchao Wang <[email protected]> wrote: > Addressing the PMU assumption that all counters are available would > resolve the issue. If perf managed reserved or pinned counters > internally, other users would not need to be aware of that detail. > > Alternatively, perf could provide an interface to query whether a > counter is pinned. Having the NMI watchdog supply that information > creates coupling between otherwise independent subsystems.
There are lots of ways to redesign the perf event subsystem, counters, etc. These things are being pushed upon. In general the API is trying to hide details like the scheduling counters. I'm in a loop, but the change here is bad because: 1) the use of nmi_watchdog in this way is misleading (outside of the perf tool) because of the name; 2) it is bad because it is altering the way a kernel API has worked for close to 10 years meaning old code doesn't work as intended; 3) it incurs extra overhead in tools. Thanks, Ian
