src/cpuinfo/SDL_cpuinfo.c
changeset 13082 f77988be3607
parent 12794 a2dc7ba484fd
child 13151 568f67c04841
equal deleted inserted replaced
13081:53ae8dc25c6e 13082:f77988be3607
   600     int a, b, c, d;
   600     int a, b, c, d;
   601     (void) a; (void) b; (void) c; (void) d;
   601     (void) a; (void) b; (void) c; (void) d;
   602     if (SDL_strcmp(cpuType, "GenuineIntel") == 0) {
   602     if (SDL_strcmp(cpuType, "GenuineIntel") == 0) {
   603         cpuid(0x00000001, a, b, c, d);
   603         cpuid(0x00000001, a, b, c, d);
   604         return (((b >> 8) & 0xff) * 8);
   604         return (((b >> 8) & 0xff) * 8);
   605     } else if (SDL_strcmp(cpuType, "AuthenticAMD") == 0) {
   605     } else if (SDL_strcmp(cpuType, "AuthenticAMD") == 0 || SDL_strcmp(cpuType, "HygonGenuine") == 0) {
   606         cpuid(0x80000005, a, b, c, d);
   606         cpuid(0x80000005, a, b, c, d);
   607         return (c & 0xff);
   607         return (c & 0xff);
   608     } else {
   608     } else {
   609         /* Just make a guess here... */
   609         /* Just make a guess here... */
   610         return SDL_CACHELINE_SIZE;
   610         return SDL_CACHELINE_SIZE;