[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 05/14 RESEND] xenpm: Change get-cpufreq-para output for internal


  • To: Jason Andryuk <jandryuk@xxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Fri, 5 May 2023 09:04:21 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=3O0K/iRk1u8q9x+Hqf1l/IJHKu+M7pGBN80sM11F79g=; b=fLiwg3zesP3iNtNzzmWw2c8ufNNlwrtT2NJbRPbLwBoYKWewL/UWA5gyAG3xctVG4gQI6xRnb1JUspIfg8XGkXSeIK4FTeQQiENbL7QPAlfvBkI+AdO+YHrbQQ1EEgtzhQZG9Nt3ZXhlV3/+fLJftfvcB+OvJmgD+laU4283VvBnSWVQxBdnmrXEgEqMgM+C6iCGNCuaMelg4tJ3n3iexZ6SfzAqD6Q9WlsaZYmuSCtVE5DhE9yA0COCfcoKz+ysSCPW0I1uhp1My3KWTk6lwltRk7zs0MUY0l1URLDsdZim8Ia/D3cGcZHFv4PomfFsJyq/LqLX/ubneLSTJSGjhQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QmTA99hTVrFpkt8kVePZKrhUs/VB+A+dj/1GH7NkQX31EWjsRvkh6V9gAr/XA/rYZczsBGGfxQsqTPtaEOKXbhXcDbjqO9KInUcIyXgK3E+sb01nA+7t+zxPuI/Hb80/y9eNFwZ4tReFsOjU3pZC/842dUwpE+PtXXQq0xcOReApcaSUvbmS+f2Vo5rcjDCKHa6xwR0f8rbUWLDodgh/O4HfCFEqydbvFAFbgskTm9ECMpLUyMWh+9ww+fGBtRKUBeMQvZzKiAMOnYsMCdYSZhauQtaZrs14mwJnbZt84uuBsso+z/DMJpihiSOT5bwVuNm4VpGh5bcTuXnPIvOSuA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: Wei Liu <wl@xxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Fri, 05 May 2023 07:05:05 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 04.05.2023 19:00, Jason Andryuk wrote:
> On Thu, May 4, 2023 at 10:35 AM Jan Beulich <jbeulich@xxxxxxxx> wrote:
>>
>> On 01.05.2023 21:30, Jason Andryuk wrote:
>>> When using HWP, some of the returned data is not applicable.  In that
>>> case, we should just omit it to avoid confusing the user.  So switch to
>>> printing the base and turbo frequencies since those are relevant to HWP.
>>> Similarly, stop printing the CPU frequencies since those do not apply.
>>
>> It vaguely feels like I have asked this before: Can you point me at a
>> place in the SDM where it is said that CPUID 0x16's "Maximum Frequency"
>> is the turbo frequency? Without such a reference I feel a little uneasy
>> with ...
> 
> I don't have a reference, but I found it empirically to match the
> "turbo" frequency.
> 
> For an Intel® Core™ i7-10810U,
> https://ark.intel.com/content/www/us/en/ark/products/201888/intel-core-i710810u-processor-12m-cache-up-to-4-90-ghz.html
> 
> Max Turbo Frequency 4.90 GHz
> 
> # xenpm get-cpufreq-para
> cpu id               : 0
> affected_cpus        : 0
> cpuinfo frequency    : base [1600000] turbo [4900000]
> 
> Turbo has to be enabled to reach (close to) that frequency.
> 
> From my cover letter:
> This is for a 10th gen 6-core 1600 MHz base 4900 MHZ max cpu.  In the
> default balance mode, Turbo Boost doesn't exceed 4GHz.  Tweaking the
> energy_perf preference with `xenpm set-cpufreq-hwp balance ene:64`,
> I've seen the CPU hit 4.7GHz before throttling down and bouncing around
> between 4.3 and 4.5 GHz.  Curiously the other cores read ~4GHz when
> turbo boost takes affect.  This was done after pinning all dom0 cores,
> and using taskset to pin to vCPU/pCPU 11 and running a bash tightloop.

Right, but what matters for the longer term future is what gets committed
(and the cover letter won't be). IOW ...

>>> @@ -720,10 +721,15 @@ static void print_cpufreq_para(int cpuid, struct 
>>> xc_get_cpufreq_para *p_cpufreq)
>>>          printf(" %d", p_cpufreq->affected_cpus[i]);
>>>      printf("\n");
>>>
>>> -    printf("cpuinfo frequency    : max [%u] min [%u] cur [%u]\n",
>>> -           p_cpufreq->cpuinfo_max_freq,
>>> -           p_cpufreq->cpuinfo_min_freq,
>>> -           p_cpufreq->cpuinfo_cur_freq);
>>> +    if ( internal )
>>> +        printf("cpuinfo frequency    : base [%u] turbo [%u]\n",
>>> +               p_cpufreq->cpuinfo_min_freq,
>>> +               p_cpufreq->cpuinfo_max_freq);
>>
>> ... calling it "turbo" (and not "max") here.
> 
> I'm fine with "max".  I think I went with turbo since it's a value you
> cannot sustain but can only hit in short bursts.

... I don't mind you sticking to "turbo" as long as the description makes
clear why that was chosen despite the SDM not naming it this way.

Jan



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.