| 27 | int fd_msr; |
| 28 | |
| 29 | uint32_t cpuid(uint32_t eax) |
| 30 | { |
| 31 | uint32_t ret; |
| 32 | |
| 33 | #if defined(__PIC__) || defined(__DARWIN__) && !defined(__LP64__) |
| 34 | asm volatile ( |
| 35 | "push " BREG "\n\t" |
| 36 | "cpuid\n\t" |
| 37 | "pop " BREG "\n\t" |
| 38 | : "=a" (ret) : "a" (eax) : "%ecx", "%edx" |
| 39 | ); |
| 40 | #else |
| 41 | asm ("cpuid" : "=a" (ret) : "a" (eax) : "%ebx", "%ecx", "%edx"); |
| 42 | #endif |
| 43 | |
| 44 | return ret; |
| 45 | } |
| 46 | |
| 47 | static inline cpuid_result_t cpuid_ext(uint32_t eax, unsigned int ecx) |
| 48 | { |
no outgoing calls
no test coverage detected