[PATCH, i386]: Introduce cpuid.h and use it everywhere.
Joseph S. Myers
joseph@codesourcery.com
Wed Sep 5 10:54:00 GMT 2007
On Wed, 5 Sep 2007, Uros Bizjak wrote:
+static inline unsigned int
Use __inline to support use of the header in C90 mode.
+__get_cpuid_max (unsigned int ext, unsigned int *sig)
+{
+ unsigned int eax, ebx, ecx, edx;
Use __ext, __sig, __eax, __ebx, __ecx, __edx so as not to interfere with
the user's namespace for macros.
+static inline int
+__get_cpuid (unsigned int level,
+ unsigned int *eax, unsigned int *ebx,
+ unsigned int *ecx, unsigned int *edx)
+{
+ unsigned int ext = level & 0x80000000;
Likewise.
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Gcc-patches
mailing list