This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Check GLIBC_IFUNC to enable/disable ifunc features


On Thu, Jun 30, 2016 at 5:51 AM, Siddhesh Poyarekar
<siddhesh@sourceware.org> wrote:
> On Thu, Jun 30, 2016 at 05:01:28AM -0700, H.J. Lu wrote:
>> My scheme is
>>
>> do
>> {
>>   if (*env == GLIBC_IFUNC=.*)
>>    {
>>       process
>>       break
>>    }
>>   env++
>> }
>>
>> We only need to check GLIBC_IFUNC only if it hasn't been found.  With
>> GLIBC_IFUNC_X86_XXX, we have to do
>>
>> do
>>   {
>>      if (*env == GLIBC_IFUNC_X86_*)
>>        process
>>      env++
>>   }
>>
>> We need to check GLIBC_IFUNC_X86 in each iteration.
>
> OK, then how about GLIBC_IFUNC_X86=avx,sse2,sse3..., i.e. a
> comma-separated value for the GLIBC_IFUNC_<ARCH> environment variable.

comma-separator is fine.  But we need to both turn it on and off.
Also do we need _X86? GLIBC_IFUNC is processor specific.  Why
pollute environment with

GLIBC_IFUNC_ARM
GLIBC_IFUNC_X86
...

-- 
H.J.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]