[MPlayer-dev-eng] Bug in loader/win32.c in latest CVS
wpaul at magnesium.net
wpaul at magnesium.net
Sun May 18 00:06:40 CEST 2003
Dear MPlayer developers:
There is a bug in loader/win32.c on the 'main' branch. I am building
on the following system:
System: Sony Picturebook PCG-C1VP
CPU: Transmeta(tm) Crusoe(tm) Processor TM5600 (661.67-MHz 586-class CPU)
OS: FreeBSD 5.0-RELEASE
I checked out sources from today (May 17th) so that I could try out
the native SVQ3 support and found that while the native video codec
worked, the qdmc audio codec was broken. It had worked before in
the 0.90 release of MPlayer. It turns out this is a problem with
CPU detection in the win32 loader.
In win32.c, the expGetSystemInfo() function contains the following
code:
if (gCpuCaps.cpuType == 4)
{
cachedsi.dwProcessorType = PROCESSOR_INTEL_486;
cachedsi.wProcessorLevel = 4;
}
else if (gCpuCaps.cpuType > 5)
{
cachedsi.dwProcessorType = PROCESSOR_INTEL_PENTIUM;
cachedsi.wProcessorLevel = 5;
}
[...]
This line is wrong:
else if (gCpuCaps.cpuType > 5)
It should be:
else if (gCpuCaps.cpuType >= 5)
This bug breaks the qdmc audio codec on any Pentium level CPU. (It
probably breaks other things too.) It turns out the Transmeta TM5600
identifies itself as such a CPU, so I lose. :(
The previous code used a switch statement which handled the 'Pentium
only' case properly.
-Bill
--
=============================================================================
-Bill Paul (510) 749-2329 | Senior Engineer, Master of Unix-Fu
wpaul at windriver.com | Wind River Systems
=============================================================================
"If stupidity were a handicap, you'd have the best parking spot."
=============================================================================
More information about the MPlayer-dev-eng
mailing list