[fpc-devel] AMD & Intel CPUCount

Ludo Brands ludo.brands at free.fr
Fri Dec 28 16:25:27 CET 2012

On 28/12/2012 15:46, Ewald wrote:
> Hmmm, that's weird. The results of the Xeon are what I was expecting.
> Quite frankly I don't know how to fix it. Maybe getting the maximum
> amount of threads sharing the caches might prove helpfull, but then
> again it is guesswork. Anyway, can you give this code a try?
> Than if I take the highest value from this and the previous program it
> *might* provide a sensible result. (?)
Xeon:#max threads sharing caches: 16
Atom:#max threads sharing caches: 2

On Xeon cpuid 00000004 returns 0x1c004121 in rax ,  on Atom 0x4121 in 
eax. So both report 2 threads per cache. The cores per package (bits 
31..26) is not coherent. Don't know how to solve that.


More information about the fpc-devel mailing list