[MPlayer-dev-eng] [PATCH] TOOLS/cpuinfo.c: correct k6_mtrr detection

Reimar at mplayerhq.hu Reimar at mplayerhq.hu
Wed Nov 23 14:15:04 CET 2005


Hi,
On Wed, Nov 23, 2005 at 10:41:21AM +0100, Guillaume Poirier wrote:
> Zuxy wrote:
> > Two years ago Diego added '{ 32, "k6_mtrr", "Memory Type Range
> > Registers" }' to TOOLS/cpuinfo.c. However, the instruction "sal eax,
> > 32" is in effect identical to "sal eax, 0", so what cpuinfo.c really
> > checked is bit 0 of the extended feature string, i.e. built-in FPU. As
> > a consequence k6_mtrr was reported on virtually every AMD CPU.
> > However, only some K6-2 and K6-III supports this type of MTRR,
> > including neither K6, which dosen't have any MTRR, nor Athlons, which
> > implement MTRR in a way compliant with Intel P6.
> > 
> > The attached patch corrects this, plus a lot of new feature bits that
> > pave the way for future optimizations to mplayer, including SSE3.
> 
> This patch works as expected on the machines I've tested it. I'll commit
> it this week in no one objects.

But get rid of the cosmetics. And fix the indentations of the amd_flags2
variable lines.

Greetings,
Reimar DÃffinger




More information about the MPlayer-dev-eng mailing list