src/cpuinfo/SDL_cpuinfo.c
changeset 9300 0293f45e4814
parent 9278 8900afb78a19
child 9619 b94b6d0bff0f
     1.1 --- a/src/cpuinfo/SDL_cpuinfo.c	Fri Dec 26 22:30:19 2014 -0500
     1.2 +++ b/src/cpuinfo/SDL_cpuinfo.c	Fri Dec 26 23:16:54 2014 -0500
     1.3 @@ -458,10 +458,11 @@
     1.4  
     1.5      if (!SDL_CPUType[0]) {
     1.6          int i = 0;
     1.7 -        int a, b, c, d;
     1.8  
     1.9          if (CPU_haveCPUID()) {
    1.10 +            int a, b, c, d;
    1.11              cpuid(0x00000000, a, b, c, d);
    1.12 +            (void) a;
    1.13              SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
    1.14              SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
    1.15              SDL_CPUType[i++] = (char)(b & 0xff); b >>= 8;
    1.16 @@ -563,15 +564,12 @@
    1.17  SDL_GetCPUCacheLineSize(void)
    1.18  {
    1.19      const char *cpuType = SDL_GetCPUType();
    1.20 -
    1.21 +    int a, b, c, d;
    1.22 +    (void) a; (void) b; (void) c; (void) d;
    1.23      if (SDL_strcmp(cpuType, "GenuineIntel") == 0) {
    1.24 -        int a, b, c, d;
    1.25 -
    1.26          cpuid(0x00000001, a, b, c, d);
    1.27          return (((b >> 8) & 0xff) * 8);
    1.28      } else if (SDL_strcmp(cpuType, "AuthenticAMD") == 0) {
    1.29 -        int a, b, c, d;
    1.30 -
    1.31          cpuid(0x80000005, a, b, c, d);
    1.32          return (c & 0xff);
    1.33      } else {