[MPlayer-dev-eng] [Patch] Correction of P4 family CPUs detection in cputable.h
Guillaume POIRIER
poirierg at gmail.com
Tue Oct 4 16:59:27 CEST 2005
Hi,
On 10/2/05, Zuxy <zuxy.meng at gmail.com> wrote:
> Cputable.h seems outdated and contains incorrect information for P4 family
> CPUs. It's not a critical issue though and it's easy to fix.
>
> --- MPlayer-1.0pre7try2\cputable.h Tue Dec 16 21:35:01 2003
> +++ MPlayer-1.0pre7try2.new\cputable.h Sun Oct 2 16:56:25 2005
> @@ -119,11 +119,11 @@
> /* D */ F_UNKNOWN,
> /* E */ F_UNKNOWN,
> /* F extended family (P4/new IA-64)*/ {
> - /* 0 */ N_UNKNOWN,
> - /* 1 */ "Pentium 4/Xeon Willamette",
> - /* 2 */ "Pentium 4/Xeon/Celeron Foster",
> - /* 3 */ "Pentium 4/Xeon/Celeron Northwood",
> - /* 4 */ N_UNKNOWN,
> + /* 0 */ "Pentium 4 Willamtte/Xeon Foster",
> + /* 1 */ "Pentium 4 Willamette/Xeon Foster",
> + /* 2 */ "Pentium 4/Celeron D Northwood/Xeon
> Prestonia/Gallatin",
> + /* 3 */ "Pentium 4/Celeron D Prescott/Xeon
> Nocona",
> + /* 4 */ "Pentium 4/Celeron D Prescott/Xeon
> Nocona",
> /* 5 */ N_UNKNOWN,
> /* 6 */ N_UNKNOWN,
> /* 7 */ N_UNKNOWN,
>
Next time, please send your patches as attachment and do not
copy/paste them in the body of your mail. It makes it more
time-consuming to apply them because of the screwed line wrapping.
Okay, applied that patch (minor the "Willamtte" typo) :-)
> In addition, according to Intel/AMD official documentations, CPU family should
> be displayed as the sum of CPUID's family field and extended family field when
> a CPU has a CPUID family 0xF.
Not that I do not trust you on this, but could you please point me to
the appropriate URL or doc+page number?
I wonder why that part of the code worded so far... is that just
"cosmetics" code?
> --- MPlayer-1.0pre7try2\cpudetect.c Thu Jan 13 05:56:25 2005
> +++ MPlayer-1.0pre7try2.new\cpudetect.c Sun Oct 2 17:04:49 2005
> @@ -122,7 +122,7 @@
> caps->cpuType=(regs2[0] >> 8)&0xf;
> if(caps->cpuType==0xf){
> // use extended family (P4, IA64)
> - caps->cpuType=8+((regs2[0]>>20)&255);
> + caps->cpuType=0xf+((regs2[0]>>20)&255);
> }
> caps->cpuStepping=regs2[0] & 0xf;
Guillaume
--
Reading doesn't hurt, really!
-- Dominik 'Rathann' Mierzejewski
More information about the MPlayer-dev-eng
mailing list