Jeroen van Rijn 9 月之前
父节点
当前提交
3bfe675a68
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/build_cpuid.cpp

+ 1 - 1
src/build_cpuid.cpp

@@ -28,7 +28,7 @@ gb_internal bool should_use_march_native() {
 		int cpu[4];
 		odin_cpuid(0x1, &cpu[0]); // Get feature information in ECX + EDX
 
-		bool have_popcnt = cpu[2] && (1 << 23); // bit 23 in ECX = popcnt
+		bool have_popcnt = cpu[2] & (1 << 23); // bit 23 in ECX = popcnt
 		return !have_popcnt;
 
 	#endif