[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [PATCH v4 14/15] tools/xenpm: remove px_cap dependency check for average frequency
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: "Penny, Zheng" <penny.zheng@xxxxxxx>
- Date: Fri, 9 May 2025 09:42:03 +0000
- Accept-language: en-US
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fYSwX0z5vHJ7EBrQ+cgJhSYFa1CQdP9Dpe5U7d9W0EM=; b=FVfJOpd7WknYeoqUP9M3+UXosCTUQlj+L0Dz7bm8ywdqVsaBKpsLMqykpBRKQsfpRBYDqRBHpxoILuGJsLHHiG1kl+lpTEGBricdeuAhTfLr1yo7BP+6Hyl5TjcwPKzKt6AZpB0P6YM+umRqkIO6VxdjXYM00rALzQ8N4Nio6RztdLShhXXai0nHVC7g/d3EczupYhe7Vo5K3grk6Q3DwZquOJj5q+T4cv3ko0s0YgZrWX/B+iyEw9sRrC2/+PMTTjFdXlIory5HWaUAQGfFX4zFG9HP2WGyo4bWlmpckkfsERUsozTFzAp/0S68UO2bKCy8giki3Hu30cf07yBOgQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=t5vL3n2upgPyXr1n6t7U2hGKnSglVzW8MyPtmzApCZS76F6dpFNx144NySG34T17C2s3U6B8IHjj+PY8D5N4T3xfMPSieZ8nYxPwFYJ9GG4RhiZX/fmedj/PIR+yBkQQ7xOTDFrbyIJ4sB1ejsVpd+XYTD7Hw+bFHFhaQvbZ3r/KeJv1L2d37eozWmCf9ikSxZ07zR1XaRAb6MeK2CFEZC26hMMHZUJPPtzlpz4+cwPr/rbEdnGnq4zc1Tlk3QQ8MUvrWneW2qO8SERSmkAH2AnCOCFUgEQJhJczzhoyOzu3jdVH/geqBX/mLUppKBHKmb529h1JAFw85PJhYNnwDA==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com;
- Cc: "Huang, Ray" <Ray.Huang@xxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Fri, 09 May 2025 09:42:14 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Msip_labels: MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_ActionId=3c63a98c-63b4-450e-a222-8b4287b10989;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_ContentBits=0;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_Enabled=true;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_Method=Privileged;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_Name=Open Source;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_SetDate=2025-05-09T09:41:56Z;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d;MSIP_Label_f265efc6-e181-49d6-80f4-fae95cf838a0_Tag=10, 0, 1, 1;
- Thread-index: AQHbrRCwc1yeGpZzL0W02M9xuQGFIrO8Yf+AgA3L4uA=
- Thread-topic: [PATCH v4 14/15] tools/xenpm: remove px_cap dependency check for average frequency
[Public]
Hi,
> -----Original Message-----
> From: Jan Beulich <jbeulich@xxxxxxxx>
> Sent: Wednesday, April 30, 2025 10:42 PM
> To: Penny, Zheng <penny.zheng@xxxxxxx>
> Cc: Huang, Ray <Ray.Huang@xxxxxxx>; Anthony PERARD
> <anthony.perard@xxxxxxxxxx>; xen-devel@xxxxxxxxxxxxxxxxxxxx
> Subject: Re: [PATCH v4 14/15] tools/xenpm: remove px_cap dependency check
> for average frequency
>
> On 14.04.2025 09:40, Penny Zheng wrote:
> > In `xenpm start` command, the monitor of average frequency shall not
> > depend on the existence of legacy P-states, so removing "px_cap"
> > dependancy check.
>
> Well, yes, I agree there. But can you explain to me what the file scope
> "avgfreq" is
> good for? Shouldn't we go farther and tidy things more thoroughly? Much like
> show_cpufreq_by_cpuid(), we could call
> get_avgfreq_by_cpuid() right before printing. (It escapes me altogether why
> start_gather_func() would pre-fill the array. Unlike cxstat_start[] and
> pxstat_start[]
> that's not incrementally or differentially used data.)
>
Right, I think avgfreq[] shall be just like cxstat_start[] and pxstat_start[],
getting pre-filled in
start_gather_func() too, maybe we don't need a avgfreq_start[] to actually
record the numbers.
What we achieve there is that in get_messured_perf(), we could let
per_cpu(usr_perf_pair, cpu)
save APERF/MPERF value at start_gather_func() point.
Then, later, in signal_int_handler(), running get_avgfreq_by_cpuid() again
could actually let get_messured_perf()
calculate APERF/MPERF incrementation happened between `xenpm start` duration.
Right now, we are
calculating incrementation between boot time, or last `xenpm start` command
till now
> Doing that would make yet more obvious that the px_cap part of the condition
> was
> bogus presumably from the very start. (I'm further inclined to say that this
> change
> should also have a Fixes: tag.)
>
> Jan
|