You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-07-11 14:30:22 +02:00
x86 cpuid: set vendor union members separately
Solaris Studio (suncc) has difficulty with filling in members of a union. Instead, let's retrieve and store the cpuid() results separately. This is still a compiler bug, however this fix does not cause a regression on other platforms. Signed-off-by: Janne Grunau <janne-libav@jannau.net>
This commit is contained in:
committed by
Janne Grunau
parent
04a5eaa1a5
commit
be0675ce67
@ -74,7 +74,10 @@ int ff_get_cpu_flags_x86(void)
|
|||||||
return 0; /* CPUID not supported */
|
return 0; /* CPUID not supported */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
cpuid(0, max_std_level, vendor.i[0], vendor.i[2], vendor.i[1]);
|
cpuid(0, max_std_level, ebx, ecx, edx);
|
||||||
|
vendor.i[0] = ebx;
|
||||||
|
vendor.i[1] = edx;
|
||||||
|
vendor.i[2] = ecx;
|
||||||
|
|
||||||
if(max_std_level >= 1){
|
if(max_std_level >= 1){
|
||||||
cpuid(1, eax, ebx, ecx, std_caps);
|
cpuid(1, eax, ebx, ecx, std_caps);
|
||||||
|
Reference in New Issue
Block a user