Changeset 398 for trunk


Ignore:
Timestamp:
May 10, 2010, 2:17:07 PM (9 years ago)
Author:
lindanl
Message:

fixed errors for x86_CPU_detect.h on Linux

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/x86_CPU_detect.h

    r397 r398  
    8080static inline int check_CPUid1_feature(CPUid_reg reg, int CPUid_bit) {
    8181  int CPUinfo[4];
    82   if __get_cpuid(1, &CPUinfo[reg_eax], &CPUinfo[reg_ebx], &CPUinfo[reg_ecx], &CPUinfo[reg_edx]) {
    83     return CPUInfo[reg] & CPUid_bit;
     82  if (__get_cpuid(1, (unsigned int*)&CPUinfo[reg_eax], (unsigned int*)&CPUinfo[reg_ebx], (unsigned int*)&CPUinfo[reg_ecx], (unsigned int*)&CPUinfo[reg_edx]))
     83    return CPUinfo[reg] & CPUid_bit;
    8484  else return 0;
    8585}
Note: See TracChangeset for help on using the changeset viewer.