[PATCH v10 0/4] Support SMT control on arm64

Yicong Yang yangyicong at huawei.com
Fri Dec 27 18:16:47 AEDT 2024


On 2024/12/26 20:28, Shrikanth Hegde wrote:
> 
> 
> On 12/26/24 17:20, Yicong Yang wrote:
>> On 2024/12/26 17:23, Shrikanth Hegde wrote:
>>>
>>>
>>> On 12/20/24 13:23, Yicong Yang wrote:
>>>> From: Yicong Yang <yangyicong at hisilicon.com>
>>>>
>>>> The core CPU control framework supports runtime SMT control which
>>>> is not yet supported on arm64. Besides the general vulnerabilities
>>>> concerns we want this runtime control on our arm64 server for:
>>>>
>>>> - better single CPU performance in some cases
>>>> - saving overall power consumption
>>>>
>>>
>>> EAS is disabled when SMT is present.
>>> I am curious to know how power saving happens here.
>>
>> EAS shouldn't work on non-asymmetic systems, so it's not the case here.
> 
> Ok. so this is a symmetric system then?

yes, symmetric.

> 
>> System wide power consumption comes down from the CPU offlining here.
>>
> 
> Ok. So SMT is enabled by default and then at runtime disable it to save power by off-lining the sibling threads?
> 

yes.

> 
> Note: When enabling SMT, current behavior differs when a core is fully offline on different archs. You may want to see which is behavior you need in that case. i.e either online or skip.
> 
> PowerPC change where we are skipping a fully offline core.
> https://lore.kernel.org/all/20240731030126.956210-1-nysal@linux.ibm.com/
> 

Thanks for the information! Currently it's implemented as online and no special need for skip. We may need further
support if skip is required in the future, currently for GENERIC_ARCH_TOPOLOGY an offline CPU's thread sibling
only contains itself so there's no information for checking whether the whole core is offline or not.

Thanks.

>> Thanks.
>>
>>>
>>>> This patchset implements it in the following aspects:
>>>>
>>>> - Provides a default topology_is_primary_thread()
>>>> - support retrieve SMT thread number on OF based system
>>>> - support retrieve SMT thread number on ACPI based system
>>>> - select HOTPLUG_SMT for arm64
>>>>
>>>> Tests has been done on our ACPI based arm64 server and on ACPI/OF\
>>>> based QEMU VMs.
>>>>
>>> .
> 
> .


More information about the Linuxppc-dev mailing list