From: Jing Wu <realwujing@gmail.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Jing Wu <realwujing@gmail.com>, Thomas Gleixner <tglx@kernel.org>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
Dave Hansen <dave.hansen@linux.intel.com>,
x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
"Paul E. McKenney" <paulmck@kernel.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
linux-kernel@vger.kernel.org,
Qiliang Yuan <yuanql9@chinatelecom.cn>,
Jian Zhang <zhangj332@chinatelecom.cn>,
Frederic Weisbecker <fweisbec@gmail.com>
Subject: Re: [PATCH] x86/aperfmperf: Refresh stale sample via IPI for busy NOHZ_FULL CPUs
Date: Wed, 29 Jul 2026 21:04:44 +0800 [thread overview]
Message-ID: <20260729130445.2939054-1-realwujing@gmail.com> (raw)
In-Reply-To: <20260729123912.GZ751831@noisy.programming.kicks-ass.net>
On Wed, Jul 29, 2026 at 08:39:12PM +0800, Peter Zijlstra wrote:
> Oh, you care about the silly sysfs files? I though this was about the
> scheduler use of aperf/mperf ratio.
>
> Both are driven from the same source, but the scheduler use makes no
> sense when isolated/NOHZ_FULL. And I would argue that keeping the CPU
> isolated is more important than having the silly number 'accurate'.
Yes, sorry for the confusion - it's the sysfs files. To be concrete
about why: when someone is chasing a real incident (packet latency in
an OVS/DPDK PMD pipeline pinned to one of these cores, say), reading
scaling_cur_freq/cpuinfo is one of the first things they check. Seeing
the P-state floor while the core is genuinely at full turbo sends that
investigation down the wrong path and burns real engineering time.
-EOPNOTSUPP doesn't fix that particular problem: the operator still
gets nothing useful from the standard interface and has to fall back
to turbostat regardless, so the diagnostic workflow ends up no better
off than it is today.
Given that, I'd like to make the case for going back to something
closer to the original approach: it's a small, self-contained change,
and it reports the actual value instead of an estimate or nothing.
The concern was IPIs turning periodic if something scrapes this file
on a schedule - but for the isolated cores we run PMD workloads on,
nothing polls per-core scaling_cur_freq/cpuinfo on any kind of
schedule; it only gets read by a person during an investigation, which
is a rare, deliberate action, not unlike running turbostat by hand.
Would you reconsider on that basis, or is there a middle ground you'd
be open to?
prev parent reply other threads:[~2026-07-29 13:04 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-28 11:27 Jing Wu
2026-07-28 13:44 ` Peter Zijlstra
2026-07-28 14:42 ` Peter Zijlstra
2026-07-29 8:22 ` Jing Wu
2026-07-29 12:39 ` Peter Zijlstra
2026-07-29 13:04 ` Jing Wu [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260729130445.2939054-1-realwujing@gmail.com \
--to=realwujing@gmail.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=fweisbec@gmail.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=paulmck@kernel.org \
--cc=peterz@infradead.org \
--cc=rafael.j.wysocki@intel.com \
--cc=tglx@kernel.org \
--cc=x86@kernel.org \
--cc=yuanql9@chinatelecom.cn \
--cc=zhangj332@chinatelecom.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®