]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
Remove useless assignments
authorVladislav Shchapov <vladislav@shchapov.ru>
Sat, 18 Feb 2023 22:01:07 +0000 (03:01 +0500)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Mon, 6 Mar 2023 12:26:09 +0000 (13:26 +0100)
Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
arch/x86/x86_features.c

index 4ff7f63ee8fe99e19e5ac6a7f76550b6c5e9865f..f60ddbcf94ba6d8de102f4546c3115bf40475f73 100644 (file)
@@ -75,9 +75,6 @@ void Z_INTERNAL x86_check_features(struct x86_cpu_features *features) {
 
         features->has_os_save_ymm = ((xfeature & 0x06) == 0x06);
         features->has_os_save_zmm = ((xfeature & 0xe6) == 0xe6);
-    } else {
-        features->has_os_save_ymm = 0;
-        features->has_os_save_zmm = 0;
     }
 
     if (maxbasic >= 7) {
@@ -90,22 +87,12 @@ void Z_INTERNAL x86_check_features(struct x86_cpu_features *features) {
         // check AVX2 bit if the OS supports saving YMM registers
         if (features->has_os_save_ymm) {
             features->has_avx2 = ebx & 0x20;
-        } else {
-            features->has_avx2 = 0;
         }
 
         // check AVX512 bits if the OS supports saving ZMM registers
         if (features->has_os_save_zmm) {
             features->has_avx512 = ebx & 0x00010000;
             features->has_avx512vnni = ecx & 0x800;
-        } else {
-            features->has_avx512 = 0;
-            features->has_avx512vnni = 0;
         }
-    } else {
-        features->has_avx2 = 0;
-        features->has_avx512 = 0;
-        features->has_avx512vnni = 0;
-        features->has_vpclmulqdq = 0;
     }
 }