util/u_cpu_detect: Drop unused has_tsc
authorJordan Justen <jordan.l.justen@intel.com>
Sun, 9 Apr 2023 19:25:14 +0000 (12:25 -0700)
committerMarge Bot <emma+marge@anholt.net>
Wed, 6 Sep 2023 01:39:53 +0000 (01:39 +0000)
This will allow us to add has_clflushopt without spilling into an new
unsigned.

Suggested-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22379>

src/util/u_cpu_detect.c
src/util/u_cpu_detect.h

index ee38d3f..395c93b 100644 (file)
@@ -853,7 +853,6 @@ _util_cpu_detect_once(void)
          }
 
          /* general feature flags */
-         util_cpu_caps.has_tsc    = (regs2[3] >>  4) & 1; /* 0x0000010 */
          util_cpu_caps.has_mmx    = (regs2[3] >> 23) & 1; /* 0x0800000 */
          util_cpu_caps.has_sse    = (regs2[3] >> 25) & 1; /* 0x2000000 */
          util_cpu_caps.has_sse2   = (regs2[3] >> 26) & 1; /* 0x4000000 */
@@ -958,7 +957,6 @@ _util_cpu_detect_once(void)
       printf("util_cpu_caps.x86_cpu_type = %u\n", util_cpu_caps.x86_cpu_type);
       printf("util_cpu_caps.cacheline = %u\n", util_cpu_caps.cacheline);
 
-      printf("util_cpu_caps.has_tsc = %u\n", util_cpu_caps.has_tsc);
       printf("util_cpu_caps.has_mmx = %u\n", util_cpu_caps.has_mmx);
       printf("util_cpu_caps.has_mmx2 = %u\n", util_cpu_caps.has_mmx2);
       printf("util_cpu_caps.has_sse = %u\n", util_cpu_caps.has_sse);
index f9db16f..86ce912 100644 (file)
@@ -88,7 +88,6 @@ struct util_cpu_caps_t {
    unsigned cacheline;
 
    unsigned has_intel:1;
-   unsigned has_tsc:1;
    unsigned has_mmx:1;
    unsigned has_mmx2:1;
    unsigned has_sse:1;
@@ -121,6 +120,8 @@ struct util_cpu_caps_t {
    unsigned has_avx512vl:1;
    unsigned has_avx512vbmi:1;
 
+   unsigned unused:1;
+
    unsigned num_L3_caches;
    unsigned num_cpu_mask_bits;
    unsigned max_vector_bits;