From: Øyvind Kolås Date: Mon, 17 Jan 2022 18:07:07 +0000 (+0100) Subject: babl: set ecx to 0 in cpuid X-Git-Tag: archive/raspbian/1%0.1.106-3+rpi1^2~15^2~4^2~67 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=362f6e73cacb5ebdc34243e6719548c8fba8bef3;p=babl.git babl: set ecx to 0 in cpuid This is neccesary to be able to detect AVX2 reliably. --- diff --git a/babl/babl-cpuaccel.c b/babl/babl-cpuaccel.c index ef26fa5..6c1f1cc 100644 --- a/babl/babl-cpuaccel.c +++ b/babl/babl-cpuaccel.c @@ -136,7 +136,7 @@ enum "=S" (ebx), \ "=c" (ecx), \ "=d" (edx) \ - : "0" (op)) + : "0" (op), "2" (0)) #else #define cpuid(op,eax,ebx,ecx,edx) \ __asm__ ("xor %%ecx, %%ecx\n\t" \ @@ -145,7 +145,7 @@ enum "=b" (ebx), \ "=c" (ecx), \ "=d" (edx) \ - : "0" (op)) + : "0" (op), "2" (0)) #endif