sna: Add extra '()' around bitwise &/&& for CPU feature detection
By popular demand. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
1d6f4078c1
commit
e63390df52
|
|
@ -72,7 +72,7 @@ unsigned sna_cpu_detect(void)
|
|||
extra |= has_YMM;
|
||||
}
|
||||
|
||||
if (extra & has_YMM && ecx & bit_AVX)
|
||||
if ((extra & has_YMM) && (ecx & bit_AVX))
|
||||
features |= AVX;
|
||||
|
||||
if (edx & bit_MMX)
|
||||
|
|
@ -87,7 +87,7 @@ unsigned sna_cpu_detect(void)
|
|||
|
||||
if (max >= 7) {
|
||||
__cpuid_count(7, 0, eax, ebx, ecx, edx);
|
||||
if (extra & has_YMM && ebx & bit_AVX2)
|
||||
if ((extra & has_YMM) && (ebx & bit_AVX2))
|
||||
features |= AVX2;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue