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] [x86_64] Detection of availability of AVX512F and AVX512DQ ISAs


On Wed, Apr 29, 2015 at 8:10 AM, Andrew Senkevich
<andrew.n.senkevich@gmail.com> wrote:
> Hi,
>
> this patch adds detection of availability of AVX512F and AVX512DQ ISAs.
>
> 2015-04-29  Andrew Senkevich  <andrew.senkevich@intel.com>
>
>         * sysdeps/x86_64/multiarch/init-arch.h (bit_AVX512F_Usable,
>         bit_AVX512DQ_Usable): New macro.
>         * sysdeps/x86_64/multiarch/init-arch.c (__init_cpu_features):
>         Check and set bit_AVX512F_Usable, bit_AVX512DQ_Usable.
>
> diff --git a/sysdeps/x86_64/multiarch/init-arch.c
> b/sysdeps/x86_64/multiarch/init-arch.c
> index 7dec218..6a81d48 100644
> --- a/sysdeps/x86_64/multiarch/init-arch.c
> +++ b/sysdeps/x86_64/multiarch/init-arch.c
> @@ -179,6 +179,19 @@ __init_cpu_features (void)
>           if (CPUID_AVX2)
>             __cpu_features.feature[index_AVX2_Usable]
>               |= bit_AVX2_Usable | bit_AVX_Fast_Unaligned_Load;
> +         /* Check if OPMASK state, upper 256-bit of ZMM0-ZMM15 and
> +            ZMM16-ZMM31 state are enabled.  */
> +         if ((xcrlow & 0xe0) == 0xe0 )

Please add/use bit_ZMM0_15_state and bit_ZMM16_31_state.
This file is used by both 32-bit and 64-bit. Does it work for both
32-bit and 64-bit?


-- 
H.J.


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