Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-23 Thread Liu Hao
在 5/23/21 11:16 PM, Jacek Caban 写道: The whole thing is really a hack, but I don't see a better solution, so it looks fine to me. I am not sure whether people expect the Microsoft `__cpuid` or the GCC one. Perhaps we can have this commit in master for some time and see how it goes. -- B

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-23 Thread Jacek Caban
On 20/05/2021 17:46, Liu Hao wrote: 在 2021-05-20 22:40, Jacek Caban 写道: We could #undef __cpuid just after including cpuid.h. Updated patch is attached. The whole thing is really a hack, but I don't see a better solution, so it looks fine to me. Thanks, Jacek __

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-23 Thread Liu Hao
在 2021-05-20 23:46, Liu Hao 写道: 在 2021-05-20 22:40, Jacek Caban 写道: We could #undef __cpuid just after including cpuid.h. Updated patch is attached. ping? -- Best regards, Liu Hao OpenPGP_signature Description: OpenPGP digital signature ___

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Liu Hao
在 2021-05-20 22:40, Jacek Caban 写道: We could #undef __cpuid just after including cpuid.h. Updated patch is attached. -- Best regards, Liu Hao From fb076cef964bfeb65c345535cceadadaff3e3ceb Mon Sep 17 00:00:00 2001 From: Liu Hao Date: Tue, 11 May 2021 00:39:58 +0800 Subject: [PATCH] includ

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Jacek Caban
On 5/20/21 4:37 PM, Liu Hao wrote: 在 2021-05-20 22:29, Jacek Caban 写道: On 5/20/21 4:21 PM, Liu Hao wrote: +#if (!defined(__GNUC__) || __GNUC__ < 11)   __MACHINEI(void __cpuid(int a[4],int b)) +#endif __cpuid is a macro in both older GCCs and clang, so it will probably not work there. It'

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Liu Hao
在 2021-05-20 22:29, Jacek Caban 写道: On 5/20/21 4:21 PM, Liu Hao wrote: +#if (!defined(__GNUC__) || __GNUC__ < 11)   __MACHINEI(void __cpuid(int a[4],int b)) +#endif __cpuid is a macro in both older GCCs and clang, so it will probably not work there. It's also present in intrin-impl.h.

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Jacek Caban
On 5/20/21 4:21 PM, Liu Hao wrote: +#if (!defined(__GNUC__) || __GNUC__ < 11) __MACHINEI(void __cpuid(int a[4],int b)) +#endif __cpuid is a macro in both older GCCs and clang, so it will probably not work there. It's also present in intrin-impl.h. Jacek

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Liu Hao
在 2021-05-20 21:58, Jacek Caban 写道: As far as I can see, cpuid.h is not included by any other header shipped with GCC. It means that with your changes, users will would need to start including it themselves in addition to intrin.h. For similar cases with other *intrin.h headers provided by G

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Jacek Caban
Hi Liu, On 5/10/21 6:45 PM, Liu Hao wrote: Subject: [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11 GCC 11 has this as a static inline function without any indicative macros. Reference:https://github.com/gcc-mirror/gcc/blob/23855a176609fe8dda6abaf2b21846b4517966eb/gcc/config/i

Re: [Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-20 Thread Liu Hao
ping. -- Best regards, Liu Hao OpenPGP_signature Description: OpenPGP digital signature ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

[Mingw-w64-public] [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11

2021-05-10 Thread Liu Hao
-- Best regards, Liu Hao From f8ee13e246884c5ddb732097310efbe67f642d91 Mon Sep 17 00:00:00 2001 From: Liu Hao Date: Tue, 11 May 2021 00:39:58 +0800 Subject: [PATCH] include/intrin-impl: Don't define `__cpuidex` for GCC 11 GCC 11 has this as a static inline function without any indicative macros