[PATCH 11/11] powerpc64le: Add glibc-hwcaps support

Adhemerval Zanella adhemerval.zanella@linaro.org
Fri Dec 4 12:35:43 GMT 2020



On 04/12/2020 05:56, Florian Weimer wrote:
> * Tulio Magno Quites Machado Filho via Libc-alpha:
> 
>> Carlos Seo via Libc-alpha <libc-alpha@sourceware.org> writes:
>>
>>> 'darn' requires firmware support, so that's why it has a hwcap2 bit
>>> separate from ISA 3.0 (see commit a4700a26 in the kernel tree). Although I
>>> personally have not seen any firmware that disables that on POWER9, it is
>>> safer to assume that ISA 3.0 does not imply that 'darn' is available.
>>
>> I think we have 2 different questions to be answered here:
>>
>> 1. Is it safe to use darn on a processor compatible with the POWER ISA 3.0b?
>>
>> 2. Should glibc-hwcaps test for PPC_FEATURE2_DARN when loading POWER9-specific
>>    libraries?
>>
>> I agree with Carlos regarding question #1: it's unsafe to use darn without
>> testing for PPC_FEATURE2_DARN.
>>
>> Regarding question #2, I see darn much like HTM even if darn doesn't have its
>> own -m parameter.  What I mean is: I don't think the entire power9 directory
>> should be disabled if a kernel (or firmware) decides to disable
>> PPC_FEATURE2_DARN.
>>
>> With that said, I don't have a strong opinion on question #2.
>>
>> By the way, I have the same opinion for scv: it's unsafe to use it without
>> testing for PPC_FEATURE2_SCV and I think glibc-hwcaps should not require it.
> 
> Okay, then the posted patch is okay as is?  May I consider it reviewed?

LGTM as is, I think we can add PPC_FEATURE2_DARN as an extra hwcap folder
is required.


More information about the Libc-alpha mailing list