Subject: pmc on AMD Duron
To: None <port-i386@netbsd.org>
From: Christian Biere <christianbiere@gmx.de>
List: port-i386
Date: 10/28/2002 18:22:49
--bu(05DUg=.IHFXbH
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit

Hi,

pmc reports wrongly(?) that counters are not supported by this CPU:

cpu0 at mainbus0: (uniprocessor)
cpu0: AMD Duron (686-class), 896.22 MHz
cpu0: features 183f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR>
cpu0: features 183f9ff<PGE,MCA,CMOV,FGPAT,PSE36,MMX>
cpu0: features 183f9ff<FXSR>
cpu0: I-cache 64 KB 64b/line 2-way, D-cache 64 KB 64b/line 2-way
cpu0: L2 cache 64 KB 64b/line 16-way
cpu0: ITLB 16 4 KB entries fully associative, 8 4 MB entries fully
associative cpu0: DTLB 24 4 KB entries fully associative, 8 4 MB entries
4-way cpu0: 8 page colors

pmc_init() sys/arch/i386/i386/pmc.c has cpu_vendor set to "Intel". For
testing I commented out the 'strcmp(cpu_vendor, "AuthenticAMD")'. pmc
worked then although I don't know whether the results are correct. Though
this is just a hack and there must be a better way to explain pmc_init()
the vendor isn't Intel. With -DCPUDEBUG and -DDIAGNOSTIC identifycpu()
reports"cpu0: family 6 model 3 step 1".

Christian

--bu(05DUg=.IHFXbH
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.0 (NetBSD)

iD8DBQE9vXJ00KQix3oyIMcRAg4oAKCP/3uK8bThdrNYdC77bTUwgghyhwCfZ0LH
B53aK4CkuAOb70vGDSIE/po=
=dlkc
-----END PGP SIGNATURE-----

--bu(05DUg=.IHFXbH--