From: "Liang, Kan" <kan.liang@linux.intel.com>
To: Ian Rogers <irogers@google.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>,
Jesper Juhl <jesperjuhl76@gmail.com>, Sam James <sam@gentoo.org>,
Namhyung Kim <namhyung@kernel.org>,
linux-kernel@vger.kernel.org, Kan Liang <kan.liang@intel.com>
Subject: Re: [PATCH v1] tools lib api cpu: Remove unused file
Date: Tue, 7 Jan 2025 14:12:00 -0500 [thread overview]
Message-ID: <691c84d7-3b3b-4896-a607-09ba7a2263d7@linux.intel.com> (raw)
In-Reply-To: <CAP-5=fWbs74a2ta_fxJdXhfzf9rQa4Uv0LNjOZqp1-=izkBFMg@mail.gmail.com>
On 2025-01-07 11:01 a.m., Ian Rogers wrote:
> On Tue, Jan 7, 2025 at 6:22 AM Liang, Kan <kan.liang@linux.intel.com> wrote:
>>
>> On 2025-01-06 5:32 p.m., Ian Rogers wrote:
>>> On Thu, Dec 19, 2024 at 12:54 PM Ian Rogers <irogers@google.com> wrote:
>>>>
>>>> No use in tools could be found, remove to simplify the code base.
>>>>
>>
>> This was to support the patch which generate per-sample
>> freq/CPU%/CORE_BUSY%.
>> https://lore.kernel.org/lkml/1442413316-33518-1-git-send-email-kan.liang@intel.com/
>>
>> However, the patch set was not merged. I don't remember the exact reason.
>>
>> It looks like there is no one interested in it. There should be no
>> reason to keep it.
>>
>> Acked-by: Kan Liang <kan.liang@linux.intel.com>
>
> Thanks Kan! That series looks nice. There is an overlap with computing
> frequencies and metrics like cpu_operating_frequency:
> https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git/tree/tools/perf/pmu-events/arch/x86/sapphirerapids/spr-metrics.json?h=perf-tools-next#n45
>
> I wonder two things:
> 1) perhaps we can add the --perf-freq flag but make the implementation
> use metrics rather than hard coded events. Outside of perf stat the
> json metrics aren't really plumbed up, so this would be a bunch of
> work.
At that time, the metrics was not well supported. Everything is
hardcoded. Yes, now, we should utilize the json metrics for it.
> 2) the metrics compute the TSC frequency from cpuid, and fall back to
> /proc/cpuinfo:
> https://git.kernel.org/pub/scm/linux/kernel/git/perf/perf-tools-next.git/tree/tools/perf/arch/x86/util/tsc.c?h=perf-tools-next
> Perhaps there should be another fallback to
> /sys/devices/system/cpu/cpu%d/cpufreq/cpuinfo_max_freq, as in this
> series.
As my understanding, the TSC frequency should be a non-turbo frequency.
The cpuinfo_max_freq should be a turbo frequency. It may not be used as
a fallback.
Thanks,
Kan
>
> Thanks,
> Ian
prev parent reply other threads:[~2025-01-07 19:12 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-19 20:54 Ian Rogers
2025-01-06 22:32 ` Ian Rogers
2025-01-07 14:22 ` Liang, Kan
2025-01-07 16:01 ` Ian Rogers
2025-01-07 19:12 ` Liang, Kan [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=691c84d7-3b3b-4896-a607-09ba7a2263d7@linux.intel.com \
--to=kan.liang@linux.intel.com \
--cc=acme@redhat.com \
--cc=irogers@google.com \
--cc=jesperjuhl76@gmail.com \
--cc=kan.liang@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=namhyung@kernel.org \
--cc=sam@gentoo.org \
/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®