[MPlayer-dev-eng] [PATCH] CPU detection related

Zuxy zuxy.meng at gmail.com
Mon Oct 17 07:10:09 CEST 2005


2005/10/17, Vladimir Mosgalin <mosgalin at vm10124.spb.edu>:
> Hi Zuxy!
>
> Er.. what? If you are talking about "model name" string, it's just a
> string given by bios. After I upgraded to this CPU from A64 3000+
> (Newcastle) old bios on the mobo knew nothing about this new cpu, and
> the string was "AMD Hammer Family - Model unknown" both on the boot
> screen and in cpuinfo. After I updated bios, it became like this.
>
> I don't think it's reliable to rely on such kind of information, but be
> it your way..

No it's not from BIOS. It's obtained directly from the CPU so we could
give accurate information even for a future CPU. But AMD obviously
provides a way for BIOS to modify such namestring through MSRs, so
most possibly your old BIOS has changed the default namestring on
boot, while your new BIOS leaves it untouched.

I'm quite confused by AMD's decision. I see no good in modifying the
default namestring and it may be utilized by remarkers. I'm for the
Intel way, where the namestring's hardwired and can never be changed
by software.
>
> But that is a problem of current detection code, the overall idea still
> works.. Especially with modern CPUs, you can precisely get its name and
> other information from cpuid.

Absolutely if we have known the family, the extended family, the
model, the extended model, the stepping, the cache information and
maybe something else. That's what x86info and cpu-z do. But it's not
mplayer's main focus and I'm lazy...sorry.
>
>
> No, I like the new too (but think about problem I described), it's just
> that I was surprised by the fact that you missed the model name of the
> CPU; from some older thread, I was under impression that you've been
> looking through AMD/Intel sites for information about processor models,
> and I thought that you updated cpu table from the latest model tables on
> both sites. Looks like I was wrong and you picked only several ones.

Firstly, there are no official documents for codenames from either
company. AMD in their docs will refer your CPU as "Sempron Processor
Model 2C" instead of "Paris", so I have to get them from somewhere
else. I knew there's Paris but I didn't know it means Model 2C until
you told me:-) And lastly, if we use the namestring system AMD
codenames simply get ignored because virtually all AMD CPUs support
namestring (it means you won't get Paris if you've applied all the
patches).

>
> By looking at the model number at /proc/cpuinfo, it wasn't clear at all
> what exactly should have I modified in cputable.h, that's why I sent
> cpuinfo contents and the codename to you. But if you don't feel like
> giving an example and vote for throwing away the whole codenames system,
> that's fine..

cputable.h is simple and well commented, just an array indexed by
vendors, families and models and filled with codenames. For you case,
look for vendor "AuthenticAMD", family 'F' and model 'C' (the least
significant nibble of your displayed model '2C') and add " ;Sempron
Paris" after "Athlon 64 Newcastle". Use '/' to seperate multiple
trademarks, use ',' to seperate multiple codenames and use '; ' to
seperate a trademark from preceding codenames, like:

Pentium 4/Celeron 4 Northwood; Xeon Prestonia,Gallatin

for GeniuneIntel Family F Model 2.

Again, if you are to maintain cputable.h you probably won't like the
other patch because it effectively eliminates you work.

Good luck!

--
Zuxy
Beauty is truth,
While truth is beauty.
PGP KeyID: E8555ED6




More information about the MPlayer-dev-eng mailing list