Re: [PATCH] [X86]: Fix zen6 AVX512BMM cpuid check.
"H.J. Lu" <[email protected]>
| Newsgroups | gmane.comp.gcc.patches |
|---|---|
| Message-ID | <CAMe9rOpgFf1WL3nCt_tTrF2XjQ5o5g7DeDuD3UD6wnOiZq-RKA@mail.gmail.com> |
On Fri, Aug 21, 2026 at 2:34 AM Dipesh Sharma <[email protected]> wrote: > > Hi, > > This patch fixes the AVX512BMM cpuid check for zen6. The AVX512BMM is > present in the extended features instead of the standard leaf. Where is AVX512BMM spec? It should also be supported by glibc. > bootstraped and regtested on x86_64-linux-gnu. Ok for trunk ? > > gcc/ChangeLog: > > * common/config/i386/cpuinfo.h (get_available_features): Detect AVXBMM from extended features instead of standard leaf. > --- > gcc/common/config/i386/cpuinfo.h | 12 ++---------- > 1 file changed, 2 insertions(+), 10 deletions(-) > > diff --git a/gcc/common/config/i386/cpuinfo.h b/gcc/common/config/i386/cpuinfo.h > index fef8f90f94c..153ab194864 100644 > --- a/gcc/common/config/i386/cpuinfo.h > +++ b/gcc/common/config/i386/cpuinfo.h > @@ -1110,16 +1110,6 @@ get_available_features (struct __processor_model *cpu_model, > } > } > > - /* Get Advanced Features at level 0x21 (eax = 0x21). */ > - if (max_cpuid_level >= 0x21) > - { > - __cpuid (0x21, eax, ebx, ecx, edx); > - if (eax & bit_AVX512BMM) > - { > - set_feature (FEATURE_AVX512BMM); > - } > - } > - > /* Get Advanced Features at level 0x24 (eax = 0x24, ecx = 0). */ > if (avx10_set && max_cpuid_level >= 0x24) > { > @@ -1205,6 +1195,8 @@ get_available_features (struct __processor_model *cpu_model, > { > set_feature (FEATURE_PREFETCHI); > } > + if (eax & bit_AVX512BMM) > + set_feature (FEATURE_AVX512BMM); > } > > #undef set_feature > -- > 2.34.1 > -- H.J.