Work around perf NMI-induced hangs
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest4 patches 2 repliesIn review
- v11 patch 0 repliesSuperseded
Changes from v1 from the cover letter
* keep a running average instead of taking a single value for determining NMI lengths.
* Fixed some of the math converting from ns to/from percentages (it was backwards)
* Included nmi length tracepoint at end of series
Patches in v3 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | perf/x86: only print PMU state when also WARN()'ingarch/ | +6 | 0 replies | |
| 2/4 | x86: warn when NMI handlers take large amounts of timearch/ | +27 | 2 replies | |
| 3/4 | perf: drop sample rate when sampling is too slowDocumentation/ arch/ include/ +2 more | +131 | 0 replies | |
| 4/4 | x86: nmi length tracepointsDocumentation/ arch/ include/ | +87 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.
Cover letter [v3][PATCH 0/4] Work around perf NMI-induced hangs
Changes from v2:
2/4:
* Only warn on the longest NMIs. Don't print when over a threshhold.
* Output in ms as opposed to ns
4/4:
* Add some Documentation/ for the tracepoint
* keep tracepoint delta in a s64 instead of an int, and vall it 'delta_ns' instead of 'len'
Changes from v1:
* keep a running average instead of taking a single value for determining NMI lengths.
* Fixed some of the math converting from ns to/from percentages (it was backwards)
* Included nmi length tracepoint at end of series
--
If root or an unprivileged user runs 'perf top', my system hangs. If I'm lucky, I get a warning out to dmesg, along these lines:
hrtimer: interrupt took 13915457 ns cpu: 132
or a hard-lockup message on occasion.
The proxmiate cause of this is that perf_event_nmi_handler() has been observed to take tens of ms on occasion. That needs to get fixed, and I'm working on tracking the root cause down.
But, These patches make the situation better: perf can no longer simply wedge the box, and we have a safe, controlled exit path when things go wrong.